pax_global_header00006660000000000000000000000064144120336400014507gustar00rootroot0000000000000052 comment=f0d1c4237a38caa124675b74d90eac9ac54919ad mlterm-3.9.3/000077500000000000000000000000001441203364000130235ustar00rootroot00000000000000mlterm-3.9.3/.github/000077500000000000000000000000001441203364000143635ustar00rootroot00000000000000mlterm-3.9.3/.github/workflows/000077500000000000000000000000001441203364000164205ustar00rootroot00000000000000mlterm-3.9.3/.github/workflows/ci.yml000066400000000000000000000023531441203364000175410ustar00rootroot00000000000000name: ci on: [push, pull_request] jobs: build: runs-on: ${{ matrix.os }} strategy: matrix: os: [macos-latest, ubuntu-latest] steps: - uses: actions/checkout@v2 - name: "setup linux build environment" if: ${{ startsWith(matrix.os, 'ubuntu') }} run: sudo apt install -y libgtk-3-dev libvterm-dev libvte-2.91-dev libsdl2-dev libfribidi-dev libuim-dev libfcitx5core-dev libfcitx5gclient-dev libscim-dev libssh2-1-dev curl - name: "setup macos build environment" if: ${{ startsWith(matrix.os, 'macos') }} run: brew install pkg-config - name: "configure on linux" if: ${{ startsWith(matrix.os, 'ubuntu') }} run: (cd uitoolkit/wayland; sh ./rescanproto.sh); CFLAGS="-Wall -g -O2" ./configure --with-gui=xlib,fb,console,wayland,sdl2 - name: "configure on macos" if: ${{ startsWith(matrix.os, 'macos') }} run: CFLAGS="-Wall -g -O2" ./configure --with-gui=quartz - name: "build on linux" if: ${{ startsWith(matrix.os, 'ubuntu') }} run: make; sudo make install; (cd gtk; make; sudo make install); (cd libvterm; make; sudo make install) - name: "build on macos" if: ${{ startsWith(matrix.os, 'macos') }} run: make; sudo make install mlterm-3.9.3/.gitignore000066400000000000000000000004111441203364000150070ustar00rootroot00000000000000aclocal-msys.m4.diff aclocal-po.m4.diff aclocal-rm.m4.diff encodefilter/util/src man1 script/config.guesssub.sh tool/mlconfig/po/ar.gmo tool/mlconfig/po/de.gmo tool/mlconfig/po/ja.gmo tool/mlconfig/po/mlconfig.pot tool/mlconfig/po/vi.gmo tool/mlconfig/po/zh_TW.gmo mlterm-3.9.3/ABOUT-NLS000066400000000000000000000601571441203364000142630ustar00rootroot00000000000000Notes on the Free Translation Project ************************************* Free software is going international! The Free Translation Project is a way to get maintainers of free software, translators, and users all together, so that will gradually become able to speak many languages. A few packages already provide translations for their messages. If you found this `ABOUT-NLS' file inside a distribution, you may assume that the distributed package does use GNU `gettext' internally, itself available at your nearest GNU archive site. But you do _not_ need to install GNU `gettext' prior to configuring, installing or using this package with messages translated. Installers will find here some useful hints. These notes also explain how users should proceed for getting the programs to use the available translations. They tell how people wanting to contribute and work at translations should contact the appropriate team. When reporting bugs in the `intl/' directory or bugs which may be related to internationalization, you should tell about the version of `gettext' which is used. The information can be found in the `intl/VERSION' file, in internationalized packages. Quick configuration advice ========================== If you want to exploit the full power of internationalization, you should configure it using ./configure --with-included-gettext to force usage of internationalizing routines provided within this package, despite the existence of internationalizing capabilities in the operating system where this package is being installed. So far, only the `gettext' implementation in the GNU C library version 2 provides as many features (such as locale alias, message inheritance, automatic charset conversion or plural form handling) as the implementation here. It is also not possible to offer this additional functionality on top of a `catgets' implementation. Future versions of GNU `gettext' will very likely convey even more functionality. So it might be a good idea to change to GNU `gettext' as soon as possible. So you need _not_ provide this option if you are using GNU libc 2 or you have installed a recent copy of the GNU gettext package with the included `libintl'. INSTALL Matters =============== Some packages are "localizable" when properly installed; the programs they contain can be made to speak your own native language. Most such packages use GNU `gettext'. Other packages have their own ways to internationalization, predating GNU `gettext'. By default, this package will be installed to allow translation of messages. It will automatically detect whether the system already provides the GNU `gettext' functions. If not, the GNU `gettext' own library will be used. This library is wholly contained within this package, usually in the `intl/' subdirectory, so prior installation of the GNU `gettext' package is _not_ required. Installers may use special options at configuration time for changing the default behaviour. The commands: ./configure --with-included-gettext ./configure --disable-nls will respectively bypass any pre-existing `gettext' to use the internationalizing routines provided within this package, or else, _totally_ disable translation of messages. When you already have GNU `gettext' installed on your system and run configure without an option for your new package, `configure' will probably detect the previously built and installed `libintl.a' file and will decide to use this. This might be not what is desirable. You should use the more recent version of the GNU `gettext' library. I.e. if the file `intl/VERSION' shows that the library which comes with this package is more recent, you should use ./configure --with-included-gettext to prevent auto-detection. The configuration process will not test for the `catgets' function and therefore it will not be used. The reason is that even an emulation of `gettext' on top of `catgets' could not provide all the extensions of the GNU `gettext' library. Internationalized packages have usually many `po/LL.po' files, where LL gives an ISO 639 two-letter code identifying the language. Unless translations have been forbidden at `configure' time by using the `--disable-nls' switch, all available translations are installed together with the package. However, the environment variable `LINGUAS' may be set, prior to configuration, to limit the installed set. `LINGUAS' should then contain a space separated list of two-letter codes, stating which languages are allowed. Using This Package ================== As a user, if your language has been installed for this package, you only have to set the `LANG' environment variable to the appropriate `LL_CC' combination. Here `LL' is an ISO 639 two-letter language code, and `CC' is an ISO 3166 two-letter country code. For example, let's suppose that you speak German and live in Germany. At the shell prompt, merely execute `setenv LANG de_DE' (in `csh'), `export LANG; LANG=de_DE' (in `sh') or `export LANG=de_DE' (in `bash'). This can be done from your `.login' or `.profile' file, once and for all. You might think that the country code specification is redundant. But in fact, some languages have dialects in different countries. For example, `de_AT' is used for Austria, and `pt_BR' for Brazil. The country code serves to distinguish the dialects. The locale naming convention of `LL_CC', with `LL' denoting the language and `CC' denoting the country, is the one use on systems based on GNU libc. On other systems, some variations of this scheme are used, such as `LL' or `LL_CC.ENCODING'. You can get the list of locales supported by your system for your country by running the command `locale -a | grep '^LL''. Not all programs have translations for all languages. By default, an English message is shown in place of a nonexistent translation. If you understand other languages, you can set up a priority list of languages. This is done through a different environment variable, called `LANGUAGE'. GNU `gettext' gives preference to `LANGUAGE' over `LANG' for the purpose of message handling, but you still need to have `LANG' set to the primary language; this is required by other parts of the system libraries. For example, some Swedish users who would rather read translations in German than English for when Swedish is not available, set `LANGUAGE' to `sv:de' while leaving `LANG' to `sv_SE'. In the `LANGUAGE' environment variable, but not in the `LANG' environment variable, `LL_CC' combinations can be abbreviated as `LL' to denote the language's main dialect. For example, `de' is equivalent to `de_DE' (German as spoken in Germany), and `pt' to `pt_PT' (Portuguese as spoken in Portugal) in this context. Translating Teams ================= For the Free Translation Project to be a success, we need interested people who like their own language and write it well, and who are also able to synergize with other translators speaking the same language. Each translation team has its own mailing list. The up-to-date list of teams can be found at the Free Translation Project's homepage, `http://www.iro.umontreal.ca/contrib/po/HTML/', in the "National teams" area. If you'd like to volunteer to _work_ at translating messages, you should become a member of the translating team for your own language. The subscribing address is _not_ the same as the list itself, it has `-request' appended. For example, speakers of Swedish can send a message to `sv-request@li.org', having this message body: subscribe Keep in mind that team members are expected to participate _actively_ in translations, or at solving translational difficulties, rather than merely lurking around. If your team does not exist yet and you want to start one, or if you are unsure about what to do or how to get started, please write to `translation@iro.umontreal.ca' to reach the coordinator for all translator teams. The English team is special. It works at improving and uniformizing the terminology in use. Proven linguistic skill are praised more than programming skill, here. Available Packages ================== Languages are not equally supported in all packages. The following matrix shows the current state of internationalization, as of August 2002. The matrix shows, in regard of each package, for which languages PO files have been submitted to translation coordination, with a translation percentage of at least 50%. Ready PO files be bg ca cs da de el en eo es et fi fr +----------------------------------------+ a2ps | [] [] [] [] | ap-utils | | bash | [] [] [] [] | bfd | [] [] | binutils | [] [] | bison | [] [] [] [] | clisp | | clisp | [] [] [] [] | clisplow | | cpio | [] [] [] [] | darkstat | () | diffutils | [] [] [] [] [] [] | enscript | [] [] | error | [] [] [] | fetchmail | [] () [] [] [] () | fileutils | [] [] [] [] [] | findutils | [] [] [] [] [] [] | flex | [] [] [] [] [] | gas | [] [] | gawk | [] [] [] | gcal | [] [] | gcc | [] [] | gettext | [] [] [] [] [] | gnupg | [] [] [] [] [] [] [] | gprof | [] [] | gpsdrive | () () () () () | grep | [] [] [] [] [] [] [] [] | gretl | [] | gthumb | () () () | hello | [] [] [] [] [] [] [] [] [] | id-utils | [] [] [] | indent | [] [] [] [] [] | jpilot | () [] [] [] | jwhois | [] [] | kbd | [] [] [] | ld | [] [] | libc | [] [] [] [] [] [] [] [] | libiconv | [] [] [] [] | lifelines | () () | lilypond | [] [] | lingoteach | [] [] | lingoteach_lessons| () () | lynx | [] [] [] [] [] | m4 | [] [] [] [] [] | make | [] [] [] [] | man-db | [] () () [] () () | mysecretdiary | [] [] [] | nano | [] () [] [] [] [] | nano_1_0 | [] () [] [] [] [] | opcodes | [] [] [] | parted | [] [] [] [] [] | ptx | [] [] [] [] [] [] [] | python | | recode | [] [] [] [] [] [] | sed | [] [] [] [] [] [] [] [] [] [] | sh-utils | [] [] [] [] | sharutils | [] [] [] [] [] [] [] | sketch | () [] () | soundtracker | [] [] [] | sp | [] | tar | [] [] [] [] [] [] | texinfo | [] [] [] [] [] | textutils | [] [] [] [] [] | util-linux | [] [] [] [] [] [] | vorbis-tools | [] | wastesedge | | wdiff | [] [] [] [] [] [] | wget | [] [] [] [] [] [] [] [] [] [] | +----------------------------------------+ be bg ca cs da de el en eo es et fi fr 0 2 19 10 30 44 9 1 12 44 17 6 53 gl he hr hu id it ja ko lv nb nl nn +-------------------------------------+ a2ps | () () [] | ap-utils | | bash | [] | bfd | [] | binutils | [] | bison | [] [] [] [] | clisp | | clisp | [] | clisplow | | cpio | [] [] [] [] | darkstat | | diffutils | [] [] [] [] [] | enscript | [] [] | error | [] | fetchmail | [] | fileutils | [] [] [] | findutils | [] [] [] [] [] [] [] [] | flex | [] | gas | | gawk | [] | gcal | | gcc | [] | gettext | [] [] | gnupg | [] [] [] [] | gprof | [] | gpsdrive | [] () () | grep | [] [] [] [] [] [] [] | gretl | | gthumb | () () | hello | [] [] [] [] [] [] [] [] [] [] [] [] | id-utils | [] [] | indent | [] [] [] [] | jpilot | () () | jwhois | [] [] | kbd | | ld | | libc | [] [] [] [] | libiconv | [] [] [] | lifelines | | lilypond | [] | lingoteach | [] | lingoteach_lessons| | lynx | [] [] [] [] | m4 | [] [] [] [] | make | [] [] [] [] [] [] | man-db | () () | mysecretdiary | [] | nano | [] [] [] [] | nano_1_0 | [] [] [] [] [] | opcodes | [] [] | parted | [] [] [] | ptx | [] [] [] [] [] | python | | recode | [] [] [] | sed | [] [] [] [] [] [] [] [] | sh-utils | [] [] [] | sharutils | [] [] [] | sketch | () | soundtracker | [] [] | sp | | tar | [] [] [] [] [] [] | texinfo | [] [] [] | textutils | [] [] [] [] | util-linux | () [] | vorbis-tools | [] | wastesedge | | wdiff | [] [] [] | wget | [] [] [] [] [] [] | +-------------------------------------+ gl he hr hu id it ja ko lv nb nl nn 23 9 12 19 16 13 26 9 1 7 19 3 no pl pt pt_BR ru sk sl sv tr uk zh_CN zh_TW +----------------------------------------------+ a2ps | () () () [] [] [] [] [] | 10 ap-utils | () | 0 bash | [] | 6 bfd | [] [] | 5 binutils | [] [] | 5 bison | [] [] [] [] | 12 clisp | | 0 clisp | | 5 clisplow | | 0 cpio | [] [] [] [] | 12 darkstat | [] [] () () | 2 diffutils | [] [] [] [] [] [] | 17 enscript | [] [] [] [] | 8 error | [] [] [] | 7 fetchmail | () () [] | 6 fileutils | [] [] [] [] [] [] | 14 findutils | [] [] [] [] [] [] [] | 21 flex | [] [] [] | 9 gas | [] | 3 gawk | [] [] | 6 gcal | [] [] | 4 gcc | [] | 4 gettext | [] [] [] [] [] [] | 13 gnupg | [] [] [] | 14 gprof | [] [] | 5 gpsdrive | [] [] | 3 grep | [] [] [] [] [] | 20 gretl | | 1 gthumb | () () [] | 1 hello | [] [] [] [] [] [] [] | 28 id-utils | [] [] [] [] | 9 indent | [] [] [] [] [] | 14 jpilot | () () [] [] | 5 jwhois | [] () () [] [] | 7 kbd | [] [] | 5 ld | [] [] | 4 libc | [] [] [] [] [] [] | 18 libiconv | [] [] [] [] [] | 12 lifelines | [] | 1 lilypond | [] | 4 lingoteach | [] [] | 5 lingoteach_lessons| () | 0 lynx | [] [] [] [] | 13 m4 | [] [] [] [] | 13 make | [] [] [] [] [] | 15 man-db | | 3 mysecretdiary | [] [] [] | 7 nano | [] [] [] [] | 13 nano_1_0 | [] [] [] [] | 14 opcodes | [] [] [] | 8 parted | [] [] [] [] | 12 ptx | [] [] [] [] [] [] [] | 19 python | | 0 recode | [] [] [] [] [] [] | 15 sed | [] [] [] [] [] [] | 24 sh-utils | [] [] | 9 sharutils | [] [] [] [] | 14 sketch | [] () [] | 4 soundtracker | [] | 6 sp | | 1 tar | [] [] [] [] [] [] [] | 19 texinfo | [] [] | 10 textutils | [] [] [] [] [] | 14 util-linux | [] [] [] | 10 vorbis-tools | [] | 3 wastesedge | | 0 wdiff | [] [] [] [] [] | 14 wget | [] [] [] [] [] [] [] [] | 24 +----------------------------------------------+ 37 teams no pl pt pt_BR ru sk sl sv tr uk zh_CN zh_TW 68 domains 4 15 2 28 28 12 10 49 43 4 1 9 609 Some counters in the preceding matrix are higher than the number of visible blocks let us expect. This is because a few extra PO files are used for implementing regional variants of languages, or language dialects. For a PO file in the matrix above to be effective, the package to which it applies should also have been internationalized and distributed as such by its maintainer. There might be an observable lag between the mere existence a PO file and its wide availability in a distribution. If August 2002 seems to be old, you may fetch a more recent copy of this `ABOUT-NLS' file on most GNU archive sites. The most up-to-date matrix with full percentage details can be found at `http://www.iro.umontreal.ca/contrib/po/HTML/matrix.html'. Using `gettext' in new packages =============================== If you are writing a freely available program and want to internationalize it you are welcome to use GNU `gettext' in your package. Of course you have to respect the GNU Library General Public License which covers the use of the GNU `gettext' library. This means in particular that even non-free programs can use `libintl' as a shared library, whereas only free software can use `libintl' as a static library or use modified versions of `libintl'. Once the sources are changed appropriately and the setup can handle to use of `gettext' the only thing missing are the translations. The Free Translation Project is also available for packages which are not developed inside the GNU project. Therefore the information given above applies also for every other Free Software Project. Contact `translation@iro.umontreal.ca' to make the `.pot' files available to the translation teams. mlterm-3.9.3/ChangeLog000066400000000000000000025637751441203364000146260ustar00rootroot000000000000002023-04-01 Araki Ken * 3.9.3 released. (tag "3.9.3") * configure.in, mlterm.spec, main/version.h.in, mlterm.c, android/jni/version.h, vt_parser.c: updated for 3.9.3. 2023-03-23 Araki Ken * cocoa.m: Unexpected scrolling by scrollbar is fixed. 2023-03-21 Araki Ken * quartz/ui_sb_view_factory.c: ui_sb_view_set_dpr() is added. * ui_sb_view_factory.[ch], ui_main_config.c: ui_simple_scrollbar_set_dpr() -> ui_sb_view_set_dpr() * README.ja, mlterm.1: Updated and fix typo. 2023-03-20 Araki Ken * im_kbd.c: im_kbd_new() returns NULL if kbd layout except arabic and hebrew is requested. * ui_screen.c: - button_motion() ignores Button2Mask, Button4Mask - Button7Mask in selecting region. (https://github.com/arakiken/mlterm/issues/53) - Not only pointer_motion() but button_motion() and button_pressed() call show_pointer(). 2023-03-18 Araki Ken * man/mlterm.1, README.ja, etc/main, etc/main.ja: Updated. * ui_sb_factory.[ch]: ui_simple_scrollbar_set_dpr() is added. * ui_main_config.c: --sdpr / simple_scrollbar_dpr option is added. * motif_data.h, mozmodern_data.h, next_data.h, ui_arrow_data.h: Fix up the appearance. 2023-03-12 Araki Ken * ui_display_linux.c: - 'ent.kb_value == K_ALTGR' is checked instead of 'ev.code == KEY_RIGHTALT'. - Other minor fixes. 2023-02-26 Araki Ken * cocoa.m: MLTermView::update always calls [self setNeedsDisplay:YES]. * ui_screen.c: 'volatile' is added to suppress unexpected optimization by clang 5.1. 2023-02-26 Araki Ken * vt_term_manager.c: vt_get_detached_term() checks if vt_term_get_master_fd() >= 0. (terminator 2.1.2 segfault in exiting pty without this fix.) 2023-02-25 Araki Ken * doc/en/README.*, doc/ja/README.*, gtk/README, etc/main, etc/main.ja, man/mlterm.1: Updated. 2023-02-23 Araki Ken * README: Updated. * config.sub, config.guess: Updated. * xdg-shell-unstable-v6-client-protocol.[ch], xdg-decoration-unstable-v1-client-protocol.[ch]: Updated. 2023-02-20 Araki Ken * README: Updated. * vt_pty_mosh.cpp: USE_TCP_RECV_FROM_SERVER (mosh-1.4.0 sixel-winsock branch) is defined. 2023-02-19 Araki Ken * MLTerm.java, MLTermPty.java: 'int ch' is added to MLTermPty.writeModifiedKey(). * MLTermPty.c: 'jint ch' is added to arguments of Java_mlterm_MLTermPty_nativeWriteModifiedKey(). 2023-02-18 Araki Ken * vterm.c: VTERM_CHECK_VERSION2 macro is added. 2023-02-13 Araki Ken * vterm.c: - vterm_output_set_callback() is added. - Garbage in resizing window is fixed. 2023-02-11 Araki Ken * vt_pty_mosh.cpp: wstring -> std:wstring, min -> std:min * configure.in, libptymosh/Makefile.in, terminaldisplayinit.cc: mosh-1.4.0 is supported. 2023-01-29 Araki Ken * xlib/ui_font.c: int parse_xfont_name() -> void parse_xfont_name() * README.android, README.mosh: Updated. * prepare-gradle.sh: Help message to build with mosh is added. * ef_ucs_property.table: Updated to Unicode 15.0.0 (UnicodeData.txt and EastAsianWidth.txt) 2023-01-28 Araki Ken * README.android: Updated. * android/jni/ui.h: Compiling error of XStringToKeysym() is fixed. * README.mosh, README.wayland: Updated. * uitoolkit/wayland/rescanproto.sh: Added. 2023-01-22 Araki Ken * tool/mlconfig/Makefile.in: If po/Makefile doesn't exist, make is not executed in po/. * configure.in: If $MSGFMT is "no", tool/mlconfig/po/Makefile is not output. 2023-01-21 Araki Ken * encodefilter/src/dexport-sun.map: Added. 2023-01-14 Araki Ken * ui_screen.c: bidi_mode=switch is available. 2023-01-14 Araki Ken * ui_screen.c, vt_term.c: use_dynamic_comb option is disabled if use_ot_layout option is enabled or UCS4 -> ISCII conversion occurs. * configure.in: If libm.so is found, for loop exits immediately. 2022-12-24 Araki Ken * encodefilter/configure.in, baselib/configure.in: 3 configure.in files are itegrated to one file. 2022-11-19 Araki Ken * bl_map.h, pixmap_engine.c, */ui.h, ui_im.[ch], ui_sb_view.h, ui_screen.c: Fix incompatible function pointer types which becomes fatal with clang 16. 2022-11-09 Araki Ken * cocoa/install.sh, cocoa/install-sdl2.sh: mkdir -p $HOME/mlterm(-sdl2).app/Contents/MacOS in advance. 2022-11-05 Araki Ken * aclocal.m4: Update to automake-1.16.5 and libtool-2.4.7. * ltmain.sh, install-sh, missing: Updated. 2022-10-30 Araki Ken * config.sub, config.guess: Updated. * encodefilter/configure.in: POBL_LIBS is never "". 2022-08-16 Araki Ken * c_imagelib.c: Fix buffer over-read. (https://twitter.com/isaki68k/status/1555895011991883783) * vte.c: Fix https://github.com/arakiken/mlterm/pull/49. 2022-07-16 Araki Ken * wayland/ui_display.c, uitoolkit/Makefile.in: - xdg-decoration is removed if COMPAT_LIBVTE is defined. - vte_terminal_paste_text() is added. 2022-07-13 Araki Ken * libptyssh/vt_pty_ssh.c, libptymosh/vt_pty_mosh.cpp: _socketpair(..., SOCKET*) -> _socketpair(..., int*) for 64-bit windows. * vt_config_menu.c: The 1st argument of CreateProcess() is changed from cmd_path (which causes failure in windows 11) to NULL. 2022-07-10 Araki Ken * ui_screen_manager.c, vt_pty_pipewin32.c: Compiling error in win32 without libssh2 is fixed. * configure.in: libregex is checked if regex.h is found. 2022-07-03 Araki Ken * wayland/ui_display.c: decoration_configure() doesn't call xdg_surface_ack_configure(). (https://github.com/arakiken/mlterm/issues/44) 2022-06-05 Araki Ken * bl_conf_io.c: XDG_CONFIG_HOME is supported. 2022-04-24 Araki Ken * inputmethod/*/Makefile.in, ui_im.c: The dll file name is changed from libim-xxx to libimx-xxx if USE_COMPACT_TRUECOLOR is not defined. 2022-04-24 Araki Ken * README.ja, doc/{en,ja}/README.fb: Updated. * inputmethod/*/Makefile.in, java/Makefile.in, libvterm/Makefile.in, gtk/Makefile.in: @TRUECOLOR_CFLAGS@ is added. * Android.mk: -DUSE_COMPACT_TRUECOLOR is added to LOCAL_CFLAGS. * c_animgif.c, skk/dict.c, daemon.c, mc_font.c, vt_parser.c, xlib/ui_display.c, vt_pty_ssh.c, vt_config_menu.c, vt_termcap.c: char [] -> const char []. * vt_color.c: #ifdef USE_COMPACT_TRUECOLOR ... #endif is added. * vterm.c: VTermStateFallbacks (introduced at libvterm-0.2) is supported. 2022-04-03 Araki Ken * vt_parser.[ch]: vt_parser->yield = 1 if CSI 38 ... m or CSI 48 ... m is processed and USE_COMPACT_TRUECOLOR is defined, because it reuses at most 240 color palettes. * vt_color.[ch]: - IS_TRUE_COLOR() macro is added. - vt_get_closest_color() is fixed. * vt_char.[ch]: fg_color2 and bg_color2 are added to vt_char_t. * ui_color_config.[ch]: - ui_color_cache_true_t is added. - get_cached_true_xcolor() is added. * configure.in: --disable-compact-truecolor option is added. 2022-02-13 Araki Ken * xdg-shell-client-protocol.[ch]: Updated. 2022-02-13 Araki Ken * wayland/ui_display.c: shell_surface_configure() does nothing if width or height argument is 0. 2022-02-13 Araki Ken * wayland/ui.h, wayland/ui_display.c, Makefile.in: xdg-decoration is supported. * wayland/xdg-decoration-unstable-v1-client-protocol.[ch]: Added. 2022-02-05 Araki Ken * ui_screen_manager.c: Set COLORTERM environmental variable. 2022-02-04 Araki Ken * c_sixel.c: Fix segmentation fault when the repeat count in sixel sequence is over 512. (https://github.com/arakiken/mlterm/issues/35) 2022-01-29 Araki Ken * doc/en/ControlSequences, doc/en/ReleaseNote: Updated. 2022-01-29 Araki Ken * ui_layout.c: - ui_screen_set_pointer_motion_event_mask() is used instead of ui_window_{add|remove}_event_mask(). - ui_window_t::pointer_motion is replaced by screen_pointer_motion() only if autohide_scrollbar is enabled. * ui_screen.[ch]: ui_screen_set_pointer_motion_event_mask() is added. * vt_parser.c: The default value of XTSMPOINTER (CSI>p) is changed from 2 to 1. * version.h: 3.9.2 -> 3.9.2post 2022-01-16 Araki Ken * 3.9.2 released. (tag "rel-3_9_2") * configure.in, mlterm.spec, main/version.h.in, mlterm.c, android/jni/version.h, vt_parser.c: updated for 3.9.2. * README, man/mlterm.1, doc/en/PROTOCOL, etc/main, etc/main.ja, gtk/README, doc/en/README.win32, doc/ja/README.win32 : Updated. 2021-12-31 Araki Ken * gtk/vte.c: vte_terminal_{set|get}_scroll_unit_is_pixels() are added. 2021-08-21 Araki Ken * vtemu/mlterm.c, libvterm/Makefile.in: libvterm compatible library doesn't call bl_sig_child_start(). 2021-08-20 Araki Ken * main.c, main_loop.c: main_loop_init() instead of main() calls vt_set_timeout_read_pty(). * vt_parser.c: Revert pull request #23. 2021-08-15 Araki Ken * vte.c: - main_config.col = main_config.rows = 1 is forced on wayland for gnome-termnal and sakura. - vte_terminal_set_size() sets PVT(terminal)->init_char_size = 1 temporarily before calling vte_terminal_get_preferred_height(). - Not only screen->window.{width|height} but also screen->{width|height} are also set in vte_terminal_set_size(). * vte_wayland.c: display_move() is added for roxterm. * wayland/ui_display.c: 'int dummy' is added to arguments of ui_display_map(). 2021-08-08 Araki Ken * MLPreferenceActivity.java: - TYPE_CLASS_NUMBER -> INPUT_TEXT_VARIATION_VISIBLE_PASSWORD in "Backlog size" entry to input "unlimited". - INPUT_TEXT_VARIATION_URI -> INPUT_TEXT_VARIATION_VISIBLE_PASSWORD in "Encoding", "Foreground Color" and "Background Color" entries. * MLActivity.java: INPUT_TEXT_VARIATION_URI -> INPUT_TEXT_VARIATION_VISIBLE_PASSWORD in "Encoding" entry of the connect dialog. 2021-08-07 Araki Ken * ui_screen.c: Flick behavior is adjusted in button_motion(). * beos.cpp: unichar -> u_int16_t (unichar is removed at HaikuOS R1Beta3) * sdl2/ui_display.c: #ifdef -> #if 2021-07-24 Araki Ken * xlib/ui_window.c: ui_set_use_clipboard_selection() calls ui_display_clear_selection() only if use_clipboard == 0 and use_it == 1. * wayland/ui_display.c: - ui_set_use_clipboard_selection() and ui_is_using_clipboard_selection() are added. - If disp_name is "", ui_display_open() uses WAYLAND_DISPLAY environmental variable. * ui_screen.c, ui_shortcut.[ch]: INSERT_CLIPBOARD is available on wayland. * ui_main_config.c: The default value of "display" option is changed from "wayland-0" to "" on wayland. * MLActivity.java: servListDialogLayout and connectDialogLayout are set to null after finishing dialogs. 2021-07-10 Araki Ken * sdl2/ui.h: ALPHA_TO_PIXEL macro is defined. * wayland/ui.h: ALPHA_TO_PIXEL macro is defined. 2021-07-07 Araki Ken * android/jni/ui.h: ALPHA_TO_PIXEL macro is defined. 2021-07-03 Araki Ken * vt_parser.c: "CSI > q" (XTVERSION) is supported. (The response is "DCS > | mlterm(3.9.1) ST") 2021-07-01 Araki Ken * vt_parser.c: show_picture() restores vt_parser->is_visible_cursor if sixel_scrolling is true. 2021-06-19 Araki Ken * etc/key: Updated. * jni/ui_xic.c: ui_xic_switch_mode() calls asciiInput() or normalInput() alternately. * MLActivity.java: - forceAsciiInput() -> asciiInput() - normalInput() is added. - commitCompletion() and commitCorrection() are added. 2021-06-12 Araki Ken * ui_screen.c: Compiling error is fixed. 2021-06-11 Araki Ken * README.ja, PROTOCOL, mlterm.1: Updated. * ui_main_config.c: --fk / format_keys option is added. * ui_screen.c: - INSERT_CLIPBOARD shortcut key is checked. - "paste" OSC 5379 command accepts "clipboard" argument. * ui_shortcut.[ch]: INSERT_CLIPBOARD shortcut is added. * xlib/ui_window.c: ui_set_use_clipboard_selection(2) makes ui_window_{utf|xct}_selection_request() call XConvertSelection() with XA_CLIPBOARD instead of XA_PRIMARY. XA_CLIPBOARD is regarded in processing SelectionNotify or PropertyNotify. * vt_parser.[ch]: - vt_set_format_other_keys() which works as "formatOtherKeys" of xterm is added. - Compatiblity of the behavior of xterm with modifyOtherKeys = 1 is improved. - 'ch' is added to arguments of vt_parser_write_modified_key(). 2021-05-15 Araki Ken * README.ja, etc/key: Updated. * ui_font_ft.c: - CAIRO_FORCE_DOUBLE_DRAWING is defined only if cairo < 1.8.0. - CAIRO_HINT_STYLE_NONE is not used. * vte.c: vte_terminal_{set|get}_enable_fallback_scrolling() are added. 2021-05-10 Araki Ken * README.ja, etc/key: Updated. * ui_font_ft.c: CAIRO_HINT_STYLE_NONE is not applied to improve the quality of drawing glyphs. 2021-05-08 Araki Ken * ui_screen.c: "proto:key=value" shortcut keys don't show "Config: key=value" message in the screen, while "proto:(echo)key=value" shortcut keys shows it as before. * tool/mlconfig/po/*.po: Updated. 2021-05-07 Araki Ken * README, README.ja: Updated. * mlterm.1: Comments about features output by 'mlterm -v' are added. * configure.in: --with-gtk=4.0 is available. * mlconfig/Makefile.in: GTK_{CFLAGS|LIBS} -> GTK_{CFLAGS|LIBS}_FOR_MLCONFIG * mlconfig/*.[ch]: GTK-4.x is supported. * vt_line.h: ctl_info and ctl_info_type are moved at the end of vt_line_t to keep binary compatibility if ctl is completely disabled. 2021-04-23 Araki Ken * vt_parser.c: - Failure of parsing "OSC Ps ST" which doesn't contain ';' is fixed. - 'int want_ctrl' is removed from arguments of inc_str_in_esc_seq(). 2021-04-17 Araki Ken * README.fb: Updated. * ui_display_linux.c: The format of KBD_INPUT_NUM and MOUSE_INPUT_NUM is changed from "%d" to "%d,%d" which enables multiple input devices. * fb/ui_display_*.c: 'int fd' is added to arguments of receive_{key|mouse}_event(). 2021-04-16 Araki Ken * ui_font_cache.[ch]: - ui_compose_dec_special_font() is added. - ui_font_cache_get_font() creates a dynamic font for DEC special characters if compose_dec_special_font option is true or ui_font_new() fails. * */ui_font.c: - ui_compose_dec_special_font() is removed. - ui_font_new_for_decsp() (dummy on beos, quartz and win32) is added. 2021-04-09 Araki Ken * im_fcitx.c: fcitx-utils/keysymgen.h is included only if NO_XKB is defined. 2021-04-06 Araki Ken * README, README.ja: Updated. * im_fcitx.c, configure.in: fcitx5 is supported. 2021-03-28 Araki Ken * vt_screen.c: BL_MAX(line->num_filled_chars, logical_num_filled_chars) is passed to vt_log_add(). * vt_logs.[ch]: 'u_int num_chars' is added to arguments of vt_log_add(). * vt_line_bidi.c: The allocated memory size of 'src' is changed from line->ctl_info.bidi->size to line->num_filled_chars in vt_line_bidi_logical() because the former can be greater than the latter. * ui_font_ft.c: check_pixel_size() which is moved from cairo_font_open() is added, and cairo_compl_font_open() also calls it. 2021-03-21 Araki Ken * fb/ui_font.c, libtype/ui_font_ft.c, ui_font.h: - get_ft_bitmap() and ui_serach_next_cairo_font() checks all fonts listed by FcFontList(). - cairo_font_open() adjusts the size of color emoji fonts like NotoColorEmoji.ttf in opening them. * im_uim.c: prop_list_update() uses malloc() instead of BUFSIZE. 2021-03-08 Araki Ken * README, README.ja: Updated. * encodefilter/test.c: - TEST_MAP() -> TEST_MAP_UCS4() - OUTPUT() -> OUTPUT_UCS4() - TEST_MAP_NON_UCS4() and OUTPUT_NON_UCS4() macros are added. * ef_uhc_johab.c: If USE_ICONV macro is defined, ef_map_johab_to_uhc() and ef_map_uhc_to_johab() use iconv(). * encodefilter/configure.in: If --with-iconv is specified, --disable-dl-table is also specified automatically. * configure.in: --without-gtk options disables mlconfig etc which use gtk+. 2021-03-02 Araki Ken * README, README.ja: Updated. * main_loop.c: bl_init_prot() is called with "no-daemon", "no-split", "no-image", "no-zmodem" or "no-xdnd" if NO_DAEMON, NO_SPLIT, NO_IMAGE, NO_ZMODEM or DISABLE_XDND are defined. * android/jni/ui_event_source.c: Java_mlterm_native_1activity_MLActivity_{resume|pause}Native() -> ui_activity_{resume|pause}() * android/jni/ui_display.c: on_app_cmd() processes APP_CMD_PAUSE and APP_CMD_RESUME. * MLActivity.java: onResume() or onPause() doesn't call resumeNative() or pauseNative(). * vtemu/Makefile.in: @TRANSFER_CFLAGS@ and @TRANSFER_LIBS@ are added. * uitoolkit/Makefile.in: @SPLIT_CFLAGS@ is added. * main/Makefile.in: @DAEMON_CFLAGS@, @SPLIT_CFLAGS@, @DND_CFLAGS@ @TRANSFER_CFLAGS@ and @IMAGE_CFLAGS@ are added. * vt_transfer.[ch]: If NO_ZMODEM is defined, vt_transfer_* functions are disabled. * ui_layout.[ch]: If NO_SPLIT is defined, ui_layout_*() functions except ui_layout_{new|delete}() are disabled. * daemon.[ch]: If NO_DAEMON is defined, daemon_*() functions are disabled. * configure.in: --disable-daemon, --disable-split and --disable-zmodem options are added. * vtemu/mlterm.c: 3.9.1 -> 3.9.2 2021-02-21 Araki Ken * encodefilter/src/Makefile.in: 3.0 -> 3.1 * encodefilter/src/dexport.map: TEST_encodefilter is added. * uitoolkit/test.c: TEST_encodefilter() is called. * encodefilter/src/test.c: Added. * encodefilter/src/ef_ucs4_map.c: TCVN5712_1_1993 is added to map_table. * encodefilter/src/ef_ucs4_tcvn5712_1.c: Typo fixed. * encodefilter/src/ef_8bit_conv.[ch], ef_8bit_parser.[ch]: ef_tcvn5712_1_1993_{conv|parser}_new() are added. * encodefilter/src/ef_ucs4_cp125x: ef_map_ucs4_to_cp874() sets EF_COMBINING property for 0xd1, 0xd4-0xda and 0xe7-0xee. * encodefilter/module/table/*.table: Updated. * encodefilter/module/ef_ucs4_tcvn5712_1.c: ef_map_ucs4_to_tcvn5712_1_1993() sets EF_COMBINING property for 0xb0-0xb4. * encodefilter/module/ef_ucs4_{cp125x|georgian_ps|koi8|tcvn5712_1|viscii}.c: ef_map_*_to_ucs() ignores 0x20 - 0x7e. * encodefilter/module/ef_ucs4_*.c: If USE_ICONV is defined, ef_map_*_to_ucs4() and ef_map_ucs4_to_*() use iconv() instead of table/*.table. * encodefilter/module/ef_iconv.h: Added * encodefilter/util/*.pl: Fixes by the change of arguments of output_table_ucs_to() and output_table_to_ucs() in ucs_mapping.pm * encodefilter/util/ucs_mapping.pm: The size of mapping table by output_separated() is shrinked. * configure.in, encodefilter/configure.in: --with-iconv option is added. * bl_path.c: TEST_bl_basename() is added. 2021-02-11 Araki Ken * mc_font.c: Compiling error is fixed. 2021-02-06 Araki Ken * xlib/ui_window.c: Segfault is fixed if mlterm screen with -t option goes outside of the display. 2021-02-03 Araki Ken * vt_pty_mosh.cpp: dead_network >= 0 => dead_network->tcp_sock >= 0 * android/jni/ui_display.c: proto of bl_parse_uri() is passed to showConnectDialog(). * android/jni/ui_connect_dialog.c: 'serv' argument of Java_mlterm_native_1activity_MLActivity_dialogOkClicked() can include "://". * MLActivity.java: - "mosh://" is supported in 'Server' text field of the connect dialog. - 'proto' is added to arguments of showConnectDialog(). * prepare-gradle.sh: mosh is supported. * Android.mk: Settings to build libptymosh are added. 2021-01-25 Araki Ken * vt_parser.c: write_loopback() doesn't reset vt_parser->r_buf.left and vt_parser->r_buf.filled_len if mlterm works as libvterm compatible library. * ui_screen.c etc: sizeof(a) / sizeof(a[0]) => BL_ARRAY_SIZE * bl_util.h: BL_ARRAY_SIZE is added. 2021-01-16 Araki Ken * vt_logical_visual.c, vt_parser.c: vt_is_arabic_combining() is not used. * vt_shape.[ch]: vt_is_arabic_combining() is removed. * vt_ctl_loader.h, vt_functbl_bidi.c: VT_IS_ARABIC_COMBINING is removed from vt_ctl_bidi_id. * vt_shape_bidi.c: - get_arabic_comb2_present_code() is added instead of vt_is_arabic_combining(). - vt_is_arabic_combining() returns the number of combined characters. - 0x6BA is added to arabic_present_table. * vt_line_bidi.c: - vt_line_bidi_render() calls vt_line_set_modified() with vt_convert_col_to_char_index(line->change_end_col, BREAK_BOUNDARY), not with vt_line_get_end_of_modified() to clear the line correctly. - vt_line_bidi_visual(), vt_line_bidi_logical() and vt_line_bidi_copy_logical_str() support dynamic combining. * libctl/vt_bidi.c: - TEST_vt_bidi() is added. - adjust_comb_pos_in_order() is added for dynamic combining. * ui_picture.c: MAX_PAGE_ID macro is used instead of 8. * mc_io_file.c: Unnecessary entries are removed from 'options' table. 2020-12-31 Araki Ken * fb/ui_virtual_kbd.c: Compiling error is fixed if ./configure is executed with --disable-image option. 2020-12-30 Araki Ken * android/jni/ui_display.c: Fix by 28174359f35290631dbd772be8de03fac78cbd34 commit (2020/10/06) is reverted. * MLActivity.java: Server list dialog is shown at startup. * vt_parser.c: write_loopback() allocates at least PTY_RD_BUFFER_SIZE for vt_parser->r_buf.chars. (open_pty_intern() in ui_screen_manager.c calls vt_term_write_loopback() when vt_parser->r_buf.len is still 0). 2020-12-11 Araki Ken * README.ja, man/mlterm.1, etc/termcap: Updated. * test.c: TEST_vt_termcap() is added. * vt_termcap.c: - TEST_vt_termcap() is added. - read_conf() calls search_termcap() with perfect_match == true, while vt_termcap_get() calls it with perfect_match == false. - perfect_match is added to arguments of search_termcap(). - search_termcap() stops to accept multiple terminal types concated by '|'. 2020-11-29 Araki Ken * ui_screen_manager.c: The previous commit didn't work by Ctrl+F1. 2020-11-28 Araki Ken * ui_screen_manager.c: The same privkey file is used for mosh connection in pressing Ctrl+F1 or Ctrl+F2. * vt_term.[ch]: vt_term_t stores not only 'uri' but also 'privkey' to use the same privkey file in pressing Ctrl+F1 or Ctrl+F2 for mosh connection. * README.cocoa, README.cocoatouch, README.ja, etc/main.ja: Updated. * ui_main_config.c: use_login_shell=false by default on MacOS. 2020-11-13 Araki Ken * vt_pty_mosh.cpp: "MOSH_UDP_PORT" environmental variable is added to specify UDP port or port-range to communicate with a mosh server. * version.h: 3.9.1 -> 3.9.1post 2020-11-08 Araki Ken * 3.9.1 released. (tag "rel-3_9_1") * configure.in, mlterm.spec, main/version.h.in, mlterm.c, android/jni/version.h: updated for 3.9.1. * README, man/mlterm.1, doc/en/PROTOCOL, etc/main, etc/main.ja, doc/en/README.fb, doc/ja/README.fb: Updated. 2020-11-08 Araki Ken * xlib/ui_font.c: ui_font_new() returns NULL if specified type engine is disabled. 2020-11-07 Araki Ken * gtk/README: Updated. * vte.c: New functions at vte 0.62 (vte_terminal_spawn_with_fds_async(), vte_get_feature_flags(), vte_terminal_event_check_regex_array(), vte_terminal_set_enable_sixel() and vte_terminal_get_enable_sixel()) are added. * ui_screen.c: get_config_intern() returns correct value if depth < 32. 2020-11-06 Araki Ken * ui_display_x68kgrf.c: conf_1024_768_4.videoc.r1 = 0x24e4 2020-11-01 Araki Ken * sdl2/ui_display.c: Type miss is fixed. (SDL_VERSION_AT_LEAST -> SDL_VERSION_ATLEAST) 2020-10-31 Araki Ken * vt_parser.c: Compiling error in buidling by ./configure --disable-image. * ui_layout.c: ui_layout_remove_child() reverts screen->screen_listener.line_scroll_out to the original one. 2020-10-27 Araki Ken * ui_screen.c: font_size_changed() sets normal hints correctly by calling ui_window_set_normal_hints() after resize_window(). 2020-10-25 Araki Ken * xlib/ui_imagelib.c: ui_imagelib_get_transparent_background() calls modify_pixmap() for the entire image. (Fix http://twitter.com/oshimyja/status/1320251099211649024) * vt_parser.c: - is_separated_sixel() is added to fix https://github.com/arakiken/mlterm/issues/4. - TEST_vt_parser() is added. * test.c: TEST_vt_parser() is called. 2020-10-25 Araki Ken * fb/ui_font.c: get_metrics() fails if width or height in PCF_METRICS table is 0. 2020-10-24 Araki Ken * cocoa.m: window_set_title() and cocoa_clipboard_set() check if utf8 argument has valid utf8 sequence by is_valid_utf8(). * sdl2/ui_display.c: SDL_WINDOW_ALWAYS_ON_TOP, SDL_WINDOW_SKIP_TASKBAR and SDL_WINDOW_UTILITY are used on SDL 2.0.5 or later. * libptymosh/vt_pty_mosh.cpp: pty.master = 1000 (dummy value) on win32. 2020-10-17 Araki Ken * libptyssh/vt_pty_ssh.c: vt_pty_ssh.c includes instead of declaring CRYPTO_num_lock() because CRYPTO_num_lock() is defined as 0 on some environments. 2020-10-12 Araki Ken * vt_line_shape.c: Compiling error by the previous commit is fixed. 2020-10-11 Araki Ken * servman/main.c, win32/ui_connect_dialog.c: X11 checkbox is grayed out if protocol except ssh is selected. * vt_line_shape.c: If open type layout is enabled, vt_shape_ot_layout() is called directly instead of 'func' because its type is different from that of vt_shape_arabic and vt_shape_iscii. * ui_im.h: The type of return value of vt_char_set is fixed. (int -> void) * im_kbd.c, ui_color.c: Fix typo. 2020-10-10 Araki Ken * vt_parser.c: wcwidth() is declared manually instead of including * ui_display_linux.c: strcasestr() is declared manually instead of including * ui_display.h: #ifdef USE_WIN32API ui_display_trigger_pty_read() #endif -> #ifdef NO_DISPLAY_FD ui_display_trigger_pty_read() #endif 2020-10-07 Araki Ken * doc/en/README.android: Updated. * android/jni/ui_display.c: _display and _disp are cleared completely not to leave dust on the screen in restarting mlterm-android. 2020-10-06 Araki Ken * libptyssh/vt_pty_ssh.c: scp_thread() truncates received bytes that exceed scp->src_size. 2020-10-03 Araki Ken * README.android: Updated. * prepare-gradle.sh, build-gradle.sh, build.gradle: Added. * android/jni/main.c, android/jni/ui_event_source.c, wnnlib.c: Implicite declaration is fixed. * android/jni/Android.mk: Fixes to build with gradle. * android/build-ant.sh: Renamed from build.sh. * win32/ui_window.c: If ui_layout receives WM_MOUSEWHEEL or WM_MOUSEHWHEEL, it is dispatched to the focused ui_screen. 2020-09-13 Araki Ken * win32/ui_connect_dialog.c: The new format of response of "servman" is supported. * servman/main.c, servman.rc: SSH private key path is configurable for each server. 2020-09-12 Araki Ken * ui_screen.c: trim_trailing_newline_in_pasting3() and convert_nl_to_cr3() which process WCHAR instead of u_char are added for win32. 2020-09-09 Araki Ken * vte.c: log_size_changed() and term_changed() set adj_value_changed_by_myself = 1. 2020-09-08 Araki Ken * ef_ucs_property.table: Updated to Unicode 13.0.0 (UnicodeData.txt and EastAsianWidth.txt) * vte.c: - ui_screen_scroll_event_listener_t::term_changed is implemented. - log_size_changed() is fixed. 2020-09-07 Araki Ken * vterm.c: vterm_{state|screen}_convert_color_to_rgb() are added. 2020-09-06 Araki Ken * vt_screen.c: If vt_edit_resize() returns 3, resize() forcibly set 'pack' to 0. * vt_edit.c: vt_edit_resize() returns 3 if RZ_SCROLL scrolls out all lines. 2020-09-05 Araki Ken * ui_screen.c: If vt_term_enter_backscroll_mode() returns 2, scrollbar state is reset. * vt_term.[ch]: vt_term_enter_backscroll_mode() returns the returned value of vt_enter_backscroll_mode(). * vt_screen.[ch]: - need_rewrap_logs is added to vt_screen_t, and If vt_edit_resize() returns 2, need_rewrap_logs is set to 1. - If need_rewap_logs is 1, vt_enter_backscroll_mode() calls rewrap_logs() which rewraps backlog according to the new number of columns. - If the number of logged lines is changed by rewrap_logs(), vt_enter_backscroll_mode() returns 2. * vt_edit.c: - replace_chars_in_line() uses vt_str_cols_to_len(). - vt_edit_resize() returns 2 if old_cols != new_cols and resize_mode == RZ_WRAP. * vt_str.[ch]: vt_str_cols_to_len() is added. * vt_iscii.c: - Duplicated entries in tables are removed. - If load_symbol() fails once, it is never called. - If vt_iscii_shape() returns 0, vt_iscii() does nothing. 2020-08-29 Araki Ken * vt_edit.[ch]: - vt_edit_resize() and resize_hadjustment() don't scroll out the cursor line. - top_line_is_wrapped() is added to vt_edit_scroll_event_listener_t. - vt_edit_resize() fully scrolls out the wrapped lines which are partially scrolled out if the new number of columns is greater than the old one. * vt_screen.c: - top_line_is_wrapped() is added. - REVERT_BACKLOG_FOR_HADJUSTMENT is always enabled. 2020-08-24 Araki Ken * xlib/ui_window.c: "use_transbg" option is disabled if depth is 32. * ui_screen.c: True transparency is revived if wall picture is removed on 32 bit depth. 2020-08-23 Araki Ken * PROTOCOL: Updated. * mc_io_pty.c: If "True Transparent" checkbox is applied but isn't saved, message dialog informs of it. * mc_bgtype.c: "True Transparent" checkbox is added. * ui_screen.c: "depth" is added to OSC 5380. 2020-08-22 Araki Ken * vt_cursor.c: cursor_goto() checks if row is not less than 0. 2020-08-22 Araki Ken * gtk/vte.c, MLTermPty.c, vterm.c, ui_picture.c, ui_screen.c, vt_cursor.c, vt_parser.c, vt_screen.c, vt_term.c: If vt_term_get_line() always returns non-NULL, NULL check is removed. * vt_logical_visual.[ch]: - The type of the return value of *_render() and *_visual_line() is changed from int to void. - comb_render() does nothing instead of calling comb_visual(). - vt_get_vertical_mode() -> vt_get_vertical_mode_by_name() - Illegal arguments passing to vt_model_resize() is fixed. * vt_bidi.[ch]: vt_get_bidi_mode() -> vt_get_bidi_mode_by_name() * xlib/ui_font.c: ui_convert_to_xft_ucs4() converts JISX0208_1983 characters correctly. (Enbugged at 34cdc1ec9f6110cf112b66c720ad41db08deb8df) * vt_model.[ch]: The type of the return value of vt_model_scroll_{up|down}ward() is changed from int to void. 2020-08-22 Araki Ken * man/mlterm.1, README.ja: Updated. * ui_main_config.c: "scroll_on_resizing" option is removed, and "resize_mode" option is added. * ui_screen.c: - selecting_word() checks whether pressed position is over the end character of a line or not correctly. - start_vt100_cmd() calls ui_window_update() if screen->term has vt_logvis which includes bidi. - 'int sb_flag' is added to arguments of xterm_resize(), and if it is true, xterm_resize() calls screen->screen_scroll_listener->term_changed(). * vt_term.h: vt_term_has_logical_visual() is added. * vt_screen.[ch]: - vt_screen_resize() wraps each line when it reverts lines from backlog. - 'int pack' is removed from arguments of vt_screen_resize(). - vt_screen_has_logical_visual() is added. * vt_edit.[ch]: - vt_set_resize_mode(), vt_get_resize_mode_by_name(), vt_edit_replace() and vt_edit_get_num_filled_rows() are added. - If resize_mode is RZ_WRAP, vt_edit_resize() wraps text on the screen. * vt_model.[ch]: The type of 'slide' argument of vt_model_resize() is changed from u_int* to u_int. * vt_parser.[ch]: 'int sb_flag' which informs ui_screen of changing scrollbar size is added to arguments of vt_xterm_event_listener_t::resize(). * vt_logical_visual.[ch]: char* -> const char* 2020-08-11 Araki Ken * README.ja: Updated. * test.c: TEST_bl_str() is added. * bl_conf.c, bl_str.c, data_entry_numeric.c, data_entry_string.c, mlterm-menu.c, mc_auto_detect.c, mc_im.c, ui_picture.c, xlib/ui_imagelib.c: Memory leak is fixed. * bl_debug.c, athena.c, mozmodern.c, motif.c, next.c, data_entry_radio.c, im_skk.c, ui_sample_sb_view_lib.c, fb/ui_window.c, ui_im_candidate_screen.c, libctl/vt_bidi.c, libctl/vt_iscii.c, vt_ot_layout.c: Meaningless code is removed. * */ui_font.[ch], ui_font_ft.c, ui_font_manager[ch], ui_font_cache.[ch], ui_screen.c, ui_main_config.[ch]: Negative value is accepted for letter_space. * vt_parser.c: request_locator() restore the original state of vt_parser->locator_mode and vt_parser->mouse_mode. * wayland/ui_display.c: Untabified. * ui_layout.c: 'return 1' is removed from screen_scroll_downward(). * beos.cpp: view_draw_string() considers font->x_off. * im_uim.c: Double free() is fixed. * bl_locale.c: bl_locale_init() returns 0 if setlocale() fails. * data.h: MAX_ENTRY is changed from 8 to 9. * ef_sjis_parser.c: Broken processing JISX0213 is fixed. * zmodem.c: get_type_string() is added. 2020-08-02 Araki Ken * wayland/ui_display.c: If wl_display_dispatch() returns -1 (failure), ui_window_t::window_destroyed() is called. 2020-08-01 Araki Ken * gtk/README: Updated. * vte_xlib.c: XInput2 event (XIDeviceEvent) is converted to XEvent. 2020-07-26 Araki Ken * MLPreferenceActivity.java: "Local echo mode" is removed. 2020-07-26 Araki Ken * MLPreferenceActivity.java: - ArrayIndexOutOfBoundsException is fixed. - "Local echo mode" is added. * vt_parser.c: "CSI 3 J" is supported. 2020-07-25 Araki Ken * fb/ui_font.[ch]: 'get_space_glyph' is added to arguments of ui_get_bitmap(). (If get_space_glyph is false, ui_get_bitmap() returns NULL for 0x20.) * fb/ui_window.c: Clipping process in draw_string_intern() is fixed. 2020-07-25 Araki Ken * fb/ui_window.c: Proportional glyphs are placed at the center of cells only if CENTER_PROPORTIONAL_GLYPHS is defined, * fb/ui_font.c: MAXIMIZE_HEIGHT macro is removed. * fb/ui.c: XStringToKeysym() supports 'A' - 'Z'. 2020-07-24 Araki Ken * cocoa.m: insertText() sets kev.keysym. * ui_screen.c: Lines outside the screen in backscrolling is not drawn. * wayland/ui_display.c: ui_display_get_utf8() removes NULL character. * vt_shape.c: combine_replacing_code() returns 1 (success) or 0 (vt_char_combine_forcibly() fails). * vt_char.[ch]: vt_char_combine_forcibly() which doesn't consider IS_ZERO_WIDTH() is added. * Android.mk: ui_copymode.c is added to LOCAL_SRC_FILES. * fb/ui_window.c: Clipping process for DECDHL is moved from draw_string() to draw_string_intern() to use ui_modify_bitmaps() well. * fb/ui_font.[ch]: - If MAXIMIZE_HEIGHT is not defined, face->glyph->bitmap_top and face->glyph->bitmap.rows are stored to cache and adjusting glyph position is processed by ui_modify_bitmaps(). - The type of XFontStruct::glyph_indeces which stores segment and offset of each glyph is changed from u_int16_t to u_int32_t, and segment is expanded from 7bit to 23 bit to get glyph size variable. - next_glyph_buf() which returns the next buffer to store glyph bitmap is added. - If XFontStruct::is_aa is true, 4 bytes header which stores height position info and pitch is embedded in each glyph buffer. * fb/ui.h, sdl2/ui.h, wayland/ui.h, android/jni/ui.h: - has_each_glyph_width_info, num_glyph_bufs and glyph_buf_left are added to XFontStruct. - glyph_size is removed from XFontStruct. - Type of width, width_full, height and ascent is changed from u_char to u_int16_t. * ui_font.h: The type of width, height and ascent of ui_font_t is changed from u_int8_t to u_int16_t. * ui_font_manager.c: If USE_FREETYPE is defined, the default value of max_font_size is changed from 10000 to 200. 2020-06-30 Araki Ken * beos.cpp: MLView::MessageReceived() calls BView::MessageReceived() if it doesn't process the received message. 2020-06-27 Araki Ken * vt_screen.c: vt_screen_search_find() considers PICTURE_CHARSET. * ui_screen.c: copymode_key() calls ui_xic_set_spot() if ui_window_update() is called without UPDATE_CURSOR. * ui_display_freebsd.c: Key code 28 is always converted to XK_Return. 2020-06-24 Araki Ken * man/mlterm.1, README.ja, etc/key: Updated. * ui_screen.c: - 'int *row' is added to arguments of bs_scroll_{up|down}ward_to_mark(). - SET_MARK shortcut key is supported. * ui_shortcut.[ch]: SET_MARK is added. * vt_term.h: 'row' is added to arguments of vt_term_backscroll_{up|down}ward_to_mark(). * vt_screen.[ch]: 'int *row' is added to arguments of vt_screen_backscroll_{up|down}ward_to_mark(). 2020-06-22 Araki Ken * README, README.ja: Updated. * configure.in, baselib/configure.in: --enable-utmp-suid and --with-utmp options are added. * ui_screen.c: Cursor is hidden in editing search text in copy mode. 2020-06-20 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * im_canna.c, im_fcitx.c, im_ibus.c, im_iiimf.c, im_scim_mod_if.c, im_uim.c, im_wnn.c: - parser->init before im_convert_encoding() is removed. - Character encoding conversion before im.listener->write_to_term() is removed. * im_iiimf.[ch], im_iiimf_aux.c: - PARSER_INIT_WITH_BOM() is removed. - If WORDS_BIGENDIAN is not defined, ef_utf16le_parser_new() is called instead of ef_utf16_parser_new(). - Character encoding conversion before im.listener->write_to_term() is removed. - Infinite loop in aux_quit() is fixed. * im_kbd.c: - Character encoding conversion before im.listener->write_to_term() is removed. - kbd->conv is removed. * im_m17nlib.c: m17nlib->conv is removed. * ef_str_parser.[ch]: ef_str_parser_init() -> ef_str_parser_get() * im_skk.c: Character encoding conversion before im.listener->write_to_term() is removed. * im_common.h: im_convert_encoding() calls parser->init(). * ui_im.h: 'ef_parser_t*' is added to arguments of ui_im_event_listener::write_to_term(). * ui_screen.c: - calculate_vtchars_width() is added to determine the current position in editing search text for get_spot_intern() and draw_preedit_str(). - copymode_xxx members of ui_screen_t are collected to ui_copymode_t and related code is moved to ui_copymode.[ch]. - 'update' argument which specifies whether to call ui_window_update() internally is added to arguments of bs_scroll_*(). - The key to stop selection in copymode is changed from Control+x to any other keys. * ui_copymode.[ch]: Added. * ui_layout.c: The return value of screen_scroll_* functions is changed from int to void. * ui_window_cairo.c: Undefined symbol 'flush_glyphs' on cairo 1.8.0 or before is fixed. 2020-06-13 Araki Ken * man/mlterm.1, README.ja, doc/en/PROTOCOL: Updated. * MLPreferenceActivity.java: "Scroll by Shift+Up or Shift+Down" is dropped. * mlcofig/main.c, mc_flags.[ch]: MC_FLAG_EXTSCROLLSHORTCUT is dropped. * ui_main_config.[ch]: "use_extended_scroll_shortcut" / -q option is dropped. * ui_shortcut.[ch], ui_screen.[ch], ui_screen_manager.c, vte.c: - SCROLL_DOWN and PAGE_DOWN shortcut keys are dropped. - "use_extended_scroll_shortcut" is removed from get_config_intern() and "ui_screen_set_config(). - use_extended_scroll_shortcut is removed from arguments of ui_screen_new(). 2020-06-09 Araki Ken * README.ja, man/mlterm.1: Updated. * ui_screen.[ch]: - If screen->copymode_enabled is true, draw_cursor() ignores vt_term_is_visible_cursor(). - If vt_line_t::mark is true, redraw_screen() draws mark before the beginning of a line. - redraw_screen() draws pattern text to be searched for in copy mode. - bs_scroll_*() doesn't call ui_window_update() in copy mode. - bs_scroll_{up|down}ward_to_mark() are added. - SCROLL_{UP|DOWN}_TO_MARK shortcuts are supported. - copymode_pattern, copymode_pattern_pos and copymode_pattern_editing are added to members of ui_screen_t. - '/' key in copymode enables searching specified text in the screen and backlog. * ui_shortcut.[ch]: - SCROLL_{UP|DOWN}_TO_MASK shortcuts are added. - The default key of COPY_MODE shortcut is changed from Control+Return to Control+Shift+Return. * win32/ui_window.c: Control+Shift+Key works. * vt_term.h: vt_term_backscroll_{up|down}ward_to_mark() are added. * vt_screen.[ch]: - vt_screen_backscroll_{up|down}ward_to_mark() are added. - 'char_index' and 'row' are added to arguments of vt_screen_search_init(). * vt_parser.c: OSC 1337;SetMark ST is supported. * vt_line.[ch]: mark is added to members of vt_line_t. 2020-06-05 Araki Ken * etc/key, doc/ja/README.ja: Updated. * ui_screen.[ch]: - copymode_enabled, copymode_cursor_char_index and copymode_cursor_row are added to ui_screen_t. - draw_cursor() draws copy mode cursor and unhighlight_cursor() hides copy mode cursor if screen->copymode_enabled is true. - copymode_{start|key|move_vertical}() are added. * ui_shortcut.[ch]: COPY_MODE whose default shortcut is Control+Return is added. 2020-05-24 Araki Ken * man/mlterm.1, README.ja, etc/main, etc/main.ja: Updated. * test.c: test() calls TEST_ui_emoji(). * vt_parser.c: put_char() supports emoji modifier fitzpatric type 1-6 (U+1F3FB-1F3FF) * vt_line.[ch]: vt_line_clear_picture() is added. * ui_screen.c: - "emoji_file_format" is added to get_config_intern() and ui_screen_set_config(). - xterm_get_emoji_data() calls vt_char_set_picture_id() instead of vt_char_combine_picture if ch1 has already had a picture id. (For emoji modifier fitzpatric type 1-6) * ui_picture.h: INLINE_AVAIL_ROWS is changed from -MAX_INLINE_PICTURES * 2 to -MAX_INLINE_PICTURES. * ui_picture.c: ensure_inline_pictures() clears inline pictures in the backscroll log if num_inline_pics >= MAX_INLINE_PICTURES after cleanup_inline_pictures(). * ui_main_config.c: --emojifmt / emoji_file_format option is added. * ui_emoji.[ch]: - ui_emoji_{set|get}_file_format() and TEST_ui_emoji() is added. - 'check_exist' is added to arguments of ui_emoji_get_path(). * main.c: setenv("MSYS", "disable_pcon"). 2020-05-17 Araki Ken * ui_picture.c: If the value of "separate_wall_picture" option is "true", a wall picture is not resized to the window size but to the display size on x68k. 2020-05-17 Araki Ken * ui_picture.c: ui_get_inline_picture() checks whether pixmap == None or not. 2020-05-17 Araki Ken * README.ja: Updated. * ui_draw_str.c: Hack to avoid http://twitter.com/isaki68k/status/1259110003874488326 is added. * main.c: setenv("CYGWIN", "disable_pcon") on cygwin to disable pseudo console support introduced since cygwin 3.1.0. * ui_picture.[ch]: - cleanup_inline_pictures() is tuned. - weighting is removed from ui_inline_picture_t. * ui_screen.c: vt_term_get_num_logged_lines() is not called before vt_term_get_line() in line_scrolled_out(). * ui_screen_manager.c: DISPLAY and WINDOWID environmental variables are set only if USE_XLIB is defined. 2020-05-04 Araki Ken * URL is changed from bitbucket to github. * bitbucket-pipelines.yml: Removed. * .gitignore: Added. * version.h: 3.9.0 -> 3.9.0post 2020-04-26 Araki Ken * 3.9.0 released. (tag "rel-3_9_0") * configure.in, mlterm.spec, main/version.h.in, mlterm.c, android/jni/version.h: updated for 3.9.0. * README, doc/en/PROTOCOL, gtk/README: Updated. 2020-04-26 Araki Ken * vtemu/Makefile.in: mkdir -p $(LIBDIR)/mlterm * Makefile.in: 'distclean' target executes 'rm -rf gui'. 2020-04-25 Araki Ken * vtemu/Makefile.in: @LPOBL@ is linked to libzmodem.la * c_sixel.c: Compiling error by g++ is fixed. * zmodem.c: basename() -> bl_basename() * README.fb: Updated. * vt_parser.c: Minor fix. 2020-04-25 Araki Ken * configure.in, ui_display_x68kgrf.c: If --with-gui=x68kgrf is specified, ui_display_x68kgrf.c includes uitoolkit/fb/grfioctl.h instead of . * uitoolkit/fb/grfioctl.h: Added. 2020-04-23 Araki Ken * configure.in, main/Makefile.in: "wscons" (NetBSD/wscons framebuffer), "x68kgrf" (NetBSD/x68kgrf framebuffer) and "scpc98" (FreeBSD/pc98 framebuffer) are added to --with-gui option. 2020-04-22 Araki Ken * fb/ui_window.c: ui_window_get_str() doesn't regard event->ksym which is >= 0x100 as UCS on SDL2. 2020-04-19 Araki Ken * vte.c: - vte_terminal_match_remove_all() is implemented. - vte_terminal_finalize() calls vte_terminal_match_remove_all() - vte_terminal_match_add_{g}regex() keeps regex in PVT(terminal)->match_{g|v}regexes and {g|vte}_regex_ref(regex). - vte_get_encodings() and vte_get_encoding_supported() symbols are added. 2020-04-18 Araki Ken * vte.c: VTE_COMPILATION is defined. 2020-04-17 Araki Ken * wayland/ui_display.c: add_root_to_display() is fixed not to destroy disp->roots[0] and disp->num_roots. 2020-04-12 Araki Ken * im_ibus.c: IBUS_ID is removed from event sources. (I forgot to remove '#ifndef USE_WAYLAND' in remove_event_source() in revision 2742.) 2020-04-12 Araki Ken * gtk/README: Updated. * vte_xlib.c: If GdkDeviceManager is created with XInput2, warning message is output to ~/.mlterm/msg.log. * configure.in: "-m 2755 -g utmp" and "-m 4755 -o root" are not set to INSTALL_OPT on MacOSX/Quartz. * bl_utmp_sysv.c: /dev/ttys00N is supported. * baselib/configure.in: setut{x}ent() is preferred to utemper. 2020-03-30 Araki Ken * mc_io.c: Function declarations are renamed as follows. mc_{set|get}_color_name_{file|pty}() -> mc_{set|get}_color_rgb_{file|pty}() 2020-03-29 Araki Ken * c_sixel.c: - Both SIXEL_SHAREPALETTE and SIXEL_ORMODE are defined, don't remove 'p++' at the end of load_sixel_from_data(). - for (x < rep) -> do .. while (x < rep) 2020-03-26 Araki Ken * vt_term.c: Missing '}' is fixed. * vt_parser.[ch]: The return value of vt_parser_write() is changed from int to size_t. * ui_display_linux.c: Compiling error in no KT_DEAD2 macro definition is fixed. * c_sixel.c: SIXEL_ORMODE is defined. 2020-03-15 Araki Ken * win32/ui.h, win32/ui_xic.c: XK_Prior - XK_Help and XK_KP_0 = VK_XXX + 0xff00. * vt_parser.c: alloca(10) -> buf[10] * ui_screen.c, MLTrem.java: If ksym is 0, vt_term_write_modified_key() is not called. 2020-03-14 Araki Ken * ui_draw_str.c: If CLIP_LINE is defined and top_margin < 0, ui_draw_str() and ui_draw_str_to_eol() calls cairo_{set|unser}_clip(). * libtype/ui_window_cairo.c: cairo_{set|unset}_clip() calls flush_glyphs() in order to apply clipping region. 2020-03-08 Araki Ken * fb/ui.h: Compiling error on FreeBSD is fixed. 2020-03-07 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/ui_window.c: - ui_window_get_str() supports unicode on FreeBSD. - ModMask is cleared if keyboard input is unicode. * ui_display_linux.c: - The type of diacrs_uc and diacrs is changed to pointer. - load_diacr() is integrated to get_accented_char(). - ModMask is not cleared if kb_value doesn't change in either kb_table = K_ALTTAB or kb_table = 0. * ui_display_freebsd.c: Dead key is processed to input accented characters etc from keyboard. 2020-03-04 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * ui_display_wscons.c: Dead key is processed to input accented characters etc from keyboard. * wskbdutil.c: Added. 2020-03-01 Araki Ken * ef_ucs_property.table: Updated to Unicode 12.1.0 (UnicodeData.txt and EastAsianWidth.txt) * config.sub, config.guess: Updated. 2020-03-01 Araki Ken * xlib/ui_imagelib.c: load_sixel() supports 8-bit depth, it enables you to show sixel on 8-bit depth without mlimgloader. * gdk-pixbuf.c: pixbuf_to_pixmap_pseudocolor() is fixed to dither the last 1 pixel of each line properly. 2020-02-29 Araki Ken * vt_parser.c: (void*) + num * sizeof(vt_macro_t) -> (vt_macro_t*) + num * xlib/ui_window.c, vt_term.c: ui_window_xft_draw_string32() and vt_term_enter_backscroll_mode() returns nothing. * ui_imagelib.h: Ternary operator is removed from ui_destroy_mask() macro because it causes compiling error on OpenServer 6.0.0. * encodefilter/module/Makefile.in, main/Makefile.in, uitoolkit/Makefile.in: Tab and backslash characters which can stops 'make' command unexpectedly are removed. * bl_mem.c: If CONCATABLE_FUNCTION is not defined, #define __FUNCTION__ "". * baselib/configure.in, bl_config.h.in, bl_types.h: Not only but also is checked. (for OpenServer 6.0.0) 2020-02-28 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * ui_selection.c: changeset 3055 is partially wrong and reverted. 2020-02-27 Araki Ken * ui_display_linux.c: ioctl(KDGKBDIACRUC) or ioctl(KDGKBDIACR) is used for get_accented_char(). * fb/ui_window.c: '*keysym -= 0x1000' for unicode characters are removed. * aclocal.m4, configure: 'rm -f' check is removed for old machines such as FreeBSD 2.x or before. * zmodem.c: <>pobl/bl_path.h> is included instead of 2020-02-24 Araki Ken * vt_parser.[ch]: The type of vtmode_flags and saved_vtmode_flags is changed from u_int64_t to u_int32_t[2]. 2020-02-24 Araki Ken * ui_im_candidate_screen.c: index &= 0xFF -> index &= 0xFFFF in set_candidate() * im_uim.c: Not only if index % uim->cand_limit == 0 but also if index % uim->cand_limit == uim->cand_limit - 1, candidate_activate() is called. 2020-02-23 Araki Ken * vt_cursor.c: vt_cursor_left_chars_in_line_are_cleared() and vt_cursor_char_is_cleared() checks if cursor->char_index or cursor->col is less than cursor->model->num_cols. 2020-02-22 Araki Ken * vt_pty.[ch]: vt_pty_set_hook() and vt_pty_hook_t are removed. * vt_term.[ch]: 'use_local_echo' is removed from vt_term_t. * vt_parser.[ch]: - is_app_cursor_keys, is_app_escape, keep_screen_on_deccolm, cursor_to_right_of_sixel, allow_deccolm, auto_cr and bold_affects_bg are removed from vt_parser_t. (vtmode_flags is used instead.) - write_to_pty_nohook() is removed. - vt_parser_write() is added. - vt_parser_write() and vt_parser_write_{modified|special}_key() call write_loopback() if SRM is set. - vt_parser_local_echo() -> local_echo() - 'use_local_echo' is added to arguments of vt_parser_new(). - vt_parser_is_transferring_data() is removed. 2020-02-20 Araki Ken * vt_parser.c: - write_to_pty_nohook() is added. - Response sequence of mlterm is sent to a console application by write_to_pty_nohook() instead of vt_write_to_pty(). * fb/ui_display_linux.c, fb/ui_window.c: Inputting accented character with the use of AltGr key is available. * wayland/ui_display.c: Warning message in ui_display_move() is not output everytime but output only once. 2020-02-16 Araki Ken * ui_display.c: xsel_offer, shm, xsel_device and xsel_device_manager are destroyed on exit. 2020-02-15 Araki Ken * ui.h, ui_display.c: WLR_SHELL_V1 is removed. * wlr-layer-shell-unstable-v1-client-protocol.[ch]: Removed. 2020-02-15 Araki Ken * gtk/Makefile.in: xdg-shell-client-protocol.o is excluded from linked objects. * ui.h, ui_display.c: xdg-shell and wlr-layer-shell are supported. * xdg-shell-client-protocol.[ch], wlr-layer-shell-unstable-v1-client-protocol.[ch]: Added. * ui_selection.[ch], ui_screen.c: - ui_start_selection() and ui_sel_line_scrolled_out() don't return anything. - update_sel_region() returns 1 only if the color of selected region is reversed or restored. - ui_{restore|reverse}_selected_region_color_except_logs() returns 0 (not redrawing) instead of 1 if sel->end_row < 0. * sdl2/ui_display.c: SDL_DestroyRenderer() is called before SDL_DestroyWindow() not after it. 2020-02-11 Araki Ken * hb.c, otf.c: hb_font_t / OTF is cached. * libotl/Makefile.in: CFLAGS_beos = @FONTCONFIG_CFLAGS@ and LIBS_beos = @FONTCONFIG_LIBS@ * beos/ui_font.c: ui_font_has_ot_layout_table() always returns 0 because HaikuOS doesn't provide API to show characters by glyph indeces. * beos.cpp, beos.h: - Declaration of ConnectDialog::Position() is fixed. - MovePenTo(x, y) is changed to MovePenTo(x, y + 1) in drawing text. - beos_get_font_path() -> beos_get_font_family() * main/Makefile.in: g++ is used to link mlterm on HaikuOS. 2020-02-09 Araki Ken * beos.cpp, beos.h: 'int geom_hint' is added to argument of window_alloc(), and if geom_hint has XValue or YValue, x or y argument is applied to the new window. 2020-02-06 Araki Ken * vt_parser.c: - The response of Primary DA is changed as follows. \x1b[?63;1;2;3;4;7;29c -> \x1b[?63;1;2;3;4;6;7;15;18;22;29c - DEC_TECHNICAL characters are converted to UCS4. * ef_charset.h: IS_JIS_EXT() is added. * vt_char_encoding.[ch]: vt_convert_dectech_to_ucs() is added. * ui_window_cairo.c: The number of characters passing to draw_string32() is fixed. 2020-02-01 Araki Ken * sdl2/ui_display.c: - MONITOR_PTY is always defined if USE_LIBSSH2 is defined. - monitor_ptys() calls select() at 0.5 second intervals. 2020-02-01 Araki Ken * xlib/ui_window.c: Memory leak in ui_window_send_selection() is fixed. * xlib/ui_imagelib.c: Minor fixes for debug mode. * ui_im_{candidate|status}_screen.c: - #ifdef condition is fixed for SDL2. - If display->resizing is true, draw_screen() does nothing. * sdl2/ui_dislay.c: init_display() supports input method window. 2020-01-29 Araki Ken * libptyssh/vt_pty_ssh.c: ssh_connect() calls mkdir("~/.ssh") to save to ~/.mlterm/known_hosts. * ui_screen.c: set_xdnd_config() calls vt_set_use_scp_full(-1) for "scp" command. * vt_parser.c: vt_set_use_scp_full(-1) sets use_scp_full = true temporarily. * vt_pty_ssh.c: vt_pty_is_loopback() is replaced by vt_config_menu_is_active() in vt_pty_ssh_scp(). * vt_config_menu.h: vt_config_menu_is_active() is added. * beos.cpp: - MLView::MouseMoved() saves the current "modifiers" if 'dragMessage' argument is not null. - MLView::MessageReceived() supports SCP by Shift+DnD. * mc_io.c, mc_io_file.c: vt_get_color_rgb() supports "lightgray" and "gray". 2020-01-26 Araki Ken * mc_io.[ch], mc_io_{file|pty}.[ch]: - FD_SET() is called in mc_io_is_file(). - mc_{set|get}_color_name() => mc_{set|get}_color_rgb() - mc_get_color_name_file() returns a value whose format is "#RRGGBB" with the use of normalize_rgb(). 2020-01-26 Araki Ken * mc_io_file.c: - open_conf() checks MLTERM_CONFIG_DIR environmental variable. - mc_{set|get}_font_name_file() and mc_{set|get}_color_name_file() use open_conf(). * bl_conf_io.c: bl_conf_write_close() writes data only if conf->num > 0. 2020-01-25 Araki Ken * mlconfig/main.c: If mlconfig start without options or with --file option, it configures files in ~/.mlterm directly. * mc_io.[ch]: mc_io_is_pty() -> mc_io_is_file(). mc_io_set_use_file() is added. * ui_layout.c: window_exposed() uses ui_layout_t.window.fg_color instead of ui_layout_t.term.screen.window.fg_color 2020-01-24 Araki Ken * mc_color.c: Color names like "white", "back" and so on are converted to RGB in mc_color_config_widget_new(). * mlconfig/main.c: "Apply&Exit" and "Apply" buttons are hidden if mc_io_is_pty() is false. * mlconfig/Makefile.in: mc_io_file.o and mc_io_pty.o are added to OBJ. * mc_io_file.c, mc_io_pty.c: Added. * mc_io.[ch]; - mc_io_is_pty() is added. - Functions of mc_io_file.c and those of mc_io_pty.c are switched according to the result of mc_io_is_pty(). * README.ja, doc/en/PROTOCOL, gtk/README: Updated. * mlcc/main.c, w3mmlconfig/section/appearance: "screen_height_ratio" is removed. * bl_str.[ch]: bl_str_tabify() is enclosed by #ifndef REMOVE_FUNCS_MLTERM_UNUSE. * bl_conf_io.[ch]: bl_fopen_with_mkdir() is not called from bl_conf_write_open() but from bl_conf_write_close(). 2020-01-19 Araki Ken * fb/ui_font.c: xfont->ascent is modified. (for Pragmata Pro Mono) 2020-01-19 Araki Ken * vte.c, vtetypebuiltins.c, test.c, ui_scrollbar.c, win32/ui.h, xlib/ui_dnd.c, xlib/ui_window.c, vt_iscii.c, vt_char.h: Tab -> 2 spaces. * fb/ui_font.c: - FONTSIZE_IN_FORMAT() macro is added. - FONTSIZE_IN_FORMAT(font->xfont->format) is passed to otl_convert_text_to_glyphs(). 2020-01-18 Araki Ken * im_canna.c, ui_window_cairo.c: https://sourceforge.net/p/mlterm/bugs/78/ is merged. * beos/ui.h, beos/ui_font.c: 'unsigned int size' is added to XFontStruct. * libotl/Makefile.in: 'TARGET_beos = libotl.la' is added. * mlclient/main.c: https://sourceforge.net/p/mlterm/patches/25/attachment/typos.diff is merged. 2020-01-18 Araki Ken * uniscribe.o: - Tab -> 2 spaces. - glyphs = alloca(sizeof(WORD) * src_len) -> alloca(sizeof(WORD) * num_shape_glyphs) - if (num_filled_glyphs + range[0] <= num_shape_glyphs) -> if (num_filled_glyphs + range[0] > num_shape_glyphs) * vt_ot_layout.c: vt_ot_layout_copy() which unexpectedly didn't set dst->num_glyphs is fixed. 2020-01-13 Araki Ken * vt_parser.c: 'buf' is declared at the beginning of the function in vt_parser_write_modified_key(). 2020-01-13 Araki Ken * vt_line.c: Compiling error in the case of disabling OpenType Layout is fixed. 2020-01-13 Araki Ken * configure.in: uniscrible.o is preferred to otf.o on win32. * ui_window_cairo.c, ui_window_xft.c, win32/ui_window.c: Trailing spaces aren't removed in drawing text if use_ot_layout is true. 2020-01-13 Araki Ken * configure.in: If harfbuzz is not found on win32, OT_LAYOUT_OBJ=uniscribe.o * libotl/uniscribe.c: Added. * */ui_font.c, ui_font.h: - 'int is_awidth' is added to arguments of ui_calculate_char_width(). - 'int8_t *yoffsets' is added to arguments of ui_convert_text_to_glyphs(). * win32/ui_font.c: ui_font_has_ot_layout_table() doesn't call GetFontData() but delegates it to libotl. * libotl/hb.c, libotl/otf.c, libotl/otl.h: - 'int8_t *yoffsets' is added to arguments of otl_convert_text_to_glyphs(). - 'obj' argument of otl_open() is changed from font data to HDC on win32. * ui_draw_str.c: - fc_draw_combining_chars() and xcore_draw_combining_chars() considers vt_char_get_yoffset(). - ui_draw_str_to_eol() clears background before drawing text in TYPE_XCORE. * vt_char.[ch]: - 'attr' bits are changed. - 'is_awidth' is added to arguments of vt_char_set() and vt_char_combine(). - vt_char_is_awidth() is added. - vt_char_get_offset() is renamed to vt_char_get_xoffset(). - vt_char_get_width() is renamed to vt_char_get_advance(). - vt_char_get_yoffset() is added. - 'yoffset' is added to arguments of vt_char_set_position(). * vt_screen.[ch]: - 'is_awidth' is added to arguments of vt_screen_combine_with_prev_char(). - vt_screen_write_content() uses vt_str_new() instead of vt_str_alloca() because log size might be too huge to succeed vt_str_alloca(). - vt_screen_write_content() calls vt_str_destroy(). - report_mouse_tracking() calls vt_line_convert_visual_char_index_to_logical() if vt_line_is_using_ctl() is true. * vt_line.c: - If vt_ot_layout() <= 0 and complex_shape or has_var_width_char was true, the line is redrawn completely. - vt_line_convert_visual_char_index_to_logical() supports ISCII and OpenType Layout. * vt_logs.[ch]: vt_unlimit_log_size() calls vt_change_log_size() because (logs)->unlimit = 1 after vt_change_log_size(0) didn't work. * vt_shape.[ch]: vt_shape_ot_layout() uses cached glyph info which vt_ot_layout stores. * vt_ot_layout.[ch]: - glyphs, xoffsets, yoffsets, advances and num_glyphs which store the result of shape_func are added. - The number of calling vt_ot_layout_shape() is decreased. - OTL_IS_COMB() is added to determine whether shaped glyph should be combined or not. * vt_term.c: #ifdef USE_HARFBUZZ => #if defined(USE_HARFBUZZ) || defined(USE_UNISCRIBE) * vt_functbl_iscii.c, vt_line_iscii.[ch], vt_ctl_loader.h: vt_line_iscii_convert_visual_char_index_to_logical() is added. 2019-12-07 Araki Ken * ui_main_config.c: Configuring bl_color and co_color is fixed. 2019-12-01 Araki Ken * vt_parser.c: Not only "CSI>4;2m" but also "CSI>4;1m" (modifyOtherKeys) is supported. * version.h: 3.8.9 -> 3.8.9post 2019-11-22 Araki Ken * 3.8.9 released. (tag "rel-3_8_9") * configure.in, mlterm.spec, main/version.h.in, mlterm.c, android/jni/version.h: updated for 3.8.9. * README, doc/en/PROTOCOL, man/mlterm.1, man/mlclient.1, README.win32, README.ja, etc/main, etc/main.ja: Updated. 2019-11-17 Araki Ken * README, README.ja, README.fb, doc/ja/README.ssh: Updated. * test.c: TEST_sixel_realloc_pixels() is added. * c_sixel.c: - realloc_pixels_intern() is fixed. - TEST_sixel_realloc_pixels() is added. 2019-11-16 Araki Ken * zmodem.c: Compiling error on FreeBSD/pc98 is fixed. 2019-11-14 Araki Ken * ui_screen_manager.c: open_pty_intern() doesn't return 0 if the connection dialog is cancelled on haiku. 2019-11-11 Araki Ken * cocoa.m: EBADF of select() is ignored because vt_pty_{ssh|mosh}_set_use_loopback() can cause it even if it's normal. * Android.mk: uitoolkit/test.c is added to LOCAL_SRC_FILES. 2019-11-09 Araki Ken * xlib/ui_dnd.c: TEST_dnd() outputs "PASS X DnD test". * ui_screen.c: "test" is added to OSC 5379 if BL_DEBUG is defined. * test.c: Added. * win32/ui.c: - The order of keysym_table is fixed. - main() -> TEST_xstringtokeysym(). * ui_font_config.c: - TEST_font_config() -> TEST_ui_font_config() - ui_acquire_font_config() never calls BL_TESTIT_ONCE(). * bl_path.c: main() -> TEST_bl_path(). * bl_map.c: main() -> TEST_bl_map(). * bl_args.c: main() -> TEST_bl_args(). 2019-11-04 Araki Ken * libptyssh/vt_pty_ssh.c: write() => send() on win32. 2019-11-03 Araki Ken * doc/en/README.transfer: Added. * doc/en/PROTOCOL: Updated. * MLActivity.java: "Start zmodem" and "Reset terminal" are added to the menu. * mlterm-menu/menu, mlmenu/menu-simple: "Zmodem" is added. * ui_main_config.c: --recvdir / "receive_directory" option is added. * ui_screen.c: If 'rz' command is executed on a remote host, Shift+DnD invokes "zmodem_start" command instead of "scp". * ui_screen.c, ui_shortcut.[ch]: "RESET" shortcut key is added. * ui_dnd.c: Shift+DnD forces "scp" command instead of pasting a file path even if its property is not "text/uri-list". * vt_parser.[ch]: - If \x18B01 is received, vt_parser_t::is_zmodem_ready flag is set. - "Send ..." or "Save in ..." message is output in starting zmodem. - "recv_dir" => "receive_directory" (OSC 5380) - The default "receive_directory" is changed from ~/.mlterm to ~/.mlterm/recv. - "send_file_utf8" is added to OSC 5379 for internal use. - "recv_dir" is removed from OSC 5379. - "zmodem_start" works only if vt_pty_is_loopback() is false. - vt_parser_reset() and vt_parser_has_pending_sequence() are added. - vt_reset_pending_vt100_sequence() is removed. * vt_pty_ssh.c, vt_pty.h: - The default directory where received files via scp are saved is changed from ~/.mlterm/scp to ~/.mlterm/recv. - recv_dir and progress_len are added to arguments of vt_pty_ssh_scp(). * libptyssh/vt_pty_ssh.c: - write(pty->slave) (write_loopback()) is called instead of vt_write_to_pty() to output message directly to the screen. - libssh2_scp_recv2() is used instead of libssh2_scp_recv(). - scp_thread() sets ssh_session_t::suspended = 2. * vt_pty_mosh.cpp: Text output from mlconfig or mlterm-menu etc when it dies is stored. * vt_transfer.c: mkdir(savedir) * gtk/vte.c: vte_terminal_{set|get}_enable_bidi() and vte_terminal_{set|get}_enable_shaping() (which are since 0.58) are added. * bl_config.h.in: _FILE_OFFSET_BITS and _LARGE_FILES macros are added. * baselib/configure.in: AC_SYS_LARGEFILE is added. 2019-10-16 Araki Ken * ui_screen.[ch], ui_screen_manager.c: Fixes for the change of ui_layout_resize(). * ui_layout.[ch]: size_str whose values are N, +N, -N or N% is added to arguments of ui_layout_resize(). 2019-10-14 Araki Ken * vt_transfer.c: Fix for android. * ui_font.c: Fix for win32. 2019-10-13 Araki Ken * vt_screen.c: vt_screen_resize() sets modified flag to lines reverted from backlog to the main screen. 2019-10-13 Araki Ken * vt_screen.c: 'pack' is added to arguments of vt_screen_resize(). * vt_logs.h: vt_log_rollback_index() is added. * ui_screen.c: ui_screen_scroll_event_listener_t::term_changed() is called if vt_term_resize() returns 2. * baselib/src/Makefile.in: MAJOR.MINOR 2.0 -> 2.1 * bl_cycle_index.[ch]: bl_cycle_index_rollback() is added. 2019-10-12 Araki Ken * wayland/ui_display.c: - If kbd_repeat_N is 0, prev_kev.type = 0 and kbd_repeat_wait = 0. - If kbd_repeat_N is less than KEY_REPEAT_UNIT / 2, kbd_repeat_wait = 1. - zxdg_toplevel_v6_set_app_id() is called. 2019-10-11 Araki Ken * c_sixel.c: Illegal copy in the case of new_stride * new_height <= cur_stride * cur_height is fixed. 2019-10-10 Araki Ken * fb/ui_font.c: If face->glyph->bitmap_left is less than 0, bitmap at retreated area is skipped in get_ft_bitmap_intern(). * xlib/ui_window.c: XSizeHints::base_{width|height} is fixed. * */ui_window.c, */ui_display.c: total_{width|height}_inc() => max_{width|height}_inc() * ui_main_config.c: If DISPLAY environment variable doesn't exist, DISPLAY=:0 is set. * main_loop.c: 'mlterm -j genuine' starts if X server is down. * win32/ui.c: XParseGeometry() doesn't change argument variables in error of parsing. 2019-10-06 Araki Ken * wayland/ui.h, wayland/ui_display.c: Whether "text/plain;charset=utf-8" or "UTF8_STRING" is supported or not is checked in data_offer_offer() and xsel_offer_offer(). * wayland/ui_font.c: If the font name contains "bold" or "italic", FT_Outline_Embolden() or FT_Outline_Transform() is not applied. * ui_font_config.c: Warning is output for invalid "DEFAULT_BOLD" etc. 2019-10-05 Araki Ken * wayland/ui_display.c, wayland/ui.h: - xdg_toplevel_close() invokes window_destroyed event. - Primary selection is supported with the use of gtk-primary-selection.[ch]. * wayland/gtk-primary-selection.[ch]: Added 2019-10-01 Araki Ken * wayland/ui_window.c: ui_window_get_str() converts keysym to utf8 string with the use of ui_display_get_utf8(). * wayland/ui_display.[ch]: ui_display_get_char() => ui_display_get_utf8() * ui_font.c: If the width of 'W' glyph is larger than face->max_advance_width, xfont->width_full = the width 'W' glyph. 2019-09-29 Araki Ken * wayland/ui_display.c: Copy&paste from other applications to mlerm-wl works. * wayland/ui_display.c: ui_display_show_root() calls wl_display_dispatch(). (Fix for 1) in https://sourceforge.net/p/mlterm/discussion/130836/thread/bc008c18db/#bb38) * mlconfig/po/Makefile.in: config.status is never called. 2019-09-28 Araki Ken * wayland/ui.h, wayland/ui_display.c: xdg-shell is supported. * xdg-shell-unstable-v6-client-protocol.[ch]: Added. 2019-09-23 Araki Ken * xlib/ui_window.c: class_hint (WM_CLASS property) is passed to XmbSetWMProperties() in ui_window_show(). * vt_pty_mosh.cpp: Pass through sequence state of each Network::Transport is saved in pass_seq_t. 2019-09-23 Araki Ken * xlib/ui_window.c: _NET_WM_PID is set. (https://sourceforge.net/p/mlterm/patches/24/) * zmodem.c: q_screen_dirty is removed. 2019-09-22 Araki Ken * ui_display_wscons.c: (fboffset + 0x40000) * _disp.depth => fboffset + 0x40000 * _disp.depth 2019-09-21 Araki Ken * ui_im_candidate_screen.c: ui_im_candidate_t::filled_len = 0 in case it is not 0. 2019-09-19 Araki Ken * doc/en/PROTOCOL: Updated. * win32/ui_xic.c: Ctrl-^ is converted to 0x1e instead of 0x1d. * vt_parser.c: "zmodem_send" and "zmodem_recv" are integrated to "zmodem_start" and "zmodem_cancel" is added in vt_parser_exec_cmd(). * vt_transfer.[ch]: vt_transfer_cancel() is added. * zmodem.[ch]: zmodem_cancel() is added. * vt_pty_mosh.cpp: - Only zmodem packets are transferred via tcp connection. - If MOSH_NO_TCP environmental variable is set, tcp connection is disabled. - Ctrl-^ commands (Ctrl-. (quit) and Ctrl-, (reset)) are supported. 2019-09-01 Araki Ken * gdiplus.cpp: Uninitialized memory access in gdiplus.cpp is fixed. 2019-09-01 Araki Ken * vt_pty_mosh.cpp: Pass through sequence via tcp connection is supported. * vt_parser.c: Minor improvement. * configure.in: Script to replace @UTMP_CFLAGS@ and @INSTALL_OPT@ is added to config.status. 2019-06-09 Araki Ken * ui_main_config.c: --sr / scroll_on_resizing option is added. * vt_edit.[ch]: vt_set_scroll_on_resizing() is added. * vt_model.c: vt_model_resize() sets vt_line_t::is_modified = 2. 2019-06-08 Araki Ken * vt_parser.c: The length of progress bar of transferring data via zmodem is vt_screen_get_cols() / 2 + 1. * zmodem.[ch]: - 'progress_len' is added to arguments of zmodem_start(). - 'progress' argument of zmodem_is_processing() is changed to 'progress_cur' and 'progress_len'. * vt_transfer.[ch]: - 'progress_len' is added to arguments of vt_transfer_start(). - 'progress' argument of vt_transfer_get_state() is changed to 'progress_cur' and 'progress_len'. 2019-06-08 Araki Ken * doc/en/PROTOCOL: Updated. * android/jni/ui_event_source.c, gtk/vte.c, java/MLTermPty.c, ui_event_source-cocoa.m: Seding data via zmodem is supported. * ui_event_source.c: - Lock is added for HaikuOS. - Sending data via zmodem is improved. * vt_term.[ch]: - vt_term_write() does nothing if vt_parser_is_transferring_data() is true. - vt_term_transfer_data() is removed. - vt_term_is_sending_data() is added. * vt_parser.[ch]: - vt_parser_transfer_data() is removed. - vt_parser_is_sending_data() and vt_parser_is_transferring_data() are added. * vt_transfer.[ch]: - NO_DYNAMIC_LOAD_TRANFER macro is added. - vt_transfer_is_processing() -> vt_transfer_get_state() * zmodem.c: Win32 is supported. * sdl2/ui_display.c: The returned value of init_display() is checked in ui_display_show_root(). * ui_main_config.c: Invalidation of --mdi=false option is fixed. 2019-05-26 Araki Ken * vt_pty_mosh.cpp: CSI?8800h is output only if pass_seq_get() returns "\x1bP..." sequence. * ui_event_source.c: receive_next_event() calls vt_term_transfer_data() in select(2) loop. * vtemu/Makefile.in: - vt_transfer.o is added to OBJ. - libzmodem.la is built from zmodem.c * vt_term.h: vt_term_transfer_data() is added. * vt_parser.c: - zmodem is supported. - vt_parser_transfer_data() is added. * vt_transfer.[ch], zmodem.[ch]: Added. 2019-04-27 Araki Ken * tool/servman/main.c: Compiling error is fixed. 2019-04-27 Araki Ken * man/mlterm.1: Updated. * ui_font_manager.c: The default value of max_font_size is changed from 100 to 10000. * vt_pty_mosh.cpp: - sixel_get_drcs() => pass_seq_get() - sixel_reset_drcs() => pass_seq_reset() 2019-04-21 Araki Ken * MLTermPty.java, MLTermPty.c: waitForReading() returns 0, 1, or -1 instead of JNI_TRUE or JNI_FALSE. * MLTermPty.c: vt_term_manager apis are enclosed by pthread_mutex_{un}lock(). * java/Makefile.in: mlterm.o is compiled before compiling MLTermPty.so. 2019-04-20 Araki Ken * xlib/ui_display.c: Not only "nil2" font but also "fixed" is loaded for XC_nil. * win32/ui_window.c: ui_window_set_cursor() supports XC_nil. 2019-04-19 Araki Ken * ui_screen.[ch]: - key_press() hides pointer, while pointer_motion() shows it. - xterm_hide_cursor() is removed. * vt_term.h: vt_term_get_hide_pointer_mode() is added. * vt_parser.[ch]: - hide_cursor is removed from vt_xterm_event_listener_t. - Ps of "CSI > Ps p" is stored in vt_parser_t::hide_pointer_mode. - vt_parser_get_hide_pointer_mode() is added. 2019-04-16 Araki Ken * README.mosh, README.console, README.win32: Updated. * win32/ui_font.c: ui_font_new() supports UTF8 encoding for 'fontname' argument. * ui_main_config.c: "use_anti_alias" option is revived on win32gdi. * vt_char_encoding.c: The size of msb_set_cs_table[] is shrinked. * ui_font_manager.c: The size of usascii_font_cs_table[] is shrinked. * ef_jis_property.c: The size of jisx0213_2000_1_property_table[] is shrinked. * baselib/configure.in: bl_dlfcn_dl.c instead of bl_dlfcn_win32.c is used by default on msys2. * ui_screen.c: - The returned value of draw_cursor(), flush_scroll_cache(), redraw_screen(), highlight_cursor(), unhighlight_cursor() and set_icon() is changed from int to void. - screen->blink_wait is reset to -1 whenever key_pressed() is called. 2019-04-12 Araki Ken * vt_pty_mosh.cpp: Memory leaks are fixed. * ui_event_source.c: Fix https://sourceforge.net/p/mlterm/mailman/message/36633222/ 2019-04-11 Araki Ken * README.mosh: Updated. * vt_pty_mosh.cpp: - convert_utf8_to_ucs() and convert_ucs_to_utf8() are removed. (moved to https://bitbucket.org/arakiken/mosh/src/tip/src/terminal/parser.cc?at=sixel-winsock) - read_pty() uses sixel_get_drcs(). 2019-04-03 Araki Ken * win32/ui_connect_dialog.c: "Mosh" checkbox of connect dialog is disabled if NO_DYNAMIC_LOAD_SSH is defined. * baselib/configure.in: Check for $host_os = msys is added. * cocoatouch.m: - IS_OPAQUE is always 1. - clearsContextBeforeDrawing = NO. * winrs.rs, servman.rc: The width of buttons of 'Protocol' groupbox is fixed. * version.h: 3.8.8 -> 3.8.8post 2019-03-31 Araki Ken * 3.8.8 released. (tag "rel-3_8_8") * configure.in, mlterm.spec, main/version.h.in, mlterm.c, android/jni/version.h: updated for 3.8.8. * doc/en/PROTOCOL, man/mlterm.1: Updated. 2019-03-31 Araki Ken * gtk/README, libvterm/README: Updated. * vte.c: - vte_terminal_set_colors() resets fg or bg color if 'foreground' or 'background' argument is NULL and palette_size is 0. - vte_set_test_flags(), vte_terminal_get_color_background_for_draw() and vte_regex_substitute() symbols are added. 2019-03-29 Araki Ken * beos.cpp, sdl2/ui_display.c: Wheel mouse is supported. 2019-03-28 Araki Ken * fb/ui_font.c: xfont->height is calculated by face->height instead of face->max_advance_height. * sdl2/ui_display.c: SDL_WINDOWEVENT_EXPOSED is processed. 2019-03-26 Araki Ken * man/mlterm.1, README.ja, etc/main, etc/main.ja: Updated. * ui_font_manager.c: - The default value of min_font_size is changed from 6 to 1. - The default value of max_font_size is changed from 30 to 100. * vt_pty_mosh.cpp: If select() in watch_ptys() fails, loop continues. * ui_event_source.c: Whether errno of select() is EINTR is checked. * ui_event_source-cocoa.m: Whether errno of select() is EAGAIN or EINTR is checked. 2019-03-25 Araki Ken * README.android, README.sdl2, doc/en/README.ssh, doc/ja/README.ssh, README.ja, etc/main, etc/main.ja, man/mlterm.1: Updated. * beos.cpp, sdl2/ui_display.c: Drag&Drop is supported. * cocoa.m: Command+Drag&Drop starts scp. * wayland/ui.h, wayland/ui_display.c: Shift+Drag&Drop start scp. * encodefilter/configure.in, encodefilter/module/Makefile.in: ef_jis_property.lo is forcibly linked to libmef_jajp.so * bl_conf_io.c, im_iiimf_aux.c, daemon.c, vt_termcap.c: The return value of bl_file_get_line() is regarded as NULL-terminated string. * bl_file.[ch]: bl_file_get_line() returns NULL-terminated string. * libctl/vt_iscii.c: ISCII tables except hindi.table are excluded. 2019-03-24 Araki Ken * sdl2/ui_display.c: - KMOD_GUI => CommandMask in get_mod_state(). - SDL_KEYDOWN event in poll_event() calls ui_window_receive_event() if state is CommandMask. * sdl2/ui.h: CommandMask is added. * ui_display_freebsd.c: All 8 bits of keymap.key[code].spcl are checked. * servman/Makefile.in, libotl/Makefile.in, libtype/Makefile.in: INSTALL_OPT is removed. 2019-03-23 Araki Ken * Androkd.mk: Compiling error is fixed. * main.c: main_loop_final() is always called at exit. * bl_config.h.in: '#undef HAVE_STDINT_H' is added. * baselib/configure.in: The existence of stdlib.h is checked. 2019-03-22 Araki Ken * configure.in: @UTMP_CFLAGS@ in vtemu/Makefile.in is replaced. * ui.h, ui_window.c: - UI_RESIZE event type is added. - If UI_RESIZE event is received, clear_margin_area() is called. * beos.cpp: 'width' and 'height' of MLWindow::FrameResized(), MLWindow::ResizeTo() and MLView::ResizeTo() are treated as 'right - left' and 'bottom - top'. 2019-03-21 Araki Ken * sdl2/ui_display.c: Compiling error is fixed. * main-con.c, console/ui_display.c: Whether IMAXBEL is defined or not is checked. * */Makefile.in: -lX11 is removed. * configure.in: - "-lX11" is set to X_LIBS if X is found. - utmp is checked and INSTALL_OPT is set after executing ./configure at subdirs. * c_sixel.c: Segfault in handling errors in load_sixel_from_data() is fixed. 2019-03-20 Araki Ken * ui_window.c: expose() exposes all screen even if win->update_window_flag is 0 and force_expose is 1. * beos.cpp, beos.h: - force_expose is added to arguments of draw_screen(). - force_expose is added to arguments of view_update(). * configure.in: "gui" => "$gui" 2019-03-19 Araki Ken * ui_simple_sb_view.c: Drawing down side shade is fixed. * bl_unistd.c: __bl_setenv() considers 'overwrite' argument. 2019-03-18 Araki Ken * java/Makefile.in: Updated to Java 10 or later. * mlterm.c: Compiling error is fixed. 2019-03-17 Araki Ken * vt_pty_ssh.c: If libssh2_userauth_list() returns NULL but no error happens, authentication is skipped. * README.ja: Updated. * im_iiimf_aux.c: Compiling error is fixed. * bl_util.[ch]: bl_base64_encode() is removed. 2019-03-17 Araki Ken * beos.cpp: Conflicting Control+a with B_HOME etc is fixed. * ui.h: 0xe0000 mask is set for XK_Home etc. * vt_util.[ch]: Removed. * bl_util.c: - Added. - bl_hex_decode(), bl_hex_encode() and bl_base64_decode() are moved from vt_util.[ch]. - bl_hls_to_rgb() is moved from c_sixel.c. ^ bl_rgb_to_hls() is moved from vt_parser.c (rgb_to_hls()). - bl_get_user_name() is added. * bl_config.h.in: '#undef HAVE_GETPWUID' is added. * src/Makefile.in: bl_util.o is added to COMOBJ. * baselib/configure.in: The existence of getpwuid is checked. 2019-03-16 Araki Ken * bl_locale.c, mef.c, im_skk.c, im_wnn.c, mc_font.c, mc_radio.c, ui_font_ft.c, ui_screen.c, ui_shortcut.c, win32/ui_font.c, xlib/ui_font.c, vt_iscii.c, vt_shape_bidi.c, vt_char_encoding.c, vt_termcap.c: Some array declarations are formatted. 2019-03-16 Araki Ken * ui_event_source-cocoa.m: If vt_check_sig_child() returns true, ui_event_source_process() exits on cocoatouch. * vt_term_manager.[ch]: vt_check_sig_child() is compiled if __APPLE__ is defined. * ef_euccn_parser.c: ef_get_ucs_property() is removed. * ef_jis_property.[ch]: 'size' is removed from arguments of ef_get_jisx0208_1983_property() and ef_get_jisx0213_2000_1_property(). * ef_jisx0208_1983_property.[ch], ef_jisx0213_2000_property.[ch] => ef_jis_property.[ch] * ef_ucs4_jisx0213.c: ef_map_ucs4_to_jisx0213_2000_1() calls ef_get_jisx0213_2000_1_property(). * ef_ucs4_jisx0208.c: ef_map_ucs4_to_jisx0208_1983() calls ef_get_jisx0208_1983_property(). * encodefilter/module/Makefile.in: @EF_JIS_PROP_LO@ is added in linking libmef_jajp.la * encodefilter/configure.in: EF_JIS_PROP_LO is defined if $allow_undefined_flag is "unsupported". 2019-03-16 Araki Ken * ui_event_source.c: If vt_check_sig_child() returns true, receive_next_event() exits on Haiku. * vt_term_manager.[ch]: vt_check_sig_child() is added. * beos.cpp: Whether uiwindow is NULL or not is checked in MLView::{Draw|KeyDown|MouseDown|MouseMoved|MouseUp}(). 2019-03-16 Araki Ken * beos.cpp: beos_dialog_{password|okcancel|alert}() are implemented. * vt_pty_ssh.c: Compiling error on Haiku is fixed. 2019-03-14 Araki Ken * beos.cpp: MLView::cur_font, buttons and messenger are initialized. 2019-03-13 Araki Ken * beos.cpp: - MLView::messenger is deleted in set_input_focus(). - Not only MLView::Draw() but also KeyDown(), MouseDown(), MouseMoved() and MouseUp() check ((ui_screen_t*)uiwindow)->term. 2019-03-12 Araki Ken * beos.cpp: BRect::right and BRect::bottom are obtained by subtracting 1 from BRect:left + width and BRect::top + height. * c_sixel.c: Memory allocation is fixed. * ui_im_status_screen.c: "\x1b[?7l" is output to the status line. * ui_event_source.c: additional_fds is processed on SDL2. * beos/ui_imagelib.c: Unused code is removed. * beos.cpp: Segfault by unexpected NULL or non-NULL value of MLView::messenger when a focused view is changed in inputting with ime. 2019-03-10 Araki Ken * beos/ui_imagelib.c: load_file() processes pic_mod. * beos.cpp, beos.h: beos_get_bits() is added. 2019-03-10 Araki Ken * ControlSequences, README.cocoa, README.cocoatouch: Updated. * ui_shortcut.c: The default value of INSERT_SELECTION is changed from Shift+Insert to Command+v on MacOSX and iOS. * vt_parser.c: CSI ? 1010 h, CSI ? 1010 l, CSI ? 1034 h, CSI ? 1034 l, CSI ? 1036 h and CSI ? 1036 l are supported. * quartz/ui_event_source-cocoa.m: Added. * quartz/ui_event_source.c: Removed. * ui_screen.c: preedit() which is set to ui_window_t::preedit is added. * sdl2/ui_display.c: update_ime_text() is moved to preedit() in ui_screen.c. * uitoolkit/Makefile.in: ui_event_source.o is moved from OBJ1 to OBJ2_*, and ui_event_source-cocoa.o is added to OBJ2_quartz. * cocoa.[hm], cocoatouch.m: - update_ime_text() is moved to preedit() in ui_screen.c. - Almost all codes in monitor_pty() is moved to ui_event_source_process(). - cocoa_add_fd() and cocoa_remove_fd() are integrated to ui_event_source_add_fd() and ui_event_source_remove_fd(). * beos.cpp: - update_ime_text() is moved to preedit() in ui_screen.c. - beos_resize_image() is implemented. * */ui.h: UIWINDOW_SUPPORTS_PREEDITING is added. 2019-03-09 Araki Ken * ui_layout.c: term->next[0] and term->next[1] are destroyed before destroying term in window_destroyed_intern(). * ui_event_source.c: beos_lock() and beos_unlock() are called on Haiku. * quartz/ui_window.c: IS_XSCREEN() => IS_UISCREEN() * beos/ui_window.c: window_dealloc() (which exits the current thread and never returns) is placed at the end of ui_window_final(). * beos/ui_display.c: ui_window_final() is moved after updating disp->num_roots and disp->roots. * beos.cpp, beos.h: - B_INPUT_METHOD_EVENT is processed in MLView::MessageReceived(). - beos_lock(), beos_unlock(), view_lock(), view_unlock(), window_lock() and window_unlock() are added. - LockLooperWithTimeout() is replaced by {window|view}_lock() in MLWindow::Foo() and MLView::Bar() - update_ime_text() is added. - window_get_position() is implemented. - window_get_orphan() is added for input method window. - widow_move_resize() is removed and window_move() is added. * ui.h: XIM_SPOT_IS_LINE_TOP is defined. 2019-03-05 Araki Ken * doc/en/README.beos: Added. * configure.in: The value of INSTALL_OPT is always "-m 755" on BeOS (Haiku). * main-beos.cpp: "extern char *global_args" is removed. * beos.cpp: - UI_KEY_FOCUS_IN event is triggered when BView::MakeFocus() is called. - "char *global_args" is removed. * ui_main_config.c: The default value of "use_login_shell" option is changed from 0 to 1 on BeOS (Haiku). * vt_pty.h: OPEN_PTY_ASYNC is always defined on BeOS (Haiku). 2019-03-04 Araki Ken * ui_screen_manager.c: Using uninitialized value is fixed. * ui_event_source.c: vt_get_all_terms() is called every time in select() loop. * ui_imagelib.c: - resize() is replaced by beos_resize_image(). - ui_destroy_image() is implemented. * beos.cpp, beos.h: - view_visual_bell() and beos_load_image() are implemented. - view_destroy_image() and beos_resize_image() are added. * configure.in, main/Makefile.in: BEOS_LIBS is removed. 2019-03-03 Araki Ken * main_loop.c: bl_alloca_garbage_collect() is called at the end of main_loop_final(). * gdiplus.cpp, beos.cpp: alloca() is removed. * vt_str_alloca() => vt_str_alloca() + vt_str_init(). * vt_str.[ch]: __vt_str_init() is removed and vt_str_alloca() doesn't call it. * bl_arg_str_to_array() => bl_argv_alloca() + bl_arg_str_to_array(). * bl_args.[ch]: bl_arg_str_to_array() is separated to bl_argv_alloca() and bl_arg_str_to_array() in order not to use alloca() in arguments of a function. * bl_sig_child.[ch]: bl_sig_child_{init|suspend|resume}() => bl_sig_child_{start|stop}() * bl_conf.[ch]: char* => const char* * bl_def.h: #include to check SIZE_MAX on Haiku R1 Beta1. * bl_str.c: bl_str_dup() => __bl_str_dup() * bl_str_alloca_dup() => alloca() + strcpy() * bl_men.h: bl_str_alloca_dup() is removed. * The return value of some functions is changed from int to void. * ui_screen_manager.c: close_screen() calls close_screen_intern() directly. * beos.cpp, beos.h: - MLView::SetFont() is added. - MLWindow::Quit() is added. - MLWindow::WindowActivated() and MLWindow::FrameResized() use LockLooperWithTimeout() - UnlockLooper(). - view_set_clip(), view_unset_clip(), window_set_title() and beos_beep() are implemented. - view_draw_string() supports font->double_draw_gap. - is_italic and is_bold are added to arguments of beos_create_font(). - beos_font_get_advance() supports characters >= 0x80. * beos/ui_font.c: - ui_font_new() processes size_attr. - ui_calculate_char_width() supports proportional fonts and considers font->is_var_col_width. * beos/ui_window.c: - need_pointer_motion_mask() is removed. - window_dealloc() is placed at the end of ui_window_final() because BWindow::Quit() in window_dealloc() exits the current thread. * beos/ui.h: XFontStruct::bfont is renamed to XFontStruct::fid. * uitoolkit/beos: Added. (The previous commit failed to add it.) 2019-02-23 Araki Ken * uitoolkit/beos: Added. * main/main-beos.cpp: Added. * configure.in: --with-gui=beos is added. * main/Makefile.in, uitoolkit/Makefile.in, skk/Makefile.in, kbd/Makefile.in: *_beos are added. * ui.h: beos is added. * encodefilter/src/Makefile.in: MAJOR is changed from 2 to 3. * baselib/src/Makefile.in: MAJOR is changed from 1 to 2. * baselib/configure.in: The case of "$host_os" = "haiku" is supported. * delete (which is reserved keyword of C++) => destroy * quartz/cocoa.[hm], cocoatouch.m: The returned value of cocoa_clipboard_own() is changed from int to void. 2019-02-17 Araki Ken * xlib/ui_window.c: Segfault in showing an input method window is fixed. 2019-02-09 Araki Ken * man/mlterm.1: Typo is fixed. * wayland/ui_display.c: cache_damage_h() and cache_damage_v() works if rotate_display = right. * sdl2/ui_display.c: ui_window_update_all() is called if SDL_WINDOWEVENT_SIZE_CHANGED is received. 2019-02-04 Araki Ken * ui_draw_str.c: 'vt_char_cols == 0' => vt_char_is_zerowidth(). * vt_char.[ch]: vt_char_is_zerowidth() is added. * vt_line_bidi.c: set_visual_modified() checks visual order properly. * vt_bidi.c: 'bidi_mode = BIDI_ALWAYS_LEFT' instead of 'fri_type == FRIBIDI_TYPE_LTR' for DEC_SPECIAL characters. 2019-01-27 Araki Ken * cocoa.m: CGLayer is used if MacOSX is 10.14 or later. (See http://twitter.com/Cj_bc_sd/status/1088111309223161857) * cocoatouch.m: CGContextSetBlendMode(kCGBlendModeCopy) is added. * lex.split.c: Logging to stdout is removed. * bl_dlfcn_dl.c: Compiling warning is fixed. 2019-01-24 Araki Ken * README.indic: Updated. * etc/*font*: ISCII_* except ISCII_TAMIL are activated. * libind/Makefile.in: tamil.o is not built. 2019-01-20 Araki Ken * ui_font_ft.c: - A font name which contains "-" is not passed to FcNameParse(). - FT_ENCODING_APPLE_ROMAN is not set for ISCII in xft_font_open() and cairo_font_open(). - "drawn_x +=" => "drawn_x =" in show_text(). - Unexpected increment of a counter is fixed in ui_window_draw_string32(). * ui_window_cairo.c: - show_iscii() is added to show ISCII characters. - flush_glyphs() is called when font->size_attr == DOUBLE_WIDTH. * ui_window_xft.c: ui_window_xft_draw_string8() shows iscii characters by FC_Get_Char_Index() and XftDrawGlyphs(). 2019-01-15 Araki Ken * vt_line_bidi.c: If vt_bidi() returns 0 or less value and base_was_trl is true, vt_line_set_modified_all(line) is called. * vt_bidi.c: If size == 0, return 0 instead of 1. * terminaldisplayinit.cc: Code formatting. 2019-01-14 Araki Ken * vt_config_menu.[ch], vt_parser.[ch], vt_pty.[ch], vt_pty_intern.h, vt_pty_mosh.c, vt_pty_ssh.c, vt_term.[ch]: vt_pty_ptr_t -> vt_pty_t * 2019-01-13 Araki Ken * README.mosh: Updated. * ui_event_source.c, ui_screen.c: 'vt_term_get_slave_fd() == -1' => 'vt_term_get_pty_mode() == PTY_SSH' * ui_main_config.c: If bl_get_lang() is not only "ja" but also "Japanese" (on win32api), the default value of "col_size_of_width_a" option is 2 instead of 1. * vt_term.[ch]: vt_term_get_slave_fd() is added. * vt_pty_mosh.cpp: - If the value of "MOSH_AWIDTH" environmental variable is "2", wcwidth() returns 2 for ambiguous width characters. - win32api locale is changed to *nix locale as follows before sending it to mosh-server. Japanese.Japan => ja_JP.UTF-8 Chinese.Taiwan => zh_TW.UTF-8 Chinese.Hong Kong SAR => zh_HK.UTF-8 Chinese.China => zh_CN.UTF-8 Korean.Korea => ko_KR.UTF-8 - PTY_MOSH is set. * vt_config_menu.c: - is_mosh is removed from vt_config_menu_t. - config_menu->is_mosh is replaced by vt_pty_get_mode() == PTY_MOSH. * vt_parser.c: - vt_parser_set_pty() modifies col_size_of_width_a if pty is mosh. - set_col_size_of_width_a() does nothing if pty is mosh. * vt_pty_ssh.c: PTY_SSH is set. * vt_pty_pipewin32.c: PTY_PIPE is set. * vt_pty_unix.c: PTY_LOCAL is set. * vt_pty_intern.h: mode is added to vt_pty_t. * vt_pty.[ch]: - vt_pty_mode_t is added. - vt_pty_get_mode() is added. 2019-01-12 Araki Ken * README.mosh: Updated. 2019-01-10 Araki Ken * vt_pty_ssh.c: vt_pty_ssh_set_pty_read_trigger() is added. * libptyssh/vt_pty_ssh.c: vt_pty_set_pty_read_trigger() is renamed to vt_pty_ssh_set_pty_read_trigger(). * vt_pty_mosh.cpp: - 'static pthread_cond_t event_cond' is added to synchronize the main thread and watch_ptys thread. - wcwidth(), convert_utf8_to_ucs() and convert_ucs_to_utf8() are added for terminal.cc, terminaloverlay.cc, parser.cc and terminalframebuffer.h on win32. - use_loopback() and unuse_loopback() support win32. - Select of mosh-x.x.x/src/util/select.h is replaced by select(2). - final() calls unuse_loopback(). - vt_pty_mosh_set_pty_read_trigger() is added. * libptymosh/Makefile.in: select.o is removed from OBJ. * configure.in: - If --with-mosh is specified on win32, ssh2 and mosh features are built as modules. - PKG_CHECK_MODULES(protobuf) is added. * version.h: 3.8.6 -> 3.8.7 2019-01-03 Araki Ken * libptymosh/Makefile.in: -lncursesw is removed. * libptymosh/terminaldisplayinit.cc: Added. * vt_pty_mosh.cpp: Warn if the value of "termtype" option is "kterm" or "mlterm" which doesn't support bce. 2019-01-03 Araki Ken * vt_pty_mosh.cpp: read_pty() is called within at least 500 msec to show notification message such as "Last contact N seconds ago.". * README.android: The way of building mlterm for android is added. 2019-01-02 Araki Ken * doc/en/README.mosh: Added. * vt_pty_mosh.cpp: - 'Overlay::OverlayManager *overlay' is added to vt_pty_mosh_t. - The returned value of pty_mosh->display.open() is always returned to the caller of read_pty(). - If the value of TERM environmental variable is not "xterm", "rxvt", "kterm, "Eterm" or "screen", setenv("TERM", "xterm") forcibly in order to enable to set window or icon title by OSC 0-2. - MOSH_PREDICTION_DISPLAY environmental variable is supported. * ui_layout.c: When parent->next[0] or parent->next[1] is set, parent->separator_x or parent->separator_y is also set. 2019-01-02 Araki Ken * man/mlterm.1, README.ja, PROTOCOL: Updated. * ui_main_config.c: "local_echo_wait" / --lew option is added. * vt_parser.[ch]: - vt_set_local_echo_wait() is added. - "local_echo_wait" is added to OSC 5379-5383. 2018-12-31 Araki Ken * vt_config_menu.c: - vt_pty_set_use_loopback() => vt_pty_{ssh|mosh}_set_use_loopback() - is_mosh is added to vt_config_menu_t. * vt_pty.h: If USE_MOSH is defined, ssh2 specific functions are concealed * vt_pty_ssh.c: vt_pty_set_use_loopback() => vt_pty_ssh_set_use_loopback() * vt_pty_mosh.c: vt_pty_mosh_set_use_loopback() is added. * libptymosh/vt_pty_mosh.cpp: - USE_LIBSSH2 and USE_MOSH are defined explicitly. - vt_pty_mosh_set_use_loopback() is added. - Dead lock is fixed in watch_ptys(). - If pty_mosh->initialized is false, pty_mosh->display.open() is called in read_pty(). - vt_pty_t::slave is -2 instead of -1 to distinguish from ssh. - Calculation of vt_pty_t::child_pid is fixed. * winrs.rs: The size of "Protocol" group box is fixed. * servman/main.c, servman/servman.rc: - mosh protocol (IDD_MOSH) is supported. - "://" is not regarded as a separator of path. 2018-12-29 Araki Ken * README.console, README.ja: Updated. * console/ui_display.c: - The default value of dither_id is changed from BUILTIN_XTERM16 to BUILTIN_XTERM256. - CSI?8452h or CSI?8452l is output. - CSI?1;1;0S (XTCOLREQ) is output and the response of it is parsed in receive_stdin_event() or ui_display_output_picture(). * vt_parser.c: Typo is fixed. 2018-12-28 Araki Ken * console/ui_window.c: copy_area() checks if width == 0 or height == 0. * c_sixel.c: Rare segfault case is fixed. * */ui_imagelib.c: Pipe from mlterm to mlimgloader is removed. * console/ui_display.c: ui_display_output_picture() calls sixel_dither_set_pixelformat() every time. 2018-12-23 Araki Ken * vt_pty_mosh.cpp: - "C.UTF-8" locale (which is the default value on cygwin) is ignored. - Error message of locale setting by mosh-server is output. * bl_locale.c: If setlocale() fails, setlocale() is called again with the previous locale. * configure.in: vtemu/libptymosh is placed after vtemu/libptyssh in MAKE_DIRS and OUTPUT_FILES. 2018-12-23 Araki Ken * etc/key, mlterm.1, README.ja: Updated. * ui_screen.c: "%s" in "exesel:..." is replaced by selected strings. 2018-12-22 Araki Ken * vt_edit.c: If the size of a window decreases and some characters on it disappear, it is cleared and all characters on it are scrolled out. * ui_window.c: total_min_{width|height}() doesn't consider RIGHT_MARGIN and BOTTOM_MARGIN. * ui_layout.c: If the size of a root window becomes smaller than the size of each child window, modify_separator() returns "total / 2". 2018-12-21 Araki Ken * README, README.ja: Updated. * vt_pty.c: vt_pty_new() calls vt_pty_mosh_new() instead of vt_pty_ssh_new() if 'host' contains "mosh://". * vt_pty_ssh.c: read_pty() calls bl_trigger_sig_child() only if libssh2_channel_read() returns 0 or less value. (If libssh2_channel_eof() returns true and libssh2_channel_read() > 0, bl_trigger_sig_child() is not called.) This change is for mosh. * win32/ui_connect_dialog.[ch], winrs.rs: IDD_MOSH is added. * bl_path.c: bl_parse_uri() recognizes "mosh://". * configure.in: --with-mosh option is added. * vtemu/libptymosh: Added. * vt_parser.c: get_vtmode() returns 3 (permanently set) for DECPCCM, DECATCUM and DECATCBM. 2018-11-23 Araki Ken * vt_parser.c: Fix segfault by "CSI 21 t". (https://sourceforge.net/p/mlterm/mailman/message/36472061/) 2018-11-18 Araki Ken * README.ja: Minor fixes. * mlconfig/po/*.po: Updated. * fb/ui_font.c, ui_font_ft.c: FcNameParse() is used. * ui_font_config.c: Parsing ';' and ',' for backward compatibility is fixed. 2018-11-05 Araki Ken * android/jni/ui_display.c: Even if the cursor moves slightly, long click is assumed to continue. * version.h: 3.8.7 -> 3.8.7post 2018-10-27 Araki Ken * 3.8.7 released. (tag "rel-3_8_7") * configure.in, mlterm.spec, main/version.h.in, mlterm.c, android/jni/version.h: updated for 3.8.7. * README, man/mlterm.1, libvterm/README, gtk/README, mlcc.1: Updated. * ui_font_config.c: ui_customize_font_file() resets font_config->font_name_table if *value is '\0'. 2018-10-13 Araki Ken * ui_layout.c: The position of calling update_normal_hints() is fixed. 2018-10-12 Araki Ken * README, PROTOCOL, README.win32, README.ja, etc/main, etc/main.ja, gtk/README, man/mlterm.1: Updated. * ui_screen.c: The restriction of the range of screen->underline_offset is mostly eliminated. * ui_layout.c: total_hint_size() sets sizehint_flag of ui_screen_t and ui_scrollbar_t. * ui_window.h, */ui_window.c: - ui_sizehint_flag_t is added. - ui_sizehint_flag is added to ui_window_t. - total_min_{width|height}() and total_{width|height}_inc() use sizehint_flag. * vt_parser.c: "switch" is available for the value of "col_size_of_width_a" of OSC 5379. 2018-09-23 Araki Ken * README.android, README.cocoatouch: Updated. * ui_screen.c: Minor changes about flick scrolling. * ui_font_manager.c: The default value of 'max_font_size' is changed from 40 to 50. * android/jni/ui_display.c: long_press_count == 15 (instead of 20) opens menu. * android/jni/ui_event_source.c: - ((ui_screen_t*)win)->is_preediting is set in update_ime_text(). - need_resize() considers bottom margin correctly. * cocoa.m, cocoatouch.m, android/jni/ui_event_source.c, sdl2/ui_display.c: If both preedit_text and cur_preedit_text are non-NULL and same value, update_ime_text() does nothing. 2018-09-17 Araki Ken * Makefile.in: 'test' target is added for bitbucket pipelines. 2018-09-16 Araki Ken * README.console: Updated. * ui_screen.c: The place where enter_backscroll_mode() is called is moved. 2018-09-13 Araki Ken * ui_screen.c: Segfault on Android in scrolling by flick is fixed. 2018-09-11 Araki Ken * cocoa/lipo.sh, mlterm-ios.app/Info.plist: Added. * ui_scrollbar.c: sb->current_row is reset in window_resized. * ui_screen.[ch]: - grab_scroll is added to ui_screen_t. - bs_scroll_upward() and bs_scroll_downward() are swapped in flick scrolling. * cocoatouch.m: Function keys are ingored in insertText(). * android/jni/ui_event_source.c, cocoa.m, cocoatouch.m, sdl2/ui_display.c: If vt_term_is_backscrolling() is true, update_ime_text() does nothing. 2018-09-09 Araki Ken * README.cocoatouch: Updated. * cocoatouch.m: - AppDelegate_{iPhone|iPad} => AppDelegate - UIWindow is manually allocated in AppDelegate::application(). - keyCommands() is implemented. * mlterm-cocoa.m: AppDelegate class is specified in calling UIApplicationMain(). * mlterm-icon.app/mlterm-Info.plist, Makefile: Added. * mlterm-icon.app/Info.plist, MainWindow_{iPad|iPhone}.{nib|xib}: Removed. 2018-09-06 Araki Ken * configure.in: -mios-simulator-version-min option is added to $CC on iOS SDK 5.0 or later. * cocoa/build-iossim43.sh: Renamed from build-iossim.sh * cocoa/build-ios43.sh: Renamed from build-ios.sh * cocoa/build-iossim71.sh, mlterm-ios.app/MainWindow_{iPad|iPhone}.xib: Added. * cocoatouch.m, vt_pty_unix.c: Minor fixes. 2018-09-03 Araki Ken * ui_screen.c: Right key scrolls upward and left key scrolls downward in scrolling mode. 2018-09-02 Araki Ken * README.android, doc/en/PROTOCOL: Updated. * ui_screen.[ch]: - 'size' is added to arguments of bs_scroll_{up|down}ward(). - bs_{half_}page_{up|down}ward() are defined as macros instead of functions. - flick_time, flick_y and autoscroll_count are added to ui_screen_t if FLICK_SCROLL is defined. - If screen->autoscroll_count != 0, idling() scrolls screen. - "autoscroll" is added to ui_screen_exec_cmd(). * */ui.h: FLICK_SCROLL which enables auto scrolling by flick is defined on Android and iOS. * android/jni/ui_display.c: - long_press_count == 20 (instead of 10) opens menu. - The are of double click to show software keyboard is changed. - Long press at the lower right corner instead of the entire screen shows context menu. * android/jni/ui_event_source.c: clock_gettime() is called to check if ui_display_idling() should be called. * cocoatouch.m: longpress.minimumPressDuration = 2.0. 2018-09-01 Araki Ken * ui_window.c, ui_screen_manager.c: Hack to keep window size is fixed. * main-cocoa.m: Application class instead of UIApplication is used. * cocoatouch.m: - UITextInput protocol is implemented. - Application class derived from UIApplication is added to receive all keyboard input events. - viewDidMoveToWindow => didMoveToWindow. * vt_pty_unix.c: Hack for iOS 4.3 is added. 2018-08-28 Araki Ken * doc/en/README.cocoatouch: Added. * main/Makefile.in: -framework Foundation -framework Cocoa => @COCOA_LIBS@ * uitoolkit/Makefile.in: cocoa.o => @COCOAOBJ@ * configure.in: - --with-ios-sdk and --with-ios-arch are added. - If --with-ios-sdk option is specified, COCOA_TOUCH macro is defined. * cocoa/build-ios.sh, build-iossim.sh, install-ios.sh, mlterm-ios.app: Added. * ui_screen_manager.c: New pty is opened in pty_closed() if pty is closed and there is no pty. * main-cocoa.m, quartz/ui_font.c, ui_im_status_screen-cocoa.m, quartz/ui_imagelib.c, quartz/ui_window.c: CocoaTouch is supported. * cocoatouch.m: Added. * cocoa.m: [super becomeFirstResponder] is called in becomeFirstResponder(). * ui_main_config.c: The default value of type_engine option is always TYPE_XCORE on platforms except xlib. * im_uim.c: Compiling error is fixed. * baselib/configure.in: Following checks are executed only if $host = $build. AC_RUNIFELSE(posix_openpt), AC_TRY_RUN(calloc). 2018-08-04 Araki Ken * mc_font.c: - gtkxlfdsel.c is included if GDK_WINDOWING_X11 is defined regardless USE_ macro defined by mlterm. - select_xlfd_font() is called only if mc_get_gui() == "xlib". * main.c: char *gui; => const char *gui; * configure.in, tool/mlconfig/Makefile.in: XLFDSEL_OBJ is removed. 2018-08-03 Araki Ken * im_uim.c: uim_scm_is_initialized() is used to check if uim_init() has been called. 2018-07-31 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/ui_display_freebsd.c: PS2 mouse (/dev/psm0) and PC98 bus mouse (/dev/mse0) are supported. * fb/ui_display.c: put_image_124bpp() is tuned up. 2018-07-23 Araki Ken * c_sixel.c: Sixel graphics extension which "sayaka --ormode on" outputs is supported. (Disabled by default. #define SIXEL_ORMODE enables it.) 2018-07-22 Araki Ken * c_sixel.c: Sixel graphics extension and option1 of https://github.com/kmiya-culti/RLogin/issues/22#issue-341758598 are supported. * vt_parser.c: Return value of CSI?1;Pa;PvS is changed from CSI?1;0;256S to CSI?1;0;1024S. * MLTermPty.c: It is possible to load libgcc_s_sjlj-1.dll. * bl_pty_streams.c: #define __XSI_VISIBLE 600 forcibly for cygwin. (see /usr/include/cygwin/stdlib.h) * uitoolkit/Makefile.in, servman/Makefile.in: i686-w64-mingw32-windres.exe is used instead of windres.exe if $CC is i686-w64-mingw32-gcc.exe. * aclocal.m4, ltmain.sh: Updated for Cygwin/x86_64. * configure.in: - $host="msys" is supported. - PKG_CHECK_MODULES(libssh2) is used instead of AC_CHECK_LIB(libssh2_init). - AM_GLIB_GNU_GETTEXT is used instead of AM_GNU_GETTEXT. * mlconfig/po/Makefile.in.in: Simplified. * mlconfig/po/ChangeLog, LINGUAS, Makevars, Rules-quot, en@boldquot.header, en@quot.header, insert-header.sin, quot.sed: Removed. * win32/mlterm.manifest: Added. * ui_screen.c: - Hack for "microsoft-edge:" is added to shortcut_str(). - permit_exec_cmd() which checks ~/.mlterm/execlist to determine whether "mlclient -e cmd" is permitted is added. 2018-07-02 Araki Ken * c_sixel.c: - The number of palettes which load_sixel_from_data() supports is up to 1024. - The palette number #1024 or greater is regarded as 15 bit RGB. 2018-06-30 Araki Ken * fb/ui_imagelib.c: SIXEL_PALETTES_SIZE is used. * c_sixel.c: - load_sixel_from_data() supports a maximum of up to 65536 palettes. - SIXEL_PALETTES_SIZE macro is defined. 2018-06-17 Araki Ken * configure.in: m17nlib is checked by PKG_CHECK_MODULES(). * mc_im.c: libim-*-sdl2.so is supported if gui is "sdl2". * ef_ucs_property.table: Updated to Unicode 11.0.0 (UnicodeData.txt and EastAsianWidth.txt) * mlconfig/main.c: mc_im_init() is called in main() first of all. * mc_im.[ch]: mc_im_init() which calls get_im_info() is added. 2018-06-14 Araki Ken * win32/ui_connect_dialog.c: HOMEPATH environmental variable is ensured before executing servman.exe. * version.h: 3.8.6 -> 3.8.6post 2018-06-12 Araki Ken * 3.8.6 released. (tag "rel-3_8_6") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.8.6. * man/mlterm.1: Updated. 2018-06-12 Araki Ken * ui_screen_manager.c: open_pty_intern() assumes that ui_connect_dialog() doesn't change arguments except uri. * win32/ui_connect_dialog.c: dialog_proc() checks selected_ssh_privkey before 'if (default_server)'. * xlib/ui_connect_dialog.c: ui_connect_dialog() doesn't change 'pass' arguments if it fails. * android/jni/ui_connect_dialog.c: ui_connect_dialog() doesn't set values to arguments except uri if ui_display_show_dialog() fails. 2018-06-10 Araki Ken * xlib/ui_window.c: Compiling error is fixed. * gtk/Makefile.in: @LPOBL@ and @LMEF@ are used. * configure.in: contrib/scrollbar is copied to gui/ if multiple values separated by ',' is specified as the value of --with-gui option. * libtype/Makefile.in: LPOBL=${top_builddir}/baselib/src/libpobl.la => LPOBL=@LPOBL@ 2018-06-09 Araki Ken * MLActivity.java: - "SCP" is added to the context menu. - onCreateDialog(2) creates SCP dialog. * android/jni/ui_event_source.c: - Type of 'cmd' argument of Java_mlterm_native_1activity_MLActivity_execCommand() is changed from jint to jstring. - Java_mlterm_native_1activity_MLActivity_isSSH() is added. * libptyssh/vt_pty_ssh.c: Hack for libssh2_scp_send(). * vt_pty_ssh.c: ~/.mlterm/scp directory is automatically created. 2018-06-09 Araki Ken * MLActivity.java: "Priv Key" entry is added to the connection dialog. * android/jni/ui_display.[ch]: 'char *privkey' is added to ui_display_show_dialog(). * android/jni/ui_connect_dialog.c: - 'char **privkey' is added to arguments of ui_connect_dialog(). - 'jstring privkey' is added to arguments of Java_mlterm_native_1activity_MLActivity_dialogOkClicked(). * vt_pty_ssh.c: The default value of privkey and pubkey is changed from /sdcard/.ssh/id_rsa(.pub) to /sdcard/.mlterm/id_rsa(.pub). 2018-06-07 Araki Ken * win32/ui_connect_dialog.c: DnD to "PrivKey" entry is supported. 2018-06-05 Araki Ken * ui_screen_manager.c: ui_connect_dialog() can modify the value of main_config.private_key. * vt_pty_ssh.c: ssh_connect() passes NULL to libssh2_userauth_publickey_fromfile() as 'publickey' argument. * winrs.rs: "PrivKey" entry is added. * win32/ui_connect_dialog.c: - get_window_text() returns UTF-8 or MB text. - set_window_text() which converts UTF-8 string to WCHAR* and calls SetWindowTextW() is added. * ui_connect_dialog.h, */ui_connect_dialog.c: - 'char **privkey' is added to arguments of ui_connect_dialog(). - IDD_SSH_PRIVKEY is added. 2018-06-02 Araki Ken * ui_draw_str.c: bg_xcolor is added to arguments of draw_picture(), and if bg_xcolor is not NULL, ui_window_fill_with() is used instead of ui_window_clear(). * ui_screen.c: xterm_get_picture_data() uses vt_term_get_bce_ch() instead of vt_sp_ch(). * vt_parser.c: put_char() uses vt_term_get_bce_ch() instead of vt_sp_ch() in dealing with DRCS-SIXEL. * vt_edit.h, vt_screen.h, vt_term.h: vt_{edit|screen|term}_get_bce_ch() is added. * ui_screen.c, vt_parser.h: CS_BOX is added to vt_cursor_style_t, and is used to draw an unfocused cursor or a cursor on a picture. 2018-06-01 Araki Ken * servman/main.c, servman.rc: - IDM_XXX and IDD_XXX are changed from 1-28 to 101-128. - Message dialog to confirm whether to save to a configration file is shown if window is closed. - Message dialog to confirm whether to really delete an entry is shown. - Whether the edited name of a directory or an entry is valid or not is checked. * drcssixel/test.c: 2 sixel graphics are output. 2018-05-29 Araki Ken * man/mlterm.1, README.ja, en/README.win32, ja/README.win32, etc/main, etc/main.ja: Updated. * configure.in: tool/servman is added to OUTPUT_FILES and MAKE_DIRS if $gui is "win32". * ui_main_config.[ch], ui_screen_manager.c: - "server_list" option is removed. - ui_main_config_add_to_server_list() is removed. * */ui_connect_dialog.[ch]: - sv_list is removed from arguments of ui_connect_dialog(). - IDD_LIST is removed. * win32/ui_connect_dialog.[ch]: - ui_connect_dialog() executes "servman.exe" if 'default_server' argument is NULL or "?". - IDD_LIST is removed. * winrs.rs: "List" combo box is removed. * tool/servman/*: Added. * ui_screen.c: Underline style cursor is shown on pictures. * main_loop.c: -foo-*- as the value of "default_font" option is renamed to -foo-*-iso10646-1 in applying it to "ISO10646_UCS4_1" font. * ui_font.c: - XLoadQueryFont() and related code are collected to load_xfont_intern(). - AddStyleName in XLFD is always specified. * vt_config_menu.c: CREATE_NO_WINDOW => 0 in CreateProcess(). 2018-05-23 Araki Ken * drcssixel.c: Fix http://twitter.com/ttdoda/status/998852239505604608 2018-05-12 Araki Ken * ui_display.c: dialog_cb() returns 1 or -1. * otf.c: Compiling error (when BL_DEBUG is defined) is fixed. 2018-05-10 Araki Ken * vte.c: Compiling error is fixed. 2018-05-07 Araki Ken * vt_screen.h: vt_screen_{set|get}_last_column_flag() are added. * vt_parser.[ch]: - is_auto_wrap is removed from vt_storage_states_t, and last_column_flag is added. - If restore_cursor() is called before save_cursor(), the cursor is moved to the home position and all character attributes are turned off. - CSI Ps1;Ps2;... t (Ps1 = 7, 11, 13, 14, 15, 16, 18, 19, 20, 21, 24) is accepted. * vt_edit.[ch]: - vt_edit_{set|get}_last_column_flag() is added. - scroll_upwrad_region() checks CURSOR_IS_INSIDE_HMARGIN(). * vt_cursor.[ch]: is_saved flag is removed from vt_cursor_t. 2018-05-05 Araki Ken * man/mlterm.1, doc/ja/README.ja, etc/main, etc/main.ja: Updated. * ui_layout.c: key_pressed() calls ui_screen_t::key_pressed only if it is not NULL. * ui_main_config.[ch]: --rv / rv_color option is added. * ui_screen.c: - "rv_color" is added to OSC 5379 and 5380. - xterm_get_display_size() and xterm_lock_keyboard() are added. * ui_color_manager.[ch]: _REVERSE_COLOR is added to ui_color_manager_t::sys_colors. * vt_color.[ch]: - VT_REVERSE_COLOR is added. - prase_conf() calls vt_get_color_rgba() instead of vt_color_parse_rgb_name() to get rgb of a specified value if color_name is not "rgb:...". * vt_parser.[ch]: - ALT_COLOR_REVERSE is added to vt_alt_color_mode_t. - put_char() considers ALT_COLOR_REVERSE. - flush_buffer() doesn't clear buffer->last_ch if buffer->filled_len == 0. - get_cell_size(), report_cell_size() and report_display_size() are added. - resize() resizes a screen to the width or height of the display if width or height argument is 0. - width or height argument of resize() not to resize a screen is changed from 0 to -1. - get_fgbg_rgb(), get_special_color_name(), change_fgbg_color() and reset_color_rgb() are added. - get_rgb() returns RGB of alt colors. - change_color_rgb() and change_special_color() support multiple parameters separated by ';'. - change_special_color() supports '?' which queries current setting. - report_status() reports DECSCA status. - get_vtmode() returns 4 (permanently reset) for GATM, SRTM, VEM, HEM, PUM, FEAM, FETM, MATM, TTM, SATM, TSM and EBM. - lock_keyboard is added to vt_xterm_event_listener_t, and KAM uses it instead of vt_parser->pty_hook.pre_write = NULL. - soft_reset() resets DECSC and DECSASD. - full_reset() resets DECCOLM, tab stops, CSI>T and CSI>t. - CSI 15 t, CSI 16 t and CSI 19 t are supported. - The response strings of OSC 20 and OSC 21 are fixed. * vt_screen.[ch]: - vt_screen_saved_cursor_to_home() is added. - vt_screen_use_{normal|alternative}_edit() keeps the cursor position. - vt_screen_set_status_line(screen, 1) moves the cursor position to home. * vt_edit.[ch]: - vt_edit_set_{hv}margin() don't call vt_edit_goto(edit, 0, 0). - vt_edit_set_hmargin() behaves same as vt_edit_set_vmargin() if beg or end argument is -1. - vt_edit_saved_cursor_to_home() is added. * vt_pty.c: pty->hook->pre_write is always non-NULL value if pty->hook is non-NULL. * vt_cursor.h: vt_saved_cursor_to_home() is added. 2018-04-27 Araki Ken * vt_screen.[ch]: vt_screen_get_checksum() is added. * vt_parser.[ch]: - save_cursor() stores is_protected, is_relative_origin and is_auto_wrap, then restore_cursor() restores them. - OSC 4 returns "OSC ... ST" instead of "OSC ... BEL". - The default values are set if 5, 6 and 7th parameters of DECCRA are omitted. - The default value of Pch of DECFRA is '%'. (compat with xterm) * vt_edit.[ch]: - apply_relative_origin() checks whether col/row/num_cols/num_rows are within screen or not if edit->is_relative_origin is false. - Corruption of vt_edit_delete_cols() if DECLRMM is fixed. - vt_edit_scroll_leftward() is fixed. - vt_edit_set_use_hmargin() ignores -1 value of 'use' argument. - vt_edit_get_checksum() is added. * xlib/ui_font.c: If cairo_set_ot_font() fails, font->ot_font_not_found = 1. * hb.c: hb_ot_layout_has_substitution() is checked. 2018-04-21 Araki Ken * ui_scrollbar.c: If win->is_mapped is false, window_exposed() does nothing. * ui_im_{candidate|status}_screen.c, ui_screen.c: ui_window_flush() is called. * ui_window.[ch]: ui_window_flush() which works for cairo is added. * ui_window_cairo.c: - Drawn glyphs are cached until cairo_flush() is called. - ui_window_draw_string32() calls cairo_flush() if str argument is NULL. * mc_opentype.c: Compiling error is fixed if gtk+ version is less than 2.14.0. 2018-04-13 Araki Ken * vtetypebuiltins.c: vte_text_blink_mode_get_type() is added. * vte.c: vte_terminal_unselect_all(), vte_terminal_set_bold_is_bright(), vte_terminal_get_bold_is_bright(), vte_terminal_set_cell_width_scale(), vte_terminal_get_cell_width_scale(), vte_terminal_set_cell_height_scale(), vte_terminal_get_cell_height_scale(), vte_terminal_set_text_blink_mode() and vte_terminal_get_text_blink_mode() are added. * xlib/ui_color.c: ui_load_rgb_xcolor() considers alpha if depth == 32 and alpha < 0xff. 2018-04-01 Araki Ken * README.ja: Updated. * vt_pty.c: S_IFCHR of fstat() is used instead of ptsname(). * ui_imagelib.c: If ui_display_is_changeable_cmap() returns true, load_sixel_from_data_sharepalette() is not called. * fb/ui.h, fb/ui_display.c, ui_display_freebsd.c: M_PC98_EGC640x400 on FreeBSD(98) is supported. * configure.in: - Missing " is added. - -DPC98 is added to GUI_CFLAGS if sysctl machdep.ispc98 returns 1. 2018-03-15 Araki Ken * ui_virtual_kbd.c: Compiling error is fixed. * vt_parser.c: "N%" is supported in OSC 1337. * configure.in: It is possible to specify multiple values for --with-gui option. (e.g. --with-gui=xlib,sdl2,wayland,fb,console) 2018-03-12 Araki Ken * ui_screen.c: xterm_get_picture_data() places image at the center of the specified width and height if keep_aspect is true. * xlib/ui_imagelib.c: - ui_imagelib_load_file() modifies *width and *height if keep_aspect is true. - width and height of ui_imagelib_loada_file() are never NULL. * fb/ui_imagelib.c, console/ui_imagelib.c: ui_imagelib_load_file() modifies *width and *height if keep_aspect is true. 2018-03-11 Araki Ken * ui_window_cairo.c: Memory leak of surface is fixed. * ui_font_ft.c: Double free when XftFontOpenPattern() succeeds is fixed. * ui_picture.[ch]: 'int keep_aspect' is added to arguments of ui_load_inline_picture(). * ui_imagelib.h, */ui_imagelib.c: 'int keep_aspect' is added to arguments of ui_imagelib_load_file(). * gdiplus.c, gdk-pixbuf.c, none.c: mlimgloader [window id] [width] [height] [src file] ([dst file]|-c) => mlimgloader [window id] [width] [height] [src file] (pixmap|stdout|[dst file]) -a * vt_parser.[ch], ui_screen.c: 'int keep_aspect' is added to arguments of vt_xterm_event_listener_t::get_picture_data. * mlcc/main.c: The value type of "use_anti_alias" option is changed from bool to string. * configure.in: 'libvterm' directory is copied to fb/ if --with-gui=fb,xlib * version.h: 3.8.5 -> 3.8.5post 2018-03-07 Araki Ken * 3.8.5 released. (tag "rel-3_8_5") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.8.5. * README, README.sdl2, README.wayland, README.ja, README.tate, PROTOCOL, man/mlterm.1: Updated. 2018-03-06 Araki Ken * gtk/vte.c: vte_terminal_copy_clipboard_format() is added. * README.ja, mlterm.1: Updated. * vt_logs.[ch]: - The value of 'logsize' option is automatically changed to 'unlimited' if it is over 65535. - VT_LOG_SIZE_UNIT is defined. 2018-03-04 Araki Ken * cocoa/install.sh: libotl.so -> libotl-quartz.so * cocoa.m: Compiling error is fixed. * MLActivity.java: - showDialog() => showConnectDialog() - showMessage() is added. * android/jni/ui_display.c: bl_dialog_set_callback(dialog_cb) is added. 2018-03-03 Araki Ken * libotl/Makefile.in, otl.h: Library name is changed from libotl to libotl-win32 on win32api and to libotl-quartz on MacOSX/Cocoa in order to coexist with libotl for sdl2. * fb/ui_font.c: get_cached_xfont() checks xfont->is_aa 2018-03-03 Araki Ken * vt_shape.c: vt_shape_ot_layout() does nothing for a character whose charset is PICTURE_CHARSET. * sdl2/ui_display.c: Not only SDL_DestroyCond but also SDL_CondSignal() is called in ui_display_close(). * fb/ui_window.c: Fix illegal memory access in draw_string_intern(). * sdl2/ui_imagelib.c: exec_mlimgloader() is added, and it works on win32api. * mlfc/main.c: FONTCONFIG_PATH environmental variable is set. * configure.in, registobmp/main.c: If SDL_ttf is not found, registobmp is compiled without it. 2018-02-28 Araki Ken * vt_ot_layout.c: If 5 or more same usascii characters are repeated, vt_ot_layout() doesn't call vt_ot_layout_shape(). * ui_font.c: init_fontconfig() initializes FONTCONFIG_PATH environmental variable if USE_WIN32API is defined. * mlfc/main.c: Compiling error is fixed. 2018-02-25 Araki Ken * ui_screen_manager.c: "No fonts" error message is shown by bl_dialog() instead of bl_msg_printf(). * sdl2/ui_display.c: Falling into infinite sleep in select() is fixed. * syswminfo.c: syswminfo_is_thread_safe() returns 0 on cocoa. * cocoa.m: create_dialog() checks if the current thread is main thread or not. * configure.in: It is possible to use fontconfig on SDL2/win32. 2018-02-25 Araki Ken * ui_shortcut.c: Control+F* shortcut keys => Command+F* on SDL2 / MacOSX. * sdl2/ui_display.c: SDL_DisplayMode::refresh_rate > 0 is checked before calculating vsync_interval_msec. * inputmethod/*/Makefile.in: @SDL2_CFLAGS@ is added to include from ui.h correctly. * configure.in: Either AC_CHECK_HEADER(hb-ft.h) or AC_CHECK_HEADER(hb-coretext.h" is executed if harfbuzz is enabled. * cocoa/install-sdl2.sh: Added. 2018-02-24 Araki Ken * sdl2/ui_display.c: SDL_CondSignal() is called after processing pty events. 2018-02-24 Araki Ken * README.fb, README.sdl2, README.wayland, README.win32: Updated. * sdl2/ui_display.c: init_display() specifies x and y position of SDL_Window. 2018-02-24 Araki Ken * sdl2/ui_display.c: pthread is replaced by SDL_thread. * fb/ui_connect_dialog.c: ui_get_opened_displays() is called instead of ui_display_receive_next_event() on SDL2. * syswminfo.[ch]: Added. * MLTerm.java: MessageBox is removed from startMLTerm(). * MLTermApplet.java: MessageBox is removed from run(). * ConfirmDialog.java: 'boolean okcancel' is added to show(). * MLTermPty.c: dialog_callback() supports BL_DIALOG_ALERT. 2018-02-22 Araki Ken * vt_term.c: "Failed to open pty" message is shown if vt_pty_new() fails. * sdl2/ui_display.c: bl_dialog_set_callback(dialog_cb) is added. * bl_util.h: - K_{MAX|MIN} => BL_{MAX|MIN} - BL_SWAP() is added. 2018-02-21 Araki Ken * sdl2/ui_display.c: Minor fixes. 2018-02-20 Araki Ken * wayland/ui_display.c: ui_display_rotate() does nothing after a display is opened. * sdl2/ui_display.c: - disp->display->resizing = 1 in ui_display_resize(), and disp->display->resizing = 0 in SDL_WINDOWEVENT_SIZE_CHANGED. - ui_display_rotate() does nothing after a display is opened. * sdl2/ui_window.c: If win->disp->display->resizing is 1, ui_window_resize() does nothing. * sdl2/ui.h: 'resizing' is added to Display. 2018-02-19 Araki Ken * sdl2/ui_window.c, sdl2/ui_display.c: Copy&paste with the use of SDL_{Get|Set|Has}ClipboardText() is supported. * configure.in: Minor fixes. 2018-02-18 Araki Ken * sdl2/ui_display.[ch]: - The timing of calling present_displays() is fixed. - SDL_WINDOWEVENT_FOCUS_{GAINED|LOST} events are processed. - ui_display_resize(), ui_display_move(), ui_display_set_maximized() and ui_display_set_title() are implemented. * wayland/ui_display.[ch]: - 'int flag' is added to arguments of ui_display_set_maximized(). * sdl2/ui_window.c: #if defined(USE_WAYLAND) || defined(USE_SDL2) => #ifndef MANAGE_ROOT_WINDOWS_BY_MYSELF 2018-02-18 Araki Ken * sdl2/ui_display.c: SDL_TEXTEDITING event is processed, and preediting text is shown. * vt_term.h, vt_parser.c: vt_term_preedit() is always compiled. * mlconfig/Makefile.in: Typo of LIBS2_win32 is fixed. 2018-02-18 Araki Ken * README, doc/{ja,en}/README.win32: Updated. * sdl2/ui_display.c: - XKeyEvent::str and XKeyEvent::parser are set in poll_event(). - ui_display_logical_to_physical_coordinates() applies the position of SDL_Window. * sdl2/ui_window.c: ui_window_get_str() processes XKeyEvent::str and XKeyEvent::parser. * sdl2/ui.h: str and parser are added to XKeyEvent. * im_fcitx.c: ui_im_status_screen is used on sdl2. 2018-02-17 Araki Ken * doc/en/README.win32: Updated. * mlimgloader/Makefile.in: LIBS2_sdl2_gdiplus is added. * mlconfig/Makefile.in: bindir=@bindir@ is added. * mlterm-menu/Makefile.in: Typo is fixed. * sdl2/ui.h: => (for inputmethod/*) * configure.in: - PKG_PATH_TOOL(pkg-config) => PKG_CHECK_TOOL(pkg-config) (This makes it unnecessary to specify an absolute path.) - "tr -d '\r'" is removed. - MLIMGLOADER_LIBS=gdiplus if $have_gdiplus = "yes" but $gui != "win32" 2018-02-16 Araki Ken * libptyssh/vt_pty_ssh.c, vt_pty.h: vt_pty_ssh_set_pty_read_trigger() is renamed to vt_pty_set_pty_read_trigger(). * vt_pty_pipewin32.c: PostThreadMessage(main_tid, WM_APP, 0, 0) is replaced by (*trigger_pty_read)(). * main.c, win32/ui_display.c: main_tid = GetCurrentThreadID() is moved from main() to ui_display_open(). 2018-02-16 Araki Ken * README, README.ja: Updated. * doc/en/README.sdl2: Added. * */Makefile.in: Target, flags or library for SDL2 is added. * configure.in: --with-gui=sdl2 is supported. * uitoolkit/sdl2: Added. * vt_pty.h, vt_pty_ssh.c: vt_pty_ssh_set_pty_read_trigger() is added. * ui_display.h, win32/ui_display.c, sdl2/ui_display.c: ui_display_trigger_pty_read() is added if USE_WIN32API is defined. * ui_draw_str.c: xcore_draw_str() supports SDL2. * fb/ui_window.c: draw_string_intern() doesn't call ui_display_get_pixel() as possible even if -otl option is enabled. * fb/ui_imagelib.c: mlimgloader is not executed if USE_WIN32API is defined. * fb/ui_font.c: mmap and munmap are invalidated if USE_WIN32API is defined. * ui_event_source.c, win32/ui_display.c: SetTimer() is called from ui_event_source.c to win32/ui_display.c. * ui_event_source.c: USE_WIN32API => NO_DISPLAY_FD * */ui.h: NO_DISPLAY_FD macro is defined (or undefined). 2018-02-03 Araki Ken * ui_draw_str.c, ui_font_cache.[ch], ui_font_manager.c, ui_im_{candidate|status}_screen.c, ui_screen.c: xfont => uifont * fb/ui_window.c: Compiling error is fixed. * Android.mk: ui_emoji.c is added. 2018-01-30 Araki Ken * ui_window.c: 'is_var_col_width' argument is added to draw_string() to distinguish it in drawing glyphs of true type fonts. * ui_font.c: - IS_PROPORTIONAL() => HAS_POSITION_INFO_BY_GLYPH() - enable_position_info_by_glyph() which adds 3 bytes position info to each glyph. - Position info is stored at the begining of glyph array instead of at the end. * ui_font.h: 'y' argument of ui_get_bitmap_line() is changed to 'offset_bytes' (== y * xfont->glyph_width_bytes) 2018-01-27 Araki Ken * README.ja, man/mlterm.1, doc/en/PROTOCOL: Updated. * ui_screen.c: "emoji_path" is added to OSC 5379, 5380 and 5381. * ui_picture.c: ui_load_inline_picture() doesn't check if path exists. (The caller should do it.) * ui_main_config.c: --emoji / emoji_path option is added. * ui_emoji.[ch]: Added. * c_imagelib.c: gdk_pixbuf_new_from_otf() which reads emoji fonts such as NotoColorEmoji.ttf is added if USE_FREETYPE_EMOJI is defined. * vt_parser.c: Not only U+1F1000-1F6FF but also U+1F900-1F9FF characters are treated as emoji. * fb/ui_font.c: Whether face->units_per_EM is 0 or not is checked. * win32/ui_font.c: Compiling error is fixed. 2018-01-20 Araki Ken * vt_parser.c: - Searching unicode_noconv_areas, full_width_areas and half_width_areas is improved. - auto_detect_count => num_auto_detect_encodings * vt_char.c: Searching unicode_areas in vt_char_set() is improved. 2018-01-14 Araki Ken * PROTOCOL, README.ja, mlterm.1, etc/main, etc/main.ja: Updated. * ui_screen_manager.c: "main_config.encoding = vt_term_get_encoding(screen->term)" is moved before create_term_intern() in open_pty(). * mc_char_width.c, mlconfig/po/*.po: - "Set full width\nareas manually" is changed to "Add full width areas". - "Add half width areas" button is added. * vt_parser.[ch]: - vt_set_half_width_areas() is added. - The char width of EF_AWIDTH property is determined in modify_ucs_property() (called from vt_convert_to_internal_ch()) instead of put_char(). - "unicode_half_width_areas" is added to OSC 5379, 5380 and 5381. * ui_main_config.c: --halfwidth / "unicode_half_width_areas" option is added. 2018-01-13 Araki Ken * README.fb, README.comb: Updated. * doc/en/README.w3m: Removed. * vterm.c: Typo is fixed. * drcssixel/DRCS-SIXEL-v2: Moved from doc/en. * drcssixel/drcssixel.c, drcssixel/test.c: Added. 2018-01-10 Araki Ken * c_sixel.c: Memory allocation is improved. 2018-01-09 Araki Ken * ui_im_status_screen.c: If USE_STATUS_LINE is defined, DECSSDT/DECSASD is used to show status characters. 2018-01-07 Araki Ken * ui_picture.c: cleanup_inline_pictures() checks DRCS-SIXEL. * vt_drcs.h: vt_drcs_has_picture() is added. * vt_pty.c: vt_pty_new_with() doesn't call vt_config_menu_init() if pty is NULL. * quartz/ui_imagelib.c: ui_imagelib_load_file() resizes a loaded image. 2018-01-06 Araki Ken * gdiplus.cpp: Sixel graphics is resized to specified width and height. * vt_parser.c: Minor fixes. 2018-01-06 Araki Ken * DRCS-SIXEL-v2: Updated. * vt_parser.c: - define_drcs_picture() is added. - "Pan;Pad;Ph;Pv is processed in receiving DRCS-Sixel sequence, and image pieces is scaled according to Pcmw/Pcmh and Ph/Pv. * vterm.c: "Pan;Pad;Ph;Pv is output unless DRCS_SIXEL=old environmental variable is defined. 2018-01-03 Araki Ken * DRCS-SIXEL-v2: Updated. * ui_font_config.c: ui_font_config_dump() outputs "_FULLWIDTH". * vterm.c: Pcmw and Pcmh in DECDLD are correctly set. 2018-01-02 Araki Ken * DRCS-SIXEL-v2, libvterm/README: Updated. * vterm.c: Adjusting vterm->drcs_charset and vterm->drcs_plane is placed before DRCS-SIXEL sequence is output. 2018-01-01 Araki Ken * DRCS-SIXEL-v2: Updated. * vterm.c: col_size_of_width_a is 1 if locale is ja_XX.XX. 2017-12-31 Araki Ken * DRCS-SIXEL-v2: Updated. * vterm.c: - q"%d;%d;%d;%d in sixel to be sent to terminal emulator as DRCS-Sixel is skipped. - 0x30-0x3f is accepted as vterm->drcs_charset. - "DRCS_SIXEL_VERSION" environmental varaible is dropped and "DRCS_SIXEL=old" is used. * vt_parser.c: - 0x30-0x3f character set is accepted for drcs. - Sixel sequence (in DRCS) which doesn't contain 'q' is accepted. - "drcs_sixel_version" is dropped and "old_drcs_sixel" is added to OSC 5379-5381. * vt_drcs.[ch]: 0x30-0x3f character set is accepted. * ef_charset.h: The range of CS96SB_ID() is changed from 0x40-0x7e to 0x30-7e to handle drcs correctly. 2017-12-31 Araki Ken * DRCS-SIXEL-v2: Updated. * vt_parser.c: 'font->pic_num_cols > 0' => vt_drcs_is_picture() * vt_drcs.[ch]: - The position of 'return 0' is fixed. - vt_drcs_is_picture() is added. 2017-12-30 Araki Ken * vterm.c: cell->attrs.reverse is set in vterm_screen_get_cell(). * vt_parser.c: DRCS-Sixel is enclosed by #ifndef NO_IMAGE ... #endif. 2017-12-30 Araki Ken * vterm.c: xterm_get_picture_data() rejects files except sixel. 2017-12-30 Araki Ken * vt_parser.c: If vt_parser->pty is NULL or not is checked in write_loopback() because vt_term_write_loopback() in open_pty_intern() in ui_screen_manager.c can be called when vt_parser->pty is NULL in connecting to ssh server. * vterm.c: default_fg and default_bg are the same as original libvterm. 2017-12-30 Araki Ken * vterm.c, ui_screen.c: RLogin way of calculating the number of columns of sixel graphics image is changed from 'width / col_width' to '(width + 1) / col_width'. * doc/en/DRCS-SIXEL-v2: Added. 2017-12-29 Araki Ken * vt_parser.[ch], ui_screen.c: Unless ENABLE_OSC5379PICTURE is defined, "show_picture" and "add_frame" are removed from OSC 5379. * vterm.c, ui_screen.c: RLogin way of calculating the number of columns and rows of sixel graphics image is changed from ({width|height} + 1) / col_{width|height} to {width|height} / col_{width|height}. * c_sixel.c: char* => const char* * ef_iso2022_parser.[ch], ef_utf{16|32}_conv.[ch]: The tyep of return value of ef_iso2022_parser_init_func() and ef_utf{16|32}_conv_use_bom() is changed from int to void. 2017-12-25 Araki Ken * vt_parser.c: - save_sixel_or_regis() is added. - DRCS-Sixel sequence which rlogin originally supports is processed. - If OSC 5379;drcs_sixel_version=2, cols and rows of DRCS-Sixel image are rounded up. * vt_drcs.[ch]: - vt_drcs_add_picture() and vt_drcs_get_picture() are added. - 'vt_drcs_t *drcs' is added to arguments of vt_drcs_get_font(), vt_drcs_final() and vt_drcs_final_full(). * ui_screen.c, ui_screen_manager.c: xterm_get_picture_data() returns num_cols_small and num_rows_small. * vterm.c: - write_to_stdout() is added. - xterm_get_picture_data() returns num_cols_small and num_rows_small. - If the value of "DRCS_SIXEL_VERSION" environmental variable is "2", num_cols and num_rows are rounded up. - vt_convert_drcs_to_unicode_pua() and vt_convert_unicode_pua_to_drcs() processes following extension. U+10XXZZ (0x40 <= 0xXX <= 0x7E, 0xA0 <= 0xZZ <= 0xFF) => ESC - SP <\xXX> <\xYY> * encodefilter/src/Makefile.in: MAJOR.MINOR 1.0 => 2.0 * ef_charset.h: The range of CS94SB_ID() is changed from 0x40-0x6f to 0x40-0x7e to handle drcs correctly. 2017-12-19 Araki Ken * vterm.c: Sixel graphics is supported with the use of sixel extension of DRCS of rlogin. * mlterm.[ch]: mlterm_final() is added. * vt_parser.c: Wrong new buffer size in write_loopback() is fixed. 2017-12-15 Araki Ken * README.ja: Updated. * java/Makefile.in: vtemu/mlterm.o is built. * mlterm.[ch], MLTermPty.c: Java_mlterm_MLTermPty_nativeOpen() in MLTermPty.c is separated to mlterm_open() in mlterm.[ch]. * ef_utf32_parser.c: Illegal access to uninitalized memory is fixed. * configure.in: libvterm/Makefile is generated. * Makefile.in: vterm, install-vterm and clean-vterm targets are added. * libvterm/*: Added. * vt_termcap.c: vt_termcap_special_key_to_seq() returns "\x1b" for SPKEY_ESCAPE. * vt_parser.[ch]: - write_loopback() changes behavior if pty is for libvterm or not. - vt_parser_set_use_multi_col_char() is removed. * ui_screen.c, vt_parser.c: OSC 5379/5380 of "use_multi_column_char" is processed in vt_parser.c instead of ui_screen.c. * vt_pty_ssh.c: vt_pty_ssh_keepalive() returns left time of keepalive. * version.h: 3.8.4 -> 3.8.4post 2017-12-02 Araki Ken * 3.8.4 released. (tag "rel-3_8_4") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.8.4. * PROTOCOL, man/mlterm.1: Updated. 2017-12-02 Araki Ken * ui_font_ft.c: ISCII and ISO10646_UCS4_1 fonts are forced to be treated as proportional. 2017-11-30 Araki Ken * doc/en/PROTOCOL, doc/en/README.fb, doc/ja/README.fb, README.ja: Updated. * vt_line.c: line->ctl_info.ot_layout->complex_shape and line->ctl_info.ot_layout->has_var_width_char are checked. * vt_ot_layout.[ch]: complex_shape and has_var_width_char are added to vt_ot_layout_state_t. * vt_shape.[ch]: IS_VAR_WIDTH_CHAR() is added. * hb.c: convert_text_to_glyphs() always sets glyph indexes in 'shaped'. * ui_screen.c: vt_line_unshape() is added before 'return 0' in draw_cursor(). * ui_draw_str.[ch]: ui_calculate_mlchar_width() -> ui_calculate_vtchar_width() 2017-11-26 Araki Ken * MLTermPty.c: vt_char_underline_style() and vt_char_is_crossed_out() => vt_char_line_style() * skk/dict.c: - set_blocking() -> set_nonblocking() - check_protocol_4() returns 0 if recv() returns error except EAGAIN. 2017-11-26 Araki Ken * vte.c: Return value type of vte_terminal_draw() is fixed. 2017-11-25 Araki Ken * quartz/ui_window.c, xlib/ui_window.c: ui_window_set_maximize_flag() supports MAXIMIZE_HORIZONTAL and MAXIMIZE_VERTICAL. * quartz/cocoa.[hm]: window_move_resize() is added. * fb/ui_window.c: ui_window_set_maximize_flag() calls ui_display_set_maximized() on wayland. * wayland/ui_display.[ch]: ui_display_set_maximized() is added. * ui_window.h, */ui_window.c: 'Window *child' is removed from arguments of ui_window_translate_coordinates(). * vte.c: vt_xterm_event_listener_t::xterm_resize is overridden by xterm_resize() in vte.c which supports MAXIMIZE_FULL and MAXIMIZE_RESTORE. 2017-11-23 Araki Ken * ui_draw_str.c: - LS_OVERLINE is processed. - is_crossed_out and underline_style are united to line_style. * ui_im_{status|candidate}_screen.c: Fixes of vt_char_set() and vt_char_combine() arguments. * inputmethod/*/*.c: Fixes of syms->vt_char_combine and syms->vt_char_set arguments. * vt_edit.[ch]: - 53 and 55 of 'attr' argument of vt_edit_change_attr_area() are processed. - Fixes of vt_char_set() arguments. * vt_parser.[ch]: - is_crossed_out is removed from vt_parser_t and vt_storage_states_t. - 'CSI 53 m' and 'CSI 55 m' are supported. * vt_char.[ch]: - vt_underline_style_t -> vt_line_style_t - LS_CROSSED_OUT and LS_OVERLINE are added to vt_line_style_t. - vt_char_underline_style() -> vt_char_line_style(). - is_crossed_out is removed from arguments of vt_char_set() and vt_char_combine(). - is_overlined is added to arguments of vt_char_{change|reverse}_attr(). - vt_char_cols() returns 0 (not 1) just before vt_char_init(). * fb/ui_imagelib.c: Minor fixes. * fb/ui_display.c: ui_cmap_get_pixel_rgb() returns 0 if specified pixel is TP_COLOR on x68k. * fb/ui.h: COLOR_CACHE_MINIMUM is defined. * c_sixel.c: color_indexes[color] is used instead of color if SIXEL_SHAREPALETTE is defined. * ef_charset.h: IS_ISO10646_UCS4 is moved from vt_char.h. 2017-11-21 Araki Ken * ui_screen.c, vt_parser.[ch]: - 'int flag' is added to arguments of vt_xterm_event_listener_t::resize(). - "CSI 9;P1 t" is supported. * ui_window.h, */ui_window.c: ui_window_set_maximize_flag() is added. * console/ui_display.c: HAVE_GETTIMEOFDAY is considered. * c_sixel.c, c_imagelib.c: SIXEL_SHAREPALETTE works if USE_GRF is defined. 2017-11-19 Araki Ken * doc/en/ControlSequences: Updated. * vt_parser.c: "CSI ? 8452 h" is always set on status line. 2017-11-18 Araki Ken * win32/ui_window.c: WM_SYSKEYDOWN event of VK_OEM_XXX keys are ignored. * im_skk.c: sticky_shift_key is separated to sticky_shift_ch and sticky_shift_ksym. * quartz/ui_event_source.c, quartz/ui_scrollbar.c: Compiling error is fixed. 2017-11-15 Araki Ken * fb/ui_window.c: max_glyph_width is limited to font_width - font_x_off in draw_string_intern(). * fb/ui_font.[ch]: - Compiling error is fixed. - ui_get_bitmap_width() and ui_get_bitmap_width_aa() are removed. 2017-11-14 Araki Ken * fb/ui_imagelib.c: - load_sixel_with_mask_from_file_1bpp() is enabled only if BUILTIN_SIXEL macro is defined. - load_file() tries load_sixel_from_data_sharepalette() if depth <= 8 and pic_mod is normal. * c_sixel.c: - load_sixel_from_data_sharepalette() is added if SIXEL_SHAREPALETTE macro is defined. - read_sixel_file() is added. * vt_parser.c: "#0;9;%d;%d;%d" instead of "#0;2;%d;%d;%d" is added to sixel sequences. 2017-11-12 Araki Ken * c_sixel.c: - Checking if width and height is changed is placed outside of realloc_pixels(). - The way of calculation of accessing address of 'pixels' array is changed. * ui_imagelib.c, vt_parser.c: Minor fixes. 2017-11-11 Araki Ken * skk/dict.c: dict_set_global() is fixed. * vt_edit.c: vt_edit_fill_area() applies bce fg/bg colors to a character to be filled. * vt_screen.[ch]: vt_screen_fill_area() is changed from a function to a wrapper macro of vt_edit_fill_area(). 2017-11-11 Araki Ken * vt_parser.c: Parameter of SL and SR is regarded as 1 if omitted. * vt_edit.c: - {copy|erase}_area() are used in vt_edit_scroll_{right|left}ward() instead of vt_edit_{copy|erase}_area(). - The third argument of erase_area() is fixed in vt_edit_scroll_leftward_from_cursor(). 2017-11-11 Araki Ken * vt_parser.c: DECSR is supported. 2017-11-10 Araki Ken * num_of_xxx -> num_xxx 2017-11-10 Araki Ken * vt_cursor.[ch]: Functions whose return values are not used return void. * vt_edit.[ch]: - horizontal_tabs() moves cursor downward if edit->wraparound_ready_line is set. - horizontal_tabs() checkes edit->hmargin_beg. - vt_edit_set_{h|v}margin() move cursor to the top-left corner. - vt_edit_set_use_hmargin() doesn't move cursor. * vt_screen.h, vt_parser.c: Minor fixes. 2017-11-05 Araki Ken * ui_im.h, ui_screen.c: write_to_status_line is added to ui_im_event_listener_t if DEBUG is defined. * vt_screen.c: change_edit() calls vt_set_modified_all() only if both current screen->edit and new edit aren't screen->status_edit. 2017-11-05 Araki Ken * vt_model.c: Whether vt_model_get_num_of_filled_rows == 0 or not is not checked in vt_model_resize(). 2017-11-05 Araki Ken * vt_edit.c: vt_edit_resize() moves cursor to the bottom line if cursor position is outside of the screen after resizing. * vt_model.c: vt_mode_get_num_of_filled_rows() uses vt_line_get_num_of_filled_chars_except_spaces() instead of vt_line_is_empty(). * im_skk.c: - cand_screen -> status_screen - start_candidate is added to struct im_skk. 2017-11-05 Araki Ken * vt_screen.c: change_edit() changes screen->main_edit correctly. * vt_parser.c: vt_set_pty_winsize() is called in processing DECSSDT. 2017-11-04 Araki Ken * ControlSequences: Updated. * MLTermPty.c: If vt_term_has_status_line() is true, window_scroll_upward_region() does nothing. * ui_picture.c: vt_term_get_rows() is placed before for(;;) instead of inside for(;;). * ui_screen.c: - screen_height() considers if status line is shown or not. - xterm_resize() converts 0 width or height to current width or height. - xterm_get_window_size() returns window size excluding status line. * vt_term.h: vt_term_has_status_line() is added. * vt_parser.c: - DECSSDT and DECSASD are supported. - "CSI 4 t", "CSI 8 t", "CSI 14 t" and "CSI 18 t" ignores the height of status line. - "CSI 4 t" and "CSI 8 t" allow omission of the third parameter. - CPR, XCPR and DECCIR reports relative position if DECOM is set. - DECSDM never considers DECOM. * vt_screen.c: - vt_screen_has_status_line(), vt_screen_set_use_status_line(), vt_status_line_is_focused(), vt_focus_status_line() and vt_focus_main_screen() are added. - Functions whose return values are not used return void. - vt_screen_cursor_logical_{col|row}() are addded, and vt_screen_cursor_relative_{col|row}() are removed. - vt_screen_resize(), vt_screen_cursor_row(), vt_screen_cursor_row_in_screen(), vt_screen_get_rows(), vt_screen_get_line() and vt_screen_get_line_in_screen() considers status line. - vt_get_logical_{cols|rows}() checks not only screen->logvis but also screen->logvis->is_visual. * vt_edit.[ch]: - Functions whose return values are not used return void. - vt_edit_cursor_logical_{col|row}() are added, and vt_cursor_relative_{col|row}() are removed. 2017-10-31 Araki Ken * ControlSequences, man/mlterm.1, README.ja: Updated. * mc_wordsep.c: ';' is replaced by '\x3b'. * mc_im.c: - "Dictionary" and "Sticky shift key" entries are added to skk options. - "Server" entry is added to wnn options. * mlconfig/main.c: USE_{XLIB|WIN32|QUARTZ} => strcmp(mc_get_gui(), "{xlib|win32|quartz}") * skk/dict.c: - 'static int is_loaded' (renamed to global_is_loaded) is reset in dict_set_global(). - dict_set_global() always closes global_sock. * im_skk.c: 'char *engine' of im_skk_new() arguments is renamed to 'options', and its format is changed from "[dictionary]" to "dict=[dictionary],sskey=[sticky shift key]". * im_wnn.c: "--im wnn:[server]" option is supported. * ui_im.[ch]: XStringToKeysym() is added to ui_im_export_syms. 2017-10-24 Araki Ken * ControlSequences: Updated. * vt_parser.c: DECRQTSR is fixed. 2017-10-23 Araki Ken * vt_parser.c: DECCIR, XCPR, DSR(Locator) and DECCKSR are fixed. 2017-10-22 Araki Ken * ControlSequences: Updated. * vt_parser.c: - "CSI 34 [hl]" is supported. - "CSI ? 9500 [hl]" is removed. * mc_opentype.c: - strcasestr() is replaced by ascii_strcasestr() which is originally implemented. - strcasecmp() is replaced by g_strcasecmp(). 2017-10-22 Araki Ken * java/Makefile.in: 'sort -r' is added in creating manifest.mf. * ef_ucs4_*.c: Code formatting. * vt_parser.[ch]: "CSI ? Pm [rs]" is supported. 2017-10-21 Araki Ken * vt_parser.[ch]: - DECBBSM(CSI ? 116 [hl]), DECRQTSR(CSI 2 $ u), DECCTR(CSI 2;Pu $ u), DECRQPSR(CSI $ w), DECSNLS(CSI * |), DECSTGLT(CSI ) {) and DECRSPS(DCS Ps $ t D...D ST) are supported. - If 1 bit flags of vt_parser_t is copied to int variable, intvalue = vt_parser->xxx ? 1 : 0. - DECRQSS supports DECSTGLT, DECSCPP, DECSLPP, DECSNLS, DECAC and DECATC. - Corrupt response of XCPR is fixed. - Corruption of TBC (CSI g), CTC (CSI W) and DECATC(CSI ,}) is fixed. - use_ansi_color is added to arguments of vt_parser_new(). - bold_affects_bg and use_ansi_color are added to vt_parser_t. - vt_set_use_ansi_colors() is removed. * vt_edit.[ch]: - vt_edit_is_tab_stop() is added. - vt_edit_set_{relative|absolute}_origin() => vt_edit_set_relative_origin(). * vt_color.[ch]: vt_color_force_linear_search() is added. * ui_main_config.[ch]: use_ansi_color is added to ui_main_config_t. * doc/en/ControlSequences: Added. 2017-10-14 Araki Ken * ui_brltty.c: bl_priv_change_e{u|g}id() are called if brlapi_openConnection() fails. 2017-10-12 Araki Ken * mc_click.[ch], mc_opentype.[ch]: Added. * mc_flags.[ch]: MC_FLAG_TRIMNEWLINE and MC_FLAG_BROADCAST are added. * mc_space.[ch]: MC_SPACE_BASELINE and MC_SPACE_UNDERLINE are added. * vt_term.c: "ot_features" and "ot_script" are added to OSC 5380 and 5381. * vt_ot_layout.[ch]: vt_get_ot_layout_attr() is added. * mlconfig/po/*.po: Updated. 2017-10-11 Araki Ken * fb/ui_font.c: "#include FT_OUTLINE_H" is added. * fb/ui_window.c: Compiling error is fixed. 2017-10-11 Araki Ken * ef_johab_conv.c, ui_main_config.c, man/mlterm.1: https://sf.net/p/mlterm/patches/_discuss/thread/f5dc445d/0fc3/attachment/fix_spelling.diff is merged. 2017-10-09 Araki Ken * doc/ja/README.ja: Updated. * main_loop.c: The return value of ui_screen_manager_init() is checked. * ui_screen.c: "click_interval" is added to OSC 5379, 5380 and 5381. * ui_font.h, */ui_font.c: - ui_font_t::cols member is removed. - ui_change_font_cols() is removed. * */ui_window.[ch]: ui_get_click_interval() is added. * ui_font_manager.[ch]: ui_set_use_multi_col_char() and ui_is_using_multi_col_char() are removed. * ui_font_cache.[ch]: - ui_font_cache_unload() reuses font_cache->usascii_font after failure of init_usascii_font(). - ui_font_cache_t::use_multi_col_char is removed. * ui_main_config.c: The default value of "use_vertical_cursor" option is changed from "false" to "true". * ui_sb_view_factory.[ch]: const modifier is added to 'name' argument of ui_{transparent_}sb_view_new() and ui_unload_scrollbar_view_lib(). * vt_parser.c: - DECSCPP and DECSLPP are supported. - "CSI [ 7 t" executes "update_all" of OSC 5379. * *.[ch]: Functions whose return values are not used return void. 2017-10-02 Araki Ken * doc/en/PROTOCOL: Updated. * ui_screen.c: - draw_cursor() checks if cursor position is outside of the screen or not. - report_mouse_tracking() considers vertical mode. - "use_vertical_cursor" is added to get_config_intern() and ui_screen_set_config(). * ui_window.c: - Whether glyph width exceeds ui_get_bitmap_width()/ui_get_bitmap_width_aa() or not is checked * fb/ui_font.h: - ui_get_bitmap_width() is renamed to ui_get_bitmap_width_aa(). - ui_get_bitmap_width() which is for not anti aliased fonts is added. * fb/ui_font.c: - width and width_full of XFontStruct have equal value if there is no full width glyph. - load_glyph() keeps face->glyph->format of FT_Load_Glyph(). - FT_Set_Transform() in load_ft() => FT_Outline_Set_Transform() in load_glyph() - is_rotated_char() returns 1 if ch is 0xff08-ff09, 0xff0d, 0xff1a-ff1e, 0xff3b, 0xff3d, 0xff5b-ff5e or 0xff62-0xff63. - is_right_aligned_char() is added. * ui_font.h: FONT_VERTICAL => FONT_VERT_RTL and FONT_VERT_LTR. * MLPreferenceActivity.java: - list.setValueIndex() is called in addList(). - "Vertical cursor" checkbox is added. * android/jni/ui_event_source.c: config_listener->set is called between pthread_mutex_{un}lock() in Java_mlterm_native_1activity_MLPreferenceActivity_setConfig(). 2017-09-28 Araki Ken * wayland/ui_display.c: 'capabilities' event of wl_seat_listener is handled. * ui_im_{status|candidate}_screen.c: ui_font_manager is newly created if terminal screen is vertical mode and USE_REAL_VERTICAL_FONT macro is defined. * fb/ui_font.c: - FONT_ROTATED is defined as (FONT_ITALIC << 1) internally and XFontStruct::format contains its bit. - load_glyph() rotates glyphs if format has FONT_ROTATED bit. - is_rotated_char() is added. - 'ch' which contains unicode code point is added to arguments of get_ft_bitmap_intern(). * */ui.h: USE_REAL_VERTICAL_FONT macro is added. * version.h: 3.8.3 -> 3.8.3post 2017-09-23 Araki Ken * 3.8.3 released. (tag "rel-3_8_3") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.8.3. * PROTOCOL, man/mlterm.1: Updated. 2017-09-22 Araki Ken * vt_parser.c: DECRQM reports SPKEY_BACKSPACE setting of vt_termcap_t instead of vt_parser_t::vtmode_flags for DECBKM. 2017-09-21 Araki Ken * vt_parser.c: - SHIFT_FLAG64 macro is added. - initial_vtmode_flags() is changed to INITIAL_VTMODE_FLAGS macro. - RIS(ESC c) moves cursor to the upper left. 2017-09-19 Araki Ken * vt_parser.[ch]: - VTMODE_20 macro and vt_parser_t::auto_cr are added to support LNM. - Cursor is moved to left-upper cell by DECOLM. - INITIAL_VTMODE_FLAGS macro is changed to initial_vtmode_flags() function to process 64bit shift properly. - soft_reset() resets options via set_vtmode(). 2017-09-18 Araki Ken * ui_screen.c: get_config_intern() supports "fontconfig" which dumps current font settings. * ui_font_manager.h: ui_font_manager_dump_font_config() is added. * ui_font_config.[ch]: - ui_get_all_config_font_names() => ui_get_config_font_names_all() - ui_font_config_dump() is added. * vt_char.[ch]: vt_get_unicode_area() is added. * vt_font.h: - FONT_WITHOUT_SIZE_ATTR() is removed. - HAS_UNICODE_AREA() => UNICODE_AREA() * MLActivity.java: String {resume|pause}Native() => void {resume|pause}Native() 2017-09-17 Araki Ken * ui_screen.c: Common processing in get_spot() and get_im_spot() is separated to get_spot_intern(). * console/ui_font.c, console/ui_window.c: - White spaces are inserted between ASCII characters in vertical mode. - scroll_region() can scroll screen leftward or rightward. * vt_term.c: NOT_CONVERT_TO_ISCII macro which is defined on console and cocoa disables CONVERT_UNICODE_TO_ISCII. * cocoa.m: - cand_x and cand_y which stores the initial position of preediting to determine the position of candidate window are added to MLTermView. - font->x_off is reflected in drawUnistr(). - ui_screen_t::is_preediting = 1 in preediting. * quartz/ui_font.c: font->x_off is set in vertical mode. * im_fcitx.c: Alt+Backspace => Alt+Control+h, Control+[ => Escape in key_event(). * */ui_display.c, fb/ui_display_*.c: Pressing alt key sets Mod1Mask instead of ModMask. * fb/ui_display_freebsd.c: XButtonEvent::button is set if event type is ButtonRelease. * wayland/ui_display.c: - "if (!display->buffer)" is added to ui_display_copy_lines(). - XButtonEvent::button is set if event type is ButtonRelease. * ui_im_{candidate|status}_screen.c: - ui_window_t::disp::display::parent is used to get size of the display on wayland. - "cand_screen->num_of_candidates > 0" is checked before calling draw_screen() in window_exposed(). * vt_logical_visual.c: Modified area conversion from logical to visual in vert_visual_intern() is fixed. 2017-09-12 Araki Ken * ui_im_candidate_screen.c: Unexpectedly wide candidate screen in vertical mode is fixed. * ui_im_status_screen.[ch]: - Calculating screen width is fixed. - head_indexes[11] => head_indexes[15] * im_fcitx.c: candidateword is splitted to multiple lines in update_client_side_ui(). * libtype/ui_font_ft.c: get_fc_col_width() never returns 0 if font->is_vertical is true on xft. * ui_screen_manager.c: width_pix and height_pix are modified by ui_screen_t::screen_width_ratio in open_pty_intern(). * ui_screen.[ch]: - ui_screen_t::{width|height} are added. - ui_screen_t::screen_width_ratio is removed. * vt_term.c: vt_term_open_pty() doesn't swap width_pix and height_pix in vertical mode. * fb/ui_font.c: Whether FT_LCD_FILTER_H is defined or not is checked. * mlconfig/main.c, mc_ratio.c: "Screen ratio against font size - Width" is removed. * ui_main_config.[ch], ui_screen.[ch]: --hscr / "screen_height_ratio" option is removed. 2017-09-09 Araki Ken * ui_font_config.c: size_attr of 'font' argument of ui_get_config_font_name() is removed. * vt_font.h: NO_SIZE_ATTR() macro is added. * quartz/ui_font.c: - is_bold and is_italic are added to arguments of parse_font_name(). - font->xfont->is_italic = 1 if (font->id & FONT_ITALIC) is true. * quartz/cocoa.m, quartz/ui.h: is_italic is added to XFontStruct, and if it is 1, glyphs are slant by CGAffineTransformMake(). * fb/ui_font.c: is_bold and is_italic are added to arguments of parse_fc_font_name() and if is_bold or is_italic is 1, FONT_BOLD or FONT_ITALIC is set. * main-cocoa.m: NSAutoreleasePool is allocated manually before NSApplicationMain(). 2017-09-08 Araki Ken * ui_im_status_screen.[ch]: - head_indexes[10] => head_indexes[11] - "\n" is not shown in a candidate window if the number of candidate lines is over MAX_ROWS. 2017-09-07 Araki Ken * im_wnn.c: Access to uninitialized memory is fixed. * ui_display_linux.c: /sys/class/input/event%d/device/name is prefered to /sys/class/input/input%d/name. 2017-09-06 Araki Ken * vte.c: Whether ui_customize_font_file() actually customizes font settings is checked before redrawing screen. * ui_font_config.c: change_custom_cache() and customize_font_name() return 0 if cached value and new value are the same. 2017-09-05 Araki Ken * ui_im_status_screen.c: max_width of draw_screen() is maximum width of all ui_display_t on wayland. * wayland/ui_display.c: - If keyboard_enter() is called in entering input method surface, it sets wlserv->current_kbd_surface to its parent surface instead of input method one. - x and y are removed from arugments of create_surface(), and ui_display_move() is called just after create_shm_buffer(). - focus_gtk_window() is not called if input method surface is clicked. * wayland/ui_window.c: - win->x and win->y of root windows aren't modified on wayland. * im_fcitx.c, im_ibus.c: - NO_XKB macro which is defined on framebuffer and console is added. - connection_handler() works on wayland. 2017-09-03 Araki Ken * im_m17nlib.c: XKeysymToString() is implemented. * im_fcitx.c: fcitx_client_set_cursor_rect() is called in connected(). 2017-09-02 Araki Ken * Makefile.in: vte, install-vte and clean-vte targets are added. 2017-09-02 Araki Ken * wayland/ui_font.c: The height of compl font is forcibly changed to the same one as base font. 2017-09-01 Araki Ken * wayland/ui_display.c: focus_gtk_window(win, time) is not called if ev.type is ButtonRelease. * wayland/ui_window.c: win->x and win->y are set to -1 in ui_window_unmap() to show scrollbars correctly on autohide scrollbar mode. * vte_wayland.c: - wl_surface_set_user_data(wl_surface, GdkWindow) is called in show_root() in order to make gdk to process events on mlterm surface as those on GdkWindow. - GdkCursor is set by gdk_window_set_cursor(). 2017-08-28 Araki Ken * vt_pty_ssh.c, vt_pty_pipewin32.c, im_iiimf.c: Not only "USER" but also "LOGNAME" environmental variable is used. ("USER" is not set on Solaris 11) 2017-08-27 Araki Ken * vt_pty_ssh.c: Data in vt_pty_ssh_t is kept after reconnection. 2017-08-26 Araki Ken * vte.c: - vte_terminal_search_set_regex() and vte_terminal_search_get_regex() are implemented. - 'GRegex* gregex' is added to VteRegex. - ui_screen_t::ui_sel_event_listener_t::select_in_window is overridden and overriding function calls g_signal_emit("selection-changed"). - deadline_ignoring_source_cancelled_event defined in wayland/ui_display.c is set to prevent ui_display_clear_selection() from being called by gtk_clipboard_set_text(). * ui_layout.c: - ui_screen_t::window::window_focused and ui_screen_t::xterm_listener::set_{window|icon}_name are overridden to show window title correctly in splitted screen. - If ui_screen_t or ui_scrollbar_t with a wall picture is moved but not resized in reset_layout() and MANAGE_SUB_WINDOWS_BY_MYSELF is not defined, ui_window_update_all() is called to redraw a wall picture. - HAS_MULTI_CHILDREN macro is added. * ui_screen.c: - ui_window_utf_selection_request() is called if ui_window_xct_selection_request() fails in yank_event_received(). - ui_get_selection_{conv|parser}() are used. - "next_pty", "prev_pty" and "close_screen" are added to OSC 5379. * xlib/ui_window.c: _NET_WM_NAME and _NET_ICON_NAME properties are supported. * win32/ui_window.c: - ui_window_set_wall_picture() in ui_window_unset_wall_picture() => ui_window_unset_wall_picture(). - 'name' argument of ui_set_{window|icon}_name() is converted to appropriate character encoding. * fb/ui_window.c: ui_window_xct_selection_request() returns 0 on android and wayland. * quartz/ui_window.c: - ui_window_set_wall_picture() in ui_window_unset_wall_picture() => ui_window_unset_wall_picture(). - ui_set_window_name() is implemented. * console/ui_window.c - If name is NULL, ui_window_t::app_name is used instead in ui_set_{window|icon}_name(). - 'name' argument of ui_set_{window|icon}_name() is converted to appropriate character encoding. * fb/ui_window.c: If name is NULL, ui_window_t::app_name is used instead in ui_set_{window|icon}_name(). * cocoa.[mh]: window_set_title() is added. * ui_selection_encoding.h, uitoolkit/*/ui_selection_encoding.c: These files are separated from ui_screen.c. * vt_parser.[ch]: "CSI > t" and "CSI > T" are supported. * vt_util.[ch]: These files are separated from vt_parser.c. * vt_char_encoding.c: The default value of "auto" is changed from unknown encoding to UTF-8. * jni/ui_event_source.c, MLActivity.java: "Next pty", "Previous pty" and "Close splitted screen" are added to context menu. 2017-08-13 Araki Ken * vt_termcap.[ch]: modify_function_keys and modify_cursor_keys are added to arguments of vt_termap_special_key_to_seq(). * vt_parser.[ch]: ModifyFunctionKeys and ModifyCursorKeys are supported. 2017-08-09 Araki Ken * man/mlterm.1, README.ja, etc/key, etc/main, etc/main.ja: Updated. * ui_main_config.[ch]: "broadcast" / --bc option and "ignore_broadcasted_chars" / --ibc option are added. * ui_screen.c: - write_to_pty() broadcasts chars to all ptys if vt_term_is_broadcasted() is true. - write_special_key() is added to wrap vt_term_write_special_key(). * vt_term.[ch]: vt_term_is_broadcasting() is added. * vt_parser.[ch]: - vt_set_broadcast() and vt_parser_is_broadcasting() are added. - "broadcast" and "ignore_broadcasted_chars" are added to OSC 5379 etc. 2017-08-02 Araki Ken * quartz/ui_display.c, win32/ui_display.c: Minor fixes. 2017-08-02 Araki Ken * quartz/ui_display.c: dialog() is implemented. * quartz/ui_connect_dialog.c: ui_connect_dialog() is implemented. * cocoa.[ch]: - cocoa_dialog_{password|okcancel|alert}() are added. - uitoolkit => uiwindow * main_loop.c: ignore_unknown_opt of bl_conf_parse_args() is 1 on MacOSX/Cocoa because "open -a /../mlterm.app" command passes "-psn_N_NNNNNN" option to mlterm. * main-cocoa.m: Arguments of main() is copied to global_args. * bl_dialog.[ch]: char* => const char* 2017-07-30 Araki Ken * vt_parser.h: is_vt52_mode is moved to the end of vt_parser_t. 2017-07-29 Araki Ken * wayland/ui_window.c: copy_blended_pixel() is fixed. * gtk/vte.c: - vte_terminal_set_colors() falls back to the default palettes if palette_size == 0. - vte_terminal_set_default_colors() is implemented. 2017-07-27 Araki Ken * fb/ui_font.c: Wrong processing of percentage in fontname is fixed. 2017-07-23 Araki Ken * man/mlterm.1, README.ja, PROTOCOL: Updated. * ui_screen.[ch]: - ui_set_trim_trailing_newline_in_pasting() which trims trailing newline in pasting text is added. - "trim_trailing_newline_in_pasting" is added to OSC 5379, 5380 etc. - shortcut_str() is called just after shortcut_match() in key_pressed(). * vt_screen.c: check_or_copy_region() doesn't append extra space at the end. * version.h: 3.8.2 -> 3.8.2post 2017-07-17 Araki Ken * 3.8.2 released. (tag "rel-3_8_2") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.8.2. * PROTOCOL, man/mlterm.1: Updated. * im_iiimf.c, im_uim.c, vte.c: Compiling error is fixed. 2017-07-15 Araki Ken * ui_main_config.c: If USE_FREETYPE is defined, "use_anti_alias" option works. * fb/ui_font.c: - FT_Library_SetLcdFilter() is called in load_ft(). - FONT_NOAA of ui_font_present_t is checked. * gtk/vte.c: - vte_terminal_hierarchy_changed() is moved to vte_x11.c - vte_terminal_draw(), vte_terminal_spawn_async(), vte_pty_spwan_async(), vte_terminal_{get|set}_allow_hyperlink and vte_terminal_hyperlink_check_event() are added. - Whether 'exception' is NULL or not is checked in vte_terminal_set_word_char_exceptions(). * gtk/vte_x11.c: FORCE_TRANSPARENCY macro is added. 2017-07-05 Araki Ken * main-con.c: It is assumed that mlterm-con-server is in BINDIR instead of LIBEXECDIR/mlterm on cygwin and msys. * bl_pty_helper.c, c_imagelib.c, c_regis.c, */ui_imagelib.c, vt_config_menu.c: BL_LIBEXECDIR is used. * bl_path.h: BL_LIBEXECDIR(suffix) is added. * ui_im_status_screen-cocoa.m: Compiling error is fixed. 2017-07-02 Araki Ken * ui_screen.c: in OSC 5379;:a=b works. * vt_parser.c: "challenge" of OSC 5380 works from console not only mlconfig. * accessories/mlsplit.sh: Added. 2017-06-29 Araki Ken * README*, man/mlterm.1: Updated. * configure.in: utmp is forcibly disabled on cygwin and mingw. 2017-06-25 Araki Ken * vt_edit.c: vt_edit_save_protected_chars() doesn't call malloc() until vt_char_is_protected() is true. * ui_font_ft.c: - Whether a name of a loaded font for iscii is *-TT* or not is checked, and if not, x_font_new() returns NULL. - cairo_font_open() removes FC_*LANG from font->pattern. * hb.c: - Characters are separated to segments and hb_shape() is called for each segment. - RTL scripts are supported. * ui_im.[ch], im_*.c, ui_im_{candidate|status}_screen.c, vt_parser.[ch]: Arguments of vt_convert_to_internal_ch() and ui_im_{candidate|status}_screen_new() are changed. * ef_ucs_property.table: Updated to Unicode 10.0.0 (UnicodeData.txt and EastAsianWidth.txt) 2017-06-21 Araki Ken * vt_edit.c: vt_edit_save_protected_chars() is optimized. 2017-06-21 Araki Ken * vt_screen.[ch], vt_term_manager.c, vt_parser.c: - vt_write_content_area_t is added. - 'area' is added to the argument of vt_screen_write_content(), and beg and end are removed. 2017-06-21 Araki Ken * ui_screen.c: UPDATE_SCREEN_BLINK is added to blink screen. * ui_draw_str.c: {fc|xcore}_draw_str() checks if fg_color == bg_color instead of vt_char_is_visible(). * vt_parser.[ch]: - get_now_suffix() is added and a file name of logging vt sequence and snapshot has "-YYYYMMDDHHMM" suffix. - is_protected is added to vt_parser_t, then DECSCA and selective erase are supported. - beg and end (row) are added to the arguments of snapshot(), then MC and DECMC are supported with the use of snapshot(). - is_invisible is added to vt_parser_t, then SGR 8 and 28 are supported. * vt_screen.[ch]: - is_protected is added to the arguments of vt_screen_fill_area(). - is_protected is added to the arguments of vt_screen_combine_with_prev_char(). - visible is removed from the arguments of vt_screen_blink(). - beg and end (row) are added to the arguments of vt_screen_write_content(). * vt_edit.[ch]: - vt_edit_{save|restore}_protected_chars() are added. - vt_edit_change_attr_area() processes SGR 3, 6, 9, 21, 23, 29. * vt_char.[ch]: - is_visible is removed and is_protected is added to vt_char_t::attr. - is_protected is added to the arguments of vt_char_set() and vt_char_combine(). - vt_char_{set|is}_visible() are removed. - vt_set_blink_chars_visible() is added. - vt_char_get_unicode_area_font() is renamed to vt_get_unicode_area_font(). - italic and crossed_out are added to the arguments of vt_char_change_attr() and vt_char_reverse_attr(). 2017-06-18 Araki Ken * vt_parser.c: Whether ps[0] < VTMODE(0) is checked in processing DECRQMH. 2017-06-18 Araki Ken * vt_parser.c: CSI?40h resizes screen as the value of DECCOLM. 2017-06-17 Araki Ken * vt_parser.[ch]: - DECATC is supported. - DECRQM and DECRQMH are supported and {set|get}_vtmode() functions and vtmode_t enum and so on are added. - SGR of DECRQSS is supported. * vt_logical_visual.c: 'count == 0' => 'count = 0' in vt_logical_visual_cursor_is_rtl(). * vt_screen.h: - vt_screen_is_using_bce() and vt_screen_is_using_rect_attr_select() are added. - vt_screen_set_use_bce() changes setting of vt_screen_t::alt_edit instead of vt_screen_::normal_edit. * vt_edit.h: vt_edit_is_using_bce() and vt_edit_is_using_rect_attr_select() are added. 2017-06-14 Araki Ken * xlib/ui_font.c: Fixes for DECDHL. * console/ui_window.c: size_attr is added to the arguments of set_attr() to support DECDHL and DECDWL. * console/ui_font.c: Unnecessary code is removed. 2017-06-12 Araki Ken * c_regis.c: Hack for MSYS is added. * ui_font.h, win32/ui.h, win32/ui_font.c: 'size' is moved from ui_font_t to XFontStruct on win32. * configure.in, baselib/configure.in: Whether it is msys-2.0 or not is checked. 2017-06-11 Araki Ken * README.win32: Updated. * libptyssh/vt_pty_ssh.c: connect_to_x11() is separated from x11_callback(). * win32/ui_display.c: CloseHandle(_disp.cursors[count]) is removed. 2017-06-07 Araki Ken * console/ui.h, win32/ui.h: "#include " is removed. * config.sub, config.guess: Updated. 2017-06-05 Araki Ken * wayland/ui_display.c: ui_display_t::selection_owner is set in add_root_to_display(). * gtk/Makefile.in: @BRLAPI_CFLAGS@ and @BRLAPI_LIBS@ are added. * vte.c: - vte_terminal_{set|get}_word_char_exceptions() is fixed. - ui_brltty_{init|final}() are called. 2017-06-04 Araki Ken * ui_brltty.c: BRLAPI_KEY_CMD_SAY_LINE, BRLAPI_KEY_CMD_SPEAK_CURR_LINE, BRLAPI_KEY_CMD_SAY_ABOVE, BRLAPI_KEY_CMD_SAY_BELOW are supported. 2017-06-04 Araki Ken * README, README.ja: Updated. * doc/en/README.brltty: Added. * main_loop.c, ui_screen.c: ui_brltty_* functions are called. * ui_brltty.c: Added. * configure.in: --enable-brlapi is added. * encodefilter/src/Makefile.in: MINOR is changed from 0 to 1. * mef.c: "utf32le" is added. * wayland/ui_display.c: - focus_gtk_window() is called in pointer_button(). - "xterm" style cursor is loaded in ui_display_init_wlserv(). * vte_wayland.c: focus_gtk_window() is added. * ui_screen_manager.c: DISPLAY environmental variable is set on wayland. * ef_utf32_conv.[ch]: ef_utf32le_conv_new() and ef_utf32_use_bom() are added. 2017-05-28 Araki Ken * ef_ucs_property.table: Updated to Unicode 9.0.0 (UnicodeData.txt and EastAsianWidth.txt) 2017-05-26 Araki Ken * README, README.ja, man/mlterm.1: Updated. * im_iiimf_aux.c: - The default value of AUX_BASE_DIR macro is changed from "/usr/lib/im" to "/usr/lib/iiim/le". - HTT_AUX_BASE_DIR environmental variable is added. * im_iiimf.c: - HTT_DISABLE_STATUS_WINDOW environmental variable is renamed to HTT_SHOW_STATUS_WINDOW. - IIIMCF_ATTR_CLIENT_X_DISPLAY_NAME is set on xlib. * im_iiimf.h: aux_* functions are disabled on platforms except xlib. * iiimf/Makefile.in: im_iiimf_aux.c is compiled on xlib alone. 2017-05-23 Araki Ken * vt_parser.c: - SGR 39 and 49 works if use_ansi_colors is false. - Unnecessary debug_print_unknown() is removed. * fb/ui_window.c: Freetype specific code is enclused by #if defined(USE_FREETYPE) ... #endif. * android/jni/ui_display.h: IM_WINDOW_IS_ACTIVATED() is added. 2017-05-21 Araki Ken * vt_parser.c: "ESC 2"(DECCAHT), "ESC 1"(DECCHTS), "ESC I"(HTJ), "CSI ? Pi;Pa;Pv S", "CSI Ps1;Ps2;Ps3 ,l"(DECAC) and "CSI W"(CBC) are implemented. * vt_edit.c: The starting position of erase_area() is fixed in vt_edit_scroll_{right|left}ward_from_cursor(). * ui_screen.c: baseline_offset option is disabled on console. * fb/ui_display.c: Busy loop where mlterm-fb on inactive console falls is fixed. * mlterm-con.c: mlterm-con works on Solaris11. * iiimf/keymap.c: keysyms which are undefined on framebuffer are enclosed by #ifdef ... #endif. * vte.c: OPEN_SCREEN, OPEN_PTY, NEXT_PTY, PREV_PTY, HSPLIT_SCREEN, VSPLIT_SCREEN, NEXT_SCREEN, CLOSE_SCREEN, HEXPAND_SCREEN, VEXPAND_SCREEN shortcut keys are disabled on libvte compatible library. * android/jni/ui.h: FORCE_UNICODE is undefined. 2017-05-18 Araki Ken * README.ja, man/mlterm.1: Updated. * ui_main_config.c: "baseline_offset" / --blpos option is added. * ui_screen.[ch]: - "baseline_offset" is added to OSC 5379 etc. - baseline_offset is added to arguments of ui_screen_new(). * ui_window.c: Chars except unicode are converted to unicode for freetype. * fb/ui_font.c: TrueType fonts are loaded for charsets except Unicode. 2017-05-17 Araki Ken * ui_screen.c: draw_cursor() selects appropriate position of cursor bar according to rtl or ltr attribute of a cursor character. * vt_term.h: vt_term_cursor_is_rtl() is added. * vt_screen.h: vt_screen_cursor_is_rtl() is added. * vt_logical_visual.[ch]: - If meet_pos_info & 0x8000000 is true, ctl_logical() forces a cursor character to be redrawn. - vt_logical_visual_cursor_is_rtl() is added. * vt_line_bidi.[ch], vt_line.[ch]: - vt_line_bidi_convert_logical_char_index_to_visual() doesn't check meeting position of rtl and ltr characters if meet_pos_info is NULL. - if meet_pos_info & 0x8000000 is true, cursor position is really adjusted according to metting position of rtl and ltr characters. 2017-05-14 Araki Ken * vt_parser.c: ESC $ ) is supported on utf8 encoding. * ef_iso2022kr_conv.c: iso2022_conv.g1 = KSC5601_1987 is added. * ef_iso2022jp_conv.c: iso2022_conv->g0 is replaced by ch.cs after convertion correctly finishes. * mef.c: "isciiroman" encoding is removed. 2017-05-14 Araki Ken * vt_pty_ssh.c: WSASocket() is called with WSA_FLAG_OVERLAPPED in _socketpair(). 2017-05-08 Araki Ken * ui_screen_manager.c, MLTermPty.c, vte.c: Calling vt_create_term() and ui_screen_new() is fixed. * ui_screen.[ch]: - blink_cursor is removed. - Underline cursor and bar cursor are supported. * vt_term.[ch]: vt_term_is_visible_cursor() and vt_term_get_cursor_style() are added. * vt_parser.[ch]: - vt_cursor_style_t is added and DECSCUSR(3,4,5,6) is supported. - is_visible_cursor is moved from vt_screen. - vt_parser_is_visible_cursor() and vt_parser_get_cursor_style() are added. - Processing "blink_cursor" of OSC 5379-5383 is moved from ui_screen.c 2017-05-07 Araki Ken * vt_parser.c: The response to DECRQDE is fixed. * uitoolkit/Makefile.in: Error in compiling winrs.rs is fixed. 2017-05-07 Araki Ken * keymap.c: XK_Kakji, XK_Muhenkan, XK_Henkan, XK_Hiragana, XK_Katakana and XK_Zenkaku_Hankaku are processed. * im_iimf.c: create_handle() searches unix domain socket files in /tmp/.iiim-$USER/. * vt_parser.c: - DECRQDE (CSI " v), NP(CSI U), PP(CSI V), PPA(CSI SP P), PPR(CSI SP Q) and PPB(CSI SP R) are processed. - DECCRA and DECLRP supports page. * ui_picture.c: cleanup_inline_pictures() checks term->screen->page_edits. * vt_screen.[ch]: - 'page_edits' is added to vt_screen_t. - vt_screen_is_alternative_edit() is changed from function to macro. - src_page and dst_page arguments are added to vt_screen_copy_area(). - vt_screen_get_page_id(), vt_screen_goto_page(), vt_screen_goto_next_page() and vt_screen_goto_prev_page() are added. 2017-05-05 Araki Ken * console/ui_font.c, ui_screen.c: line_space and letter_space options are ignored. * console/ui_window.c, fb/ui_window.c: ui_window_is_scrollable() returns 0 if IM_WINDOW_IS_ACTIVATED() (not IS_IM_WINDOW()) is true. * console/ui_display.[ch], fb/ui_display.[ch]: IM_WINDOW_IS_ACTIVATED() macro is added. * main/main-con.c, console/ui_display.c: If termios.c_cc[VERASE] is 0x7f, 0x7f character from stdin is converted to 0x08. * main/Makefile.in: LIBS2_{fb|console|wayland} variables are fixed. * iiimf/keymap.c, im_iiimf.h, im_iiimf_aux.c: Platforms except x11 are supported. * im_iiimf.c: - The timing of calling status_change() or stat_screen->delete() is fixed. - IIIMF_SERVER_ADDRESS environmental variable => HTT_SERVER_ADDRESS. * iiimf/Makefile.in: TARGET_{xlib|fb|console|wayland} are added. 2017-05-04 Araki Ken * quartz/ui_window.c, quartz/ui_font.[ch], quartz/ui.h, cocoa.m: ui_font_t::cg_font is moved to XFontStruct. * win32/ui_window.c, win32/ui_font.[ch], win32/ui.h, ui_font_cache.c: ui_font_t::fid and ui_font_t::conv are moved to XFontStruct. * xlib/ui_xim.c: Minor fixes. * xlib/ui_xic.c: XNArea is removed from XVaCreateNestedList(). * inputmethod/im_iimf.c: - IIIMF_ATTR_SERVER_ADDRESS and IIIMF_ATTR_SERVER_SERVICE attributes are set. - The value of IIIMF_SERVER_ADDRESS environmental variable replaces IIIMF_ATTR_SERVER_ADDRESS attribute. - status_change() is called in lookup_choice_done() and in IIIMCF_EVENT_TYPE_TRIGGER_NOTIFY case in dispatch(). * inputmethod/iiimf: Revived. * configure.in: --disable-iiimf option is added. * version.h: 3.8.1 -> 3.8.1post 2017-04-29 Araki Ken * 3.8.1 released. (tag "rel-3_8_1") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.8.1. * PROTOCOL, man/mlterm.1: Updated. * vte.c: screen->window.width and screen->window.height are updated even if VteTerminal is not realized. * wayland/ui_display.c: ui_display_move() stores x and y in display->{x,y} only if display->buffer is non-NULL. 2017-04-28 Araki Ken * README, gtk/README: Updated. * vte_wayland.c, vte.c: - vte_terminal_map() is added and registered to GTK_WIDGET_CLASS(vclass)->map. - ui_display_map() etc are removed from vte_terminal_focus_in(). * wayland/ui_color.c: The value of x_color_t::{red|green|blue} is not multiplied by alpha on wayland. * {wayland,fb}/ui_window.c, console/ui_window.c: Initialization of child->inputtable and child->is_focused in ui_window_add_child() is fixed. * wayland/ui_display.[ch]: - search_focused_window() searches windows in turn from children. - FocusOut macro is defined and ui_window_receive_event(FocusOut) instead of win->window_unfocused() is called in keyboard_leave(). - wl_subsurface_set_desync() is called in ui_display_map(), and wl_subsurface_set_sync() is called in ui_display_unmap(). * ui_color_cache.c: color_caches[count]->is_loaded => color_caches[count]->cache_256ext->is_loaded (This causes segmentation fault in using many colors by SGR 38;2;r;g;b or 48;2;r;g;b sequence) 2017-04-25 Araki Ken * README.ja, man/mlterm.1, PROTOCOL: Updated. 2017-04-24 Araki Ken * vt_pty_ssh.c: zombie() removes a zombie channel from ssh_session_t. 2017-04-24 Araki Ken * vte.c: gtk_m_adjustment_value_changed() => gtk_adjustment_value_changed(). * ui_font_ft.c: Double free problem by FcPatternDestroy() is fixed. 2017-04-23 Araki Ken * fb/ui_window.c: A bug which disabled ui_window_move() to move root windows is fixed. * fb/ui.h: Compiling error is fixed. * wayland/ui_display.c: The return value of ui_display_move is changed from void to int. 2017-04-23 Araki Ken * main_loop.c: Minor fixes. * fb/ui_font.c: Compiling error is fixed. 2017-04-23 Araki Ken * ui_window.c: draw_string() is separated to draw_string() and draw_string_intern() in order to show complementary glyphs. * ui.h, ui_font.h, ui_font.c: ui_get_bitmap() returns a complementary glyph in an alternative font if no glyph is found in a specified xfont. * main_loop.c, ui_font_config.c: ui_costomize_font_file() works if --aafont option is specified on framebuffer or wayland. 2017-04-16 Araki Ken * README, README.ja: Updated. * fb/ui_window.c: ui_window_move() does nothing for root windows except on wayland. * vte.c, vte_wayland.c: - toplevel_configure and hierachy_changed handlers are removed on wayland. - ui_display_map() is called from vte_terminal_focus_in() instead of vte_terminal_map() on wayland. - Focus and unfocus hacks are removed on wayland. - Dummy api functions related to VteRegex (0.46 or later) are added. * wayland/ui.h, wayland/ui_display.c: wl_subsurface instead of wl_shell_surface is used for libvte compatible library. * android/jni/ui.h: COMPOSE_DECSP_FONT is defined. 2017-03-28 Araki Ken * ui_display_linux.c: - 10 or larger number is availabe for event device (/dev/input/event*%d*) number. - "ts" is removed from mouse name list. * fb/ui_font.c, fb/ui_decsp_font.c: "decsp-%dx%d" of a composed decsp font is created in ui_font_new() instead of ui_load_decsp_xfont(). * */ui.h: COMPOSE_DECSP_FONT is added. 2017-03-25 Araki Ken * {wayland,fb}/ui_window.c: convert_to_decsp_font_index() is added. * {wayland,fb}/ui_font.c: - ui_compose_dec_special_font() is implemented. - If compose_dec_special_font is true, ui_load_decsp_xfont() is called. * {wayland,fb}/ui_decsp_font.[ch]: Added. * gtk/vte.c: If ui_wlserv_t::current_kbd_surface is Display::surface or Display::parent_surface, win->window_unfocused is forcibly called in vte_terminal_focus_out() on wayland. * wayland/ui.h, wayland/ui_display.c: Display::current_surface => current_kbd_surface. * console/ui_display.c: vt_char_encoding_conv_set_use_loose_rule(1) is called for disp->display->conv. * console/ui_connect_dialog.c: USE_COSNOLE => USE_CONSOLE * console/ui_window.[ch], ui_draw_str.c: ui_window_console_drwa_decsp_string() is added. * ui_screen.c: utf16le_illegal_char() which converts DEC Special to Unicode is added. * vt_char_encoding.[ch]: - vt_convert_ucs_to_decsp() and vt_convert_decsp_to_ucs() are moved from vt_parser.c - utf8_illegal_char which converts DEC Special to Unicode is added. - iso2022_illegal_char and non_iso2022_illegal_char aren't used by default and vt_char_encoding_conv_set_use_loose_rule() enables them. 2017-03-21 Araki Ken * doc/{en,ja}/README.fb: Updated. * ui_screen.c: draw_preedit_str() can have drawn cursor vertical line outside screen. * wayland/ui_font.c: ui_font_set_dpi_for_fc() is implemented. * gtk/Makefile.in: ui_display.o is rebuilt every time with -DCOMPAT_LIBVTE option. * wayland/ui_display.c: Functions for libvte compatible library are added. * gtk/vte.c: - wayland is supported. - vte.c is separated to vte.c, vte_xlib.c and vte_wayland.c. 2017-03-07 Araki Ken * wayland/ui_connect_dialog.c: Server name is shown before "Password:". 2017-03-07 Araki Ken * wayland/ui_connect_dialog.c: - ui_window_draw_image_string() is called every time. - ui_display_receive_next_event_singly() is called on wayland. * wayland/ui_display.[ch]: ui_display_receive_next_event_singly() is added. * main_loop.c: 'mlterm -v' outputs compiled features. * main/Makefile.in: CFLAGS_FOR_FEATURES is added. * configure.in: "Supported font formats" is output on wayland. * Makefile.in: 'install-wl' target is added. 2017-03-06 Araki Ken * wayland/ui_display.c: check_resize() returns 0 if the difference between specified width and height and current width and height is less than width_inc and height_inc. * doc/en/README.wayland: Added. * doc/en/README.fb: Updated. 2017-03-05 Araki Ken * wayland/ui_color.c: red, green and blue are multiplied by alpha before RGB_TO_PIXEL() on wayland. * wayland/ui_window.c: minor fixes. 2017-03-05 Araki Ken * wayland/ui_display.c: - Pointer at the center of top and bottom margin enables you to move the window instead of pressing Alt+Button1. - 'check_inc' argument (which is Display::is_resizing) is added to check_resize(). * ui_layout.c: - Rounding up 'separator' is prohibited if 'total < separator + margin + next_win' in modify_separator(). - MANAGE_SUB_WINDOWS_BY_MYSELF => MANAGE_ROOT_WINDOWS_BY_MYSELF in change_sb_mode_intern(). * ui_window.c: check_update_children() is added to redraw screen correctly on wayland. * */ui.h, ui_layout.c, wayland/ui_window.c: NO_EXPOSE_ON_RESIZE is removed. 2017-03-05 Araki Ken * ui_screen.c: ui_window_update_all(ui_screen_t) instead of ui_window_update_all(ui_layout_t) is called in window_resized(). * ui_main_config.c: ONLY_USE_UNICODE_FONT and ONLY_USE_UNICODE_BOXDRAW_FONT are set if ui_is_using_aafont() is true. * ui_layout.c: Even if a child window is not resized by resizing its parent, ui_window_update_all() is called in reset_layout on wayland. * wayland/ui_window.c: ui_window_update_all() is called at the end of ui_window_show() on wayland. Without this, screen isn't drawn in startup. 2017-03-05 Araki Ken * wayland/ui_display.c: ui_display_resize() calls wl_display_roundtrip() internally. * wayland/ui_window.c: ui_window_set_normal_hints() is implemented. 2017-03-05 Araki Ken * mc_im.c: get_im_info() is fixed. * ui_screen.c: - "use_aafont" is added to OSC 5380/5381. - ui_window_update_all(ui_layout_t) instead of ui_window_update_all(ui_screen_t) is called in window_resized(). * ui_font_config.[ch]: ui_is_using_aafont() is added. * mc_font.c: get_font_file() returns "*aafont" if use_aafont option is true. * wayland/ui_display.c: Minor fixes. 2017-03-04 Araki Ken * ui.h, ui_display.c: - During wl_shell_surface_resize(), Display::is_resizing is 1. This forces shell_surface_configure() not to modify specified width and height, and permits miximizing windows. - ui_display_receive_next_events() calls wl_display_dispatch() once per wl_display. * ui_main_config.c: The default value of "input_method" option is "ibus" on wayland. * ui_layout.c: x_window_resize_with_margin(scrollbar) is called before x_window_resize_with_margin(screen) in reset_layout(). 2017-03-04 Araki Ken * quartz/ui_window.c: - view_update() is called in ui_window_set_wall_picture() in order to update screen in changing a wall picture. - ui_window_draw_*_image_string() are removed. * fb/connect_dialog.c: - ui_window_get_str() is called in key_pressed(). - ui_window_console_draw_string() is called on console. * configure.in, inputmethod/*/Makefile.in: - {POBL|MEF}_LIBS_FOR_MODULE are replaced by LPOBL and LMEF * console/ui_window.c: - XK_BackSpace, XK_Tab and XK_Returns key events are correctly processed. - ui_window_draw_*_string() functions are removed. * main-con.c: - termios is reverted to the default value on exit(). - Whether read() returns -1 is not checked. * */ui.h, ui_draw_str.c, ui_picture.c: - DRAW_SCREEN_IN_PIXELS, NO_DRAW_IMAGE_STRING are added - HAVE_PTHREAD is defiend or undefined in ui.h instead of ui_picture.c. * ui_screen_manager.c: 'mlclient' is disabled on console, while 'mlclientx' is still available. * console/ui_connect_dialog.h: Added. 2017-03-03 Araki Ken * wayland/ui_display.c: Whether disp is NULL or not is checked in receive_key_event() which may be called after the surface is destroyed. * ui_font_manager.c: If US-ASCII font is not found, font loading is retried after calling ui_use_aafont(). * ui_font_config.[ch]: ui_use_aafont() is added. * fb/ui_font.[ch]: ui_font_use_fontconfig() is added. * mc_im.c: get_im_info() searches libim-foo-fb.so on framebuffer or console and libim-foo-wl.so on wayland. * mc_font.c, mc_io.[ch]: mc_gui_is_win32() is replaced by mc_get_gui(). * main_loop.c: --aafont / use_aafont option is added. * skk/dict.c, im_skk.c, ef_str_parser.c: The dependency on libmef library is removed. * configure.in: --enable-fontconfig option is enabled by default. 2017-02-28 Araki Ken * README.ja, README.fb: Updated. * wayland/ui_display.c: - ui_display_rotate() and ui_display_logical_to_physical_coordinates() are added. - wl_display_roundtrip() is called in auto_repeat(). * */ui.h: - XIM and XIMStyle are removed. - MANAGE_WINDOWS_BY_MYSELF => MANAGE_{ROOT|SUB}_WINDOWS_BY_MYSELF - NO_EXPOSE_ON_RESIZE, USE_GC, CHANGEABLE_CURSOR, PLUGIN_MODULE_SUFFIX, KEY_REPEAT_BY_MYSELF, ROTATABLE_DISPLAY, PSEUDO_COLOR_DISPLAY, WALL_PICTURE_SIXEL_REPLACES_SYSTEM_PALETTE, SUPPORT_URGENT_BELL, FORCE_UNICODE, NEED_DISPLAY_SYNC_EVERY_TIME are added. * main_loop.c, ui_display_wscons.c: wskbd_repeat_{1|N} => kbd_repeat_{1|N} * configure.in: --enable-fontconfig option is disabled by default. 2017-02-25 Araki Ken * */ui_display.c: The default value of ui_display_t::name is as follows. - DisplayString() on xlib - getenv("DISPLAY") or ":0.0" on other platforms. 2017-02-25 Araki Ken * wayland/ui_display.c: - Wheel mouse is supported. - Control+Button3 etc work. * ui_screen.c: NULL is passed to vt_term_start_config_menu() on wayland. * {console,fb,win32,cocoa}/ui_display.c: ui_display_t::name has always non-null value. * */ui.h: DisplayString() macro is removed. 2017-02-24 Araki Ken * ui_screen_manager.c, vte.c: main_config.underline_offset is added to arguments of ui_screen_new(). * ui_draw_str.[ch]: - bottom_margin is removed. - underline_offset is added. * ui_screen.[ch]: - ui_line_top_margin() -> line_top_margin() - ui_line_bottom_margin() is removed. - check_line_space() => modify_line_space_and_underline_offset(). - "underline_offset" is added to OSC 5379 etc. * ui_main_config.[ch]: --ulpos/underline_offset option is added. 2017-02-24 Araki Ken * README.ja, mlterm.1: Updated. * ui_screen.[ch], ui_main_config.[ch]: The type of line_space is changed from u_int8_t to int8_t. 2017-02-23 Araki Ken * console/ui_window.c: ui_window_{xct|utf}_selection_request() and ui_window_send_text_selection() are implemented. * console/ui_display.c: ui_display_{own|clear}_selection() enables copy&paste between different displays. * console/ui.h: XSelectionRequestEvent is defined as a structure. * fb/ui_window.c: ADDITIONAL_ARG is removed. * fb/ui_display.[ch], android/jni/ui_display.[ch], wayland/ui_display.[ch]: 'ui_display_t *disp' argument is added to ui_display_get_pixel(), ui_display_put_image() and ui_display_copy_lines(). 2017-02-20 Araki Ken * quartz/ui_window.c: If ui_window_is_selection_owner() is true, ui_window_set_selection_owner() does nothing. * fb/ui_window.c: - ui_display_clear_selection() is called in ui_window_final(). - ui_display_own_selection() is called in ui_window_set_selection_owner(). - ui_window_{utf|xct}_selection_request() works on framebuffer. * fb/ui.h: XSelectionRequestEvent is defined as a structure. * console/ui_window.c: - ui_display_clear_selection() is called in ui_window_final(). - ui_display_own_selection() is called in ui_window_set_selection_owner(). * android/jni/ui_display.c, console/ui_display.c, fb/ui_display.c: ui_display_own_selection() and ui_display_clear_selection() are implemented. * ui_window.h, ui_screen.c: - is_sel_owner is removed from ui_window_t on platforms except win32. - ui_window_is_selection_owner() is added. 2017-02-19 Araki Ken * *.[ch], *.[ch].in: 'type* var' => 'type *var' 2017-02-19 Araki Ken * wayland/ui.h, wayland/ui_display.c: DnD and Copy&Paste are supported. * ui_screen_manager.c: WAYLAND_DISPLAY environmental variable is set on wayland. * ui_screen.c: ui_window_update_all() is called instead of ui_window_update() in window_resized() on wayland because expose event is not delivered in resizing a window. * ui_im_{status|candidate}_screen.c: adjust_window_position_by_size() is disabled on wayland. * ui_event_source.c: additional_fds.handler() is called after ui_display_idling() because input method additional handler may destroy ui_display. * wayland/ui_window.c: - Wrong clipped area in draw_string() is fixed. - Stuff for wayland. * ui_imagelib.c: waitpid() is called to wait for child process to die because vt_pty_unix_new() may block without this. * ui_font_config.c: If USE_FONTCONFIG and USE_FREETYPE is enabled on wayland, "mlterm/*aafont" files are used. * ui_font.c: fontconfig is supported. * im_ibus.c, im_fcitx.c: - wayland is supported. - USE_IM_CANDIDATE_SCREEN macro is added. * ui_im.c: libim-xxx-wl.so is loaded on wayland. * inputmethod/*/Makefile.in: TARGET_wayland = libim-xxx-wl.la is added. * configure.in: - anti-alias is enabled by default. - --disable-fontconfig is added. 2017-02-06 Araki Ken * configure.in, mlterm-menu/Makefile.in, main/Makefile.in, tool/mlconfig/Makefile.in tool/mlimgloader/Makefile.in, uitoolkit/Makefile.in, fb/ui_window.c, ui.h, ui_display.h, ui_draw_str.c, ui_event_source.c, ui_font_config.c, ui_gc.h, ui_im.c, ui_main_config.c, ui_sb_view_factory.c, ui_window.h, wayland/*: Initial wayland support is added. * fb/ui_font.c: USE_FREETYPE macro check is added to ui_font_has_ot_layout_table(). 2017-02-05 Araki Ken * ui_event_source.c: 'break' in checking FD_ISSET(additional_fds) is removed. 2017-02-05 Araki Ken * android/jni/ui_display.c: rotate_display flag and related code are removed. 2017-02-05 Araki Ken * android/jni/ui_display.c: Minor fixes. * version.h.in: 3.8.0 -> 3.8.0post 2017-01-07 Araki Ken * 3.8.0 released. (tag "rel-3_8_0") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.8.0. * README, gtk/README: Updated. * libptyssh/vt_pty_ssh.c: zombie() calls vt_write_to_pty() instead lo_write_to_pty(). * MLTerm.java: display.isDisposed() is checked just before display.wake() in startPtyWatcher(). 2017-01-07 Araki Ken * libptyssh/vt_pty_ssh.c: bl_trigger_sig_child() is called if vt_pty_ssh_t::is_eof is true in lo_send_to_pty() instead of lo_write_to_pty(). 2017-01-03 Araki Ken * bl_pty_{bsd|streams}.c: termios.c_cc[VSTATUS] = CSTATUS. 2016-12-30 Araki Ken * ui_screen_manager.c: main_config.disp_name is passed to open_screen_intern() in mlclient(). 2016-12-29 Araki Ken * android/jni/ui_event_source.c: - Java_mlterm_native_1activity_MLActivity_{pause|resume}Native() which call ui_window_set_mapped_flag() are added. - ui_window_set_mapped_flag() are removed in Java_mlterm_native_1activity_MLPreferenceActivity_set{DefaultFontConfig|Config}(). * MLActivity.java: onResume() calls resumeNative(), and onPause() calls pauseNative(). * android/jni/ui_display.c: - get_jni_env() is added. - AttachCurrentThread()/DetachCurrentThread() is replaced by get_jni_env(). - if a specified window is not mapped, ui_window_set_mapped_flag(1) does nothing. * android/jni/ui_xic.c: AttachCurrentThread()/DetachCurrentThread() is replaced by GetEnv(). * ui_window.h: - saved_mapped is added to ui_window_t on Android. - xft_draw and cairo_draw are added to ui_window_t on xlib. * android/jni/main.c: android_main() calls AttachCurrentThread()/DetachCurrentThread(). * MLPreferenceActivity.java: 'private' is added to native methods. 2016-12-25 Araki Ken * xlib/ui_window.c: - ensure_input_focus() which calls XSetInputFocus() with a window whose 'inputtable' is greater than 0 is added. - ensure_input_focus() is called if a root window receives FocusIn event. * ui_font_ft.c: charset_cache is allocated dynamically. * vte.c, ui_screen_manager.c, cocoa.m: bl_dl_close_all() which frees leaked memory is called after bl_mem_free_all(). 2016-12-25 Araki Ken * jni/ui_event_source.c: - "mlclient --serv=" is allocated on stack in Java_mlterm_native_1activity_MLActivity_execCommand() - Java_mlterm_native_1activity_MLPreferenceActivity_setConfig() changes start_with_local_pty variable, not only saves it to ~/.mlterm/main. 2016-12-24 Araki Ken * ui_font_ft.c: FcCharSetDestroy(font->compl_fonts[count].charset) is removed. 2016-12-24 Araki Ken * ui_font_ft.c: - add_charset_to_cache() and get_cached_charset() are added to store FcCharSet. - FcConfigSubstitute() in cairo_compl_font_open() is removed. * MLActivity.java: - MENU_OPENPTY_ID => MENU_NEWSCREEN_ID - MENU_LOCALPTY_ID is added. - "Open new pty" => "Open new screen" - "Open local pty" is added to menu. * jni/ui_event_source.c: Java_mlterm_native_1activity_MLActivity_execCommand() supports opening local pty by "mlclientx --serv=" by cmd == 1. 2016-12-18 Araki Ken * ui_screen_manager.c: Uninitialized variables are fixed. 2016-12-13 Araki Ken * ui_event_source.c: Java_mlterm_native_1activity_MLActivity_execCommand() is added. * MLActivity.java: - "Open new pty", "Connect to SSH server", "Split screen vertically", "Split screen horizontally" and "Update screen" are added to context menu. - execCommand() native method is added. * vte.c: - Compatibility with vte 0.40.0 or later which dropped VteTerminalPrivate is supported. - vte_terminal_set_color_cursor_foreground() is added. - vte_terminal_set_geometry_hints_for_window() is implemented. 2016-12-11 Araki Ken * ui_main_config.c, ui_screen_manager.[ch], vt_term.[ch]: ui_set_start_with_local_pty() in ui_screen_manager.c is removed, and vt_term.c has 'start_with_local_pty' global variable. * ui_font_ft.c: Whether font->compl_fonts is NULL or not is checked in cairo_calculate_char_width(). * MLPreferenceActivity.java: "Don't show SSH dialog on startup" checkbox is added. * android/jni/ui_event_source.c: - XWINDOW_OF() => UIWINDOW_OF() - ui_window_set_mapped_flag(0) and ui_window_set_mapped_flag(1) are called in Java_mlterm_native_1activity_MLPreferenceActivity_setConfig() and Java_mlterm_native_1activity_MLPreferenceActivity_setDefaultFontConfig(). * android/jni/ui_display.[ch]: - Long click on scrollbar doesn't invoke context menu. - ui_window_set_mapped_flag() is added. - ui_window_set_mapped_flag(0) is called on APP_CMD_TERM_WINDOW, and ui_window_set_mapped_flag(1) is called on APP_CMD_INIT_WINDOW, and 2016-12-04 Araki Ken * README.android: Updated. * ui_font_config.c: mlcc font FOOBAR "" removes a font setting of FOOBAR specified in ~/.mlterm/*font. * main_loop.c, ui_main_config.c: The 6th argument (option explanation) of bl_conf_add_opt() is removed on Android, Cocoa or Win32GDI. * vt_pty_intern.h: vt_config_menu_write() sets android_config_response instead of write data to a configuration menu program on Android. * ui_event_source.c: - get_current_term() which searches currently focused vt_term is added. - Java_mlterm_native_1activity_MLPreferenceActivity_* are added. - 'android_config_response' global variable is added. * ui_display.c: init_window() ignores the difference between lock == -1 and lock == 0. * MLActivity.java: "Configuration" is added to context menu. * MLPreferenceActivity.java: Added. * AndroidManifest.xml: MLPreferenceActivity is added. 2016-11-14 Araki Ken * README.android: Updated. * ui_main_config.c: "start_with_local_pty" / --slp option is added only if USE_LIBSSH2 is defined on Android. * ui_screen_manager.[ch]: ui_set_start_with_local_pty() is added. * configure.in: - vt_cv_* -> ml_cv_* - -lfreetype is added to OT_LAYOUT_LIBS with -lharfbuzz on cygwin/win32gdi in order to avoid compiling error. * MLActivity.java: 'weight' argument is passed to LinearLayout.LayoutParams() in makeTextEntry(). 2016-11-12 Araki Ken * MLActivity.java: - Context menu by long click is supported. - Screen is completely redrawn in onResume(). * android/jni/ui_event_source.c: Java_mlterm_native_1activity_MLActivity_updateScreen() is added. * android/jni/ui_display.c: - process_mouse_event() considers LongClick event. - perform_long_click(), ui_display_update_all() is added. * android/jni/ui.h: long_press_counter is added to Display. 2016-11-06 Araki Ken * Android.mk, android/jni/main.c, android/jni/ui_display.[ch], android/jni/ui_connect_dialog.c, MLActivity.java: libssh2 is supported. * ui_screen_manager.c: clean up. * vt_pty_ssh.c: If user is NULL, getenv("USER") or getenv("USERNAME") is used to search a matched ssh session. * ui_main_config.c: --restart option is invalidated on Android. 2016-10-16 Araki Ken * *.[chm], *.java: Indentation settings for emacs are added to the head of files. * wnn/wnnlib.[ch], gtk/marshal.[ch], gtk/reaper.c, gtk/vtetypebuiltins.c, mlconfig/gtkxlfdsel.[ch]: Format of them is reverted to 3.7.2 2016-10-10 Araki Ken * uitoolkit/*/ui_window.c: x_window_t::button_released is called if ButtonPress event is received when x_window_t::button_is_pressing is true. * mlconfig/main.c: "Snapshot" button is added. * tool/mlclient/main.c: Help message is fixed. * tool/accessories/gedit.sh: Added. 2016-10-07 Araki Ken * ui_shortcut.c: Mod2 which is sent by pressing a button when num-lock is on is ignored. 2016-10-02 Araki Ken * man/mlclient.1: Updated. * ui_screen_manager.c: - mlclient() accepts --vsep and --hsep options. - retain_encoding and retain_server arguments are added to open_or_split_screen(). 2016-09-27 Araki Ken * vt_line.c: set_real_modified() is called in vt_line_unuse_ctl() for *_render(). 2016-09-24 Araki Ken * configure.in, vtemu/Makefile.in: libmlterm_core is renamed to libmlterm_coreotl if open type layout is supported. * doc/ja/README.ja, man/mlterm.1, etc/main, etc/main.ja: Updated * ui_main_config.c: "ssh_auto_reconnect" / --rcn option is added. * vt_pty_ssh.[ch], vt_pty.h, vt_pty_ssh.c: - Automatic reconnection to ssh server in unexpected disconnection is supported. - vt_pty_ssh_set_use_auto_reconnect() is added. 2016-09-04 Araki Ken * ui_layout.c: screen->window.[vh]margin * 2 is added to term->separator_[xy]. 2016-09-03 Araki Ken * ui.h: GUI_TYPE is added. * uitoolkit/*/ui.h, ui_screen.c: XIM_SPOT_IS_LINE_TOP is added. * vte.c: vte_terminal_event_check_gregex_simple() and vte_get_features() are implemented. 2016-08-29 Araki Ken * ef_tblfunc_loader.c: The names of dynamically Loaded modules are changed from libef_xxx.so to libmef_xxx.so. * ui_event_source.c, ui_picture.c: X_PROTOCOL -> USE_XLIB. 2016-08-29 Araki Ken * java/.java.policy: Added. * xwindow/ -> uitoolkit/ kiklib/ -> baselib/ mkf/ -> encodefilter/ mlterm/ -> vtemu/ libkik -> libpobl libmkf -> libmef * Google coding style is applied. 2016-08-21 Araki Ken * ml_pty_ssh.c: Compression of ssh connection is always enabled if libssh2-1.5.0 or later is used. 2016-08-18 Araki Ken * README.cosole, PROTOCOL: Updated. * main-con.c: termios is reset on exit. * version.h.in: 3.7.2 -> 3.7.2post 2016-08-15 Araki Ken * 3.7.2 released. (tag "rel-3_7_2") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.7.2. * doc/en/README.console: Added. 2016-08-14 Araki Ken * main_loop.c, x_main_config.c: "mod_meta_prefix" / --metaprefix option is processed in x_main_config.c instead of main_loop.c. * x_screen.[ch]: x_free_mod_meta_prefix() is added. * vte.c: "word_separators" / --sep and "auto_restart" / --restart options which are processed in x_main_config.c are removed. * hb.c: in win32gdi is changed to * android/jni/x.h: platform dependent options are added. 2016-08-11 Araki Ken * README.ja, man/mlterm.1: Updated. * x_main_config.c: "primary_da" / --da1 and "secondary_da" / --da2 options are added. * ml_vt100_parser.[ch]: - ml_set_{primary|secondary}_da() are added. - DA1 response is changed from CSI?1;2;3;4;7;29c to CSI?63;1;2;3;4;6;29c. - DA2 response is changed from CSI>1;279;0c to CSI>24;279;0c - DECRQSS is partially supported. * ml_edit.c: ml_edit_scroll_{up|down}ward() works if cursor position is not within vertical and horizontal margins. * mlterm/Makefile.in: Whether $libdir/libmlterm_core.so is built with open type layout option is checked before installing new libmlterm_core.so libraray. * main-con.c, console/x_display.c: #ifdef ECHOPRT is added. * x_window.c: Cursor is moved within vertical and horizontal margins before SD or SU. * configure.in: --with-gui=console works on cygwin. 2016-08-07 Araki Ken * x_window.h: clip_y and clip_height members of x_window_t are enabled on mlterm-con for input method plugins to work with both mlterm-fb and mlterm-con. * x_im_{candidate|status}_screen.c: MARGIN and LINE_SPACE are 0 on mlterm-con. * console/x_window.c: - IS_IM_WINDOW() macro is defined. - IS_IM_WINDOW() check is added to x_window_fill_with(). * fb/x_window.c: IS_IM_WINDOW() macro is defined. * console/x.h: - The previous change is reverted for input method plugins to work with both mlterm-fb and mlterm-con. - Values of key symbols on platformes except linux and *bsd are the same as those on freebsd. * configure.in: --with-gui=console works on cygwin. 2016-08-06 Araki Ken * console/x_window.c: If win->disp->width == win->width, x_window_is_scrollable() returns 1 even if win->disp->display->support_hmargin is 0. * x_display.h: x_display_set_sixel_colors() is defined as (0) if USE_LIBSIXEL is not defined. * console/x_display.c: The default value of Display::support_hmargin is changed from 1 to 0. * console/x.h: The values of keyboard symbols are defined as 0xff00-0xffff. * main/Makefile.in: mkdir $(LIBEXECDIR)/mlterm instead of $(LIBEXECDIR). 2016-08-06 Araki Ken * x_screen.c: ModifyOtherKeys on win32 gdi is fixed. * console/x.h, console/x_display.c, console/x_window.c: x_window_is_scrollale() is enabled only if the console where mlterm-con works supports DECSLRM and DECLRMM which is checked by DA2 response. * ml_vt100_parser.c: - DA2 response is changed from \x1b[>1;277;0c to \x1b[>1;279;0c. - Wrong processing of shift+space in ml_vt100_parser_write_modified_key() is fixed. 2016-07-30 Araki Ken * console/x_display.c: modifyOtherKeys is enabled by default. 2016-07-29 Araki Ken * c_imagelib.c, main_loop.c, gdk-pixbuf.c, x_color.h, x_color_cache.c, x_color_manager.c, x_display.h, x_draw_str.c, x_font.h, x_font_cache.c, x_font_cache.h, x_font_config.c, x_font_manager.c, x_font_manager.h, x_im_candidate_screen.c, x_im_status_screen.c, x_imagelib.h, x_layout.c, x_main_config.c, x_picture.h, x_screen.c, x_window.h, xlib/x_imagelib.c: USE_WIN32GUI, USE_QUARTZ, USE_FRAMEBUFFER and USE_CONSOLE are refactored. * console/x.h, fb/x.h, quartz/x.h, win32/x.h: Platform dependent options (X_COLOR_HAS_RGB, SUPPORT_TRUE_TRANSPARENT_BG, TYPE_XCORE_SCALABLE, MANAGE_WINDOWS_BY_MYSELF, INLINE_PICTURE_MOVABLE_BETWEEN_DISPLAYS, SUPPORT_POINT_SIZE_FONT) are added. * xlib/x.h: Added. * x.h: USE_XLIB is defined on xlib. 2016-07-26 Araki Ken * man/mlterm.1, README.ja, PROTOCOL: Updated. * main_loop.c: If no ml_term_t exists, mlterm-con-server exits from the main loop. * main/main-con.c: - Moved from tool/mlclient/. - mlterm-con-server is started if unix domain socket of ~/.mlterm/socket-con doesn't work. * main/Makefile.in: mlterm-con-server is installed to $(libexec)/mlterm, and mlterm-con is to $(bindir)/mlterm. * im_fcitx.c, im_ibus.c, im_m17nlib.c, im_uim.c: USE_FRAMEBUFFER -> USE_FRAMEBUFFER || USE_CONSOLE * x_screen.c: "console_encoding" and "console_sixel_colors" are added to OSC 5379. * x_main_config.c: --csz/cell_size option is added. * x_draw_str.c, x_picture.h: If INLINE_PICTURE_MOVABLE_BETWEEN_DISPLAYS macro is defined, cur_pic->disp == window->disp is not checked. * daemon.c: - client_connected() for mlterm-con-server is moved from console/x_display.c - STD{IN|OUT|ERR}_FILENO are closed in daemon_init(). * console/x_window.c: - x_window_fill_with() do nothing if height or width is less than LINE_HEIGHT or COL_WIDTH, - UTF16 characters are converted to UTF8 in draw_string(). - Creating sixel_{output|dither}_t and calling sixel_encode() are moved to x_display.c. * console/x_display.[ch]: - x_display_set_default_cell_size() is added. - ShiftMask is set if 'A' - 'Z' character is received. - start_server() and end_server() are removed. - client_connected() is moved to daemon.c. - x_picture_display_closed() is not called in x_display_close(). - "x_display_t * disp" is added to arguments of x_display_set_char_encoding(). - x_display_set_sixel_colors() and x_display_output_picture() are added. * console/x.h: sixel_output and sixel_dither are added to Display. 2016-07-18 Araki Ken * x_screen_manager.c: open_screen_intern() uses layout->window.disp instead of calling x_display_open() if layout is not NULL. * man/mlterm.1, doc/ja/README.ja, etc/main, etc/main.ja: Updated. * x_font_manager.c: The type of returned value of adjust_font_size() is changed from void to int. * x_main_config.c: mlterm-con accepts -d option. * console/x_display.c: - Server mode via unix domai socket of ~/.mlterm/socket-con is supported. - Multiple displays are managed. * mlclient/main-con.c, mlclient/Makefile, mlclient/Makefile.in: mlclient-con is added. 2016-07-09 Araki Ken * cocoa.m: A patch at http://the.nyarla.net/entry/2016/06/03/195013 is merged. (Wheel mouse is supported.) * x_window_cairo.c: x_font_t::x_off is ignored in drawing text with the use of complementary fonts. * x_font_ft.c: Loading complementary fonts is moved from x_window_cairo.c to x_font_ft.c, and named as x_search_next_cairo_font(). * main.c: ml_set_timeout_read_pty(0xffff) on NetBSD or OpenBSD framebuffer. * ml_vt100_parser.[ch]: - ml_set_timeout_read_pty() is added. - USE_FRAMEBUFFER macro is removed. - snapshot() is rewritten with the use of ml_screen_write_content(). * mlterm/Makefile.in: @GUI_CFLAGS@ is removed. * ml_term_manager.c: ml_term_write_content() is called in restarting mlterm in segv etc. * ml_term.h: ml_term_write_content() is added. * ml_screen.[ch]: ml_screen_write_content() is added. * inputmethod/*/Makefile.in: TARGET_console is added. * configure.in: - "console" is added to --with-gui option. - --disable-skk is revived. * x_layout.c: SEPARATOR_WIDTH => SEPARATOR_WIDTH and SEPARATOR_HEIGHT. * x_draw_str.c: If USE_CONSOLE is defined, text is drawn by x_window_console_draw_string*(). * x_window.h, console/x_window.c: x_window_console_draw_string*() which receive a flag to draw underline are added. * x_main_config.c: --ckm, console_encoding option is added. * x_display.h, console/x_display.c: x_display_set_char_encoding() is added. * xwindow/x.h: console/x.h is included if USE_CONSOLE is defined. * xwindow/console: Added. * version.h.in: 3.7.0 -> 3.7.0post 2016-05-08 Araki Ken * 3.7.1 released. (tag "rel-3_7_1") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.7.1. * man/mlterm.1, doc/en/PROTOCOL: Updated. 2016-05-08 Araki Ken * im_wnn.c: Shortcut in inserting 'n' is added. * im_skk.c: The color of converting text in editing a new word is reversed. 2016-05-07 Araki Ken * dict.c: "\r\n" is supported. * im_skk.c: Shortcut in inserting 'n' is added. * quartz/x.h: NSBackTabCharacter is assigned to XK_ISO_Left_Tab. 2016-05-06 Araki Ken * im_skk.c: - im_skk_t::mode is backed up and restored before and after editing a new word. - Text on a status window is correctly updated. * dict.c: - The timing of loading global dictionary is fixed. - Uninitialized variable ('num') is fixed. 2016-05-05 Araki Ken * im_skk.c, dict.[ch]: Cleanup. 2016-05-05 Araki Ken * im_skk.c, dict.c: - 'back' argument of dict_completion() is changed to 'step' which designates how many steps to go to a next caption. - dict_completion_reset() -> dict_completion_reset_and_finish(). 2016-05-05 Araki Ken * dict.c: Whether skk server supports "4xxx \n" protocol or not is checked. * im_skk.c, dict.c: Completion is supported. * ml_vt100_parser.c: vt100_parser->yeild = 0 (specific to framebuffer) at the end of parse_vt100_parser() is removed. 2016-05-04 Araki Ken * x_im_status_screen.c, win32/x_window.c: Hack for win32gdi is moved from x_im_status_screen.c to win32/x_window.c * x_im_status_screen-cocoa.m: Status screen is shown before calling x_im_status_screen_t::show(). 2016-05-04 Araki Ken * im_skk.c: - Direct input triggered by 'l' key is available in editing a word to be newly registerd. - Status window is shown while skk is enabled. - Full width alphabets input triggerd by 'L' is available. - (concat "...") is partially available. - It is possible to register a new word containing '/' and ';'. * hb.c: Compiling error is fixed. * configure.in: hb-coretext.h is checked on MacOSX/Cocoa. 2016-05-01 Araki Ken * im_skk.c: Ctrl+g resets preediting states. 2016-05-01 Araki Ken * im_skk.c: Wrong parsing of comment string staring with ';' is fixed. * skk/dict.c: winsock is supported. * configure.in: skk is enabled on win32gdi without cygwin. * x_window_cairo.c: A bug which dropped almost all glyph complementary fonts is fixed. 2016-05-01 Araki Ken * quartz/x_im_status_screen-cocoa.m: Added for input method plugin. * quartz/x_window.c: x_window_translate_coordinates() is implemented by using window_get_position(). * cocoa.[hm]: - window_get_position() is added. - NSShiftMask isn't ignored in insertText(). - x_display_t::width and x_display_t::height are set in viewDidMoveToWindow. * im_skk.c, im_wnn.c: dha dhi dhu dhe and dho are supported. * skk/dict.c: input_method option accepts whether skk dictionary or skk server uses utf8 instead of eucjp. (e.g. --im skk:localhost:utf8) * wnn/Makefile.in, canna/Makefile.in, skk/Makefile.in: TARGET_quartz is added. * configure.in: skk, wnn and canna are available on MacOSX/Cocoa. * configure.in, ml_char.c: Fix https://github.com/saitoha/homebrew-sixel/pull/2 (Merge https://bitbucket.org/arakiken/mlterm/pull-requests/2/ml_charc-strip-the-dependency-of with some fixes.) * README, doc/ja/README.ja: Updated. 2016-04-28 Araki Ken * skk/dict.[ch], skk/mkf_str_parser.[ch]: Added. * im_skk.c: Many bugs are fixed. 2016-04-21 Araki Ken * im_skk.c: ~/.skk-jisyo is loaded. * kik_conf_io.c: Regular files whose names begin with "." in the home directory aren't checked if they should exit in ~/.config/ or not. 2016-04-18 Araki Ken * inputmethod/skk: Added. * im_wnn.c: Minor fixes. * x_im_status_screen.c: Incorrect redrawing on win32gdi is fixed. * configure.in: skk is enabled by default. 2016-04-10 Araki Ken * x_screen.c: The change of 1611 commit is reverted. * ml_vt100_parser.c: 0.01 sec interval is used for the limit of reading bytes in ml_parse_vt100_sequence() instead of MAX_READ_COUNT. * ml_line.c: Fix https://sourceforge.net/p/mlterm/mailman/message/34992704/. * man/mlterm.1: U+XXXX-XXXX in ~/.mlterm/*font is documented. * kik_pty_{bsd|stream}.c: If B38400 is defined, B38400 is used instead of B9600. 2016-04-03 Araki Ken * man/mlterm.1: Updated. 2016-03-23 Araki Ken * x_im_candidate_screen.c: The number of drawing candidate window is decreased. * x_im_status_screen.c: Minor fixes. * im_wnn.c: - "[N/N]" is shown after preediting text. - Candidate number is shown in candidate window. - CAND_WINDOW_ROWS(==5) is defined. 2016-03-19 Araki Ken * registobmp/Makefile.in: Changeset 2562 commit (-lm is removed) is reverted. * ml_vt100_parser.c: "vt_color_mode" is added to OSC 5380 and 5381. * ml_color.[ch]: ml_get_color_mode() is added. * vte.c: Font size specified after font family in the 2nd argument of vte_terminal_set_font_from_string() is applied to "fontsize" option. * version.h.in: 3.7.0 -> 3.7.0post 2016-03-13 Araki Ken * 3.7.0 released. (tag "rel-3_7_0") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.7.0. * etc/main, etc/main.ja: Updated. * fb/x_color.c, fb/x_display.c: The type of the first argument of x_cmap_get_closest_color() is reverted from u_int to u_long. 2016-03-12 Araki Ken * mlfc/main.c: 'mlfc -h' shows usage message. * MLTerm.java: The size of color palette is changed from 258 to 512. * MLTermPty.c: If a previous character is not converted to UTF-16, NULL is passed to the 2nd argument of need_style(). * ml_color.c: If current value is overwritten by specifying the same value as the default rgb, color_config_set_rgb() erases the current one. * x_screen.c: Not only "USASCII" but also "US_ASCII" and "US-ASCII" are available for {set|get}_font_config(). 2016-03-11 Araki Ken * README.ja, man/mlterm.1: Updated. * ml_vt100_parser.c, x_main_config.c: "use_approximate_vt_color" is changed to "vt_color_mode" * ml_color.c: - 'threshold' is added to arguments of ml_get_closest_256_colors(). - ml_set_use_approximate_vt_color() -> ml_set_color_mode() 2016-03-11 Araki Ken * x_main_config.c: "use_approximate_vt_color" option is added. * fb/x_display.c: The performance of x_cmap_get_closest_color() is improved by using ml_get_closest_256_color(). * ml_color.c: - ml_set_use_approximate_vt_color() is added. - ml_get_closest_256_color() is added. - The performance of ml_get_closest_color() is improved by using ml_get_closest_256_color(). * ml_vt100_parser.c: - Whether ps is -1 or not is checked before calling ml_get_closest_color(). - "use_approximate_vt_color" is added to OSC 5379. * c_imagelib.c, fb/x_display.c, ml_color.c: The variable type of holding distance of colors in searching approximate color is changed from u_long to u_int. 2016-03-06 Araki Ken * x_color_cache.[ch]: x_color_cache_256_t -> xc_olor_cache_256ext_t which contains extended colors. * x_color.h: The type of pixel is changed from u_long to u_int32_t in x_color_t. * ml_color.[ch]: - 0x100-0x1ef is used to allocate 24bit colors. (Named as "extended colors") - 0x100-0x106 (ML_FG_COLOR-ML_CROSSED_OUT_COLOR) is moved to 0x1f0-0x1f6. - MAX_256_COLORS, MAX_EXT_COLORS, MAX_256EXT_COLORS, IS_EXT_COLOR(), IS_256EXT_COLOR(), EXT_COLOR_TO_INDEX(), INDEX_TO_EXT_COLORS(), COLOR_DISTANCE() and COLOR_DISTANCE_THRESHOLD macros are added. - ml_ext_color_is_changed() is added. - ml_get_closest_color() and ml_get_color_rgba() consider extended colors. - IS_VALID_COLOR_EXCEPT_FG_BG() is renamed to IS_VALID_COLOR_EXCEPT_SPECIAL_COLORS(). * kik_map.h: - The number of searching is decreased. - MAP_MARGIN_SIZE macro is newly defined. * kik_map.c: Minor fixes of test code. 2016-03-05 Araki Ken * x_screen.c: 'mlcc font USASCII ' is available. * x_font_config.c: Unnecessary kik_str_alloca_dup() is removed. * quartz/x_imagelib.c: If gif file path is ~/.mlterm/anim*, split_animation_gif() is not called. * quartz/x_font.c: x_font_t::ot_font_not_found is checked in x_font_has_ot_layout_table(). * kik_mem.c: Illegal access to unallocated memory in kik_mem_free_all() is fixed. 2016-03-03 Araki Ken * quartz/cocoa.m: [NSRunLoop runUntilDate] is called if huge data is received or screen is blanked temporarily by visual bell. * mlfc/Makefile.in: Install directory is fixed. 2016-03-01 Araki Ken * configure.in: Not only but also is checked not to enable USE_GRF on NetBSD/macppc. 2016-02-28 Araki Ken * quartz/x_window.c: x_window_set_normal_hints() is fixed. * quartz/x_imagelib.c: animation gif is supported. * ml_vt100_parser.c: SUPPORT_ITERM2_OSC1337 is enabled by default. * main.c: _fmode = _O_BINARY on win32. 2016-02-26 Araki Ken * README.fontproto, README.ja, man/mlterm.1: Updated. * mc_font.c: "UNICODE (Hebrew)", "UNICODE (Hindi)", "UNICODE (Bengali)", "UNICODE (Punjabi)", "UNICODE (Gujarati)", "UNICODE (Oriya)", "UNICODE (Tamil)", "UNICODE (Telugu)", "UNICODE (Kannada)" and "UNICODE (Malayalam)" are added. * mc_io.[ch]: font_size is removed from arguments of mc_{set|get}_font_name(). * ml_vt100_parser.[ch]: - font_size is removed from arguments of ml_config_event_listener_t::get_font. - CSI?12h and CSI?12l (XT_CBLINK) are dropped. * x_window_cairo.c: Alias font names are considered in searching glyph complementary fonts. * x_font_ft.c: - The format of cairo or xft font name is changed as follows. [Family] [Weight] [Slant] [Size]-[Encoding]:[Percentage] ->[Family] [Weight] [Slant] [Size]:[Percentage] - It is not necessary to escape '-' by '\' in font name. * x_font_config.[ch]: - The format of value of ~/.mlterm/*font is changed as follows. [Font name];[Size],[Font name];[Size],[Font name];... -> [Font name] - x_customize_font_name() and x_customize_default_font_name() are removed. * x_main_config.c, x_font_manager.c: Whether font_size is within font_size_range is checked in x_font_manager.c, not in x_main_config.c. * x_font_cache.c, x_font_config.c, x_font_manager.c: {min|max}_font_size static variables and x_set_font_size_range() are moved from x_font_config.c to x_font_manager.c. * ml_termcap.c: - Illegal memory access around db on memory for MacOSX/Cocoa and Android is fixed. - DB on memory isn't used on MacOSX/Cocoa. * ml_char.c: unicode_area_{max|min} static variables are added. * configure.in: mlfc is added to the default value of --with-tools option. * tool/mlfc: Added. * cocoa.m: If x_get_all_screens(NULL) has already returned 0 before willClose() is called, nothing except calling [NSNotificationCenter removeObserver] is done. * cocoa.[hm], quartz/x_window.c: view_set_normal_hints() is changed to window_set_normal_hints(), because x_window_set_normal_hints(root window whose my_window is NSWindow*) calls window_set_normal_hints(NSWindow). * main-cocoa.m: [[NBundle mainBundle] bundlePath] is passed to kik_set_sys_conf_dir(). * cocoa/install.sh: etc/* files are installed to mlterm.app bundle. * otl.h: Syntax error is fixed. * ml_char_encoding.c, kik_conf_io.c: Minor fixes. * version.h.in: 3.6.3 -> 3.6.3post 2016-02-14 Araki Ken * 3.6.3 released. (tag "rel-3_6_3") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.6.3. * ml_ot_layout.c: ucs_filled++ is moved outside of ml_is_rtl_char() which may be replaced by (0). 2016-02-14 Araki Ken * README, README.ja: Updated. * libotl/Makefile.in: LKIK=${top_builddir}/kiklib/src/libkik.la -> LKIK=@LKIK@ * configure.in: If --enable-anti-alias isn't specified, open type layout is disabled on framebuffer. 2016-02-13 Araki Ken * 3.6.2 released. (tag "rel-3_6_2") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.6.2. * README, doc/ja/README.ja: Updated. * configure.in: --disable-otl is added. 2016-02-11 Araki Ken * README.indic: Updated. * ml_vt100_parser.c: fopen/fclose/fwrite are replaced by cygfopen/cygfclose/cygfwrite defined in cygfile.[ch]. * mlterm/cygfile.[ch]: Added. * kik_dlfcn_win32.c, gdiplus.cpp, gdk-pixbuf.c, mlimgloader/none.c, win32/x_dnd.c, win32/x_imagelib.c: cygwin_conv_to_{win32|posix}_path() -> kik_conv_to_{win32|posix}_path(). * kik_path.[ch]: kik_conv_to_{win32|posix}_path is added. * x_screen.c: x_stop_selecting() is called in button_released() even if mouse reporting mode is set. * fb/x_font.c, libtype/x_window_{cairo|xft}.c, cocoa.m, quartz/x_font.c, win32/x_font.c, xlib/x_font.c: #ifdef USE_OT_LAYOUT ... #endif is inserted. * configure.in: `pkg-config freetype2 --cflags` is added to OT_LAYOUT_CFLAGS with harfbuzz on platforms except MacOSX/Cocoa. * prepare.sh: Files in xwindow/libotl are copied. * Android.mk: - OTF_* -> OTL_* - -Ixwindow/libotl and -DNO_DYNAMIC_LOAD_OTL are added to OTL_CFLAGS. 2016-02-10 Araki Ken * README.ja: Updated, * x_font.h, quartz/x_font.c: pointsize -> size. * x_main_config.[ch]: use_ot_layout is added to x_main_config_t. * x_screen.c: use_ot_layout is added to arguments of change_ctl_flag(). * x_draw_str.c: If xfont->use_ot_layout is true on win32gdi, x_window_draw_image_string() variant functions are not used. * win32/x_font.c: - ISO10646_UCS4_1_V is added to wincs_info_table. - is_ucs is added to arguments of text_out(). - x_calculate_char_width() returns 0 if calculate_char_width() returns 0. * otf.c, win32/x_font.c: free(obj) is called in otl_open(), not in x_font_has_ot_layout_table(). * hb.c: Fixes for win32gdi. * ml_line.[ch]: - ml_set_use_ot_layout() and ml_is_using_ot_layout() are removed. - Opentype layout is enabled if 'term' argument of ml_line_ctl_render() is non-NULL value. * ml_term.[ch]: - ml_term_set_use_ctl() is defined as a macro, not as a function. - ml_term_set_use_ot_layout() and ml_term_is_using_ot_layout() are added. - use_ot_layout is added to ml_term_t. * ml_term.c, ml_vt100_parser.c: "use_ot_layout", "ot_script" and "ot_features" of OSC 5379-5381 are moved from ml_vt100_parser.c. * ml_term.[ch], ml_term_manager.[ch]: use_ot_layout is added to arguments of ml_term_new() and ml_create_term(). * ml_vt100_parser.[ch]: - CONVERT_UNICODE_TO_ISCII is added to ml_unicode_policy_t. - Even if use_char_combining is false, is_comb attr of ml_char_t is set. - use_ctl is removed from ml_vt100_parser_t, and the result of IS_ARABIC_CHAR() is checked before ml_is_arabic_combining() is called. * ml_shape.h: IS_ARABIC_CHAR() is added. * ml_screen.h: use_dynamic_comb is removed. 2016-02-07 Araki Ken * README.cocoa, README.indic, doc/en/README.win32: Updated. * etc/font.cocoa: Added. * quartz/x_font.c: If a specified font family for us ascii is not found, "Menlo" font is loaded instead. * quartz/x_window.c: x_window_set_normal_hints() calls view_set_normal_hints(). * cocoa.[hm]: view_set_normal_hints() is added. 2016-02-06 Araki Ken * README.cocoa, README.indic: Updated. * x_draw_str.c: If ch_cs == ISO10646_UCS4_1_V, ml_char_get_offset() of a combining char whose ch_code is less than 0x100 is added to x. * quartz/x_font.c: fontsize_d of parse_from_name() is applied. * cocoa.m: (char*)str -> (u_char*)str in drawString(). * hb.c: hb_ot_font_set_funcs() is called after hb_font_create() on MacOSX/Cocoa. * otl.h, otf.c, hb.c: fontsize argument which is not used from otf.c for now is added to otl_convert_text_to_glyphs(). * mlconfig/main.c, mc_flags.[ch]: "OpenType Layout" checkbox is added to "Encoding" tab. * ml_line.c: If dst->num_of_chars < src->num_of_filled_chars, src->ctl_info is not copied to dst->ctl_info in case ml_line_shape(dst) is called before ml_line_ctl_render(dst). * im_kbd.c: result->num_of_args and readable_args are fixed. * configure.in: libind is never built on MacOSX/Cocoa. * cocoa/install.sh: Linkage to libotf and libharfbuzz is adjusted. 2016-02-04 Araki Ken * quartz/x_font.c: font->use_ot_layout check in x_calculate_char_width() is fixed. * ml_line_iscii.c: Processing a returned value of ml_iscii() is fixed again. * configure.in, libotl/hb.c: Hack to build libotl/hb.c with harfbuzz library on quartz is added. 2016-02-03 Araki Ken * ml_line_iscii.c: Processing a returned value of ml_iscii() is fixed. * quartz/x_font.c: - ISO10646_UCS4_1_V is supported. - x_font_has_ot_layout_table() supports harfbuzz version of libotl. - x_calculate_char_width() supports proportional fonts. * cocoa.[hm]: - cocoa_font_get_advance() is added. - drawUnistr supports proportional fonts. * hb.c: otl_{open|close}() support win32 and quartz. * cocoa/install.sh: libctl_iscii.so and libind_{hindi|bengali}.so are installed. * configure.in: libind is built on MacOSX/Cocoa. 2016-02-02 Araki Ken * win32/x_font.c: - The address of GetTextExtentPointI is gotten dynamically in USE_WIN32API because its symbol doesn't exist on mingw-i686-pc-mingw. - ISO10646_UCS4_1_V is considered. - Whether the width of full width characters is actually double or not is checked by GetTextExtentPoint32W(0x3000). * libind/Makefile.in: tamil.o is added to TBL_OBJ. * kik_dlfcn_win32.c: LoadLibrary() -> LoadLibraryA() * ml_ot_layout.c, ml_shape.c: Minor fixes. 2016-02-01 Araki Ken * x_draw_str.c: calculate_char_width() which is separated from x_calculate_mlchar_width is used internally. * fb/x_window.c: Combined ISO10646_UCS4_1_V characters whose ml_char_get_offset() is minus is correctly drawn. * fb/x_display_linux.c: - Not only /sys/class/input/inputN/name but also /sys/class/input/eventN/device/name is checked to search keyboard and mouse devices. - /dev/input/mice and /dev/input/mouse0 are checked. - EVIOCGABS(ABS_X) and EVIOCGABS(ABS_X) are checked when EV_ABS event is received. * ml_vt100_parser.c, x_screen.c: - {stop|start}_vt100_cmd() aren't called in set_mouse_report() in ml_vt100_parser.c and x_stop_selecting() etc aren't called in xterm_set_mouse_report() in x_screen.c in order to reduce the number of calling ctl_render(). - {stop|start}_vt100_cmd() aren't called in request_locatator(). - 'visualize' is added to arguments of config_protocol_set_simple() to control whether to call {stop|start}_vt100_cmd(). * libctl/ml_line_iscii.c: - ml_iscii() is called only if ml_line_is_real_modified() is true. - Loop end in ml_line_iscii_convert_logical_char_index() is changed from ml_line_end_char_index(line) to line->ctl_info.iscii->size. * libctl/ml_iscii.c, ml_ot_layout.c: The allocated size of state->num_of_chars_array is minimized. * libctl/ml_line_bidi.c: - ml_bidi() is called only if ml_line_is_real_modified() is true. - set_visual_modified() which sets visual modified area from logical one is called if visual_order is not changed. * libctl/ml_bidi.c: visual_order is not changed => return 1 visual_order is changed => return 2 * x_screen.c: ml_line_has_ot_layout() -> ml_line_has_ot_substituting_glyphs(). * ml_line.[ch]: - line->is_modified = 2 (in set_real_modified() called internally) if it is really modified while ml_line_set_modified*() called externally sets line->is_modified = 1. - ml_line_is_real_modified() is added. - ml_ot_layout() is called only if ml_line_is_real_modified() is true. - ml_line_has_ot_layout() -> ml_line_has_ot_substituting_glyphs(). * ml_line.c, ml_line_shape.c, ml_ot_layout.[ch]: line->ctl_info.ot_layout->has_ot_layout => line->ctl_info.ot_layout->substituted 2016-01-29 Araki Ken * ml_vt100_parser.c: - Unicode => ISCII conversion is enabled only if ml_is_using_ot_layout() is false. - "use_ot_layout" option is added to ml_vt100_parser_get_config(). * ml_line.[ch]: ml_is_using_ot_layout() is added. * fb/x_font.c: Minor fixes. * otf.c, win32/x_font.c: Compiling error is fixed. 2016-01-28 Araki Ken * x_screen.c: x_calculate_char_width() -> x_calculate_mlchar_width() * x_draw_str.[ch]: x_calculate_mlchar_width() is added. * x_font.h, xlib/x_font.c, fb/x_font.c, win32/x_font.c, quartz/x_font.c, x_font_ft.c, otl.h, otf.c, hb.c: offsets and widths arguments are added to x_convert_text_to_glyphs(). * ml_line.c: ml_line_ot_layout_{visual|logical|convert_logical_char_index_to_visual} are reverted. * ml_char_encoding.[ch], x_font_config.c, x_font_manager.c: ML_ISCII_ROMAN and ML_ISCII_TAMIL are removed. * ml_char.[ch]: - new_comb() is separated from ml_char_combine(). - ml_char_combine_simple() uses new_comb(). - ml_char_get_offset(), ml_char_get_width() and ml_char_set_position() are added. * mkf_8bit_conv.[ch], mkf_8bit_parser.[ch], mkf_charset.h, mkf_ucs4_iscii.[ch], mkf_ucs4_map.c: Functions related to ISCII_ROMAN are removed. * mkf/lib/Makefile.in: 16.1 -> 17.0 * libctl/ml_iscii.c: iscii_tamil_table is revived. * libind/tamil.c: Revived. * table/tamil.table: Revived with minimum. 2016-01-24 Araki Ken * doc/ja/README.ja, man/mlterm.1, etc/main, etc/main.ja, doc/en/README.indic: Updated. * x_font_cache.c, x_font_manager.c: ISO10646_UCS4_1_V font is treated as FONT_VAR_WIDTH forcibly in x_font_cache_get_xfont() and x_get_font(). * win32/x_font.c: GetTextExtentPointIW() is used for glyph index. * cocoa.[hm], quartz/x_font.c: ot_font is created in x_font.c, not in cocoa.m (cocoa_create_otf() is removed. cocoa_get_font_path() is added.) * */x_font.c, x_font_ft.c, */x_window.c, x_window_{cairo|xft}.c: 'if( font->ot_font && font->use_ot_layout)' => 'if( font->use_ot_layout)' (font->ot_font can be NULL if its charset is ISO10646_UCS4_1_V) * x_window_cairo.c: Centering of the last glyph under font->use_ot_layout == 1 in show_text() is fixed. * fb/x_font.c: A font for ISO10646_UCS4_1_V is treated as proportional. (If XFontStruct for ISO10646_UCS4_1_V has been already used for ISO10646_UCS4_1 (fixed-pitch), loaded glyphs are cleared by clear_glyph_cache_ft() becauase glyph_size is 3bytes different from fixed-pitch font to proportional one.) * */x_font.c, x_font_ft.c: libotl is used. * quartz/otfwrap.[ch], win32/otfwrap.[ch]: Removed. * libotl/: Added. * ml_vt100_parser.c: If USE_HARFBUZZ is defined, Unicode->ISCII conversion is disabled. * ml_shape.c: If src code is 0x900-0xd7f, ISO10646_UCS4_1_V is set. * ml_line.c, ml_shape.c: The algorithm of ml_line_ot_visual(), ml_line_ot_logical() and ml_shape_ot_layout() is changed. * x_main_config.c: - "use_gsub", "gsub_script" and "gsub_features" => "use_ot_layout", "ot_script" and "ot_features". - use_ctl is forcibly enabled if use_gsub is true. * x_screen.c: The 3rd argument (use_ot_layout) of x_font_manager_set_attr() is always false in draw_preedit_str(). * ml_line[ch], ml_line_shape.c, ml_logical_visual.[ch], ml_shape.[ch], ml_vt100_parser.c, x_font.h, */x_font.[ch], libtype/x_font_ft.c, */x_window.c, x_window_{xft|cairo}.c, x_functbl_*.c, x_type_loader.h, x_font_manager.c, x_screen.c: - ml_gsub -> ml_ot_layout - x_font_t::otf -> x_font_t::ot_font - {xft|cairo}_set_otf -> {xft|cairo}_set_ot_font * ml_gsub.[ch]: Renamed to ml_ot_layout.[ch]. * ml_char.[ch]: Max number of unicode areas is changed from 511 to 255 and 1 bit is used for CS_REVISION_1. (ISO10646_UCS4_1_V) * ml_str_parser.c: Null character is skipped. * libctl/Makefile.in, libtype/Makefile.in: LMKF is removed. * libtbl/mkf_ucs4_iscii.c: 0xa00-a7f => ISCII_PUBJABI. * mkf_charset.h: ISO10646_UCS4_1_V is added to draw indic scripts in variable column width all the time. * main/Makefile.in: @GSUB_LIBS@ is removed from LIBS2_fb. * tamil.c, tamil.table, roman.c, roman.table, im_kbd.c, ml_iscii.c: tamil and roman in libind are removed. 2016-01-17 Araki Ken * man/mlterm.1, README.ja: Updated. * x_font_ft.c: ":Percentage" in ~/.mlterm/aafont is enabled on cairo. * xlib/x_font.c, x_font_ft.c, win32/x_font.c: x_font_t is created by calloc instead of malloc. * ml_logical_visual.[ch], ml_line.c, x_main_config.c: defined(USE_GSUB) is added. 2016-01-16 Araki Ken * ml_bidi.[ch], ml_gsub.c: ml_load_ctl_bidi_func(ML_IS_RTL_CHAR) is moved from ml_bidi.c to ml_gsub.c in order to link ml_gsub.o to libmlterm_core.so * mlterm/Makefile.in: ml_gsub.o is linked to libmlterm_core.so. * win32/x_window.c: is_glyph argument is added to text_out(). * win32/x_font.c: - x_font_has_gsub_table() and x_convert_text_to_glyphs() are added. - GetTextExtentPoint -> GetTextExtentPoint32 - font->width = w_sz.cx instead of tm.tmAveCharWidth because w_sz.cx of PragmataPro is 1 pixel larger than tm.tmAveCharWidth. * win32/otfwrap.[ch]: Added. 2016-01-13 Araki Ken * quartz/otfwrap.[ch], quartz/x_font.c: otf_check_table() is integrated to otf_open(). 2016-01-11 Araki Ken * etc/main, etc/main.ja: Updated. * fb/x_window.c: Compiling error is fixed. * jni/Android.mk: OTF_SRC_FILES and OTF_CFLAGS are cleared once on every arch. * x_font_ft.c: XftGlyphExtents() is used if ch is glyph index. * main/Makefile.in: Mistake of the previous commit is reverted. 2016-01-10 Araki Ken * doc/ja/README.ja, man/mlterm.1: Updated. * x_main_config.c: "use_gsub", "gsub_script" and "gsub_features" options are added. * x_screen.c: gsub_get_gsub_font() is added. * x_type_loader.[ch]: - Moved to xwindow/xlib/. - X_SET_OTF and X_CONVRET_TEXT_TO_GLYPHS are added to x_type_id_t. * xlib/x_font.c, libtype/x_font_ft.c: - x_font_has_gsub_table(), x_convert_text_to_glyphs(), {xft|cairo}_set_otf and {xft|cairo}_convert_text_to_glyphs() are added. * fb/x_font.c: - load_char() -> load_glyph() - get_glyph_index(), x_font_has_gsub_table() and x_convert_text_to_glyphs() are added. - get_ft_bitmap() accepts glyph index if use_gsub argument is true. * x_font_manager.[ch]: - use_gsub is added to x_font_manager_t. - x_font_manager_set_size_attr() is renamed to x_font_manager_set_attr(). * x_font.h: otf, otf_not_found and use_gsub are added to x_font_t. * ml_vt100_parser.c: - CSI33h / CSI33l are supported. - "use_gsub" is added to OSC 5379. * ml_term_manager.c: ml_set_gsub_attr(NULL) is called in ml_term_manager_final() to free memory. * ml_logical_visual.[ch]: ml_term_t is added to ml_logvis_ctl_new() in order to pass it to ml_line_ctl_render(). * ml_line_shape.c: - ml_line_gsub_need_shape() is added. - ml_line_shape() uses ml_shape_gsub(). * ml_shape.[ch]: ml_shape_gsub() is added. * ml_line.[ch]: - ml_gsub_state_t is added to ml_line_t. - ml_set_use_gsub(), ml_line_set_use_gsub(), ml_line_gsub_render(), ml_gsub_visual(), ml_line_gsub_logical(), ml_line_has_gsub() and ml_line_gsub_convert_logical_char_index_to_visual() are added. - ml_term_t is added to arguments of ml_line_ctl_render() in order to pass it to ml_line_gsub_render(). * ml_char.[ch]: ml_char_set_cs() is added. * libctl/ml_iscii.c, mlterm/ml_iscii.c: ml_iscii_copy() doesn't copy ml_iscii_state_t if optimize argument is true and source ml_iscii_state_t doesn't have rtl characters. * ml_ctl_loader.h: ML_IS_RTL_CHAR is added. * libctl/ml_bidi.c, mlterm/ml_bidi.c: - ml_bidi() returns -1 if ISCII character is found. - ml_bidi_copy() doesn't copy ml_bidi_state_t if optimize argument is true and source ml_bidi_state_t doesn't have rtl characters. - ml_is_rtl_char() is added. * ml_gsub.[ch]: Added. * main/Makefile.in, mlterm/Makefile.in, xwindow/Makefile.in: @GSUB_CFLAGS@ and @GSUB_LIBS@ are added. * configure.in: libotf is checked. * Android.mk: libotf files are added to LOCAL_SRC_FILES and USE_GSUB is added to LOCAL_CFLAGS. * im_uim.c: Experimental implementation of showing not only candidate screen but also status one is added. * ml_normalize.m: Added. 2015-12-27 Araki Ken * ml_vt100_parser.[ch]: - ml_pty_hook_t is added to ml_vt100_parser_t. - KAM(CSI2h, CSI2l), SRM (CSI12h, CSI12l), DECBKM(CSI?67h, CSI?67l), DA3(CSI=c), DECDSR(CSI?n), OSC 104 and OSC 105 are supported. * ml_pty.[ch], ml_pty_intern.h: ml_pty_set_hook() and ml_pty_hook_t are added. * ml_termcap.[ch]: - ml_termcap_entry_t * => ml_termcap_ptr_t - ml_termcap_get_{str|bool}_field() are removed. - ml_termcap_bce_is_enabled() and ml_termcap_set_key_seq() are added. - ml_termcap_{str|bool}_field is moved from ml_termcap.h to ml_termcap.c. 2015-12-23 Araki Ken * man/mlterm.1, README.ja, etc/main, etc/main.ja: Updated * mlconfig/main.c: "Select URI by double click" checkbox is added to "Others" tab. * mc_flags.[ch]: MC_FLAG_REGARDURIASWORD is added. * x_main_config.c: "regard_uri_as_word" / --uriword option is added. * ml_vt100_parser.c: "regard_uri_as_word" is added to OSC 5379-5383. * ml_screen.[ch]: - ml_{set|get}_regard_uri_as_word() are added. - If regard_uri_as_word is true, ml_screen_get_word_region() regards uri as word. 2015-12-20 Araki Ken * mc_radio.c: "sound|visual" value is added to bel_mode option. * quartz/x_window.c: x_window_bell() is implemented. * cocoa.[hm]: view_visual_bell() and cocoa_beep() are added. * win32/x_window.c: x_window_blank() is fixed. 2015-12-20 Araki Ken * man/mlterm.1, README.ja: Updated. * vte.c: - vte_terminal_{set|get}_word_char_exceptions() are added. - "child-exited" signal is triggered with exit status on vte-0.38 or later. * main-cocoa.m: LANG environmental variable is set. * x_main_config.c: The default value of "type_engine" option is changed from xft to cairo on xlib. * ml_char.c: ml_char_combine() calls ml_normalize(). * mlterm/Makefile.in, configure.in: ml_normalize.o is added to OBJ_CORE on MacOSX. * ml_normalize.m: Added. (available on MacOSX alone.) * version.h.in: 3.6.1 -> 3.6.1post 2015-12-15 Araki Ken * 3.6.1 released. (tag "rel-3_6_1") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.6.1. 2015-12-13 Araki Ken * gtk/Makefile.in: x_sb_screen.lo -> x_layout.lo * vte.c: catch_child_exited() calls ml_close_dead_terms() via g_timeout_add() because gnome-terminal() exits with segfault. * README.ja, man/mlterm.1: Updated. * mc_radio.c: "autohide" value of scrollbar_mode option is supported. * x_layout.[ch], x_screen.c: If sb_mode is SBM_AUTOHIDE, scrollbar is hidden or unhidden according to the position of the mouse pointer. * x_sb_mode.[ch]: SBM_AUTOHIDE is added. * cocoa.m: The position of the mouse pointer is fixed. * x_window.h, */x_window.c: - x_window_init_event_mask() is removed. - x_window_{add|remove}_event_mask() are fixed. * x_event_source.c: If need_resize() returns true, "use_local_echo" is forcibly disabled. * jni/x_display.c: Pointer motion event is handled. * configure.in: utmp and ind options are disabled by default on MacOSX/Cocoa. * x_screen_manager.c: - "mlclientx --serv ..." is available. - WINDOWID environmental variable = window id of x_screen_t instead of a top window. * fb/x_connect_dialog.c: Inputting password is implemented. * fb/x_window.c: check_child_window_area() which was added at revision 2480 is removed. 2015-12-05 Araki Ken * x_draw_str.c: Minor fixes around draw_drcs(). * win32/x_dnd.c: Minor fixes. * x_font_ft.c: font->compl_fonts and font->pattern is always initialized. * bengali.table, hindi.table: Minor fixes. * configure.in: - 'extra' and 'pixmap_engine' scrollbars are built by default. - Following options are enabled by default. --enable-ind, --enable-ssh2, --enable-utmp, --enable-uim, --enable-m17nlib, --enable-scim, --enable-ibus, --enable-fcitx, --enable-canna, --enable-wnn 2015-11-28 Araki Ken * x_draw_str.c: Fix a bug of draw_drcs(). * quartz/x_window.c: x_window_t::button_pressing and prev_button_press_event are set. * quartz/x_display.c: x_display_idling() uses static variable _disp. * cocoa.m: x_display_idling(NULL) is called at 0.1 sec intervals. * MLActivity.java: IME_FLAG_NO_FULLSCREEN is set. * android/jni/x_display.c: The area of the right bottom corner is expanded according to the screen size. 2015-11-26 Araki Ken * quartz/x_window.c, quartz/x.h: - x_window_{add|remove}_event_mask() calls window_accepts_mouse_moved_events() if event_mask has PointerMotionMask. - X_POINTER_MOTION event is processed in x_window_receive_event(). * cocoa.[mh]: - window_accepts_mouse_moved_events() is added. - rightMouseUp, rightMouesDragged and mouesMoved are implemented. - mev.state is correctly set in menuForEvent(). * x_screen.c: Minor fixes. 2015-11-23 Araki Ken * x_draw_str.c: (bottom_margin + top_margin > 0 || xfont->size_attr >= DOUBLE_HEIGHT_TOP) is replaced by (xfont->height != height). * ml_str_parser.c: ml_convert_drcs_to_unicode_pua() isn't called on Android. * ml_char.c: It is disabled to combine ISCII character to another charset. * tamil.table: Fix. 2015-11-23 Araki Ken * ml_font.h, x_font_cache.c: The position of size_attr in ml_font_t is changed. 2015-11-22 Araki Ken * x_font_cache.c: If size_attr > 0, x_font_cache_get_xfont() loads USASCII font instead of a specified font which doesn't exist. * x_draw_str.c: draw_drcs() supports DOUBLE_{WIDTH|HEIGHT_TOP|HEIGHT_BOTTOM}. * ml_vt100_parser.c: ESC - (designate CS96 single byte charset) is supported on utf8 encoding. 2015-11-21 Araki Ken * README.ja, man/mlterm.1: Updated. * doc/term: Removed. 2015-11-21 Araki Ken * ml_vt100_parser.c: Mistake of revision 2510 commit is reverted. 2015-11-21 Araki Ken * x_screen.c: x_font_manager_set_size_attr() is called before x_get_font(). * x_draw_str.c: - If xfont->size_attr >= DOUBLE_HEIGHT_TOP, x_window_draw_{image}_string*() aren't used. - Drawing height and ascent is modified according to font_man->size_attr in x_draw_str() and x_draw_str_to_eol(). * x_font_manager.[ch]: x_font_manager_set_size_attr() is added. * x_functbl_{cairo|xft}.c, x_window_{cairo|xft}.c: {xft|cairo}_{un}set_clip() are added. * x_type_loader.h: X_WINDOW_SET_CLIP and XWINDOW_UNSET_CLIP are added. * cocoa.m: - setClip and unsetClip are added to MLTermView. - view_set_clip() and view_unset_clip() are added. - Glyph size is transformed according to x_font_t::size_attr. * x_window.h, fb/x_window.c, win32/x_window.c, xlib/x_window.c, quartz/x_window.c: x_window_set_clip() and x_window_unset_clip() are added. * x_font.h, fb/x_font.c, win32/x_font.c, xlib/x_font.c, quartz/x_font.c: - size_attr is added to x_font_t and to arguments of x_font_new(). - Large fonts are loaded according to size_attr. * ml_font.h: DOUBLE_WIDTH, DOUBLE_HEIGHT_TOP and DOUBLE_HEIGHT_BOTTOM are added. * ml_screen.h: ml_screen_clear_size_attr() is added. * ml_screen.c: size_attr of newly scrolled in line is reset in receive_scrolled_out_line(). * ml_edit.[ch]: ml_edit_clear_size_attr() is added. * ml_line.[ch]: - size_attr is added to ml_line_t. - ml_line_set_size_attr() is added. * ml_vt100_parser.c: - clear_line_all() and clear_display_all() doesn't change cursor position. - DECDHL and DECDWL (ESC # 3 - 6) are supported. * cocoa/install.sh: mlterm and mlconfig are installed correctly. 2015-10-25 Araki Ken * x_layout.c: x_window_update_all() is called in reset_layout() if true transparency is enabled on MacOSX/Cocoa because x_window_move() clears screen. * cocoa/install.sh: mlconfig is installed if exits. 2015-10-25 Araki Ken * mlconfig/Makefile.in, mlterm-menu/Makefile.in: "LIBS2_quartz = $(LKIK)" is added. * version.h.in: 3.6.0 -> 3.6.0post 2015-10-25 Araki Ken * 3.6.0 released. (tag "rel-3_6_0") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h: updated for 3.6.0. 2015-10-24 Araki Ken * x_screen.c: x_screen_exec_cmd() supports "mlconfig" command. * cocoa.m: "Config" and "Paste" menu items are added to the main menu. 2015-10-22 Araki Ken * mlconfig/main.c: "Scrollbar" tab is revived on MacOSX/Cocoa. * mkf_utf16_parser.c: Unnecessary mkf_parser_n_increment() is removed. * gtk/vte.c: Illegal memory access is fixed. * gtk/INSTALL: Renamed to README. * libctl/dexport-fb.map: Removed. * gtk/dexport-sun.map, libctl/dexport-sun.map, libtype/dexport-sun.map: Added. * configure.in: - mlimgloader is never built on MacOSX/Cocoa. - dexport.map -> dexport-sun.map on Solaris. 2015-10-17 Araki Ken * x_screen.c: - cocoa_get_bundle_path() + "/Contents/MacOS/" is appended to mlconfig path on quartz. * quartz/x_font.c: - screen_get_user_space_scale_factor() is not used to determine width and height by pixel. - CGFontGetUnitsPerEm() and CGFontGetGlyphAdvances() are additionally used to determine width and height by pixel. * cocoa.[ch]: - screen_get_user_space_scale_factor() is removed. - monitor_pty() is called only once. - http://flex.phys.tohoku.ac.jp/~okuyama/mlterm-30ef99499785.patch is merged. (Thanks to @LabDrunker) - PANGO_LIBDIR is set for mlconfig bundled in mlterm.app. - menuForEvent() event is handled. - cocoa_get_bundle_path() is added. * mc_font.c: gtkxlfdsel.[ch] aren't used on quartz. * mlconfig/main.c: - "Scrollbar" tab is disabled on quartz. - gtk_window_set_keep_above(TRUE) is called on win32 or quartz. 2015-10-12 Araki Ken * cocoa.m: Alt+x isn't interpreted by NSView::interpretKeyEvents unless preediting. * mlconfig/main.c: "Columns" and "Rows" entries are added to "Others" tab. * mc_geometry.[ch]: Added. * mc_wordsep.c: Entry width is limited. * mc_ratio.c, mc_space.c: Constant value => macro (MAX_VALUE_LEN) * ml_vt100_parser.c: "geometry" is added to OSC 5379. * configure.in: Minor fixes. * kiklib/configure.in, kik_utmp_sysv.c: USE_UTMPX is defined if setutxline() exists. 2015-10-12 Araki Ken * cocoa.m, x_window.c: DnD is supported. * x.h: X_SELECTION_NOTIFIED and struct XSelectionNotifyEvent are added. 2015-10-12 Araki Ken * ml_iscii.c, ml_shape.c: __attribute__((weak)) is added to function declarations on MacOS X because they are bounded to the same name symbols in ml_ctl_{bidi|iscii}_func_table without it. * mlterm/Makefile.in: ml_shape.o is moved from libmlterm_core to libmlterm. * mlterm/ml_line_shape.c: Added. (ml_line_{bidi|iscii}_need_shape, ml_line_shape() and ml_line_unshape() are moved from ml_line.c) * kik_dlfcn_dl.c: strstr(..., "mlterm/") is replaced by strcmp(..., "mlterm/") because dirpath can contain multiple "mlterm/" strings. * configure.in: x_event_source.c, x_sb_view_factory.c, x_scrollbar.c and x_simple_sb_view.c in $top_srcdir/xwindow are moved to xwindow/xlib/ on MacOS X in order to build those in xwindow/quartz/. 2015-10-11 Araki Ken * x.h: XK_BackSpace = NSDeleteCharacter instead of NSBackspaceCharacter. * ml_termcap.c: If $prefix/etc/mlterm/termcap is not found, default settings are applied on macosx and android. * cocoa.m: - 0x66(Eisu) and 0x68(Kana) keycodes are ignored in keyDown event. - x_window_receive_event(KeyEvent) is called immediately in insertText(), not in keyDown(). * x_font.h, quartz/x_font.c, cocoa.m: x_font_t:{height|ascent|width} are multiplied by NSScreen.userSpaceScaleFactor. 2015-10-05 Araki Ken * quartz/cocoa.m: [view release] is called in view_alloc() to decrement its reference count. 2015-10-04 Araki Ken * quartz/x_window.c: - view_update() is called in x_window_update_all() only if win is x_screen_t. - window_set_alpha() -> view_bg_color_changed() in x_window_set_bg_color(). * quartz/x_imagelib.c: adjust_cgimage() is added to apply pic_mod to CGImage. * quartz/x_display.c: _disp.depth = 24 -> 32. * quartz/x_color.c: x_get_xcolor_rgba() is implemented. * cocoa.[mh]: - window_set_alpha() is removed. - view_bg_color_changed() and MLTermView::bgColorChanged() are added. - True transparency is supported. * configure.in: Input method plugins are disabled on MacOSX/cocoa. 2015-10-04 Araki Ken * x_screen_manager.c: - "login -fp $USER" is used instead of "$SHELL" environmental variable. - Uncertainty of "disp = root->disp" in close_screen_intern() is fixed. (Enbugged at 2015-10-02 commit) 2015-10-03 Araki Ken * doc/en/README.cocoa: Added. * quartz/x_xic.c: Control+space and Alt+x work on MacOSX/Cocoa. * x_screen.c: Delete key works on MacOSX/Cocoa. * cocoa.[mh]: - view_resize() and view_move() are integrated to view_set_rect(). - Position and size of each subview is reset when a top window is resized. - MLTermView::pasteboard() is implemented. * quartz/x_window.c, quartz/x_display.c, quartz/x_gc.c: - x_window_t::gc is always NULL. * quartz/x_window.c: win->wall_picture is drawn in x_window_clear() and clear_margin_area(). * quartz/x_imagelib.c: x_imagelib_load_file_for_background() is implemented. 2015-10-02 Araki Ken * Cocoa is supported. (experimental) * version.h.in: 3.5.1 -> 3.5.1post 2015-08-29 Araki Ken * 3.5.1 released. (tag "rel-3_5_1") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.5.1. * man/mlterm.1, etc/main, etc/main.ja, doc/ja/README.ja: Updated. 2015-08-29 Araki Ken * kik_utmp_sysv.c: Error of pututxline() is ignored if errno is ECHILD on NetBSD. * configure.in, x_font_ft.c: Minor fixes. 2015-08-26 Araki Ken * configure.in, java/Makefile.in: Minor fixes. 2015-08-25 Araki Ken * configure.in, gtk/Makefile.in: - 'make VTE_ABI=(|2.90|2.91)' can change VTE ABI version to be built. - libvte-2.91.so.9 -> libvte-2.91.so.0 * vte.c: Failure of ioctl(slave, TIOCSCTTY) in vte_pty_child_setup() is fixed. * MLActivity.java, android/jni/x_event_source.c: Ambiguous method name is fixed. 2015-08-17 Araki Ken * mc_font.c: "Font width" buttons are added. 2015-08-15 Araki Ken * mkf_ucs_property.table: Updated to Unicode 8.0.0 (UnicodeData.txt and EastAsianWidth.txt) * xlib/x_font.c: Fix typo. 2015-08-15 Araki Ken * win32/x_window.c: Improvement for an input method window. * x_screen.c, mlconfig/main.c, mc_flags.[ch]: It is enabled to change the value of "use_extended_scroll_shortcut" option dynamically, and a checkbox of it is added to mlconfig. * im_wnn.c: Ctrl+h works. * x_screen_manager.c: X11 forwarding of an opened ssh session isn't disabled. 2015-08-14 Araki Ken * */x_window.c, x_layout.[ch], x_main_config.[ch], x_screen.[ch], x_screen_manager.c: layout_inner_border/--lborder option which enables you to specify the number of inner border pixels of a layout manager is added. 2015-08-02 Araki Ken * x_display_linux.c: KBD_INUPT_NAME => KBD_INPUT_NUM MOUSE_INUPT_NAME => MOUSE_INPUT_NUM 2015-08-02 Araki Ken * x_display_linux.c: Keyboard or mouse input device name is configurable by "KBD_INPUT_NAME" or "MOUSE_INPUT_NAME" environmental variable. 2015-08-01 Araki Ken * x_window_cairo.c, x_font_ft.c, x_font.h: - user_data_t is removed. - compl_fonts and pattern are added to x_font_t. - compl_fonts and pattern are created only if charset isn't US_ASCII, ISO8859_1_R or ISCII. 2015-07-25 Araki Ken * x_window_cairo.c: If a character code is not found in FC_CHARSET, another font which contains it is searched and used automatically. * x_font_ft.c: FC_CHARSET is set to cairo_scaled_font_t as a user data. * im_wnn.c: Illegal memory access by pressing 'A' - 'Z' is fixed. 2015-06-13 Araki Ken * im_wnn.c: - https://gist.github.com/tsutsui/1d4f9af3b4a53c906eb4 is merged. - Small "tsu" is available. 2015-06-07 Araki Ken * Makefile.in: 'make install-fb' error is fixed. * version.h.in: 3.5.0 -> 3.5.0post 2015-06-07 Araki Ken * 3.5.0 released. (tag "rel-3_5_0") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.5.0. 2015-06-06 Araki Ken * fb/x_window.c: x_window_move() doesn't redraw screen if the area of child windows fills less than 90% of a parent window. * fb/x_display.c: expose_window(all child winodws) in expose_display(). * x_im_{candidate|status}_screen.c: The change at 2015/05/06 is reverted. 2015-05-31 Araki Ken * x_layout.c: - If x_layout_t has multiple x_screen_t windows which have a wall picture, x_layout_t plunders it. - total_min_size() -> total_hint_size(). * x_screen.[ch]: x_screen_reload_color_cache() is added. * x_window.h, */x_window.c: - do_expose is added to arguments of x_window_(un)set_wall_picture(). - If wall picture is set to a root window, ParentRelative is set to its child windows. - configure_root is added to x_window_t for xlib. 2015-05-26 Araki Ken * man/mlterm.1, etc/README.ja: Updated. * x_screen.[ch], x_shortcut.[ch], x_screen_manager.c: - HEXPAND_SCREEN and VEXPAND_SCREEN are added to shortcut keys. - NEXT_SCREEN, PREV_SCREEN, CLOSE_SCREEN, HEXPAND_SCREEN, VEXPAND_SCREEN shortcuts are ignored if screen isn't splited. * x_layout.c: The position of a separator is adjusted to cell width and height. * fb/x_window.c: x_window_update() and x_window_update_all() do nothing if x_window_t::is_mapped is 0. * vte.c: "MLTERM=X.X.X" environmental variable is set in ml_term_open_pty_wrap(). * ml_pty_unix.c: "goto return_pty" is called after putenv(), not before it. 2015-05-17 Araki Ken * README.ja: Updated. 2015-05-12 Araki Ken * x_layout.c: x_window_fill() -> x_window_fill_with( x_layout_t::screen::window::fg_color) 2015-05-10 Araki Ken * x_main_config.[ch], x_screen_manager.c: use_scrollbar -> use_mdi * x_screen.c: "next_screen" is added to OSC 5379. * x_screen.c, x_screen_manager.c, x_layout.[ch], x_shortcut.[ch]: - hsplit or hresize <=> vsplit or vresize - PREV_SCREEN is added to shortcut key settings. * x_layout.c: - Slightly broken screen in changing the position of a scrollbar is fixed. - struct terminal::sb_mode is inherited from a current terminal in x_layout_add_child(). * win32/x_xic.c: If a specified window has focus, get_spot() returns cursor position relative to it. * */x_window.c, x_window.h: - x_window_move() returns 0 if both win->x and win->y aren't changed. - x_window_t::has_input_focus -> inputtable. * win32/x_window.c: x_window_update_all() calls InvaidateRect(NULL). * ml_line_iscii.c: Compiling error is fixed. 2015-05-07 Araki Ken * man/mlterm.1, doc/ja/README.ja, etc/key: Updated. * jni/x_display.c: Henkan or Muhenkan keycode from Nihongo Full Keyboard is supported. * x_layout.c: Minor fixes. * jni/x_event_source.c: Minor fixes. 2015-05-06 Araki Ken * doc/en/PROTOCOL, man/mlterm.1, ja/README.ja: Updated. * x_screen.[ch], x_screen_manager.c, x_shortcut.c: - VRESIZE_SCREEN and HRESIZE_SCREEN shortcuts are supported. - "vsplit_screen", "hsplit_screen", "vresize_screen" and "hresize_screen" are added to OSC 5379. * x_shortcut.[ch]: The default shortcut keys are changed as follows. VSPLIT_SCREEN: Ctrl+F5 -> Shift+F1 HSPLIT_SCREEN: Ctrl+F6 -> Shift+F2 * x_layout.[ch]: - x_layout_resize() and x_layout_get_next_screen() are added. - sep_str is added to the arguments of x_layout_add_child(). - get_separator_x() round sep_x to multiples of 8 on 8 planes framebuffer. * fb/x_window.c, xlib/x_window.c, win32/x_window.c, x_window.h: x_window_set_input_focus() is added. * fb/x_window.c: If x_window_move() moves a window outside of the display, it doesn't try to redraw a window. * x_im_{candidate|status}_screen.c: adjust_window_position_by_size() adjusts an input method window within x_screen_t::x_window_t::{x|y|width|height} instead of x_display_t::{width|height} on framebuffer. * x_virtual_kbd.c: Compiling error is fixed. 2015-05-05 Araki Ken * ml_vt100_parser.[ch]: https://gist.github.com/saitoha/4b320b9cb6d637d14dbc is merged. 2015-05-03 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * MLActivity.java, jni/x_display.[ch], fb/x_window.c: Copy&paste via clipboard is supported. * jni/x_event_source.c: - update_ime_text_on_active_term() searches not only attached but also focused window. - ALooper_removeFds() is called everytime before closing fds in x_event_source_process(). * mkf_*_conv.c: mkf_parser_reset() -> mkf_parser_full_reset(). * mkf_parser.c: mkf_parser_full_reset() which resets ml_parser_t::is_eos is added. * mkf/lib/Makefile.in: 16.0 -> 16.1 * win32/x_window.c: - x_window_remove_child() is added. - SetFocus() is called in receiving Button1 event. * x_im_{candidate|status}_screen.c: Compiling error is fixed. * x_shortcut.[ch], x_screen.c: CLOSE_SCREEN shortcut is supported. * x_layout.c: The size of a removed child window is reverted to the original in x_layout_remove_child(). * x_main_config.c: "exec_cmd" option is avalable in ~/.mlterm/main. * x_screen_manager.c: Fixes for win32. 2015-04-30 Araki Ken * x_sb_screen.[ch]: renamed to x_layout.[ch]. 2015-04-29 Araki Ken * x_screen_manager.c: x_system_event_listener_t::split_screen is implemented. * x_screen.[ch], x_shortcut.[ch]: - VSPLIT_SCREEN and HSPLIT_SCREEN shortcuts are supported. - split_screen is added to x_system_event_listener_t. * x_sb_screen.[ch]: It is supported to manage multiple sets of screen and scrollbar. * x_window.h, xlib/x_window.c: - has_input_focus is added to x_window_t. - x_window_t::is_focused is off except when x_window_t::has_input_focus is on. * fb/x_window.c: - focus_window() which focuses a specified window is called when mouse button is clicked on it and when x_window_map() is called. - x_window_remove_child() is added. - input_focus is added to arguments of x_window_init(). * win32/x_window.c: input_focus is added to arguments of x_window_init(). * fb/x_display.c: get_window() searches child windows recursively. 2015-04-18 Araki Ken * x_screen.c: GetDC/ReleaseDC are called in draw_preedit_str(). * im_wnn.c: - Ctrl+c or Ctrl+g cancels preediting. - Current mode (Kana or Kanji) is shown if there is no preedited text. 2015-04-13 Araki Ken * im_wnn.c: - Preedit characters are fixed when a new character is inserted if jcIsConverted() is true. - Candidate window is changed correctly in changing a candidate word by XK_Up. 2015-04-13 Araki Ken * im_wnn.c: Sign characters are converted to full width. 2015-04-12 Araki Ken * README, README.ja, man/mlterm.1: Updated. * configure.in: --enable-wnn is added. * input_method/wnn/*: Added. * im_canna.c: Cleanup. * mkf_parser.c: mkf_parser_reset() resets parser->is_eos. 2015-04-07 Araki Ken * configure.in: --enable-canna is added. * x_im_status_screen.[ch]: - modified_beg is added to arguments of draw_screen(). - It is supported to draw multiple lines by '\n'. * inputmethod/canna/*: Added. * im_fcitx.c: Candidate or preedited text is converted to a terminal encoding. 2015-03-24 Araki Ken * im_fcitx.c, im_ibus.c: Minor fixes. 2015-03-22 Araki Ken * x_display_linux.c: Hack for HankakuZenkaku key is added. * im_ibus.c: - The argument of next_engine() is changed from im_ibus_t * to IBusInputContext *. - ibus->is_enabled is reversed in switch_mode() on IBus 1.5.x. 2015-03-21 Araki Ken * MLActivity.java: /sdcard/.mlterm/anim*.gif isn't splited any more. 2015-03-20 Araki Ken * x_picture.c: HAVE_PTHREAD is defined on android. * x_display.c, MLActivity.java: hashPath() -> convertToTmpPath() in order to support not only /sdcard but also /mnt/sdcard and /extsdcard. * jni/Android.mk: -DBUILTIN_IMAGELIB is added. 2015-03-18 Araki Ken * kik_path.c, android/jni/x_display.c: HOME directory on android is /sdcard, /mnt/sdcard or /extsdcard. * jni/Android.mk, build.sh: Minor fixes. * ml_screen.c, ml_vt100_parser.c: The previous commit is partially reverted. 2015-03-17 Araki Ken * x_event_source.c: If ml_pty_ssh_poll() > 0, ml_pty_ssh_send_recv_x11() and ml_term_parse_vt100_sequence() are called immediately instead of 'break' in order not to skip select(). * ml_screen.[ch]: - gettimeofday() is used instead of clock() in ml_screen_enable_local_echo() and ml_screen_local_echo_wait(). - ml_stored_edit stores a current edit, not both normal and alt edits. - ml_screen_is_local_echo_mode() is added. * kiklib/configure.in, kik_config.h.in, android/jni/kik_config.h: Whether gettimeofday exists or not is checked. (HAVE_GETTIMEOFDAY macro) * xlib/x_connect_dialog.c: Memory leak is fixed. * libptyssh/ml_pty_ssh.c, ml_pty.c, ml_vt100_parser.c: Minor fixes. 2015-03-15 Araki Ken * x_display_wscons.c: WSDISPLAYIO_GET_FBINFO is supported. * Usage.win32: Updated. * version.h.in: 3.4.5 -> 3.4.5post 2015-03-14 Araki Ken * 3.4.5 released. (tag "rel-3_4_5") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.4.5. * ml_vt100_parser.c: to_menu = -1 (show key=value temporarily on the screen) only if OSC 5380. * libptyssh/ml_pty_ssh.c: - If waitpid() == config_menu.pid and kik_trigger_sig_child() is called, lo_{read|write_to}_pty() returns without reading pty->master or writing to pty->slave because kik_trigger_sig_child() disables loopback. - libssh2_channel_request_auth_agent is called if its symbol is found in cygssh2-1.dll on cygwin. * x_display_{linux|freebsd|wscons}.c: open(FRAMEBUFFER) is held between kik_priv_restore_{euid|egid}() and kik_priv_change_{euid|egid}(). 2015-03-10 Araki Kena * 3.4.4 released. (tag "rel-3_4_4") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.4.4. * x_shortcut.c: "Alt" which equals to "Mod" is available in ~/.mlterm/key. 2015-03-08 Araki Ken * mlclient/Makefile.in, mlclient/main.c: - mlclient doesn't depend on kiklib. - ~/.config/mlterm/socket is supported. * mlcc/data_entry_numeric.c: entry_numeric_reset() does nothing for "alpha". * mlcc/comm.c: - ~/.config/mlterm/challenge is supported. - OSC 5380 is sent without challenge if mlcc works on a remote host. * mlcc/comm.h: _COMM_H -> _COMM_H_ * mlcc/Makefile, mlclient/Makefile: Added. (For building mlcc or mlclient alone.) * x_screen.c, MLTermPty.c: ml_pty_event_listener_t::show_config is implemented. * ml_vt100_parser.c: - If OSC 5380 is received without challenge, to_menu = -1 which calls ml_pty_event_listener_t::show_config. - vt100_parser->cs is set before ml_convert_to_internal_ch(). - ml_vt100_parser_show_message() calls {start|stop}_vt100_cmd() with trigger_xterm_event == 0. * ml_pty.[ch]: show_config is added to ml_pty_event_listener_t. * mkf_utf8_parser.c, mkf_utf8_conv.c, mkf_utf16_parser.c, mkf_utf16_conv.c, mkf_utf32_parser.c, mkf_utf32_conv.c: 0x0 - 0x7f characters are treated as US_ASCII instead of ISO10646_UCS4_1. * mkf_iso8859_conv.c, mkf_ja_jp_map.c, mkf_ko_kr_map.c, mkf_ru_map.c, mkf_tg_map.c, mkf_ucs4_jisx0201.c, mkf_ucs4_map.c, mkf_uk_map.c, mkf_viet_map.c, mkf_zh_cn_map.c, mkf_zh_hk_map.c, mkf_zh_tw_map.c: mkf_map_ucs4_to_us_ascii() and mkf_map_us_ascii_to_ucs4() are removed. * mkf_ucs4_usascii.[ch]: Removed. * configure.in: mlclient is not built on win32 mingw. 2015-03-06 Araki Ken * gtk/INSTALL: Updated. * gtk/reaper.c: Compiling error on vte-2.91 is fixed. * win32/x_window.c: Extra margin area at the right and bottom edges is cleared in maximizing a window. * mc_combo.c: gtk_entry_set_width_chars() is used on GTK+-3.x instead of gtk_widget_set_size_request(). * mlconfig/main.c: Failure in compiling with GTK+-3.x and libssh2 is fixed. * x_screen_manager.c: The same command as the current screen is executed in open_{screen|pty}(). * ml_term.h: ml_term_get_cmd_line() is added. * ml_pty.[ch]: ml_pty_get_cmd_line() is added. * libptyssh/ml_pty_ssh.c: ml_pty_t::cmd_line is stored. * ml_pty_intern.h: cmd_line is added to ml_pty_t. * vte.c: vte_terminal_set_font_from_string() accepts "[FONT LIST] [FONT SIZE]" format. * configure.in: - Both gtk+-2.0 and gtk+-3.0 are checked. - The default value of --with-gtk option is changed from 2.0 to 3.0. 2015-03-03 Araki Ken * ml_edit_scroll.c: scroll_region_{beg|end} => vmargin_{beg|end} * mlclien/main.c, mlclient/Makefile.in: https://gist.github.com/hattya/97df7df875d72d8030bb is merged. (Thanks to @hattya) 2015-03-01 Araki Ken * ml_edit.c: Minor fix of copy_area(). * ml_char.c: Arguments of COMPOUND_ATTR() are fixed. 2015-02-28 Araki Ken * ml_vt100_parser.c: DECBI, DECFI, DECIC, DECDC, DECST8C, DECSACE, DECRARA and DECCARA are supported. * ml_screen.c: 'scroll' argument is added to ml_screen_go_{forward|back}(). * ml_edit.[ch]: - ml_edit_scroll_{left|right}ward_from_cursor() are added. - ml_edit_change_attr_area() is added. - ml_edit_set_use_rect_attr_select() is added. - {h|v}margins are applied in ml_edit_go_forward(). - scroll_region_{beg|end} => vmargin_{beg|end} margin_{beg|end} => hmargin_{beg|end} * ml_line.c: ml_line_{overwrite|fill}() allows 'beg_char_index' argument to exceed line->num_of_filled_chars. * ml_char.[ch]: ml_char_{change|reverse}_attr() are added. 2015-02-25 Araki Ken * gtk/INSTALL: Updated. * ml_term_manager.c, xlib/x_window.c: Minor fixes. 2015-02-22 Araki Ken * vte.c: vte_get_{major|minor|micro}_version() are implemented. 2015-02-22 Araki Ken * vte.c: gtk_widget_set_visual(toplevel window, rgba_visual) is called in vte_terminal_hierarchy_changed() to enable true transparency forcibly on vte-2.91. 2015-02-21 Araki Ken * configure.in: LIBVTE_SUFFIX=2.91 -> LIBVTE_SUFFIX=-2.91 * vte.c: - Compiling error in vte_terminal_feed() is fixed. (enbugged at the previous commit.) - vte_terminal_get_geometry_hints() is implemented. - vte_terminal_{set|get}_input_enabled() are added. - vte_terminal_screen_changed() event handler is added. - "inner-border" style is removed since vte 0.38.0. * vtetypebuiltins.c: vte-2.91 types are added. 2015-02-20 Araki Ken * gtk/INSTALL: Updated. * man/mlterm.1, doc/ja/README.ja, etc/main, etc/main.ja: Updated. * x_window.c, x_main_config.c: The default value of "use_clipboard" option is changed from "false" to "true". * x_screen.c: "Config: key=value" is shown if configuration is changed by "proto:" shortcut. * ml_vt100_parser.[ch], ml_term.h: ml_{vt100_parser|term}_show_message() is added. * ml_term.h: (term)->pty check is added to ml_term_write_{modified_key|special_key|loopback}(). 2015-02-19 Araki Ken * xlib/x_window.c: size_hints.min_width and min_height are fixed. * gtk/INSTALL: Updated. * configure.in: vte-2.91 api functions are added partially. * vte.c: - vte-2.91 is supported. (Experimental) - Following functions are implemented. vte_terminal_feed vte_terminal_feed_child vte_terminal_feed_child_binary vte_terminal_set_scroll_on_output vte_terminal_write_contents(_sync) - window.width_inc,min_width,height_inc,min_height are reset in vte_terminal_set_font_from_string(). - g_object_ref(terminal->pvt->pty) is replaced by g_object_ref(pty) in vte_terminal_set_pty(_object)(). * kik_pty_helper.c: - kill(pty_helper_pid, SIGTERM) isn't called by child processes. - setsid() and setpgid() are moved after reopening pty like vte-0.39.1/src/pty.c. * version.h.in: 3.4.3 -> 3.4.3post 2015-02-11 Araki Ken * 3.4.3 released. (tag "rel-3_4_3") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.4.3. * mlterm.1, doc/en/PROTOCOL: Updated. * fb/x_font.[ch], fb/x_window.c, fb/x.h, android/jni/x.h: - USE_ANTI_ALIAS is removed and is_aa flag is added to XFontStruct. - Fixes for rendering proportional fonts. * x_draw_str.c: If xfont->is_proportional is true (== ISCII), x_window_draw_string() with x_window_clear() is used instead of x_window_draw_image_string(). * bengali.table: Add an entry. 2015-02-05 Araki Ken * jni/x_event_source.c: Minor fixes. 2015-02-04 Araki Ken * ml_pty_unix.c: kik_killpg(SIGWINCH) is used instead of kill(SIGWINCH). * jni/x_event_source.c: need_resize() is implemented and passed to x_display_resize(). * android/jni/x_display.[ch]: need_resize is added to the arguments of x_display_resize(). * kik_unistd.h: kik_killpg is added. * kik_config.h.in, android/jni/kik_config.h: HAVE_KILLPG is added. * kiklib/configure.in: killpg is added to AC_CHECK_FUNCS(). * MLActivity.java: finishComposingText() is revived. 2015-02-02 Araki Ken * ml_screen.c: ml_str_bytes_equal() check is enabled in ml_screen_disable_local_echo(). * android/jni/x_event_source.c: Current preediting text is restored after ml_term_parse_vt100_sequence(). 2015-02-01 Araki Ken * README.android: Updated. * MLActivity.java: forceAsciiInput() which x_xic_switch_mode() uses is added. * android/jni/x_xic.c: Added. 2015-01-31 Araki Ken * x_event_source.c: - ml_term_set_config("use_local_echo", "false") is called before ml_term_parse_vt100_sequence() if term->use_local_echo is true. - Java_mlterm_native_1activity_MLActivity_{commit|preedit}Text() calls update_ime_text() with the use of pthread_mutex_lock(). * android/jni/x_display.[ch], x_event_source.c: Java_mlterm_native_1activity_MLActivity_visibleFrameChanged() is moved to x_event_source.c while its implementation is left as x_display_resize(). * MLActivity.java: visibleFrameChanged() is called even if isPreediting is true. 2015-01-28 Araki Ken * README.ja, man/mlterm.1: Updated. * doc/ja/README.w3m: Removed. * MLActivity.java: visibleFrameChanged() is not called if isPreediting is true. * x_event_source.c: ALooper_wake() is removed and pthread_mutex_{un}lock() are called before and after changing commit_text and preedit_text. * x_main_config.c: - The default value of "only_use_unicode_font" is "true" on Android. - The default value of "box_drawing_font" is "unicode" on Android. 2015-01-25 Araki Ken * fb/x_font.c: percent = 0 in x_font_new() on android. * etc/main, etc/main.ja: Updated. * ml_term.c: ml_logvis_ctl is created if terminal encoding is not only UTF-8 but also ISCII_XXX. 2015-01-24 Araki Ken * README, PROTOCOL, README.android, README.indic, README.ja, man/mlterm.1: Updated. * android/jni/main.c, MLActivity.java: unifont.pcf is not saved in starting. * vte.c: Minor fixes. * mc_flags.[ch]: MC_FLAG_BIDI and MC_FLAG_IND are integrated to MC_FLAG_CTL. * mc_bidi.[ch]: Renamed to mc_ctl.[ch]. * x_main_config.[ch], x_screen.c, x_screen_manager.c, ml_term.[ch], ml_term_manager.[ch], ml_vt100_parser.[ch]: "use_bidi" and "use_iscii" are integrated to "use_ctl". * ml_line.c: - ml_line_unuse_ctl() and ml_line_ctl_{render|visual|logical}() are added. - shape argument is remove from ml_line_shape(). * ml_ctl_loader.h, ml_functbl_bidi.c: - ml_logvis_bidi_new and ml_arabic_shape_new are removed and ml_shape_arabic and ml_line_bidi_{render|visual|logical} are added. - CTL_API_VERSION is changed from 0x01 to 0x02. * ml_logical_visual.[ch]: Add ml_ctl_logical_visual which is integrated from ml_bidi_logical_visual and ml_iscii_logical_visual. * ml_logical_visual_{bidi|iscii}.c: Removed. * ml_shape_bidi.c, ml_shape_iscii.c, ml_shape.[ch]: ml_shape_t is removed. ml_shape_{arabic|iscii}() are added. * libctl/ml_iscii.c, libctl/ml_line_iscii.c: If ISO10646_UCS4_1 charset is found and ISCII_XXX charset is not found, ml_iscii() and ml_line_iscii_render() return -1. * libctl/ml_bidi.c, libctl/ml_line_bidi.c: If ISCII_XXX charset is found, ml_bidi() and ml_line_bidi_render() return -1. * ml_screen.c: ml_screen_resize() resizes ml_screen_t::stored_edits. 2015-01-20 Araki Ken * doc/en/README.indic: Updated. * etc/aafont: U+FF61-FF9F (Hankaku kana) is added. * etc/font-fb: ISCII fonts are added. * Android.mk: Files and options related to ISCII rendering are added. * libctl/ml_iscii.c: Indic tables are statically linked if STATIC_LINK_INDIC_TABLES macro is defined. (for Android) * ml_iscii.c: If both NO_DYNAMIC_LOAD_CTL and USE_IND are defined, #include "libctl/ml_iscii.c". * mc_font.c: "UNICODE (HANKAKU KANA)" is added to "Font name" combo box. * fb/x_font.c: Unexpected behavior in loading a ISCII font in multiple times is fixed. * fb/x_window.c: Minor fixes. * x_screen.c: Not only png but also gif files are supported for emoji. * Makefile.in: Typo is fixed. (Thanks to @msmhrt) 2015-01-18 Araki Ken * doc/en/README.fb, doc/ja/README.fb, doc/en/README.android: Updated. * im_fcitx.c: The position of a candidate window is fixed. (Thanks to @msmhrt) * fb/x_font.c, fb/x_window.c: ISCII fonts are supported with freetype. 2015-01-12 Araki Ken * doc/en/README.fb, doc/ja/README.fb, doc/en/README.android: Updated. * x_font_config.c: The default value of "font_size_range" option is changed from 6-30 to 10-40 on Android. * configure.in, main/Makefile.in, xwindow/Makefile.in: --enable-anti-alias option of configure enables freetype on framebuffer. * Android.mk: freetype support is enabled. * fb/x_font.[ch], fb/x_window.c: freetype2 is supported. * fb/x_font.c: font->is_var_col_width works if multiple size fonts are used at the same time. * fb/x.h, android/jni/x.h: FT_Face is stored in XFontStruct. * x_screen.c, x_font_manager.h: "USASCII" key is supported by OSC 5380 and 5381. * ml_vt100_parser.c: OSC 5380 and 5381 doesn't require "," which is automatically complemented by the current font size. 2015-01-07 Araki Ken * win32/x_imagelib.c: - It is enabled to show regis without mlimgloader.exe. - *mask = NULL after LoadImage() succeeds. * main_loop.c: Not only DEFAULT but also ISO10646_UCS4_1 font setting is customized by --deffont option. * vte.c: Not only DEFAULT but also ISO10646_UCS4_1 font setting is customized by vte_terminal_set_font_from_string(). * c_regis.c: Separated from c_imagelib.c. * version.h.in: 3.4.2 -> 3.4.2post 2015-01-06 Araki Ken * 3.4.2 released. (tag "rel-3_4_2") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.4.2. * mlterm.1, doc/en/PROTOCOL: Updated. * ml_config_menu.c: On cygwin and msys menu programs exist in /bin instead of LIBEXECDIR/mlterm directory. 2015-01-04 Araki Ken * ml_termcap.c, win32/x.h, win32/x_window.c, x_screen.c: Compiling error is fixed. 2015-01-04 Araki Ken * gtk/vte.c: vte_terminal_set_scrollback_lines() is implemented. * mlconfig/main.c: mc_char_width_config_widget_new() and mc_flag_config_widget_new(MC_FLAG_STATICBACKSCROLL) are used. * mc_font.c: "Unicode areas you won't convert to other charsets" entry is added. * mc_flags.[ch]: MC_FLAG_STATAICBACKSCROLL is added. * mc_unicode_areas.[ch], mc_char_width.[ch]: Added. * ml_vt100_parser.[ch]: - "unicode_noconv_areas" and "unicode_full_width_areas" are added to OSC 5380 or 5381. - ml_get_backscroll_mode() is used for OSC 5380 or 5381 "static_backscroll_mode" instead of ml_screen_is_backscrolling(). - ml_vt100_parser_{init|final}() are added. * ml_screen.h: ml_get_backscroll_mode() is added. * ml_pty_ssh.c: ml_pty_ssh_t::doing_scp is renamed to ml_pty_ssh_t::suspended, and ml_pty_ssh_t::suspended = 1 in use_loopback(). * ml_term.c: - ml_term_final() is added. - The order of arguments of ml_screen_new() is fixed. - ml_search_ssh_session(host,port,user) -> ml_search_ssh_session(server,port,user) 2014-12-29 Araki Ken * x_font_ft.c, x_window_cairo.c: The performance of drawing proportional font's glyphs is improved. * ml_char_encoding.c: ml_parse_unicode_area() parses not only "U+NNNN-NNNN" but also "U+NNNN". * fb/x_window.c: Shift + Tab works. * win32/x_window.c, win32/x_xic.c: Ctrl or Shift + Tab works. * ml_vt100_parser.[ch]: CSI?8452h, CSI?8452l CSI?117h and CSI?117l are supported. * ml_screen.h, ml_edit.h: ml_{edit|screen}_set_use_bce() are added. 2014-12-27 Araki Ken * ml_pty_ssh.c: - Compiling error when OPEN_PTY_ASYNC is not defined is fixed. - libssh2_channel_open_ex(window_size = 64 * LIBSSH2_CHANNEL_PACKET_DEFAULT) is called instead of libssh2_channel_open_session() in order to improve performance. * win32/x_window.c, win32/x_xic.c: Ctrl+0, Ctrl+1, Ctrl+9 and so on are processed for modify other keys. * MLTermPty.c, MLTerm.java, MLTermPty.java: writeModifiedKey() and writeSpecialKey() are added to MLTermPty. modifyOtherKeys feature is supported. * x_picture.c: Image files in ~/.mlterm/emoji are cachable. * ml_vt100_parser.[ch]: - get_emoji_data() which is called in processing U+1F000-1F6FF is added to ml_xterm_event_listener_t. - tcap query is supported. - DA2 response is changed from "1;96;0" to "1;277;0" - DA response is changed from "1;2;4;7" to "1;2;3;4;7;29" - ml_vt100_parser_write_modified_key() and ml_vt100_parser_write_special_key() are added. * x_screen.[ch], x_screen_manager.c ml_term.[ch], ml_term_manager.c, vte.c: x_termcap is replaced by ml_termcap. * ml_termcap.[ch]: Added. * x_termcap.[ch]: Removed. 2014-12-13 Araki Ken * mc_wordsep.c: Memory leak is fixed. * mc_bidi.[ch]: Added for "Separators" of BiDi. * ml_font.h: Fix FONT_STYLE_INDEX() macro. (Enbugged at 3.3.0) * kik_str.c: kik_str_replace() replaces multiple 'orig' strings by 'new'. * x_font_config.c, x_dnd.c: TEST_xxx functions are fixed. * kik_debug.h: KIK_TESTIT and KIK_TESTIT_ONCE are added. * kik_map.h: Minor fixes. * im_ibus.c, im_uim.c, kik_mem.c, kik_dlfcn_dyld.c: Use kik_slist instead of kik_list. * kik_slist.h: Added. * kik_list.h, kik_iterator.h: Removed. 2014-12-07 Araki Ken * mlconfig/main.c: "Word separators" entry is added to "Others" tab. * mlconfig/mc_wordsep.[ch]: Added. * ml_term.c: "word_separators" is added to OSC 5380/5381. * ml_screen.[ch]: ml_get_word_separators() is added. 2014-12-04 Araki Ken * doc/en/ReleaseNote: Fix typo. * version.h.in: 3.4.1 -> 3.4.1post 2014-12-03 Araki Ken * 3.4.1 released. (tag "rel-3_4_1") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.4.1. * man/mlterm.1: Updated. 2014-12-02 Araki Ken * ml_pty_ssh.c: Minor fixes around handling error cases. 2014-11-30 Araki Ken * MLTerm.java: Null pointer exception in closing one of multiple opened ptys is fixed. * c_sixel.c: Compiling error by g++ is fixed. * x_screen.c: SF Bug #72 2014-11-27 Araki Ken * mlconfig/main.c, mc_font.c: "Box drawing" and "Font policy" radio buttons are moved from main.c to mc_font.c * mc_radio.[ch]: - mc_is_vertical(), mc_always_unicode_font() and mc_never_unicode_font() are removed. - mc_radio_set_callback() and mc_radio_get_value() are added. 2014-11-25 Araki Ken * mc_im.c: "None" is removed from "Input Method" on win32. * x_xic.c: win->xic == NULL check is added. 2014-11-24 Araki Ken * ml_screen.c: line->num_of_filled_chars is reset by ml_line_get_num_of_filled_chars_except_spaces_with_func(ml_char_equal) instead of ml_line_get_num_of_filled_chars_except_spaces() in receive_scrolled_out_line(). * ml_line.[ch]: ml_line_get_num_of_filled_chars_except_spaces_with_func() is added. * mc_im.c: - get_kbd_info() which is implemented similarly to im_kbd_get_info() is used if cygim-kbd.dll isn't found. - If mlterm is built with win32gdi, "MS IME" is shown instead of "XIM". * mc_color.c: gdk_color_to_string() is added for gtk+ < 2.12. * mlconfig/main.c: mc_im_config_widget_new() is called if USE_WIN32GUI is defined. * ml_term.h: ml_reset_pending_vt100_sequence() is called before ml_start_config_menu(). * ml_vt100_parser.c: - ml_reset_pending_vt100_sequence() is called and sixel_scrolling is set to 1 in OSC 5379 full_reset. - Cursor position is not moved by soft_reset(). * ml_edit.c: If use == -1, ml_edit_set_use_margin() resets states except cursor position. * mlcc/comm.c: mlterm_get_color_param() is implemented. * im_kbd.c, im_uim.c, im_m17nlib.c: Fix memory leaks on error. 2014-11-23 Araki Ken * mc_color.[ch]: mc_{cursor|substitute}_color_config_widget_new(), mc_vtcolor_config_widget_new(), mc_update_{cursor|substitute}_color() and mc_update_vtcolor() are added. * mc_{letter|line}_space.[ch]: Integrated to mc_space.[ch]. * mc_mod_meta.[ch], mc_vertical.[ch], mc_sb.[ch], mc_bel.[ch]: Integrated to mc_radio.[ch]. * mc_brightness.[ch], mc_contrast.[ch], mc_fade.[ch], mc_gamma.[ch], mc_screen_ratio.[ch]: Integrated to mc_ratio.[ch]. * mc_io.c: "font_policy" and "logging_vt_seq" wrappers are added to mc_{set|get}_str_value(). * ml_vt100_parser.[ch], x_screen.c: get_color is added to ml_config_event_listener_t. * ml_term.c, ml_vt100_parser.c: 'output' argument of ml_{term|vt100_parser}_get_config() is NULL if term == output. 2014-11-19 Araki Ken * mc_font.c, mc_char_encoding.c: An appropriate character set is automatically selected in selecting font on mlconfig according to a selected character encoding. * ml_vt100_parser.c: ml_vt100_parser_t::is_auto_encoding is set in ml_vt100_parser_new() and ml_vt100_parser_change_encoding(). * mkf_ucs_property.table: Updated to Unicode 7.0.0 (UnicodeData.txt and EastAsianWidth.txt) 2014-11-02 Araki Ken * ml_term.c, ml_vt100_parser.c: Pty to be responsed to by OSC 5381 is fixed. * version.h.in: 3.4.0 -> 3.4.0post 2014-10-28 Araki Ken * 3.4.0 released. (tag "rel-3_4_0") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.4.0. 2014-10-28 Araki Ken * registobmp/main.c, Makefile.in: USE_WIN32API -> USE_WIN32GUI 2014-10-26 Araki Ken * etc/main, etc/main.ja, gtk/INSTALL, doc/ja/README.ja: Updated. * x_screen.c: change_true_transbg_alpha() is always called (except when x_window_has_wall_picture() is true) even if screen->pic_mod.alpha == alpha. * vte.c: - gdk_rgba_to_string() is replaced by gdk_rgba_to_string2() which returns the format mlterm can recognize. - vte_terminal_set_color_bold() and vte_terminal_set_color_bold_rgba() are implemented. - x_font_use_point_size_for_fc() -> x_font_use_point_size() ml_term_set_winsize() is removed. 2014-10-25 Araki Ken * im_ibus.c: Cursor position passed to ibus_input_context_set_cursor_location() is fixed. 2014-10-24 Araki Ken * c_sixel.c: Hue 120=Red, 240=Green, 0=Blue * man/mlterm.1: .TP was missing. 2014-10-19 Araki Ken * xlib/x_imagelib.c: kik_mem_malloc() etc are enabled if KIK_DEBUG is defined. * kik_mem.[ch]: kik_mem_remove() is added. * x_screen.c, x_screen_manager.c: sixel_palette argument is added to get_picture_data(). * ml_vt100_parser.[ch]: - ml_vt100_parser_t::sixel_palette is added. - sixel_palette argument is added to ml_xterm_event_listener_t::get_picture_data(). * c_sixel.c, x_picture.h, fb/x_imagelib.c: - "custom_palette" static variable is introduced and x_set_custom_sixel_palette() is added. - "#define color_tbl sixel_cmap" is removed. 2014-10-18 Araki Ken * c_sixel.c: HLS is supported. * im_ibus.c: Calling select(2) with an invalid file descriptor after restarting ibus is fixed. 2014-10-17 Araki Ken * ml_vt100_parser.[ch], x_screen.c: DECEFR is supported. 2014-10-13 Araki Ken * README, doc/ja/README.ja: Updated. * x_main_config.c: The default value of "type_engine" option is changed from "xcore" to "xft". * configure.in: fribidi, xft and cairo are enabled by default. * im_ibus.c: "connected" and "disconnected" signals are handled. 2014-10-11 Araki Ken * x_screen.c, x_picture.c: INLINEPIC_AVAIL_ROW is added. 2014-10-07 Araki Ken * x_screen.c, x_picture.c: The previous fix is moved from x_picture.c to x_screen.c. 2014-10-07 Araki Ken * x_picture.c: Inline pictures in back logs (except recent 1024 lines) are removed. 2014-10-05 Araki Ken * ml_edit.c: Corrupt scrolling in Left-right margin which contains full width characters is fixed. 2014-10-04 Araki Ken * x_screen.c: event->state & ModMask => compare_key_state_with_modmap(). 2014-10-02 Araki Ken * display.h, android/jni/x.h, fb/x.h, win32/x.h, win32/x_display.c, xlib/x_display.c, x_scrollbar.c: XC_sb_v_double_arrow is removed. 2014-09-28 Araki Ken * ml_vt100_parser.c, ml_edit.h, ml_screen.h: Auto wrap is disabled in putting sixel images to the screen. 2014-09-23 Araki Ken * ml_vt100_parser.c: CSI>4p is changed to CSI>2p for Xsixel. * main_loop.c, x_font.h, win32/x_font.c, xlib/x_font.c: - x_font_use_point_size_for_fc() is renamed to x_font_use_point_size(). - "use_point_size" option works on win32. * MLTermPty.c: Compiling error is fixed. 2014-09-22 Araki Ken * doc/ja/README.fb, doc/en/README.fb: Updated. * Makefile.in: Minor fix for install-fb target. * x_virtual_kbd.c, fb/x_display.c: Software keyboard area is correctly redrawn. 2014-09-22 Araki Ken * ml_term.c: Opening pty asynchronously is disabled in opening a new pty channel on an exsiting session. * x_virtual_kbd.[ch], fb/x_display.c: Software keyboard is redrawn when it is partially exposed. * fb/x_imagelib.c: Transparent pixels are replaced by the current background color on 1bpp. 2014-09-21 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_display.c, fb/x_virtual_kbd.c: Software keyboard is available on rotated display. * xlib/x_window.c: clear_margin_area() cleargs RIGHT_MARGIN and BOTTOM_MARGIN. * x_display_x68kgrf.c: _disp.height is replaced by _display.height to fix segv in x68k_tvram_set_wall_picture(). * ml_pty_ssh.c: libssh2_session_set_timeout(0) is called at the end of ssh_connect(). 2014-09-20 Araki Ken * fb/x_window.c: x_window_bell() supports BEL_VISUAL. * xlib/x_window.c, fb/x_window.c: x_window_blank() doesn't blank RIGHT_MARGIN and BOTTOM_MARGIN. * ml_pty_ssh.c: libssh2_session_set_timeout(10000) => libssh2_session_set_timeout(30000) 2014-09-18 Araki Ken * ml_pty.[ch], ml_pty_intern.h, ml_pty_ssh.c, ml_pty_pipewin32.c, ml_pty_unix.c, ml_term.[ch], ml_term_manager.c, x_screen_manager.c: width_pix and height_pix arguments are added to the functions opening pty. * ml_term.[ch]: ml_term_set_winsize() is removed. * ml_pty_ssh.c: libssh2_session_set_timeout(10000). 2014-09-14 Araki Ken * Makefile.in: "./configure;make install" executes "make all" automatically before "make install". * ml_term_manager.c: Don't restart mlterm in segv twice or more times if auto_restart=true. 2014-09-14 Araki Ken * ml_term_manager.c: Fix compiling error. 2014-09-13 Araki Ken * ml_pty.[ch], ml_pty_intern.h, ml_pty_unix.c, ml_term.[ch], ml_vt100_parser.c, ml_screen.c, ml_screen_manager.c, ml_pty_ssh.c, MLTermPty.c, vte.c: Window width and height by pixel are set to struct winsize::ws_{x|y}pixel. 2014-09-10 Araki Ken * x_screen.c: ml_term_reset_pending_sequence() is called in pressing Pause key instead of ESC key. 2014-09-07 Araki Ken * x_screen.c: xterm_show_picture() is renamed to x_term_show_sixel() and char_index, row and scrollable arguments are removed. * ml_vt100_parser.[ch]: - ml_xterm_event_listener_t::show_picture is renamed to ml_xterm_event_listener_t::show_sixel. - ml_xterm_event_listener_t::show_sixel is called only if sixel scrolling is off by OSC?80h. 2014-09-05 Araki Ken * ml_vt100_parser.c: Clean up. 2014-09-03 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * main_loop.c: --point/use_point_size option is added. * mlterm/ml_vt100_parser.c: - OSC>2p => OSC>4p - show_picture() moves cursor in showing animation frames. 2014-09-02 Araki Ken * win32/x_display.h: Added. * win32/x_display.c: x_display_get_cursor() is added. * win32/x.h, fb/x.h: XC_sb_v_double_arrow and XC_left_ptr are defined as the same value in X11/cursorfont.h. * xlib/x_window.c: x_window_set_cursor() calls XDefineCursor() in changing the current cursor shape. * x_display.h: XC_nil which hides pointer is defined. * x_screen.c: xterm_show_picture() is added. * x_picture.[ch]: x_{load|delete}_tmp_picture() are added. * win32/x_window.c: - x_window_copy_area() draws it directly without x_window_update(). - WM_SETCURSOR message is processed. * ml_vt100_parser.[ch]: Animation sixel frames are drawn by ml_xterm_event_listener_t::show_picture instead of ml_xterm_event_listener_t::get_picture_data. * ml_screen.[ch]: ml_screen_get_cursor_line(), ml_screen_go_horizontally() and ml_screen_go_vertiacally() are changed from function to macro. 2014-08-26 Araki Ken * ml_vt100_parser.c: - DECLRP is returned by DECRQLP even if DECELR isn't sent. - DECSLE accepts Pm instead of Ps. - locator_mode is not reset by DECELR. 2014-08-24 Araki Ken * ml_vt100_parser.c: vt100_parser->mouse_mode >= LOCATOR_CHARCELL_REPORT is checked before responsing to the DECRQLP. 2014-08-24 Araki Ken * xlib/x_imagelib.c: load_sixel() is called regardless of BUILTIN_IMAGELIB. * x_screen.[ch], MLTermPty.c: The default value of prev_mouse_report_{col|row} is changed from -1 to 0. * ml_vt100_parser.c: locator_mode is not checked if button == 0. 2014-08-23 Araki Ken * xlib/x_imagelib.c: Sixel graphics without any modifiers is processed in mlterm instead of calling mlimgloader. * gdk-pixbuf.c: Compiling error with gdk-pixbuf-1.x is fixed. * x_screen.c, MLTermPty.c: ml_term_report_mouse_tracking() is used. * ml_term.h: ml_term_report_mouse_tracking() is added. * ml_vt100_parser.[ch]: - DEC Locator is partially supported. - ml_vt100_parser_report_mouse_tracking() is added. * version.h.in: 3.3.8 -> 3.3.8post 2014-08-16 Araki Ken * 3.3.8 released. (tag "rel-3_3_8") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.8. * etc/main, etc/main.ja: Updated. 2014-08-16 Araki Ken * ml_vt100_parser.[ch]: Compiling error if mlterm is built without --enable-ssh2 is fixed. * ml_pty_ssh.c: Hack for cygwin SIGCHLD is added. * win32/mlterm-msys_cygwin.bat, mlterm-win32.bat, mlterm-xcygwin.bat, setup-cygwin.bat: Removed. 2014-08-12 Araki Ken * doc/ja/README.ja: Updated. * xlib/x_dnd.c, x_screen.c: DnD without Shift doesn't start scp. * fb/x_imagelib.c, win32/x_imagelib.c: Sixel parser is embeded instead of using mlimgloader. 2014-08-09 Araki Ken * doc/ja/README.ja, man/mlterm.1: Updated. * x_screen.c: "scp" is executed in set_xdnd_config() if a local file is dropped on ssh client window. * xlib/x_dnd.c: "text/uri-list" triggers set_xdnd_config("scp"). * win32/x_dnd.c: Shift+DnD triggers set_xdnd_config("scp"). * ml_term.h: ml_term_exec_cmd() and ml_term_scp() are added. * ml_vt100_parser.[ch]: ml_vt100_parser_exec_cmd() is added. * libptyssh/ml_pty_ssh.c, ml_pty_ssh.c: - read/write on ssh session is blocked while scp thread is working. - Outputting "SCP: src -> dst" message is moved from ml_pty_ssh.c to libptyssh/ml_pty_ssh.c 2014-08-06 Araki Ken * win32/x_imagelib.c: CreateProcess() => CreateProcessW() * gdiplus.cpp: - mbstowcs() => MultiByteToWideChar() - CommandLineToArgvW(GetCommandLineW()) is used. * ml_pty_ssh.c: - IS_RELATIVE_PATH() => IS_RELATIVE_PATH_UNIX(). - scp works fully from mlconfig even if use_scp_full = false. * kik_path.h: IS_RELATIVE_PATH_{DOS|UNIX}() are added. * mlconfig/main.c: gtk_window_set_keep_above() is removed. * ml_config_menu.c: close(STDERR_FILENO) is added. * mc_wall_pic.c, gdiplus.cpp: Change of mc_wall_pic.c at 2014-08-03 is reverted, and strchr(path,'/') is checked before cygwin_conv_to_win32_path() in gdiplus.cpp. 2014-08-03 Araki Ken * mlconfig/po/*.po: Updated. * mlconfig/main.c, mc_flags.[ch]: "Local echo" checkbox is added to "Others" tab. * mc_bel.c, mc_mod_meta.c: The position of showing label is adjusted. 2014-08-03 Araki Ken * mc_wall_pic.c: escape_path() is added for win32. * doc/en/PROTOCOL: Updated. * MLTermPty.c, gtk/vte.c: Minor fixes. * win32/x_font.c, libtype/x_font_ft.c: Font name like "Hoge 0" is parsed correctly and "0" is ignored. * x_screen.[ch]: x_system_event_listener_t::get_pty() and ::pty_list() are removed and ml_get_term() and ml_get_pty_list() are called from x_screen.c directly. * ml_vt100_parser.[ch], ml_term.[ch], ml_term_manager.[ch], x_screen.c: - ml_{term|vt100_parser}_{set|get}_config() are added. - {get|set}_config in x_screen.c calls ml_term_{set|get}_config(). - use_auto_detect and logging_vt_seq arguments are added to ml_create_term(), ml_term_new() and ml_vt100_parser_new(). * ml_pty.[ch], ml_pty_intern.h: - ml_config_menu is managed by ml_pty instead of ml_term. - ml_response_config() is added. * ml_config_proto.[ch]: - ml_get_proto_challenge() is added. - ml_parse_proto_prefix() returns 1 instead of 0 if dev is not found in the sequence. * ml_edit.c: The result of https://gist.github.com/ttdoda/5798565 and https://gist.github.com/ttdoda/5902671 becomes the same as TeraTerm. (Compatibility with VT525 is improved.) 2014-07-28 Araki Ken * x_event_source.c, x_screen.c: x_display_sync() is called in receive_next_event() and interrupt_vt100_cmd(). * x_display.[ch]: x_display_sync() is added. 2014-07-27 Araki Ken * ml_vt100_parser.c: Minor fixes around ml_vt100_parser_t::yield. 2014-07-26 Araki Ken * doc/ja/README.ja, man/mlterm.1: Updated. * ml_vt100_parser.c: fclose(fp) and free(path) are called before return 0 in processing sixel sequence. 2014-07-26 Araki Ken * x_main_config.c, x_screen.c: --seqfmt/vt_seq_format option is added. * ml_vt100_parser.[ch]: ml_set_use_ttyrec_format() enables or disables to log vt100 sequence by ttyrec format. 2014-07-25 Araki Ken * ml_bidi.c, x_picture.c: ml_get_picture_char() is used. * ml_char.[ch]: ml_get_picture_char() is added. * x_screen.c: interrupt_vt100_cmd() is added. * ml_vt100_parser.[ch]: - interrupt event is added to ml_xterm_event_listener_t. - ml_xterm_event_listener_t::interrupt is called if sixel graphics is drawn by DECINVM. - The amount of reading data from pty once is shrinked if buffered data isn't DCS or OSC. - new_len is added to ml_read_buffer_t, and only newly received data is parsed in restarting to parse DCS or OSC in parse_vt100_escape_sequence(). 2014-07-23 Araki Ken * ml_drcs.[ch], ml_vt100_parser.[ch]: const is added to some arguments. 2014-07-21 Araki Ken * ml_vt100_parser.c: - hex_to_text() is optimized. - define_macro() deletes specified entry if *data is '\0'. 2014-07-21 Araki Ken * x_picture.c, xlib/x_imagelib.c: ~/.mlterm/macro_*.six is cached. * ml_vt100_parser.[ch]: - DECDMAC/DECINVM are supported. - If DECDMAC defines sixel graphics data, store it in ~/.mlterm/macro_*.six and show it by DECINVM. 2014-07-19 Araki Ken * MLTermPty.c: - "use_auto_detect" and "auto_detect_encodings" are supported. - replaceTextBuffering(0,0,null,null) is called in checkTextLimit(). * x_screen.c, doc/en/PROTOCOL: "auto_detect_encodings" is added to OSC 5380 and 5381. * ml_vt100_parser.[ch]: - ml_get_auto_detect_encodings() is added. - ISO8859_6_R (arabic) and ISO8859_8_R (hebrew) are always converted to unicode because they need bidi rendering. * mc_io.[ch]: 'const' is added. * mc_auto_detect.[ch]: Added. * mc_check.[ch]: Removed. * ml_pty.c: Parenthesis is added. 2014-07-15 Araki Ken * x_screen.c: ml_line_is_empty() in start_selection() and selecting_with_motion() is removed. * ml_screen.c: convert_col_to_char_index() is fixed. 2014-07-14 Araki Ken * x_display_wscons.c: The null pointer bug of_display.color_cache in the case of vinfo.depth >= 2 && _disp.depth == 1 is fixed. 2014-07-13 Araki Ken * ml_vt100_parser.c: Compiling error is fixed. * ml_screen.c, x_screen.c: ml_term_get_cols(screen->term) - line->num_of_chars => ml_term_get_cols(screen->term) - ml_line_get_num_of_filled_cols(line) * x_selection.c: conved flag is added in update_sel_region() instead of col != conved_col because it doesn't works if col == 0. 2014-07-13 Araki Ken * ml_screen.[ch], ml_term.h, x_screen.c, x_selection.[ch]: Rectangle selection is supported. * win32/x_window.c: get_key_state() is set to XButtonEvent::state in x_window_receive_event(). * ml_line.c: - ml_line_{reverse|restore}_color() calls ml_line_set_modified() only if ml_char_{reverse|restore}_color() returns 1. - BREAK_BOUNDARY works in ml_convert_char_index_to_col() works even if specified line is empty. * ml_char.c: Minor fixes. 2014-07-10 Araki Ken * configure.in: "-lfontconfig -lfreetype" is added to CAIRO_LIBS and XFT_LIBS because mlterm has undefined symbols if --disable-shared is specified on some platforms where dependency_libs="" in libcairo.la. 2014-07-09 Araki Ken * x_display_freebsd.c: Duplicated capslock processing is fixed. * jni/x_display.c: Minor fixes. 2014-07-08 Araki Ken * x_display_x68kgrf.c: - Keyboard events from /dev/kbd are processed instead of stdin. - x68k_set_use_tvram_colors() and x68k_set_tvram_cmap() resets _display.color_cache. * x.h: KS_Print -> KS_Print_Screen * x_display.c: Key squences on NetBSD/x68k are added to the table in receive_stdin_key_event(). 2014-07-08 Araki Ken * libtype/Makefile.in: Compiling error is fixed. * version.h.in: 3.3.7 -> 3.3.7post 2014-07-06 Araki Ken * 3.3.7 released. (tag "rel-3_3_7") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.7. 2014-07-06 Araki Ken * x_shortcut.c: Minor fixes. * gtk/vte.c: If cmd_path is omittted in argv, argv[0] = cmd_path. 2014-07-05 Araki Ken * kik_str.c: Illegal memory allocation is fixed. * x_shortcut.c: [operation]=[key] format is obsoleted. 2014-07-05 Araki Ken * kik_str.c, x_shortcut.c: kik_str_unescape() hack for x_shortcut.c is removed. 2014-07-05 Araki Ken * mlclient/main.c: Minor fixes. * main_loop.c: --deffont option is added. * README.ja, mlterm.1: Updated. * ml_bidi.c: U+2500-259f and DEC_SPECIAL characters are forcibly regarded as bidi separator ones. * ml_term.c: kik_str_unescape(bidi_separators) is called. * ml_screen.c: kik_str_unescape(word_separators) is called. 2014-06-30 Araki Ken * ml_pty.[ch], ml_pty_inter.h, ml_pty_unix.c, ml_term.[ch], x_main_config.[ch], x_screen_manager.c: chdir(work_dir) if --work-directory option is specified. * mlterm.1, mlclient.1, README.ja, PROTOCOL, etc/main, etc/main.ja: Updated. 2014-06-29 Araki Ken * ml_bidi.c: Minor fixes. 2014-06-28 Araki Ken * x_main_config.c, x_screen.c: ml_set_bidi_separators() is changed to ml_term_{get|set}_bidi_separators(). * ml_term.[ch], ml_term_manager.[ch], x_screen_manager.c: - bidi_separators variable is changed from static to the member of ml_term_t. - ml_term_{get|set}_bidi_separators() are added. - ml_set_bidi_separators() is removed. * vte.c, MLTermpty.c: Arguments of ml_create_term() is fixed. * ml_vt100_parser.[ch]: Minor fixes. 2014-06-28 Araki Ken * mlterm.1, README.ja: Updated. * libctl/ml_bidi.[ch], ml_line_bidi.[ch], ml_logical_visual_bidi.c, mlterm/ml_bidi.[ch], ml_logical_visual.[ch], ml_term.[ch], x_screen.c, x_main_config.c: - bidi_separator option is added. - "left" and "right" are available as the value of bidi_mode option. * libptyssh/ml_pty_ssh.c: Unread data in loopback pty isn't discarded. * mc_io.c: HOEMPATH environmental variable is used instead of HOME in win32. 2014-06-24 Araki Ken * x_draw_str.c: If ml_char_is_visible() is false, text is not drawn. * ml_char.[ch]: - IS_CONCEALED => IS_VISIBLE - ml_char_is_visible() is added. 2014-06-22 Araki Ken * MLTermPty.c, MLTerm.java, Style.java: SGR 9 and 29 are supported. * ml_screen.[ch], ml_term.h, x_screen.c: 'visible' argument is added to ml_term_blink() and ml_screen_blink(). * ml_char.[ch]: ml_char_blink() => ml_char_set_visible() * ml_vt100_parser.c: put_char() is fixed. 2014-06-21 Araki Ken * vte.c: set_colors() is fixed. * man/mlterm.1, doc/ja/README.ja: Updated. * x_main_config.[ch]: --it/it_color, --bl/bl_color, --co/co_color and --itfont/use_italic_font options are added. * x_font_manager.[ch]: x_set_use_italic_font() is added. * vte.c, MLTermPty.c, ml_term_manager.[ch]: Fixes by the change of the arguments of x_font_manager_new(), x_color_manager_new() and ml_create_term(). * x_draw_str.[ch]: adjust_bd_ul_color() is removed. * x_color_manager.[ch]: - _ITALIC_COLOR, _BLINKING_COLOR and CROSSED_OUT_COLOR are managed in x_color_manager_t::sys_colors. - x_color_manager_{set|get}_{bd|ul}_color() -> x_color_manager_{set|get}_alt_color(). - x_color_manager_adjust_{bd|ul}_color() are removed. * ml_term.[ch]: ml_term_{set|get}_alt_color_mode() are added. * ml_vt100_parser.[ch]: - ml_alt_color_mode_t is added. - ml_vt100_parser_{set|get}_alt_color_mode() are added. - vt100_parser->alt_color_mode is checked in put_char(). * ml_color.h: ML_BOLD_COLOR, ML_ITALIC_COLOR, ML_UNDERLINE_COLOR, ML_BLINKING_COLOR, ML_CROSSED_OUT_COLOR are added. 2014-06-20 Araki Ken * ml_vt100_parser.[ch], x_screen.[ch]: SGR 5 and 25 are supported. * ml_term.h: ml_term_blink() is added. * ml_screen.[ch]: ml_screen_blink() and ml_screen_enable_blinking() are added. * im_fcitx.c, im_ibus.c, im_m17nlib.c, im_scim_mod_if.c, im_uim.c, ml_screen.[ch], x_im.h, x_im_{candidate|status}_screen.c: Fixes by is_blinking of ml_char_{set|combine}(). * ml_char.[ch]: is_blinking is added to ml_char_{set|combine}(), and ml_char_is_blinking() and ml_char_blink() are added. * x_picture.c: ~/.mlterm/anim* are completely removed on exit. * fb/x_display.c, win32/x_display.c: x_picture_display_closed() is called in x_display_close_all(). 2014-06-16 Araki Ken * x_im.h, im_*.c: is_crossed_out argument is added to x_im_export_syms_t::ml_char_set and ::ml_char_combine(), and IM_API_VERSION is changed from 0x09 to 0x0a. * x_font_config.c, ml_vt100_parser.c: ml_parse_unicode_area() is used. * ml_char_encoding.[ch]: ml_parse_unicode_area() is added. 2014-06-15 Araki Ken * doc/ja/README.ja, man/mlterm.1, doc/en/PROTOCOL: Updated. * ml_vt100_parser.[ch], x_main_config.c: full_width_areas => unicode_full_width_areas 2014-06-15 Araki Ken * doc/ja/README.ja, man/mlterm.1: Updated. * x_font_config.c: "_HALFWIDTH" suffix is removed. * ml_vt100_parser.[ch], x_main_config.c: "use_unicode_property" option is removed. * mc_font.c: "UNICODE (EMOJI)" is added. * ml_vt100_parser.[ch], x_main_config.c: "full_width_areas" option which forces full width regardless of EastAsianWidth.txt is added. 2014-06-13 Araki Ken * ml_edit.[ch], ml_screen.h, ml_vt100_parser.c: ml_{edit|screen}_scroll_{left|right}ward() are added and used to process SL and SR. 2014-06-10 Araki Ken * ml_char.[ch], ml_vt100_parser.[ch], x_draw_str.c: is_underlined => underline_style 2014-06-09 Araki Ken * ml_vt100_parser.c: ML_BOLD_COLOR_MASK is not set to ML_{FG|BG}_COLOR. * xlib/x_color.c: Fix alloc_closest_xcolor_pseudo(). * fb/x.h, fb/x_display.c: #ifdef LARGE_CACHE => #ifndef COLOR_CACHE_MINIMUM. * README.ja, man/mlterm.1: Updated. 2014-06-09 Araki Ken * fb/x.h, fb/x_display.c: LARGE_CACHE is added. (disabled by default.) 2014-06-09 Araki Ken * fb/x.h, fb/x_display.c: Caching in x_cmap_get_closest_color() is improved. * main_loop.c: Starting mlterm with -j option executes mlclient if daemon process has already started. * daemon.[ch]: - free(un_file) is called in daemon_final(). - daemon_get_fd() is removed. * x_screen_manager.c: mlclient permits unknown options. * kik_conf.[ch]: ignore_unknown_opt argument is added to kik_conf_parse_args(). * ml_char.c, ml_vt100_parser.c: ML_BOLD_COLOR_MASK is set in ml_vt100_parser.c, not in ml_char.c. 2014-06-07 Araki Ken * mc_logsize.c: "unlimited" is added. * ml_config_proto.c, ml_vt100_parser.c: Minor fixes. 2014-06-06 Araki Ken * ml_char.c: CHARSET() macro checks is_unicode_area_cs flag. 2014-06-05 Araki Ken * ml_config_proto.[ch]: ml_parse_proto_prefix() checks challenge. * x_draw_str.c: draw_line() is added to draw underline, double-underline or crossed out line. * ml_vt100_parser.[ch]: - SGR 9, 21, and 29 are processed. - is_crossed_out is added to ml_vt100_parser_t and ml_vt100_storable_states_t. - DECFRA is processed. * ml_edit.[ch]: ml_edit_fill_all() -> ml_edit_fill_area() * ml_screen.[ch]: ml_screen_fill_all_with_e() -> ml_screen_fill_area() * ml_char.[ch]: - is_crossed_out is added to ml_char_t, ml_char_set() and ml_char_combine(). ml_char_is_crossed_out() is added. - is_underlined == 2 means drawing underline doubly. * x_im_{status|candidate}_screen.c: Minor fixes. * x_font_ft.c: Fixes if font->is_vertical is true. 2014-06-03 Araki Ken * main_loop.c, x_screen.c: "mod_meta_prefix" option is added. * x_shortcut.c, x_termcap.c: kik_str_unescape() is used. * kik_str.[ch]: kik_str_unescape() is added. 2014-06-01 Araki Ken * fb/x_display.c, x.h: x_cmap_get_closest_color() caches 512 + 64 pixels. * x_screen_manager.c: get_picture_data() for background terminals is set when they are detached from the window system. * ml_term.[ch]: ml_term_t::user_data and ml_term_{get|set}_user_data() are added. 2014-05-29 Araki Ken * mkf/configure.in, mkf/Makefile.in: If --disable-dl-table is specified, 'make' isn't executed under libtbl/. * configure.in, main/Makefile.in: XWINDOW_OBJ_SUFFIX => MAIN_OBJ_SUFFIX * version.h.in: 3.3.6 -> 3.3.6post 2014-05-25 Araki Ken * 3.3.6 released. (tag "rel-3_3_6") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.6. * x_transparent_sample_sb_view.c: x_transparent_sample2_sb_view_new() => x_transparent_sample_sb_view_new() * x_sample_sb_view.c: x_sample2_sb_view_new() => x_sample_sb_view_new() 2014-05-25 Araki Ken * ml_term.c: ml_screen_visual() is called in ml_term_set_modified_*() only if ml_screen_logical() succeeded, because ml_term_set_modified_*() can be called in logical context. (see flush_scroll_cache() in x_screen.c) * x_draw_str.c: The position of drawing drcs glyphs is fixed. * ml_line.[ch], ml_edit.c, ml_edit_scroll.c, ml_model.c: - ml_line_copy_line() -> ml_line_copy() - ml_line_swap() is added, and ml_line_copy_line() in copy_lines() in ml_edit_scroll.c is replaced by ml_line_swap(). * win32/x_xic.c: The focused window alone can call ImmSetCompositionWindow(). * README, README.ja: Minor fixes. 2014-05-23 Araki Ken * x_font_config.c: The change at 2014-05-22 is reverted. 2014-05-23 Araki Ken * MLActivity.java: unifont.pcf which is older than the apk file is overwritten. 2014-05-22 Araki Ken * x_font_config.c: changed_font_file argument is removed from read_all_conf(). * ml_char.[ch]: ml_char_add_unicode_area_font() -> ml_char_get_unicode_area_font() 2014-05-19 Araki Ken * x_sb_screen.c, win32/x_window.c: button_pressed() hack in x_sb_screen.c for USE_WIN32GUI is moved to x_window.c * Android.mk, android/jni/x_display.c, x_screen_manager.c: Scrollbar is supported on Android. * pixmap_engine.c, x_sb_view_factory.c, x_sb_view.h, main/dexport.map: The address of x_imagelib_load_file is passed to pixmap_engine via x_sb_view_conf_t instead of building mlterm with -export-dynamic. * x_sb_view.h, x_scrollbar.c, x_simple_sb_view.c, main/dexport-fb.map, scrollbar/sample/: - "sample" scrollbar is linked to mlterm as "simple" one. - "sample2" scrollbar is renamed to "sample". * xlib/x_simple_sb_view.c, win32/x_simple_sb_view.c, fb/x_simple_sb_view.c: The original "simple" scrollbar is removed. 2014-05-18 Araki Ken * ml_vt100_parser.c: The current foreground color of the terminal is designated as the default value of the first entry of the sixel palette. 2014-05-17 Araki Ken * x_screen.c: If Pc of OSC 52 is 'p' and "use_clipboard" option is true, clipboard is disabled temporarily. 2014-05-17 Araki Ken * ml_vt100_parser.[ch], x_screen.c: If Pc of OSC 52 is 'c' and "use_clipboard" option is false, clipboard is enabled temporarily. * ml_drcs.[ch], ml_vt100_parser.[ch], x_screen.c: Each pty has its own drcs database. * c_sixel.c: Fix http://twitter.com/kefir_/status/467340224628924416 * ml_pty.c: Minor hack is added to ml_pty_get_slave_name(). 2014-05-11 Araki Ken * x_im_{candidate|status}_screen.c: Calculating appropriate size of input method window in draw_screen() is skipped if window_exposed() calls it. 2014-05-11 Araki Ken * x_im_{candidate|status}_screen.c: x_window_move_no_expose() is removed. * fb/x_window.c: x_window_move() works same as x_window_move_no_expose() for the input method window, and x_window_move_no_expose() is removed. * fb/x_display.[ch]: - x_display_check_visibility_of_im_window() becomes static and renamed to check_visibility_of_im_window(). - x_display_reset_input_method_window() is added. 2014-05-11 Araki Ken * fb/x_window.c: clear_margin_area() is called in x_window_resize() which is called from x_im_{status|candidate}_screen.c 2014-05-11 Araki Ken * x_display_linux.c: - strstr() in get_event_device_num() is replaced by strcasestr(). - If get_event_device_num() doesn't find kbd or mouse input event devices, it returns the default number of kbd or mouse device instead of -1. * fb/x_window.c: x_display_check_visibility_of_im_window() is called not only from x_window_move() but also from x_window_resize(). * fb/x_display.c: The bug of clearing input method window unexpectedly in receive_event_for_multi_roots() is fixed. * im_fcitx.c: Preedit text is drawn before candidate window in order not to clear candidate window by preedit text at the corner of the window. 2014-05-10 Araki Ken * x_im_status_screen.c: draw_screen() wraps and draws status characters in multiple lines. * README, man/mlterm.1, README.ja: Updated. * im_fcitx.c: fcitx plugin works on framebuffer. 2014-05-10 Araki Ken * x_im.c: Segmentation fault in exiting with fcitx is fixed. * im_fcitx.c: connection_handler() is registerd to x_event_source only if the initialization of fcitx succeeds. * im_ibus.c: Minor fixes. 2014-05-10 Araki Ken * inputmethod/fcitx: Added. * configure.in: --enable-fcitx option is added. 2014-05-05 Araki Ken * ml_vt100_parser.c: The hack of continuing sixel sequence by FF, GS, RS and US after ST is removed. * x_draw_str.c: INLINEPIC_ID and INLINEPIC_POS are defined. (Not in x_picture.h) * x_picture.c, x_screen.c: Following macros in ml_char.h are used. * ml_char.h: - PICTURE_ID_BITS and PICTURE_POS_BITS are defined. (Not in x_picture.h) - ml_char_combine_picture(), ml_char_picture_id() and ml_char_set_picture_id() macros are defined. * x_picture.h: INLINEPIC_ID_SHIFT, INLINEPIC_ID and INLINEPIC_POS macros are removed. 2014-05-02 Araki Ken * x_display_wscons.c: WSDISPLAYIO_MODE_DUMBFB is used instead of WSDISPLAYIO_MODE_MAPPED on NetBSD. * x_font_ft.c: cairo_matrix_init_identity() + cairo_matrix_scale() => cairo_matrix_init_scale(). 2014-04-26 Araki Ken * x_draw_str.c: The margin area of transparent frame of animation gif is never cleared. * version.h.in: 3.3.5 -> 3.3.5post 2014-04-26 Araki Ken * 3.3.5 released. (tag "rel-3_3_5") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.5. 2014-04-25 Araki Ken * x_font_ft.c: The default width of proportional fonts is changed from the width of 'N' to 'M'. * xlib/x_window.c: win->is_focused is always true on override redirect mode in order not to call XSetInputFocus() in pressing input method window. * x_im_candidate_screen.c, x_im_status_screen.c: Even if window is unfocused hide() always calls x_window_unmap() in order to hide input method window as soon as preedit string is removed all. 2014-04-24 Araki Ken * c_imagelib.c: The error of compiling mlimgloader/none.c is fixed. 2014-04-23 Araki Ken * x_font_ft.c: - Mono spacing is always forced on xft unless use_variable_column_width is true. - ":Percentage" after font names in ~/.mlterm/aafont works on cairo. 2014-04-22 Araki Ken * x_screen.c, etc/termcap: The default output string of XK_BackSpace is changed from '\x07' to '\x7f'. * x_font_ft.c: Processing proportional fonts on cairo is improved. * mlimgloader/none.c: Minor fixes. 2014-04-22 Araki Ken * x_event_source.c, xlib/x_display.c: Pending events in the event queue is read before select(). 2014-04-17 Araki Ken * x_picture.c: Minor fixes. 2014-04-14 Araki Ken * c_imagelib.c: Hack for unexpected behavior of GDI+ in reading animation GIF frames is improved. 2014-04-13 Araki Ken * gdiplus.cpp, c_anim.gif: Hack for unexpected behavior of GDI+ in reading animation GIF frames is added. * x_picture.c, c_imagelib.c: Minor fixes. 2014-04-12 Araki Ken * c_anim.gif, c_imagelib.c: If gdk_pixbuf_new_from() reads a GIF Animation frame whose width and height are smaller than those of the first frame, it resizes appropriately. (gdk_pixbuf_new_from_file() ignores the logical width and height in the GIF header.) * x_picture.c: If it fails to load an animation gif frame, skip it. 2014-04-11 Araki Ken * x_display.c, MLActivity.java, c_animgif.c, c_imagelib.c, gdiplus.cpp, x_picture.c: ~/.mlterm/anim.gif => ~/.mlterm/anim%d.gif to support asynchronous loading. 2014-04-10 Araki Ken * x_picture.[ch]: It is possible to load GIF files asynchronously. * MLActivity.java: Minor fixes. 2014-04-09 Araki Ken * x_event_source.c: update_ime_text() and x_display_idling() are called in idling. 2014-04-07 Araki Ken * MLActivity.java, x_display.c: The failure of animating gif images downloaded from remote hosts on Android is fixed. * c_animgif.c: The processing of dispose method is fixed. 2014-04-06 Araki Ken * x_picture.c, c_animgif.c: ~/.mlterm/anim%d.gif => ~/.mlterm/anim.gif * c_animgif.c: Separated from c_imagelib.c. * android/jni/x_display.c, android/jni/x_event_source.c, MLActivity.java: Animation GIF is supported on Android. 2014-04-05 Araki Ken * x_picture.c, x_screen.[ch]: Waiting between animation frames is managed in x_screen.[ch] instead of x_picture.c. * gdiplus.cpp: Fix for win32. 2014-04-05 Araki Ken * xlib/x_window.c: XSetClipMask(None) is called in x_window_update(). * x_picture.[ch], c_imagelib.c, gdiplus.cpp, xlib/x_imagelib.c, x_draw_str.c: The number of gif animation frames is unlimited. 2014-03-31 Araki Ken * c_imagelib.c: O_BINARY is added to open() in reading animation gif on win32. * ml_vt100_parser.c: Accessing free'ed memory is fixed. 2014-03-31 Araki Ken * doc/en/PROTOCOL: Updated. * x_screen.c: - x_window_t::idling is always set and whether blink_cursor is enabled or not is stored in x_screen_t::cursor_blink_wait. (cursor_blink_wait == 0 => disable blinking cursor_blink_wait < 0 => enable blinking (hide cursor) cursor_blink_wait > 0 => enable blinking (show cursor)) - prev_inline_pic is added to x_screen_t. * ml_vt100_parser.[ch]: - "add_frame" is added to OSC 5379. - add_frame_to_animation event is added to ml_xterm_event_listener_t. * x_picture.[ch]: - next_frame and anim_wait are added to x_inline_picture_t. - x_add_frame_to_animation() and x_animate_inline_pictures() are added. * gdiplus.c: - create_cardinals_from_file() supports Animation GIF. - Image::GetLastStatus() is checked after Image::FromStream() or Image::FromFile(). * c_imagelib.c: gdk_pixbuf_new_from() supports Animation GIF. 2014-03-24 Araki Ken * kik_debug.c: The bug of calling vfprintf(...,NULL) is fixed. 2014-03-23 Araki Ken * x_imagelib.c: c_sixe.c is included instead of c_imagelib.c. * c_sixel.c: Separated from c_imagelib.c. * kik_debug.c: Whether errno is 0 or not is checked in kik_error_printf(). * version.h.in: 3.3.4 -> 3.3.4post 2014-03-22 Araki Ken * 3.3.4 released. (tag "rel-3_3_4") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.4. 2014-03-22 Araki Ken * java/MLTermPty.java: env_for_dialog is explicitly set NULL after ml_term_open_pty(). * ml_pty.h, java/Makefile.in: OPEN_PTY_ASYNC is always disabled on java/win32. 2014-03-21 Araki Ken * ml_vt100_parser.c: - OSC 1337 support is added. (Disabled by default though) - Control characters escape 0x07 and 0x1b are available in Pt of OSC Ps;Pt ST(BEL). 2014-03-19 Araki Ken * fb/x_display.c: Compiler error is fixed if ENABLE_2_4_PPB is defined. 2014-03-17 Araki Ken * xlib/x_font.c, win32/x_font.c: x_calculate_char_width() checks if characters whose width is ambiguous should be drawn one by one. * registobmp/main.c: Minor fixes. 2014-03-16 Araki Ken * registobmp/main.c: - (C) option of C command is supported. - (S) option of T command is supported. - "" quotation of T command is supported. * registobmp/Makefile.in: @exec_prefix@ is added. * README, doc/ja/README.ja: Updated. 2014-03-16 Araki Ken * registobmp/main.c: Error check of TTF_RenderUTF8_Blended() is added. 2014-03-15 Araki Ken * registobmp/main.c: "F" and "C" commands are implemented. * ml_screen.c: normal_edit::bce_ch and alt_edit::bce_ch are synchronized when changing from normal buffer to alt buffer and vice versa. * c_imagelib.c: STARTF_FORCEOFFFEEDBACK is set in executing registobmp. 2014-03-12 Araki Ken * c_imagelib.c: convert_regis_to_bmp() works on USE_WIN32API and __CYGWIN__. * x_display_x68kgrf.c: kik_priv_{restore|change}_e{u|g}id() are called before and after open("/dev/grf0"). (Thanks to @tsutsuii san) * registobmp/main.c: - Substitute strsep is added. - The default font is changed from "arial.ttf" to "c:\\Windows\\Fonts\\arial.ttf" on win32. - The implementation of strsep() is added in case it doesn't exist. * registobmp/Makefile.in: @KIK_CFLAGS@ is added. * ml_screen.c: BCE fg/bg color is reset in switching to the alternate screen buffer. 2014-03-11 Araki Ken * c_imagelib.c, mlimgloader/gdiplus.cpp, mlimgloader/none.c, ml_vt100_parser.c: ReGIS is partially supported by using registobmp. * tool/registobmp/*, configure.in: registobmp is added. 2014-03-09 Araki Ken * x_screen.c: x_color_cache and x_color_manager are reloaded after loading a wall picture on NetBSD/OpenBSD 4bpp framebuffer. * fb/x.h, fb/x_display.c: prev_closest_pixel -> prev_closest_color * ml_vt100_parser.c: ReGIS sequence is stored in ~/.mlterm/*.rgs 2014-03-06 Araki Ken * x_event_source.c: The segfault caused by calling FD_ISSET(-1) if x11 forwarding failed is fixed. * im_uim.c: Hack for uim-mozc is added. * x_screen.c: The bug of get_config_intern() returning invalid stack pointer is fixed. 2014-03-04 Araki Ken * */x_display*.c, kik_pty_streams.c: kik_msg_printf() -> kik_error_printf() * kik_debug.c: strerror() is output in kik_error_printf(). * kiklib/configure.in, kik_config.h.in: errno.h check is added. * gdiplus.cpp, gdk-pixbuf.c, none.c: Help message is output to stderr instead of stdout where mlterm waits for image data. 2014-03-01 Araki Ken * x_main_config.c, x_display_x68kgrf.c: - The default value "separate_wall_picture" option is changed to true. * x_display_x68kgrf.c: - Merge https://gist.github.com/tsutsui/9285759. (Thanks to @tsutsuii san) - The default resolution is changed to 768x512x4. 2014-02-28 Araki Ken * doc/en/README.android: Updated. * android/jni/x_display.[ch]: locked = -1 on APP_CMD_TERM_WINDOW. 2014-02-28 Araki Ken * fb/x_imagelib.c: load_file() calls x_display_get_bitmap() on Android instead of executing mlimgloader. * MLActivity.java: getBitmap() which loads image files is added. * android/jni/x_display.[ch]: x_display_get_bitmap() which calls MLActivity::getBitmap() is added. * AndroidManifest.xml: android.permission.INTERNET is added. 2014-02-27 Araki Ken * kik_pty_streams.c: Control characters defaults macros are added for Android. * version.h.in: 3.3.3 -> 3.3.3post 2014-02-22 Araki Ken * 3.3.3 released. (tag "rel-3_3_3") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.3. * android/jni/x_display.c: Java_mlterm_native_1activity_MLActivity_visibleFrameChanged() doesn't change width and height of the display if new width or height is less than 50 pixels. 2014-02-20 Araki Ken * fb/x_display.c: - rotate_mouse_cursor_shape() is added. - if -rotate (right|left) option is specified on 8bpp or less framebuffer, rotate_display is set to 0 and rotate_mouse_cursor_shape() is called in x_display_open() to fall back to the normal shape. * fb/x_imagelib.c: Illegal memory access in resize_sixel() is fixed. * android/jni/Android.mk, java/Makefile.in: Minor fixes. 2014-02-19 Araki Ken * fb/x_imagelib.c: resize_sixel() is added to resize the sixel image to the screen size. * c_imagelib.c: - The sixel width is changed just after parsing the first line to reduce the cost of realloc_pixels() at the end of load_sixel_from_file(). - The step of increasing the width and height of the sixel image is changed to 512. * win32/x_imagelib.c, gdiplus.cpp, none.cpp: Minor fixes. * android/jni/kik_debug.h: kik_msg_printf outputs messages at ANDROID_LOG_INFO level. * android/build.sh: Minor fixes. * ml_char.c: Minor fixes. 2014-02-18 Araki Ken * doc/en/README.fb, doc/ja/README.fb, x_main_config.c: Minor fixes. * fb/x_display.c: - The width and height arguments of win->window_exposed was wrongly reversed. - Minor fixes of x_display_get_pixel() and x_display_put_image(). * android/jni/x_display.c: Display rotation is supported. 2014-02-17 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_display.c, fb/x_display_*.c: Counterclockwise rotation is supported. * x_screen.c, x_main_config.c: The value of "rotate_display" option is changed from true|false to none|right|left. 2014-02-16 Araki Ken * android/jni/x_event_source.c: ALooper_pollAll() doesn't block but exits in 750ms in order to show ime preedit or commit text immediately. * bengali.table: "\xcf\xe8\xcd\xe8\xd6\xdb\xa2" entry is fixed. * fb/x_display.c: The problem of drawing the mouse cursor in the rotated display is fixed. * android/jni/x_display.c: The symbol of x_display_rotate() is added. 2014-02-16 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * x_sb_screen.c: Segfault in changing "rotate_display" option dynamically is fixed. 2014-02-16 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * x_main_config.c, x_screen.c: "rotate_display" option is added. * fb/x_display.c, fb/x_display_*.c: Display rotation is supported. * ml_line.c: Typo is fixed. 2014-02-15 Araki Ken * ml_char_encoding.c: iso2022_illegal_char() which converts unicode pua to drcs before mkf_iso2022_illegal_char() is set to conv->illegal_char. * ml_drcs.[ch]: ml_convert_unicode_pua_to_drcs() and ml_convert_drcs_to_unicode_pua() are added. 2014-02-13 Araki Ken * bengali.table: "\xcf\xe8\xcd\xe8\xcd*" entries are fixed. 2014-02-12 Araki Ken * ml_str_parser.c: DRCS is converted to Unicode Private Area code point in next_char(). * ml_vt100_parser.[ch]: CSI ? 8800 h and CSI ? 8800 l are supported, and the conversion from DRCS to Unicode Private Area is disabled by default. (See http://github.com/saitoha/drcsterm/blob/master/README.rst) 2014-02-11 Araki Ken * README.indic: Updated. * win32/x_window.c: ExtTextOutW(ETO_GLYPH_INDEX) is used for drawing ISCII_BENGALI and ISCII_ASSAMESE text. * bengali.table: "\xe8\xcd" => "\xee" is added. * ml_char.c: is_zerowidth is stored in attr. 2014-02-09 Araki Ken * x_screen.c: The rectangle of the unfocused cursor is fitted to the cell size. * README.indic: Updated. * x_main_config.c: The default value of use_bidi option is false instead of true if -ind option is specified. * ml_term.[ch]: "use_ind = true" on the configuration protocol makes the value of use_bidi false, and vice versa. * ml_line_iscii.c: The lines not only which has iscii characters but also which had ones are redrawn to the end. 2014-02-09 Araki Ken * ml_vt100_parser.c: Indic scripts works if not_use_unicode_font=true. * x_screen.c: Even if ml_line_shape() returns NULL, continue processing. * ml_line.c: ml_line_shape() doesn't shape the line which doesn't contain RTL or ISCII characters. * ml_ctl_loader.h, ml_functbl_{bidi|iscii}.c, libctl/ml_line_{bidi|iscii}.c: ML_LINE_{BIDI|ISCII}_NEED_SHAPE and ml_line_{bidi|iscii}_need_shape() are added. * keyboard.c: bzero -> memset * indian.c: - isprint() which can return true for ISCII characters on some environment is removed. - bzero -> memset * bengali.table: The glyph index 0xe5 is mostly changed to 0xe6. * font.win32.indic: Integrated to font.win32. 2014-02-05 Araki Ken * bengali.table: Entries containig 0xab, 0xae, 0xaf, 0xb2, 0xc7, 0xd0, 0xd2, 0xd3, 0xd4, 0xe0, 0xe3, 0xe4 and 0xe7 are removed. 2014-02-04 Araki Ken * bengali.table: - Following entries are fixed. "*\xe8\xcd*" "\xb3\xe8\xd6\xe8\xcd*" "\xc6\xe8\xc5\xe8\xcd*" - "\xcd*" is converted to "\x5e*", not to "\xcc\x5e*". 2014-02-01 Araki Ken * README.indic: Updated. 2014-01-30 Araki Ken * x_display_wscons.c: https://gist.github.com/steleto/8671862 is partially merged. (Thanks to @tristelo) * x.h: KEY_KP5 is assigned to XK_KP_Begin not to XK_KP_5. 2014-01-29 Araki Ken * bengali.table: Following entries are fixed. "\xc2\xe8" "\xcf\xe8\xc2\xe8" * ml_vt100_parser.c: '\e9' -> '\xe9' * README.indic:Updated. 2014-01-27 Araki Ken * x_font_ft.c: FT_Set_Charmap(FT_ENCODING_APPLE_ROMAN) is called for ISCII fonts. * libtype/fc_wrapper.c, libtype/Makefile.in: libfc_wrapper.so which wraps libfontconfig.so by LD_PRELOAD and which overrides FcFreeTypeCharIndex() and FcCharSetHasChar() is added. * ml_vt100_parser.c: Characters with nukta of ISCII character sets except devanagari are put to the screen buffer. * ml_iscii.c: Each of ISCII_XXXX character sets is distinguished in ml_iscii(). * bengali.table: - Following entry is added. "\xb7\xe8\xb5\xe1" => "\xe5\x86" "\xce\xe1" => "\xe3\xcc\x5e" "\xce\xe5" => "\xe5\xcc\x5e\xe7" - Following entries are fixed. "\xc2\xe8\xcd*" "\xca\xe8\xcd*" "\xd1\xe8\xcd*" "\xd1\xe8\xd1\xe8\xcd\xde" "\xd7\xe8\xc3\xe8\xcd*" * syllable.lex, indian.c: Full stop (ISCII 0xea, U+964) is supported. 2014-01-24 Araki Ken * x_screen.c: The behavior of selecting in mouse motion is changed like other X terminal emulators. 2014-01-24 Araki Ken * x_draw_str.c: Minor fixes of the previous commit. 2014-01-23 Araki Ken * ml_vt100_parser.c: nukta is always combined even if use_combining option is false. * x_draw_str.c: x_window_clear() is called once to clear background in x_draw_str_to_eol(). * hindi.table: - Following entries are added. "\xb3\xe8\xc2\xdc\xa2" => "\x48\xf2\xd3" "\xca\xe3" => "\xa4\xc9\xec" "\xd0\xe8\xcd" => "\xad\xaa\xc9" "\xd0\xe8\xcd\xda" => "\xad\xaa\xc9\xc9" - Following entries are fixed. "\xbd\xe8\xbd*" * assamese.table, bengali.table, gujarati.table, hindi.table, kannada.table, malayalam.table, oriya.table, punjabi.table, tamil.table: 0x23 glyph is removed. * libind/indian.[ch], syllable.lex: - 0xf1-fa is parsed as digit characters. - Minor fixes to improve performance and error handling. * man/mlterm.1, doc/en/README.indic, doc/ja/README.ja: Updated. 2014-01-21 Araki Ken * libtype/Makefile.in: Compilation error is fixed. 2014-01-20 Araki Ken * ml_screen.c: line->num_of_filled_chars never becomes more than line->num_of_chars in receive_scrolled_out_line(). * ml_char.[ch], ml_vt100_parser.c: ml_set_use_char_combining() is removed. * ml_iscii.c, ml_line_iscii.c, ml_vt100_parser.c: ISCII characters converted from unicode retain combining property. 2014-01-19 Araki Ken * ml_vt100_parser.c: Characters with nukta of not only devanagari but also other indic languages are converted from unicode to ISCII. 2014-01-19 Araki Ken * ml_logical_visual_iscii.c: Logicalizing iscii characters is simplified by ml_line_iscii_logical(). * ml_line_iscii.[ch]: ml_line_iscii_logical() is added. * ml_vt100_parser.c: The conversion table from U+90c and U+960-963 to ISCII is added. * hindi.table: ISCII "\xaa\xe9"(== U+9600) => FONT "\x41\xf1" is added. * syllable.lex: {VOWELS}{VOWMOD}?, {VOWMOD}{NUKTA}? and {NUKUTA} are integrated to {VOWELS}?{VOWMOD}?{NUKUTA}? to parse "\xaa\xe9"(=={VOWELS}{NUKTA}). 2014-01-18 Araki Ken * ml_vt100_parser.c: U+950 and U+958-95e are converted to two ISCII characters. * ml_line_iscii.c, ml_logical_visual_iscii.c, ml_screen.c: - The number of characters in lines is increased if visual iscii glyphs need more. It is decreased as before when iscii characters are converted to logical. - iscii_render_line() is called from iscii_visual_line() in ml_logical_visual_iscii.c. * ml_iscii.c: - The rendering of iscii characters in ml_iscii() is fixed. - ml_iscii_copy() copied has_iscii flag. * ml_logical_visual_bidi.c: Cleanup code. * x_screen.c: Minor fixes. 2014-01-12 Araki Ken * x_display_freebsd.c: Configuration for M_PC98_EGC640x400 is added. * x.h, x_display_wscons.c: size_t plane_len is changed to size_t plane_offset[8] in Display structure. * doc/ja/Usage.win32: Added. 2014-01-11 Araki Ken * MLActivity.java: - NativeContentView and TextInputConnection inner classes are added to support Google IME. - IME is hidden on pause and shown on restart. * android/jni/x_event_source.c: commitText and preeditTexit native methods which output text from IME are added. * xwindow/Makefile.in: fb/x_display_*.c are added to the dependency of x_display.o on framebuffer. * xwindow/libtype/Makefile.in: x_font_ft.c is added to the dependency of x_font_cairo.o and x_font_xft.o. 2014-01-05 Araki Ken * android/jni/main.c, MLActivity.java: unifont.pcf is saved in /data/data/mlterm.native_activity/files instead of /sdcard/.mlterm. * x_screen.c: Fixes because of the changes of x_window.[ch]. * win32/x_window.c, xlib/x_window.c, x_window.h: - x_window_send_picture_selection() which sends double-clicked picture to other windows via clipboard. - x_window_send_selection() is renamed to x_window_send_text_selection(). 2014-01-01 Araki Ken * MLActivity.java: Minor changes around input method window in onCreate(). * android/jni/x_display.c: If no root window has been shown yet, width and height of x_display_t and yoffset of Display are changed immediately in Java_mlterm_native_1activity_MLActivity_visibleFrameChanged(). * android/jni/x_display.c, MLActivity.java: Double-click at the right bottom corner of the screen calls showSoftInput() which is added to MLActivity. 2013-12-30 Araki Ken * x_display_wscons.c: 8 bpp on OpenBSD/luna88k is supported. * ml_model.c: Minor fixes. * mlterm/Makefile.in, ml_vt100_parser.c: Read as large amount of data as possible from pty on NetBSD and OpenBSD framebuffer for old machines. 2013-12-30 Araki Ken * jni/Android.mk: -DKIK_DEBUG is removed. * doc/en/README.fb, doc/ja/README.fb: Updated. * mlcc/comm.c, x_im_candidate_screen.c: Minor fixes. 2013-12-28 Araki Ken * android/jni/x_display.c: - ANativeWindow_unlockAndPost() is not called in display_lock(). - AMotioinEvent_getY() - _display.yoffset 2013-12-28 Araki Ken * android/jni/x_display.c: _display.app = app in the first place in x_display_init() because x_display_lock() can be called from update_window() in init_window() if restarting mlterm from paused state. 2013-12-28 Araki Ken * android/jni/x_display.c, android/jni/x.h, MLActivity.java: yoffset is added to the members of Display and the argumens of MLActivity.visibleFrameChanged(). 2013-12-26 Araki Ken * mlimgloader/none.c, gdk-pixbuf.c, gdiplus.cpp: Help message is added. * x_screen.c: "switch" value is available for x_screen_set_config(). 2013-12-23 Araki Ken * fb/x_display_x68kgrf.c: x68k_set_tvram_cmap() and x68k_set_use_tvram_colors() are changed to static functions. * fb/x_display.[ch]: x_display_enable_to_change_cmap() is added. * version.h.in: 3.3.2 -> 3.3.2post 2013-12-22 Araki Ken * fb/x_display.c: Only if _display.pixels_per_byte is 8, multiple planes of scrolled lines are copied. 2013-12-21 Araki Ken * 3.3.2 released. (tag "rel-3_3_2") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.2. 2013-12-21 Araki Ken * fb/x_display.c: The bug which drew mouse cursor incorrectly on 4bpp is fixed. * gtk/vte.c: - The bug which disabled true transparency on roxterm just after it started is fixed. - Hack for roxterm works if it started as "x-terminal-emulator" or "exo-open --launch TerminalEmulator". * jni/x_display.c: x_display_set_use_ansi_colors() is added. * win32/x_window.c: x_window_{xct|utf}_selection_request() works as a thread. * ml_line.c: Segfault caused by zero column characters like 0x200e is fixed. 2013-12-19 Araki Ken * x_display_wscons.c: The palette of 4bpp framebuffer is initialized to monochrome if --depth 1 option is specified. * fb/x_display.c: put_image_124bpp() is fixed. * c_imagelib.c, fb/x_imagelib.c, fb/x_display.c: If the value of "use_ansi_colors" option is false on 4bpp framebuffer, the colors used by the wall picture are set to framebuffer palette by x_display_set_use_ansi_colors() and x_display_set_cmap(). * win32/x_window.c: Fix error check of OpenClipboard(). * x_main_config.c: Even if the default value is specified for "use_urgent_bell", "exit_backscroll_by_pty", "allow_change_shortcut", "allow_scp", "use_clipboard", "use_alt_buffer", "use_ansi_colors" and "leftward_double_drawing", it is applied. 2013-12-18 Araki Ken * fb/x_display.c: Fix the 4 bpp specific bug. 2013-12-18 Araki Ken * fb/x_display.c: Fix typo. * mlimgloader/gdk-pixbuf.c: It is possible to convert image format by mlimgloader [windowid] [width] [height] [src path] [dst path]. 2013-12-17 Araki Ken * doc/en/README.win32, doc/ja/README.win32: Updated. * doc/en/README.ssh, doc/ja/README.ssh: Added. * libptyssh/ml_pty_ssh.c: Agent authentication is tried only if no password is specified. 2013-12-15 Araki Ken * x_font_ft.c: FC_CHAR_WIDTH is not used for US-ASCII font on xft. 2013-12-15 Araki Ken * ml_vt100_parser.c: U+2580 - U+259f is never Embolded by double drawing. * man/mlterm.1, README.ja, etc/main, etc/main.ja: Updated. * fb/x_font.c, fb/x_window.c, x_font_ft.c, x_window_cairo.c, x_window_xft.c, win32/x_font.c, win32/x_window.c, xlib/x_font.c, xlib/x_window.c, x_font_cache.[ch], x_font.h, x_main_config.c: "leftward_double_drawing" option is added. 2013-12-14 Araki Ken * libptyssh/ml_pty_ssh.c: Opening a new channel after creating a session works non-blocking for multi-threading. 2013-12-11 Araki Ken * x_picture.c: Double free of file names of inline pictures is fixed. * c_imagelib.c: Wrong address of free() is fixed. 2013-12-11 Araki Ken * c_imagelib.c: - DCS P q without any parameters separated by ; is accepted. - Pan;Pad;Ph;Pv is ignored. * ml_term.c: The bug of pty_args_new() which didn't clone env correctly is fixed. 2013-12-10 Araki Ken * fb/x_display.c: The bug of calculating the address of each plane in x_display_fill_with() and x_display_copy_lines() is fixed. * x.h, fb/x_display_wscons.c, fb/x_display.c: plane_len is added to Display. 2013-12-10 Araki Ken * fb/x_display.c: x_display_fill_with() and x_display_copy_lines() support 4 bpp. * kiklib/configure.in: NSLinkModule is enabled only if no other dynamic loader is found. 2013-12-09 Araki Ken * mlterm.1, doc/en/README.fb, doc/ja/README.fb, gtk/INSTALL: Updated. * fb/x_display.c: plane > 0 => _disp.depth > 0 in put_image_124bpp(). * x_color_manager.[ch], x_screen.c, vte.c: x_color_manager_change_alpha() -> x_change_true_transbg_alpha(). * mc_bgtype.c, mlconfig/po/*.po: Transparent => Pseudo transparent. 2013-12-08 Hayaki Saito * c_imagelib.c: Change DECGNL(-) behavior to move the active position to the "beginning" of the next line. 2013-12-07 Araki Ken * fb/x_display.c, x_display_wscons.c: 16 color mode by 4 planes is supported on NetBSD/luna68k framebuffer. * x_imagelib.c: Sixel loaders for both 1 and 32 bpp are built in on NetBSD and OpenBSD. * c_imagelib.c: It is enabled to include c_imagelib.c with SIXEL_1BPP after including it without it. 2013-12-07 Araki Ken * libptyssh/ml_pty_ssh.c, ml_pty_ssh.c, ml_pty.h, ml_term.c: ml_pty_ssh_new() gets thread safe by directly calling set_use_multi_thread() which was ml_pty_ssh_set_use_multi_thread() originally. * ml_pty.h, ml_term.h: OPEN_PTY_ASYNC macro is moved from ml_term.h to ml_pty.h. 2013-12-06 Araki Ken * ml_term.c: ml_pty_ssh_set_use_multi_thread() is called before and after ml_pty_new(). * libptyssh/ml_pty_ssh.c: ml_pty_ssh_set_use_multi_thread() which enables or disables multi threading of openssl/libssh2 is added. * configure.in: -lcrypto is specified with -lssh2 on win32. 2013-12-03 Araki Ken * c_imagelib.c: GdkPixbufLoader is used instead of g_unix_input_stream_new(). * main.c, libptyssh/ml_pty_ssh.c: main_tid used in ml_pty_ssh.c is initialized not in ml_pty_ssh.c but in main.c. 2013-12-02 Araki Ken * x_screen.c, x_event_source.c: Minor fixes. 2013-12-02 Araki Ken * x_screen.c: Typo which disabled to paste UTF8 string is fixed. 2013-12-01 Araki Ken * x_screen.c: The limitation of the column width and the line height (< 32) is removed. 2013-11-30 Araki Ken * ml_vt100_parser.c: U+200c-200f and U+202a-202e aren't converted even if -n option is specified. 2013-11-28 Araki Ken * fb/x_display.c: The bug which ignored win->hmargin and win->vmargin in calling win->window_exposed() in expose_window() is fixed. (If large value was specified for --border option, hidden input method window wasn't cleared.) * fb/x_display.c, fb/x_virtual_kbd.c, fb/x_window.c, x_window_cairo.c, x_window_xft.c, win32/x_window.c, win32/x_xic.c, x_im_candidate_screen.c, x_im_status_screen.c, x_main_config.c, x_main_config.h, x_sb_screen.c, x_screen.[ch], x_screen_manager.c, x_scrollbar.c, x_window.h, xlib/x_window.c, xlib/x_xic.c: "inner_border" option accepts [horizontal border],[vertical border]. * kik_sig_child.c: Wait multiple zombie processes for one SIGCHLD signal. 2013-11-24 Araki Ken * x_screen_manager.c: Memory leak when opening pty fails on win32gdi is fixed. * x_event_source.c: receive_next_event() assumes that ml_term_get_master_fd() could return -1 in opening pty asynchronously on cygwin or mingw. * ml_term.[ch]: ml_term_open_pty() works asynchronously on cygwin or mingw. * version.h.in: 3.3.1 -> 3.3.1post 2013-11-23 Araki Ken * 3.3.1 released. (tag "rel-3_3_1") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.1. * README, man/mlterm.1, doc/en/PROTOCOL, doc/en/README.win32, doc/ja/README.win32: Updated. 2013-11-22 Araki Ken * x_screen.c, ml_vt100_parser.c: "snapshot" is moved from x_screen.c to ml_vt100_parser.c. * mlcc/main.c: Arguments of commands except mlclient, snapshot, show_picture and scp aren't enclosed by "". 2013-11-20 Araki Ken * MLTermPty.c: ml_set_use_scp() -> ml_set_use_scp_full(). * x_picture.c, x_screen.c: Minor fixes. 2013-11-19 Araki Ken * c_imagelib.c: -L option is added to curl. * mlimgloader/gdk-pixbuf.c, xlib/x_imagelib.c: Minor fixes. 2013-11-16 Araki Ken * configure.in: Don't link an external image library such as gdk-pixbuf on win32gdi or framebuffer even if --with-imagelib option is specified. 2013-11-16 Araki Ken * fb/x_window.c: draw_string() which causes segfault by illegal surrogate pairs is fixed. * xlib/x_font.c: https://bugzilla.novell.com/attachment.cgi?id=566444 (https://bugzilla.novell.com/show_bug.cgi?id=849342) is applied. * README.ja, man/mlterm.1: Updated. * ml_logs.[ch], ml_screen.h, ml_term.h, x_screen.c, x_sb_screen.c, x_screen_manager.c, x_main_config.[ch], vte.c: "logsize" option accepts "unlimited" which unlimits the number of lines of backscroll logs. * mlcc/main.c: The argument of set_shortcut command isn't enclosed by "". 2013-11-10 Araki Ken * ml_pty_ssh.c: Minor fixes around processing path. * mlcc/main.c: Arguments of exec command are always enclosed by "". 2013-11-10 Araki Ken * ml_pty_ssh.c, ml_vt100_parser.c: ml_set_use_scp() in ml_vt100_parser.c is moved to ml_pty_ssh.c as ml_set_use_scp_full(). * libptyssh/ml_pty_ssh.c: ml_pty_ssh_poll() doesn't check while scp is executing. * kik_path.h: IS_RELATIVE_PATH() is added. * doc/ja/README.fb, doc/ja/README.win32, doc/en/PROTOCOL: Updated. 2013-11-06 Araki Ken * x_event_source.c, xlib/x_display.c: XFlush() is called directly in x_event_source.c, not in x_display.c. 2013-11-04 Araki Ken * im_ibus.c: --im ibus:[conversion engine] is available. 2013-11-04 Araki Ken * im_ibus.c: ibus 1.5 is supported on framebuffer. 2013-11-03 Araki Ken * im_ibus.c: ibus 1.5 is supported on x11. * ml_term.[ch]: Following functions are changed to macros. ml_term_set_bidi_mode ml_term_set_use_ind ml_term_set_vertical_mode ml_term_set_use_dynamic_comb * ml_vt100_parser.[ch]: Following functions are changed to macros. ml_vt100_parser_set_use_char_combining ml_vt100_parser_set_use_multi_col_char ml_vt100_parser_set_logging_vt_seq ml_vt100_parser_set_unicode_policy ml_vt100_parser_set_use_auto_detect 2013-11-03 Araki Ken * ml_vt100_parser.c: Auto encoding detection is a little improved. * ml_vt100_parser.[ch], ml_term.h, x_screen.c: ml_{term_}reset_pending_vt100_sequence() which resets pending DCS sequence on ESC key is added. 2013-11-02 Araki Ken * ml_vt100_parser.c: Minor fixes. * mkf_sjis_conv.c: The bug of converting to shift jis is fixed. * etc/main, etc/main.ja: Updated. 2013-11-02 Araki Ken * mlterm.1, README.ja, PROTOCOL: Updated. * ml_vt100_parser.c: ESC $ is available on non-ISO2022 encodings such as UTF-8. * ml_vt100_parser.[ch], ml_term.h, x_screen_manager.c, x_screen.c, x_main_config.[ch]: "use_auto_detect" and "auto_detect_encodings" options are added. 2013-10-27 Araki Ken * README.androind: Updated. * android/build.sh, Android.mk: Support fribidi. * version.h.in: 3.3.0 -> 3.3.0post 2013-10-27 Araki Ken * 3.3.0 released. (tag "rel-3_3_0") * configure.in, mlterm.spec, main/version.h.in, MLTermPty.c, android/jni/version.h, doc/en/ReleaseNote: updated for 3.3.0. 2013-10-26 Araki Ken * ml_vt100_parser.c, x_screen.c: OSC 5379 logging_msg, word_separators, use_alt_buffer, use_ansi_colors, unicode_noconv_areas and allow_scp are moved from x_screen.c to ml_vt100_parser.c. * MLTermPty.c: - Minor fixes around some options. - ONLY_USE_UNICODE_BOXDRAW_FONT is alwasy enabled. 2013-10-24 Araki Ken * x_screen.c: Button3 motion event doesn't start selecting on libvte. * kik_conf.c: Illegal memory access is fixed. 2013-10-23 Araki Ken * x_screen_manager.c: config_saved() is called in x_screen_manager_startup() on android. * x_screen.c: - OSC 5379 snapshot rejects file names containing "..". - OSC 5379 selected_text is removed. - OSC 5379 paste is rejected. * x_screen.c, x_shortcut.[ch]: SWITCH_OSC52 shortcut is removed. (Use "proto:allow_osc52=switch" instead.) * ml_vt100_parser.c, x_screen.c, x_main_config.c: OSC 5379 scp is disabled by default, while "allow_scp" option is added. * ml_vt100_parser.c: - The illegal memory access in ml_set_unicode_noconv_areas() is fixed. - OSC 5383 requests challenge sequence. * ml_screen.c: The bug of freeing static data is fixed. 2013-10-22 Araki Ken * win32/x_window.c: The bug which makes the window smaller than necessary in resizing is fixed. 2013-10-21 Araki Ken * fb/x_display_wscons.c, fb/x_imagelib.c: BBGGRR style wsdisplay is supported. (Thanks to @oshimayja san) * ml_model.[ch], ml_edit.c: Overflowed lines are scrolled out in ml_edit_resize(). (ml_model_get_num_of_filled_rows() is added.) * MLActivity.java: mkdir("/sdcard/.mlterm") before saving unifont.pcf. 2013-10-20 Araki Ken * doc/en/README.android: Added. 2013-10-20 Araki Ken * android/build.sh: target is changed from android-10 to android-14. * android/jni/Android.mk: -DDEBUG and -DKIK_DEBUG are added. * android/AndroidManifest.xml: android.app.NativeActivity -> mlterm.native_activity.MLActivity * MLActivity.java, x_display.c, x_window.c: - The terminal screen is resized by the software keyboard. - AKEY_EVENT_ACTION_MULTIPLE is processed. * android/jni/main.c, x_screen_manager.c: x_screen_manager_suspend() which closes only screen objects is called instead of main_loop_final() at the end of android_main() in order to make mlterm activity restartable. * MLActivity.java, android/jni/main.c, fb/x_font.c: unifont.pcf packed in the apk package is saved in /sdcard/.mlterm/ and loaded by default on startup. * android/jni/x.h, fb/x.h: width_bi -> width_full * ml_char_encoding.c: "auto" encoding is UTF-8 on Android. 2013-10-15 Araki Ken * man/mlterm.1, doc/ja/README.ja, doc/en/PROTOCOL: Updated. * ml_vt100_parser.[ch], x_main_config.c, x_screen.c: ml_set_unicode_fixed_areas() is added, and unicode_fixed_areas (a.k.a --ucsnoconv) option is added. * ml_char.[ch], x_font_config.c: ml_char_add_unicode_area_font() is added and font configuration files support "U+XXX-XXX" key which designates a font of specific unicode area. * BIWIDTH => FULLWIDTH, NARROW => HALFWIDTH 2013-10-12 Araki Ken * x_display_x68kgrf.c: - The number of resetting T-VRAM palette in changing wall pictures is decreased. - Wall picture is never drawn in the Left and right margin of virtual keyboard. - TP_COLOR is changed from 8 to 12. * doc/en/PROTOCOL: Updated. * fb/x_screen.c: "locale" is added to OSC 5379 protocol. * fb/x_main_config.c: "locale" option is added. 2013-10-11 Araki Ken * fb/x_display_x68kgrf.c, fb/x_imagelib.c, common/c_imagelib.c: x68k_set_use_tvram_colors() and x68k_set_tvram_cmap() are added. * fb/x_display_netbsd.c -> fb/x_display_wscons.c, fb/x_display_x68kgrf.c 2013-10-10 Araki Ken * fb/x_display_freebsd.c, fb/x_display_netbsd.c, fb/x_display_linux.c: Platform dependent stuff is separated from fb/x_display.c. 2013-10-10 Araki Ken * fb/x_main_config.c: --multivram / separate_wall_picture option is added. * fb/x_window.c, fb/x_display.c: x68k_tvram_set_wall_picture() and x68k_tvram_is_enabled() are added to show the wall picture on the text vram and to improve the performance of scrolling with the wall picture. * x_virtual_kbd.c: normal_pixmap and pressed_pixmap are swapped on 1bpp to make normal keyboard visible. 2013-10-09 Araki Ken * main/main.c: main.c was overwritten by android/jni/main.c at the revision 2098. It reverts to the revision 2097. 2013-10-06 Araki Ken * android/jni/x_display.c: _display.button_state is not changed if action & AMOTION_EVENT_ACTION_POINTER_INDEX_MASK is 0. 2013-10-04 Araki Ken * fb/x.h, fb/x_display.h: CLKED, NLKED, SLKED, ALKED macros are moved from x.h to x_display.h. * x_screen_manager.c, fb/x_imagelib.c, fb/x_font.c, kik_path.c: #ifdef __ANDROID__ is added. * android/: Support Android native-activity. * x_screen.c, vte.c: malloc() is used instead of alloca() in copying text to avoid the failure of alloca(). * ml_edit.c: Minor fixes of ml_edit_restore_cursor(). 2013-09-24 Araki Ken * ml_edit.c: Wraparound is stopped on DECRC. * android/: Minor fixes. 2013-09-21 Araki Ken * x_font.c: "Courier New" font is used by default. * x_dnd.c: #include for cygwin_conv_to_posix_path. * kik_path.h: cygwin_conv_to_posix_path is replaced by cygwin_conv_path on cygwin. * android/: Minor fixes. 2013-09-18 Araki Ken * kik_dlfcn_win32.c, tool/mlimgloader/none.c, gdk-pixbuf.c, gdiplus.cpp: #include for cygwin_conv_to_win32_path. * kik_path.h: cygwin_conv_to_win32_path is replaced by cygwin_conv_path on cygwin. * configure.in: Fixed typo. * android/: Minor fixes. 2013-09-17 Araki Ken * fb/x_display.c: The result of ioctl(WSDISPLAYIO_SETGFXMODE) is ignored. * tool/mlimgloader/Makefile.in: Fix for Cygwin/X. 2013-09-10 Araki Ken * ml_pty.c: ml_pty_get_slave_name() returns /dev/vptyN instead of /dev/ptyN if connected to the remote host. 2013-09-08 Araki Ken * ml_vt100_parser.c: The bug of storing not only sixel graphics data but also following sequence to ~/.mlterm/*.six is fixed. * ml_bidi.c: PICTURE_CHARSET is considered. 2013-09-08 Araki Ken * ml_vt100_parser.[ch]: 'yield' member which is used to exit the parser of vt100 sequence as soon as possible after OSC 5379 show_picture is added to ml_vt100_parser_t. 2013-09-04 Araki Ken * fb/x_display.c: Mouse is supported on NetBSD/x68k. * etc/color: Updated. 2013-09-03 Araki Ken * win32/x_window.c: AltGr+VK_OEM* which can cause WM_*_CHAR message later aren't converted to Ctrl+*. * win32/x.h: VK_Clear (Keypad key 5) is assigned to XK_Begin. 2013-09-01 Araki Ken * configure.in, fb/x_display.c, fb/x_imagelib.c: Whether the port on NetBSD is x68k or not is checked by in configure. 2013-08-29 Araki Ken * win32/x_window.c: AltGr+key is supported. * ml_edit.c: Minor fixes. 2013-08-27 Araki Ken * ml_edit.c: - The bug which erased the end character of each line in scrolling if DECSLRM set the right margin at the right end is fixed. - The bug of DL/IL which scrolled the screen instead of insert or delete lines from the cursor position. * win32/x_window.c: - x_xic_filter_event() is called before win->key_pressed for WM_SYSKEYDOWN message in x_window_receive_event() to make Mod+XXX shortcut key settings work. - Hack for AltGr is added in x_window_receive_event(). 2013-08-24 Araki Ken * mkf_locale_ucs4_map.c: get_map_ucs4_to_func_for_current_locale() never changes a cached map function after the first call. * mkf_ucs4_map.c: mkf_map_ucs4_to() doesn't cache the map functions of non ISO2022 cs (GBK etc), in order not to map the following chars automatically to GBK etc if a ucs4 character is mapped to the one of GBK etc which doesn't exist in GB2312 etc. 2013-08-21 Araki Ken * version.h.in: 3.2.2post -> 3.2.3pre * ml_vt100_parser.c: - OSC ? 80 h (disable sixel scrolling) is (ad-hoc) supported. - A sixel next line character (-) is sent after a sixel dump. 2013-08-20 Araki Ken * win32/x_window.c: The background raster operation of MaskBlt is changed from PATCOPY to 0xaa0029 which draws nothing to the destination device context. * x_screen.c: x_window_set_bg_color() is called in x_screen_reset_view() because RGB of the window bg color can be changed. * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_display.c: 1024x768x1 is supported on NetBSD/x68k. 2013-08-16 Araki Ken * fb/x_display.c, ml_color.c, c_imagelib.c: Threshold to determine the closest pixel is changed from 31 to 640. * fb/x_display.c, fb/x.h: prev_pixel and prev_closest_pixel which cache the closest pixel previously found in the color palette are added to Display. 2013-08-15 Araki Ken * x_screen_manager.c: x_display_reset_cmap() is called in color_config_updated(). * fb/x_display.[ch]: - x_cmap_reset() is renamed to x_display_reset_cmap(). - cleanup. 2013-08-15 Araki Ken * fb/x_display.c: orig_reg is copied from 768x512x4 crtc and videoc (except videoc.r2 = 0x20) instead of being copied from reg in order not to slide the screen on exit. 2013-08-14 Araki Ken * fb/x_display.c: Cleanup code for NetBSD/x68k. 2013-08-13 Araki Ken * fb/x_display.c: open_display() on NetBSD is separated to open_display() for wscons and open_display() for x68k. 2013-08-12 Araki Ken * x_main_config.c: "fb_resolution" option is available on NetBSD/x68k framebuffer. * fb/x_display.c, fb/x_imagelib.c: /dev/grf1 support for NetBSD/x68k is added. * mkf/configure.in, mkf/libtbl/Makefile: If --disable-dl-table is not specified, don't make at libtbl/. 2013-08-07 Araki Ken * fb/x_window.c: The bug of copy_area() which disabled redrawing the margin area is fixed. * version.h.in: 3.2.1 -> 3.2.1 post 2013-08-06 Araki Ken * 3.2.2 released. (tag "rel-3_2_2") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.2.2. 2013-08-05 Araki Ken * main.c: If __argv is NULL on win32, dummy_argv ({"mlterm",NULL}) is used instead. 2013-08-04 Araki Ken * kiklib/configure.in: socklen_t of winsock is checked. * win32/x.h: _WINSOCK2_H is not defined unless __CYGWIN__ or __MSYS__ to fix compilation error with i686-pc-mingw32-gcc. * win32/x_xic.c: CFS_POINT is replaced by CFS_FORCE_POSITION and x_xic_set_spot() in x_xic_set_focus() is removed. 2013-08-04 Araki Ken * win32/x_xic.c: - Y of the preedit position is fixed. - x_xic_set_spot() is called in x_xic_set_focus(). 2013-08-03 Araki Ken * kik_dlfcn.c, x_event_source.c, main/main.c: kik_dl_close_all() is called at the end of main() instead of atexit(kik_dl_close_all). * x_xim.c: Fix segfault in x_xim_final(). 2013-08-03 Araki Ken * kik_dlfcn.c: Double free is fixed. * x_screen.c: If screen->term != NULL is checked in window_unfocused() in case of receiving unfocus event after screen->term was deleted. (especially for win32.) * win32/x_xic.c: x_xic_font_set_changed() is called in x_xic_set_focus(). * man/mlterm.1, doc/ja/README.ja: Updated. * x_main_config.c: The range of "inner_border" option is changed from 0-127 to 0-224. 2013-08-01 Araki Ken * win32/x_xic.c, x_font_manager.c: x_xic_font_set_changed() and x_get_fontset() are implemented on win32. * doc/ja/README.win32, doc/en/README.win32, etc/main, etc/main.ja: Updated. * win32/x_window.c: If the returned value of GlobalLock() or GetClipboardData() is NULL or not is checked. * x_main_config.[ch]: "skip_dialog" option is changed to "always_show_dialog" and the default behavior is reversed. * x_screen_manager.[ch]: main_config.default_server is temporarily replaced by uri of the current pty in open_screen() and open_pty(). * ml_term.[ch]: - 'host' (uri) argument of ml_term_open_pty() is kept. - ml_term_get_uri() is added. * main.c: kik_dl_close_all() is called at the end of main(). * kik_dlfcn.c: - close_at_exit() is renamed to kik_dl_close_all() - kik_dl_close_all() closes from the last loaded library. 2013-07-26 Araki Ken * kik_dlfcn.c: Compilation error is fixed. * gdiplus.cpp: The leak of resources is fixed. 2013-07-24 Araki Ken * ml_pty_ssh.c: Compilation error is fixed. 2013-07-23 Araki Ken * ml_pty_ssh.[ch]: - x11_callback is always set. - Each session has its own use_x11_forwarding option. - "ssh_session_t *" is added to the argument of ml_pty_ssh_set_use_x11_forwarding(). * winrs.rs, x_connect_dialog.h, win32/x_connect_dialog.c, fb/x_connect_dialog.c, xlib/x_connect_dialog.c, x_main_config.[ch], x_screen_manager.c: X11 forwarding checkbox is added to the connection dialog. * x_main_config.c: Minor fixes. 2013-07-22 Araki Ken * libssh2/ml_pty_ssh.c, common/c_imagelib.c: fclose() -> pclose() 2013-07-20 Araki Ken * x_main_config.c: The range of "inner_border" option is changed from 0-255 to 0-127. * x_event_source.c: - ml_pty_ssh_poll() is used in receive_next_event(). - ml_pty_ssh_send_recv_x11() is not called after ml_term_parse_vt100_sequence() but called before it. * MLTerm.java, MLTermApplet.java: Thread.sleep() is used to change the executing thread instead of wait/notify(). * MLTermPty.c: - Compilation error is fixed. - Version number is fixed. (3.0.11 -> 3.2.1) - ml_pty_ssh_poll() is used in waitForReading(). - ml_pty_ssh_send_recv_x11 is called in nativeRead() instead of waitForReading(). * libssh2/ml_pty_ssh.c: - ml_pty_ssh_poll() which checks waiting data on pty and x11 channel by libssh2_poll_channel_read() is added. - MAX_NUM_OF_X11 which limits the number of X11 channels is removed. 2013-07-19 Araki Ken * win32/x_display.c: Not only GetMessage() but also PeekMessage() is called on win32 GDI. * ml_pty.h, ml_pty_pipewin32.c, libssh2/ml_pty_ssh.c, x_screen.c: PostThreadMessage() is used instead of ml_pty_listener_t::read_ready. * libssh2/ml_pty_ssh.c: - X11 forwarding is supported on win32. - The shortage of alloca() memory for xauth command is fixed. 2013-07-18 Araki Ken * kik_config.h.in: _BSDTYPES_DEFINED macro is added to avoid compilation error of i686-pc-mingw32-gcc at winsock2.h. 2013-07-17 Araki Ken * libptyssh/ml_pty_ssh.c: Compilation error on win32 is fixed. * mkf_tblfunc_loader.c, ml_iscii.c, ml_pty_ssh.c, x_imagelib.c, x_im.c, x_type_loader.c: kik_dl_close_at_exit() is called with handles created by kik_dl_open(). * kiklib/src/Makefile.in: 15.0 -> 15.1 * kik_dlfcn.c: Added. (kik_dl_close_at_exit() is added.) * win32/x_window.c: - button_motion event isn't called if mev.{x|y} are the same as prev_button_press_event.{x|y}. - Clipboard operations are fixed. * configure.in, kiklib/configure.in: *-*-mingw-gcc is supported. 2013-07-16 Araki Ken * x_event_source.c: Minor fixes to improve the performance of x11 forwarding. * libptyssh/ml_pty_ssh.c: - LIBSSH2_FLAG_COMPRESS is not enabled if x11 forwarding is enabled because LIBSSH2_FLAG_COMPRESS might fail to decompress highly compressed data. - libssh2_channel_x11_req_ex() is called with untrusted xauth data. - bidirection argument is added to ml_pty_ssh_send_recv_x11(). 2013-07-13 Araki Ken * vte.c: Whether VteTerminal is realized or not is checked in setting WINDOWID environmental variable in ml_term_open_pty_wrap(). (Segfault with synaptic 0.80 is fixed.) * gtk/vte.c: "logging_vt_seq" option works. 2013-07-12 Araki Ken * libptyssh/ml_pty_ssh.c: Workaround for libssh2/cygwin. 2013-07-12 Araki Ken * README, doc/ja/README.ja: Updated. * libptyssh/ml_pty_ssh.c: SSH agent authentication and forwarding are supported. 2013-07-06 Araki Ken * ml_line_bidi.c: The cursor position in inserting RTL characters after one LTR character (and vice versa) is fixed. (There were no problem in inserting RTL characters after two or more LTR characters.) 2013-06-30 Araki Ken * x_display.c: Minor fixes. 2013-06-30 Araki Ken * ml_vt100_parser.c: DECALN(ESC#8) resets the screen margins. * x_display.c: Support for touch screen on NetBSD/OpenBSD is added. (Experimental) 2013-06-30 Araki Ken * configure.in: configure error which --with-gui=xlib,fb option causes is fixed. * version.h.in: 3.2.1 -> 3.2.1 post 2013-06-29 Araki Ken * 3.2.1 released. (tag "rel-3_2_1") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.2.1. * man/mlterm.1, gtk/INSTALL, doc/ja/README.win32, doc/en/README.win32: Updated. 2013-06-28 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * x_virtual_kbd.c: The trigger to start software keyboard is changed from the click at the bottom of the screen to the double click at the right bottom corner. 2013-06-27 Araki Ken * ml_edit.c: The behavior of ml_edit_goto_beg_of_line(), ml_edit_copy_area() and ml_edit_erase_area() in origin mode is fixed. * ml_vt100_parser.c, ml_edit.h, ml_screen.h: Relative-origin position of the cursor is reported to CPR sequence. 2013-06-25 Araki Ken * x_display.c: - The bug which leaves the cursor shape in the virtual keyboard area is fixed. - EV_ABS events are processed on Linux framebuffer. * x_virtual_kbd.c: - x_is_virtual_kbd_event() is added. - x_virtual_kbd_stop() is renamed to x_virtual_kbd_hide(). 2013-06-25 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * x_virtual_kbd.c: Error handling is fixed. 2013-06-24 Araki Ken * x_virtual_kbd.c, fb/x_imagelib.c, fb/x_display.c: Minor fixes. 2013-06-23 Araki Ken * fb/x_display.c: get_ps2_kcode() is added to convert usb keycode to ps2 keycode for iBus on NetBSD/OpenBSD framebuffer. * x_virtual_kbd.c: kbd.six and pressed_kbd.six are used instead of kbd.png and pressed_kbd.png. * doc/kbd/kbd.six, doc/kbd/pressed_kbd.six, doc/kbd/Makefile.in: Replace kbd.png and pressed_kbd.six. 2013-06-22 Araki Ken * configure.in: doc/kbd is added to MAKE_DIRS and doc/kbd/Makefile is added to OUTPUT_FILES. * fb/x_virsual_kbd.[ch], fb/x_display.c, fb/x.h, fb/Makefile.in: Software keyboard support is added on framebuffer. * fb/x_virtual_kbd.[ch], doc/kbd/: Added. 2013-06-20 Araki Ken * ml_edit.c: ICH is disabled if the cursor is outside of the left and right margins * mc_font.c: The bug which outputs unchanged fontname is fixed. * etc/key: Minor fixes. * x_font_config.c: Minor fixes. 2013-06-18 Araki Ken * fb/x_font.c: The default font of bold ISO8859-1 or ISO10646-UCS4-1 is doubly drawn. 2013-06-17 Araki Ken * xlib/x_font.c, x_font_ft.c: use_medium_for_bold argument is removed from the functions of xft and cairo. * x_font.c: If "-*-bold-*-" is unable to be loaded on xcore, retry "-*-medium-*-" which is drawn doubly. * x_font_ft.c: The column width of italic fonts is always treated as variable on xft. * x_font_config.c: If DEFAULT=-foo-bar-medium-r-*--%d-*- is specified in ~/.mlterm/font, -foo-bar-bold-r-*--%d-*-, -foo-bar-medium-i-*--%d-*- or -foo-bar-bold-i-*--%d-*- are automatically searched for a bold, italic or bold italic font. * kik_str.[ch]: kik_str_replace() is added. 2013-06-12 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * x_main_config.c: "geometry" option is disabled and the default value of cols and rows is not 80x24 but 1x1 on framebuffer. 2013-06-12 Araki Ken * ml_edit.c: CURSOR_IS_INSIDE_MARGIN() is not checked in scroll_{up|down}ward_region() for vim. 2013-06-11 Araki Ken * ml_edit.c: - The bug of the cursor position in scrolling in ml_edit_overwrite_chars() is fixed. - scroll_{up|down}ward_region() doesn't scroll if the cursor is outside of the scrolling region. 2013-06-11 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * ml_char.[ch], ml_color.c: 16 and 231 aren't treated as ML_FG_COLOR and ML_BG_COLOR internally but as 256 colors. 2013-06-11 Araki Ken * xlib/x_font.c: "fixed" fonts are preferred to other fonts if nothing is specified in ~/.mlterm/font. 2013-06-10 Araki Ken * ml_edit.c: Bug fixes of insert_chars(). * ml_cursor.[ch]: ml_cursor_reset_col_in_char() is removed. 2013-06-10 Araki Ken * ml_edit.[ch], ml_screen.h, ml_vt100_parser.c: DECLRMM(CSI ? 69 h / CSI ? 69 l) and DECSLRM(CSI pl;pr s) are supported. * ml_vt100_parser.[ch], ml_term.c: use_bidi flag is added to ml_vt100_parser_t in order to determine whether ml_is_arabic_combining() should be called. 2013-06-09 Araki Ken * ml_char.c: The bug of ml_char_code_equal() is fixed. 2013-06-08 Araki Ken * x_screen.c: x_window_set_selection_owner() is called after the selected region is decided in order not to let parcellite reset the selected region. 2013-06-07 Araki Ken * man/mlterm.1, doc/ja/README.ja, doc/ja/README.fb: Updated. * fb/x_window.c: draw_string() supports surrogate pair. * x_shortcut.c: The bug which disabled Control+Button1 and Control+Button3 is fixed. * mkf_char.[ch]: mkf_char_to_int() is changed from function to macro. * MLTermPty.c, MLTerm.java, Style.java: Italic font style is supported. * ml_char.[ch], ml_font.h, ml_line.c, ml_screen.[ch], ml_str.c, ml_str_parser.c, ml_vt100_parser.[ch], fb/x_font.c, x_font_ft.c, win32/x_font.c, x_draw_str.c, x_font.h, x_font_config.c, x_im.h x_im_candidate_screen.c, x_im_status_screen.c, x_picture.[ch], x_screen.c, xlib/x_font.c, libctl/ml_bidi.[ch], libctl/ml_iscii.c, libctl/ml_line_bidi.c, libctl/ml_line_iscii.c, libctl/ml_shape_bidi.c, libctl/ml_shape_iscii.c: - ml_char_t::bytes == 32 bits attr == 16 bits => code == 24 bits attr == 24 bits and related ml_char_*() functions are changed. - is_italic is added to ml_char_t::attr. - FOO_ITALIC key is available in ~/.mlterm/*font* files. * x_screen.c: - Window is always resized according to the size of the pty in x_screen_attach(). - Even if Button6 or Button7 is pressed, the reversed fg and bg colors of the selected region aren't restored. 2013-06-03 Araki Ken * x_im_status_screen.c: The number of drawing string is reduced. * fb/x_font.c: Segfault if pcf.gz file is illegally gzipped is fixed. 2013-06-02 Araki Ken * fb/x_font.c, etc/font-fb: The default fonts of ISO10646_UCS4_1 and ISO8859_1_R are not defined in etc/font-fb but in fb/x_font.c. * x_screen_manager.c: Error messages in the failure of x_font_manager_new() are simplified. * x_font_config.[ch]: x_get_charset_name() is added. * xlib/x_window.c: The type for 32-bit format data of XChangeProperty() is changed to u_long. (SF Bug #3614192) * kiklib/src/Makefile.in: 14.3 -> 15.0 (SF Bug #3614142) 2013-06-01 Araki Ken * fb/x_display.[ch], x_window.c, x_im_{candidate|status}_screen.[ch]: Input method window on framebuffer is improved. * fb/x_display.c: Segfault in closing input method status window is fixed. * x_screen_manager.c: Minor fixes. 2013-05-29 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_display.c, main_loop.c: Minor fixes. 2013-05-28 Araki Ken * fb/x_display.c: Segfault in x_font_t::x_off > 0 is fixed. (Thanks to @tsutsuii san) 2013-05-27 Araki Ken * main_loop.c: "fb_resolution" option is added for OpenBSD framebuffer. * fb/x_display.c: OpenBSD support is added. * etc/font-fb: JISC6226_1978, JISX0208_1990 and JISX0213_2000_1 are defiend as &JISX0208_1983. * mkf_ucs4_map.c: mkf_map_ucs4_to_jisx0213_2000_1 is not cached in mkf_map_ucs4_to() to prefer JISX0208 to JISX0213 all the time. * version.h.in: 3.2.0 -> 3.2.0 post 2013-05-26 Araki Ken * 3.2.0 released. (tag "rel-3_2_0") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.2.0. * kiklib/src/Makefile.in, mkf/lib/Makefile.in: Fixes for SunOS make. * win32/x_window.c: Compilation error on msys-dtk is fixed. * win32/x.h: Minor fixes. * fb/x_display.c: - ENABLE_2_4_PPB is added. 2 and 4 ppb are disabled by default. - _display.back_fb is free'ed in x_display_close_all(). 2013-05-24 Araki Ken * fb/x_font.h: x_get_bitmap_line() and x_get_bitmap_cell() are changed from functions to macros to be always inlined even if compiled with -Os option. * fb/x_window.c: Optimization of draw_string(). 2013-05-23 Araki Ken * kik_util.h: BIT_MSBFIRST macro is removed. * fb/x_font.[ch], fb/x.h: LSB first glyphs are converted MSB first in loading the font, x_get_bitmap_cell() is simplified and glyphs_same_bitorder member is removed from XFontStruct. * fb/x_window.c: Optimization of draw_string(). * win32/x.h: #define WINVER 0x0500 is added. * fb/x_window.c, fb/x_display.[ch], x_font.[ch]: The previous commit of adding const modifier is cancelled. 2013-05-22 Araki Ken * fb/x_window.c, fb/x_display.[ch], x_font.[ch]: const modifier is added. 2013-05-22 Araki Ken * fb/x_window.c: Minor optimization of draw_string(). * ml_vt100_parser.c: get_home_file_path() is added to remove duplicated codes. 2013-05-21 Araki Ken * x_screen.c: ESC [ 1 ; * A is output instead of ESC O 1 ; * A if modifier keys + arrow key is pressed in applicatio cursor key mode. (Thanks to Mohammad_Alsaleh) * fb/x_display.c: Minor fixes. 2013-05-19 Araki Ken * x_shortcut.c: - Button*Mask is disabled until Button* is specified in ~/.mlterm/key to avoid such a problem as http://sourceforge.net/mailarchive/message.php?msg_id=30866232 - The bug which disabled "UNUSED" key is fixed. * fb/x_display.c: Optimization of put_image_124bpp. 2013-05-19 Araki Ken * kik_util.h, fb/x_font.c: BIT_MSBLEFT => BIT_MSBFIRST * fb/x_display.c: BIT_MSBLEFT => VRAMBIT_MSBRIGHT * fb/x_window.c: Segfault in draw_string without bg_color (for example in drawing a candidate window of input method plugin) is fixed. 2013-05-17 Araki Ken * fb/x_display.c: Off by one error in put_image_124bpp is fixed. * fb/x_window.c: Optimization of draw_string() for 1bpp. 2013-05-16 Araki Ken * fb/x_display.c: Optimization of put_image_124bpp() and x_display_fill_with(). * fb/x_imagelib.c: Check of sixel picture size is fixed. 2013-05-15 Araki Ken * fb/x_display.c: The bug of draw_mouse_cursor_line() is fixed. 2013-05-14 Araki Ken * x_screen.c, x_font_manager.c: Whether usascii_font_cs is actually changed or not is checked in usascii_font_cs_changed(). * fb/x_window.c: - Mistake of need_fb_pixel in the previous commit is fixed. - Optimization of draw_string(). - Hack in x_window_resize() is applied if scrollbar is hidden. * fb/x_display.c, fb/x_window.c: x_display_fill_with() for 8 or less bpp is added, and x_window_fill_with() uses it. 2013-05-12 Araki Ken * fb/x_display.c, fb/x_window.c: need_fb_pixel argument which triggers memchr( BG_MAGIC) is added to put_image_124bpp. 2013-05-12 Araki Ken * fb/x.h, fb/x_display.c: Display structure has shift_0 and mask members which stores the result of FB_SHIFT_0() and FB_MASK(). 2013-05-12 Araki Ken * fb/x_display.c: All possible memmove is replaced by memcpy. * c_imagelib.c: realloc_pixels() is called before correct_height() because correct_height() expects the width of pixels to be curtailed. * ml_char.c: Optimization of ml_char_size(). * kik_conf.c: The initial size of kik_conf_entry_t table is changed from 128 to 16 to speed up starting mlterm. * doc/en/README.fb, doc/ja/README.fb: Updated. 2013-05-11 Araki Ken * kik_map.h: Uninitialization of KIK_MAP::hash_func is fixed. * kik_map.h, kik_conf.c, ml_color.c, mc_im.c, x_font_cache.c, x_font_config.c: 'result' argument is removed from kik_map_get(). * doc/en/README.fb, doc/ja/README.fb: Updated. 2013-05-10 Araki Ken * kiklib/src/Makefile.in: MAJOR.MINOR 14.2 => 14.3 * kik_unistd.h: #include is added for putenv. * x_font_cache.c, x_font_config.c: font_hash => kik_map_hash_int * kik_map.[ch]: - kik_map_hash_int_fast() is added. - DEFAULT_MAP_SIZE is changed from 128 to 16. - (map)->pairs_array is allocated in kik_map_get_pairs_array() instead of kik_map_new_with_size(). - The bug which erases data unexpectedly in shrinking the map size is fixed. 2013-05-09 Araki Ken * fb/x_imagelib.c: Minor fixes. * x_screen.c: F12 => F10 to invoke benchmark. 2013-05-08 Araki Ken * fb/x_display.[ch]: - x_display_get_fb() -> get_fb() (static function) - "Display * display" argument is removed from x_display_get_pixel(), x_display_put_image(), x_display_copy_lines() and x_display_reset_cmap() which is renamed to x_cmap_reset(). - "fb_cmap_t * cmap" argument is removed from x_get_closest_color() which is renamed to x_cmap_get_closest_color(). - x_cmap_get_pixel_rgb() is added. * fb/x_font.[ch]: x_get_bitmap_line() and x_get_bitmap_cell() are changed to inline static functions. 2013-05-07 Araki Ken * mlimgloader/Makefile.in: Compilation error on framebuffer is fixed. * fb/x_display.c, fb/x_window.c: Optimization. * configure.in: If --disable-shared option is specified, --disable-dl-ctl, --disable-kbd, --disable-dl-type, --disbale-dl-table and --without-scrollbars options are automatically specified. 2013-05-06 Araki Ken * c_imagelib.c: Workaround for the pixel aspect ratio is added. * fb/x_font.c: - The returned value of system("gunzip fontfile") is ignored because it may return -1 with errno=ECHILD even if it succeeds. - If a unicode font of biwidth characters is loaded, the width of U+3000 is used. (Hack for efont-unicode (b*.pcf.gz)) 2013-05-06 Araki Ken * mkf/Makefile.in, kiklib/Makefile.in: The dependency of collect-headers target is clarified. * Makefile.in, mkf/Makefile.in, tool/mlconfig/Makefile.in: "cd xxx" is enclosed by (). * x_font_manager.[ch]: x_get_usascii_font() is changed from function to macro. 2013-05-06 Araki Ken * doc/ja/README.fb, doc/en/README.fb: Updated. * x_screen.c: - Benchmark which is invoked by XK_F12 is added to shortcut_match(). - Segfault in preediting at the lower left corner of the screen is fixed. 2013-05-04 Araki Ken * fb/x_display.c: The previous fix which caused segfault is fixed again. 2013-05-04 Araki Ken * fb/x_display.c: The bug of drawing the mouse cursor if ENABLE_DOUBLE_BUFFER is defined is fixed. * fb/x_window.c, x_draw_str.c: wall_picture_bg argument is added to draw_str() in x_window.c to optimize drawing string with wall picture. 2013-05-03 Araki Ken * fb/x_window.c: copy_area() is optimized. * fb/x.h, fb/x_display.c: Double buffering of 1,2 or 4 bpp framebuffer is added. 2013-05-03 Araki Ken * c_imagelib.c: correct_height() is added to try to correct the height of sixel graphics. 2013-05-02 Araki Ken * ml_char.c: ml_char_set() allows is_biwidth, is_comb, is_bold and is_underlined to be > 1. (This fixes the bug of use_dynamic_comb option.) * ml_logical_visual.c: Minor fixes. * fb/x_font.c, fb/x_window.c: x_get_bitmap_line() is added. * fb/x_font.h: Added. 2013-05-02 Araki Ken * fb/x_display.[ch], fb/x_window.c: x_display_copy_line() -> x_display_copy_lines() * fb/x_display.c, x.h: Display::fp -> Display::fb 2013-05-01 Araki Ken * fb/x_imagelib.c: If the difference between the specified height and the height of the loaded sixel picture is less than 6, they are regarded as the same ones. * fb/x_font.c: "% 8" is replaced by "& 7". * fb/x_display.c: - "% ppb" is replaced by "& (ppb - 1)". - Tune up FB_SHIFT. 2013-04-30 Araki Ken * x_screen.c: set_wall_picture() isn't called in window_realized() if the window is unmapped (== not resized to the screen size yet) in framebuffer. * fb/x_imagelib.c: load_sixel_1bpp_from_file() is added to tune up loading sixel graphics in 1bpp framebuffer. * c_imagelib.c: load_sixel_from_file() returns 1bpp bitmap data if SIXEL_1BPP is defined. 2013-04-28 Araki Ken * im_scim_mod_if.c: Fixed typo. 2013-04-28 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_display.c: The value of WSKBD environmental variable is used for the keyboard device. 2013-04-28 Araki Ken * x_display.c: Tune up drawing the wall picture in put_image_to_124bpp() and x_display_get_pixel(). * x_display.c, x_font.c: TOINT32 and TOINT16 macros are used to access fb and pcf fonts. * kik_util.h: BE32DEC, BE16DEC, LE32DEC, LE16DEC, TOINT32 and TOINT16 macros are added. 2013-04-27 Araki Ken * mlimgloader/Makefile.in: mlimgloader can be built without X11 library. * configure.in, mlcc/Makefile.in: configure script at the top directory generates Makefile of mlcc. * mlcc/configure, mlcc/configure.in, mlcc/config.h.in, mlcc/install-sh: Removed. 2013-04-22 Araki Ken * man/mlterm.1, doc/ja/README.ja, gtk/INSTALL: Updated. * x_screen.c, x_window.h, xlib/x_window.c, win32/x_window.c, fb/x_window.c: - "bel_mode" option accepts "sound|visual" value which enables both audible and visual bell. - "use_urgent_bell=true" works even if the value of "bel_mode" option is "none". * configure.in: --with-gui option can accept "xlib,fb" which means compiling both mlterm-xlib and mlterm-fb. 2013-04-21 Araki Ken * x_display.c: Minor fixes. 2013-04-21 Araki Ken * x.h, x_display.[ch], x_window.c: Experimental support for less than 8bpp/framebuffer is added. * x_imagelib.c, x_color.c, x_display.c: Drawing pictures is supported in 8 bpp/framebuffer. 2013-04-19 Araki Ken * x_screen.c: The wrong height of the preediting cursor of the input method plugin in the case of inner_border != 2 is fixed. (Thanks to @tsutsuii) * man/mlterm.1, doc/en/README.ja, doc/en/PROTOCOL: Updated. * x_main_config.c, x_screen.c: "use_urgent_bell" option is added. * x_window.h, xlib/x_window.c, win32/x_window.c: x_set_use_urgent_bell() is added for "use_urgent_bell" option. 2013-04-17 Araki Ken * x_im_candidate_screen.c, x_im_status_screen.c: x_window_clear_margin_area() is also called in redrawing the window frame. * fb/x_display.c: The number of redrawing input method window is decreased. 2013-04-17 Araki Ken * x_main_config.c: "ibus" is added to the message of --im option. (Thanks to @tsutsuii) * fb/x_display.c: Minor fixes. 2013-04-16 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Minor fixes. * fb/x_window.c: Minor fixes. 2013-04-15 Araki Ken * im_uim.c, im_ibus.c, fb/x.h: XK_Hiragana_Katakana is supported. * x_screen_manager.c, im_ibus.c, fb/x_display.c: Minor fixes. 2013-04-14 Araki Ken * fb/x_window.c: - x_window_resize() always calls clear_margin_area() for input method window. - x_window_map() calls clear_margin_area(). * fb/x_display.c: Minor fixes around IME window. * im_scim_mod_if.c: Candidate window is shown after the 2nd candidate. * im_ibus.c: "show-lookup-table" and "hide-lookup-table" events are processed in framebuffer. 2013-04-13 Araki Ken * README, doc/ja/README.fb: Updated. * configure.in, main/Makefile.in: -lpthread is added in compiling mlterm in NetBSD if ./configure is executed with --enable-ibus, --enable-ssh2 or --with-type-engines=cairo option unless --without-pthread is specified. 2013-04-13 Araki Ken * doc/ja/READBE.fb: Updated. * inputmethod/kbd/Makefile.in: libim-kbd.so -> libim-kbd-fb.so in framebuffer. 2013-04-13 Araki Ken * fb/x.h, win32/x.h: IsModifierKey() which is used by im_m17nlib.c is added. * doc/en/README.fb, doc/ja/README.fb: Updated. * libctl/ml_bidi.c: -> * im_m17nlib.c: Compilation error is fixed. * inputmethod/m17nlib/Makefile.in: libim-m17nlib.so -> libim-m17nlib-fb.so in framebuffer. * inputmethod/*/Makefile.in: Minor fixes. * x_im_candidate_screen.c: Minor fixes. * fb/x_display.c: /dev/wskbd is opened instead of /dev/wskbd0 because "wsconsctl encoding" command returns "encoding=unknown_0" if /dev/wskbd0 is opened. 2013-04-13 Araki Ken * fb/x_display.c: The region where input method window is opened is always exposed in moving it. 2013-04-12 Araki Ken * fb/x_display.c: The region where input method window is opened is always exposed in hiding it. * doc/en/README.fb, doc/ja/README.fb: Updated. * im_ibus.c: Framebuffer on Linux is supported. 2013-04-11 Araki Ken * im_ibus.c: "hide-preedit-text" signal is processed. * im_ibus.c, ibus/Makefile.in, fb/x.h, fb/x_display.c, configure.in: Framebuffer on NetBSD is supported. * im_scim_mod_if.c: Minor fixes. * x_im.c: Compilation error is fixed. 2013-04-08 Araki Ken * man/mlterm.1, README.ja, etc/main, etc/main.ja, doc/en/PROTOCOL: Updated. * x_screen.c, x_main_config.c, ml_vt100_parser.[ch], ml_term.h, x_font_manager.[ch], x_screen_manager.c, gtk/vte.c, main_loop.c: - "box_drawing_font" option is added. - It is possible to change "not_use_unicode_font" and "only_use_unicode_font" dynamically. * ml_char_encoding.c: ml_is_msb_set() is tuned up. 2013-04-06 Araki Ken * Makefile.in: install-fb target is added. * doc/en/README.fb, doc/ja/README.fb: Updated. * x_im.[ch], x_screen.c: - IM_API_VERSION 0x08 => 0x09. - get_display, get_font_man and get_color_man are removed from x_im_event_listener_t and get_unicode_policy is added. - ml_is_msb_set is removed from x_im_export_syms and ml_convert_to_internal_ch is added. * im_ibus.c, im_kbd.c, im_m17nlib.c, im_scim_mod_if.c, im_uim.c, x_im_candidate_screen.c: - ml_convert_to_internal_ch() is used for preedit or candidate characters. - MKF_BIWIDTH or MKF_AWIDTH property of preedit or candidate characters is always checked even if they are not ISO10646_UCS4_1. * ml_term.h, ml_vt100_parser.h: ml_{term|vt100_parser}_get_unicode_policy() is added. * ml_vt100_parser.c: ml_convert_to_internal_ch() is added. * fb/x_display.c, x_event_source.c: The minimum interval of autorepeating is changed from 50ms to 25ms. 2013-04-05 Araki Ken * fb/x_display.c: Autorepeat bug is fixed. 2013-04-04 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_imagelib.c: The bug which disabled sixel graphic images in 16bpp is fixed. * x_main_config.c: --contrast, --gamma, --bright and --pic options are removed if configure with --disable-image option. * main_loop.c: "wskbd_repeat_1" and "wskbd_repeat_N" options are added in NetBSD framebuffer. * x_event_loop.c: addional_fds::handler() is called every 50ms in NetBSD framebuffer. * fb/x.h, fb/x_display.c, fb/x_window.c: Support for NetBSD framebuffer. * ml_logical_visual.c: Inline pictures are correctly shown if use_dynamic_comb option is true. 2013-03-24 Araki Ken * x_screen_manager.c: If term hasn't been attached to screen yet, ml_term_change_encoding() is called instead of ml_term_write_loopback("\x1b]5379;encoding=...\x07") in open_pty_intern(). * fb/x_display.c: _mouse.button_state is reset when button is released in FreeBSD. * version.h.in: 3.1.9 -> 3.1.9 post 2013-03-23 Araki Ken * 3.1.9 released. (tag "rel-3_1_9") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.1.9. * libptyssh/ml_pty_ssh.c: gethostbyname() is used if getaddrinfo() doesn't exist. * win32/x.h: VK_OEM_{1|3|4} macros are defined. * script/config.guess, mkf/script/config.guess, kiklib/script/config.guess, script/config.sub, mkf/script/config.sub, kiklib/script/config.sub: Updated (timestamp='2013-02-12') * etc/main, etc/main.ja: Updated. 2013-03-22 Araki Ken * libptyssh/ml_pty_ssh.c: If libssh2_channel_{write|read}() returns LIBSSH2_ERROR_SOCKET_RECV, call kik_trigger_sig_child(). 2013-03-21 Araki Ken * x_shortcut.c: The bug which ignored ButtonMask in x_shortcut_match() is fixed. * etc/key: Examples are added. * x.h, win32/x.h, win32/x_window.c, fb/x_display.c: Button6 and Button7 (Tilt wheel) are supported. 2013-03-20 Araki Ken * mkf_parser.c: If parser->next_char() returns error, mkf_parser_increment() is called before continuting parsing. * x_screen.c: Window title string is always terminated by U+0000 in xterm_set_window_name() in win32. * README, doc/ja/README.ja: Updated. 2013-03-18 Araki Ken * x_screen_manager.c, accessories/google.sh: Minor fixes. * accessories/README: Added. * accessories/README.ja: Removed. 2013-03-16 Araki Ken * x_screen.c: mod_meta_mode=8bit works correctly in 8bit character encodings except ISO8859-1. * README, man/mlterm.1, doc/ja/README.ja, doc/ja/BUGS: Updated. * mlterm/libptyssh/Makefile.in, mlterm/libptyssh/ml_pty_ssh.c, mlterm/ml_pty_ssh.c: ml_pty_ssh is separated to a dynamically loaded module in platforms except win32. * ml_pty.h, ml_pty_ssh.c: ml_pty_(un)use_loopback() -> ml_pty_set_use_loopback() * kiklib/src/Makefile.in: MAJOR.MINOR: 14.1 -> 14.2 * kik_conf.c, kik_map.[ch]: kik_map_compare_str_nocase which compare strings ignoring case is added, and kik_conf uses it to check key strings of configuration files. * configure.in: --without-pthread option is added. 2013-03-14 Araki Ken * x_screen.c: mod_meta_mode=8bit works in win32. * win32/x_window.c, win32/x_xic.c: - Alt + symbol character works. - Control + @ works. 2013-03-13 Araki Ken * x_screen.c: If the value of mod_meta_mode option is 8bit, input character masked with 0x80 is encoded to the character encoding of pty. (Thanks to Vladimir Elisseev) * x_main_config.c: Typo fixed. 2013-03-11 Araki Ken * doc/en/PROTOCOL: Updated. * tool/w3m-remoteimg/README, README.ja: Moved to doc/en/README.w3m, doc/ja/README.w3m * tool/w3m-0.5.3-remoteimg.patch: Removed. (Moved to bitbucket repository.) * tool/tlex: Removed. (Moved to bitbucket repository.) 2013-03-10 Araki Ken * w3m-0.5.3-remoteimg.patch: Time to wait for the response of "\x1b[14t\x1b[18t" is changed from 0.1 sec to 0.5 sec. 2013-03-09 Araki Ken * mlclient/main.c: Extra space in arguments of OSC 5379 mlclient is removed. * w3m-remoteimg/README.ja: Minor fixes. * x_screen.c: Minor fixes. 2013-03-08 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * x_main_config.c: -P option is assigned as the short option as --clip, and -M option is as --im. * kik_conf.[ch]: kik_conf_set_default_value() is removed for buiding mlterm. * x_screen.c: --shortcut and --osc52 options which are specified as the arguments of OSC 5379 mlclient are ignored. 2013-03-07 Araki Ken * x_main_config.c, x_screen.[ch]: "allow_change_shortcut" option is added. * man/mlterm.1, doc/ja/README.ja: Updated. * configure.in: DEXPORT is set in Solaris. 2013-03-06 Araki Ken * doc/ja/README.w3m -> tool/w3m-remoteimg/README.ja doc/en/README.w3m -> tool/w3m-remoteimg/README * tool/w3m-remoteimg: Added. * tlex/main.c: The previous commit around disable_logging flag in parse_vtseq() is undone. 2013-03-05 Araki Ken * tlex/main.c: - tlex client skips parsing vt sequence in parse_vtseq(). - Wrong check of disable_logging flag in parse_vtseq() is fixed. * tlex/ChangeLog: Added. 2013-03-04 Araki Ken * c_imagelib.c, mlimgloader/Makefile.in: Minor fixes. 2013-03-02 Araki Ken * ml_config_menu.c: ml_pty_use_loopback() is called only if ml_pty_get_slave_fd() returns -1 like mlterm-3.1.7 or before. * configure.in, x_screen_manager.c: Minor fixes. 2013-02-28 Araki Ken * ml_vt100_parser.c: 0x90 is always processed as DCS. * fb/x_imagelib.c, win32/x_imagelib.c, xlib/x_imagelib.c, x_picture.[ch]: If --diable-image is specified to configure, nothing is compiled. * configure.in, c_imagelib.c, ml_term.c, ml_vt100_parser.c, mlimgloader/gdiplus.c, mlimgloader/gdk-pixbuf.c, mlimgloader/none.c, x_draw_str.c, x_screen.c: --enable-sixel option of configure (ENABLE_SIXEL macro) is replaced by --disable-image option (NO_IMAGE). * fb/x_display.c: Error message is added. 2013-02-28 Araki Ken * ml_vt100_parser.c: Fixes around parsing C1 characters. * mkf_iso2022_parser.c: C1 characters are regarded as US_ASCII like C0 ones instead of being ignored. * mkf_*_parser.c: If error happens in parsing sequence, the parsing position is reset. * mkf.c: Minor fixes. 2013-02-23 Araki Ken * README: Updated. * version.h.in: 3.1.8 -> 3.1.8 post 2013-02-23 Araki Ken * 3.1.8 released. (tag "rel-3_1_8") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.1.8. * win32/x_font.c: Type engines except TYPE_XCORE are rejected. * win32/x.h: Fix compilation error in msys-1.0. * x_screen_manager.c: Minor fixes. 2013-02-22 Araki Ken * win32/x_window.c, x_screen.c: DragAcceptFiles() is moved from x_screen.c to x_window.c. * ml_config_menu.[ch]: ml_config_menu_t::pid and ml_config_menu_t::fd are changed from pid_t and int to void * (==HANDLE). 2013-02-20 Araki Ken * x_screen.c: "vertical_mode" option is dynamically changeable. * fb/x_window.c: - x_window_resize() supports NOTIFY_TO_PARENT. - window_realized() event show nothing by setting win->is_mapped = 0 to prevent segfault in startup. 2013-02-16 Araki Ken * fb/x_window.c, fb/x_display.[ch]: Conversion from Keypad keys to ASCII character is moved from x_display.c to x_window_get_str() in x_window.c. 2013-02-16 Araki Ken * win32/x_window.c, win32/x_xic.c: F10 key is available. * win32/x_xic.c: Range check bug is fixed in x_xic_get_str(). * win32/x.h: - The definition of XK_Zenkaku_Hankaku, XK_Henkan_Mode and XK_Muhenkan is added. - Range check bug of IsKeypadKey() is fixed. 2013-02-15 Araki Ken * fb/x.h, fb/x_display.c: Numlock key is supported. 2013-02-13 Araki Ken * x.h, x_display.c: 0x100 is added to KEY_KPXX keys to distinguish them from the same code keys. 2013-02-12 Araki Ken * x.c: XStringToKeysym() supports Zenkaku_Hankaku, Henkan_Mode and Muhenkan. * fb/x_display.c: Zenkaku_Hankaku, Henkan_Mode and Muhenkan key syms are set from its scan codes. * doc/en/README.fb, doc/ja/README.fb: Updated. 2013-02-11 Araki Ken * fb/x_display.c: Minor fixes for FreeBSD termios. * fb/x.h: Minor fixes. * doc/en/README.fb, doc/ja/README.fb: Updated. 2013-02-10 Araki Ken * x_screen.c: The button state of any event mouse tracking is changed from 3 to 35. * x_sb_screen.c, x_window.c: The hack of repositioning windows when "scrollbar_mode" option is changed is moved from x_window_(un)map() to change_sb_mode(). 2013-02-10 Araki Ken * fb/x_display.c: Minor fixes. * x_im_status_screen.c: Minor fixes. * fb/x_window.c: clear_margin_area() is not called if flag is not specified to NOTIFY_TO_MYSELF in x_window_resize(). (Without this fix, segfault happens when kbd:arabic window is shown in the bottom of the screen.) * fb/x.h, fb/x_display.c: Keyboard mode is set to K_CODE instead of K_XLATE in order to handle modifier keys in framebuffer@FreeBSD. 2013-02-08 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x.h, fb/x_color.c, fb/x_display.c: Support for FreeBSD is added. * x_screen.c, x_screen_manager.c: Fixes for framebuffer. * x_scrollbar.c: The drawn area of draw_background() is fixed. 2013-02-03 Araki Ken * x_screen.c: Backscroll mode is not exited if pressing a mouse button. * ml_pty_ssh.c: Compression is enabled by libssh2_session_flag(). * version.h.in: 3.1.7 -> 3.1.7 post 2013-02-02 Araki Ken * xlib/x_imagelib.c, mlimgloader/gdk-pixbuf.c, c_imagelib.c: The function of creating GdkPixbuf from the specified path is integrated to gdk_pixbuf_new_from() in c_imagelib.c. 2013-01-30 Araki Ken * doc/ja/README.ja, man/mlterm.1, etc/key, etc/main, etc/main.ja, doc/en/PROTOCOL: Updated. * x_main_config.[ch]: -M/--menu, --button3 options are removed. * x_screen.c, x_screen_manager.c, vte.c: button3_open and conf_menu_path_[1-3] are replaced by x_shortcut using Button1-Button5. * x_screen.c: - The bug which didn't redraw a part of full-width characters in window_exposed() is fixed. - "set_shortcut" is added to configuration protocol. * x_shortcut.c: Button1-Button5 are available. * doc/en/README.fb: Added. * doc/en/README.w3m: Updated. 2013-01-26 Araki Ken * doc/ja/README.fb: Updated. * tool/mlimgloader/gdiplus.c: It is possible to be built with URL Monikers even if IID_PPV_ARGS macro is not defined. 2013-01-25 Araki Ken * win32/x_connect_dialog.c: exec_cmd is not freed. 2013-01-24 Araki Ken * ml_edit.c: The bug of copying overlapped area in ml_edit_copy_area() is fixed. 2013-01-22 Araki Ken * 3.1.7 released. (tag "rel-3_1_7") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.1.7. * fb/x_font.c: Whether a font has been already loaded or not isn't checked by its gunzipped file path but by the one specified in ~/.mlterm/font-fb. * xlib/x_font.c: 0 width glyph is accepted for showing indic characters. * tlex/main.c: The size of a log file is shrinked after excessing over 5MB. 2013-01-20 Araki Ken * tool/tlex: Added. 2013-01-15 Araki Ken * x_screen.c: "vertical_mode" is not dynamic changeable. * x_picture.c: THRESHOLD for inline pictures is changed from 24 to 48. * fb/x_window.c: - x_window_full_expose() and x_window_move_no_expose() are added. - If input method screen is opened, x_window_is_scrollable() which is implemented as a function instead of a macro returns 0. * fb/x_display.c: x_expose_window() is added. * fb/x_display.c, fb/x_window.c, fb/x.h: - XK_Return is defined as 0x0d instead of 0x0a. - Masking '@' ... '_' characters pressed with control key by 0x1f is moved from kcode_to_ksym() in x_display.c to x_window_get_str() in x_window.c. * im_uim.c, uim/Makefile.in, im_m17nlib.c, im_kbd.c, x_im.c: Fixes for framebuffer. * x_im_candidate_screen.c, x_im_status_screen.c: - x_im_status_screen.c uses x_window_full_expose() in framebuffer. - x_im_candidate_screen.c uses x_window_no_expose() in framebuffer. - line_height (x_im_status_screen alone), x and y members are added to place screen correctly. * x_screen.c: window_exposed() is tuned up. 2013-01-09 Araki Ken * x_picture.c: The bug of decreasing num_of_inline_pics wrongly after the failure of loading a picture is fixed. * win32/x_imagelib.c, xwindow/Makefile.in: If CreateProcess("mlimgloader.exe") failed, try "c:\cygwin\bin\mlimgloader.exe". * mlimgloader/gdiplus.c: is enclosed by extern "C" to fix compilation error. * c_imagelib.c: load_sixel_from_file() returns the pointer to cardinal + 2 in order to decrease the number of allocating and copying memory if gdk_pixbuf is not used. 2013-01-07 Araki Ken * win32/x_display.c, xlib/x_display.c, main.c: hide_console() is moved x_display.c to main.c. * win32/x_window.c: PlgBlt() is replaced by MaskBlt() in copy_area(). * x_draw_str.c: The number of calling x_window_copy_area() is decreased. * ml_drcs.[ch]: - ml_drcs_get() -> ml_drcs_get_font() - ml_drcs_get_glyph() is added. * xlib/x_window.c, x_gc.[ch]: The number of calling XSetClipMask() is decreased. 2013-01-04 Araki Ken * x_draw_str.c: Performance of draw_drcs() is improved. 2013-01-04 Araki Ken * x_draw_str.c: - Segfault in drcs using ESC(I is fixed. (Thanks to saitoha san) - Minor fixes for alpha mask. * fb/x_window.c, xlib/x_window.c, win32/x_window.c: x_window_copy_area() accepts alpha mask. * xlib/x_imagelib.c, x_imagelib.h, fb/x.h, win32/x.h: - Minor fixes for alpha mask. - Fix memory leak (double g_object_ref) of pixbuf of sixel graphics in load_file() in xlib/x_imagelib.c. * fb/x_imagelib.c, win32/x_imagelib.c: Alpha mask is loaded in x_imagelib_load_file() if necessary. * c_imagelib.c: Alpha value in sixel graphics is supported in load_sixel_from_file(). * ml_drcs.[ch]: ml_drcs_final_full() is added. 2013-01-03 Araki Ken * x_screen.c: x_window_fill() is used for preediting of input method plugins instead of x_window_draw_line(). * x_draw_str.c: x_window_fill_with() is used for drawing drcs instead of x_window_draw_line(). * xlib/x_window.c, win32/x_window.c, fb/x_window.c: x_window_draw_line() is removed. 2013-01-02 Araki Ken * win32/x_window.c: The point of x2/y2 is drawn in x_window_draw_line(). * Makefile.in, ml_vt100_parser.c, x_draw_str.c: DECDLD (DCS ... { ... ST) sequence is supported. * ml_drcs.[ch]: Added. * mkf_iso2022_parser.c, ml_vt100_parser.c: ISO2022 sequences like "ESC ( SP Ft" are accepted. * doc/ja/README.w3m: Updated. * x_picture.[ch]: Fixes around cleaning up inline pictures. 2012-12-30 Araki Ken * mlcc/comm.[ch], mlcc/main.c: - If OSC 5380 doesn't return anything, exit mlcc instead of segfault. - 1000 usec -> 10000 usec for select() in read_stdin_timeout(). * x_picture.c: Minor fixes around the timing of cleaning up inline pictures. 2012-12-29 Araki Ken * x_picture.c: Unused inline pictures aren't cleaned up until the number of inline pictures reaches 24. 2012-12-28 Araki Ken * ml_config_menu.c, ml_pty_pipewin32.c, mlimgloader/gdiplus.cpp, win32/x_imagelib.c: STARTF_FORCEOFFFEEDBACK is added to STARTUPINFO for CreateProcess(). 2012-12-28 Araki Ken * x_picture.[ch]: The inline picture which have the same file_path is shared. * x_draw_str.c: The position of drawing inline pictures following US ASCII characters is fixed. * ml_vt100_parser.c: The format of "show_picture" of configuration protocol is changed from "WxH clip WxH+X+Y" to "WxH WxH+X+Y". * doc/ja/README.w3m: Added. * tool/mlimgloader/gdk-pixbuf.c, xlib/x_imagelib.c: Remote access with curl is supported. * tool/mlimgloader/gdiplus.cpp: Remote access with URLMoniker is supported. 2012-12-24 Araki Ken * ml_vt100_parser.c: "show_picture" of configuration protocol accepts "clip WxH+X+Y" which clips region of the specified picture. 2012-12-23 Araki Ken * ml_vt100_parser.c: {save|restore}_cursor() aren't called in CSI ? 1047 h and CSI ? 1047 l. 2012-12-22 Araki Ken * fb/x_display.c: if(read() > 0) -> while(read() > 0) * x_screen.c: Memory leak in x_set_button3_behavior() is fixed. 2012-12-21 Araki Ken * x_screen.c: execv() -> execvp() in open_button3_command(). * kik_args.c: kik_arg_str_to_array() parsed "\ " as a normal space character not as an argument separator. * man/mlterm.1, README.ja: Updated. 2012-12-20 Araki Ken * x_im_candidate_screen.c, x_im_status_screen.c: Compilation error is fixed. 2012-12-19 Araki Ken * configure.in, mlterm/Makefile.in, xwindow/Makefile.in, ml_config_menu.[ch], xlib/x_imagelib.c: --disable-use-tools option is added to configure. 2012-12-18 Araki Ken * x_draw_string.c: "xfont->is_proportional && ! xfont->is_var_col_width" is replaced by draw_alone of x_calculate_char_width(). * xlib/x_font.c: Whether the width of U+2580 - U+259f whose width is ambiguous is the same as font->width or not is checked explicitly, because their glyphs of some fonts (e.g. GNU Unifont) are full width. * x_font.h, fb/x_font.c, win32/x_font.c, xlib/x_font.c, x_screen.c: draw_alone argument is added to x_calculate_char_width(). * etc/main, etc/main.ja: Updated. 2012-12-16 Araki Ken * xlib/x_display.c: #include is placed before Xlib.h is included in order to avoid compilation error in cygwin/X. * x_screen.c, win32/x_window.c: UTF8 text is supported for setting the window title by OSC 0 or OSC 2 in win32. * mlcc/comm.c: - Wait the next bytes until 0.01 second elapse in read_one(). ("\x1bOA" is separated to "\x1b", "O" and "A" without this in cygwin.) - The way of determining KEY_BS and KEY_DEL is fixed. - "use_ind", "alpha" and "use_clipboard" options are supported. * configure.in: Fix the way of checking the existence of gdiplus.h. 2012-12-15 Araki Ken * doc/en/README.win32, doc/ja/README.win32: Updated. * version.h.in: 3.1.6 -> 3.1.7pre * configure.in, xlib/x_imagelib.c: USE_EXT_IMAGELIB => BUILTIN_IMAGELIB 2012-12-14 Araki Ken * xlib/x_imagelib.c: - Illegal format of cardinal data is fixed. - Code cleanup. 2012-12-14 Araki Ken * xlib/x_imagelib.c: If gdk-pixbuf is not built in mlterm, "mlimgloader 0 0 0 path -c" creates cardinal data instead of creating cardinal from Pixmap. * fb/x_window.c: Minor fixes. * c_imagelib.c, mlimgloader/gdk-pixbuf.c: #ifndef USE_WIN32GUI -> #ifdef USE_X11 2012-12-13 Araki Ken * configure.in, tool/mlimgloader/Makefile.in, c_imagelib.c: Fixes for tool/mlimgloader/none.c. * tool/mlimgloader/none.c: Added. (none.c can handle sixel graphics alone.) * tool/mlimgloader/main.c -> gdk-pixbuf.c tool/mlimgloader/main_gdi+.cpp -> gdiplus.cpp * xwindow/win32/x_font.c: Font names like "Courier 10 Pitch" which was wrongly regarded as 10-point size "Courier" font is parsed correctly. 2012-12-12 Araki Ken * doc/en/PROTOCOL, doc/en/README.win32, doc/ja/README.win32: Updated. * x_screen.c, x_screen_manager.c, ml_term.[ch], ml_vt100_parser.[ch], ml_term_manager.[ch], vte.c, MLTermPty.c: - CSI 22 0..2 t and CSI 23 0..2 t are supported. - "title" is removed from configuration protocol. * configure.in, c_imagelib.c: Minor fixes for GDI+ support in win32. * tool/mlimgloader/main_gdk+.c: Added to support GDI+ not only gdk-pixbuf. * xlib/x_imagelib.c: create_pixbuf_from_cardinals() is disabled unless ENABLE_CARD2PIXBUF macro is defined. * x_font.c, x_window.c: libtype functions are correctly declared if libtype is statically linked to mlterm. * ml_logical_visual.h, ml_shape.h, ml_line.c: libctl functions are correctly declared if libctl is statically linked to mlterm. 2012-12-10 Araki Ken * mlimgloader/Makefile.in: -mwindows is added to link option in win32. * mlimgloader/main.c: Retry with cygwin_conv_to_win32_path(file_path) if load_file() fails in cygwin/msys. * mlimgloader/main.c, common/c_imagelib.c, xlib/x_imagelib.c: SIZE_MAX -> SSIZE_MAX 2012-12-09 Araki Ken * mlimgloader/main.c: setmode(STDOUT_FILENO, O_BINARY) in win32. * win32/x_imagelib.c: Minor fixes. 2012-12-08 Araki Ken * fb/x_imagelib.c, xlib/x_imagelib.c: kik_dl_open("libm.so") is tried not only with LIBMDIR but also without it. * fb/x_window.c: Segfault in starting mlterm with --pic option in framebuffer is fixed. * doc/en/README.win32, doc/ja/README.win32: Updated. * win32/x_imagelib.c, mlimgloader/main.c, mlimgloader/Makefile.in, c_imagelib.c, configure.in: - mlimgloader is possible to be built in win32. - Not only BMP format but also other image formats are supported in win32 by mlimgloader. - "contrast", "gamma" and "brightness" options are supported in win32. 2012-12-07 Araki Ken * x_screen.c: The pty size of ml_term_t is fit to the screen size when it is attached to x_screen_t in framebuffer. 2012-12-05 Araki Ken * libtype/x_font_ft.c: Font names like "Courier 10 Pitch" which was wrongly regarded as 10-point size "Courier" font is parsed correctly. 2012-12-04 Araki Ken * x_screen.c: - The bug of "button3_behavior" option rejecting "mlclient ..." command is fixed. - "mlclient ..." with "-e" and "--initstr" option can be specified in ~/.mlterm/key. 2012-12-01 Araki Ken * 3.1.6 released. (tag "rel-3_1_6") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.1.6. * ml_vt100_parser.c, ml_edit.[ch], ml_screen.h: DECCRA(CSI...$v) and DECERA(CSI...$z) are supported. 2012-11-30 Araki Ken * x_sb_view_factory.c: Memory leak is fixed. * ml_term.[ch], ml_vt100_parser.[ch], x_draw_str.c, x_picture.[ch], x_screen.[ch]: Sixel graphic pictures are divided to the screen cells. * MLTerm.java: F1-F20 key sequences are output. 2012-11-25 Araki Ken * sylalble.lex, lex.split.c: bzero() -> memset() * doc/en/README.fb, doc/ja/README.fb, gtk/INSTALL: Updated. (Ubuntu 12.04 -> Ubuntu 12.10) * vte.c: g_object_ref(pty) is called in vte_terminal_set_pty_object(). * version.h.in: 3.1.5post -> 3.1.6pre * configure.in: If --with-imagelib option is not specified, mlimgloader is always built. 2012-11-24 Araki Ken * win32/x.h, win32/x_xic.c: The conflict between 0x61 and 0x7a ('a' - 'z' <=> VK_K_MULTIPLY..VK_DIVIDE, VK_F1..VK_F11.NUMPAD1...9) is fixed. * ml_color.c: ~/.mlterm/color configurations for VT SYS colors (0x0-0x0f) are applied. (Thanks to Andi Cristian Serbanescu) 2012-11-23 Araki Ken * ml_config_menu.c, xlib/x_imagelib.c, fb/x_imagelib.c: Code cleanup around execv(). * configure.in: gio-2.0 is explicitly linked if gdk-pixbuf-2.0 is 2.14 or later. (Thanks to Lotus Shih and rabin_y) * man/mlterm.1, doc/ja/README.ja, doc/en/PROTOCOL: Updated. * x_main_config.c, x_screen.[ch]: --exitbs / "exit_backscroll_by_pty" option is added. 2012-11-22 Araki Ken * ml_color.c: ml_color_parse_rgb_name() returns RGB defined in ~/.mlterm/color. 2012-11-21 Araki Ken * ml_vt100_parser.c: Minor fixes. 2012-11-20 Araki Ken * MLTermPty.c: "use_ansi_colors" option is added to set_config(). * x_screen.c: Checking the argument of mlclient is moved from set_config() to x_screen_exec_cmd(). * ml_pty_unix.c: exit(1) is called explicitely if execv() failed. 2012-11-20 Araki Ken * mltracelog.sh: -b option is added to trachet. 2012-11-19 Araki Ken * gtk/INSTALL: Minor fixes. * tool/accessories/mltracelog.sh: Added. Note that mltracelog.sh depends on trachet. (http://pypi.python.org/pypi/trachet/). 2012-11-18 Araki Ken * gtk/INSTALL: Updated. * mlterm.spec: Fix the version number. * gtk/vte.c: - x_display_idling() is called in vte_terminal_timeout(). - Cursor blinking is enabled not only by VTE_CURSOR_BLINK_ON but also VTE_CURSOR_BLINK_SYSTEM. - vte_terminal_set_cursor_blinks() is implemented. 2012-11-17 Araki Ken * man/mlterm.1, README.ja, PROTOCOL: Updated. * ml_vt100_parser.[ch], x_screen.c, x_main_config.c: --colors / "use_ansi_colors" option is added. * gtk/vte.c: Duplicate code is removed. 2012-11-16 Araki Ken * man/mlterm.1, man/mlclient.1, doc/en/PROTOCOL, doc/ja/README.ja: Updated. * ml_vt100_parser.[ch], x_screen.c, x_main_config.c: --altbuf / "use_alt_buffer" option is added. * main_loop.c, gtk/vte.c, x_screen_manager.c: "click_interval" option is processed in x_screen_manager.c instead of main_loop.c and gtk/vte.c. 2012-11-15 Araki Ken * doc/ja/README.ja, man/mlterm.1: Updated. * version.h.in: 3.1.5 -> 3.1.5 post * ml_vt100_parser.[ch], x_screen.c: 3 byte rgb color sequence is supported. ([38;2;;;m and [48;2;;;m) * x_color_config.[ch], ml_color.[ch], x_color_cache.[ch]: - x_color_config.[ch] are integrated to ml_color.[ch]. - Color names defined in ~/.mlterm/color are not available for -fg, -bg, -sbfg and -sbbg options. * x_color.h, xlib/x_color.c, win32/x_color.c, fb/x_color.c: x_get_xcolor_rgb() -> x_get_xcolor_rgba() 2012-11-13 Araki Ken * mkf_ucs_property.table: - Updated to Unicode 6.2.0 (UnicodeData.txt and EastAsianWidth.txt) - U+0160 - U+01ff (Jamo medial vowels and final consonants) are treated as MFK_COMBINING|MKF_BIWIDTH. * x_draw_str.c: Minor fixes. 2012-11-12 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. 2012-11-11 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * ml_vt100_parser.c, main_loop.c, gtk.c: Unicode line drawing characters like U+2500 etc are converted to dec special ones if -Y option is specified. * x_screen.c: Minor fixes. 2012-11-11 Araki Ken * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_font.c: - glyph index in pcf font is casted to unsigned in order not to be minus if it is over 32767. - Gzipped pcf fonts are available. 2012-11-10 Araki Ken * x_termcap.[ch], x_screen.c: kh and @7 settings are applied in application cursor key mode. * etc/font-fb, doc/ja/README.fb, doc/en/README.fb: Minor fixes. 2012-11-07 Araki Ken * etc/font-fb: unifont.pcf is added. * fb/x_font.c: ":[Percentage]" format is supported. 2012-11-06 Araki Ken * 3.1.5 released. (tag "rel-3_1_5") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.1.5. 2012-11-06 Araki Ken * x_transparent_sample_sb_view.c: RIGHT_MARGIN is removed. * doc/ja/README.ja, man/mlterm.1: Updated. * x_screen.c, x_termcap.[ch]: k5 entry (ML_F5) is added. * xlib/x_window.c, fb/x_window.c, win32/x_window.c: clear_margin_area() is called before window_exposed(). (For x_im_candidate_screen.c:window_exposed.) 2012-11-05 Araki Ken * configure.in: Minor fixes. * doc/en/README.fb, doc/ja/README.fb, doc/en/PROTOCOL: Updated. * x_screen.c, xlib/x_window.c, fb/x_window.c, win32/x_window.c, x_window.h: - "update_all" is added to the configuration protocol. - x_window_update_all() is added for "update_all". 2012-11-04 Araki Ken * x_font_config.c: The way to specify fonts like JISX0213_2000_1=&JISX0208_1983 which means that the font specified for JISX0208_1983 is also used for JISX0213_2000_1 is supported. * fb/x_font.c: Minor fixes. * xlib/x_font.c, mc_font.c: "jisx0208.1983-0" is added to the font encoding candidates of JISX0213_2000_1. * xlib/x_font.c: The last element of cs_info_t::encoding_names is removed. 2012-11-03 Araki Ken * fb/x_display.c: /sys/class/input/inputN/name is checked instead of /sys/class/input/eventN/device/name to determine the type (keyboard or mouse). * doc/en/README.fb, doc/ja/README.fb: Updated. * fb/x_color.c: The bug which disabled any colors except black in 15,16,24,32 bpp is fixed. * x_sb_view.h, x_sb_view_factory.h: Support of x_sb_view_t version 0 is dropped. * extra/athena.c, extra/motif.c, extra/mozmodern.c, extra/next.c, pixmap_engine/pixmap_engine.c: extra scrollbars and pixmap_engine are migrated to x_sb_view_t version 1. * x_sample(2)_sb_view.c: malloc -> calloc. 2012-11-02 Araki Ken * libctl/dexport-fb.map: Added. (Symbolic link to dexport.map) * vte.c: Compilation error is fixed. * fb/x_color.c: "gray" and "lightgray" colors are available in 256 colors. * x_sb_view_factory.c: Backward compatibility of scrollbar plugins with the one before 2.4.0 is broken. * doc/ja/README.fb, doc/en/README.fb: Updated. * fb/x.h, fb/x_display, fb/x_simple_sb_view.c, fb/x_window.c, x_screen_manager.c, x_scrollbar.c, x_sample_sb_view_fb.c, x_sb_view_factory.c, configure.in, dexport-fb.map: simple and sample scrollbars are supported in framebuffer. * win32/x_xic.c: Typo is fixed. 2012-10-31 Araki Ken * x_display.c: - set_use_console_backscrolling() is added. - If the console of mlterm-fb is not active, events from /dev/input/event* aren't processed. - ioctl(EVIOCGRAB) to keyboard and mouse device is removed. * ml_vt100_parser.c: DCS sequence except DCS q is also parsed and ignored if sixel is enabled. 2012-10-30 Araki Ken * fb/x_window.c: Pixmap size check is added in x_window_copy_area(). * doc/ja/README.fb, doc/en/README.fb: Updated. * fb/x_display.c, fb/x_color.c, fb/x.h: - cmap is moved to Display structure. - Original cmap is restored at exiting. 2012-10-29 Araki Ken * fb/x_display.c: Set EVIOCGRAB to keyboard and mouse device. * fb/x_color.c: 8bpp support is added. * fb/x_display.c: Compilation error is fixed. 2012-10-28 Araki Ken * x_picture.c, x_screen.c: The (sixel etc) pictures are redrawn correctly in exiting backscrolling mode. * x_screen.c, x_selection.[ch]: The selection behavior of double or tripple clicking and dragging is fixed. (Thanks to Andi Cristian Serbanescu) * ml_vt100_parser.c: '4' which means sixel support is added to DA1 answerback string if configured with --enable-sixel opton. (Thanks to saitoha san) 2012-10-27 Araki Ken * doc/en/README.fb: Added. * etc/Makefile.in: font-fb is installed to $(SYSCONFDIR). * fb/x_window.c: clear_margin_area() is called in x_window_set_bg_color(). * x_window.h, {xlib|fb|win32}/x_window.c: x_window_clear_margin_area() -> clear_margin_area() [static] * x_font_config.c: "OSC 5379;font;..." works in framebuffer. * win32/x.c: '0' - '9' keys are available for ~/.mlterm/key. * fb/x_window.c: Whether font->height or font->ascent excesses the display height is checked in draw_string(). * fb/x_font.c: font->width is always the same or exactly double. * fb/x_display.c: The way to convert keys combined with the control key to control characters is fixed. 2012-10-26 Araki Ken * main_loop.c, fb/x_window.c, x.h , x_font_manager.c, x_main_config.c, x_screen.c, x_window.h: Minor fixes. 2012-10-26 Araki Ken * x_screen.c: Minor fixes. 2012-10-26 Araki Ken * fb/x.h, fb/x_display.c: Minor fixes. 2012-10-25 Araki Ken * doc/ja/README.fb: Updated. * fb/x_display.c, fb/x.h, fb/x_window.c: /dev/input/event* of keyboard is processed instead of read(STDIN_FILENO). 2012-10-24 Araki Ken * fb/x_display.c: Minor fixes. 2012-10-23 Araki Ken * doc/ja/README.fb: Updated. * fb/x_display.h, xlib/x_display.h: Added. * configure.in: Install mlterm-fb with -m 4755 -o root option for mouse support. * fb/x_display.c, fb/x_window.c, fb/x.h: Mouse support is added. (/dev/input/eventN device is used.) 2012-10-19 Araki Ken * fb/x_window.c: memmove is used instead of memcpy in copying overlapped area in framebuffer. (Thanks to uobikiemukot san) * tool/mlimgloader/main.c: Minor fixes. 2012-10-18 Araki Ken * configure.in: - Fix the way to search libm for pow(). - mlimgloader is possible to be built in --with-gui=fb. * doc/ja/README.fb: Updated. * fb/x_color.c: 15 and 16 bpp are supported. * fb/x_imagelib.c, fb/x.h, mlimgloader/main.c, c_imagelib.c: Wall picture and sixel graphics are supported except in 8 bpp. 2012-10-17 Araki Ken * README, doc/ja/README.ja, doc/ja/README.fb: Updated. * fb/x_window.c: Display width and height are applied forcibly even if x_window_resize() is called with any value. * fb/x_font.c: Initialize XFontStruct::ref_count in loading a new font. 2012-10-16 Araki Ken * main_loop.c, x.h, x_dislay.h, x_font.h, x_font_config.c, x_font_manager.c, x_main_config.c, x_screen_manager.c, x_window.h: Minor fixes for framebuffer support. * window/fb, doc/ja/README.fb, etc/font-fb: Added for framebuffer support. * win32/x.[ch]: - x_win32.[ch] -> x.[c] - XParseGeometry() is added. * x_picture.c: Overlapped pictures are removed when a new picture is added in x_picture_manager_add(). 2012-10-03 Araki Ken * ml_vt100_parser.c, x_screen.c: CSI 14 t and CSI 18 t are supported. * win32/x_display.c: Minor fixes. 2012-09-29 Araki Ken * ml_vt100_parser.c, x_screen.c: "?" of OSC 4, 10 and 11 is supported. * version.h.in: 3.1.4 -> 3.1.4 post 2012-09-28 Araki Ken * 3.1.4 released. (tag "rel-3_1_4") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.1.4. 2012-09-26 Araki Ken * ml_vt100_parser.c: CSI ? 8840 -> CSI ? 8428(RLogin original) * vte.c: Fix vte_terminal_set_word_chars(). * kik_str.h, x_imagelib.c: Minor fixes. 2012-09-23 Araki Ken * xlib/x_imagelib.c, mlimgloader/main.c: Fix memory leaks. * ml_str_parser.c: Fix uninitialized value of ml_str_parser::comb_left. 2012-09-23 Araki Ken * x_screen.c: Fix segfault caused by "remove_picture" configuration protocol with no argument. * c_imagelib.c: memcpy -> memmove. * xlib/x_imagelib.c, mlimgloader/main.c: Fix memory leaks. * x_selection.[ch], x_screen.c: x_sel_lock() is added to fix the problem of reverting back to selecting one character at a time by dragging the pointer after double- or triple-clicking. 2012-09-17 Araki Ken * x_imagelib.c, ml_vt100_parser.c: ~/.mlterm/picture.six is changed to ~/.mlterm/[pty name].six. * x_imagelib.c, mlimgloader/main.c, x_screen.c: Image files on remote hosts are available for the wall picture via network protocols supported by GVfs. 2012-09-15 Araki Ken * x_screen.c: Freeze in scrolling by CSI r is fixed. (Thanks to koie san) * dexport.map: http://ideone.com/N9xUw is merged. * ml_vt100_parser.c: Minor fixes around parsing sixel graphics sequence. 2012-09-13 Araki Ken * ml_vt100_parser.c: Continuous DCS/FF/GS/RS/US sequences are saved in one file (~/.mlterm/picture.six). * c_imagelib.c: Continuous DCS sequences (ESC P ... ESC \) for sixel graphics are processed. 2012-09-08 Araki Ken * xlib/x_imagelib.c: gdk_pixbuf of ~/.mlterm/picture.six is not cached. 2012-09-06 Araki Ken * android/Android.mk -> android/jni/Android.mk android/kik_config.h -> android/jni/kiklib/src/kik_config.h * android/build.sh, android/build.xml, android/AndroidManifest.xml, android/res/values/strings.xml, android/src/mlterm/android/MLTerm.java: Added. 2012-09-05 Araki Ken * ml_vt100_parser.c: Minor fixes. * c_imagelib.c: malloc() is used for picture file data instead of alloca(). 2012-09-04 Araki Ken * MLTerm.java: Application-cursor-keys sequences for Home and End keys are ^[OH and ^[OF instead of ^[[H and ^[[F. * x_screen.c, x_termcap.c, etc/termcap: - code cleanup - ML_F1(k1), ML_F2(k2), ML_F3(k3), ML_F4(k4) are added. - Application-cursor-keys sequences for XK_Home and XK_End are ^[OH and ^[OF instead of ^[[H and ^[[F. - Following key sequences are changed. XK_BackSpace: \x7f -> \x08 XK_Home: \x1bOH -> \x1b[H XK_End: \x1bOF -> \x1b[F XK_F1: \x1b[11~ -> \x1bOP XK_F2: \x1b[12~ -> \x1bOQ XK_F3: \x1b[13~ -> \x1bOR XK_F4: \x1b[14~ -> \x1bOS * x_screen.c: PAGE_DOWN shortcut is checked even if it is not backscroll mode. * ml_edit.c, ml_edit_util.c, ml_line.c: ml_line_t::is_continued_to_next flag is reset ml_edit_clear_line_to_right(), ml_edit_clear_below(), ml_edit_clear_above(), ml_edit_fill_all() and ml_edit_clear_lines() by using the new function ml_line_clear_with() instead of ml_line_fill(). 2012-08-23 Araki Ken * ml_vt100_parser.c: 0x90 ... 0x9c are available for sixel graphics sequence. 2012-08-15 Araki Ken * mlterm.1: Spelling mistake is fixed. (SF Patch #3557298, Thanks to Ahmed El-Mahmoudy) * ml_vt100_parser.c: The bug which didn't reset modifyOtherKeys by "CSI>m" is fixed. 2012-08-14 Araki Ken * kik_utmp_utmper.c: Fix conflicting types of kik_utmp_new. (Thanks to KATO Masashi san) 2012-08-12 Araki Ken * mkf_tblfunc_loader.[ch]: If NO_DYNAMIC_LOAD_TABLE is defined, the functions in these files are removed. * android/prepare.sh, android/Android.mk: Minor fixes. 2012-08-11 Araki Ken * android/: Added. * kik_pty_streams.c: Fixes for android. 2012-08-10 Araki Ken * 3.1.3 released. (tag "rel-3_1_3") * configure.in, mlterm.spec, main/version.h.in, doc/en/ReleaseNote: updated for 3.1.3. 2012-07-13 Araki Ken * kik_pty_streams.c, kik_bsd_streams.c: - Even if fcntl() fails, processing is continued with warning message. (fcntl(fd,F_SETFL,O_NDELAY) fails in Darwin Kernel Version 11.4.0: Mon Apr 9 19:32:15 PDT 2012 / i686-apple-darwin11-llvm-gcc-4.2) - fcntl(fd,F_SETFL,O_NDELAY) -> fcntl(fd,F_SETFL,fcntl(fd,F_GETFL,0)|O_NDELAY). (Thanks to saitoha san) 2012-07-12 Araki Ken * MLTermPty.java: mkdir() -> mkdirs() in order to make sure to make parent directories of %HOMEPTH%\mlterm\java. 2012-07-07 Araki Ken * etc/main, etc/main.ja, doc/ja/README.ja, man/mlterm.1: Updated. * ml_screen.[ch], ml_edit.[ch], ml_term.[ch], ml_term_manager.[ch], ml_vt100_parser.[ch], x_font_config.c, x_main_config.[ch], x_screen.c, x_screen_manager.c, gtk/vte.c, java/MLTermPty.c: Local echo mode which reflects keyboard inputs immediately is supported. --loecho / "use_local_echo" option which enables or disables local echo mode is added. 2012-06-26 Araki Ken * x_screen.c: If x_shortcut_str() returns text in key_pressed(), event->state is set 0 to ignore mod_meta_mode. * x_shortcut.c: ModMask check in x_shortcut_str() is fixed. * x_screen.[ch], ml_term.h, ml_vt100_parser.[ch]: modify_other_keys flag is moved from x_screen_t to ml_vt100_parser_t. 2012-06-24 Araki Ken * ml_vt100_parser.c: CSI ? 8840 n is supported. 2012-06-24 Araki Ken * x.h, x_win32.h: XK_FMAX is added. XK_F25 ... XK_F35 macros are removed in win32. * x_screen.c: If x_window_get_modifier_mapping() returns NULL, is_alt is set by (state & ModMask). * ml_vt100_parser.[ch], x_screen.[ch]: CSI[>4;2m and CSI[>4;0m (enable and disable modifyOtherKeys) are partially supported. (Note that sequence from terminal is CSI [;u, not CSI [27;;~.) 2012-06-24 Araki Ken * ml_vt100_parser.c: Duplicated code is removed. * x_screen.c, x_window.c: Minor fixes related to GraphicsExpose. 2012-06-21 Araki Ken * ml_vt100_parser.c: CSI Ps SP q (0 <= Ps <= 2) is supported. 2012-06-21 Araki Ken * x_window.[ch]: NoExpose and GraphicsExpose events caused by XCopyArea are processed with wait_copy_area_response flag. * x_gc.c, vte.c: Default value of graphics_exposures of GCValue is changed from False to True. 2012-06-13 Araki Ken * xlib/x_window.c: FocusIn/FocusOut events not only to top windows but also to child ones are processed. (SF Bug #3528838. Thanks to Thomas Wolff) * ml_vt100_parser.c: CSI ? 8840 h and CSI ? 8840 l are supported. * x_font_config.c: Minor fixes. 2012-06-11 Araki Ken * README.ja, README.cairo: Fixed. * x_font_ft.c: If ":percent" is specified in ~/.mlterm/*font, x_off is set to center a character in the cell. * x_draw_str.c: If current and next characters are bold or not is checked by the value of ml_char_font() instead of xfont->id. 2012-06-09 Araki Ken * doc/en/PROTOCOL, doc/en/README.cairo: Updated. * x_screen.c: cursor blinking is stopped in unfocused. * xlib/x_font.c, x_font_ft.c, win32/x_font.c, xlib/x_window.c, x_window_cairo.c, x_window_xft.c: - If letter_space is larger than 0, x_off += letter_space / 2 to center a character in the cell. - If x_off is larger than 0, x_window_draw_string*() draws string from x + x_off. * x_screen.c, x_font_manager.[ch], x_main_config.[ch], gtk/vte.c: --bdfont / "use_bold_font" option is added. * MLTermPty.c: "ssh_x11_forwarding" option is supprted. * ml_pty_ssh.c: Minor fixes. * version.h.in: 3.1.2 post => 3.1.3 pre 2012-06-06 Araki Ken * etc/main, etc/main.ja, doc/ja/README.ja, main/mlterm.1: Updated. * x_event_source.c: x11 forwarding events are polled and dispatched. * x_main_config.c: "ssh_x11_forwarding" option is added. * ml_pty.h, ml_pty_ssh.c: X11 forwarding functions (ml_pty_ssh_set_use_x11_forwarding, ml_pty_ssh_get_x11_fds and ml_pty_ssh_send_recv_x11) are added. 2012-06-02 Araki Ken * x_event_source.[ch]: Macros -> Dummy functions. * x_screen_manager.c: If open_pty_intern() fails in open_screen_intern(), new screen is not added to static variable screens. * ml_vt100_parser.c: MAX_PS_DIGIT macro is defined. * ml_screen.c: Max number of lines to be inserted or deleted is number of screen rows. 2012-06-01 Araki Ken * win32/x_font.c: Minor fixes. * vte.c, ml_vt100_parser.c, x_imagelib.c: Usage of DIGIT_STR_LEN is fixed. 2012-05-31 Araki Ken * kik_unistd.h: Minor fixes. 2012-05-29 Araki Ken * contrib/tool/mlcc/Makefile.in: SF Patch #3530235 is merged. * doc/ja/README.ja, man/mlterm.1: Updated. * mlclient/main.c: "--keepalive" is added to na_options. * ml_pty.h, ml_pty_ssh.c, main_loop.c, MLTermPty.c: "ssh_keepalive_interval" option is added. * kik_mem.c: Minor fixes. * ml_pty.c: Declaration of ptsname() is enabled by defining _GNU_SOURCE. 2012-05-27 Araki Ken * x_color_manager.c: Minor fixes. 2012-05-26 Araki Ken * x_color_manager.[ch], x_screen.c: - sys_colors are loaded from the beginning. (sys_colors.is_loaded flag is removed) - If illegal color name is specified for sys_color, current sys_color is not changed. (Not falls back to white or black.) 2012-05-25 Araki Ken * indian.h, lex.split.c, syllable.lex, ml_vt100_parser.c, mc_im.c: SF Patch #3529392 and #3529386 are merged. (Thanks to Ahmed El-Mahmoudy) 2012-05-24 Araki Ken * xlib/x_window.c: If background color is changed, margin area is cleared in x_window_set_bg_color(). * ml_vt100_parser.c: OSC 5;0 and OSC 5;1 are supported. * ml_vt100_parser.c, x_color_config.c, x_color_manager.c: - "?" which query color spec in OSC 4, 10, 11 and 12 is ignored. - If unknown color name is specified for fg color, it falls back to white. (Related to SF Bug #3528836, Thanks to Thomas Wolff) * kik_mem.h, x_imagelib.c: If glib/galloca.h is included before kik_mem.h, alloca check in kik_mem.h is disabled. * kiklib/configure.in, kik_config.h.in, kik_unistd.[ch]: If setenv doesn't exist, __kik_setenv is used instead. (Related to SF Bug #3509744, Thanks to Thomas Wolff) * version.h.in: 3.1.2 => 3.1.2 post 2012-05-19 Araki Ken * 3.1.2 released. (tag "rel-3_1_2") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.1.2. * README, doc/en/README.win32, doc/ja/README.win32, gtk/INSTALL: Updated. * x_screen.c, x_screen_manager.c, doc/en/PROTOCOL: "close_pty" command is added to configuration protocol. * x_screen.c: ml_term_write( term) is replaced by ml_term_write( screen->term) in get_config(). * mc_im.c: Current directory is searched for im-xxx modules if IM_DIR is not found. * mlterm-menu.c: Ptys attached to other screens are not displayed in the menu list. * ml_vt100_parser.c: - buf length < vt100_parser->r_buf.len is checked. - Pp of DA2 is changed from 0 (xterm default) to 1(VT220). * x_screen_manager.c: Minor fixes. * x_event_source.h: Minor fixes. * ml_screen.c: Minor fixes. 2012-05-17 Araki Ken * doc/ja/README.win32, doc/en/README.win32: Updated. * x_main_config.c, win32/x_window.c, win32/x_win32.h: -g +X+Y is possible to be specified. * configure.in, x_im_candidate_screen, x_im_status_screen.c, win32/x_window.c, x_screen.c, inputmethod/kbd/im_kbd.c: inputmethod/kbd is possible to be enabled in win32. * ml_vt100_parser.c: ESC Z is processed. * inputmethod/*/Makefile.in: @TYPE_CFLAGS@ is removed and @GUI_CFLAGS@ is added. 2012-05-14 Araki Ken * x_font_xft.c, x_font_cairo.c: undef unnecessary USE_TYPE_XXX macro. * x_font_ft.c: Minor fixes. 2012-05-14 Araki Ken * README: Updated * libind/*.c: u_int -> unsigned int * MLTermPty.java: A bug which disabled loading libMLTermPty.so in mlterm.jar is fixed. * ml_vt100_parser.c: FF(0x0c) is processed. * configure.in, main/Makefile.in, libctl/Makefile.in, mlclient/Makefile.in, xwindow/Makefile.in, libtype/Makefile.in: Minor fixes. * libctl/ml_shape_bidi.c: Minor fixes. * x_draw_str.c: Minor fixes. 2012-05-12 Araki Ken * README, mlterm.spec: Minor fixes. * README.ja, doc/en/PROTOCOL, man/mlterm.1: Updated. * x_draw_str.[ch], x_screen.[ch], x_screen_manager.[ch], x_main_config.[ch], vte.c, x_im_{candidate|status}_screen.c: "hide_underline" option is added. * ml_vt100_parser.c: It is possible to process sequences whose length is more than PTY_RD_BUFFER_SIZE. * x_draw_str.c: Minor fixes. * version.h.in: 3.1.1 post => 3.1.2 pre 2012-05-10 Araki Ken * Makefile.in, kik_pty_helper.c, ml_config_menu.c, x_imagelib.c: SF Patch #3524577 and #3524578 are merged. (Thanks to Ahmed El-Mahmoudy) * etc/key: Updated. 2012-05-07 Araki Ken * ml_pty_ssh.c: Command string to be executed over ssh connection is braced by "" if it contains a space. * x_screen_manager.c: A problem which failed to open a new screen because command string to be executed over ssh connection wasn't initialized is fixed. 2012-05-06 Araki Ken * ml_pty.[ch], ml_term.[ch], ml_term_manager.c, ml_vt100_parser.c, ml_pty_intern.h, x_screen.c, x_screen_manager.c: Experimental implementation of multiple windows per one pty (MULTI_WINDOWS_PER_PTY) is removed. 2012-05-06 Araki Ken * im_ibus.c, x_im.c: Hack to avoid calling ibus_init() more than once is added. (If ibus daemon was not found last time and ibus_init() is called again, segfault happens.) 2012-05-06 Araki Ken * etc/font.win32.indic: Added. * README.indic, aafont.indic: Updated. * ml_iscii.c: libiscii_xxx.so modules are possible to be loaded from current working directory. * win32/x_font.c: is_var_col_width of ISCII font is always true. 2012-05-05 Araki Ken * ml_vt100_parser.[ch], x_screen.c: FocusIn/FocusOut event tracking (CSI ? 1004 h and CSI ? 1004 l) is supported. 2012-05-04 Araki Ken * MLTerm.java: The way to get mouse position is improved. * MLTermPty.java: isTrackingMouse() method is added to check mouse traking mode is on or off. * ml_vt100_parser.[ch], x_screen.c, java/MLTermPty.c: Extended mouse report(SGR/URXVT) is supported. * x_draw_str.c: Even if fg/bg color is reversed, bd_color and ul_color options work correctly. (Thanks to Andi Cristian Serbanescu) * mkf/script/config.guess, kiklib/script/config.guess, script/config.guess: updated (timestamp='2012-02-10') * mkf/script/config.sub, kiklib/script/config.sub, script/config.sub: updated (timestamp='2012-04-18') * win32/x_window.c: Fixed typo. 2012-04-30 Araki Ken * doc/en/PROTOCOL: Updated. * configure.in: --enable-sixel option is added. * ml_vt100_parser.c: DCS .. q .. ST sequence is supported. * Sixel format picture is partially supported. * "add_picture" and "remove_picture" are added to configuration protocol. * version.h.in: 3.1.1 => 3.1.1 post 2012-04-29 Araki Ken * 3.1.1 released. (tag "rel-3_1_1") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.1.1. * configure.in: If xlib is not found, configure script exits. * kik_pty_streams.c: is included instead of to fix segfault in 64bit Linux. * mlterm.1, mlclient.1: Updated. * x_main_config.c, main_loop.c: --sep, --button3, --clip, --restart and --logmsg options are moved from main_loop.c to x_main_config.c to enable to specify them for mlclient. 2012-04-22 Araki Ken * ml_color.[ch], x_color_config.c: It is possible to change 0-15 colors by OSC 4 sequence. 2012-04-21 Araki Ken * 3.1.0 released. (tag "rel-3_1_0") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.1.0. * x_main_config.c, MLTermPty.c, ml_pty.h, ml_pty_ssh.c, etc/main, etc/main.ja, man/mlterm.1, README.ja: "cipher_list" option is added. * kik_debug.c, kik_utmp_sysv.c: Minor fixes. 2012-04-16 Araki Ken * MLTermPty.c: Minor fixes. 2012-04-14 Araki Ken * x_color_manager.[ch], x_draw_str.c, x_main_config.[ch], x_screen.c, x_screen_manager.c: "bd_color" (equivalent to colorBD of xterm) and "ul_color" (equivalent to colorUL of xterm) options are added. * kik_str.[ch]: kik_compare_str() which accepts NULL as arguments is added. * ml_term.[ch], ml_pty.[ch]: ml_term_flush() and ml_flush_pty() which rarely work is removed. * vte.c, x_font_ft.c, xlib/x_font.c, win32/x_font.c, x_draw_str.[ch], x_im_candidate_screen.c, x_im_status_screen.c, x_screen.[ch], x_decsp_font.[ch]: height_to_baseline -> ascent 2012-04-13 Araki Ken * x_screen.c, x_xic.c: Even if X*LookupString() returnes XBufferOverflow, all input text is received. * kik_dialog.[ch]: kik_dialog_style_t is added. * win32/x_display.c, win32/x_window.c: - Callback function of kik_dialog is set. - MessageBox is replaced by kik_dialog. 2012-04-12 Araki Ken * MLTermPty.c, MLTermPty.java: '\r' characters at end of lines are removed. 2012-04-11 Araki Ken * MLTermPty.c: If ssh server is unknown, message box is shown. * kiklib/src/Makefile.in, java/Makefile.in: Fixed. * ConfirmDialog.java: Added. * kik_dialog.[ch]: Added. * ml_pty_ssh.c: ~/.ssh/known_hosts or ~/.mlterm/known_hosts are checked. 2012-04-08 Araki Ken * ml_line_bidi.c: BiDi mirroring is supported. (Thanks to Khaled Hosny) * ml_bidi.c: ml_bidi_get_mirror_char() is added. 2012-04-08 Araki Ken * ml_vt100_parser.c: Characters which failed to be converted from or to ucs in -u and -n option are displayed as they are, instead of being ignored. * MLTermListener.java: cellSizeChanged() -> sizeChanged() * MLTerm.java: - Max number of pty windows is changed from 10 to 32. - Size of window decorations is cached. - Ctrl+F2 which opens pty in current window is supported. - Ctrl+F3 which switches to a next free pty is supported. * MLTermPty.java, MLTermPty.c: - listener object is managed not in MLTermPty.java but in MLTermPty.c. - getRows() and getCols() methods are implemented. - {set|get}AuxData() methods which are used to store StyledTextContent for the pty are added. * ml_char.c: If IS_REVERSED is true and IS_BOLD is true, ml_char_fg_color() masks ML_BOLD_COLOR_MASK and ml_char_bg_color() doesn't mask ML_BOLD_COLOR_MASK. * x_screen.c: - ml_char_reverse_color() is used to draw cursor. - unhighlight_cursor() in bs_* functions is removed. * x_screen.c, x_window.c, x_main_config.[ch]: - x_window_t::idling event is added, and cursor blinking is supported by using it. - "blink_cursor" option is added. - "inner_border" option is added. 2012-04-01 Araki Ken * configure.in: --enable-vt52 is added. * ml_vt100_parser.[ch]: VT52 emulation is added. * README: Updated * version.h.in: 3.0.11 => 3.1.0 pre 2012-03-31 Araki Ken * mlterm/ml_char.c, x_draw_str.c, x_screen.c: ml_char_cols() returns 0 for some control characters of Unicode, and characters which ml_char_cols() returns 0 for aren't drawn. (Thanks to phcoder) * doc/en/ReleaseNote: Updated. 2012-03-26 Araki Ken * ml_pty_pipewin32.c: If cmd_argv is { "...\plink.exe" , NULL }, its options which are input from dialogbox are appended. * MLTermPty.java: Native shared libraries are saved at ~/.mlterm/java or %HOMEPATH%/java instead of /tmp. * MLTermPty.java, MLTermPty.c: - setAltLibDir() -> setLibDir() - PATH and LD_LIBRARY_PATH are set instead of mkf_set_alt_lib_dir(). * mkf/lib/Makefile.in, mkf_tblfunc_loader.[ch], mkf/lib/dexport.map: MAJOR.MINOR version 16.1 -> 16.0. mkf_set_alt_lib_dir() is removed. * kik_debug.c: fseek( fp , 0 , SEEK_SET) is called after checking if EOF character is '\n' or not by fseek( fp , -1 , SEEK_END), because it fails to write messages in win32 without this. 2012-03-25 Araki Ken * xlib/x_display.c: Add a hack not to inclulde in order to avoid compilation failure in Cygwin/X. (SF Bug #3509743) (Thanks to Thomas Wolff) * x_screen_manager.c, win32/x_connect_dialog.c, winrs.rs, ConnectDialog.java, MLTerm.java, MLTermApplet.java: "Exec cmd" is possible to be input in connecting to a ssh server. * MLTerm.java: "geometry" option is supported. * ml_term_manager.c: unsetenv -> kik_unsetenv (SF Bug #3509744) (Thanks to Thomas Wolff) * kik_unistd.[ch]: - kik_setenv is defined as setenv or SetEnvironmentVariable(). - kik_unsetenv is defined as unsetenv, setenv(...,"") or SetEnvironmentVariable(...,NULL). __kik_unsetenv() is removed. 2012-03-24 Araki Ken * MLTerm.java: The place to dispose font and color objects is moved from PtyWather thread to a dispose event listener of a display. * MLTermPty.c: If libssh2 is used in win32, prevent a thread to watch pty in ml_pty_ssh.c from spawning. 2012-03-24 Araki Ken * MLTerm.java: After display is disposed, font and color objects are disposed, too. * MLTermApplet.java: lineHeightChanged -> cellSizeChanged * xlib/x_imagelib.c, tool/mlimgloader/main.c: is included. 2012-03-23 Araki Ken * kik_types.h, kik_def.h, xlib/x_imagelib.c: SIZE_MAX is defined in kik_def.h, not in kik_types.h to fix a compilation error in x_imagelib.c. (SF Bug #3509744) (Thanks to Thomas Wolff) * ml_vt100_parser.c: "\x1b[0;96;0c" is returned as the value of Secondary DA in order for vim to decide ttymouse=xterm2 automatically. * MLTerm.java: Drag&Drop is supported. * MLTerm.java, MLTermPtyListener.java, MLTermPty.c: Audible bell is supported. * MLTerm.java, MLTermPty.java, MLTermPty.c: "fg_color", "bg_color" options are supported. (MLTermPty.getColorRGB() method is added.) * MLTerm.java, MLTermPty.c, MLTermPty.java: Mouse tracking sequences ("CSI ? 1000 h/l", "CSI ? 1002 h/l" and "CSI ? 1003 h/l") are supported. * mltermlet.html: Meta tags to disable cache is added. 2012-03-21 Araki Ken * MLTerm.java: getProperty() method is added to apply configuration in ~/.mlterm/main. * MLTerm.java, MLTermPtyListener.java, MLTermPty.c: - Lines are scrolled out only if not line_scrolled_out but window_scroll_upward_region of ml_screen_event_listenert is called. (Fixed failure of 7th test of vttest test type 2.) - resize() of ml_xterm_event_listener_t is implemented and MLTerm handles resize event of MLTermPtyListener to support "CSI ? 3 h", "CSI ? 3 l", "CSI 4 t" and "CSI 8 t". * MLTermPty.c: If next line is modified, set mog_beg = 0 in Java_mlterm_MLTermPty_nativeGetRedrawString() to enable combining modified characters in current line and next line and to decrease the number of calling replaceTextRange(). * mkf/lib/Makefile.in: MAJOR.MINOR version 16.0 -> 16.1 2012-03-19 Araki Ken * MLTerm.java: replaceTextBuffering() is added to decrease number of calling replaceTextRange(). 2012-03-18 Araki Ken * MLTerm.java: - Application cursor key is supported. - setTextLimit( 100000) * MLTermPty.java: isAppCursorKeys() is added. * MLTermPty.c: - nativeIsAppCursorKeys() is added. - ml_screen_event_listener_t::window_scroll_{up|down}ward_region are partially implemented. - Each native_obj_t has its MLTermPtyListener object, which was set to static variable. 2012-03-17 Araki Ken * MLTerm.java: The way of calling wait/notifyAll is fixed. * java/Makefile.in: Minor fixes. 2012-03-17 Araki Ken * MLTermPty.java: waitForReading() is added. * MLTermPty.c: Java_mlterm_MLTermPty_waitForReading() is added. * MLTerm.java: - startPtyWatcher() to check MLTermPty.waitForReading() added. - setCaret(null) 2012-03-16 Araki Ken * ConnectDialog.java: SWT.PASSWORD is removed to create "Encoding" text field. * MLTerm.java: - numOfScrolledOutLines member is added. - Redrawing performance is improved. - Shift-tab key is processed. * MLTermPtyListener.java: redraw() is renamed to lineScrolledOut(). * MLTermPty.java: numOfScrolledOutLines member is removed. * MLTermApplet.java: Minor fixes. * mlterm.html -> mltermlet.html 2012-03-14 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * x_shortcut.c: Not only "Mod" but "Mod1"-"Mod5" keys are available for ~/.mlterm/key. (SF Patch #3496423 is merged, Thanks to Kevin Schoedel) * mkf_tblfunc_loader.c: mkf_set_alt_lib_dir() is added. * java/INSTALL: Updated. * java/Makefile.in: Minor fixes. * java/manifest.mf: Renamed to java/manifest.mf.in. java/manifest-win32.mf: Removed. * java/MLTermPty.c: Added. - ml_config_listener_t::{set|get}_config and ::exec_cmd are implemented. - Options in ~/.mlterm/main are applied. * java/mlterm/ConnectDialog.java, java/mlterm/MLTermListener.java, java/mlterm/MLTermPtyListener.java, java/mlterm/MLTermApplet.java, java/mlterm.html: Added. * java/mlterm/MLTerm.java: - "-km", "-dialog", "-g" and "-e" options are added. - "-pass" option is removed. - Screen scroll is supported. - Screen resize is supported. * configure.in, java/Makefile.in: @CYGPATHW@ is added. 2012-03-09 Seiichi SATO * README, configure, configure.in, doc/ja/README.ja, etc/key, etc/main, etc/main.ja, man/mlterm.1, xwindow/x_main_config.c, inputmethod/iiimf/LICENCE, inputmethod/iiimf/Makefile.in, inputmethod/iiimf/im_iiimf.c, inputmethod/iiimf/im_iiimf.h, inputmethod/iiimf/im_iiimf_aux.c, inputmethod/iiimf/keymap.c, inputmethod/iiimf/keymap.h: removed IIIMF plugin 2012-03-03 Araki Ken * xwindow/win32/x_window.c: WM_SIZE message is ignored if window is iconified. * xwindow/win32/x_win32.c: Added. XStringToKeysym() is implemented for ~/.mlterm/key in win32. 2012-03-01 Araki Ken * ml_vt100_parser.c: SM, RM, DECSET and DECRST accept multiple numeric parameters. (Thanks to Iwamoto Kouichi san) * ml_color.h: Range of IS_VALID_COLOR() is changed from "<= 0x101" to "< 0x100" in order for ml_get_color_rgb(ML_{FG|BG}_COLOR) to return 0. * man/mlterm.1, doc/ja/README.ja, doc/ja/README.win32, doc/en/README.win32: Updated. * x_main_config.c: - The default value of "col_size_of_width_a" option is changed from 1 to 2 if locale is "ja_XX.XXX". - If "auto" is specified as the value of "encoding" option not only if nothing is specified, set x_main_config_t::is_auto_encoding = 1. * java/: Added. * ml_edit.[ch], ml_pty_{pipewin32|ssh}.c: Minor fixes. * mkf_tbl_func_loader.h: Minor fixes. 2012-02-14 Araki Ken * x_draw_str.c: Starting position to draw combining character is fixed. (SF Bug #3487163) (Thanks to raghavkrishna) 2012-02-13 Araki Ken * x_sb_screen.c: button_press() event is implemented for wheel mouse in win32. (Wheel mouse in win32 hasn't worked since 2012-08-26 commit.) * mkf_tblfunc_loader.h: If mkf module is not found, mkf_map_func() and mkf_map_func2() return 0 to avoid segfault. * xwindow/Makefile.in, configure.in, win32/x_dnd.c, xlib/x_dnd.c: @DND_OBJ@ is obsolete. If DISABLE_XDND is defined, comment out all source code in x_dnd.c. 2012-02-12 Araki Ken * doc/ja/README.win32, doc/en/README.win32, README: Updated. * win32/x_font.c: - use_variable_column_width and letter_space options are supported. - x_convert_ucs4_to_utf16() is moved from x_draw_str.c * win32/x_window.c: x_window_scroll_{left|right}ward_region() are implemented to scroll screen correctly in vertical mode. * ml_vt100_parser.c: trigger_xterm_event argument of start_vt100_cmd() after xterm_listener::bel() is changed from 0 to 1 in order to erase cursor which xterm_listener::bel() drew if bel_mode is visual. 2012-02-11 Araki Ken * x_display.[ch], xlib/x_window.c, win32/x_window.c: x_display_t::width and x_display_t::height members are added and used instead of calling Display{Width|Height}() or GetSystemMetrics(SM_C{X|Y}SCREEN) directly. * x_screen.c, x_window.h, {xlib|win32}/x_window.c: A problem that margin area isn't cleared after visual bell is fixed. * configure.in, mlterm-menu/Makefile.in, main/Makefile.in, xwindow/Makefile.in, scrollbar/sample/Makefile.in, tool/mlconfig/Makefile.in: @WIN32TAG@ -> _@GUI@ * xwindow/: x_color.c -> xlib/x_color.c x_color_win32.c -> win32/x_color.c x_connect_dialog.c -> xlib/x_connect_dialog.c, win32/x_connect_dialog.c x_display.c -> xlib/x_display.c x_display_win32.c -> win32/x_display.c x_dnd.c -> xlib/x_dnd.c x_dnd_win32.c -> win32/x_dnd.c x_font.c -> xlib/x_font.c x_font_win32.c -> win32/x_font.c x_gc.c -> xlib/x_gc.c, win32/x_gc.c x_imagelib.c -> xlib/x_imagelib.c x_imagelib_win32.c -> win32/x_imagelib.c x_simple_sb_view.c -> xlib/x_simple_sb_view.c x_simple_sb_view_win32.c -> win32/x_simple_sb_view.c x_win32.h -> win32/x_win32.h x_window.c -> xlib/x_window.c x_window_win32.c -> win32/x_window.c x_xic.c -> xlib/x_xic.c x_xic_win32.c -> win32/x_xic.c winrs.rs -> win32/winrs.rs x_gdiobj_pool.[ch] -> win32/x_gdiobj_pool.[ch] x_decsp_font.[ch] -> xlib/x_decsp_font.[ch] x_xim.[ch] -> xlib/x_xim.[ch] 2012-02-04 Araki Ken * x_window.h, x_window.c, x_window_win32.c: - x_event_dispatch_t -> x_resize_flag_t - Only if LIMIT_RESIZE flag is passed to x_window_resize(), x_window_resize() never resizes over DisplayWidth or DisplayHeight. * ml_vt100_parser.[ch], ml_term.h, x_screen.[ch]: - Extended mouse report(UTF8) is supported. - ml_{vt100_parser|term}_is_extended_mouse_report_mode() are added. * configure.in, ml_pty_unix.c, ml_pty.c, kik_utmp*: Utmp support is fixed. (SF Bug #3481552) (Thanks to Kobayashi Hiroaki san) * daemon.[ch], xwindow/main.c, xwindow/version.h.in, xwindow/dexport.map: Moved to main/ directory. * x_term_manager.[ch] => x_screen_manager.[ch], x_event_loop.[ch], daemon.[ch] * x_term_manager.c, doc/ja/README.ja, man/mlterm.1, etc/main, etc/main.ja: "startup_ptys" option is removed. 2012-01-15 Araki Ken * 3.0.11 released. (tag "rel-3_0_11") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.11. 2012-01-08 Araki Ken * version.h.in: 3.0.10 => 3.0.11 pre * x_window_win32.c: WM_SYSKEYDOWN event is processed to receive Alt+key events. * x_xic_win32.c: Combination of Control + space ^ _ / 2 3 4 5 6 7 8 is supported. 2012-01-03 Araki Ken * mlcc/main.c: - Help message is fixed. ("exec" was omited in "mlcc exec [command]") - 'mlcc exec select_pty /dev/xxx' is available instead of 'mlcc exec "select_pty /dev/xxx"'. * x_window.c: Processing Expose events is optimized. * x_screen.c: "paste", "open_pty", "select_pty", "open_screen", "snapshot", "search_next" and "search_prev" of configuration protocol doesn't keep backward compatibility with mlterm 3.0.10 or before which accepts '=' like "paste=". * ml_pty.[ch], ml_pty_*.c, ml_term.[ch], ml_term_manager.[ch], ml_vt100_parser.c, x_screen.[ch], x_term_manager.[ch]: Experimental implementation of multiple windows per one pty is added. (Open window by OSC 115 and close it by OSC 116.) (This feature is enabled by MULTI_WINDOWS_PER_PTY macro). 2012-01-01 Araki Ken * malloc() to create objects is mostly replaced by calloc(). 2011-12-31 Araki Ken * configure, configure.in: Fixed SF Bug #3464878. (Thanks to Daniel Lublin) 2011-12-30 Araki Ken * vte.c: If ConfigureNotify events are queued or not is checked in toplevel_configure() to improve performance of pseudo transparency. 2011-12-29 Araki Ken * x_window.c, x_window_win32.c: - x_window_clear_margin_area() is called not after but before win->window_exposed(). - x_window_clear() doesn't clear margin area in order to suppress flickering of im_{candidate|status}_screen. * x_draw_str.c: - Characters outside the right end of screen aren't drawn. * x_im_{status|candidate}_screen.c: x_window_draw_rect_frame() is called in window_exposed(), not in draw_screen(). 2011-12-28 Araki Ken * x_window.c, x_window_win32.c: window->exposed() is called after x_window_clear_margin_area() when window is exposed, because border of x_im_candidate_screen and x_im_status_screen is erased. * gtk/INSTALL: Updated. * gtk/vte.c: - vte_terminal_paste_primary() is implemented. - If vte_terminal_set_font_(string_)full is called before widget is realized, dummy terminal->pvt->screen->term is set to avoid segfault. - The value of WINDOW_MARGIN is changed from 2 to 1 because lxterminal-0.1.11 always regards the value of inner-border property as 1. 2011-12-24 Araki Ken * man/mlterm.1, README.ja, ReleaseNote, gtk/INSTALL: Updated. * gtk/vte.c: Hack for supporting VtePty is implemented. * kik_conf_io.c: If ~/.config/mlterm exists, it is used as a user config directory instead of ~/.mlterm. * kik_debug.c: File to output messages by --logmsg option is changed from ~/.mlterm/msg[pid].log to ~/.mlterm/msg.log. * x_window.c, x_window_win32.c: x_window_resize( larger than the size of display ) resizes window to the size of display. * ml_vt100_parser.[ch], x_screen.c: "CSI 8;rows;cols t" and "CSI 4;height;width t" sequence is supported partially. 2011-12-17 Araki Ken * 3.0.10 released. (tag "rel-3_0_10") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.10. * doc/ja/README.ja, doc/ja/README.dl, gtk/INSTALL: Updated. * x_imagelib.c, mlimgloader/main.c: - The cases of passing 24 as bitmap_pad argument to XCreateImage(). and passing 0 as pixmap to XFreePixmap() is fixed. - create_cardinals_from_image() supports 8 and 16 depth color. * tool/mlclient/Makefile.in, contrib/tool/mlcc/Makefile.in: @LDFLAGS@ is added. * xwindow/x_decsp_font.c: SF Patch #3459267 is merged. (Thanks to Kusanagi Kouichi san) 2011-11-18 Araki Ken * 3.0.9 released. (tag "rel-3_0_9") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.9. * mlterm.1, mlclient.1: Updated. * kik_types.h, x_imagelib.c: Definition of SIZE_MAX macro is moved from x_imagelib.c to kik_types.h. * kik_mem.h, kiklib/src/configure.in: If calloc doesn't check possibility of integer overflow, kik_mem_calloc is used instead. 2011-11-17 Araki Ken * x_window_win32.c, x_window.c: Typo is fixed in x_window_clear(). 2011-11-16 Araki Ken * mlterm.1, README.ja, PROTOCOL, ReleaseNote: Updated. * x_screen.c, ml_vt100_parser.[ch], x_shortcut.[ch], x_main_config.[ch]: - OSC 52 sequence is partially supported. (OSC 52 is not accepted by default and allowed by pressing Control+Insert.) - SWICH_OSC52 shortcut key and "allow_osc52" option is added. * vte.c: WINDOWID, TERM, DISPLAY and COLORFGBG environmental variables are added to 'envv' in ml_term_open_pty_wrap(). 2011-11-12 Araki Ken * x_imagelib_win32.c: file_path is converted from cygwin path to win32 path in x_imagelib_load_file_for_background(). * tool/mlconfig/main.c: "Brightness", "Contrast" and "Gamma" boxes are revived. * mc_*.c: g_free() is used instead of free() to free returned value of gtk_editable_get_chars(). * tool/mlconfig/mc_alpha.[ch]: Added. * x_picture.c: Normal alpha value is changed from 255 to 0. * README.ja, ReleaseNote, doc/en/README.win32, doc/ja/README.win32: Updated. 2011-11-09 Araki Ken * x_imagelib.c: Behavior of "alpha" option is reversed. (255=transparency, 0=opacity => 255=opacity, 0=transparency) * vte.c: kik_sig_child_init() which internally calls signal(3) and which confuses VteReaper is never called from vte.c. 2011-11-05 Araki Ken * x_imagelib.c: Minor fixes. * ml_term.c: Check if term->pty is NULL or not in ml_term_zombie(). * im_ibus.c: - ibus_proxy_destroy() is used instead of ibus_object_destroy in ibus-1.4. - g_main_context_iteration() is called in key_event(). 2011-11-02 Araki Ken * x_screen.c: The order of x_im_new and x_im_delete is reversed in x_screen_attach() to avoid to delete all resources inside im-module. * x_imagelib.c: x_imagelib_get_transparent() supports root pixmap whose depth is different from that of my window. 2011-10-31 Araki Ken * im_ibus.c: GDBusConnection ibus-1.4.0 depends on is partially supported. (Experimental) * vte.c: x_color_manager_change_alpha( ... , 0xff) if wall picture is set in update_wall_picture(). * x_imagelib.c: 0xff000000 is added to pixel value passed to XPutPixel() in 32 bit depth in pixbuf_to_ximage_truecolor(). 2011-10-29 Araki Ken * ml_screen.c: copy_or_check_region() and reverse_or_restore_region() are rewritten becase chars argument in copy_or_check_region() could be overflown occasionally. * x_gc.c: Initial foreground/background colors of GC always equal to those of x_gc_t in x_gc_new(). * vte.c: - Fixed mistakes of macros for vte-2.18 or before. - x_window_update() is called appropriately. - x_color_manager_change_alpha() and x_window_set_bg_color() are called in vte_terminal_realize(). * vtetypebuiltins.c: vte_pty_flags_get_type() and vte_pty_error_get_type() are added. * x_color.c: Alpha blended pixel is set in 32 bit depth in x_load_rgb_xcolor(). * x_sample(2)_sb_view.c, x_sample_sb_view.h: Black and white pixel are gotten by XAllocColor(), not BlackPixel and WhitePixel macros. * x_gc.c: Default values of fg and bg colors are 0xff000000 and 0xffffffff respectively instead of BlackPixel and WhitePixel. 2011-10-23 Araki Ken * x_picture.[ch]: x_root_pixmap_available() is removed. * x_window.c, x_imagelib.c: If depth of root pixmap isn't equal to one of current window, background (translucent) pixmap is not set. * README, README.ja, etc/main, etc/main.ja: Updated. * ml_pty_ssh.c: Previous commit is canceled and libssh2_channel_setenv_ex() is used instead of libssh2_channel_setenv(). 2011-10-22 Araki Ken * ml_pty_ssh.c: Not *env but kik_str_alloca_dup( *env) is used in overwriting its memory to separate it to key and value. 2011-10-22 Araki Ken * ml_pty.c: Minor fixes for win32 native. 2011-10-21 Araki Ken * x_term_manager.c: "version" varaible was freed unjustly in x_term_manager_final() and mlterm@cygwin was prevented from exiting normally. So "version" variable and so on is removed. (Thanks to Iwamoto Kouichi san) 2011-10-21 Araki Ken * vte.c: - x_window_set_transparent(terminal->pvt->screen) is called if GdkWindow of VteTerminal is re-configured. - If envv argument of vte_terminal_fork_command(_full) and vte_terminal_forkpty is NULL, TERM, WINDOWID, DISPLAY and COLORFGBG environmental variables are set for a child process. 2011-10-19 Araki Ken * vte.c: - Almost all parts of code in vte_terminal_unrealize() is moved to vte_terminal_finalize(). - Dummy x_screen_t is created before x_display_remove_root() in vte_terminal_unrealize() in case terminal will be realized again. * xwindow.[ch]: x_window_hide() is added. * gtk/Makefile.in, configure.in: Name of libvte using gtk+-3.0 is libvte2_90. 2011-10-17 Araki Ken * vte.c: pty_list and open_pty of x_system_event_listener_t are implemented for mlterm-menu. * ml_term_manager.c, mlterm/Makefile.in: If executing auto_restart_cmd failed, do execl(BINDIR "/mlterm") instead of execlp("mlterm"). 2011-10-16 Araki Ken * kiklib/kik_conf.[ch]: - kik_conf_new(): No argument. - kik_init_prog(), kik_get_prog_path(): Added. * kiklib/Makefile.in: 13.1 => 14.0 * ml_term_manager.c: - Even if SIGSEGV, SIGABRT, SIGBUS or SIGQUIT is received, all opened ptys survive and are inherited to restarted mlterm, unless "auto_restart" option is "false". * mc_combo.c, mc_font.c: gtk_widget_set_size_request(... , 0) -> gtk_widget_set_size_request(... , -1) * vte.c: - PROP_VADJUSTMENT property is supported. - "word_separators", "compose_dec_special_font" and "use_cp932_ucs_for_xft" options in ~/.mlterm/main are avaialble. 2011-10-12 Araki Ken * vte.c: "inner-border" property is set in GTK+-3.0. 2011-10-11 Araki Ken * configure.in: --with-gtk=(2.0|3.0) option is added. * tool/mlconfig/*.c, contrib/tool/mlterm-menu/mlterm-menu.c: Experimental support for GTK+ 3.0 is added. * gtk/vte.c: - Experimental support for GTK+ 3.0 is added. - If child_pid is NULL or not is checked in vte_terminal_fork_full_command_full() is checked. 2011-10-09 Araki Ken * x_window.c, x_window_win32.c: Edges of a window is cleared, margin area is cleared at the same time in x_window_clear(). * im_ibus.c: "forward-key-event" is processed. 2011-10-09 Araki Ken * x_window.h, x_window_win32.c: - x_window_t::wall_picture_is_set is removed in win32. - x_window_has_wall_picture() macro is added. 2011-10-08 Araki Ken * x_window_win32.c: - x_window_{un}set_wall_picture() functions reflect screen immediately. - Background image is redrawn in margin area. * x_window_cairo.c, x_window_xft.c, x_window.c, x_window_win32.c: Spaces at the end of lines are ignored by x_window_draw_string() and x_window_{cairo|xft}_draw_string8(). * x_window_cairo.c: cairo_move_to()/cairo_show_text() is replaced by cairo_scaled_font_text_to_glyphs()/cairo_show_glyphs(). * ml_vt100_parser.c: IGNORE_SPACE_FG_COLOR macro is removed. 2011-10-05 Araki Ken * x_font_ft.c: CAIRO_HINT_STYLE_NONE is applied in cairo_font_open(). * x_window.c: GraphicsExpose event is processed instead of VisibilityNotify event to improve performance. 2011-10-03 Araki Ken * im_ibus.c: A result of ibus_input_context_is_enabled() is cached in im_ibus_t. * x_window_cairo.c: 0x80 - 0xff characters are converted to UTF-8 in x_window_cairo_draw_string8(). 2011-10-02 Araki Ken * x_font_ft.c: CAIRO_HINT_METRICS_OFF is not applied in cairo_font_open(). * gtk/vte.c: If font size is changed, gtk_widget_queue_resize_no_redraw() is called in vte_terminal_set_font_from_string(). 2011-09-29 Araki Ken * man/mlterm.1, README.ja, README.indic, ReleaseNote: Updated. * x_screen.c: -V option is no longer automatically turned on to show indic characters. * x_font_fc.c, x_font.c: If minus value is returned as text width, xxx_calculate_char_width() returns 0 instead. * ml_line_iscii.c: A line who contains indic characters is forced to be redrawn to EOL in ml_line_iscii_render(). * ml_line.c: If end_char_index argument of ml_line_set_modified() is larger than line->num_of_filled_chars, ml_line_is_cleared_to_end() returns true. * x_font.c: ISCII font is always loaded as variable column width one. 2011-09-27 Araki Ken * version.h.in: 3.0.8 => 3.0.8 post * gtk/Makefile.in: @GTK_LIBS@ is added. * doc/ja/FAQ, doc/ja/README.fontproto, doc/term/README.term: Updated. 2011-09-24 Araki Ken * 3.0.8 released. (tag "rel-3_0_8") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.8. * man/mlterm.1, README.ja, etc/main, etc/main.ja: Updated. * x_main_config.c: Default value of "use_ind" option is changed from true to false. * mc_char_encoding.c: ISCII-XXX encodings are added. 2011-09-23 Araki Ken * ml_logical_visual.c: u_int -> int in container_delete() and container_logical(). * ml_edit.c: ml_edit_set_absolute_origin() sets edit->is_relative=0. (Thanks to Konosuke Watanabe san) * Makefile.in: Merged ID:3412453 patch. (Thanks to Ahmed El-Mahmoudy) * README.ja: Fixed. 2011-09-19 Araki Ken * 3.0.7 released. (tag "rel-3_0_7") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.7. * man/mlterm.1, doc/ja/README.ja: Updated. * inputmethod/ibus/im_ibus.c: ' ' character is available even if input context is enabled in key_event(). 2011-09-19 Araki Ken * libctl/ml_bidi.o, libctl/ml_iscii.o: Memory size passed to malloc() is fixed in ml_bidi_new() and ml_iscii_new(). * mlterm/Makefile.in: ml_bidi.o and ml_iscii.o are moved from OBJ_CORE to OBJ. * x_window.h: xft_draw and cairo_draw are never removed from x_window_t. * im_scim.cpp: KeyEvent::layout is initialized explicitly in im_scim_key_event(). 2011-09-16 Araki Ken * x_screen.c: - -V and -m options are forcibly enabled if -ind option is specified. - -m options are forcibly enabled if -bi option is specified. * doc/en/README.dl: Added. * libctl/ml_functbl_{bidi|iscii}.c, ml_ctl_loader.[ch]: API compatibility check by CTL_API_COMPAT_CHECK_MAGIC is added. * Type engine modules are loaded dynamically. - xwindow/libtype/: Added. - x_window.c, x_font.c: Separated to xwindow/libtype/. - x_main_config.c, x_screen.c, mlconfig/main.c: USE_FRIBIDI, USE_IND macros are removed. * gtk/Makefile.in: @VTE_LIBS@ are not linked. * x_window.c: XftDrawRect() is not used. * x_color.c: XftColor is not used. 2011-09-11 Araki Ken * x_screen.c: Set use_variable_column_width = true or use_combining = true forcibly in bidi or indic rendering. * libctl/ml_bidi.h: base_is_rtl and has_rtl members of ml_bidi_state_t are integrated to rtl_state, and some macros to operate rtl_state are added. * Bidi and indic rendering modules are loaded dynamically. - mlterm/libctl/: Added. - ml_line.[ch], ml_logical_visual.[ch], ml_shape.[ch], ml_bidi.[ch], ml_iscii.[ch]: Separated to mlterm/libctl/. - x_main_config.c, x_screen.c, mlconfig/main.c: USE_FRIBIDI, USE_IND macros are removed. * configure.in, xwindow/Makefile.in, mlterm/Makefile.in: --disable-dl-ctl option which disable dynamic loading of BiDi and Indic rendering modules. * mkf/lib/mkf_ucs4_xxx.c, mkf_tblfunc_loader.[ch]: The way of loading modules is improved. * x_font_config.c: In x_get_all_config_font_names(), when size == 1 and d_size == 0 and array[0]->key == DEFAULT_FONT, neither strcpy() nor sprintf() are done, thus p is left at the first character of the blank buffer font_name_list. In that case it's wrong to do simply *(p - 1) = '\0'. (Thanks to Noda, Kai san) * ml_bidi.c: Double free problem is fixed. (Thanks to NODA, Kai san) * ml_edit.[ch], ml_screen.[ch], x_screen.c, mlterm-menu/menu, etc/key: Minor fixes. 2011-09-04 Araki Ken * doc/en/README.win32, doc/ja/README.ja, mlterm.1: Updated. * x_main_config.c: - Default value of "logging_msg" option is changed from false to true. - mlterm/core configuration file which was used by mlterm 1.9.44 or before is not read. * ml_vt100_parser.c: If "CSI ? 6 l" or "CSI ? 6 h" sequence is received, cursor position is reset. On the other hand, if "CSI ! p" is received and origin is reset, cursor position is not reset. * ml_edit.c: ml_edit_set_{relative|absolute}_origin() don't reset cursor position. * doc/en/PROTOCOL.font, doc/en/PROTOCOL.color: Removed. * ml_vt100_parser.[ch], ml_config_proto.[ch], x_screen.[ch], mlcc/comm.c, mlconfig/mc_io.h, vte.c: - OSC 5384 - 5391 are integrated to OSC 5379 - 5383. - Format of "select_pty", "search_prev", "search_next" "snapshot" in OSC 5379 sequence is changed as follows. select_pty= => select_pty search_prev= => search_prev search_next= => search_next snapshot=: => snapshot - OSC 5382 is dropped. * ml_pty.c, ml_term.c: ml_{pty|term}_get_slave_name() always return non-NULL value. 2011-08-28 Araki Ken * version.h.in: 3.0.6 post => 3.0.7 pre * doc/en/README.tp: Updated. * ml_vt100_parser.c: OSC 10, OSC 11, OSC 12 are supported. 2011-08-27 Araki Ken * gtk/dexport.map: Added. * ml_pty_unix.c: Set delete, write, read and etc members of ml_pty_t in ml_pty_unix_new() if cmd_path argument is NULL and nothing is executed in child process. (vte_terminal_forkpty() didn't work correctly by this bug.) 2011-08-26 Araki Ken * x_screen.c: Fixed a problem which didn't clear selected region by pressing key if use_ind option was enabled. * doc/en/PROTOCOL, RADME.win32: Fixed. * code cleanup. 2011-08-23 Araki Ken * tool/mlconfig/mc_font.c: Fixed a problem which crashed mlconfig if type_engine is cairo and use_anti_alias is true. * ml_pty_ssh.c: - SCP is processed in non-blocking mode. - "Cancel" button is removed. "Return" and "Exit" buttons are added. * ml_pty.c: ml_pty_(un)use_loopback() and related fucntions are moved to ml_pty_ssh.c. * ml_pty_ssh.c: Source and destination file names are convered to system locale encoding and terminal encoding respectively. 2011-08-22 Araki Ken * ml_pty.c, ml_pty_intern.h : pty->stored->count member is added. * ml_pty_ssh.c: - Destination of scp is always directory. - Only one scp process works at the same time. * tool/mlconfig/main.c: Front-end window for SSH SCP is added. * doc/en/PROTOCOL: Fixed. 2011-08-20 Araki Ken * README, doc/en/PROTOCOL: Updated. 2011-08-20 Araki Ken * --logmsg/logging_msg option which writes messages to ~/.mlterm/msg[pid].log is added. - kik_debug.[ch]: kik_set_msg_log_file_name() is added. - screen.c, x_main_config.[ch]: Fixed. * kik_path.[ch]: - __kik_basename() supports '\' as a separator. - __kik_basename() is forcibly used in win32 even if system basename() is provided. * ml_pty.c: - File descriptors by _socketpair() are used for pty loopback in win32 in order to select(2) it. * ml_config_menu.[ch]: mlconfig is available in using libssh2. - ml_pty_ptr_t is passed to ml_config_menu_start() instead of slave fd. - pty loopback is enabled by ml_pty_(un)use_loopback() while mlconfig works. * ml_vt100_parser.c: DECTCEM is reset in DECSTR. 2011-08-16 Araki Ken * "scp " is added to configuration protocol. - ml_pty.[ch], ml_pty_intern.h: ml_pty_(un)use_loopback() are added. - ml_pty_ssh.c: scp is supported. - ml_vt100_parser.c: "scp" key of configuration protocol calls ml_pty_ssh_scp(). - doc/en/PROTOCOL: Updated. - configure.in: If pthread is available or not is checked. - tool/accessories/mlscp.sh: Added. 2011-08-14 Araki Ken * x_screen.c: If x or y of XButtonEvent is less than 0, it is treated as 0 in reporting mouse position. (Thanks to Iwamoto Kouichi san) * ml_char_encoding.c: non_iso2022_illegal_char() is added to enable copy DEC Special characters in non iso2022 encodings(e.g. UTF-8). 2011-08-13 Araki Ken * x_window_win32.c: Check if win->pointer_motion is NULL or not before calling win->pointer_motion function. (Thanks to Iwamoto Kouichi san) * x_font.c, x_font.c, x_font_config.c, x_font_win32.c: ISO10646_UCS2_1(_BIWIDTH) is removed. * doc/en/README.indic: E-mail from sumeet inani is added. (Thanks to sumeet inani) * ml_vt100_parser.c: DECOM and DECAWM are reset in DECSTR. 2011-08-11 Araki Ken * x_window_win32.c: WM_WHEELMOUSE event which is sent to a top level window is passed to a child window. (Thanks to Iwamoto Kouichi san) * x_screen.c, ml_line.[ch]: - Mouse position outside window is not reported. (Thanks to Iwamoto Kouichi san) - Mouse report position is not visual but logical one in rtl lines. (ml_bidi_convert_visual_char_index_to_logical() is added for this.) 2011-08-08 Araki Ken * ml_vt100_parser.[ch], x_screen.c: Application escape mode ("CSI ? 7727 h" "CSI ? 7727 l" sequences are supported. * mkf/libtbl/table/*.table: CONV_XXX_TO_XXX is declared as static. * ml_vt100_parser.c: Application keypad, application cursor, application escape, bracketed paste and mouse report modes are reset by DECSTR. 2011-08-07 Araki Ken * doc/en/README.tp: Updated. * x_window_win32.c: Position in WM_MOUSEWHEEL event is processed by ScreenToClient(). (Thanks to Iwamoto Kouichi san) * ml_vt100_parser.c, ml_term.[ch], x_screen.c: "CSI ? 1002 h" "CSI ? 1003 h" "CSI ? 1002 l" "CSI ? 1003 l" sequences are supported. * kiklib/configure.in: Not only if posix_openpt and /dev/ptmx exist but also if they work is checked. * Makefile.in: 'make uninstall' is supported. 2011-08-02 Araki Ken * x_window_win32.c: Width and height of window decorations like caption are calculated by difference between WindowRect and ClientRect. 2011-08-01 Araki Ken * ml_vt100_parser.c: The way of parsing intermediate or parameter characters is improved. 2011-07-31 Araki Ken * doc/en/README.win32, doc/ja/README.win32: Updated. * x_font_win32.c, x_window_win32.c: "Tera Special" font is used for DEC Special characters. 2011-07-30 Araki Ken * gtk/vte.c: Fixed typo. * ml_vt100_parser.c: CSI sequence inside OSC is interpreted. 2011-07-27 Araki Ken * vte.c: A problem which overwrites disp.gc->gc more than once and causes leak of GC resource is fixed. * ml_screen.h: ml_screen_logical_visual_is_reversible() is added. * ml_logical_visual.[ch]: "is_reversible" flag is added to ml_logical_visual_t. 2011-07-25 Araki Ken * x_window.c: Fixed typo in x_window_ft_draw_string8(). (cairo_show_text( ... , str) -> cairo_show_text( ... , buf)) * x_font.c: - If x_font_t::id has FONT_BOLD, x_font_t::is_double_drawing is always 1 in cairo because the width of normal font is different from that of bold font in some cases. - pixel_size passed to cairo_matrix_scale() is rounded up to multiple of 2. * x_window_win32.c: x_set_use_clipboard_selection() and x_is_using_clipboard_selection() return 0 in win32. 2011-07-24 Araki Ken * ml_vt100_parser.c, ml_term.[ch], x_screen.c: Bracketed paste mode (CSI ? 2004 h , CSI ? 2004 l) is supported. * version.h.in: 3.0.6 -> 3.0.6 post 2011-07-23 Araki Ken * 3.0.6 released. (tag "rel-3_0_6") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.6. * etc/main, etc/main.ja, mlterm.1, README.ja: Updated * ml_line.c: ml_char_bytes_equal() is used instead of ml_char_equal() in ml_line_get_num_of_filled_chars_except_spaces(). 2011-07-19 Araki Ken * x_window_win32.c: x_window_set_use_cairo() is added. * x_im_candidate_screen.c, x_im_status_screeen.c: x_window_set_use_cairo() is called in window_realized(). * x_font.c: CAIRO_HINT_METRICS_OFF is set in cairo_font_open. * UTF_MAX_SIZE in ml_char.h is changed from 8 to 6. 2011-07-17 Araki Ken * README, README.ja, gtk/INSTALL, man/mlterm.1: Updated * gtk/Makefile.in: Set valid value to SYSCONFDIR macro in CFLAGS. * cairo is supported for type_engine option. - x_window.[ch]: x_window_xft_draw_string{8|32} => x_window_fc_draw_string{8|12}. x_window_set_use_cairo() is added. - x_font.[ch]: cairo_calculate_char_width() and cairo_font_open() are implemented. - mc_font.c, mc_flags.[ch]: "cairo" checkbox is added. - configure.in: --with-type-engines option accepts "cairo" as value. - doc/en/README.cairo: Added. * x_font_config.c: The way of searching shared font tables in create_shared_font_config() and x_release_font_config() is fixed. * ml_char_encoding.[ch]: ml_convert_to_ucs4, ml_use_cp932_ucs_for_xft and ml_convert_to_xft_ucs4, are moved to x_font.c * x_type_engine.c: Added 2011-07-12 Araki Ken * vte.c: - If command is not NULL and argv is NULL, argv(= {command,NULL}) is allocated in vte_terminal_fork_command(). - If name is NULL, "monospace" font is loaded in vte_terminal_set_font_from_string(). * mlconfig/main.c: "Indic" checkbox is selectable only if "Bidi(UTF8 only)" checkbox is not selected. * version.h.in: 3.0.5 post -> 3.0.6 pre * vte.c: gtk_style_{attach|detach}() and gdk_window_set_user_data() are not called. * README: Updated 2011-07-04 Araki Ken * vte.c: If command and argv arguments of vte_terminal_fork_command() is NULL, default shell is executed in child process. * x_gdiobj_pool.h: Include . * README.ja, gtk/INSTALL: Updated. 2011-07-02 Araki Ken * x_sb_view.h, x_win32.h: Independent from kik_types.h. * libind/lex.split.c: Added. (generated by lex) * im_kbd.c: If opt is NULL or not is checked before calling ml_get_char_encoding(opt) in im_kbd_new(). * x_font_win32.c: Fixed cs_info_table. * mlsearch.sh: "mlsearch.sh [pattern]" (without "prev" or "next") is available. * mkf_ucs4_iscii.c: Fixed ISCIICS_TO_INDEX() macro. * mkf/lib/dexport.map: Added. * ml_char.[ch]: ml_combine_chars -> ml_char_combine_simple * ml_line.[ch]: ml_get_num_of_filled_chars_except_spaces -> ml_line_get_num_of_filled_chars_except_spaces * README.ja, README.indic: Updated. 2011-06-29 Araki Ken * mlconfig/main.c, mc_flags.c: - Button of "use_ind" option is added. - Combo box of "iscii_lang" option is removed. * mc_iscii_lang.c: Removed. * mc_font.c: Fonts for ISCII_XXX encodings are possible to select. * x_font_manager.[ch]: x_(de)activate_local_font_config() are removed. * x_term_manager.c, x_main_config.c, x_screen.c: "use_ind" option is added. * ml_vt100_parser.c: Indic unicode characters are always converted to ISCII. * ml_logical_visual.c: iscii_logical_visual_t::visual_lines are removed. * ml_line.[ch]: - Cursor movement is fixed in ml_bidi_convert_logical_char_index_to_visual(). - ml_line_t::bidi_state -> ml_line_t::ctl_info.bidi -> ml_line_t::ctl_info.iscii - ml_line_is_using_iscii(), ml_line_use_iscii(), ml_line_unuse_iscii() and ml_line_iscii_render() are added. * ml_iscii.[ch]: - ml_iscii_get_lang(), ml_iscii_get_lang_name(), ml_iscii_lang_new() and ml_iscii_lang_delete() are removed. - ml_iscii_keymap_new() and ml_iscii_keymap_delete() are renamed to ml_isciikey_state_new() and ml_isciikey_state_delete(). - ml_iscii_new(), ml_iscii_delete(), ml_iscii_copy(), ml_iscii_reset() and ml_iscii() are added. - ml_iscii_lang_t -> ml_iscii_state_t - Iscii conversion tables are loaded dynamically. * ml_bidi.c: ml_bidi_copy() is added. * ml_char_encoding.[ch]: - ML_ISCII -> ML_ISCII_XXX - mkf_iscii_lang_t is removed. * mkf/lib/Makefile.in: MAJOR.MINOR version 15.0 -> 16.0 * mkf_8bit_conv.[ch], mkf_8bit_parser.[ch]: mkf_iscii_conv_new -> mkf_iscii_xxx_conv_new mkf_iscii_parser_new -> mkf_iscii_xxx_parser_new * mkf_charset.h: ISCII -> ISCII_XXX * mkf/lib/mkf_ucs4_iscii.c: mkf_map_iscii_to_ucs4 -> mkf_map_iscii_xxx_to_ucs4 * mkf/libtbl/mkf_ucs4_iscii.c: Added. * libind/: Added for processing indic characters. * etc/aafont.indic, etc/font.indic: Added. * README.iscii: Renamed to README.indic and updated. * README, README.ja, man/mlterm.1, PROTOCOL: Updated. * configure.in, xwindow/Makefile.in: Checking if regex.h exists or not is added. 2011-06-20 Araki Ken * "CSI < r", "CSI < s" and "CSI < t" sequences are supported. - x_im.h, im_ibus.c, im_iiimf.c, im_kbd.c, im_m17nlib.c, im_scim_mod_if.c, im_uim.c: is_activate() method is added. - im_ibus.c, im_scim.c: switch_mod() method is implemented. - x_xic.c, x_xic_win32.c: x_xic_is_active() and x_xic_switch_mode() are added. - ml_vt100_parser.c: sequences above are parsed. * x_term_manager.c, x_screen.c: Cursor color if input method is activated is changeable by "im_cursor_color" option. (Available only if built with USE_IM_CURSOR_COLOR macro.) 2011-06-19 Araki Ken * vte.c: - vte_terminal_search_set_gregex(), vte_terminal_search_get_gregex(), vte_terminal_search_previous() and vte_terminal_search_next() are implemented. - Columns and rows which are passed to ml_term_create() are replaced by main_config.cols and main_config.rows, not 80 and 25. - line_scrolled_out() is fixed. * "search_prev" and "search_next" which search specified pattern (regex) in mlterm screen are added to configuration protocol. - ml_screen.[ch]: ml_screen_t::search member is added. ml_screen_search_{init|final|reset|find}() are added. - tool/accessories/mlsearch.sh: Added - x_scrollbar.[ch]: x_scrollbar_move_to() is added. - x_screen.c: match() and search_find() are added. * gtk/Makefile.in: "-Wall" is replaced by @CFLAGS@ and @CPPFLAGS@ in CFLAGS. * x_font_cache.c: x_font_cache_t::prev_cache is initialized in x_acquire_font_cache() before init_usascii_font() which accesses x_font_cache_t::prev_cache in x_font_cache_get_xfont() is called. * UTF_MAX_CHAR_SIZE and XCT_MAX_CHAR_SIZE are moved to ml_char.h and renamed to MLCHAR_UTF_MAX_SIZE and MLCHAR_XCT_MAX_SIZE. * ml_line.[ch]: ml_line_copy_str() is renamed to ml_line_copy_logical_str(). * ml_char_encoding.[ch]: ml_char_encoding_convert{_with_parser}() are added. * README, README.ja, README.win32: Updated. * version.h.in: 3.0.5 -> 3.0.5 post 2011-06-04 Araki Ken * 3.0.5 released. (tag "rel-3_0_5") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.5. * configure.in: gtk/ directory is added to compilation targets only if vte library is installed to system. * doc/en/README.win32, doc/ja/README.win32: Updated. * "ssh_public_key" and "ssh_private_key" options are added. - ml_pty_ssh.c, x_term_manager.c: Modified. - mlterm.1, README.ja: Updated. * kik_path.c: kik_get_home_dir() is added. 2011-05-29 Araki Ken * 3.0.4 released. (tag "rel-3_0_4") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.4. * configure.in: configure script doesn't stop if gdk-pixbuf-2.0 is not found. * configure: re-generated * mlconfig/main.c, mc_font.c: Tooltip text is set to widgets changing font size. * x_font.c: "-*-biwidth-*-" font is automatically loaded only for unicode biwidth characters. * etc/main, etc/main.ja: Updated. * mlclient.1: Fixed. 2011-05-25 Araki Ken * mlterm/ml_pty.c: Revived. (Thanks to Koie Hidetaka san) * xwindow/Makefile.in, mlimgloader/Makefile.in: $(OBJ:.o=.lo).libs => $(OBJ:.o=.lo) .libs (Thanks to Koie Hidetaka san) 2011-05-22 Araki Ken * README.ja: Updated. * mkf_charset.h: Error of IS_BIWIDTH_CS macro is fixed. * x_font_config.c: "XXX_NARROW" key for font configuration is supported. (JISX0208_1983 for biwidth font, JISX0208_1983_NARROW for narrow font.) * ml_font.h: NORMAL_FONT_OF checks IS_BIWIDTH_CS and sets FONT_BIWIDTH. * mlclient/main.c: If mlterm server returns error, retry by configuration protocol(ESC ] 5379 ; mlclient BEL). * vte.c: kik_sig_child_init and kik_sig_child_final are called. * kik_mem.h: undef alloca before defining it. 2011-05-21 Araki Ken * man/mlterm.1, README.ja, README.win32: Updated. * x_font_win32.c: Proportional font is not assumed in order to prefer drawing performance. * x_font.c, x_font_win32.c: IS_BIWIDTH_CS is removed from x_font_new(). * x_window_win32.c: Rectangle() is replaced by FillRect(). * vte.c: Hack for roxterm is added. 2011-05-15 Araki Ken * "use_unicode_property" option which enables properties of unicode in other codesets is added.(Thanks to Hidetaka Koie san) - ml_vt100_parser.[ch]: Unicode property of received characters is checked. - x_main_config.[ch]: "use_unicode_property" option is added. - ml_char.c: IS_BIWIDTH_CS is removed from ml_char_biwidth() and is checked in ml_vt100_parser.c. Its result is given to ml_char_set(). * Support libssh2. - ml_pty_ssh.c, ml_pty_intern.h are added. - configure.in: --enable-ssh2 option is added. - "default_server" option is available in unix and value format of it is changed. - x_connect_dialog is partially implemented in unix. - kiklib/src/kik_path.c: kik_parse_uri() is added. - xwindow/main.c: WSAStartup and WSACleanup are added in win32. * winrs.rs, x_connect_dialog.c: Port number is possible to specify in dialog. * kiklib/src/Makefile.in: MAJOR.MINOR version 12.1 => 13.0 * kik_pty_xxx.c: kik_pty_helper_close(int) => kik_pty_close(int) * mlclient/main.c - A bug which has broken mlclientx since 3.0.3 is fixed. * x_font_config.c: Bug fix in x_deactivate_local_font_config(). 2011-04-25 Araki Ken * ml_vt100_parser.c: Fixed SF Bug #3280196 by accepting 0x80-0x9f characters as Pt in get_pt_in_esc_seq(). (Thanks to Yoshiaki Kasahara san) * im_ibus.c: Fixed result->id in im_ibus_get_info(). ("iBus" => "ibus") (Thanks to shitamo san) * im_kbd.c, x_screen.c, ml_term.c: If 'not_use_unicode_font' option is specified, indic characters in unicode are drawn as iscii ones. * x_screen.c: Number of calling flush_scroll_cache() is decreased. * mkf_charset.h, ml_iscii.h: ml_iscii_lang_type_t in ml_iscii.h is replaced by mkf_iscii_lang_t in mkf_charset.h. * mkf_ucs4_map.c, mkf_locale_ucs4_map.c: Mapping function used previously is cached to improve performance. * mkf_{viscii|iscii}_{conv|parser}.[ch]: Integrated to mkf_8bit_{conv|parser}.[ch] and removed. * mkf_ucs4_iscii.[ch]: Added. * version.h.in: 3.0.3 -> 3.0.4 pre 2011-04-02 Araki Ken * mkf/lib/Makefile.in: increased MAJOR version. (14->15) * ml_char_encoding.[ch], mkf_8bit_conv.[ch], mkf_8bit_parser.[ch], mkf_charset.h, mkf_ucs4_cp125x.[ch], mkf_ucs4_map.c, mc_font.c, x_font.c, x_font_manager.c: CP874 which requires "-u" option is supported. * x_draw_str.c: All fonts use the same ascent (ascent of US-ASCII font) in order to align baseline. (Merged a part of ID:3243231 patch, Thanks to Kusanagi Kouichi san) 2011-03-30 Araki Ken * ml_iscii.c: - Support "%d" which is converted to font size in "FONT" entry of /etc/libind.conf. - Fixed minor bugs. * ml_edit_scroll.c: ml_edsl_delete_line() and ml_edsl_insert_new_line() use CopyArea or BitBlt in scrolling. * x_window_win32.c: x_set_use_clipboard_selection() and x_is_using_clipboard_selection() are added. * x_window.c: x_set_clipboard_selection() -> x_set_use_clipboard_selection() * ml_char.c: ml_(un)use_multi_col_char() -> ml_set_use_multi_col_char() ml_(un)use_char_combining() -> ml_set_use_char_combining() * man/mlterm.1: Merged ID:3243508 patch. (Thanks to Ahmed El-Mahmoudy) 2011-03-22 Araki Ken * ml_edit.c: Fixed wraparound problem in ml_edit_overwrite_chars(). * configure.in: Fixed a bug which forcibly disabled "--with-imagelib=gdk-pixbuf1" option of configure if gdk-pixbuf2 was installed to your system. * mlimgloader/main.c: Fixed error in compiling with gdk-pixbuf1. 2011-03-20 Araki Ken * 3.0.3 released. (tag "rel-3_0_3") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.3 * configure: re-generated * man/mlterm.1, doc/en/README.win32, doc/ja/README.win32, README.ja: Updated * win32/setup-msys.bat: "set CYGWIN=tty" is added. * x_term_manager.c, x_window.c: "use_clipboard" option which enables CLIPBOARD selection (not only PRIMARY selection) is added. * tool/mlconfig/main.c, mc_flags.c: "use_clipboard" option is added. 2011-03-11 Araki Ken * vte.c: palette settings are reflected in vte_terminal_set_colors(). * x_screen.c: "--initstr" option is prohibited in "mlclient" configuration protocol. 2011-03-09 Araki Ken * im_iiimf_aux.c: Compilation error is fixed. * x_color_cache.c: x_color_cache_256_t.is_loaded is cleared in unloading 256 colors in x_color_cache_unload() instead of x_color_cache_t.is_loaded. * vte.c: - Implementation of gdk_color_to_string() is added for gtk+ < 2.12. - Checking if GtkWidget.allocation is a initial one or not is added before x_window_resize() in vte_terminal_fork_command and vte_terminal_forkpty. - If a wall picture is set and 'alpha' option is less than 255, run-time change of 'bg_color' option automatically causes alpha blending of wall picture. * x_screen.c: If 'use_transbg' option is unset, screen->pic_mod.alpha is never reset. 2011-03-06 Araki Ken * vte.c: - Members of x_main_config_t is not changed dynamically. - gtk_widget_set_rc_style is used instead of gtk_widget_ensure_style in vte_terminal_init. * im_ibus.c: - RGB of foreground or background of IBusAttribute is not used, but if background of IBusAttribute is specified, ML_FG_COLOR and ML_BG_COLOR are reversed in update_preedit_text(). - DBus functions are used directly in connection_handler(_idling). 2011-03-05 Araki Ken * im_ibus.c: - im_ibus_get_info() is added. - IBusText->attrs is applied. 2011-03-03 Araki Ken * inputmethod/ibus: Native iBus support is added. (Experimental) * ml_vt100_parser.c: ISO2022 escape sequence which was wrongly parsed by parse_vt100_escape_sequence() in ml_vt100_parser.c is correctly passed to mkf. * kik_mem.h: alloca is wrapped by memset(..0xff..) if KIK_DEBUG is defined. 2011-02-27 Araki Ken * x_imagelib.c: Size of args array in load_file() is fixed from 4 to 6. * configure.in: - '\r' which can be output by pkg-config in win32 is removed from GDK_PIXBUF_CFLAGS and GDK_PIXBUF_LIBS. - mlimgloader is not built in win32. * mkf_iso2022_parser.c: iso2022_parser->g1_is_decsp = 0 if cs except decsp is set to g1. 2011-02-26 Araki Ken * tool/mlconfig/po/Makefile.in.in: $(mkinstalldirs) is removed and $(MKINSTALLDIRS) is used directly. (Thanks to Iwamoto Kouichi san) * x_screen.c: ml_term_set_modified all_lines_in_screen() is always called in x_screen_attach() regardless of result of update_special_visual(). * ml_term.c, ml_screen.c: Meaning of return value of ml_term_update_special_visual() and ml_screen_delete_logical_visual() is changed. 2011-02-24 Araki Ken * x_imagelib.c: "/" is appended to LIBMDIR in kik_dl_open(). (Thanks to Iwamoto Kouichi san) * configure.in: If gdk-pixbuf is linked to mlterm, DLOPEN_LIBM and LIBMDIR macros are never defined. 2011-02-23 Araki Ken * libtool: version down to 1.5.26 * x_window.c: x_decsp_font_draw_string() is used instead of x_decsp_draw_image_string() in x_window_draw_decsp_string(). (Thanks to Iwamoto Kouichi san) * vte.c: Returned value of gdk_screen_get_resolution() is used for DPI of xft font. * x_font.c: x_font_set_dpi_for_xft() is added. 2011-02-23 Araki Ken * configure.in, Makefile.in: @DL_LIBS_SB@ is removed from gtk/Makefile.in in order to avoid --version-script=\$(top_srcdir)/xwindow/dexport.map option in building libvte library. * version.h.in: 3.0.2 post -> 3.0.3 pre 2011-02-21 Araki Ken * xwindow/Makefile.in: $(LMLTERM) is moved before $(LMKF) in LIBS1. (This bug causes link error in win32.) * configure, aclocal.m4, ltmain.sh: Updated to libtool 2.2.6b. * configure.in: 'nm -D libm.so' is used instead of 'objdump -T libm.so'. 2011-02-19 Araki Ken * kik_debug.c: Wrong modification in 2011-02-08 is fixed. * configure.in, xwindow/Makefile.in: - Check if libm is possible to dlopen by 'objdump -T libm.so'. - SYSLIBDIR => LIBMDIR - MATH_CFLAGS and MATH_LIBS are added. * x_display.c: x_display_get_visual_info() is added. * x_imagelib.c, mlimgloader/main.c: code clean up. 2011-02-18 Araki Ken * pixmap_engine.c: Common pixmaps are shared by multiple scrollbar views. 2011-02-16 Araki Ken * x_imagelib.c: Fixed create_cardinals_from_image(). 2011-02-13 Araki Ken * README, doc/ja/README.ja: Updated. * tool/mlimgloader/main.c, Makefile.in: Added. mlimgloader which depends on gdk-pixbuf loads image files. If --with-imagelib option is not specified to configure, mlterm uses mlimgloader for wall picture, icon picture and pixmap_engine. * xwindow/dexport.map: Added. It specifies dynamic symbols for pixmap_engine. * ml_shape.c, ml_logical_visual.c: If USE_FRIBIDI or USE_IND is not defined, related codes are removed in building mlterm binary. 2011-02-08 Araki Ken * xwindow/Makefile.in: Fixed SF Bug #3158963. (Thanks to Jyun-Yan You) * ml_vt100_parser.c: Fixed a bug in previous commit. (Thanks to Iwamoto Kouichi san) 2011-01-29 Araki Ken * ml_vt100_parser.c: Unsupported but valid escape / CSI sequence format is correctly ignored. (Thanks to Iwamoto Kouichi san) * x_imagelib_win32.c, x_window_win32.c: "wall_picture" option is partially supported in win32. (Supported BMP format only.) 2011-01-09 Araki Ken * ml_char.c: ML_BOLD_COLOR_MASK is not set for background color. 2011-01-06 Araki Ken * ml_edit.c: - If beg >= end (not beg > end), ml_edit_set_scroll_region fails. - wraparound is supported in vertical_tabs. * ml_vt100_parser.c: - "ESC [ b"(REP) is supported. * xwindow/version.h.in: 3.0.2 => 3.0.2 post 2011-01-02 Araki Ken * 3.0.2 released. (tag "rel-3_0_2") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.2 * configure: re-generated * pixmap_engine.c: First argument of x_imagelib_load_file() is changed from Display to x_display_t. * mc_letter_space.[ch]: Added. * etc/main.ja: Updated. * x_color_cache.c: x_color_cache_t::is_loaded and x_color_cache_256_t::is_loaded are initialized to zero. * vte.c: IS_MLTERM_SCREEN() macro uses PARENT_WINDOWID_IS_TOP() instead of checking win->parent_window is None or not, because win->parent_window is never None in xlib. * ml_vt100_parser.c: - "ESC [ ! p"(DECSTR) is partially supported. - ml_screen_goto_home() is called with ml_screen_set_scroll_region() in "ESC [ r" sequence. * ml_edit.c: ml_edit_set_scroll_region() doesn't let cursor go home in order to support DECSTR which resets terminal but doesn't reset cursor position. 2011-01-01 Araki Ken * gtk/vte.c: vte_terminal_fork_command_full, vte_terminal_search_set_gregex, vte_terminal_search_get_gregex, vte_terminal_search_set_wrap_around, vte_terminal_search_get_wrap_around, vte_terminal_search_find_previous, vte_terminal_search_find_next are added. * gtk/Makefile.in: `pkg-config vte --cflags` is used instead of `pkg-config gtk+-2.0 --cflags` * x_term_manager.c: SF Bug #3148132 is fixed. (Thanks to Orgad Shaneh) * "letter_space" option is added. * ml_vt100_parser.c: Minor fixes. * x_screen.c: "mlclient(x) -e ..." configuration protocol in vt100 sequence is prohibited. 2010-12-29 Araki Ken * ml_vt100_parser.c: "ESC [ r" and "ESC c" reset scrolling region. (Thanks to Iwamoto Kouichi san) 2010-12-28 Araki Ken * ml_edit.c: - 'use_bce' flag is managed in ml_edit.c, not in ml_screen.c. - Bug which disabled vttest 11.4.5 are fixed. * ml_edit_util.c: Bug which disabled vttest 11.4.6 are fixed. * ml_screen.c: "|()[]{}" is added to default value of word_separators option. 2010-12-25 Araki Ken * vte.c: - vte_terminal_set_word_chars is implemented. - vte_terminal_match_add_regex and vte_terminal_match_check are partially implemented. * button3_behavior option accepts "mlclient -e w3m", "/usr/bin/emacs" and so on. In this case, specified program which gets selected text as arguments starts when button3 is clicked. * word_separators and button3_behavior options are possible to change by configuration protocol. * kiklib/src/Makefile.in: MINOR = 0 => MINOR = 1 * kik_args.[ch]: kik_arg_str_to_array is added. 2010-12-20 Araki Ken * x_sample_sb_view_win32.c, x_sample_sb_viwe_lib_win32.c: Wrong arguments of x_get_icon_pixmap are fixed. * x_imagelib_win32.c: Wrong argument of x_imagelib_load_file is fixed. * x_window_win32.c: x_set_window_name is partially implemented. 2010-12-18 Araki Ken * x_color.c: fall-backs code for "black"/"white" (see 2006-03-14 ChangeLog) is removed because color_cache->black is loaded by rgb, not "black". * doc/ja/README.ja, man/mlterm.1: Minor fixes. 2010-12-16 Araki Ken * x_im_{candidate|status}_screen.c: x_window_set_xft is added to x_window_t::realized event handler. * x_display.c: Minor fixes. * x_window.c, x_window_win32.c: Double buffering code is removed. 2010-12-15 Araki Ken * vte.c: If visual of parent window is not default one, visual, colormap and depth attributes from parent window are set to x_display members. * scrollbar/sample, contrib/scrollbar/extra, contrib/scrollbar/pixmap_engine: visual, colormap and depth are obtained from window attributes. * x_window.c: - Type of {fg|bg}_color members is changed from u_long to x_color_t. - x_window_set_xft function which creates or destroys xft_draw member of x_window_t is added. - XCreateWindow is used instead of XCreateSimpleWindow in order to specify visual and colormap. - XftDrawRect is used instead of xlib functions in xft mode. * x_color.c, x_color_win32.c, x_color_cache.c, x_imagelib.c: x_display_t is used instead of Display in order to use visual, colormap and depth of x_display_t. * x_display.c: visual, colormap and depth are managed in x_display_t. * x_term_manager.c, x_display.c, doc/ja/README.ja, man/mlterm.1: 'depth' option is added. * x_gc.c: DefaultGC is used in x_gc_new if drawable is not specified. * x_color.c, ml_color.c: - alpha is processed. - "rgba:RR/GG/BB/AA" or "#RRGGBBAA" format is supported. * gtk/INSTALL: Minor fixes. 2010-11-28 Araki Ken * version.h.in: 3.0.1 post -> 3.0.2 pre * vte.c: - vte_terminal_key_press is added. - "encoding-changed" signal is supported. - Minor fixes. 2010-11-25 Araki Ken * x_screen.c: Hidden value "none" is added to button3_behavior option. * vte.c: - Button and key signals to enable popup menu of gnome-terminal, roxterm and etc are supported. - vte_terminal_get_has_selection is implemented. - vte_terminal_reset is partially implemented. - vte_terminal_get_text, vte_terminal_get_text_include_trailing_spaces, vte_terminal_get_text_range and vte_terminal_match_check return NULL instead of "". - gtk_widget_queue_resize_no_redraw in processing ConfigureNotify event in vte_terminal_filter is removed. (Fixed a problem of resizing gnome-terminal.) 2010-11-21 Araki Ken * vte.c: Value of type_engine option can be specified in ~/.mlterm/main in vte compatible library. * reaper.c: #include is added. 2010-11-19 Araki Ken * vte.c: "window-title-changed" / "icon-title-changed" signals and "window-titel" / "icon-title" properties are supported. * gtk/Makefile.in: x_simple_sb_view.lo is removed. * x_font_cache.c: Call of kik_map_new_with_size() is collected to xfont_table_new(). 2010-11-10 Araki Ken * vte.c: term_type static variable and TERM_TYPE macro are removed and main_config.term_type is used instead. * doc/en/PROTOCOL, man/mlterm.1, doc/ja/README.ja: Explanation about "bidi_mode" is added. * ml_bidi.[ch], ml_line.[ch], ml_logical_visual.[ch], ml_term.[ch], ml_term_manager.[ch], x_main_config.[ch], x_screen.c, x_term_manager.c: "bidi_mode" option is added. * x_font.c: get_xft_col_width() is rewritten. 2010-10-27 Araki Ken * vte.c: - If backscroll mode is BSM_STATIC, GtkAdjustnemt::value is not changed when line is scrolled out. - gtk_widget_queue_resize_no_redraw() is added to vte_terminal_size_allocate() because gnome-terminal(2.29.6) isn't resized correctly without it. - Following functions are implemented. vte_terminal_select_all vte_terminal_select_none vte_terminal_set_color_cursor vte_terminal_get_emulation vte_terminal_get_default_emulation vte_terminal_get_window_title vte_terminal_get_icon_title * gtk/INSTALL: Unsupported vte api functions, signals and property are enumerated. * x_imagelib.c: Checking if *file_path is '\0' or not is added to x_imagelib_load_file_for_background() because following strncmp( "" , "pixmap:" , 0) can return 0. 2010-10-22 Araki Ken * vte.c: - VteTerminal doesn't catch x_system_event_listener_t::pty_closed but ml_pty_event_listener_t::pty_closed event. - vte_terminal_set_background_saturation() is implemented. - Minor fixes. * x_imagelib.c: GdkPixbuf which load_file() returns is copyed before modify_image. * ml_term.c: ml_term_zombie() is added. * ml_term_manager.c: ml_term_manager_enable_zombie_pty() is added. 2010-10-15 Araki Ken * x_font.c: x_font_use_point_size() is added. * vte.c: - configure_toplevel() is added to process ConfigureNotify event of top level window for transparency. - vte_terminal_set_opacity() is implemented. - kik_sig_child_init is not called. VteReaper is used to manage child process instead. - vte_terminal_forkpty() returns 0 for child process. - vte_terminal_hierarchy_changed() is added. - x_font_use_point_size(1) is called in vte_terminal_class_init(). * reaper.c: Added. * configure.in: - SYSLIBDIR is added. - USE_IMAGELIB => USE_EXT_IMAGELIB * x_window.c: MapNotify is ignored. * x_imagelib_none.c, x_imagelib_gdk => x_image_lib.c - x_imagelib_get_transparent_background() is supported without gdk-pixbuf. (alpha option is enabled not only in win32 but also in xlib.) - Cashing mechanism in x_imagelib_load_file_for_background() and x_imagelib_get_transparent_background() is mostly moved to x_picture.c. * x_picture.h: blend_color => blend_red, blend_green and blend_blue. * x_picture.c: - x_picture_modifiers_equal() is added. Then, x_picture_modifier_is_normal() is rewritten as macro using x_picture_modifiers_equal(), and is_picmod_eq() in x_imagelib.c is removed. - x_bg_picture_init(), x_bg_picture_final(), x_bg_picture_load_file(), x_bg_picture_get_transparency() => x_acquire_bg_picture(), x_release_bg_picture() 2010-10-04 Araki Ken * x_window.c: - XCheckTypedWindoEvent is used instead of XCheckMaskEvent in x_window_receive_event. - Checking win->wall_picture_is_set is removed in x_window_unset_wall_picture(). - x_window_resize_with_margin() checks if width or height is larger than win->margin * 2. - Fixed wrong definition of IS_INHERIT_TRANSPARENT macro. - x_window_enable_inherit_transparent() is added. * kiklib/src/Makefile.in: increased MAJOR version. (11->12) * kiklib/src/kik_pty*: - slave_name is removed from arguments of kik_pty_fork(). - kik_pty_helper_close and kik_pty_helper_set_flag functions are added. * kiklib/src/kik_pty_helper.c: Added for gnome-pty-helper. * kiklib/configure.in: - --enable-pty-helper option is added. - recvmsg, setpgid and socketpair are checked. * gtk/vte.c: - vte_terminal_forkpty is not called in vte_terminal_realize(). - vte_reaper_get and vte_reaper_add_child functions are added. - width and height members of x_window_t are set if GtkWidget is not still realized in vte_terminal_set_font_from_string(). - "inner-border" property is available. - vte_terminal_size_allocate() is fixed. 2010-09-25 Araki Ken * x_window.c: XK_Num_Lock is added to default_keysyms in x_window_get_mod_ignore_mask() to fix SF Bug #3072833 which was caused by 2010-06-03 fix. (Thanks to Andreas Metzler) 2010-09-24 Araki Ken * kik_utmp_sysv.c, gtk/INSTALL: Minor fixes 2010-09-23 Araki Ken * kik_pty_streams.c: '#if && defined(I_PUSH)' is added at ioctl( .. I_PUSH .. ). * kik_utmp_sysv.c (kik_utmp_new): - setut(x)ent() is moved after kik_priv_restore_egid() from before it. (putut(x)line() could fail without this fix.) (SF Bug #3051467, Thanks to David Kolovratnik) - kik_priv_change_egid(getgid()) is called not only if pututxline() succeeds but also if it fails. - endut(x)ent() is called after putut(x)line(). - ut.ut_session = getsid(0) is added. * gtk/INSTALL: Added * gtk/mlvte.h, mlvte-in.c, mlvte-ex.c, main.c: Removed * USE_IMLIB, USE_GDK_PIXBUF => USE_IMAGELIB 2010-09-22 Araki Ken * vte.c: vte_terminal_set_alternative_screen_scroll() function (which is empty yet) is added. (Thanks to Usama Akkad) * x_imagelib_none.c: cleanup * gtk/Makefile.in: '-lX11' is added to 'gmlterm-in' and 'gmlterm-ex' targets. (Thanks to to Hicham Haouari) * xwindow.c: Code related to Pseudo transparency (especially around ParentRelative transparency) is cleaned up. PropertyNotify of "_XSETROOT_ID" is supported. 2010-09-22 Araki Ken * Imlib support is dropped. x_imagelib_imlib.c and x_imagelib_imlib2.c: Removed configure.in and configure: 'imlib' is removed from value of --with-imagelib option. (To tell the truth, 'imlib' is still possible to specify as a value of --with-imagelib option if x_imagelib_imlib.c file is revived.) README, README.ja, mlterm.1, mlterm.spec: Updated * gtk-1.x support is dropped. mc_font.c, gtkxlfdsel.c, tool/mlconfig/main.c mlterm-menu.c: Anything related to gtk-1.x is removed. configure.in: gtk-1.x is not supported. README, README.ja, mlterm.1: Updated 2010-09-20 Araki Ken * vtetypebuitins.c: Added * vte.c: vte_terminal_set_{backspace|delete}_binding() are implemented. 2010-09-19 Araki Ken * vte.c: adj_value_changed_by_myself is set to 1 in line_scrolled_out(), otherwise bidi text is not correctly drawn. (Thanks to Usama Akkad) * tool/mlconfig/Makefile.in -lX11 is added to LIBS2 variable. (Thanks to Hicham Haouari) 2010-09-18 Araki Ken * vte.c: pango_font_description_to_string() is used in vte_terminal_set_font(). 2010-09-18 Araki Ken * vte.c: Font and color configuration protocol updates font setting immediately. Pressing button3 opens menu whose items are still just "Copy" (which copys selected text to clipboard) and "Paste". 2010-09-16 Araki Ken * gtk/marshal.[ch], vte.c: Added for vte compatible api. * man/mlterm.1, doc/ja/README.ja: updated * "default" value which makes mlterm follow default setting of anti-alias is added to "use_anti_alias" option. If -A option is not specified in startup, the value of "use_anti_alias" is "default" by default. If you want to disable anti alias explicitly, specify "use_anti_alias=false" or -A=false. * scim/im_scim_mod_if.c, im_scim.cpp: code clean up. * ml_color.c: Fixed a bug of shifting 16 bit color to 8 bit in ml_color_parse_rgb_name(). (">> 4" => ">> 8") * ml_vt100_parser.c: Check of VTE_CJK_WIDTH environment is added (but disabled for now). * x_screen.[ch]: x_screen_get_config is removed (not public). 2010-09-01 Araki Ken * x_im_candidate_screen.c, x_im_status_screen.c: Fixed a bug of argument of x_display_show_root(). (SF Bug #3051467, Thanks to Khaled Hosny) * man/mlterm.1, doc/ja/README.ja: parent_window option is added. * gtk/Makefile: Renamed to Makefile.in * gtk/mlvte-in.c: Added. It wraps xwindow/x_screen.c. * gtk/mlvte.c: Renamed to mlvte-ex.c 2010-08-16 Araki Ken * gtk/main.c: Wrong arguments of g_signal_emit_by_name( "focus-in-event" ... ) are fixed. * gtk/mlvte.c: sig_int() is added for SIGINT. waitpid() after fork() is added. * mlclient/main.c: If mlterm server is daed, mlclient returns 1 instead of writing "\x1b]5379;mlclient\x07". 2010-07-28 Araki Ken * mlvte.c: reset_size() is added. 2010-07-27 Araki Ken * x_window.c: XSetInputFocus() is called in ButtonPress event. * x_screen.c, x_display.c: --parent("parent_window") option is added. * gtk/Makefile, main.c, mlvte.[ch]: Added. 2010-06-29 Araki Ken * ml_vt100_parser.c: fg and bg colors of bce character are changed by "ESC[48;5;Xm" sequence. (Thanks to Anonymous bin ich) * ml_vt100_parser.c: 0x7f is ignored. (Thanks to Y.Amagai) (see http://vt100.net/docs/vt100-ug/table3-10.html) 2010-06-22 Araki Ken * x_screen.c: Fixed a bug which disabled transparency of mlterm without image library like gdk-pixbuf. (SF Bug #3014219, Thanks to Khaled Hosny) 2010-06-10 Araki Ken * x_screen.c: Fixed a bug which disabled delete key in win32. * ml_char.c: 'is_comb' flag check which destroys Lam Alef ligature is excluded in ml_char_combine. (SF Bug #3012762, Thanks to Khaled Hosny) * xwindow/version.h.in: 3.0.1 => 3.0.1 post 2010-06-07 Araki Ken * 3.0.1 released. (tag "rel-3_0_1") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.1 * configure: re-generated 2010-06-06 Araki Ken * x_win32.h: XK_Begin, XK_KP_Begin and IsKeypadKey macros are added for win32. * etc/termcap: kh and @7 definitions are added to "xterm" and "*". * x_screen.c: Fixed a bug which disabled keyboard input in application keypad mode. 2010-06-03 Araki Ken * x_font.c: Returned value of get_cs_info() is checked. * x_screen.c: Modifier keys with Del/Home/End are distinguished. The keypad middle key (XK_Begin, XK_KP_Begin) is mapped to ^[[E, ^[[1;5E etc. (SF Bug #2818015, Thanks to Thomas Wolff) * x_screen.c: If Num_Lock is pressed, application keypad is ignored. * x_window.c: XK_Num_Lock is not ignored in XModifierKeymap by default. 2010-05-23 Araki Ken * man/mlterm.1, doc/ja/README.ja: Updated. * x_screen.c: The default value of button3_behavior option is changed from "menu1" to "xterm". * x_screen.c: Release events for the wheel buttons are not reported. (SF Bug #2818018, Thanks to Thomas Wolff) 2010-05-22 Araki Ken * xwindow/version.h.in: 3.0.0 post -> 3.0.1 pre * mc_flags.c: "Ambiguouswidth = fullwidth (UTF8 only)" checkbox is added for "col_size_of_width_a" option. * x_screen.c: "col_size_of_width_a" option is added to configuration protocol. * x_screen.c: Screen is redrawn in selection_cleared(). 2010-05-19 Araki Ken * Performance of 256colors2.pl(1999/07/11 version) is improved by reducing number of redrawing screen in "\x1b]4;%d;rgb:..." seqeunce. (Thanks to Konosuke Watanabe san.) (set_{font|color}_config in x_term_manager.c are moved to x_screen.c, and {font|color}_updated which are called from stop_vt100_cmd() in x_screen.c are added to x_term_manager.c.) 2010-05-08 Araki Ken * ml_vt100_parser.c: "ESC[9Nm" and "ESC[10Nm" sequences are supported. * x_color_cache.c: get_cached_vtsys_xcolor() returns colors compatible with xterm. * x_screen.c: Even if screen is not selection owner, "selected_text" protocol returns former value. 2010-05-05 Araki Ken * --button3/button3_behavior option is added. Now pressing button3 shows conf_menu_path_1 program (mlterm-menu) like gnome-terminal by default except in win32. If "xterm" is specified as a value of this option, pressing button3 works like xterm as before. * mlterm-menu.c: "Copy" and "Paste" menus are added. "Copy" copys selected text to clipboard. "Paste" works like INSERT_SELECTION. * x_screen.c: "selected_text" and "paste" options are added to configuration protocol. * ml_term.c: revert_visual argument is added to ml_term_unhighlight_cursor(). If revert_visual is 0, ml_term_unhighlight_cursor() leaves ml_term_t logical. start_vt100_cmd functions in x_screen.c and ml_vt100_parser.c are also fixed. 2010-04-29 Araki Ken * ml_char.c: ML_WHITE | ML_BOLD_COLOR_MASK is used to replace 0xe7 color internally instead of ML_WHITE. * x_color_cache.h: x_color_cache_256_t is added for caching all 256 colors. x_color_cache.c: Fixed. * x_color.h: x_color_t structure is defined instead of typedef X(ft)Color x_color_t in order to shrink x_color_t size. x_color.c: Fixed. * man/mlclient.1, man/mlterm.1: Merged id:2988801 patch. (Thanks to Ahmed El-Mahmoudy) 2010-04-17 Araki Ken * configure.in, mkf/Makefile.in, tool/mlclient/Makefile.in: Merged id:2987646 patch. (Thanks to Ahmed El-Mahmoudy) * ml_vt100_parser.[ch]: xterm_listener->start or xterm_listener->stop event is called once from ml_parse_vt100_sequence(). Maximum size read from pty in ml_parse_vt100_sequence() is increased from PTY_RD_BUFFER_SIZE to PTY_RD_BUFFER_SIZE * 3. * xwindow/version.h.in: 3.0.0 -> 3.0.0 post 2010-04-10 Araki Ken * 3.0.0 released. (tag "rel-3_0_0") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 3.0.0 * configure: re-generated * x_sb_view_factory.c: If mlterm is not built with -export-dynamic option, functions related to pixmap_engine are removed from x_sb_view_factory.c. * x_sb_view.c: ver0_color_changed which is a wrapper function of version 0 library calls x_sb_view_ver0_t::draw_decoration for update_color of motif.c. * ml_line.c: if LTR-base is changed to RTL-base, line is redrawn in ml_line_bidi_render(). 2010-04-04 Araki Ken * man/mlterm.1, doc/ja/README.ja, doc/en/README.win32, doc/ja/README.win32: Updated * x_main_config.c: -d/--display option is removed in win32. * ml_vt100_parser.c: Fixed a bug which treated VPR as VPB wrongly. (See http://slashdot.jp/~doda/journal/503828 in detail.) VPB and HPB sequences are supported. * configure.in, version.h.in, x_term_manager.c: CVS_REVISION is replaced by CHANGE_DATE. mlterm -v shows "mlterm version N.N.N pre(or post)/YYYY-MM-DD". 2010-04-01 Araki Ken * tool/mlconfig/mc_font.c, gtkxlfdsel.c: If G_PLATFORM_WIN32 is defined, GtkXlfdSelection is not used. 2010-03-31 Araki Ken * doc/en/PROTOCOL: Fixed. * doc/en/README.win32, doc/ja/README.win32: Updated. * tool/mlclient/Makefile.in: mlclientx command is added. * tool/mlclient/main.c: mlclient tries "\x1b]5379;mlclient...\x07" sequence if mlterm server is dead. * x_display_win32.c: kik_file_set_cloexec(Display::fd) is added. 2010-03-28 Araki Ken * tool/mlconfig/gtkxlfdsel.[ch]: Added. GtkXlfdSelection which is ported from gtkfontsel.[ch] in GTK+-1.2.10 shows XLFD font in GTK+ >= 2.0. mc_font.c: Fixed around gtkxlfdsel.[ch]. * kik_utmp_sysv.c: /dev/ttypN format is supported. * configure.in, tool/mlconfig/Makefile, contrib/tool/mlterm-menu/Makefile: Fixed. 2010-03-21 Araki Ken * README: updated. 2010-03-20 Seiichi SATO * ml_pty.c: add missing #include * scim: drop support for scim-1.2 2010-03-17 Araki Ken * xwindow/Makefile.in, tool/mlconfig/Makefile.in, x_sb_view_factory.c, mc_sb_view.c: DATADIR macro is renamed to XDATADIR to avoid conflicting with DATADIR structure in w32api/objidl.h. * "static_backscroll_mode" option is added to configuration protocol. ('set' only) * "open_screen" configuration protocol or Ctrl+F1 opens a new screen in the display which the screen where it is executed belongs to. * scrolled_out_lines_finished event is added to ml_edit_scroll_event_listener_t. If ml_screen_set_modified_all() is called in receive_scrolled_out_line event in which ml_model_t is not scrolled yet, redrawing screen can fail. * --maxptys option which specifies maximum number of ptys to open simultaneously is added. * 'mlclient ' and 'mlclientx ' are supported in configuration protocol. (see doc/en/PROTOCOL.) * x_screen instead of x_display and x_window manages an icon picture. * x_picture.[ch]: x_icon_picture_t and related functions are added. * etc/main.ja: Updated. * doc/en/README.win32, doc/ja/README.win32: Updated. * doc/term/mlterm.ti: colors#8 => colors#256 * doc/term/mlterm.tc: Co#8 => Co#256 * x_main_config.c: -I/--icon option is removed in win32. 2010-02-28 Araki Ken * x_term_manager.c: -pw option of plink is specified only with SSH in open_pty_intern(). * x_term_manager.c: 'init_str' is output after open_pty_intern() in open_screen_intern(). * tool/accessories/Makefile, README.ja, google.sh: Fixed. tool/accessories/viewsfml.sh: Removed. * */Makefile.in: Remove @X_PRE_LIBS@ because mlterm doesn't depend on them. * mkf/libtbl/table/mkf_ucs_property.table, mkf_ucs4_unified_hangul_to_uhc.table: Removed. (2009/12/30 commit failure.) * doc/en/README.win32, doc/ja/README.win32: Fixed. 2010-02-26 Araki Ken * tool/mlconfig/main.c, contrib/tool/mlterm-menu/mlterm-menu.c: kik_set_sys_conf_dir(".") in win32 without cygwin or msys. * winrs.rs: ',' is added after label text. (Fixed syntax error). * configure.in: If CC="cc -mno-cygwin" in cygwin, $(OBJ) contains x_connect_dialog.o. * tool/mlmenu/main.c: Fixed. * tool/mlmenu/menu-simple: Added for mlmenu. * x_sb_screen.c: button_pressed event is dispatched to x_screen.c in win32 because WM_MOUSEWHEEL message is sent to root window. * x_win32.h: Use VK_SHIFT, VK_CONTROL and VK_MENU for XK_Shift_L, XK_Control_L and XK_Alt_L instead of VK_LSHIFT, VK_LCONTROL and VK_LMENU. * mkf/script/config.guess, kiklib/script/config.guess, script/config.guess: updated (timestamp='2009-12-30') * mkf/script/config.sub, kiklib/script/config.sub, script/config.sub: updated (timestamp='2010-01-22') * doc/en/README.win32,doc/ja/README.win32,README.ja,mlterm.1,README.server: Updated. * PROTOCOL.color, README.fontproto: Fixed. * contrib/tool/mlcc/main.c: Help messages are shown by -h or --help option. 2010-02-23 Araki Ken * x_dnd_win32.c: Added for supporting simple drag and drop in win32. * x_dnd.c: "src[len-1] = '\0'" in parse_mlterm_config() is removed and strchr() is used instead of while() loop in parse_text_uri_list() because XGetWindowProperty() always allocates one extra byte in prop_return and sets it to zero. (Thanks to Kouichi Kusanagi san) * x_window_win32.c: WM_MOUSEHWEEL message is processed. (Not tested yet.) * mkf_utf16_parser.c: Fixed typo. (Renamed utf16_parser_init() to utf16le_parser_init() in mkf_utf16le_parser_new().) 2010-02-20 Araki Ken * scrollbar/*/Makefile.in, inputmethod/*/Makefile.in: Target library names are renamed to 'lib[name].la'. * x_term_manager.c,mlclient/main.c: Merged id:1574764 patch(fixed a little). Unix domain socket file is changed from /tmp/.mlterm-[UID] to ~/.mlterm/socket. (Thanks to Christian Biere) * ml_config_proto.c: "~/.mlterm" directory is created before ml_gen_proto_challenge() in ml_config_proto_init(). * kik_conf_io.c: kik_fopen_with_mkdir() is used in kik_conf_write_open(). * kik_file.c: kik_fopen_with_mkdir() and kik_mkdir_for_file() are added. 2010-02-18 Araki Ken * x_dnd.c: Merged id:2879800 patch(fixed a little). (Thanks to Kouichi Kusanagi san) 2010-02-17 Araki Ken * tool/mlconfig/mc_font.c: my_gtk_font_selection_dialog_set_font_name() doesn't escape '-' in win32. * x_font.c, x_font_win32.c: A bug which can cause buffer overrun in parse_(xft_)font_name() is fixed. (e.g. If "Hoge L" is passed to old parse_(xft_)font_name() as font name, then if( strncasecmp( p(=="L") , "light" , K_MIN(1,5)) == 0) becomes true and "p += 5" (not "p += 1") is processed. * etc/font.win32: Added. * README.dev: Removed. 2010-02-14 Araki Ken * kik_file.c: If a file which doesn't end with '\n' is read, '\0' is appended to the end of file in kik_file_get_line(). Configuration files which don't end with '\n' is treated correctly by this. * mc_font.c: If "Variable column width" check box is toggled, font name entry is reset. * kik_map.h: kik_map_erase_simple() is added. * x_mod_meta_mode.c, x_sb_mode.c, x_bel_mode.c: Simplified. * x_scrollbar.c: x_window_update( ..., FGCOLOR_CHANGED|BGCOLOR_CHANGED) is called after sb->view->realized() in x_scrollbar_(un)set_transparent and x_scrollbar_change_view. * x_screen.c: If specified picture is loaded successfully, screen->pic_file_path retains in spite of failure of x_window_set_transparent() in set_wall_picture(). * x_window_win32.c: Sound and visual bell are supported. x_window_bell() is implemented. x_window_fill_all() is renamed to x_window_blank() and implemented. * doc/ja/README.fontproto: Added. * x_gc_new() in x_gc.c: Fixed a bug which makes background color forcibly black until color except white is spcified. * x_font_config.c: Fixed. "DEFAULT" key is avaiable. * x_color_config.c: Fixed. 2010-02-05 Araki Ken * x_font_config.c: Fixed vaafont and taafont file names("vaafont_file" => "vaafont", "taafont_file" => "taafont") and some bugs. * x_font_manager.c: If you set type_engine=xcore in anti-aliased, use_anti_alias automatically becomes false in order for type_engine option to be xcore. * mlcc/main.c: Font and color configuration protocol is supported in non-interactive mode. ex) mlcc font ISO8859_1 *--%d-*-iso8859-1 mlcc font ISO8859_1,12 * mlcc/main.c,w3mmlconfig/section/appearance: type_engine option is supported. 2010-01-30 Araki Ken * x_display.c: "#include " which causes compiling error in cygwin-xlib is removed. * setup-msys.bat, setup-cygwin.bat: Added. These batch files create mlterm.bat which starts mlterm.exe in MSYS or Cygwin. * x_sb_view_factory.c: Careless mistakes in dlsym_sb_engine_new_func which causes failure of loading pixmap_engine module. 2010-01-28 Araki Ken * winrs.rs,x_display_win32.c: mlterm-icon-win32.ico is loaded as icon of mlterm.exe. * contrib/icon/mlterm-icon-win32.ico: Added. * Bidi rendering using fribidi is supported in win32. * configure.in: 'pkg-config fribidi' instead of 'fribidi-config' is supported. 2010-01-25 Araki Ken * winrs.rs: Input characters of password entry is masked. * x_connect_dialog.c,winrs.rs,x_term_manager.c: Format of default_server(--serv) and server_list(--servlist) options is changed. (@)(:) => (@)(:)(:) * x_display.c: If BadValue error happens in XLoad(Query)Font function, mlterm doesn't stop(Thanks to Hirose Masaaki san). * ml_char_encoding.c: If -E/--km/encoding option is "AUTO" or not specified, encoding is set UTF8 regardless of kik_get_codeset() in mlterm built with MSYS-DTK or Cygwin. 2010-01-16 Araki Ken * version.h.in: 2.9.4 post XXX => 3.0.0 pre XXX * man/mlterm.1: Updated. * doc/en/README.win32: Added. * x_term_manager.c: Fixed a bug around SendMessage(WM_CLOSE) which causes mlterm (win32 GUI) to dump core in exiting if fade_ratio is less than 100. * x_font_win32.c: ':[percentage]' format of ~/.mlterm/font font name is validated. And width of each font is adjusted to that of US-ASCII font if at all possible. 2010-01-13 Araki Ken * x_window_win32.c: US_ASCII characters in utf8 encoding are shown as unicode. (They are converted to UTF16 in x_window_draw_{image_}string.) * button_motin in x_scrollbar.c: A bug in button_motion() which leaves garbage in scrollbar area if you grab and move scrollbar is fixed. * x_display_win32.c, x_window_win32.c, x_xic_win32.c, x_win32.h: Characters are received as UTF16 by WM_IME_CHAR message if UTF16_IME_CHAR macro (which is defined by default) is defined. * x_screen.c: Memory leak of font_name in get_font_config() is fixed. * x_font_win32.c: Double drawing method is used by default to draw bold characters. * parse_{xft_}font_name() in x_font{_win32}.c: "Oblique", "Light", "Semi-bold", "Heavy" and "Semi-condensed" are acceptable in Xft and win32 font name. * mlconfig/mc_font.c: If font size is changed, new_fontname_list is reset. If font name of selected charset is empty and "select" button is pressed, default font name in font selection dialog is set by selected font size and charset. * x_font_manager.c: usascii_font_cs_table follows ml_char_encoding_t in ml_char_encoding.h. * README.sb: Updated. 2009-12-31 Araki Ken * xwindow/Makefile.in: 'winres' is renamed to 'winrs'. * output_separated() in ucs_mappings.pm: The way of outputting "static ${fromcs}_to_${tocs}_table_t ${fromcs}_to_${tocs}_tables[]" is fixed. According to this, some mkf/libtbl/table/mkf_*.table's are also fixed. 2009-12-30 Araki Ken * CP1250,CP1252,CP1253,CP1254,CP1256,CP1257,CP1259 related codes are added to mkf. (Binary compatibility is broken.) * 'daemon_mode = genuine' is rejected (only 'blend' is accepted) in win32. * mkf_utf16_{parser|conv}.c: Processing surrogate pair is fixed. * x_draw_str.c: convert_ucs4_to_utf16 which is used to convert ucs4 code to XChar2b(Xlib) or WCHAR(win32) is added. * ucs property table(mkf): Updated and data structure is changed. mkf/libtbl/mkf_ucs_property.c,table/mkf_ucs_*_property.table (which becomes libmkf_ucsprop.la) are removed and mkf/lib/table/mkf_ucs_property.table(statically linked to libmkf.la) is added. * mkf/libtbl/table/mkf_*.table: Shrunk. * mkf/table: Scripts which generates mkf tables are added. 2009-12-11 Araki Kena * mkf_tblfunc_loader.h: 'kik_dl_open( "" , libname)' is added to mkf_map_func2 and mkf_prop_func. * mkf/mkf_utf16_conv.c: use_bom member is added to mkf_utf16_conv_t and use_bom is false by default. * x_window_win32.c: text_out function which outputs text by TextOutW or TextOutA appropriately is added. UCS2 text encoded by UTF8 is supported. * ml_term_manager.c: ml_destroy_term() which is used when ml_term_open_pty() fails is added. * ml_pty_pipewin32.c: Error handling codes are added in pty_open(). * /dev/windows is used for waiting for windows messages in msys and cygwin(win32 native GUI). Fixed the problem that mlterm sometimes hung up in GetMessage() when child process exited. * mlterm server and mlclient seems to work in msys and cygwin(win32 native GUI). * Dialog box to input server, protocol, user name and password is introduced to mlterm built in MinGW. o 'default_server'(--serv) and 'server_list'(--servlist) options which are shown by default in dialog box are introduced. o x_connect_dialog.[ch],winrs.rs: added. * Configuration protocol(get) 'gui' which mlconfig uses to determine if mlterm is built with xlib or win32 is added. * kik_str.[ch]: kik_count_char_in_str() is added. 2009-11-21 Araki Ken * kik_conf_io.c: Search %HOME% directory if %HOMEPATH% directory does not exist in win32. * tool/mlconfig and contrib/tool/mlterm-menu: Possible to be built with win32 native gtk+-2.0. * ml_config_menu.c: Added win32API implementation(which is used when mlterm is bulit without cygwin.dll and msys.dll.). * For the first time, a folder in which mlterm is installed is searched for configuration files and menu progurams in win32. * x_font_win32.c: Format of font file is changed as follows(() is omittable). [Family] => [Family]( [Weight] [Slant] [Size]:[Percentage]) * x_window.c: Set is_focus 0 by default in order to call XSetICFocus(x_xic_set_focus) in startup FocusIn event. (If XSetICFocus() is not called, KeyPress event is discarded in XFilterEvent.) * Added: win32/mlterm-xcygwin.bat 2009-11-07 Araki Ken * x_display.[ch]: Added x_display_get_cursor(). * scrollbar plugin libraries: Removed XDefineCursor and XCreateFontCursor, which are called with shape according to scrollbar name in x_scrollbar.c. * kik_locale.c: sys_locale is strdup'ed. * x_xic_get_{utf8_}string(x_xic.c): If XBufferOverflow happens, overflowed input string is ignored. This is temporary expedient. * ml_pty_delete(ml_pty_pipewin32.c): Moved TerminateProcess() before CloseHandle(). * ml_vt100_parser.c: If parsing protocol sequence failed, "#error" is returned to pty in config_protocol_get() and config_protocol_get_font(). If challenge_it() in ml_config_protocol.c failed, "#forbidden" is returned to pty in config_protocol_get_font(). * x_term_manager.c: Process is terminated if all mlterm screens are closed in win32. 2009-11-03 Araki Ken * x_color_manager.c: Merged id:2879623 patch(Thanks to Kouichi Kusanagi). * x_xic_{fg|bg}_color_changed(x_xic.c): Added ->pixel after win->xim_listener->get_{fg|bg}_color. * Added 'get' method to font configuration protocol(doc/en/PROTOCOL.font). Changed font and color configuration protocol numbers(not compatible with cvs-2009/10/20 or before.). * mc_font.c: Added font selection dialog. * Renamed mc_fontsize.[ch] to mc_font.[ch]. * "type_engine" configuration is changeable in run time. (Added to configuration protocol(doc/en/PROTOCOL).) * x_color_manager.c/x_color_cache.c: Color fading was broken. Fixed. * Font format of aafont is changed as follows(() is omittable). [Family]-[Encoding](:[Percentage]) => [Family]( [Weight] [Slant] [Size]-[Encoding]:[Percentage]) * ml_parse_proto2(ml_config_proto.c): Fixed process of parsing 'key' and added do_challenge flag. 2009-10-20 Araki Ken * ml_vt100_parser.c: Recognize "ESC [ > ..." sequence. * x_window_win32.c: Added check_scrollable() function to check if window is visible or not when window focus, position or size is changed. And related to this change, is_focused member is added to x_window_t and remove from x_screen_t. * doc/ja/README.ja: Added explanation of -*/--type/type_engine option at this late date... * x_imagelib_gdk.c,x_imagelib_imlib2.c: Renamed win->display and win->screen to win->disp->display and win->disp->screen. * configure.in: Fixed bugs related to imlib2. * mkf/lib/Makefile.in: Added "-DLIBDIR=\"$(LIBDIR)\" to CFLAGS. * x_term_manager.c: mlterm server related codes are excluded if USE_WIN32GUI is defined. * win32/mlterm-msys_cygwin.bat: Added. * x_display_win32.c: Added hide_console(). * configure.in,xwindow/Makefile.in: Added -Wl,--subsystem,console option to CFLAGS for MSYS-DTK and cygwin. * kik_pty_streams.c: Added close(0..2) between fork() and setsid() for MSYS-DTK. * Added -X/--alpha option(effective in win32). * x_window_win32.c: Implemented x_window_{un}set_transparent() (which just uses SetLayeredWindowAttributes()). * ml_vt100_parser.c: Added kik_file_set_closexec(vt100_parser->log_file). * read_challenge() in ml_config_proto.c: Added fclose( file). * x_window_fill{_with}(x_window_win32.c): Added win->margin to x and y position. * kiklib/configure.in: kik_dlfcn_win32.c is always used in cygwin regardless of libtool decision. * kiklib/kik_locale.c: Added kik_get_codeset_win32() which is used in USE_WIN32GUI. 2009-09-10 Araki Ken * x_gdiobj_pool.[ch]: Added. * scrollbar/sample/x_sample_sb_view{_lib}_win32.c: Added. ('sample' scrollbar in win32.) * x_window{_win32}.[ch]: Added x_window_get_{fg|bg}_gc() which is used in x_scrollbar.c. * x_sb_view_factory.c: Added hack for source and binary backward compatibility of x_sb_view_t. * x_{transparent_}{simple|sample}_sb_view.c: Adujsted to new x_sb_view_t. * x_sb_view: Changed members of x_sb_view_t structure for win32. 2009-08-13 KATO Kazuyoshi * scrollbar/sample/Makefile.in: Added @KIK_CFLAGS@. (Thanks to AIDA Shinra) * contrib/scrollbar/*/Makefile.in: Added @KIK_CFLAGS@. (Thanks to AIDA Shinra) * xwindow/x_imagelib_none.c (x_imagelib_get_transparent_background): Follow the changes of x_window_t. (Thanks to AIDA Shinra) 2009-08-06 Araki Ken * Added imlib2 support(experimental). (Thanks to Frederic Heulin). * x_window.c(x_window_receive_event,MotionNotify): Check if button is pressed before win->button_motion is called. (Thanks to shirai hideyuki) 2009-07-29 Araki Ken * Added: win32/mlterm-win32.bat. * README, README.win32: Modified. * kiklib/src/kik_conf_io.c: kik_get_sys_rc_path() returns SYSCONFDIR\mlterm and kik_get_user_rc_path() returns %HOMEPATH%\mlterm in win32. * kiklib/src/kik_util.c: Added kik_getuid() and kik_getgid(). * x_window_win32.c: win->is_scrollable is 0 in WM_KILLFOCUS and 1 in WM_SETFOCUS. 2009-07-26 Araki Ken * x_display_win32.c: Implemented x_get_opened_displays(). (Could be core dumped in time_proc(x_term_manager.c) without this modification.) 2009-07-26 Araki Ken * IME Window pursues cursor position. * Added: doc/ja/README.win32. * Supported multiple pty, startup options and configuration by 'main' file in win32. x_term_manager.[ch], main.[ch] and x_main_config.[ch] are built in win32. x_window_manager*.[ch] are removed and united to x_display*.[ch]. Removed: main_win32.c Added: x_display_win32.c * Ucs property table is separated from libmkf as a shared library. Added: mkf/libtbl/mkf_ucs_property.c and libmkf_ucsprop.la. Moved: mkf/lib/table/mkf_ucs_*_property.table to mkf/libtbl/table/ Renamed: mkf/lib/mkf_map_loader.h to mkf_tblfunc_loader.h * kik_debug.h: Use __FILE__:__LINE__ instead of __FUNCTION__. 2009-07-17 Araki Ken * libtool: version up to 1.5.26 autoconf: version up to 2.63 (for win32 compilation.) * Separated mkf table from mkf as dynamic shared library(LIBDIR/mkf/libmkf_*.so). (Added configure option --enable(disable)-dl-table) * Added scrollbar support in win32. (Added x_simple_sb_view_win32.c) * x_window_win32.c: Apply min_{width|height} and {width|height}_inc when window resized. * *_color_*.[ch]: u_short changed to u_int8_t. * etc/mlterm/color: Supported rgb:RR/GG/BB format as value. * mlterm/ml_color.[ch]: Added ml_color_parse_rgb_name() function. 2009-07-11 Seiichi SATO * get rid of compiler warnings. 2009-07-11 Seiichi SATO * mkf/script/config.guess, kiklib/script/config.guess, script/config.guess: updated (timestamp='2009-04-27') * mkf/script/config.sub, kiklib/script/config.sub, script/config.sub: updated (timestamp='2009-04-17') 2009-07-11 Seiichi SATO * x_sb_screen.c, x_dnd.c: s/utf8_selection_notified/utf_selection_notified/ (see x_window.h rev 1.42) 2009-06-30 Araki Ken * Supported "ESC ] 4 ; ... ; rgb:%02x/%02x/%02x BEL" sequence. * Added 5384-5387 protocol(see doc/en/PROTOCOL.font and PROTOCOL.color). * configure: Added --with-gui option. * xwindow/*.[ch]: USE_WIN32API => USE_WIN32GUI * ml_pty_win32.c: Renamed to ml_pty_pipewin32.c. 2009-06-16 Araki Ken * mkf_utf16_conv.[ch]: Added mkf_utf16le_conv_new() * Support 256 color sequence(ESC[38;...m,ESC[48;...m). (Thanks to shinichiro.h). * x_gc.[ch]: added(for sharing GC with all x_window except scrollbar and xim). * x_color_cache.[ch]: added. 2009-06-04 Araki Ken * win32: Supported mouse and clipboard. * README.ja: Fixed explanation of default value of use_multi_column_char option. 2009-05-31 Araki Ken * Fixed many bugs. 2009-05-28 Araki Ken * win32/Makefile.in,main.c: deleted. * ml_pty_unix.c: renamed to ml_pty.c * ml_pty_win32pipe.c: renamed to ml_pty_win32.c * x.h x_win32.h main_win32.c,x_color_win32.c,x_font_win32.c, x_imagelib_win32.c,x_window_manager_win32.c,x_window_win32.c, x_xic_win32.c: added 2009-03-24 Araki Ken * Incomplete win32 support added. * win32/: added. * ml_pty_win32.c: renamed to ml_pty_win32pipe.c ml_pty.c: renamed to ml_pty_unix.c 2008-11-26 MINAMI Hirokazu , Seiichi SATO * inputmethod/uim/im_uim.h, xwindow/x_im_candidate_screen.[ch]: honor heading labels. 2008-11-22 Jun Inoue * inputmethod/uim/im_uim.c: fix dangling pointer dereference that can cause initialization to fail. 2008-10-21 Seiichi SATO * inputmethod/iiimf/Makefile.in, configure.in: To detect libiiimcf, use pkg-config if available. 2008-08-17 Seiichi SATO * mkf/script/config.guess, kiklib/script/config.guess, script/config.guess: updated (timestamp='2008-01-23') * mkf/script/config.sub, kiklib/script/config.sub, script/config.sub: updated (timestamp='2008-01-16') * contrib/tool/mlterm-menu/mlterm-menu.c: apply the patch from FreeBSD ports x11/mlterm. (files/patch-contrib_tool_mlterm-memu_mlterm-menu.c) 2008-08-02 MINAMI Hirokazu * kiklib/configure.in: added GNU libc detection. * kik_src/kik_pty_sterams.c: - no longer define _XOPEN_SOURCE to avoid problems on misc. platforms. - define _GNU_SOURCE iff compiled with glibc to get ptsname() prototype (its mandantory on LP64). - #define for _BSD_SOURCE/__EXTENSIONS__ should be no longer needed. (SF Bug#1999220, thanks to Christian Biere). 2008-07-22 MINAMI Hirokazu * inputmethod/uim/im_uim.c: tweaked initialization order to make automatic engine detection work again. uim_get_default_im_name() seems to return a non-GC-protected string which do not survive uim_create_context(). though it seems like a uim's bug, calling uim_get_default_im_name() iff uim_create_context() should be efficient anyway. 2008-05-28 MINAMI Hirokazu * inputmethod/uim/im_uim.c: add stdio.h to includes for BUFSIZ. 2008-04-26 MINAMI Hirokazu * mlterm/ml_edit.c: should not loop forever when window was too narrow. 2008-03-13 MINAMI Hirokazu * mlterm/ml_vt100_parser.c: fixed infinite loop. when a sequence-like input was actually so looooong, mlterm should assume it was just not properly terminated (Thanks to shinichiro.h). 2007-12-26 MINAMI Hirokazu * code cleanup using Sparse. - use NULL properly insted of (int)0. - added/fixed typos for #include. 2007-12-20 MINAMI Hirokazu * mlterm/ml_term.c: plugged a memory leak. 2007-12-11 KATO Kazuyoshi * kiklib/src/kik_pty_streams.c: don't define _XOPEN_SOURCE on Mac OS X. * kiklib/src/kik_pty_streams.c (kik_pty_fork): MacOS X >= 10.4 has posix_openpt() but needs ioctl(TIOCSTTY) instead of open(slavetty) to acquire a controlling tty. (thanks to AIDA Shinra for sending a patch) 2007-11-30 Seiichi SATO * xwindow/version.h.in: 2.9.4 -> 2.9.4 post 2007-11-30 Seiichi SATO * 2.9.4 released. (tag "rel-2_9_4") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 2.9.4 * configure: re-generated 2007-11-30 Seiichi SATO * mkf/script/config.guess, kiklib/script/config.guess, script/config.guess: updated (timestamp='2007-07-22') * mkf/script/config.sub, kiklib/script/config.sub, script/config.sub: updated (timestamp='2007-06-28') 2007-11-22 MINAMI Hirokazu * xwindow/x_screen.c: yank(paste) of a selection is now done when Button-2 was released, not pressed. 2007-11-12 Mike FABIAN * inputmethod/scim/im_scim_1.4.cpp: add "#include " to fix the build with gcc 4.3. 2007-09-28 MINAMI Hirokazu * mlterm/x_screen.c: added config key string "title" to allow change pty title by "mlcc title foobar". 2007-04-27 MINAMI Hirokazu * mlterm/ml_term.h: updated for ml_vt100_parser_set_logging_vt_seq. * xwindow/x_dnd.h: handle zero-length property properly. 2007-04-13 MINAMI Hirokazu * xwindow/x_screen.c: selection can be expanded on right-click. (Thanks to ssakane) 2007-01-24 Mike FABIAN * kiklib/src/kik_time.c: add missing day of week to avoid that the array subscript gets above the array bounds. Fix by Dominique Leuenberger . 2006-11-20 Seiichi SATO * xwindow/x_window.c, xwindow/x_window.h xwindow/x_screen.c: specify 32-bit format in the call to XChangeProperty, when the data is Atom. (thanks to Kusanagi Kouichi for sending a patch) * xwindow/x_term_manager.c (x_term_manager_add_fd): set close-on-exec flag to file descriptor of input method helpers. * xwindow/version.h.in: 2.9.3 post -> 2.9.4 pre 2006-11-02 MINAMI Hirokazu * kiklib/src/kik_sysv.c: #include missing kik_privilege.h. 2006-11-01 Seiichi SATO * kiklib/src/kik_utmp_sysv.c: fixed compilation error on biarch systems. (Debian Bug#396532, thanks to Kenshi Muto for sending a patch) 2006-10-24 MINAMI Hirokazu * mlterm/ml_screen.[ch]: API addition(ml_screen_is_alternate_edit()). * mlterm/ml_vt100_parser.[ch]: states of a screen can now be save/restored separately for normal/alternate screens. (SF Bug#1472143) * xwindow/x_xim.c: always setting close-on-exec flag should be harmless. 2006-10-20 Seiichi SATO * kiklib/configure.in: swapped the order of setutent() and logout(). (Debian BUG #329194, thanks to David Kolovratnik) * kiklib/configure: regenerated. 2006-10-19 MINAMI Hirokazu * xwindow/x_term_manager.c, mlterm/ml_conf_menu.c, kiklib/src/kik_pty_stream.c, kiklib/src/kik_pty_bsd.c xwindow/x_display.c, xwindow/x_xim.c: plugged file descriptor leaks. * kiklib/src/kik_file.[ch]: added new functions to add/remove close-on-exec flag on a file descriptor. (SF Patch #1576044, thanks to Christian Biere) * kiklib/src/Makefile.am: increased library version to reflect API addition. 2006-10-14 MINAMI Hirokazu * xwindow/x_shortcut.c: fixed typo. (SF Bug#1568596, thanks to nakada-san) * kiklib/src/kik_util.h: DIGIT_STR_LEN() macro should be safe for signed types. (SF Patch#1574241, thanks to Christian Biere) 2006-09-30 Seiichi SATO * xwindow/x_term_manager.c: applied a patch from Nakada-san. (#1534313) 2006-08-13 Seiichi SATO * tool/mlconfig/po/ar.po: Arabic translation contributed by Khaled Hosny. * tool/mlconfig/po/LINGUAS: added 'ar'. 2006-05-07 Seiichi SATO * xwindow/version.h.in: 2.9.3 -> 2.9.3 post 2006-05-07 Seiichi SATO * 2.9.3 released. (tag "rel-2_9_3") * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated for 2.9.3 * configure: re-generated * doc/en/PLATFORMS: updated 2006-04-18 Seiichi SATO * tool/mlconfig/po/vi.po: Vietnamese translation contributed by Pham Thanh Long. * tool/mlconfig/po/LINGUAS: added 'vi'. 2006-04-09 Seiichi SATO * xwindow/x_screen.c (compare_key_state_with_modmap): allowed NULL as arguments such as is_shift and is_meta. * xwindow/x_screen.c (key_pressed): changed to be more compatible with xterm. (e.g., Shift + F5: ESC [ 15 ; 2 ~) (Thanks to Konosuke Watanabe) * doc/term/mlterm.ti: added kf13-63. * xwindow/x_screen.c (im_changed), xwindow/x_im.h (im_changed): u_char -> char * xwindow/x_screen.c (key_pressed): allowed 'OSI ' format as escape sequence. * configure, kiklib/configure, mkf/configure: regenerated. 2006-04-06 Seiichi SATO * configure.in, kiklib/configure.in, mkf/configure.in: fixed a few of compilation errors with /usr/ccs/bin/ld of Solaris 9. - AC_CANONICAL_TARGET -> AC_CANONICAL_BUILD. - HAVE_POSIX_OPENPT should not be defined, when posix_openpt() is not available. * doc/en/PLATFORMS: updated 2006-04-05 Seiichi SATO * mkf/lib/mkf_iso2022_parser.c (parse_escape): fixed typo. * aclocal.m4 (PKG_CHECK_MODULES): added AC_MSG_RESULT(no). * mkf/script/config.guess, kiklib/script/config.guess, script/config.guess: updated (timestamp='2005-08-03') * mkf/script/config.sub, kiklib/script/config.sub, script/config.sub: updated (timestamp='2005-07-08') * configure.in, inputmethod/uim/im_uim.c: removed support for old uim. * configure.in: AC_CONFIG_SUBDIRS(kiklib, mkf) -> AC_CONFIG_SUBDIRS([kiklib mkf]) 2006-03-21 Seiichi SATO * mlterm/ml_edit.c (ml_edit_set_scroll_region): changed to be more compatible with xterm. (ESC [ Ps ; Ps r) (Thanks to SHIOTA Shoichi and Takashi SHIRAI) * mlterm/ml_vt100_parser.c (parse_vt100_escape_sequence): removed checks for ps[0] and ps[1] for ml_screen_set_scroll_region(). 2006-03-15 MINAMI Hirokazu * kiklib/configure.in: POSIX_OPENPT should be checked unconditionally. * configure.in: use literals for AC_CONFIG_SUBDIRS() to make ./configure --help=recursive work with autoconf 2.5x. 2006-03-14 MINAMI Hirokazu * xwindow/x_screen.c: set PATH_MAX if it's not already defined in limits.h. * xwindow/x_color.c: added fall-backs for "black"/"white" i.e. don't die even if rgb.txt was missing. 2006-03-12 MINAMI Hirokazu * configure.in: try to trick pkg-config in the right manner. * man/mlclient.1: documented --kill option. 2006-03-10 MINAMI Hirokazu * configure.in: allow pkg-config to be a wrapper script for happy cross-compiling. * tool/cross/cross-pkg-config: (NEW) a sample wrapper to make pkg-config search only under /usr/$PKG_CONFIG_CROSS_TARGET/lib/pkgconfig , where recent dpkg-cross places converted config files (*.pc). 2006-03-01 Seiichi SATO * xwindow/x_font.c (set_xft_font): added workaround for Debian Bug #350590. # The latest fontconfig (>= 2.3.0?) has 'Synthetic emboldening'. 2006-02-06 MINAMI Hirokazu * xwindow/x_window.c: Don't trust the value of 'property' from a selection requester. Some outdated client may fill 'None' to it. 2006-01-08 KATO Kazuyoshi * doc/en/PROTOCOL: added "logging_vt_seq" to configuration protocol. * xwindow/x_screen.c (set_config), xwindow/x_screen.c (get_config): added logging_vt_seq. * mlterm/ml_term.c (ml_term_set_logging_vt_seq), xwindow/x_term_manager.c (create_term_intern): use ml_term_set_logging_vt_seq instead of ml_term_enable_logging_vt_seq. * mlterm/ml_vt100_parser.h, mlterm/ml_vt100_parser.c (ml_vt100_parser_set_logging_vt_seq): use ml_vt100_parser_set_logging_vt_seq instead of ml_vt100_parser_enable_logging_vt_seq. * mlterm/ml_vt100_parser.c (receive_bytes): changed to be more compatible with xterm. 2005-11-12 Seiichi SATO * xwindow/version.h.in: 2.9.2 post -> 2.9.3 pre 2005-11-21 MINAMI Hirokazu * kiklib/src/kik_pty_streams.c: fixed typo. 2005-11-12 Seiichi SATO * inputmethod/scim/im_scim_1.4.cpp: allowed to switch property. 2005-11-11 MINAMI Hirokazu * kiklib/configure.in, kiklib/src/kik_pty_streams.c: use posix_openpt() instead of open(/dev/ptmx", ...) whenever possible. # according to IEEE Std 1003.1-2001, the name of a device to clone master pseudo-terminals can be other than /dev/ptmx. * kiklib/configure: regenerated. 2005-11-10 Seiichi SATO * inputmethod/scim/im_scim_1.4.cpp: new file * inputmethod/scim/im_scim_1.0.cpp: removed 2005-11-01 MINAMI Hirokazu * xwindow/x_font_config.c: added sanity checks for fontname templates. 2005-10-31 MINAMI Hirokazu * mkf/lib/mlf_locale_to_ucs4.c: minor code cleanup. - K_MIN is no longer used here. - sorted candidates alphabetically. 2005-10-30 MINAMI Hirokazu * doc/term/mlterm.t[ic]: - dropped unused entries from acsc. - made sgr0 to be xterm compatible. 2005-10-19 MINAMI Hirokazu * xwindow/x_window.c: do not try to align full-width chars to a half-width char when variable column width is enabled (Thanks to "Oibane" for reporting and helping to fix this). * xwindow/x_dnd.c: added sanity checks. * xwindow/x_screen.c: while pseudo-transparency or wallpaper is in use, draw cursor as using background (this looks better in most case IMHO). 2005-10-17 MINAMI Hirokazu * doc/term/mlterm.t[ci]: disable mouse position reporting in "reset" sequence for Debian BTS#55637. (stolen from ncurses-5.5/misc/terminfo.src) 2005-10-13 MINAMI Hirokazu * mlterm/ml_char.c: - Since LP64 glibc's malloc() is known to always return 16-byte aligned chunks, sanity check can be omitted. - changed nl_ch and sp_ch from file-local to function-local. 2005-10-05 Seiichi SATO * inputmethod/iiimf/aux.c: renamed to .. * inputmethod/iiimf/im_iiimf_aux.c: this. (see http://www.cygwin.com/faq/faq_toc.html#TOC58) 2005-09-29 MINAMI Hirokazu * mlterm/ml_vt100_parser.c: do not reset parser state in restore_cursor(). * xwindow/x_im.h: #include for sprintf. 2005-09-26 MINAMI Hirokazu * doc/term/mlterm.t[ic]: use xterm like sequences for rmcup/smcup since - length of termcap/terminfo entries can be a bit shorter. - we may implement titeInhibit someday. 2005-09-25 MINAMI Hirokazu * mlterm/ml_vt100_parser.c: now passes test #2 of the vttest on ja_JP.EUC-JP. 2005-09-23 MINAMI Hirokazu * mkf/lib/mkf_gb18030_2000_intern.c, mkf/lib/mkf_xct_parser.c: added casts to clarify signedness. 2005-09-23 Mike FABIAN * kiklib/src/kik_utmp_utmper.c, tool/mlclient/main.c: fix implicit function declarations (patch by MINAMI Hirokazu ). 2005-09-19 MINAMI Hirokazu * kiklib/src/kik_conf_io.c: added a debugging feature. The user configuration directory can be overridden using CONF_DIR. 2005-09-18 MINAMI Hirokazu * contrib/tool/mlcc/main.c: mlcc [parameter name] now generates a corresponding query sequence so that you can get a list of ptys by "mlcc pty_list". 2005-09-18 MINAMI Hirokazu * mlterm/ml_vt100_parser.c: try to restore a parser's GL when restore_cursor() was called. - only works on non-iso2022 locales at present. (I'm not yet sure how the parser's internal states should be save/restored on iso2022 locales.) - test#2 of the vttest should be passed on UTF-8 locales. (Thanks to Thomas Dickey for suggestions) * mlterm/ml_vt100_parser.c: declare digits[] as char[] since atoi() expects maybe-(un)signed-char and not u_char. (We should add some more casts to make gcc4 happy, though.) 2005-09-09 MINAMI Hirokazu * mlterm/ml=vt100_parser.c: // -> /**/ 2005-09-03 Seiichi SATO * tool/mlconfig/po/de.po: applied a patch from Jens Seidel. (Debian BTS #313970) 2005-09-04 Seiichi SATO * kiklib/configure.in: applied a patch from Mike FABIAN. (SUSE Bug #105320) 2005-09-04 Seiichi SATO * kiklib/configure.in: suppress libxpg4 check, if setlocale() is available in libc. (Thanks to SHIOTA Shoichi and MANTANI Nobutaka) 2005-09-04 Seiichi SATO * doc/ja/README.ja: fixed typo. (Thanks to SHIOTA Shoichi) 2005-09-01 Seiichi SATO * contrib/scrollbar/pixmap_engine/HOWTO.html: fixed typo. 2005-08-31 Seiichi SATO * kiklib/configure.in: fixed a bug that kiklib didn't link libutmpter even if available. (SUSE Bug #105320) 2005-05-23 MINAMI Hirokazu * xwindow/x_scrollbar.c: applied a patch from Takeshi Hakamata. (SF Bug #1206515) 2005-03-31 Seiichi SATO * inputmethod/iiimf/aux.c: applied a patch from Andreas Jochens. (Debian BTS #302231) 2005-03-18 Seiichi SATO * inputmethod/kbd/im_kbd.c: added Hebrew key mapping table. * README, doc/ja/README.ja, man/mlterm.1: updated. 2005-03-14 Seiichi SATO * mlterm/ml_screen.c (receive_scrolled_out_line): if backscrolling mode is BTS_NONE, do nothing to make the scroll caching mechanism in x_screen.c to work correctly. (#1161050) 2005-03-13 Seiichi SATO * kiklib/src/Makefile.in, mkf/lib/Makefile.in, inputmethod/iiimf/Makefile.in, inputmethod/kbd/Makefile.in, inputmethod/m17nlib/Makefile.in, inputmethod/scim/Makefile.in, inputmethod/uim/Makefile.in, contrib/scrollbar/extra/Makefile.in, contrib/scrollbar/pixmap_engine/Makefile.in: fixed incorrect paths for -rpath of libtool. (#1161055) 2005-03-10 MINAMI Hirokazu * xwindow/x_imagelib_gdk.c: don't try to be translucent if root pixmap is not available. 2005-03-05 Seiichi SATO * xwindow/version.h.in: 2.9.2 -> 2.9.2 post 2005-03-05 Seiichi SATO * 2.9.2 released. (tag "rel-2_9_2") * xwindow/x_imagelib_gdk.c: fixed possible integer overflow. * configure, configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated. 2005-03-04 Seiichi SATO * doc/en/PLATFORM: updated. * README: updated. * man/mlterm.1: changed date. (->2005/02/18). 2005-03-03 Mike FABIAN * inputmethod/scim/im_scim_1.0.cpp, inputmethod/scim/im_scim_1.2.cpp, mlterm/ml_term.c: add "return 1 ;" to some functions to avoid compiler warning "Control reaches end of non-void function". 2005-03-02 Seiichi SATO * xwindow/x_window.h: added x_window_remove_icon(). * xwindow/x_screen.c (change_char_encoding): use change_im(). * inputmethod/uim/im_uim.c: - removed unnecessary #ifdef. (Thanks to Etsushi Kato) - code cleanup. * inputmethod/iiimf/im_iiimf.c: fixed a segfault when using Wnn8. * inputmethod/iiimf/keymap.c: added key mappings for auxiliary functions (XK_F*) and keypad (XK_KP_*). * tool/mlconfig/mc_im.c: minor code cleanup. 2005-03-01 Seiichi SATO * inputmethod/uim/im_uim.c: - applied a patch from Etsushi Kato. (for focus problem) - get rid of compiler warning. - allow to work with uim-0.3.8. * inputmethod/iiimf/im_iiimf.c, inputmethod/iiimf/im_iiimf.h, inputmethod/iiimf/aux.c, inputmethod/iiimf/keymap.c, inputmethod/m17nlib/im_m17nlib.c, inputmethod/scim/im_scim_mod_if.c, inputmethod/scim/im_scim_1.0.cpp, inputmethod/scim/im_scim_1.2.cpp: get rid of compiler warning. * kiklib/src/kik_dlfcn_dyld.c: fixed a segfault that occurred when the module was loaded multiply. (Thanks to Etsushi Kato for report) * contrib/scrollbar/extra/exsb_comon.c: - removed. - To avoid multiple definitions problem on Mac OS X, exsb_get_pixel() was moved to exsb_common.h as static function. * contrib/scrollbar/extra/Makefile.in: removed exsb_common.o * xwindow/x_im_candidate_screen.c (init_candidates): cleanup. 2005-02-28 Seiichi SATO * inputmethod/iiimf/im_iiimf.c: minor code cleanup. * inputmethod/iiimf/aux.c: minor code cleanup. * configure.in: IIIMF plugin cannot be used with --with-libltdl. * xwindow/x_term_manager.c (client_connected): - argv[argc + 1] = NULL ; ---> argv[argc] = NULL ; - "mlclient --foo=bar" does not work. fixed. 2005-02-26 MINAMI Hirokazu * mlterm/ml_screen.h: reverted the last change. (it should be done in 3.x) 2005-02-25 Seiichi SATO * inputmethod/iiimf/im_iimf.c: minor code cleanup. * inputmethod/iiimf/aux.c: minor code cleanup. * inputmethod/uim/im_uim.c: minor code cleanup. * inputmethod/uim/LICENCE: new file * inputmethod/m17nlib/LICENCE: new file * inputmethod/kbd/LICENCE: new file * configure.in: removed -DSCIM_1_2_0 * inputmethod/scim/im_scim_1.0.cpp: renamed from im_scim.cpp * inputmethod/scim/im_scim_1.2.cpp: new file * inputmethod/scim/Makefile.in: added im_scim_@SCIM_VERSION@.o * inputmethod/scim/im_scim_mod_if.c: code cleanup * inputmethod/scim/LICENCE: new file Note: In the next release, SCIM plugin will be distributed under LGPL. See inputmethod/scim/LICENCE for more detail. 2005-02-24 Seiichi SATO * inputmethod/m17nlib/im_m17nlib.c: minor code cleanup. * configure.in: - fixed typo. (scim=$enable_m17nlib) - added -DSCIM_1_2_0. (beginning of #ifdef hell) 2005-02-24 Seiichi SATO supported IIIMF X aux object. * inputmethod/iiimf/aux.c: new file (heavily based on iiimpAux.c of IIIMXCF) * inputmethod/iiimf/keymap.c: - renamed from im_iiimf_keymap.h. - fixed wrong mappings. ("%", "|", "~". "`", "?") * inputmethod/iiimf/LICENCE: new file * inputmethod/iiimf/keymap.h: new file * inputmethod/iiimf/im_iiimf.c: - code cleanup. - check for HTT_DISABLE_STATUS_WINDOW environment variable. - removed IM_IIIMF_ATOKX_HACK. Note: In the next release, IIIMF plugin will be distributed under MIT/X license. See inputmethod/iiimf/LICENCE for more detail. 2005-02-23 MINAMI Hirokazu * xwindow/x_screen.c: report meta while mouse tracking mode. * mlterm/ml_screen.h: modified definitions for back scroll mode. * mlterm/ml_vt100_parser.c: fixed typo. 2005-02-22 Seiichi SATO * xwindow/x_im.c (x_im_new): return NULL when input_method is "none". 2005-02-22 MINAMI Hirokazu * x_term_manager.c: mlterm daemon can be killed by "mlclient --kill". * tool/mlclient/main.c: _K/--maxpts options was removed long ago... * mlterm/ml_vt100_parser.c: try to mimic term's extended escape sequences(1047/1048/1049). 2005-02-21 MINAMI Hirokazu made a window icon to belong a pty not a window. * xwindow/x_screen.c: added change_icon() and set/reset an icon when a term is attache/detached. * xwindow/x_term_manager.c: handle term->icon_path. * xwindow/x_window_manager.c: added x_window_manager_set_icon. * xwindow/xwindow.c: added x_window_remove_icon() and x_window_set_icon_from_file. * doc/en/PROTOCOL: updated. 2005-02-19 Seiichi SATO * inputmethod/im_common.h (im_convert_encoding): initialized converter before conversion. 2005-02-18 Seiichi SATO * kiklib/src/kik_dlfcn_dl.c, kiklib/src/kik_dlfcn_dld.c, kiklib/src/kik_dlfcn_dyld.c, kiklib/src/kik_dlfcn_ltdl.c, kiklib/src/kik_dlfcn_win32.c: supported prefix-less library name such as foo.so, foo.sl and foo.dll. 2005-02-18 Mike FABIAN * inputmethod/scim/Makefile.in: add "CC = @CC@" * man/mlterm.1: fix typo. 2005-02-17 MINAMI Hirokazu * mlterm/ml_logs.c: use calloc to fail when integer overflow. * kiklib/src/kik_mem.c: detect integer overflow in calloc() while debugging. * mlterm/ml_term.[ch]: added a new member "icon_path" to ml_term_t for future expansion. 2005-02-15 Seiichi SATO * inputmethod/uim/im_uim.c, configure.in: uim_prop_update_custom() * xwindow/x_im_candidate_screen.c (draw_screen_vertical): 10 -> num_per_window 2005-02-10 Seiichi SATO * doc/term/mlterm.tc: revived. 2005-02-10 MINAMI Hirokazu * xwindow/x_term_manager.c, xwindow/x_window_manager.[ch]: mlclient now accepts --iconpath option and the value is used as a icon of the newly created window. * minor code cleanup. 2005-02-10 MINAMI Hirokazu * man/mlterm.1: updated many out-of-date descriptions. 2005-02-09 MINAMI Hirokazu * xwindow/x_main_config.c: now accepts --iconpath option. 2005-02-05 Seiichi SATO * doc/en/PLATFORM: updated. * configure.in: if scim is enabled, try to detect c++ compiler. if not, do nothing. * mkf_char.c, mkf_char.h (mkf_char_to_int) (mkf_int_to_bytes) (mkf_bytes_to_int) * mkf_parser.c mkf_parser.h (__mkf_parser_increment) (__mkf_parser_n_increment) (__mkf_parser_mark) (__mkf_parser_reset) * ml_char.c, ml_char.h (ml_char_init) (ml_char_final) (ml_char_set) (ml_char_combine) (ml_combine_chars) (ml_remove_combining_char) (ml_get_base_char) (ml_get_combining_chars) (ml_char_move) (ml_char_copy) (ml_char_bytes) (ml_char_size) (ml_char_set_bytes) (ml_char_cs) (ml_char_is_comb) (ml_char_font) (ml_char_cols) (ml_char_is_biwidth) (ml_char_fg_color) (ml_char_set_fg_color) (ml_char_bg_color) (ml_char_set_bg_color) (ml_char_is_underlined) (ml_char_reverse_color) (ml_char_restore_color) (ml_char_copy_color_reversed_flag) (ml_char_is_null) (ml_char_equal) (ml_char_bytes_is) (ml_char_bytes_equal) (ml_sp_ch) (ml_nl_ch) * ml_str.c, ml_str.h (ml_str_copy) (ml_str_cols) (ml_str_equal) (ml_str_bytes_equal): removed 'inline' from all global functions. (#1081111) 2005-02-04 MINAMI Hirokazu * xwindow/x_window.c: * use Mapnotify as a trigger of transparency processing. 2005-02-04 MINAMI Hirokazu * xwindow/x_screen.c: During mouse tracking, try to report sane location even if there was no character under clicked column. (This is not perfect when variable-width font is used, though) 2005-02-04 MINAMI Hirokazu * man/mlterm.1: added description for PREV/NEXT_PTY. (SF#1110868. Thanks to John Foerch) 2005-02-03 Seiichi SATO * mlterm/ml_edit.c (ml_edit_go_back), mlterm/ml_vt100_parser.c (parse_vt100_escape_sequence): fixed #1048321 (autowrap test of vttest-2.7). 2005-02-03 MINAMI Hirokazu * xwindow/x_screen.c: - changed to ignore un-reportable mouse click. - fixed a bug for sending button4/5 events. 2005-02-03 Seiichi SATO * man/mlterm.1: removed xim_open_in_startup. (#1115198) * etc/main.ja: - removed xim_open_in_startup. (#1115198) - added input_method 2005-02-02 MINAMI Hirokazu * xwindow/x_screen.c: For mouse tracking, report the maximum value, not random value, when the clicked position was out of protocol-supported range. 2005-01-31 Seiichi SATO * xwindow/version.h.in: 2.9.1 post -> 2.9.2 pre * configure.in: utmp is still experimental feature. 2005-01-28 Seiichi SATO * xwindow/x_im_candidate_screen.c (draw_screen_vertical): snprintf() -> kik_snprintf 2005-01-27 Seiichi SATO * contrib/scrollbar/pixmap_engine/HOWTO.html, contrib/scrollbar/pixmap_engine/HOWTO.images/fig*.png: new files. The following changes are made to fix compilation errors on mingw32. * kiklib/src/Makefile.in, mkf/lib/Makefile.in: -rpath $(PREFIX)/lib ---> -rpath $(LIBDIR) * mkf/configure.in: KIK_LIBS='-L${top_builddir}/kiklib/src -lkik' * configure.in: KIK_LIBS_FOR_MODULE='-L${top_builddir}/kiklib/src -lkik' MKF_LIBS_FOR_MODULE='-L${top_builddir}/mkf/lib -lmkf' * inputmethod/scim/im_scim_mod_if.c: fixed typo. 2005-01-26 Seiichi SATO * inputmethod/scim/im_scim.cpp, inputmethod/scim/im_scim_mod_if.c. inputmethod/scim/im_scim.h: - cleaned up error messages. - removed im_changed callback. - use replace_instance method for changing the factory. - removed find_factory(). * README, doc/ja/README.ja, man/mlterm.1, xwindow/x_main_config.c: updated. * inputmethod/kbd/im_kbd.c (mlterm_syms): renamed to syms. * inputmethod/scim/im_scim.cpp (send_help_description): implemented. * inputmethod/scim/im_scim_mod_if.c (im_scim_get_info): num_of_args = 0 * tool/mlconfig/mc_im.c: allow im_info.num_of_args is 0. 2005-01-25 Seiichi SATO * inputmethod/uim/im_uim.c (xksym_to_ukey): fixed typo. (candidate_shift_page): implemented. * inputmethod/scim/im_scim_mod_if.c (im_scim_get_info): fixed a segfault when scim daemon is not running. * xwindow/x_im.c (x_im_new): cleaned up error messages. * inputmethod/im_uim.c (im_uim_new): cleaned up error messages. * inputmethod/scim/im_scim.cpp (find_factory): saved selected factory to SCIM_GLOBAL_CONFIG_DEFAULT_IMENGINE_FACTORY 2005-01-24 Seiichi SATO * inputmethod/iiimf/im_iiimf.c (show_available_gui_objects): new function for debugging. * inputmethod/iiimf/im_iiimf.c, configure.in: added -DHAVE_HOTKEY_NOTFY_EVENT and -DHAVE_AUX_GETVALUES_EVENT * inputmethod/uim/im_uim.c * inputmethod/m17nlib/im_m17nlib.c * inputmethod/iiimf/im_iiimf.c (mlterm_syms): renamed to syms * inputmethod/scim/im_scim_mod_if.c (preedit_update): dropped candidates, when position of editing segment was changed, 2005-01-23 Seiichi SATO * inputmethod/scim/im_scim.cpp: minor bug fix. 2005-01-23 Seiichi SATO * inputmethod/scim/im_scim.cpp: implemented property. 2005-01-23 MINAMI Hirokazu * tool/mlconfig/mc_im.c: increased MAX_IM_INFO to make room for scim. 2005-01-23 Seiichi SATO * inputmethod/scim/im_scim.cpp (im_scim_create_context): moved be->signal_connect_*() into * inputmethod/scim/im_scim.cpp (im_scim_initialize): this. 2005-01-23 Seiichi SATO SCIM (Smart Common Input Method platform) support: * configure.in: - added '--enable-scim' - added AC_PROG_CXX * inputmethod/scim/im_scim.cpp: new file * inputmethod/scim/im_scim.h: new file * inputmethod/scim/im_scim_mod_if.c: new file * inputmethod/scim/Makefile.in: new file * inputmethod/uim/im_uim.c, xwindow/x_im.c, xwindow/x_im.h: minor code cleanup. 2005-01-23 MINAMI Hirokazu Made cursor looks better (thanks to Ian Ward). * mlterm/ml_vt100_parser.c: stopped to unify cursor color. * xwindow/x_screen.c, xwindow/x_color_manager.*: cursors are now drawn using the colors of characters under them. 2005-01-21 Seiichi SATO * inputmethod/uim/im_uim.c: minor code cleanup. 2005-01-16 Seiichi SATO * mlterm/ml_pty.c (ml_pty_new): In the forked pty process, reset the signal handler for SIGPIPE. (SIG_IGN -> SIG_DFL) * configure.in, tool/mlconfig/Makefile.in, contrib/tool/mlterm-zoom/Makefile.in: revived DL_SELF (-dlopen self). 2005-01-15 Seiichi SATO * xwindow/x_term_manager.c (x_term_manager_init): ignore SIGPIPE. * inputmethod/uim/im_uim.c: removed a handler for SIGPIPE. 2005-01-13 Seiichi SATO Allow to use static linked IM plugins with libltdl. (./configure --disable-shared --enable-static --with-libltdl) * configure.in, tool/mlconfig/Makefile.in, xwindow/Makefile.in, contrib/tool/mlterm-zoom/Makefile.in: - separated DL_LIBS to DL_LIBS_SB and DL_LIBS_IM. - when using libltdl, add "-dlopen /path/to/libim-foo.la" to libtool option. - removed DL_SELF (-dlopen self). * kiklib/src/kik_dlfcn_ltdl.c (kik_dl_is_module): added check for "la" suffix. * tool/mlconfig/mc_im.c: im_get_info --> im__get_info * xwindow/x_im.c: im_new --> im__new * inputmethod/kbd/im_kbd.c (im_new): renamed to im_kbd_new. (im_get_info): renamed to im_kbd_get_info. * inputmethod/uim/im_uim.c (im_new): renamed to im_uim_new. (im_get_info): renamed to im_uim_get_info. * inputmethod/iiimf/im_iiimf.c (im_new): renamed to im_iiimf_new. (im_get_info): renamed to im_iiimf_get_info. * inputmethod/m17nlib/im_m17nlib.c (im_new): renamed to im_m17nlib_new. (im_get_info): renamed to im_m17nlib_get_info. 2005-01-10 Seiichi SATO * doc/ja/README.ja: minor cleanup. 2005-01-01 MINAMI Hirokazu * xwindow/x_screen.c: BackSpace/Delete couldn't be used as a shortcut key. (Thanks to Yusuke Sakai) 2004-12-29 Seiichi SATO * configure.in: applied a patch from Ken'ichi Handa. 2004-12-22 MINAMI Hirokazu * configure.in: noted about --with-type-engines in the description of --enable-anti-alias to make upgrade easier (for lusers). 2004-12-21 MINAMI Hirokazu * kiklib/src/kik_mem.h: When HAVE_ALLOCA_H was defined, alloca.h should be always #include'ed even if __GNUC__ was defined. (alloca() may remain undefined otherwise). 2004-12-17 Seiichi SATO * doc/en/PROTOCOL: updated. (#1084176) 2004-12-09 MINAMI Hirokazu * minor code cleanup. 2004-12-09 MINAMI Hirokazu * mkf/lib/, kiklib/src/kik_debug.c: minor code cleanup. 2004-12-09 Seiichi SATO * xwindow/x_im_candidate_screen.c: fixed a syntax error inside #ifndef USE_IM_PLUGIN. (Thanks to SHIOTA Shoichi for sending a patch) 2004-12-06 MINAMI Hirokazu * xwindow/x_window_manager.c: pointer should be initialized by NULL. * xwindow/x_screen.c, xwindow/x_im_candidate_screen.c: minor code cleanup. * tools/mlconfig/*.c: use kiklib/*.h instead of standard headers for better memory usage tracking. 2004-12-03 Seiichi SATO * tool/w3mmlconfig/Makefile.in: /usr/bin/perl -> @PERL@ 2004-11-28 Seiichi SATO * xwindow/version.h.in: 2.9.1 -> 2.9.1 post 2004-11-28 Seiichi SATO * 2.9.1 released. (tag "rel-2_9_1) * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated. 2004-11-27 Seiichi SATO * doc/en/PLATFORM: updated. (Thanks to MURASE, Masaki) 2004-11-25 MINAMI Hirokazu * tool/mlconfig/mc_im.c: fixed typo. 2004-11-25 MINAMI Hirokazu * common/c_intl.h: removed "#define const " which seems to be useless. * tool/mlconfig/*.c: tried to be -Wall clean. 2004-11-25 Seiichi SATO * mlterm.spec: - fixed #1072304 - FHS compliance 2004-11-21 Seiichi SATO * doc/en/PLATFORM: updated supported platforms. 2004-11-21 Seiichi SATO * mlterm/ml_term_manager.c (sig_child): if(pid == -1) --> if(pid <= 0) 2004-11-21 Seiichi SATO * kiklib/configure.in, kiklib/src/kik_config.h.in: added check for stdint.h. * inputmethod/iiimf/im_iiimf.c: "#define HAVE_STDINT_H 1" -> #include 2004-11-21 Seiichi SATO Fixed #1069725. * kiklib/src/kik_conf.c (kik_conf_parse_args): check whether argc is 0. * xwindow/x_term_manager.c (client_connected): argv[argc] = NULL. (POSIX exec family style) * xwindow/x_screen.c, xwindow/x_im.c: screen->input_method=strdup("none"); -> screen->input_method=NULL; 2004-11-19 Seiichi SATO * mkf/lib/Makefile.in, inputmethod/kbd/Makefile.in, inputmethod/uim/Makefile.in, inputmethod/iiimf/Makefile.in, inputmethod/m17nlib/Makefile.in: Workaround for HP-UX's make. ;-( Makefile.in -- s/@FOO@/foo/g, s/@BAR@//g --> Makefile target: target: < TAB >@FOO@ \ < TAB >foo \ < TAB >@BAR@ < TAB > :-) Makefile.in -- s/@FOO@/foo/g, s/@BAR@//g --> Makefile target: target: < TAB >@FOO@ @BAR@ < TAB >foo * doc/en/PLATFORM: updated supported platforms. * configure, mkf/configure: synchronized with configure.in. 2004-11-18 Seiichi SATO * doc/en/PLATFORM: updated supported platforms. 2004-11-18 MINAMI Hirokazu * configure.in, mkf/configure.in: added AC_C_INLINE. * xwindow/x_window.c: added workaround for stupid application which sends Atom "NONE" instead of None. 2004-11-17 Seiichi SATO * doc/en/PLATFORM: updated supported platforms. 2004-11-17 Seiichi SATO * xwindow/version.h.in: 2.9.0 post -> 2.9.1 pre 2004-11-17 MINAMI Hirokazu * kiklib/src/kik_sig_child.c: changed the handler for SIGCHLD from SIG_IGN to SIG_DFL to be old POSIX compliant. 2004-11-16 Seiichi SATO * mlterm/ml_term_manager.c (sig_child): ignore SIGCHLD from non pty process. (pid == -1) * inputmethod/uim/im_uim.c (helper_read_handler): An empty message ("") from helper crased mlterm, fixed. (im_new): removed workaround for SIGCHLD problem with prime. (sig_pipe): New function to handle SIGPIPE from prime. 2004-11-15 Seiichi SATO * inputmethod/kbd/Makefile.in: @MKF_LIBS@ -> @MKF_LIBS_FOR_MODULE@ 2004-11-14 Seiichi SATO * tool/w3mmlconfig/Makefile: moved to... * tool/w3mmlconfig/Makefile.in: this for autoconfication. * configure.in, tool/w3mmlconfig/mlconfig.cgi.in, tool/w3mmlconfig/w3mmlconfig.in, tool/w3mmlconfig/Makefile.in: autoconfication 2004-11-14 Seiichi SATO * tool/w3mmlconfig/mlconfig.cgi.in: ~/.mlterm/challenge support. * tool/w3mmlconfig/section/encoding: "xim", "xim_locale" -> "input_method" 2004-11-12 Seiichi SATO * kiklib/src/kik_map.h: An expanded hash table was broken. Fixed. (#1061470) 2004-11-12 Seiichi SATO * xwindow/x_im.c, xwindow/x_im_candidate_screen.c, xwindow/x_im_candidate_screen.h, inputmethod/iiimf/im_iiimf.c, inputmethod/m17nlib/im_m17nlib.c, inputmethod/uim/im_uim.c: allowed to list candidates horizontally. * xwindow/x_im.h: increased IM_API_VERSION. 2004-11-07 Seiichi SATO * tool/mlconfig/mc_im.c: "None" -> _("None") 2004-11-04 Seiichi SATO * xwindow/x_im.c: don't increase ref_count_uim and ref_count_m17nlib if x_im_new() failed. * tool/mlconfig/mc_sb_view.c (has_rc_file): I forgot closing dir, fixed. 2004-11-04 Seiichi SATO * inputmethod/m17nlib/im_m17nlib.c: - - fixed a bug that the last preedit text was not cleared when deactivating the input method. (Thanks to Ken'ichi HANDA) - changed the format in the status window. - minor cleanups. * man/mlterm.1: added explanation for keyboard input method to 'GUI CONFIGURATOR'. 2004-10-29 Seiichi SATO * tool/mlconfig/Makefile.in: -lmkf (required from libim-iiimf.so) 2004-10-29 Seiichi SATO Removed -lkik and -lmkf from linker flag of modules. Note: Both libraries are linked if the platform does not support undefined symblos such as Cygwin and AIX. * configure.in: added MKF_LIBS_FOR_MODULE and KIK_LIBS_FOR_MODULE. * inputmethod/kbd/Makefile.in, inputmethod/iiimf/Makefile.in, inputmethod/uim/Makefile.in, inputmethod/m17nlib/Makefile.in: KIK_LIBS -> KIK_LIBS_FOR_MODULE, MKF_LIBS -> MKF_LIBS_FOR_MODULE * mkf/configure.in, mkf/lib/Makefile.in: KIK_LDFLAGS -> KIK_LIBS 2004-10-29 Seiichi SATO * doc/ja/README.ja: added description about kbd and m17nlib. * configure.in: discontinue if imlib-config is not available. 2004-10-28 Seiichi SATO * inputmethod/uim/im_uim.c: - don't send engine_name to helper. - removed engine_name from im_uim_t. - allow to debug using MOD_KEY_DEBUG environment variable. (e.g., MOD_KEY_DEBUG=1 mlterm --im=uim) 2004-10-27 Seiichi SATO * inputmethod/m17nlib/im_m17nlib.c (key_event): ingore invalid key event. Thanks to Kenichi Handa for report. 2004-10-27 Seiichi SATO * xwindow/x_screen.c, xwindow/x_im.c, xwindow/x_im.h, inputmethod/m17nlib/im_m17nlib.c, inputmethod/iiimf/im_iiimf.c, inputmethod/kbd/im_kbd.c: added parameter 'mod_ignore_mask' to x_im_new(). * inputmethod/uim/im_uim.c: clear pressing_mod_key in focused() and unfocused(). * xwindow/x_im.h: increased IM_API_VERSION. 2004-10-26 Seiichi SATO * inputmethod/m17nlib/im_m17nlib.c: - use EUC-JP instead of EUC-JISX0213 for the internal code convertion. - fixed a segfault with ISO-2022-JP[123]. - show error messages if code convertion failed. 2004-10-26 Seiichi SATO * inputmethod/iiimf/im_iiimf.c, inputmethod/m17nlib/im_m17nlib.c, tool/mlconfig/po/de.po, tool/mlconfig/po/mlconfig.pot, tool/mlconfig/po/zh_TW.po, xwindow/x_im.c: fixed typo (Cound -> Could). 2004-10-26 Seiichi SATO * inputmethod/uim/im_uim.c (key_event): for exact matching mechanism in uim_press_key(), if and only if the target modifier key is pressing modifier bit will be set. (Thanks to gabor for reporting) * doc/en/PLATFORM: updated supported platforms. 2004-10-24 Seiichi SATO * xwindow/version.h.in: 2.9.0 -> 2.9.0 post 2004-10-24 Seiichi SATO * 2.9.0 released. (tag "rel-2_9_0) * configure.in, mlterm.spec, xwindow/version.h.in, doc/en/ReleaseNote: updated. 2004-10-24 Seiichi SATO * xwindow/x_window.h (x_window_t): added following dummy members to keep the size of x_winodw_t. - void * xft_draw; (used if USE_TYPE_XFT is undefined) - void * dnd; (used if DISABLE_DND is defined) - void * set_xdnd_config; (used if DISABLE_DND is defined) * inputmethod/uim/Makefile.in: * inputmethod/iiimf/Makefile.in: * inputmethod/m17nlib/Makefile.in: * inputmethod/kbd/Makefile.in: removed AA_CFLAGS and DND_CFLAGS. 2004-10-23 Seiichi SATO * README: fixed typo. (for X -> on X) 2004-10-23 Seiichi SATO * man/mlclient.1: AUTHOR -> CONTACT 2004-10-23 Seiichi SATO * man/mlterm.1, man/mlclient.1: - fixed typo. (MLTERM -> MLCLIENT) - changed date. (->2004/10/23) 2004-10-23 Seiichi SATO * man/mlterm.1: fixed typo. (for X -> on X) 2004-10-23 Seiichi SATO * xwindow/x_term_manager.c (open_pty_intern): set COLORFGBG environment variable to "default;default" (hardcorded). 2004-10-23 Seiichi SATO * kiklib/src/kik_pty_streams.c: moved linux specific error message into #ifdef __linux__. 2004-10-23 Seiichi SATO * xwindow/version.h.in: 2.8.0 post -> 2.9.0 pre 2004-10-22 MINAMI Hirokazu * kiklib/src/kik_net.h: when neither PF_LOCAL nor PF_UNIX was defined, use AF_LOCAL (which may be an alias of AF_UNIX) instead. 2004-10-22 Seiichi SATO * inputmethod/uim/im_uim.c: - strlen() -> strlen() + 1 - fixed typo in comment. * inputmethod/iiimf/im_iiimf.c: strlen_utf16() -> strlen_utf16() + 1 * inputmethod/m17nlib/im_m17nlib.c: fixed typo in comment. * inputmethod/im_common.h: fixed a minor bug. 2004-10-21 Seiichi SATO * doc/en/PLATFORM: updated supported platforms. 2004-10-21 Seiichi SATO * kiklib/src/kik_net.h: defined PF_LOCAL as PF_UNIX on the system which doesn't have PF_LOCAL. 2004-10-21 Seiichi SATO * configure.in: removed "echo -n" for portability. * doc/ja/BUGS: updated. * README, doc/en/PLATFORM: updated supported platforms. * inputmethod/uim/im_uim.c (im_new): - added workaround for setlocale() in make_locale() of m17nlib. - save/restore a signal handler for SIGCHLD when prime is specifed. * inputmethod/m17nlib/im_m17nlib.c (im_new): added workaround for setlocale() in make_locale() of m17nlib. * tool/mlconfig/po/ja.po: updated. * man/mlterm.1: minor cleanup. 2004-10-20 Araki Ken * xwindow/x_shortcut.h: Removed XIM_OPEN XIM_CLOSE from x_key_func. (This bug has broken default shortcut keys.) 2004-10-20 MINAMI Hirokazu * xwindow/x_term_mmanager.c: fixed typo. 2004-10-18 Seiichi SATO * man/mlterm.1: conf_menu_path -> conf_menu_path_[123]. 2004-10-18 Seiichi SATO * README, doc/en/PLATFORM: updated supported platforms. 2004-10-18 Seiichi SATO * configure.in: could not find IIIMF's path (/usr/lib/im/) on Fedora Core 2, fixed. * doc/en/PLATFORM: updated supported platforms. 2004-10-17 Seiichi SATO * inputmethod/iiimf/im_iiimf.c: minor cleanups. * inputmethod/im_common.h: fixed a minor bug. 2004-10-17 Seiichi SATO * inputmethod/iiimf/im_iiimf.c: hide a status window when conversion mode is off. * configure.in: minor cleanups. 2004-10-17 MINAMI Hirokazu * doc/term/mlterm.tc: removed. * doc/term/README.term: updated. 2004-10-16 Seiichi SATO * README, doc/en/PLATFORM: updated supported platforms. 2004-10-16 Seiichi SATO * tool/mlconfig/mc_im.c (is_im_plugin): fixed a stupid bug. (strstr() == 0 -> strstr()) 2004-10-15 Seiichi SATO * tool/mlconfig/mc_im.c: - removed a workaround for gettext problem in uim, since the problem fixed at uim-0.4.5-beta1. - fixed a bug with 'cyg' prefix for DLL on cygwin. * configure.in: - fixed minor bugs in the configuration result message. - added USE_KBD into IM_CFLAGS. 2004-10-14 Seiichi SATO * x_xim.c: fixed a segfault. how to reproduce: 1. $ LANG=UNSUPPORTED_LOCALE mlterm --im=foo 2. switch input method 2004-10-14 Seiichi SATO * inputmethod/m17nlib/im_m17nlib.c (im_new): - fixed a segfault with an invalid parameter. (e.g., --im=m17nlib:non_supported_lang) - minor cleanups. * inputmethod/uim/im_uim.c (im_new): allowed --im=uim: 2004-10-13 Seiichi SATO xim could not get the rectangle information of maximized window. fixed. * x_window.c (x_window_receive_event): moved x_xic_resized() into... * x_screen.c (window_resized): this. 2004-10-13 MINAMI Hirokazu * man/mlclient.1: Updated. 2004-10-13 Seiichi SATO * inputmethod/*/Makefile.in: fixed a stupid bug. (-I${top_builddir}/xwindow -> -I${top_srcdir}/xwindow) 2004-10-12 Seiichi SATO * x_xim.c (search_xim): fixed a bug with multiple displays. (#1034630) 2004-10-11 Seiichi SATO * inputmethod/iiimf/im_iiimf.c (im_get_info): fixed a segfault with htt server provided within ATOK X. 2004-10-11 Seiichi SATO I got "YOUR MEMORY MANAGEMENT IS PERFECT!" message from kik_mem by these changes: * inputmethod/iiimf/Makefile.in, inputmethod/kbd/Makefile.in, inputmethod/m17nlib/Makefile.in, inputmethod/uim/Makefile.in: added DEB_CFLAGS * inputmethod/iiimf/im_iiimf.c, inputmethod/kbd/im_kbd.c, inputmethod/m17nlib/im_m17nlib.c, inputmethod/uim/im_uim.c: - #include - minor cleanups. * inputmethod/uim/im_uim.c: #include * x_im.c, x_im.h: fixed a segfault which is caused by using uim and m17nlib together. 2004-10-10 Seiichi SATO * configure.in: - --disable-kbd. - --enable-dnd -> --disable-dnd - USE_IM_PLUGIN in IM_CFLAGS. * README.iscii, README.ja, man/mlterm.1, etc/key, x_screen.c, x_screen.c, x_shortcut.c, x_shortcut.h: - removed screen->kbd. - removed XIM_OPEN and XIM_CLOSE. - added IM_HOTKEY. * x_screen.h (compare_key_state_with_modmap): new function for callback of input methods. * inputmethod/iiimf/im_iiimf.c, inputmethod/uim/im_uim.c, inputmethod/m17nlib/im_m17nlib.c (switch_mode): new functions for IM_HOTKEY. * inputmethod/m17nlib/im_m17nlib.c: added status window. * inputmethod/iiimf/im_iiimf.c, inputmethod/uim/im_uim.c, inputmethod/m17nlib/im_m17nlib.c (im_get_info): * tool/mlconfig/mc_im.c (get_im_info): added 'encoding' argument. * x_kbd.c, x_kbd.h: moved to .. * inputmethod/kdb/im_kbd.c: this. * inputmethod/kdb/Makefile.in: new file. * xwindow/Makefile.in: - removed x_kbd.o. - added IM_CFLAGS. * x_im.h, x_im.h: added ml_iscii_keymap_new, ml_iscii_keymap_delete and ml_convert_ascii_to_iscii into x_im_export_syms_t. * x_main_config.c: minor cleanup. 2004-10-09 Seiichi SATO * ml_cursor.h: added missig #endif. 2004-10-09 Araki Ken * ml_cursor.[ch]: Intensified cursor operations. * ml_screen.c,ml_edit_util.c,ml_logical_visual.h,ml_mode.h,ml_edit.[ch]: Fixed because of ml_cursor.[ch] being added. 2004-10-06 Seiichi SATO * configure.in: - removed test for uim_get_im_short_desc(). - -DUIM_CAN_GET_DEFAULT_IM -> -DUIM_0_4_4_OR_LATER - defined USE_UIM, USE_IIIMF and USE_M17NLIB in IM_CFLAGS. - --enable-m17nlib. - added /usr/lib/im/ to the library search paths for libiiimcf. - minor cleanups. m17n library support: * inputmethod/m17nlib/Makefile.in: new file. * inputmethod/m17nlib/im_m17nlib.c: new file. * inputmethod/uim/Makefile.in, inputmethod/iiimf/Makefile.in: added IM_CFLAGS into CFLAGS. * inputmethod/iiimf/im_iiimf.c: - fixed a segfault when moving the cursor in pre-editing. - minor cleanups. * inputmethod/iiimf/im_iiimf.c (status_start, status_change, status_done): new functions to handle status events. * inputmethod/iiimf/im_iiimf.c (dispatch): removed IIIMCF_EVENT_TYPE_AUX_GETVALUES to avoid compilation error on FC2. * inputmethod/iiimf/im_iiimf.c (delete): - return reference count. - added finalization for status window. * inputmethod/iiimf/im_iiimf.c (im_get_info): new function to provide information of IM plugins to external tools. * inputmethod/im_info.h: new file used for im_get_info() API. * inputmethod/uim/im_uim.c: - disabled IM_UIM_COMPAT_0_3_8 under uim-0.4.4 or later. - added uim_list to manage all im_uim_t objects. - minor cleanups. - hold terminal encoding name in im_uim_t. - fixed an invalid memery read detected by valgrind. * inputmethod/uim/im_uim.c (delete): - return reference count. - removed im_uim_t from uim_list. - don't call uim_quit(), when m17nlib is enabled. * inputmethod/uim/im_uim.c (helper_send_imlist, helper_im_changed): new functions to handle "im_*" messages from helper. * inputmethod/uim/im_uim.c (im_new): inserted newly-created im_uim_t object into uim_list. * inputmethod/uim/im_uim.c (im_get_info): new function to provide information of IM plugins to external tools. * kiklib/src/Makefile.in: increased MAJOR version. (9->10) * kik_dlfcn.h, kik_dlfcn_dl.c, kik_dlfcn_dld.c, kik_dlfcn_dyld.c, kik_dlfcn_ltdl.c, kik_dlfcn_none.c, kik_dlfcn_win32.c (kik_dl_is_module): new functions to check if a file name has module suffix such as ".so", ".sl" and ".dll". * man/mlterm.1: updated --im option. * tool/mlconfig/Makefile.in: - added LIBDIR for loading module. - removed @UIM_LIBS@ and @IIIMF_LIBS@. now mlconfig is not linked to libuim and libiiimcf. * tool/mlconfig/mc_im.c: - added IM_OTHER intended to unify functions for pluggable IMs. - get IM specific information from plugins. * tool/mlconfig/mc_im.c (is_im_plugin, get_im_info): new functions. * tool/mlconfig/mc_im.c (uim_selected, uim_widget_new, iiimf_set_item, iiimf_selected, iiimf_best_match_index, iiimf_widget_new, button_uim_checked, button_iiimf_checked, button_none_checked): - removed. (unified to below functions) * tool/mlconfig/mc_im.c (im_selected, im_widget_new, button_im_checked): new functions for pluggable IMs. * x_im.h: - added ml_get_char_encoding_name and x_im_status_screen_new into x_im_export_syms_t. - added im_changed callback into x_im_event_listener_t. - increased IM_API_VERSION. * x_im.c (dlsym_im_new_func): return module handle. * x_im.c (x_im_delete): new function to be used for deleting IM objects and unloading modules. * x_im_candidate_screen.c: minor cleanups. * x_im_status_screen.c, x_im_status_screen.h: new files for status window of input methods. * x_screen.c (im_changed): new function for im-switcher. * xwindow/Makeile: added x_im_status_screen.o. 2004-09-26 Seiichi SATO * tool/mlconfig/mc_im.c: fixed a minor bug. 2004-09-26 Seiichi SATO * man/mlterm.1: fixed typo. (JISX0201_KANA -> JISX0201_KATA) (Thanks to Konosuke WATANABE for reporting) 2004-09-19 Seiichi SATO * mlterm/ml_vt100_parser.c (change_char_attr): kept is_reversed when 'ESC [ 39 m' or 'ESC [ 49 m' was received. 2004-09-19 Seiichi SATO * x_im.h: increased IM_API_VERSION. * etc/xim: removed uim-*. * inputmethod/uim/im_uim.c (prop_list_update, prop_label_update): - sent engine name to uim helper. - minor cleanups. * inputmethod/iiimf/im_iiimf.c (atokx_lookup_show, atokx_lookup_hide, atokx_lookup_select, atokx_lookup_set, atokx_lookup): new functions for handling the candidate window using ATOK X LookupAux event. * inputmethod/iiimf/im_iiimf.c (show_iiimcf_version): new function for debugging. * inputmethod/iiimf/im_iiimf.c: minor cleanups. * inputmethod/im_common.h (im_convert_encoding): minor cleanups. * x_im_candidate_screen.c (init_candidates) x_im_candidate_screen.h (x_im_candidate_t): added new parameter 'num_per_window'. 2004-09-19 MINAMI Hirokazu * mkf_ucs4_koi8.c: fixed mapping for cyryllic capital letter ukrainian ie. Thanks to Eugeniy Meshcheryakov(Debian BTS #267631). 2004-09-17 Seiichi SATO * tool/mlconfig/mc_im.c (uim_widget_new): added workaround for htt server included in ATOK X for Linux. * inputmethod/iiimf/im_iiimf.c: minor cleanups. 2004-09-16 Seiichi SATO * ml_edit.c (delete_cols): fixed a bug. (#1028815) 2004-09-15 Seiichi SATO * tool/mlconfig/mc_im.c (uim_widget_new): minor bug fix. 2004-09-15 Seiichi SATO * inputmethod/uim/im_uim.c (im_new), tool/mlconfig/mc_im.c: - use uim_get_default_im_name() if available. - unset the signal handler for SIGCHLD before calling uim_create_context(). * configure.in: added tests for uim_get_default_im_name() and uim_get_im_short_desc() 2004-09-15 Seiichi SATO * tool/mlconfig/mc_im.c: fixed a small bug in auto selector for IIIMF. 2004-09-15 Seiichi SATO * tool/mlconfig/mc_im.c: - fixed segfault when the combo box for IIIMF was changed. - minor improvements around IIIMF. - minor cleanups. 2004-09-14 Seiichi SATO * tool/mlconfig/mc_im.c: cleanups. 2004-09-13 Seiichi SATO * tool/mlconfig/mc_sb_view.c (has_rc_file): new function to check scrollbar has 'rc' file. 2004-09-13 Seiichi SATO * tool/mlconfig/mc_im.c(iiimf_best_match_index): select default language automatically. (according to current locale) 2004-09-13 Seiichi SATO * tool/mlconfig/mc_im.c: cleaned up. * tool/mlconfig/po/POTFILES.in: mc_xim -> mc_im.c. * tool/mlconfig/po/mlconfig.pot, tool/mlconfig/po/ja.po: updated. 2004-09-13 Seiichi SATO * inputmethod/uim/im_uim.c(preedit_pushback): fixed a segfault in encoding conversion. 2004-09-12 Seiichi SATO * inputmethod/iiimf/im_iiimf.c, inputmethod/uim/im_uim.c, x_im.c: - initialized the common object in x_im_new(). - minor cleanups. * x_im.h: increased IM_API_VERSION. 2004-09-12 Seiichi SATO * configure.in: fixed typo. 2004-09-12 Seiichi SATO * etc/Makefile.in: removed uim. 2004-09-12 Seiichi SATO * configure.in: added output to show how you configured mlterm. * updated config.sub (timestamp='2004-06-24') * updated config.guess (timestamp='2004-08-13') 2004-09-11 Seiichi SATO * man/mlterm.1: fixed typo. 2004-09-11 Seiichi SATO * man/mlterm.1: fixed typo. 2004-09-11 Seiichi SATO * x_im.c, x_main_config.c, x_screen.c, tool/mlconfig/mc_im.c: allowed "input_method=none". * man/mlterm.1: updated. (--im=none) 2004-09-11 Seiichi SATO * tool/mlconfig/mc_im.c, tool/mlconfig/Makefile.in: - get available conversion engines from libuim directly. - added IIIMF support. * man/mlterm.1: added IIIMF related things into 'GUI CONFIGURATOR' section. 2004-09-11 Seiichi SATO * etc/uim: removed 2004-09-11 Seiichi SATO * man/mlterm.1: - removed xim_open_in_startup. - added input_method and --im. - 'GTK+ 1.2' -> 'GTK+ 1.2 or later'. - added 'Input Method' into 'GUI CONFIGURATOR' section. 2004-09-10 Seiichi SATO * README, doc/ja/README.ja: - removed xim_open_in_startup. - added input_method. - added --enable-dnd, --enable-uim and --enable-iiimf. - reformatted to fit in 80 columns. * LICENCE: updated. (Contents are not changed) * kiklib/configure.in: applied SuSE's patches(mlterm-configure.patch). * aclocal.m4: applied SuSE's patch(autoconf.patch). 2004-09-10 Seiichi SATO * x_im.h (x_im_t): - remove draw_preedit. - increased IM_API_VERSION. * inputmethod/uim/im_uim.c(drar_preedit), inputmethod/iiimf/im_iiimf.c(drar_preedit): moved to .. * x_im.c (x_im_redraw_preedit): ..this * inputmethod/iiimf/im_iiimf.c: minor cleanups. * inputmethod/im_common.h: - minor cleanups. - fixed a memory leak. 2004-09-10 Seiichi SATO * inputmethod/uim/Makefile.in: * inputmethod/iiimf/Makefile.in: - fixed typo. - added LIBS_LOCAL. * inputmethod/iiimf/im_iiimf.c: fixed compilation errors with libiiimcf in Fedora Core 2. 2004-09-10 Seiichi SATO * inputmethod/im_common.h: new file * xwindow/x_im.h (x_im_convert_encoding): moved to.. * inputmethod/im_common.h (im_convert_encoding): ..this 2004-09-10 Seiichi SATO IIIMF (Internet Intranet Input Method Framework) support: * configure.in: added '--enable-iiimf'. * inputmethod/iiimf/im_iiimf.c: new file * inputmethod/iiimf/im_iiimf_keymap.h: new file * inputmethod/iiimf/Makefile.in: new file How to use: --im=iiimf ............. use IIIMF in the default language. --im=iiimf:ar .......... use IIIMF in Arabic. --im=iiimf:ja:CannaLE .. use IIIMF in Japanese using CannaLE languages engine. about IIIMF: 2004-09-10 Seiichi SATO * inputmethod/uim/im_uim.c (convert_encoding): moved to... * xwindow/x_im.h (x_im_convert_encoding): ..this * inputmethod/uim/im_uim.c: minor cleanups. 2004-09-08 Seiichi SATO * inputmethod/uim/im_uim.c (im_new): - u_int32_t -> u_int64_t - minor cleanups. * inputmethod/uim/Makefile.in: fixed incorrect VPATH. 2004-09-07 Seiichi SATO some improvements around input method: * x_im.h: - increased IM_API_VERSION. - expanded IM_API_COMPAT_CHECK_MAGIC to 64bits. * x_im_candidate_screen.c (set_candidates): renamed to.. * x_im_candidate_screen.c (set_candidate): ..this * x_im_candidate_screen.c (set_candidate): removed a unused argument. * x_im_candidate_screen.h: removed func_ prefix from x_im_export_syms_t. * inputmethod/uim/im_uim.c (convert_encoding): new function to convert received strings to term encoding. * inputmethod/uim/im_uim.c: - fixed some wrong comments. - minor cleanups. 2004-09-06 Seiichi SATO * x_draw_str.c: fixed an incorrect position of #endif. (Thanks to Fanatic for report) 2004-09-06 Mike FABIAN * man/mlterm.1: - fixed typo (CONFIGURATABLE -> CONFIGURABLE) 2004-09-06 Seiichi SATO * x_im_candidate_screen.c: fixed a compiler warning. (Thanks to Mike FABIAN for sending a patch) 2004-09-01 Seiichi SATO * man/mlterm.1: - Added cursor_bg_color and cursor_fg_color. - fixed a typo (encoding -> ENCODING). 2004-08-31 Seiichi SATO * x_screen.c: fixed a deadkey problem with uim. 2004-08-30 Seiichi SATO * man/mlterm.1: fixed a typo. 2004-08-29 Seiichi SATO * inputmethod/uim/im_uim.c: converted X modify key to uim key. 2004-08-28 MINAMI Hirokazu * doc/term/mlterm.* : reversed the order of sequences in sgr0. 2004-08-15 MINAMI Hirokazu * doc/term/mlterm.* : updated information. 2004-08-06 MINAMI Hirokazu * mlterm/ml_vt100_parser.* : enhanced support for "save/restore cursor" escape sequence. 2004-08-01 Seiichi SATO * kik_pty_streams.c (kik_pty_fork): more verbose error message for Linux. 2004-08-01 MINAMI Hirokazu * mlterm/ml_edit.c: allowed multiple restore cursor request. 2004-08-01 Seiichi SATO * mlterm/ml_edit.c (ml_edit_overwrite_chars): fixed a wrap-around bug. 2004-07-16 Seiichi SATO * contrib/icon/mlterm-icon.svg, contrib/icon/mlterm-icon-trans.svg: contributed from Tobias Kieslich. 2004-07-11 MINAMI Hirokazu * doc/term/mlterm.*: changed some sequences to be rxvt compatible. 2004-07-07 Seiichi SATO * inputmethod/uim/Makefile.in: Added X_CFLAGS. * inputmethod/uim/im_uim.c: fixed wrong header path. 2004-06-27 Araki Ken * x_window.c: Fixed a failure of compilation. 2004-06-21 Seiichi SATO * tool/mlconfig/mc_im.c (uim_read_conf): Renamed to ... * tool/mlconfig/mc_im.c (read_uim_conf): ..this. * tool/mlconfig/mc_im.c (xim_read_conf): Renamed to ... * tool/mlconfig/mc_im.c (read_xim_conf): ..this. * tool/mlconfig/mc_im.c (read_uim_conf): Fixed a minor bug. 2004-06-20 Seiichi SATO * x_im_candidate_screen.c(set_candidates): In encoding conversion, set msb if need be. 2004-06-20 Seiichi SATO * x_term_manager.c(x_term_manager_init): * x_main_config.c(x_prepare_for_main_config): Some cleanups against help messages. The words in round brackets indicate available values, and the square bracket quoted value is default. (description (value1/value2/...) [default]) * x_screen.c, x_screen.h: To unify input method related options and configuration keys, --openim(xim_open_in_startup) option, 'xim' key and 'xim_name' key are removed. How to use new input method option: --im=xim .... use XIM with the default server specified by XMODIFIERS --im=xim:xcin ... use XIM with xcin on the current locale. --im=xim:Ami:ko_KR.eucKR ... use XIM with Ami on ko_KR.eucKR locale. --im=uim ... use uim with the default conversion engine. --im=uim:anthy ... use uim with anthy engine. - Added 'default_xim_name' key to allow mlconfig to select xim server automatically. * x_xic.c, x_xic.h(x_xic_get_default_xim_name): * x_xim.c, x_xim.h(x_get_default_xim_name): New functions for 'default_xim_name' key, used to get the name of XIM server which is set by XMODIFIERS. * tool/mlconfig/mc_xim.c, tool/mlconfig/mc_xim.h: Removed. * tool/mlconfig/mc_im.c tool/mlconfig/mc_im.h: * tool/mlconfig/Makefile.in: * tool/mlconfig/main.c: * etc/uim: Supported uim. * x_im.c, x_im.h: - added a symbol for ml_is_msg_set() to x_im_export_syms_t. - increased IM_API_VERSION. * inputmethod/uim/im_uim.c(preedit_pushback): In encoding conversion, set msb if need be. 2004-06-16 Seiichi SATO * x_im_candidate_screen.c(init_candidates): cleared index of candidate table. 2004-06-14 Seiichi SATO * im_uim.c: updated for uim-0.3.9. * x_term_manager.c: cleanup. 2004-06-13 Seiichi SATO * x_screen.c(x_screen_new, x_screen_delete): duplicated conf_menu_path_[1-3] and input_method. 2004-06-13 Seiichi SATO * xwindow/x_uim.c, xwindow/x_uim.h: moved to... * inputmethod/uim/im_uim.c, inputmethod/uim/im_uim.h: this. Uim related things have been implemented as plug-ins(pluggable modules). This change enables mlterm to be compiled without -luim in case of either --enable-uim or --disable-uim, and libuim is required from this module only. * x_im.c, x_im.h: new file, used to load input method plug-ins. * x_im_candidate_screen.c, x_im_candidate_screen.h: new file, used to show the candidates for conversion received from uim. * x_window.c(x_window_set_override_redirect): new function, separated from x_window_set_borderless_flag(). * x_screen.c(draw_str, draw_str_to_eol): moved to x_draw_str.c * x_draw_str.c, x_draw_str.h: New files, separated from x_screen.c to share draw_str() and draw_str_to_eol() with x_im_candidate_screen.c and x_screen.c. * x_main_config.c, x_main_config.h: remove 'uim_engine' and add 'input_method' option. (input_method=:) * x_term_manager.c, x_term_manager.h: removed 'use_uim' option. * x_term_manager.c, x_term_manager.h (x_term_manager_add_fd, x_term_manager_remove_fd): new functions, used to add/remove file descriptors to/from the event source. 2004-05-24 MINAMI Hirokazu * x_xic.c: type of event mask should be long. * kiklib/configure*: added some includes to a test for socklen_t. (thanks to Waldemar Brodkorb) 2004-05-23 MINAMI Hirokazu * x_screen.c: fixes for underlines placement. - shouldn't displaced by bottom_margin. - use the same bottom_margin to draw a cursor. * x_xic.c: load_fontset() should return NULL in case of failure. 2004-05-16 MINAMI Hirokazu * x_window.c: use ct.encoding instead of xselection.property to reject garbage data. 2004-05-16 Seiichi SATO * ml_screen.c(ml_screen_is_cursor_visible): new function * ml_term.c(ml_term_is_cursor_visible): new function * x_screen.c(draw_cursor): Don't draw cursor if cursor is unvisible. 2004-05-16 MINAMI Hirokazu * x_window.c: pasting text using incremental transfer is supported. 2004-05-07 MINAMI Hirokazu * x_imagelib_gdk.c: gdk_pixbuf_ref() was deprecated and shouldn't be called on GTK2. 2004-04-23 Tomohiro KUBOTA * The --borderless option was not documented in the manpage. Patch from Nicolas Kratz , Debian Bug#244657. 2004-04-18 MINAMI Hirokazu * x_shortcut.c: before assigning new function to a key, clear already registered function. 2004-04-18 Seiichi SATO * x_screen.c: Moved all callbacks for uim inside #ifdef USE_UIM. 2004-04-15 Seiichi SATO * pixmap_engine.c: fixed tiny memory leak. 2004-04-12 Seiichi SATO * x_uim.c (x_uim_delete): To plug a file descriptor leak, closed pipes for uim-helper-candwin-gtk. * x_uim.c (x_uim_new): Plugged a memory leak detected by valgrind. It was caused by uninitialized variable 'uim->encoding'. * x_screen.c (draw_preedit_str, get_segment_spot): Calculate the preedit position correctly in the back scroll mode. * x_uim.c (candwin_update_position): Hide a candidate window when the cursor position is out of screen. 2004-04-11 Seiichi SATO * Added uim support. 2004-04-03 MINAMI Hirokazu * tool/mlconfig/Makefile.in: re-introduced IMAGELIB_CFLAGS. (thanks to TAKAHASHI Tamotsu) 2004-03-28 MINAMI Hirokazu * xwnidow/x_shortcut.c: default shortcut should be disabled if some string is assigned to the key combination. 2004-03-23 MINAMI Hirokazu * mlterm/ml_char.c: ml_char_set() now checks its input values when compiled with -DDEBUG. 2004-03-22 MINAMI Hirokazu * xwindow/x_font.c: added a sanity check. (in *aafont, an encoding must follow a font family name) 2004-03-15 MINAMI Hirokazu * kiklib/src/kik_pty_streams.c: warn if /dev/ptmx could not be opened. 2004-03-12 MINAMI Hirokazu * tools/mltconfig/po/Makevars: set subdir to the correct relative path. (SF#906977. Thanks to Min Sik Kim ) 2004-03-09 MINAMI Hirokazu * configure.in: warn if some tools cannot be compiled due to the lack of gtk headers. 2004-03-05 MINAMI Hirokazu * added --enable-dnd configure option[default=yes]. * mlterm/m_char.c: ml_char_t can be initialized single movq on LP64 systems and call to memset() is not neccesary. 2004-03-04 Tomohiro KUBOTA * "-p"/"--pic" option was not enabled when using gdk-pixbuf2. Fixed. 2004-03-03 Araki Ken * Moved ml_line_copy_color_reversed_flag() to ml_logical_visual.c from ml_line.c. * Added ml_char_copy_color_revsered_flag() Removed ml_char_is_color_reversed() * Crossed over line->chars array boundary in shape_iscii(ml_shape.c) and ml_iscii_convert_logical_char_index_to_visual(). Fixed. 2004-03-01 MINAMI Hirokazu * mlterm/ml_vt100_parser.c: ignore leading zeroes in numeric arguments of escape sequences to pass vttest. 2004-02-29 MINAMI Hirokazu * documentation updates. 2004-02-27 MINAMI Hirokazu * configure.in, aclocal.m4, configure: - use PKG_CHECK_MODULES() where possible. - accept "gdk-pixbuf" as a target of with-imagelib. - mlconfig/mlterm-menu will be linked against gtk+-2.x when apropreate libraries are available. * xwindow/x_imagelib_gdk.c: minor code cleanup. * mlterm/ml_edit.c: try to feed a line if next char does not fit in curent line. 2004-02-22 Araki Ken * Added ml_str.[ch].(separated from ml_char.[ch].) 2004-02-20 MINAMI Hirokazu * kiklib/src/kik_pty_streams.c: setsid() seems to detach control terminal. Don't call ioctl TIOCNOTTY when HAVE_SETSID is defined. 2004-02-19 MINAMI Hirokazu * kiklib/src/kik_pty_streams.c: stopped use of ioctl TICNOTTY on glibc2 for happy valgrinding. 2004-02-16 Seiichi SATO * Don't use -no-undefined libtool option, expect that $allow_undefined_flag is "unsupported". 2004-02-13 Tomohiro KUBOTA * configure: synchronized with configure.in (2004-01-31). 2004-02-12 MINAMI Hirokazu * **/Makefile.in: - use @X_LIBS@/@X_PRE_LIBS@/@X_EXTRA_LIBS@ when possible. - mlconfig does not needs IMAGELIB_CFLAGS to compile. 2004-02-11 Araki Ken * Region selection and backscrolling are disabled in vertical mode. * Color was not reversed in selecting in ISCII mode. Fixed. 2004-02-11 Tomohiro KUBOTA * xwindow/xfont.c, xwindow/xfont.h, xwindow/x_term_manager.c: mlterm will print an error message if mlterm cannot start because of lacking of fonts. 2004-02-09 MINAMI Hirokazu * xwindow/Makefile.in, scrollbar/sample/Makefile.in, contrib/scrollbar/extra/Makefile.in: replaced hard-coded path by @X_CFLAGS@/@X_LIBS@ for cross compile. 2004-02-05 MINAMI Hirokazu * x_descsp_font.c: - backgorund wasn't cleared in draw_image_string. - when xft is used for rendering, always compose dec special chars since we can see nothing otherwise. (XXX to be fixed) 2004-02-03 Araki Ken * x_screen.c: If screen->line_space is over zero, XClearArea() and XDrawString() are used instead of XDrawImageString(). 2004-02-03 MINAMI Hirokazu * xwindow/x_decsp_font.c: - In x_decsp_font_draw_string(), reset a clip mask when unknown char was passed so that dummy rectangle can be drown correctry. - In x_decsp_font_draw_image_string(), draw a rectangle for unknown char. (Thanks to Mike FABIAN for reporting) 2004-01-31 Seiichi SATO * kik_pty_stream.c: If ptsname() fails, show an error message. 2004-01-31 Seiichi SATO * mlterm/ml_edit.c(ml_edit_resize): Clear char_index of cursor, when the cursor position was reset. This change fixes a bug that caused a segfaul when resizing window over and over. 2004-01-31 KATO Kazuyoshi * configure.in: mlterm-zoom can be specified as a value of --with-tools option. * contrib/tool/mlterm-zoom: Added. 2004-01-31 Tomohiro KUBOTA * xwindow/x_font.c: wrong comment was fixed. 2004-01-29 Seiichi SATO * xwindow/x_term_manager.c: fixed a segfault when initial font size was out of range. (Thanks to Mike FABIAN for sending a patch) 2004-01-29 MINAMI Hirokazu * mlterm/ml_edit.c: Fixed infinite loop when the number of columns needed to display a character is greater than screen width. 2004-01-26 Tomohiro KUBOTA * Added an explanation for -*/--type option for man/mlterm.1. 2004-01-25 KATO Kazuyoshi * tool/mlmenu/Makefile.in: Fixed a installation path. 2004-01-21 MINAMI Hirokazu * made font size range specification options work again. (THanks to Mike FABIAN for patchs) 2004-01-17 Tomohiro KUBOTA * When "configure --with-type-engines=xcore,xft" or "configure --enable-anti-alias", xcore was not enabled. Fixed. * "mlterm --help" says the default of --type-engine is always xcore regardless of the real default (which depends on the compilation option). Fixed. 2004-01-15 MINAMI Hirokazu * x_imagelib_gdk.c: When gtk2 is choosed(-with-imagelib=gdk-pixbuf2), use g_object_unref insted of (deprecated)gdk_pixbuf_unref. * kik_pty_streams.c: #define __EXTENSIONS__ for solaris. 2004-01-14 Tomohiro KUBOTA * mlconfig lists scrollbars in user's configuration directory and system directory. 2004-01-13 Seiichi SATO * tool/mlclient/main.c: arguments specified by -e option were able to estimate(e.g., mlclient -e w3m -v). fixed. (Thanks to Murano Naoki san for sending a patch) 2004-01-12 MINAMI Hirokazu * kiklib/src/kik_pty_streams.c: #defined _BSD_SOURCE to get rid of compile error on glibc. 2004-01-12 Tomohiro KUBOTA * Include in xwindow/x_sb_mode.c for usage of strcmp(). 2004-01-08 MINAMI Hirokazu * kiklib/src/kik_pty_streams.c: #defined _XOPEN_SOURCE as 500 to make features defined in UNIX98 pty available. (should fix debian Bug#226654. Thanks to lamont for reporting) 2004-01-07 MINAMI Hirokazu * xwindow/x_main_config.c: minor bugfix. * xwindow/x_font_manager.c: fixed segv when changing font size using escape sequence. 2004-01-06 MINAMI Hirokazu * mlterm/ml_vt100_parser.c: replaced magic constant "20" by DIGIT_STR_LEN(int). * xwindow/x_screen.c: mod_meta_mode = 8bit (set MSB) was not working. fixed. 2004-01-05 Seiichi SATO * mlterm/ml_edit.c (cursor_goto_intern): If requested row is larger than terminal size, round it to end of row. 2004-01-03 MINAMI Hirokazu * xwindow/x_main.config.c: type_engine was not initialized when no option had been specified. fixed. * xwindow/x_font_cache.c: "font_name_list" should not be accessed after realloc. * xwindow/x_window.c: #ifdef'ed not-yet-implemented features. 2003-12-30 Araki Ken * Core X Font Subsystem can be removed by --with-type-engines=xft. 2003-12-28 MINAMI Hirokazu * xwindow/x_screen.c: reverted the last change. 2003-12-28 MINAMI Hirokazu * configure.in, configure: changed VERSION from 2.7.0->2.8.0 * xwindow/x_screen.c: fixed segv (use_anti_alias should do nothing when USE_TYPE_XFT is not defined). 2003-12-27 Seiichi SATO * tool/mlconfig/main.c: ANTI_ALIAS -> USE_TYPE_XFT 2003-12-27 Seiichi SATO * If confiugre detects that pkg-config and xft2 library are available, define USE_TYPE_XFT. 2003-12-27 Araki Ken * Added --type-engines option to configure and obsoleted --anti-alias option. * Added -*,--type,type_engine option to mlterm. You can specify which engine you use, xcore or xft. 2003-12-27 Seiichi SATO * mlterm/ml_pty_win32.c: cleaned up error handling. * updated config.sub and config.guess. (timestamp='2003-10-07') 2003-12-25 MINAMI Hirokazu * tools/mlconfig/main.c: made gettext work with GTK2. * Re-mapping of keys using xmodmap now should be handled properly. * Keys that can be locked(Num_Lock/Scroll_Lock/ISO-Level3_Lock) are no longer regarded as a valid modifier key. 2003-12-24 Seiichi SATO * contrib/scrollbar/pixmap_engine/pixmap_engine.c: fixed a problem when slider images were not presented. 2003-12-22 MINAMI Hirokazu * x_window.c: selection conversion request type "TARGETS" is now supported( clipboard now should work with KDE klipper). 2003-12-21 Seiichi SATO * mlterm/ml_pty_win32.c: Added:-) * configure.in mlterm/Makefile.in: Only a few changes for ml_pty_win32.c * man page: Updated the maximum number of windows in MULTIPLE PTY section. * etc/xim: Added uim-anthy, uim-skk, uim-tcode, uim-prime and uim-tutcode. Notes: - Uim is available at http://www.freedesktop.org/Software/uim - uim-xim version 0.2.0 said 'Now only supports Japanese' on startup. - I've tested uim-anthy and uim-prime for a little while, both seem to work fine with mlterm. 2003-12-11 MINAMI Hirokazu * xwindow/x_screen.c: fixed an off-by-one error in get_mod_meta_mask(). (modifiermap[8*max_keypermod] shouldn't be accessed) * removed redundant spaces/ corrected typo. 2003-11-24 Seiichi SATO * configure.in, mlterm/Makefile: Added AC_CANONICAL_HOST, AC_CANONICAL_TARGET and mingw32-dependent stuff. 2003-11-24 Seiichi SATO * kiklib/configure.in, kiklib/src/kik_config.h.in: Added AC_CHECK_TYPE(ssize_t,int), since mingw32 does not have ssize_t. (Does anybody know if this will work on Win64?) 2003-11-03 Araki Ken * Enbugged by [2003-10-31-2]. Fixed. 2003-10-31 Araki Ken * The color of log lines sometimes reversed or restored incorrectly. Fixed. * Supported borderless window by _MOTIF_WM_HINTS atom. 2003-10-16 Araki Ken * A snapshot file name must not contain ".." and its suffix is always ".snp" for security issues. 2003-10-12 Araki Ken * 'snapshot' protocol allows no value. 2003-10-12 Araki Ken * Added 'snapshot' to 5379 protocol. 2003-10-12 Araki Ken * doc/ja/README.ja: Updated and fixed typo. 2003-10-12 Araki Ken * Removed tool/viewsfml/. * Added tool/accessories/. 2003-10-12 Araki Ken * mlmenu/main.c: Fixed a critical bug. * mlmenu/Makefile: Removed. * configure.in: mlmenu can be specified as a value of --with-tools option. 2003-10-12 Araki Ken * x_font_config.[ch]: Renamed x_configize_... to x_customize_... * version.h.in: Validated CVS_REVISION. 2003-10-12 Araki Ken * Minor cleanups. 2003-10-12 Araki Ken * mlmenu/main.c: ~/.mlterm/menu couldn't be loaded correctly. Fixed. 2003-10-11 Araki Ken * Renamed font_custom and color_custom to font_config and font_custom. * Added x_main_config.[ch] pulled out from x_term_manager.c 2003-10-11 Araki Ken * After options saved by 5382 or 5383 protocol, new terminals start with the new options. 2003-10-11 Araki Ken * Added -&,--borderless,borderless option. * Added tool/mlmenu. 2003-10-05 Araki Ken * 2.8.0 released. (tag "rel-2_8_0") * Visual bel didn't work as expected. Fixed. 2003-10-04 Araki Ken * Added --with-tools and --with-scrollbars description to README and README.ja. 2003-10-01 Araki Ken * Modified some documents. 2003-10-01 MINAMI Hirokazu * etc/*aafont: UCS2->UCS4 2003-09-30 Araki Ken * x_screen.c(window_exposed): Consider vertical mode. 2003-09-30 Araki Ken * x_sb_view_factory.c: Memory leaked if specified scrollbar not found and "simple" scrollbar used. Fixed. * x_sb_view_factory.c: Removed stuff about lib_ref_table. * ml_char.c(ml_char_move): Use ml_char_init instead of memset. 2003-09-29 Araki Ken * version.h: 2.8.0 * mlconfig: "Font size (temporal)" changed to "Font size (temporary)". 2003-09-26 Araki Ken * Added font.ja and main.ja 2003-09-25 Araki Ken * x_screen.c(draw_line): RTL lines shown incorrectly when variable fonts used and region being selected. 2003-09-25 Araki Ken * ml_char.[ch]: Supported little endian machines in 64bit. 2003-09-21 Seiichi SATO * x_window.c(x_window_receive_event): Fixed incorrect width and/or height of the exposed area. For example, at event->expose.height = 1 and event->expose.y = 0, height should be 0 not -1. 2003-09-21 Araki Ken * ml_logical_visual.c(comb_logical): Usage of ml_char_at() was wrong. Fixed. * ml_char.c: IS_COMB(attr) used wrong mask. Fixed. 2003-09-21 Araki Ken * x_font_cache.c,x_font_custom.c: minor fixes. 2003-09-21 Araki Ken * mlterm.spec,ml_char.h: minor fixes. 2003-09-20 Araki Ken * ml_char.[ch]: ml_char_t is 64bit in LP64 system. LSB 4bits of attr are always valid even if characters combined. 2003-09-19 MINAMI Hirokazu * x_dnd.c: code cleanup. 2003-09-18 Araki Ken * ml_char.[ch]: If ml_char_t combined or not could not be distinguished. Fixed. (96bit in LP64 system now) (Thanks to Minami Hirokazu san) 2003-09-17 Seiichi SATO * doc/ja/README.sb: Fixed a typo. 2003-09-16 Seiichi SATO * configure.in : Disabled pixmap_engine by default. * README, README.ja, README.sb: Updated. 2003-09-16 MINAMI Hirokazu * ml_config_menu.c: call kik_remove_sig_child_listener() when the config menu is finalized. 2003-09-15 Araki Ken * mlterm-menu/Makefile.in: Added $(SYSCONFDIR) target. * x_font_cache.c(x_get_font_name_list_for_fontset): Load "-*-*-medium-r-*--%d-*-*-*-*-*" font by default for FontSet. 2003-09-15 Araki Ken * ml_char.[ch]: ml_char_t is 64bit in LP64 system. 2003-09-15 Araki Ken * x_term_manager.c(start_daemon,client_connected): If multiple mlterms started with -j {genuine|blend} option, both of or either of them could die. Fixed. 2003-09-15 MINAMI Hirokazu * x_term_manager.c: - dead mask for screens is now also stored in u_long like the one for terms in ml_term_manager.c . - renamed MAX_TERMS to MAX_SCREENS . 2003-09-15 Seiichi SATO * x_font_manager.c (x_get_fontset): Fixed a compilation error with --enable-debug. 2003-09-15 Araki Ken * configure.in: Added --enable-optimize-redrawing option. 2003-09-15 KATO Kazuyoshi * xwindow/x_screen.c (button_pressed): Ctrl+Middle button don't launches external program. Fixed. 2003-09-14 Araki Ken * tool/mlclient/Makefile.in: Added $(BINDIR) target which creates $(BINDIR) if it doesn't exist. 2003-09-14 Araki Ken * x_font_custom.c(x_get_all_custom_font_names): Returns fontname list separated by ','. (Illegal font name list returned before.) 2003-09-14 Araki Ken * x_font.c(x_font_new): Surrounded xft_font by #ifdef ANTI_ALIAS - #endif. 2003-09-14 Araki Ken * Added mlterm/API. * ml_screen.c(ml_screen_set_modified_all): Removed '== NULL'. * x_screen.c(flush_scroll_cache): The second and third arguments of ml_set_modified_lines() if screen->scroll_cache_rows < 0 was reversed. Fixed. * x_screen.c: Don't use ml_line_updated(). Use ml_term_updated_all() instead. 2003-09-14 Araki Ken * ml_logical_visual.c(iscii_visual): cleaned and tuned up. * ml_term.c, x_screen.c: ml_model_t and ml_logs_t states must not be modified by x_screen.c, in other words, functions in ml_term.c must not modify them unless these are logicalized in advance. But it was not complied. Fixed. 2003-09-13 Araki Ken * xwindow/Makefile.in: Added x_font_cache.o. * x_screen.c:selecting_with_motion(): A character which is after expected one was selected. Fixed. * x_screen.c: Use x_get_font_size() instead of accessing screen->font_man->font_cache->font_size directly. * x_font_manager_t.font_cache_table can be shared by multiple font managers as x_font_cache_t. 2003-09-10 MINAMI Hirokazu * ml_term_manager.c: dead_mask is now u_long instead of u_int32. Up to 64 pty (not window) may be opened on 64-bit systems. * x_term_manager.c: stopped to check whether unused screen should be closed. * contrib/tool/dnd: Added smaple.c to show how to configure mlterm using X Drad and Drop protocol. 2003-09-08 Araki Ken * x_font_custom.[ch]: Added default_font_name_table to x_font_custom_t. Shrunk wasted memory if many default font names specified in ~/.mlterm/*font files. 2003-09-01 Araki Ken * Dumped core in selecting region in some situations. Fixed. 2003-08-29 MINAMI Hirokazu * x_dnd.c: - fixed sgev in incremental data transfer. - code cleanup. 2003-08-27 Araki Ken * The colors of lines next to empty ones were not reversed correctly in selection. Fixed. 2003-08-25 Araki Ken * version.h.in: 2.8.0pre 2003-08-20 MINAMI Hirokazu * x_dnd.c: added a handler for DestroyNotity. 2003-08-18 MINAMI Hirokazu * x_window.c, x_dnd.h: code cleanup. XDnD subsystem is separated into x_dnd.c and should be easily disabled if it's desired. * x_dnd.c: plugged tiny memory leaks. 2003-08-14 Araki Ken * Added tool/viewsfml/README,tool/viewsfml/Makefile. * viewsfml.sh: Replace charset=iso-8859-1 with charset=iso-2022-jp. 2003-08-14 Araki Ken * ml_edit.c(ml_edit_clear_line_to_right,ml_edit_clear_line_to_right_bce): Garbage could be left even if line is cleared by ESC [ K. Fixed. (Thanks to Kubota Tomohiro san) * Added tool/viewsfml/viewsfml.sh. 2003-08-12 MINAMI Hirokazu * x_dnd.c: for incremental transfer, parser/converter should be kept to remember its state(endianess/fragments etc.) 2003-08-10 MINAMI Hirokazu * x_xim.c: - xim->im should be cleared when im was closed due to an error. - Default XIM name is now "none", not "@im=none". 2003-08-10 Araki Ken * Cursor wasn't redrawn under vertical writing mode. Added ml_xterm_event_listener_t.start_2 and fixed this problem. * Using ml_char_at() instead of refering to ml_line_t:chars[] array directly. * ml_edit_intern.c: renamed to ml_edit_util.c. 2003-08-05 Araki Ken * ml_screen.c(receive_scrolled_out_line): Adhoc workaround to fix strange selection in backscroll mode. 2003-08-03 Seiichi SATO * configure.in: I forgot appending '-export-symbol' to DL_LIBS. 2003-08-03 Seiichi SATO * configure.in, configure, kiklib/configure.in, kiklib/configure kiklib/src/Makefile.in, kik_dlfcn_ltdl.c, xwindow/Makefile.in tool/mlconfig/Makefile.in, contrib/tool/mlterm-menu/Makefile.in: Added libltdl support. (Thanks to Aida Shinra san for sending a patch) * kik_dlfcn_dld.c, kik_dlfcn_win32.c: Some cleanups. 2003-08-03 Araki Ken * ml_line.c(ml_line_set_modified): Fixed a bug in dealing with multi-byte character. (Thanks to Kubota Tomohiro san) 2003-07-27 Seiichi SATO * mkf/lib/Makefile.in: My change(2003-03-21) seems to be wrong. Fixed. 2003-07-27 Araki Ken * Added OPTIMIZE_REDRAWING macro, which is defined by default, to ml_line.c. 2003-07-27 Tomohiro KUBOTA * contrib/tool/mlterm-menu/Makefile.in: SYSCONFDIR is changed from $(sysconfdir)/mlterm to $(sysconfdir) because "mlterm" is added by source-file-side. This fixes a problem that mlterm-menu refers /etc/mlterm/mlterm/menu (which should be /etc/mlterm/menu) as system-wide configuration file. 2003-07-27 Araki Ken * Fixed scrollbar behavior bug(BTS:762666). (Thanks to Murase Masaki san) 2003-07-22 Seiichi SATO * kik_dlfcn_dl.c: Fixed a typo. 2003-07-21 Seiichi SATO * mkf/lib/Makefile.in: Cleaned up. - ${top_builddir}/kiklib/src/libkik.la -> -lkik - -L${top_builddir}/kiklib/src/.libs -> -L${top_builddir}/kiklib/src 2003-07-21 Seiichi SATO * kik_dlfcn_dl.c: Could not dynamically load HP-UX library(.sl). Fixed. NOTE: Recent HP-UX has dlopen() and shl_load(). At first configure scripts do check for dlopen(). If we don't find dlopen(), shl_load() will be used. 2003-07-21 Seiichi SATO * kik_dlfcn_dyld.c: Supported the Darwin dynamic module loading via dyld APIs. 2003-07-18 MINAMI Hirokazu * x_dnd.c: tweaked mime-type preference order. 2003-07-17 MINAMI Hirokazu * x_dnd.c: fixed bugs in the parsing of configuration protocol. 2003-07-17 Seiichi SATO * Started porting to MS Windows. * kik_dlfcn.c: Removed. * kik_dlfcn_dl.c: Taken from kik_dlfcn.c. (dlopen() in libdl) * kik_dlfcn_dld.c: Taken from kik_dlfcn.c. (shl_load() of HP-UX) * kik_dlfcn_dyld.c: Added for Mac OS X. (not written yet) * kik_dlfcn_win32.c: Added for Windows. (native Win32 and Cygwin) * kik_dlfcn_none.c: Dummy functions. * kik_pty_win32.c: Dummy functions. * kik_unistd.c (kik_usleep): Replaced usleep() with Sleep() in Win32API. * kiklib/configure.in: Added AC_CANONICAL_TARGET and cleaned up. * mkf/configure.in: Added AC_CANONICAL_HOST and AC_CANONICAL_TARGET. 2003-07-17 Seiichi SATO * kik_pty_streams.c: slave -> *slave (line 243) 2003-07-14 Seiichi SATO * Applied a keypad patch from Mike Fabian. 2003-07-14 Araki Ken * Bidi characters in backward-scrolled area were not correctly selected. Fixed. * The end characters of lines in backward-scrolled area couldn't be selected. Fixed. 2003-07-13 Seiichi SATO * Added "lang" and "country" into map_ucs4_to_func_table struct instead of "locale", and get_map_ucs4_to_func_for_current_locale() function was changed to select UCS mapping table by sys_lang and sys_coutry. Probably it is useful, if your system have no posix locale mechanism, or broken one such as old UN*X and Mac OS X. (Thanks to Aida Shinra san for sending a patch) 2003-07-13 Seiichi SATO * kik_config.h.in: Added gid_t. It is required on some platforms, and defined by AC_TYPE_UID_T. * kiklib/configure.in: Cleaned up platform dependent stuff. 2003-07-09 Araki Ken * Fixed 0x0 core dump bug. (BTS:762681) * ml_vt100_parser.c: Enabled IGNORE_SPACE_FG_COLOR. (redrawing optimized) * Added -%,--logseq,logging_vt_seq option. 2003-07-07 MINAMI Hirokazu * fixed a compilation error. (Thanks to Hironori SAKAMOTO san) 2003-07-08 Seiichi SATO * Previous fix for sizehint bug still had a problem in x_window_set_normal_hints(). Fixed. * Now pixmap_engine does not require *_use_mask key in rc file. (Thanks to Minami Hirokazu san) 2003-07-08 Seiichi SATO * x_imagelib_imlib.c: fixed a small bug in x_imagelib_load_file(). 2003-07-08 Seiichi SATO * My fix for sizehints bug (2002-08-29) seems not to be enough. Fixed. 2003-07-06 Araki Ken * Cursor character was not correctly drawn in window unfocused. Fixed. 2003-07-06 Seiichi SATO * pixmap_engine.c: minor cleanup 2003-07-06 Araki Ken * ml_edit.c, ml_line.c: Optimized the way of redrawing. 2003-07-05 Seiichi SATO * fixed a small bug in pixmap_engine.c 2003-07-05 MINAMI Hirokazu * x_imagelib_gdk.c:x_imagelib_load_file() now retuens None as "mask" when there's no alpha plane in the specified image file. 2003-07-05 Seiichi SATO * Updated pixmap_engine since x_imagelib_load_file() was changed. 2003-07-05 MINAMI Hirokazu * Changed API of the x_imagelib_load_file() function. 2003-07-03 Araki Ken * Modified a little README,man/mlterm.1,doc/ja/README.ja 2003-07-01 Araki Ken * Updated tool/mlconfig/po/de.po. (Thanks to Mike Fabian) 2003-07-01 Araki Ken * Updated tool/mlconfig/po/zh_TW.po. (Thanks to Ambrose Li) 2003-06-30 Araki Ken * Compiled mlcc and pixmap_engine by default. * Added sample3 description to doc/en/README.ja and man/mlterm.1. * Added sample3 to mc_sb_view.c. 2003-06-29 Araki Ken * If 5380 request is denied as a result of challenge failure, #forbidden is returned. * Set "@im=none" as the value of XMODIFIERS by default. * Fixed contrib/tool/mlcc/Makefile.in and removed contrib/tool/mlcc/Makefile. * Added mlcc to --with-tools in configure.in. 2003-06-29 Seiichi SATO * Renamed entry function name of scrollbar engine to x_*_sb_engine_new. * '-export-dynamic' is only used when you specify -with-scrollbars=pixmap_engine. * Fixed a description for --with-scrollbars. 2003-06-29 MINAMI Hirokazu * re-introduced "mlcc" for as a sample of a configurator on the mlterm. 2003-06-29 Araki Ken * Minor fixes of pixmap_engine.c and x_sb_view_factory.c. 2003-06-29 Seiichi SATO * Fixed segfault with scrollbar rcfile which does not specify engine. * Added VPATH to Makefile.in of pixmap_engine * Minor bugfix of Makefile.in of mlterm-menu. 2003-06-29 Seiichi SATO * Extended an API of scrollbar plugin to load new style scrollbar which has an rcfile. * To use x_imagelib_load_file() from plugin side, added '-export-dynamic' to link option. * Added 'pixmap_engine' scrollbar library.(depends on imlib or gdk-pixbuf) * Added 'sample3' scrollbar to show the usage of pixmap_engine. 2003-06-29 Araki Ken * If a text was folded into multiple lines and one of them were ended with space character, the space character couldn't be selected in copy&paste. Fixed. (Thanks to Sakamoto Hironori san) 2003-06-28 Araki Ken * Added description of -6,--stbs,static_backscroll_mode option to mlterm.1 manual. 2003-06-26 Seiichi SATO * Fixed a installation path for mlterm-menu. ($(DESTDIR)$(sysconfdir) -> $(DESTDIR)$(sysconfdir)/mlterm) * Moved "$(INSTALL) -m 644 menu $(SYSCONFDIR)" to install target from mlterm-menu target in Makefile.in. 2003-06-23 Araki Ken * Added authorization mechanism by ~/.mlterm/challenge and revived protocol 5380. 2003-06-23 MINAMI Hirokazu * Priority of "text/plain" in XDND is degraded so that work around mozilla's buggy DND handling. 2003-06-22 MINAMI Hirokazu * Added support of window group. 2003-06-22 Araki Ken * 'make distclean' failed. Fixed. (Thanks to Kubota Tomohiro san) 2003-06-21 Araki Ken * kik_conf_io_write() could misunderstand a value string as its key string. Fixed. 2003-06-21 Araki Ken * In some cases, combining characters couldn't be drawn. Fixed. (Thanks to Kubota Tohomiro san) 2003-06-15 Tomohiro KUBOTA * A typo in doc/en/PROTOCOL. 2003-06-14 Araki Ken * Released 2.7.0 (rel-2_7_0) 2003-06-14 Tomohiro KUBOTA * Update mlterm.1 for "proto:" prefix. * Tiny typo fixes. 2003-06-13 Araki Ken * Supported "proto:" prefix which is a part of shortcut key string and designates its following string as mlterm configuration protocol. 2003-06-13 Araki Ken * If pty device not opened, mlterm died. Fixed. (Thanks to Minami Hirokazu san) 2003-06-11 MINAMI Hirokazu * Don't free color cells even if mlterm was compiled with Xft. 2003-06-09 Seiichi SATO * Changed parse_xft_font_name() to allow XftFont name to include hyphens, e.g. "Foo\-Bold-iso10646-1" (Thanks to Ambrose Li) 2003-06-08 Araki Ken (1.449) * Rewritten documentations(doc/en/*,doc/ja/*) 2003-06-08 Araki Ken * http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=196228 fixed. (Thanks to Sato Seiichi san) * Available '\n','\r','\e','\n' chars in key config file. 2003-06-05 MINAMI Hirokazu * Icon handling is re-designed. - do not hinder window property anymore - smaller memory consumption (Thanks to Tatsuya Kinoshita san and Seiichi SATO san) 2003-06-04 Seiichi SATO * Added $CPPFLAGS to CFLAGS. 2003-06-04 Seiichi SATO * Fixed a problem with occuring an incorrect size hint when changing scrollbar. (change the order of x_window_resize() and x_window_set_normal_hints() in x_scrollbar_change_view().) 2003-06-03 Tomohiro KUBOTA * Update man/mlterm.1 (The default of --sb is "true".) 2003-06-03 Araki Ken * Renamed 'ut.name' to 'ut.user' in kik_utmp_sysv.c. * Fixed typo in kik_dlfcn.c. (Thanks to Sakamoto Hironori san) 2003-06-03 Araki Ken * Added doc/ja/README.pty * Updated doc/ja/README.ja * Ctrl+[F2-F4] are assigned to OPEN_PTY,NEXT_PTY,PREV_PTY shortcut by default. * If --sb=false is specified, ignored --title and --icon options. Fixed. 2003-06-03 MINAMI Hirokazu * xwindow/x_imagelib_gdk.c: - support MSBFirst screen - fixed bugs in PseudoColor visual 2003-06-02 MINAMI Hirokazu * Removed obsoleted config tools(mlcc/mlconf_curses) * xwindow/x_dnd.c: code cleanup * xwindow/x_imagelib_imlib.c: added mask support * xwindow/x_imagelib_gdk.c: plugged leak 2003-05-25 Tomohiro KUBOTA * Japanese translation for a new item in tool/mlconfig/po . * Current automatic (locale-sensible) encoding is now shown like "ISO-8859-15" instead of "ISO885915" on mlconfig. 2003-05-25 Seiichi SATO * Added a search path to kiklib/src/.libs/libkik.* for -lkik to mkf/lib/Makefile.in. (Thanks to Kubota Tomohiro san and Minami Hirokazu san) 2003-05-25 Araki Ken * The free'd 'root' could be accessed at close_screen_intern() in x_term_manager.c. Fixed. (Thanks to Minami Hirokazu san) * As soon as the child 'make' process exits, the parent one also exits. (Thanks to Minami Hirokazu san) * Added 'is_auto_encoding' to doc/en/PROTOCOL. (Thanks to Kubota Tomohiro san) 2003-05-25 Araki Ken * Cursor position could be illegal after a window resized. Fixed. 2003-05-24 Tomohiro KUBOTA * Removed description on -%/--class command option from manpage. * Removed non-ASCII (well, seems to be intended to be EUC-JP) characters from this ChangeLog. 2003-05-24 Araki Ken * Fixed set_xdnd_config() in x_screen.c 2003-05-22 MINAMI Hirokazu * Removed unused functions from x_window.c. 2003-05-22 Araki Ken * Compilation failed in ml_logical_visual.c. Fixed. (Thanks to Kubota Tomohiro san) 2003-05-20 MINAMI Hirokazu * make XDND handler call start/stop_vt100_cmd() before/after processing a config sequence. 2003-05-20 Araki Ken * Fixed some problems in resizing window. (Thanks to >>796) 2003-05-19 MINAMI Hirokazu * support DND from nautilus's background setting dialog. * support application/x-color as DND type and reflect the color to the window's background. * added lots of debug messages. * In DND session, "text/x-mlterm.config" is now preffered to other mime types. 2003-05-18 Araki Ken * Renamed x_font_set_x{ft_}font() to x_font_load_x{ft_}font(). 2003-05-18 MINAMI Hirokazu * Really fixed the XDND bug (Thanks to Seiichi SATO san) 2003-05-18 Araki Ken * BEL character after ESC ] ... was ignored. Fixed. 2003-05-18 Araki Ken * Supported ESC [ ? 6 h(relative origin), ESC [ ? 6 l(absolute origin). * Supported ESC [ ? 7 h(auto wrap), ESC [ ? 7 l(no auto wrap). 2003-05-18 MINAMI Hirokazu * fixed yet another XDND bug. 2003-05-18 Araki Ken * Support cursor control characters possibly anywhere inside escape sequences. 2003-05-18 Araki Ken * If bold font not found in anti-alias mode, pseudo bold processing enabled. (Thanks to >>619) 2003-05-18 Araki Ken * Set adhoc_right_align of bidi_logical_visual off. 2003-05-17 MINAMI Hirokazu * mlterm now accepts configuration strings through XDND protocol. 2003-05-17 Araki Ken * ml_convert_col_to_char_index() could access invalid characters if BREAK_BOUNDARY flag is set. Fixed. 2003-05-17 Araki Ken * The width of U+300A, (U+300B,) U+301A, U+301B chars changed from "ambiguous" to "wide" for xterm compatibility. (Thanks to Sakamoto Hironori san) 2003-05-17 Araki Ken * Removed -%/--class/app_class. * Fixed the behaviors of --name,--title,--icon options. (Thanks to Gareth Jones) * x_dnd_process_xxx() functions was declared as x_process_xxx() in x_dnd.h. fixed. 2003-05-16 Araki Ken * The font color of selected region remained reversed when window was resized. Fixed. 2003-05-16 Araki Ken * Cleaned up mlterm/ml_(edit|model|line).[ch]. 2003-05-16 MINAMI Hirokazu * xwindow/x_dnd.c: added a X error handler. 2003-05-15 MINAMI Hirokazu * xwindow/x_dnd.h, xwindow/x_dnd.c, xwindow/x_window.h,xwindow/x_window.c: Major rewrite of the DND subsystem. 2003-05-12 MINAMI Hirokazu * xwindow/x_dnd.c: added another sanity check so that malicious dnd data will be ignored * xwindow/x_dnd.c: mlterm could be crashed if only one mime-type was provided for a dropped data. 2003-05-12 MINAMI Hirokazu * xwindow/x_dnd.c: fixed typo 2003-05-11 MINAMI Hirokazu * doc/term/mlterm.tc: Removed u[6-9] to make the file smaller. 2003-05-10 Seiichi SATO * configure.in, kiklib/configure.in, mkf/configure.in: added AC_LIBTOOL_WIN32_DLL macro. * kiklib/src/Makefile.in: MAJOR increment with a change of kik_dl_open(). 2003-05-06 MINAMI Hirokazu * xwindow/x_dnd.c, xwindow/x_dnd.h : adopt XDnD v5 spec. 2003-05-06 MINAMI Hirokazu * xwindow/x_term_manager.c: plugged memory leak. 2003-05-05 MINAMI Hirokazu * xwindow/x_imagelib_gdk.c: minor code cleanup 2003-05-05 MINAMI Hirokazu * mlterm/ml_vt100_parser.c: The rxvt style background changing sequence "ESC ] 49 ; colorname BEL" was not working. 2003-05-05 Araki Ken * Minor fixes around only_use_unicode_font and not_use_unicode_font options. 2003-04-14 MINAMI Hirokazu * xwindow/x_imagelib_gdk.c: - power of zero was used for color conversion. fixed. 2003-04-13 Seiichi SATO * x_term_manager.c: changed to be more compatible with xterm/rxvt. If "--icon" option was not specified, title name is used for WM_ICON_NAME, 2003-04-13 Seiichi SATO * kiklib/configure.in, kiklib/configure, kiklib/src/Makefile.in, kiklib/src/kik_dlfcn.c, kiklib/src/kik_dlfcn.h, xwindow/x_sb_view_factory.c: - Removed obsolete AC_CYGWIN from kiklib/configure.in. (Thanks to Sakai Masahiro san) - Added AC_CANONICAL_HOST instead of AC_CYGWIN into kiklib/configure.in. - Removed all of "#ifdef __CYGWIN__". - Added a test to define LIB_PREFIX and LIB_SUFFIX. - Changed the arguments of kik_dl_open(). 2003-04-10 Seiichi SATO * mkf/lib/Makefile.in, contrib/scrollbar/extra/Makefile.in, contrib/tool/mlterm-menu/Makefile.in, kiklib/src/Makefile.in, kiklib/src/kik_dlfcn.c, mlterm/Makefile.in, scrollbar/sample/Makefile.in, tool/mlclient/Makefile.in, tool/mlconfig/Makefile.in, xwindow/Makefile.in, xwindow/x_sb_view_factory.c: - To compile DLL on Cygwin environment, added "-no-undefined" to libtool option. - Added ".exe" suffix in "clean" target in Makefile. - In case of Cygwin, the dynamic library name is "cygfoo.dll". It's supported now. (Thanks to Sakai Masahiro san) NOTE: To compile mlterm with DLL support on Cygwin, recent libtool is recommended. (--with-libtool=/usr/autotool/devel/bin/libtool) 2003-04-06 Tomohiro KUBOTA * kiklib/src/kik_conf_io.c kik_conf_write_open(): Could not create config file, which caused [save&exit] button of mlconfig could not save config if ~/.mlterm/main didn't exist. * man/mlterm.1 and tool/mlconfig/mc_char_encoding.c: added "cp1251" and "cp1255". 2003-04-06 Araki Ken * Added "cp1251" and "cp1255" encodings. 2003-04-06 Araki Ken * The message mlclient -P outputs is easier to understand. 2003-04-05 Tomohiro KUBOTA * Clean up mlterm/ml_vt100_parser.c config_protocol_save(), removed a possibility of free(NULL). 2003-04-02 MINAMI Hirokazu * xwindow/x_imagelib_gdk.c: fixed another color conversion bug... 2003-04-01 MINAMI Hirokazu * xwindow/x_imagelib_gdk.c: - last change caused a X error. reverted. - fixed a bug in color conversion. 2003-04-01 Tomohiro KUBOTA * tool/mlconfig/mc_char_encoding.c: mlconfig supports "GEORGIAN-PS" and "KOI8-T". * tool/mlconfig/main.c: write in the label that "font larger" and "font smaller" doesn't modify (save) configuration files. * Updated "po" (gettext) files for the above modification. * man/mlterm.1: mentions these two encodings and "-%" and "-$" options. 2003-03-31 MINAMI Hirokazu * xwindow/x_imagelib_gdk.c: minor code cleanup. 2003-03-30 Araki Ken * Added "georgian-ps" and "koi8-t" encodings. 2003-03-30 Tomohiro KUBOTA * A patch contributed by Mike Fabian to fix unstability in 64 bit platforms, by changing "0" into "NULL". * $(SYSCONFDIR)/mlterm/menu was not read even when $(HOME)/.mlterm/menu isn't available. Fixed. 2003-03-29 Araki Ken * Output cvs revision of ChangeLog by mlterm -v. 2003-03-28 Araki Ken * If a shell exited in a screen, the screen could be closed even if other background ptys left. Fixed. 2003-03-26 Araki Ken * Mlterm died as soon as the shell exited while screen region being selected. Fixed. 2003-03-26 Tomohiro KUBOTA * Updated tool/mlconfig/po/de.po (Thanks to Mike Fabian). 2003-03-25 Tomohiro KUBOTA * Fixed a bug that non-listed colors are not available. (This bug was due to 2003-02-21's oversimplification.) 2003-03-24 Araki Ken * Added -%/--class/app_class option. Fixed the behavior of 'title' and 'name' option. (Thanks to >>283) 2003-03-21 Tomohiro KUBOTA * tool/mlconfig/mc_color.[ch] simplification. * Color names are now translatable in mlconfig. * Japanese translation of above new translatable items. * Encoding change in tool/mlconfig/po/ja.po from UTF-8 to EUC-JP for easier editing. 2003-03-20 MINAMI Hirokazu * fixed a pixmap cache corruption bug with gdk-pixbuf (Thanks to Kato san and Kubota san) 2003-03-19 Tomohiro KUBOTA * mlconfig to have "save&exit", "apply&exit", "apply", and "cancel" buttons instead of "OK", "apply", and "cancel" buttons. (Thanks to "Nanashi"-san.) * Updated "po" (gettext) files for the above modification. 2003-03-16 Tomohiro KUBOTA * mlconfig shows window title of each ptys in pty list. 2003-03-15 Tomohiro KUBOTA * "configure --with-tools --with-scrollbars" didn't compile any tools nor scroll bars. Now it compiles all tools and scroll bars. 2003-03-15 Araki Ken * Changed doc/en/PROTOCOL format. /dev/... can be specified before key(=value) now. * Forbidden config protocol 5380 because of security issues. 2003-03-10 Araki Ken * Added --with-tools,--with-scrollbars options. 2003-03-09 Araki Ken * -M/--menu option was bound to conf_menu_path_1 previously, but is to conf_menu_path_3 now. 2003-03-08 Araki Ken * Removed --with-conf-menu option. * Added conf_menu_path_1,conf_menu_path_2,conf_menu_path3 options. * Ctrl+Left button launches mlterm-menu by default. 2003-03-08 Tomohiro KUBOTA * "wall_picture = none" in "main" configuration file now means that the user doesn't use wall picture. Previously, the same configuration caused that mlterm complains "wall picture file none is not found." (xwindow/x_term_manager.c, xwindow/x_screen.c) * mlconfig could not output the filename of the selected wall paper, fixed (tool/mlconfig/x_wall_pic.[ch]). This bug might be introduced in 2003-03-01 and is my fault. * Cleaning up tool/mlconfig/mc_bgtype.c, using integer value to store background type instead of string. 2003-03-08 Araki Ken * Added --with-conf-menu option. * If Ctrl+F1 pressed continuously on FreeBSD, mlterm died. Fixed. (Thanks to Konosuke Watanabe san) 2003-03-05 Tomohiro KUBOTA * The default BEL mode is "sound", not "none", at the help message. 2003-03-04 Tomohiro KUBOTA * mlconfig outputs "wall_picture = none" when background type is transparent. * Added comments for "encoding" items of mlconfig and make these comments and "auto" translatable. * Japanese translation of these translatable items. 2003-03-02 Araki Ken * grantpt() could behave unexpectedly because SIGCHLD installed when grantpt() execed. Fixed. 2003-03-02 Tomohiro KUBOTA * Added "New PTY" button for mlconfig. 2003-03-02 MINAMI Hirokazu * Code cleanup in the gdk-pixbuf module. (gave up "correct" color conversion scheme for the sake of simplicity) 2003-03-02 Araki Ken * Removed is_active[] array in ml_term_manager.c, and each ml_term_t has is_attached flag. 2003-03-02 MINAMI Hirokazu * fixed a pixmap cache corruption with gdk-pixbuf (Thanks to Sato san and Kubota san) 2003-03-02 Araki Ken * The point where column width changed is regarded as the boundary of words. (Now character set is not considered when the boundary of words is searched.) 2003-03-02 Araki Ken * Unswitchable ptys were shown in PTY List of mlconfig. Fixed. 2003-03-02 Tomohiro KUBOTA * Forgot to define N_() in addition to _() in common/c_intl.h . Thanks to Sakamoto Hironori san. 2003-03-02 Araki Ken * Characters whose character sets are the same alone are regarded as one word. 2003-03-02 Araki Ken * If ENCODING option not set, character encoding wasn't detected automatically. Fixed. (Thanks to Kubota Tomohiro san) 2003-03-02 Tomohiro KUBOTA * Fixed tools/mlconfig/mc_flags.[ch] and tools/mlconfig/po/POTFILES.in to enable translation (gettextization) of labels which are handled in mc_flags.[ch] . * Updated po files in tools/mlconfig/po . 2003-03-02 Araki Ken * If Backspace -> 0-9 or space pressed continuously, backspace was output twice in some environment. Fixed. 2003-03-02 Araki Ken * Added -$/--mc/click_interval option. * Updated libtool to 1.4.3. 2003-03-02 Araki Ken * Mlterm/mlclient hung up if mlclient execed with no options. Fixed. (Thanks to Nakada Nobuyoshi san) 2003-03-02 Seiichi SATO * When the font size is dynamically changed, Enlightenment and FVWM2 make an error in the calculation for window size (WMHints). Fixed. (Thanks to Sakamoto Hironori san) 2003-03-02 Araki Ken * Added PREV_PTY shortcut. (Thanks to Minami Hirokazu san) 2003-03-01 Araki Ken * Mlconfig writes changed configs alone to ~/.mlterm/main. (Thanks to Kubota Tomohiro san) * Revived conf_menu_path option. (Thanks to Nakada Nobuyoshi san) * Mlterm follows the change of _XROOTPMAP_ID. (Thanks to Minami Hirokazu san) * "encoding" of mlterm configuration protocol accepts "auto". * Mlclient supports quoted string as arguments. * Each pty has its own window/icon title name. (Thanks to Nanashi san) 2003-03-01 Tomohiro KUBOTA * Changed the way how to choose pty in mlconfig from button array to combobox, in order to avoid extremely wide mlconfig window when many ptys are opened. 2003-02-27 Tomohiro KUBOTA * Added mc_flush() for buttons of font larger/smaller, full reset, and pty select for mlconfig, so that the change of the configuration is immediately accepted. 2003-02-23 MINAMI Hirokazu * REALLY fix the caching bug. 2003-02-23 MINAMI Hirokazu * Modifications to the background image were not applied when the wallpaper had been changed. (Thanks to KATO Kazuyoshi san) 2003-02-18 Seiichi SATO * mlclient failed to connect to the server. Fixed. (Thanks to Nanashi san) 2003-02-16 Araki Ken * Mlconfig couldn't apply configuration changes more than once. Fixed. 2003-02-16 Tomohiro KUBOTA * Update manpage (man/mlterm.1) for -0/-9/-@ options. * Update manpage for OK/Apply/Cancel buttons and PTY List of mlconfig. 2003-02-15 Araki Ken * Terminals with Arabic,ISCII,vertical writing etc options can be switched by NEXT_PTY in the same Window. 2003-02-15 Araki Ken * Tuned up mlconfig. 2003-02-15 Araki Ken * '\n','\t','\e' special characters can be specified in the value of init_str option. 2003-02-15 Araki Ken * Added -#/--initstr/init_str option. The string specified as this option's value is initially sent to pty. * Renamed mlclient prefix option "pty_list" to "-P" / "--ptylist". * If -e option is specified after "mlterm /dev/...", the command string following "-e" is sent to the specified "/dev/..." pty. 2003-02-15 Araki Ken * Mlconfig didn't deal with ISO8859-11(TIS620) correctly. Fixed. * Mlterm exit(1) if us ascii for the specified encoding not found. 2003-02-12 MINAMI Hirokazu * Added a cache to x_imagelib_load_file in x_imagelib_gdk.c so that the last used image can be re-generated without reading from the image file again. (for Seiichi SATO san) 2003-2-11 Araki Ken * Mlterm died as soon as the pty in the last window closed even if other background ptys exist. Fixed. (Thanks to Nanashi san) 2003-2-11 Araki Ken * Backscroll mode is automatically exitted if screen is scrolled to the bottom. (Thanks to Murase Masaki san) * Mlconfig appears in the correct display even if it is called from the window whose display is different from the default. (Thanks to Minami Hirokazu san and Nakada Nobuyoshi san) 2003-2-11 Araki Ken * mlclient wouldn't die until the new window which mlclient created dies. Fixed. (Thanks to Nanashi san) 2003-2-11 Araki Ken * mlclient accepts "pty_list" and "/dev/..." as the 1st argument. If "pty_list" is specified, mlclient outputs pty lists which are opened. If "/dev/..." is specified, a new window is opened with the specified pty. 2003-2-11 Araki Ken * Renamed -P/--ptys/ptys option to -@/--screens/startup_screens, and added -P/--ptys/startup_ptys option. * Added ESC [ 5379 ; select_pty = ; BEL and ESC [ 5380 ; pty_list = ; BEL * Added PTY selection menu to mlconfig. 2003-2-9 Araki Ken * Added zh_TW locale messages to mlconfig. (Thanks to Yaun-Chen Cheng) 2003-2-9 Araki Ken * If you pressed 'U' and 'Z' with arabic kbd, nothing output. Fixed. 2003-2-8 Araki Ken * mlconfig saves configurations in ~/.mlterm/main if OK button pressed. 2003-2-5 MINAMI Hirokazu * Added support for depth 8 PseudoColor in gdkpixbuf image processing module. 2003-2-3 Araki Ken * Fixed a bug of cursor fg/bg colors. * Fixed arguments of ml_iscii_new_lang(). (Thanks to Sakamoto Hironori san) 2003-2-2 Araki Ken * Added -9/--crfg/cursor_fg_color,-0/--crbg/cursor_bg_color options. These options specify foreground/background colors of the cursor. If not specified, cursor fg color is default bg color, and vice versa. 2003-2-2 Seiichi SATO * Fixed a bug in alloc_closest_xcolor_pseudo(). (diff_r -> diff_b) (Thanks to Hirokazu Minami san) 2003-2-2 Araki Ken * Added EXT_KBD shortcut in ~/.mlterm/key. This shortcut activate or deactivate arabic or iscii input method. 2003-2-2 Araki Ken * Added --without-map-table,--without-prop-table options to configure. These options remove character mapping table and character property table. 2003-2-1 Araki Ken * Even if log buffer is full, static backscrolling works. (Thanks to Murase Masaki san) * Renamed x_keymap to x_shortcut. 2003-1-27 Araki Ken * Mouse position reporting is enabled, selecting region is forced to stop. 2003-1-26 Araki Ken * Each user can start his/her own mlterm server. (Thanks to Nakda Nobuyoshi san) 2003-1-26 MINAMI hirokazu * Fixed a bug in gdk-pixbuf module which prevents gamma correction with pseudo-transparency (Thanks to TAKAHASHI Tamotsu san) * Rewrited cache mechanism of background pictures for performance. 2003-1-26 Araki Ken * Added -6/--stbs/static_backscroll_mode option, under which backscroll mode isn't reset even if vt100 sequence is output from tty. * You can select region even while vt100 sequence is output from tty. 2003-1-13 Araki Ken * config.h.in -> c_config.h.in 2003-1-13 Araki Ken * ml_intl.h -> c_intl.h 2003-1-12 Araki Ken * Multiple 'key=value' pairs separated by ';' can be specified in "ESC ] 5379 ; .... BEL". * Newly added "ESC ] 5382 ; ... BEL sequence" and "ESC ] 5383 ; ... BEL sequence". The former sequence saves specified key and value pairs in ~/.mlterm/main, and the latter one sets and saves them at the same time. 2003-1-12 Araki Ken * Cleaned up codes around arabic shaping. * Merged gettextize patch. (Thanks to Mike Fabian and Koushi Takahashi san) 2003-1-12 Araki Ken * 2.6.3 released. (rel-2_6_3) 2002-12-16 Seiichi SATO * Applied Minami-san's Xft2 support patch. 2002-12-15 Araki Ken * 2002-12-14 fix was incomplete, that is, copy&paste in the same window failed. fixed. (Thanks to Martin Horcicka) 2002-12-14 Araki Ken * Newline characters in pasted text are converted to carriage return characters. (Thanks to Martin Horcicka) 2002-12-13 Araki Ken * Fixed arabic combining problem. (Thanks to Nadim Shaikli) 2002-12-13 Araki Ken * Fixed a bug in ml_line_fill(). (Thanks to Sato Seiichi san) 2002-12-10 Araki Ken * Fixed cursor highlight problem. (Thanks to Martin Horcicka) * Added doc/en/FAQ. (Thanks to Nadim Shaikli) 2002-12-6 Araki Ken * utemper wasn't checked correctly in configure. fixed. (Thanks to Mike Fabian) * dead key and multi key didn't work. fixed. (Thanks to Martin Horcicka) 2002-11-26 Araki Ken * Improved kik_map. 2002-11-21 Araki Ken * ml_cursor_t::col_in_char was wrong in some situations. fixed. (Thanks to Wang WenRui) 2002-11-16 Araki Ken * Added mkf_utf16_conv.[ch] which generates UTF16 sequence. 2002-11-16 Araki Ken * Added mkf_utf16_parser.[ch] which parses UTF16 sequence. 2002-11-15 MINAMI Hirokazu * added support for some lazy WM which does only set a part of root image as _XROOTPMAP_ID. (Thanks to Wang WenRui) 2002-11-14 Araki Ken * screen->xct_parser->is_eos is replaced by parser->is_eos in x_screen.c:key_pressed(). (Thanks to Minami Hirokazu san) 2002-11-13 MINAMI Hirokazu * In XDND, drop via UCS2 (as "text/unicode") is supported. 2002-11-12 MINAMI Hirokazu * XDND code cleanup/separation. added x_dnd.(c|h) . 2002-11-11 Seiichi SATO * Updated config.guess and config.sub.(timestamp='2002-11-08') (Thanks to Kubota Tomohiro san) 2002-11-08 MINAMI Hirokazu * Rewrited XDND processiong code. - INCR (incremantal transfer of huge data) is supported. - cleaned up a bit for future separation. 2002-11-07 Araki Ken * Default screen size is 80x24 instead of 80x30. (Thanks to Sato Seiichi san) * Performance tuning of ml_edit.c. 2002-11-06 MINAMI Hirokazu * GBK parser became more robust againt invalid input. (Thanks to Wang WenRui) 2002-11-04 MINAMI Hirokazu * UTF8_STRING and COMPOUND_TEXT are now accepted as XDND's mime type. 2002-10-16 MINAMI Hirokazu * Major rewrite of x_imagelib_gdk.c. Now it's only depends on gdk-pixbuf and not gdk-pixbuf-xlib. 2002-10-11 Araki Ken * Transparency failed in some situations. fixed. (Thanks to Nanashi san) * ml_line_fill() has a buffer overflow bug. fixed. 2002-10-08 Araki Ken * 2.6.2 released (rel-2_6_2) 2002-10-07 Araki Ken * There was some interval between the time when Focus events available and when window really mapped. fixed. (Thanks to Nanashi san) 2002-10-06 Araki Ken * Fixed a bug in deleting multi-byte characters by ESC [ P. 2002-10-06 Araki Ken * ESC [ x sequence is supported. 2002-10-06 Araki Ken * 2002-10-02 fix is discarded. Scrollbar gets never smaller than the maximum possible height / 20. (Thanks to Murase Masaki san) 2002-10-06 Araki Ken * ESC [ S, ESC [ T sequences are supported. 2002-10-06 Araki Ken * If screen was resized too small, it disappeared once, but resized smaller, it appeared again drawn corruptly. fixed. 2002-10-06 Araki Ken * copy_paste_via_ucs option is renamed to receive_string_via_ucs. And if its value is true, strings from XIM as well as from X Selection are converted to UCS once. * Even if the value of fade_ratio option was 100, screen was completely redrawn when window focus is switched. fixed. 2002-10-05 Araki Ken * Cleaned up size hint patch(see 2002-08-29) by Sato Seiichi san. * If window height was for only one line, where wraparound happened, mlterm died. fixed. 2002-10-02 Araki Ken * If line characters and RTL characters mixed in a line, screen corrupt. Fixed a little. (Thanks to Nadim Shaikli) 2002-10-02 Araki Ken * Scrollbar never get too small even if the value of 'logsize' option is huge. 2002-10-01 Araki Ken * If more than 512 bytes were copy&pasted within a window, the 513th byte was lost. fixed. (Thanks to Nanashi san) 2002-09-29 Araki Ken * Character encoding parser is reset by ESC c sequence. (Thanks to Murase Masaki san) 2002-09-29 Araki Ken * ESC [ I and ESC [ Z sequences are supported. 2002-09-28 Araki Ken * If cursor was placed at a half-width char preceded by a full-width char and the full-width char was deleted by "ESC [ 2 P", the half-width char was also deleted. fixed. (Thanks to Hideki EIRAKU san) 2002-09-28 Araki Ken * "Full reset" button of mlconfig didn't work. fixed. (Thanks to Murase Masaki san) 2002-09-28 Seiichi SATO * x_window_get_visible_geometry() returned width and height of no visible window. fiexd. 2002-09-27 Araki Ken * GDK_PIXBUF_CFLAGS and IMILB_CFLAGS are renamed to IMAGELIB_CFLAGS in tool/mlconfig/Makefile.in. (Thanks to Muto Kenshi san) 2002-09-27 Araki Ken * The last character of a wraparound line was not deleted by BS + ' '. fixed. 2002-09-27 Araki Ken * x_imagelib_*.o linked directly, not via x_imagelib.o. (Thanks to Nobuyoshi Nakada san) 2002-09-20 Nobuyoshi Nakada * kiklib: link kik_pty_*.o and kik_utmp_*.o directly, not via kik_pty.o and kik_utmp.o. 2002-09-17 MINAMI Hirokazu * Renamed x_picdep_* to x_imagelib_* * When image has alpha channel, wallpapers can be patially translucent with gdk-pixbuf imagelib module. (unfinished and not updated poperly yet ...) 2002-09-16 Seiichi SATO * Cleaned up to get rid of compiler warning messages with gcc. 2002-09-16 MINAMI Hirokazu * Major rewrite of icon handling - Added new members (icon and mask) to struct x_window_t - Actuall icon setting process is now done in x_window.c. - remove icon cache from x_picture_gdk which seems not to be useful. 2002-09-15 MINAMI Hirokazu * x_picdep_load_icon( &data,&pixmap,&mask) is added in gdk-pixbuf module. 2002-09-15 Araki Ken * If cursor is located at the second byte of a multi-byte character, cursor moves strangely, when bce is enabled. fixed. 2002-09-12 Araki Ken * 2.6.1 released (tag "rel-2_6_1") 2002-09-12 Araki Ken * The right-end column was not drawn correctly under anti-alias mode. fixed. (Thanks to Sato Seiichi san) * INCDIR macro was wrong. fixed. (Thanks to Nakada Nobuyoshi asn) 2002-09-08 Araki Ken * Screen of logged lines which contains multi byte characters got corrupt. fixed. * Tanween characters were ignored when arabic characters shaped. fixed. * Added doc/ja/README.confapp. 2002-09-08 Seiichi SATO * Added mlterm-icon-24colors-[12].png for low color depth. 2002-09-08 Araki Ken * OPEN_PTY and OPEN_SCREEN shortcut keys were confused. fixed. * mkf_charset_t variable was passed to usascii_font_cs_changed() in x_screen_attach(). fixed. * Added --with-imagelib option to mlterm/configure(.in) and removed --enable-imlib, --enable-gdk-pixbuf. 2002-09-07 Araki Ken * 2.6.0 released (tag "rel-2_6_0") 2002-09-07 Araki Ken * Added --with-imagelib=[imlib,gdk-pixbuf1,gdk-pixbuf2] Removed --enable-imlib, --enable-gdk-pixbuf (Thanks to Sato Seiichi san) * USPosition bit is set in XSizeHints.flags. (Minami Hirokazu san) 2002-09-07 MINAMI Hirokazu * mlterm.tc is now non-shrinked version. It's more accurate but may not compiled. Please modify it to fit <1K . 2002-09-06 MINAMI Hirokazu * Added mlterm.ti and mlterm.tc under doc/term/ . 2002-09-06 MINAMI Hirokazu * Mlterm's default behabior is changed as following - mod_meta_mode is 8bit - kD (sequence for DELETE) is \E[3~ - kb (sequence for BS) is ^? - kh (sequence for HOME) is \EOH - @7 (sequence for END) is \EOF 2002-09-05 Araki Ken * Screen gets disordered when new line inserted. fixed. (Thanks to Takahashi Tamotsu san, Sato Seiichi san) 2002-09-04 Araki Ken * cursor moved to the end of line under insert mode. fixed. (Thanks to Nobuyoshi Nakada san) 2002-09-04 Araki Ken * String pointed by icon_path in x_term_manager.c is leaked. fixed. * doc/en/History is updated. 2002-09-04 MINAMI Hirokazu * Added documentation of HOME/END support in README.ja and manpage. 2002-09-03 Seiichi SATO * The icons designed for various desktop environments / window managers, such as GNOME, KDE, Window Maker, FVWM and twm, are added. (contrib/icon/*.png) 2002-09-03 Araki Ken * Even if imlib used, screen gets darker as gamma value greater like gdk-pixbuf. (Thanks to Nobuyoshi Nakada san) * Documentation around OPEN_SCREEN,OPEN_PTY updated. 2002-09-03 Araki Ken * ml_edit* module cleaned up. * some warnings in x_term_manager.c and x_window.c are suppressed. 2002-09-02 MINAMI Hirokazu * segmantation fault when no font is available for specified CS. Inplemented woraround(fallback to old codeset) 2002-08-30 MINAMI Hirokazu * Updated documents. 2002-08-30 MINAMI Hirokazu * initialize struct termios by zero because setting random values may cause unexpectable results. 2002-08-29 Seiichi SATO * Fixed incorrect size hints. 2002-08-29 MINAMI Hirokazu * Fixed possible access violation. 2002-08-29 MINAMI Hirokazu * Plugged small memory leak. 2002-08-28 MINAMI Hirokazu * Generalized XDND support. "text/uri-list" is now also accepted. 2002-08-28 MINAMI Hirokazu * emulate ANSY.SYS's save/restore cursor. (Thanks to Wang WenRui) 2002-08-28 MINAMI Hirokazu * Window icon support is added (require --enable-gdk-pixbuf). 2002-08-28 MINAMI Hirokazu * Compilation failed on Linux glibc 2.1.x because of incomplete langinfo.h. Built-in (dummy) kik_langinfo is now used when CODESET is not defined. (Thanks to Kubota Tomohiro san) * background picture was not drawn when pseudo transparency had been turned off. fixed. * winsize structure were not fully initialized during pty setup. fixed. (Thanks to Nanashi san) * Fixed typos in Changelog. 2002-08-09 MINAMI Hirokazu * Corrected path for gdk-pixbuf headers. * Gtk2's libs are now used by preference when gdk-pixbuf support is enabled. 2002-08-02 Araki Ken * 2002-07-29 (*) problem not still fixed. (Thanks to Minami Hirokazu san) 2002-07-29 Araki Ken * If bce enabled in termcap config, mlterm hung up when multi-byte characters were shown in screen. fixed. (*) * NEW_PTY short cut key is renamed to OPEN_SCREEN. * OPEN_PTY option is added. 2002-07-15 Tomohiro KUBOTA * Update background/wall_picture/transparent handling in mlconfig. 2002-07-07 Tomohiro KUBOTA * Update manpage for -M/-3/-4 command options. * Update mlconfig to support Wallpaper contrast and gamma. 2002-07-05 MINAMI Hirokazu * Code cleanup (xwindow/x_picture_gdk.c). - results of pow() are now cached. - old transparency code is dropped. 2002-07-04 MINAMI Hirokazu * Enabled command-line option for contrast/gamma when configured with gdk-pixbuf. (Thanks to IWAMOTO Toshihiro san) 2002-07-03 MINAMI Hirokazu * Added contrast/gamma support to gdk-pixbuf module. 2002-07-04 Araki Ken * -3/--contrast,-4/--gamma options are added. (Thanks to IWAMOTO Toshihiro san and Nakada Nobuyoshi san) * the last character of each line cannot be selected by mouse. fixed. 2002-07-03 MINAMI Hirokazu * HOME/END key support is added. 2002-07-02 MINAMI Hirokazu * Minor code cleanup (xwindow/x_decsp_font.c). 2002-07-01 MINAMI Hirokazu * Background of line characters did not drawn when pseudo transparency is enabled. fixed. (Thanks to Tomohiro KUBOTA san) 2002-06-30 MINAMI Hirokazu * Optimized drawing of line chars. 2002-06-29 Araki Ken * -K,--metakey=[mod1-mod5,meta,alt,super,hyper] option is added. This option works the same as rxvt's -mod option. 2002-06-29 Araki Ken * Background of line characters can be transparent when -Y option is specified. 2002-06-28 MINAMI Hirokazu * XDnD session was not terminated properly. fixed. 2002-06-25 Araki Ken * XDnD is supported. (Thanks to Minami Hirokazu san) 2002-06-23 Araki Ken * the style of selecting characters in RTL lines is improved. 2002-06-19 Tomohiro KUBOTA * A debug message was displayed by mlconfig even if compiled without DEBUG option; fixed. (Thanks to MINAMI Hirokazu san) 2002-06-16 Araki Ken * 2.5.0 is released. 2002-06-16 Araki Ken * mlterm died if -Y option is specified with -A, -t or -P. fixed. (Thanks to Minami Hirokazu san) 2002-06-15 Araki Ken * if -E iscii was specified, mlterm died. fixed. * shaped characters were not shown correctly. fixed. 2002-06-14 Araki Ken * w3mmlconfig is updated. * compilation never fails if --enable-utmp option is specified on Cygwin. (Thanks to Sato Seiichi san) 2002-06-13 Araki Ken * If use_dynamic_comb option was dynamically changed over twice, RTL lines were shown correctly and even worse mlterm died. fixed. 2002-06-12 MINAMI Hirokazu * mlcc (new console based config tool) is added. 2002-06-12 Araki Ken * "rows" and "cols" are added to ESC ] 5380 configuration protocol. 2002-06-11 Tomohiro KUBOTA * XIM server could not be changed by using mlconfig; fixed. * manpage update for mlconfig. * a new sample color configuration file. 2002-06-09 Araki Ken * All characters in line were redrawn if it is modified even a little. fixed. 2002-06-08 Araki Ken * Garbage could be left on the right side of screen. (specially when ut is defined in termcap) fixed. * "ESC [ Ps X VT100" sequence is supported. 2002-06-08 Tomohiro KUBOTA * Removed command options from mlconfig which are not needed any more. 2002-06-06 Araki Ken * -K/--maxptys option is removed. * Logged lines are not faded when screen is not focused. * If 0 is specified as value of -sl option, mlterm died. fixed. 2002-06-05 Tomohiro KUBOTA * renewal of mlconfig. 2002-06-04 Araki Ken * mlterm version number is set as the value of "MLTERM" environmental variable. 2002-06-04 Tomohiro KUBOTA * Widgets for anti-alias and variable-font-width were not displayed in mlconfig, fixed. 2002-06-03 Araki Ken * mlconfig path didn't reflect configure prefix. fixed. * w3mmlconfig is updated. (Thanks to Sakamoto Hironori san) 2002-06-03 Araki Ken * multi-column characters were not treated as multi-column in UTF-8 encoding. fixed. (Thanks to Sakamoto Hironori san) * If Control Mask is set, mouse position is not reported. (Thanks to Sakamoto Hironori san) * mlconfig and mlterm communicate through doc/en/PROTOCOL protocol. * mlconfig design is renewed. (Thanks to Kubota Tomohiro san) 2002-05-31 Tomohiro KUBOTA * rewrite manpage for 2002-05-30 changes. 2002-05-30 Araki Ken * string to be output can be defined in ~/.mlterm/key like Control+F1="foobar". * rgb of highlighted 8 colors can be defined as hl_{black|white|...} in ~/.mlterm/color. 2002-05-26 Tomohiro KUBOTA * rewrite help message ("mlterm --help"). * rewrite help message of ./configure script. 2002-05-20 Araki Ken * VPATH was wrong in mlterm/Makefile.in xwindow/Makefile.in. fixed. (Thanks to Nakada Nobuyoshi san) 2002-05-19 Seiichi SATO * x_color.c: alloc_closest_xcolor_pseudo() doesn't free the memory space pointed to by all_colors. fixed. 2002-05-19 Araki Ken * auto pointer was passed to putenv(). fixed. (Thanks to Nakada Nobuyoshi san) 2002-05-19 Araki Ken * display name specified by --display overwrites DISPLAY environment variable. 2002-05-19 Araki Ken * combining characters were not shown with both -bi and -m options. fixed. 2002-05-19 Araki Ken * Unicode characters except 0x00-0x7f could be shown incorrectly. fixed. 2002-05-19 Tomohiro KUBOTA * manpage update: explanations for -H, -J, -Q, -Z, and -q are vastly modified. Added a chapter of DAEMON MODE. Keys which are available only in -q mode are noted. * Added a new manpage of mlclient.1 . (man/Makefile.in is also modified to install this new page.) 2002-05-19 Araki Ken * DEC_SPECIAL characters were not shown with -Y,--decsp option. fixed. (Thanks to Kubota Tomohiro san) * "RRRRR-BBBBB-GGGG;" style is accepted in color config file for backward compatibility with 2.4.0 or before. (Thanks to Nanashi san) 2002-05-19 Araki Ken * a bug of shaping arabic combining characters is fixed. * scrollbar's height was incorrect when screen was revived. fixed. 2002-05-18 Araki Ken * compilation failed if ./configure is done with --disable-shared. fixed. (Thanks to Nadim Shaikli) 2002-05-17 Araki Ken * kik_pty_streams.c is improved. (Thanks to Nadim Shaikli) * When base direction is changed from RTL to LTR, garbage is left in screen. fixed. (Thanks to Nadim Shaikli) 2002-05-16 Araki Ken * core dump when illegal color name is specified for fg/bg color. fixed. 2002-05-16 Araki Ken * change of scrollbar foreground and background colors etc is not reflected immediately. fixed.(2002-05-14 fix was incomplete) * #RRGGBB format is accepted in "color" config file. * ECHOE and ECHOCTL are added to termios.c_lflag. (Thanks to Kitagawa Takurou san and Minami Hirokazu san) 2002-05-15 Araki Ken * Ctrl-H as well as backspace key invokes ML_BACKSPACE shortcut key. fixed. 2002-05-14 Araki Ken * change of fade ratio, fg color and bg color was not reflected immediately. fixed. * fg color and bg color are not highlighted by "\E[1m". 2002-05-14 Araki Ken * vt100 core functions and GUI(x window system) functions are separated. (vt100 core functions doesn't depend on any UI) 2002-05-09 MINAMI Hirokazu * utmp entry may be left unterminated when login() is used. fixed. 2002-05-07 MINAMI Hirokazu * stopped dithering for root pixmap which should be already dithered/quantized. (src/ml_picture_gdk.c) 2002-05-05 MINAMI Hirokazu * dithering support for PseudoColor (src/ml_picture_gdk.c). 2002-05-04 Seiichi SATO * Added a mechanism to find the closest color when visual class is PseudoColor or GrayScale. (src/ml_color.c) 2002-05-02 Seiichi SATO * Fixed segfault when destroying a scrollbar in PseudoColor visual. (Thanks to Minami Hirokazu san) 2002-05-01 Tomohiro KUBOTA * manpage update: termcap file and -y option. 2002-04-30 Araki Ken * etc/termcap format is changed and it is possible to define entries for multiple terminals. * ut field(a.k.a bce in terminfo) is added to etc/termcap and --bce option is removed. * -ldl is linked to libkik.so. 2002-04-29 MINAMI Hirokazu * Added documentations for background picture processing. (doc/*/README.picdep) 2002-04-28 Tomohiro KUBOTA * Fixed several typos in the manpage. * Explanation on "-1" command option in more detail in the manpage. 2002-04-28 Araki Ken * underline can be left as garbage on screen if line space is odd number(1,3,5...). fixed. * configure fails with --with-libtool option. fixed. (Thanks to Nakada Nobuyoshi san) 2002-04-27 Araki Ken * kik_utmp_sysv.c patch is merged. (Thanks to Nadim Shaikli) 2002-04-27 Araki Ken * ml_term_model_t is dynamically plugged in ml_term_screen_t from outside, instead of being internally created. * ml_sb_view_factory manages reference counter of each library so as not to unload a library which is used by other terminals. (Thanks to Sato Seiichi san) 2002-04-27 Araki Ken * -3,--bce,use_bce=(true|false) option which enables or disables BCE support is added. 2002-04-26 Seiichi SATO * Added stuff for new scrollbar libraries to configure script. 2002-04-26 Tomohiro KUBOTA * The manpage now mentions Sato-san's new scrollbar libraries. * Added whitespace after commas and before open parentheses in the manpage. 2002-04-25 Tomohiro KUBOTA * "mlterm -Y" sometimes segfaulted, fixed. * Line-drawing characters in "mlterm -Y" had a gap, fixed. 2002-04-24 Tomohiro KUBOTA * Added a note on older changelog information to this file. 2002-04-23 Araki Ken * if ${srcdir} is absolute path, configure fails. fixed. 2002-04-23 Araki Ken * "configure ; make ; make install" process is possible in any directories other than mlterm source directory. (Thanks to Nobuyoshi Nakada san) * Please read doc/en/ChangeLog.old for previous changelog information. (This term was written by Tomohiro KUBOTA in 2002-04-24.) $Id$ mlterm-3.9.3/LICENCE000066400000000000000000000031121441203364000140050ustar00rootroot00000000000000Copyright (c) Araki Ken(arakiken@users.sourceforge.net) Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. The name of any author may not be used to endorse or promote products derived from this software without their specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Note: files in contrib/, inputmethod/, win32/plink and vtemu/libptymosh/ directories are contributed files and they have their own licenses. Please respect the licenses. mlterm-3.9.3/Makefile.in000066400000000000000000000036561441203364000151020ustar00rootroot00000000000000MAKE_DIRS=@MAKE_DIRS2@ all .DEFAULT: # "cd baselib" and "cd encodefilter" must be enclosed by () because it may not return # to the $(top_builddir) at the next line. if [ -f baselib/Makefile ]; then (cd baselib ; $(MAKE) $@) ; fi if [ -f encodefilter/Makefile ]; then (cd encodefilter ; $(MAKE) $@) ; fi (for dir in $(MAKE_DIRS) ; do (cd $${dir} ; $(MAKE) $@) || exit $? ; done) && \ if test "$@" != "clean" ; then touch BUILD_SUCCESS ; else rm -f BUILD_SUCCESS ; fi BUILD_SUCCESS: Makefile $(MAKE) all install: BUILD_SUCCESS if [ -f baselib/Makefile ]; then (cd baselib ; $(MAKE) install-la) ; fi if [ -f encodefilter/Makefile ]; then (cd encodefilter ; $(MAKE) install-la) ; fi for dir in $(MAKE_DIRS) ; do (cd $${dir} ; $(MAKE) $@) || exit $? ; done install-fb: BUILD_SUCCESS for dir in main vtemu `find inputmethod -name Makefile|sed 's/\/Makefile//'` ; \ do (cd $${dir} ; $(MAKE) install) || exit $? ; done install-wl: BUILD_SUCCESS for dir in main vtemu `find inputmethod -name Makefile|sed 's/\/Makefile//'` ; \ do (cd $${dir} ; $(MAKE) install) || exit $? ; done install-sdl2: BUILD_SUCCESS for dir in main vtemu uitoolkit/libotl `find inputmethod -name Makefile|sed 's/\/Makefile//'` ; \ do (cd $${dir} ; $(MAKE) install) || exit $? ; done vte: (cd gtk; $(MAKE)) install-vte: (cd gtk; $(MAKE) install) clean-vte: (cd gtk; $(MAKE) clean) vterm: (cd libvterm; $(MAKE)) install-vterm: (cd libvterm; $(MAKE) install) clean-vterm: (cd libvterm; $(MAKE) clean) distclean: if [ -f baselib/Makefile ]; then (cd baselib ; $(MAKE) $@) ; fi if [ -f encodefilter/Makefile ]; then (cd encodefilter ; $(MAKE) $@) ; fi if [ -f gtk/Makefile ]; then (cd gtk ; $(MAKE) $@) ; fi for dir in $(MAKE_DIRS) java ; do (cd $${dir} ; $(MAKE) $@) || exit $? ; done rm -rf gui rm -f config.log config.cache config.status libtool Makefile \ common/c_config.h common/stamp-h1 BUILD_SUCCESS tags: find . -name "*.[ch]" | xargs etags test: mlterm-3.9.3/README000066400000000000000000000224061441203364000137070ustar00rootroot00000000000000MLTERM - Multi Lingual TERMinal emulator COMPILATION =========== $ ./configure $ make Options for configure --------------------- --prefix Installation prefix --disable-dl-table Disable dynamic loading of character mapping or property table, which is statically linked to libmef. --without-map-table Remove character mapping table --without-prop-table Remove unicode character property table --with-iconv Use iconv to convert between different character sets. (If --with-iconv is specified, --disable-dl-table is the default.) --with-gui=(xlib|win32|fb|quartz|console|wayland|sdl2|beos) Use specified gui library See "Supported platforms" below. --with-imagelib=(gdk-pixbuf) Link specified image library to mlterm for image processing. Note that this option is not necessary for image processing, because 'mlimgloader' program (which is compiled with gdk-pixbuf if --with-tools=mlimgloader option is specified) can process images and pass them to mlterm. This option is recommended only if you build libvte which depends on gdk-pixbuf anyway. (Imlib is not supported since mlterm 3.0.2) --with-libltdl Load modules with libltdl --with-type-engines=(xcore|xft|cairo) Use specified type engines for rendering text. xcore is possible to disable only when --with-type-engines=(except xcore) is specified with --disable-dl-type option. --disable-anti-alias Same as --with-type-engines=xcore on xlib. (--enable-anti-alias is the same as --with-type-engines=xcore,xft,cairo) This option is ignored if --with-type-engines is specified on xlib. Disable truetype fonts on framebuffer or wayland. --disable-fontconfig Disable fontconfig (use ~/.mlterm/*aafont) on framebuffer or wayland. --disable-dl-type Disable dynamic loading of type engine modules, which are statically linked to mlterm. --disable-fribidi Disable BiDi rendering (see https://github.com/arakiken/mlterm/blob/master/doc/en/README.bidi) --disable-ind Use libind for Indic rendering (see https://github.com/arakiken/mlterm/blob/master/doc/en/README.indic) --disable-dl-ctl Disable dynamic loading of BiDi and Indic rendering modules, which are statically linked to mlterm. --disable-ssh2 Disable to connect ssh2 server. If enabled, libssh2 (https://www.libssh2.org) is used to connect ssh2 server. (Usage: mlterm(mlclient) --serv ssh://user@xxx.xxx.xxx) If you want to use camellia as common key cryptography or SSH agent forwarding, install alternative libssh2 of camellia-agentfwd branch at https://github.com/arakiken/libssh2/archive/camellia-agentfwd.zip (see https://github.com/arakiken/mlterm/blob/master/doc/en/README.ssh and https://github.com/arakiken/mlterm/blob/master/doc/en/README.transfer) --with-mosh=(mosh source directory) Enable mosh and specify its source directory, where ./configure script should be executed in advance. This option is available only if libssh2 is enabled. Don't distribute libptymosh in binary format. (see see https://github.com/arakiken/mlterm/blob/master/doc/en/README.mosh) --without-pthread Don't depend on pthread for secure copy (scp) over ssh. (Furthermore, don't link libpthread to mlterm in NetBSD even if --enable-ibus or --with-type-engines=cairo is specified.) --enable-debug Build debug version --enable-optimize-redrawing Optimize redrawing a line --with-scrollbars Build specified scrollbars in scrollbar/ and contrib/scrollbar/ directories --with-tools Build specified tools in tool/ and contrib/tool/ directories mlimgloader is necessary to show images if --with-imagelib option is not specified. registobmp is necessary to process ReGIS. --disable-use-tools Don't build and use external tools. If this option is specified, --with-tools option is ignored. --disable-dnd Disable XDnD --disable-kbd Disable kbd input method for Arabic, Hebrew and Indic --disable-iiimf Disaable IIIMF (Internet/Intranet Input Method Framework) --disable-uim Disable uim (Universal? Input Method) --disable-m17nlib Disable m17n library --disable-scim Disable SCIM (Smart Common Input Method platform) --disable-ibus Disable iBUS (Intelligent Input Bus) --disable-fcitx Disable Fcitx If Fcitx is enabled, fcitx-gclient or Fcitx5GClient is necessary. --disable-canna Disable Canna --disable-wnn Disable Freewnn --disable-skk Disable SKK --enable-pty-helper Support gnome-pty-helper. (Note that it is impossible to enable gnome-pty-helper in BSD style pty system and that gnome-pty-helper must be placed at ${libexecdir}/mlterm directory.) --with-gtk=(2.0|3.0|4.0) Use specified version of GTK+ (4.0 is available for mlconfig. libvte compatible library and mlterm-menu continue to need 2.0 or 3.0.) --enable-vt52 Support vt52 emulation --disable-image Disable wall picture, icon picture, pseudo transparency and sixel graphics. --disable-otl Disable Open Type Layout with the use of harfbuzz or libotf. --enable-brlapi Enable brltty with the use of brlapi library. (Experimental) (see https://github.com/arakiken/mlterm/blob/master/doc/en/README.brltty) --enable-utmp-suid Install mlterm binary with root setuid or utmp setgid to access to utmp database directly. The default is disabled. --with-utmp=(utempter|sysv|login|bsd|none) Specify the way of reading from or writing to utmp database. --disable-daemon Disable daemon mode --disable-split Disable to split screen except on MacOSX/Cocoa and HaikuOS. --disable-zmodem Disable zmodem (see https://github.com/arakiken/mlterm/blob/master/doc/en/README.transfer) --disable-compact-truecolor Disable to reuse 240 palettes in displaying true color. Disabling this option supports true color completely, but sizeof(vt_char_t) is changed from 8 bytes to 12 bytes. --disable-shared Disable shared libraries --disable-static Disable static libraries If you want to minimize mlterm binary, execute configure with following options. --without-map-table --without-prop-table --disable-image --disable-dl-ctl \ --disable-fribidi --disable-dl-type --disable-otl \ --disable-ssh2 --with-utmp=none --disable-dnd --disable-kbd --disable-uim \ --disable-m17nlib --disable-ibus --disable-fcitx --disable-scim --disable-canna \ --disable-wnn --disable-skk --disable-iiimf --disable-ind --with-type-engines=xcore \ --disable-anti-alias --disable-fontconfig --disable-daemon --disable-split \ --disable-zmodem (--disable-shared) What you need for compilation ----------------------------- All you need for basic compilation is libc and Xlib. You don't need internationalization support of OS because mlterm has own i18n code. XFree86 4.0.2 or above and FreeType 2.0.2 or above are needed for anti-alias. gdk-pixbuf (Gtk+ 2.0.1 or higher) for background image. Gtk+ (2.x ?) for GUI configurator "mlconfig" and "mlterm-menu". Gtk+ (2.x ?) for libvte compatible library. (see gtk/INSTALL) Fribidi (0.9.0 - ?) for Bidi. libssh2 (https://www.libssh2.org) for ssh2 client and scp. (If you want to use camellia as common key cryptography or SSH agent forwarding, install alternative libssh2 of camellia-agentfwd branch at https://github.com/arakiken/libssh2/archive/camellia-agentfwd.zip) Compilation of library based on mlterm ----------------------- vte compatible library $ make vte (see https://github.com/arakiken/mlterm/blob/master/gtk/README) libvterm compatible library $ make vterm (see https://github.com/arakiken/mlterm/blob/master/libvterm/README) Supported platforms ------------------- Platforms tested by developers. * NetBSD 3.0.1 / X (x86) * NetBSD teokure 9.0 / X, frmebuffer (x86) * NetBSD 5.2 / framebuffer (hpcmips) * NetBSD 9.0 / framebuffer (xm6g 3.31L15) * OpenSolaris 2009.06 / X (CC=cc) (x86) * Solaris 11.1 / X (x86) * Arch Linux / X, framebuffer, wayland, SDL2 (x86) * CentOS 5 / X (x86) * FreeBSD 9.0 / framebuffer (x86) * FreeBSD 2.2.9 / X (x86) * FreeBSD(98) 4.11 / framebuffer (np21w ver.0.86 rev.88) * OpenBSD 5.3 / framebuffer (x86) * MS Windows 10 + Cygwin 3.4.3 / GDI, SDL2 (CC=gcc, CC="i686-pc-mingw32-gcc") (x86_64) * MS Windows 10 + MSYS2 3.1.7 / GDI (x86) * MacOSX 10.6.8 / X, Cocoa, SDL2 (x86) * MacOSX 10.8.5 / X, Cocoa, SDL2 (x86) * iOS Simulator 4.3 / CocoaTouch (x86) * iOS Simulator 7.1 / CocoaTouch (x86) * Android 4.0 (x86) * Android 9.0 (x86) * Java 1.8.0 / SWT (x86) * Haiku R1 Beta4 / Interface Kit, SDL2 (x86) See README.fb, README.win32, README.android, README.cocoa, README.cocoatouch, README.console, README.wayland, README.sdl2 and README.beos in https://github.com/arakiken/mlterm/blob/master/doc/en and README in https://github.com/arakiken/mlterm/blob/master/java in detail. USAGE ===== $ mlterm Read the manpage (and documentations in mlterm-x.x.x/doc/{ja,en}) for detail. See ~/.mlterm/msg.log on error. CONTACT ======= Subscribe mlterm-dev-en ML (https://lists.sourceforge.net/lists/listinfo/mlterm-dev-en). COPYRIGHT AND LICENSE ===================== Modified BSD-style license. See LICENCE file for detail. mlterm-3.9.3/aclocal.m4000066400000000000000000014222611441203364000146730ustar00rootroot00000000000000# generated automatically by aclocal 1.16.5 -*- Autoconf -*- # Copyright (C) 1996-2021 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, [m4_warning([this file was generated for autoconf 2.69. You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically 'autoreconf'.])]) # Copyright (C) 1995-2002 Free Software Foundation, Inc. # Copyright (C) 2001-2003,2004 Red Hat, Inc. # # This file is free software, distributed under the terms of the GNU # General Public License. As a special exception to the GNU General # Public License, this file may be distributed as part of a program # that contains a configuration script generated by Autoconf, under # the same distribution terms as the rest of that program. # # This file can be copied and used freely without restrictions. It can # be used in projects which are not available under the GNU Public License # but which still want to provide support for the GNU gettext functionality. # # Macro to add for using GNU gettext. # Ulrich Drepper , 1995, 1996 # # Modified to never use included libintl. # Owen Taylor , 12/15/1998 # # Major rework to remove unused code # Owen Taylor , 12/11/2002 # # Added better handling of ALL_LINGUAS from GNU gettext version # written by Bruno Haible, Owen Taylor 5/30/3002 # # Modified to require ngettext # Matthias Clasen 08/06/2004 # Increment this whenever this file is changed. #serial 1 # We need this here as well, since someone might use autoconf-2.5x # to configure GLib then an older version to configure a package # using AM_GLIB_GNU_GETTEXT AC_PREREQ(2.53) dnl dnl We go to great lengths to make sure that aclocal won't dnl try to pull in the installed version of these macros dnl when running aclocal in the glib directory. dnl m4_copy([AC_DEFUN],[glib_DEFUN]) m4_copy([AC_REQUIRE],[glib_REQUIRE]) dnl dnl At the end, if we're not within glib, we'll define the public dnl definitions in terms of our private definitions. dnl # GLIB_LC_MESSAGES #-------------------- glib_DEFUN([GLIB_LC_MESSAGES], [AC_CHECK_HEADERS([locale.h]) if test $ac_cv_header_locale_h = yes; then AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, [AC_TRY_LINK([#include ], [return LC_MESSAGES], am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) if test $am_cv_val_LC_MESSAGES = yes; then AC_DEFINE(HAVE_LC_MESSAGES, 1, [Define if your file defines LC_MESSAGES.]) fi fi]) # GLIB_PATH_PROG_WITH_TEST #---------------------------- dnl GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) glib_DEFUN([GLIB_PATH_PROG_WITH_TEST], [# Extract the first word of "$2", so it can be a program name with args. set dummy $2; ac_word=[$]2 AC_MSG_CHECKING([for $ac_word]) AC_CACHE_VAL(ac_cv_path_$1, [case "[$]$1" in /*) ac_cv_path_$1="[$]$1" # Let the user override the test with a path. ;; *) IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in ifelse([$5], , $PATH, [$5]); do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then if [$3]; then ac_cv_path_$1="$ac_dir/$ac_word" break fi fi done IFS="$ac_save_ifs" dnl If no 4th arg is given, leave the cache variable unset, dnl so AC_PATH_PROGS will keep looking. ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" ])dnl ;; esac])dnl $1="$ac_cv_path_$1" if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then AC_MSG_RESULT([$]$1) else AC_MSG_RESULT(no) fi AC_SUBST($1)dnl ]) dnl Checks for special options needed on Mac OS X. dnl Defines INTL_MACOSX_LIBS. dnl dnl Copied from intlmacosx.m4 in gettext, GPL. dnl Copyright (C) 2004-2013 Free Software Foundation, Inc. glib_DEFUN([glib_gt_INTL_MACOSX], [ dnl Check for API introduced in Mac OS X 10.2. AC_CACHE_CHECK([for CFPreferencesCopyAppValue], [gt_cv_func_CFPreferencesCopyAppValue], [gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" AC_LINK_IFELSE( [AC_LANG_PROGRAM( [[#include ]], [[CFPreferencesCopyAppValue(NULL, NULL)]])], [gt_cv_func_CFPreferencesCopyAppValue=yes], [gt_cv_func_CFPreferencesCopyAppValue=no]) LIBS="$gt_save_LIBS"]) if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], [1], [Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in the CoreFoundation framework.]) fi dnl Check for API introduced in Mac OS X 10.3. AC_CACHE_CHECK([for CFLocaleCopyCurrent], [gt_cv_func_CFLocaleCopyCurrent], [gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" AC_LINK_IFELSE( [AC_LANG_PROGRAM( [[#include ]], [[CFLocaleCopyCurrent();]])], [gt_cv_func_CFLocaleCopyCurrent=yes], [gt_cv_func_CFLocaleCopyCurrent=no]) LIBS="$gt_save_LIBS"]) if test $gt_cv_func_CFLocaleCopyCurrent = yes; then AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], [1], [Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the CoreFoundation framework.]) fi INTL_MACOSX_LIBS= if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation" fi AC_SUBST([INTL_MACOSX_LIBS]) ]) # GLIB_WITH_NLS #----------------- glib_DEFUN([GLIB_WITH_NLS], dnl NLS is obligatory [USE_NLS=yes AC_SUBST(USE_NLS) gt_cv_have_gettext=no CATOBJEXT=NONE XGETTEXT=: INTLLIBS= glib_gt_INTL_MACOSX AC_CHECK_HEADER(libintl.h, [gt_cv_func_dgettext_libintl="no" libintl_extra_libs="" # # First check in libc # AC_CACHE_CHECK([for ngettext in libc], gt_cv_func_ngettext_libc, [AC_TRY_LINK([ #include ], [return !ngettext ("","", 1)], gt_cv_func_ngettext_libc=yes, gt_cv_func_ngettext_libc=no) ]) if test "$gt_cv_func_ngettext_libc" = "yes" ; then AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc, [AC_TRY_LINK([ #include ], [return !dgettext ("","")], gt_cv_func_dgettext_libc=yes, gt_cv_func_dgettext_libc=no) ]) fi if test "$gt_cv_func_ngettext_libc" = "yes" ; then AC_CHECK_FUNCS(bind_textdomain_codeset) fi # # If we don't have everything we want, check in libintl # if test "$gt_cv_func_dgettext_libc" != "yes" \ || test "$gt_cv_func_ngettext_libc" != "yes" \ || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then AC_CHECK_LIB(intl, bindtextdomain, [AC_CHECK_LIB(intl, ngettext, [AC_CHECK_LIB(intl, dgettext, gt_cv_func_dgettext_libintl=yes)])]) if test "$gt_cv_func_dgettext_libintl" != "yes" ; then AC_MSG_CHECKING([if -liconv is needed to use gettext]) AC_MSG_RESULT([]) AC_CHECK_LIB(intl, ngettext, [AC_CHECK_LIB(intl, dcgettext, [gt_cv_func_dgettext_libintl=yes libintl_extra_libs=-liconv], :,-liconv)], :,-liconv) fi # # If we found libintl, then check in it for bind_textdomain_codeset(); # we'll prefer libc if neither have bind_textdomain_codeset(), # and both have dgettext and ngettext # if test "$gt_cv_func_dgettext_libintl" = "yes" ; then glib_save_LIBS="$LIBS" LIBS="$LIBS -lintl $libintl_extra_libs" unset ac_cv_func_bind_textdomain_codeset AC_CHECK_FUNCS(bind_textdomain_codeset) LIBS="$glib_save_LIBS" if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then gt_cv_func_dgettext_libc=no else if test "$gt_cv_func_dgettext_libc" = "yes" \ && test "$gt_cv_func_ngettext_libc" = "yes"; then gt_cv_func_dgettext_libintl=no fi fi fi fi if test "$gt_cv_func_dgettext_libc" = "yes" \ || test "$gt_cv_func_dgettext_libintl" = "yes"; then gt_cv_have_gettext=yes fi if test "$gt_cv_func_dgettext_libintl" = "yes"; then INTLLIBS="-lintl $libintl_extra_libs $INTL_MACOSX_LIBS" fi if test "$gt_cv_have_gettext" = "yes"; then AC_DEFINE(HAVE_GETTEXT,1, [Define if the GNU gettext() function is already present or preinstalled.]) GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl if test "$MSGFMT" != "no"; then glib_save_LIBS="$LIBS" LIBS="$LIBS $INTLLIBS" AC_CHECK_FUNCS(dcgettext) MSGFMT_OPTS= AC_MSG_CHECKING([if msgfmt accepts -c]) GLIB_RUN_PROG([$MSGFMT -c -o /dev/null],[ msgid "" msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Project-Id-Version: test 1.0\n" "PO-Revision-Date: 2007-02-15 12:01+0100\n" "Last-Translator: test \n" "Language-Team: C \n" "MIME-Version: 1.0\n" "Content-Transfer-Encoding: 8bit\n" ], [MSGFMT_OPTS=-c; AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])]) AC_SUBST(MSGFMT_OPTS) AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :) AC_TRY_LINK(, [extern int _nl_msg_cat_cntr; return _nl_msg_cat_cntr], [CATOBJEXT=.gmo DATADIRNAME=share], [case $host in *-*-solaris*) dnl On Solaris, if bind_textdomain_codeset is in libc, dnl GNU format message catalog is always supported, dnl since both are added to the libc all together. dnl Hence, we'd like to go with DATADIRNAME=share and dnl and CATOBJEXT=.gmo in this case. AC_CHECK_FUNC(bind_textdomain_codeset, [CATOBJEXT=.gmo DATADIRNAME=share], [CATOBJEXT=.mo DATADIRNAME=lib]) ;; *-*-openbsd*) CATOBJEXT=.mo DATADIRNAME=share ;; *) CATOBJEXT=.mo DATADIRNAME=lib ;; esac]) LIBS="$glib_save_LIBS" INSTOBJEXT=.mo else gt_cv_have_gettext=no fi fi ]) if test "$gt_cv_have_gettext" = "yes" ; then AC_DEFINE(ENABLE_NLS, 1, [always defined to indicate that i18n is enabled]) fi dnl Test whether we really found GNU xgettext. if test "$XGETTEXT" != ":"; then dnl If it is not GNU xgettext we define it as : so that the dnl Makefiles still can work. if $XGETTEXT --omit-header /dev/null 2> /dev/null; then : ; else AC_MSG_RESULT( [found xgettext program is not GNU xgettext; ignore it]) XGETTEXT=":" fi fi # We need to process the po/ directory. POSUB=po AC_OUTPUT_COMMANDS( [case "$CONFIG_FILES" in *po/Makefile.in*) sed -e "/POTFILES =/r tool/mlconfig/po/POTFILES" tool/mlconfig/po/Makefile.in > tool/mlconfig/po/Makefile esac]) dnl These rules are solely for the distribution goal. While doing this dnl we only have to keep exactly one list of the available catalogs dnl in configure.ac. for lang in $ALL_LINGUAS; do GMOFILES="$GMOFILES $lang.gmo" POFILES="$POFILES $lang.po" done dnl Make all variables we use known to autoconf. AC_SUBST(CATALOGS) AC_SUBST(CATOBJEXT) AC_SUBST(DATADIRNAME) AC_SUBST(GMOFILES) AC_SUBST(INSTOBJEXT) AC_SUBST(INTLLIBS) AC_SUBST(PO_IN_DATADIR_TRUE) AC_SUBST(PO_IN_DATADIR_FALSE) AC_SUBST(POFILES) AC_SUBST(POSUB) ]) # AM_GLIB_GNU_GETTEXT # ------------------- # Do checks necessary for use of gettext. If a suitable implementation # of gettext is found in either in libintl or in the C library, # it will set INTLLIBS to the libraries needed for use of gettext # and AC_DEFINE() HAVE_GETTEXT and ENABLE_NLS. (The shell variable # gt_cv_have_gettext will be set to "yes".) It will also call AC_SUBST() # on various variables needed by the Makefile.in.in installed by # glib-gettextize. dnl AU_DEFUN([GLIB_GNU_GETTEXT], [AC_REQUIRE([AC_PROG_CC])dnl GLIB_LC_MESSAGES GLIB_WITH_NLS if test "$gt_cv_have_gettext" = "yes"; then if test "x$ALL_LINGUAS" = "x"; then LINGUAS= else AC_MSG_CHECKING(for catalogs to be installed) NEW_LINGUAS= for presentlang in $ALL_LINGUAS; do useit=no if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then desiredlanguages="$LINGUAS" else desiredlanguages="$ALL_LINGUAS" fi for desiredlang in $desiredlanguages; do # Use the presentlang catalog if desiredlang is # a. equal to presentlang, or # b. a variant of presentlang (because in this case, # presentlang can be used as a fallback for messages # which are not translated in the desiredlang catalog). case "$desiredlang" in "$presentlang"*) useit=yes;; esac done if test $useit = yes; then NEW_LINGUAS="$NEW_LINGUAS $presentlang" fi done LINGUAS=$NEW_LINGUAS AC_MSG_RESULT($LINGUAS) fi dnl Construct list of names of catalog files to be constructed. if test -n "$LINGUAS"; then for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done fi fi dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly dnl find the mkinstalldirs script in another subdir but ($top_srcdir). dnl Try to locate is. MKINSTALLDIRS= if test -n "$ac_aux_dir"; then MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" fi if test -z "$MKINSTALLDIRS"; then MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" fi AC_SUBST(MKINSTALLDIRS) dnl Generate list of files to be processed by xgettext which will dnl be included in po/Makefile. test -d tool/mlconfig/po || mkdir tool/mlconfig/po if test "x$srcdir" != "x."; then if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then posrcprefix="$srcdir/" else posrcprefix="../../../$srcdir/" fi else posrcprefix="../../../" fi rm -f tool/mlconfig/po/POTFILES sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ < $srcdir/tool/mlconfig/po/POTFILES.in > tool/mlconfig/po/POTFILES ], [[$0: This macro is deprecated. You should use upstream gettext instead.]]) # AM_GLIB_DEFINE_LOCALEDIR(VARIABLE) # ------------------------------- # Define VARIABLE to the location where catalog files will # be installed by po/Makefile. glib_DEFUN([GLIB_DEFINE_LOCALEDIR], [glib_REQUIRE([GLIB_GNU_GETTEXT])dnl glib_save_prefix="$prefix" glib_save_exec_prefix="$exec_prefix" glib_save_datarootdir="$datarootdir" test "x$prefix" = xNONE && prefix=$ac_default_prefix test "x$exec_prefix" = xNONE && exec_prefix=$prefix datarootdir=`eval echo "${datarootdir}"` if test "x$CATOBJEXT" = "x.mo" ; then localedir=`eval echo "${libdir}/locale"` else localedir=`eval echo "${datadir}/locale"` fi prefix="$glib_save_prefix" exec_prefix="$glib_save_exec_prefix" datarootdir="$glib_save_datarootdir" AC_DEFINE_UNQUOTED($1, "$localedir", [Define the location where the catalogs will be installed]) ]) dnl dnl Now the definitions that aclocal will find dnl ifdef(glib_configure_ac,[],[ AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)]) AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)]) ])dnl # GLIB_RUN_PROG(PROGRAM, TEST-FILE, [ACTION-IF-PASS], [ACTION-IF-FAIL]) # # Create a temporary file with TEST-FILE as its contents and pass the # file name to PROGRAM. Perform ACTION-IF-PASS if PROGRAM exits with # 0 and perform ACTION-IF-FAIL for any other exit status. AC_DEFUN([GLIB_RUN_PROG], [cat >conftest.foo <<_ACEOF $2 _ACEOF if AC_RUN_LOG([$1 conftest.foo]); then m4_ifval([$3], [$3], [:]) m4_ifvaln([$4], [else $4])dnl echo "$as_me: failed input was:" >&AS_MESSAGE_LOG_FD sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD fi]) # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # # Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software # Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. m4_define([_LT_COPYING], [dnl # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . ]) # serial 59 LT_INIT # LT_PREREQ(VERSION) # ------------------ # Complain and exit if this libtool version is less that VERSION. m4_defun([LT_PREREQ], [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, [m4_default([$3], [m4_fatal([Libtool version $1 or higher is required], 63)])], [$2])]) # _LT_CHECK_BUILDDIR # ------------------ # Complain if the absolute build directory name contains unusual characters m4_defun([_LT_CHECK_BUILDDIR], [case `pwd` in *\ * | *\ *) AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; esac ]) # LT_INIT([OPTIONS]) # ------------------ AC_DEFUN([LT_INIT], [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl AC_BEFORE([$0], [LTDL_INIT])dnl m4_require([_LT_CHECK_BUILDDIR])dnl dnl Autoconf doesn't catch unexpanded LT_ macros by default: m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 dnl unless we require an AC_DEFUNed macro: AC_REQUIRE([LTOPTIONS_VERSION])dnl AC_REQUIRE([LTSUGAR_VERSION])dnl AC_REQUIRE([LTVERSION_VERSION])dnl AC_REQUIRE([LTOBSOLETE_VERSION])dnl m4_require([_LT_PROG_LTMAIN])dnl _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) dnl Parse OPTIONS _LT_SET_OPTIONS([$0], [$1]) # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' AC_SUBST(LIBTOOL)dnl _LT_SETUP # Only expand once: m4_define([LT_INIT]) ])# LT_INIT # Old names: AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PROG_LIBTOOL], []) dnl AC_DEFUN([AM_PROG_LIBTOOL], []) # _LT_PREPARE_CC_BASENAME # ----------------------- m4_defun([_LT_PREPARE_CC_BASENAME], [ # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in @S|@*""; do case $cc_temp in compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } ])# _LT_PREPARE_CC_BASENAME # _LT_CC_BASENAME(CC) # ------------------- # It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, # but that macro is also expanded into generated libtool script, which # arranges for $SED and $ECHO to be set by different means. m4_defun([_LT_CC_BASENAME], [m4_require([_LT_PREPARE_CC_BASENAME])dnl AC_REQUIRE([_LT_DECL_SED])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl func_cc_basename $1 cc_basename=$func_cc_basename_result ]) # _LT_FILEUTILS_DEFAULTS # ---------------------- # It is okay to use these file commands and assume they have been set # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. m4_defun([_LT_FILEUTILS_DEFAULTS], [: ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} ])# _LT_FILEUTILS_DEFAULTS # _LT_SETUP # --------- m4_defun([_LT_SETUP], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl dnl _LT_DECL([], [host_alias], [0], [The host system])dnl _LT_DECL([], [host], [0])dnl _LT_DECL([], [host_os], [0])dnl dnl _LT_DECL([], [build_alias], [0], [The build system])dnl _LT_DECL([], [build], [0])dnl _LT_DECL([], [build_os], [0])dnl dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl dnl AC_REQUIRE([AC_PROG_LN_S])dnl test -z "$LN_S" && LN_S="ln -s" _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl dnl AC_REQUIRE([LT_CMD_MAX_LEN])dnl _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl m4_require([_LT_CMD_RELOAD])dnl m4_require([_LT_DECL_FILECMD])dnl m4_require([_LT_CHECK_MAGIC_METHOD])dnl m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_WITH_SYSROOT])dnl m4_require([_LT_CMD_TRUNCATE])dnl _LT_CONFIG_LIBTOOL_INIT([ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi ]) if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi _LT_CHECK_OBJDIR m4_require([_LT_TAG_COMPILER])dnl case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC and # ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o _LT_CC_BASENAME([$compiler]) # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then _LT_PATH_MAGIC fi ;; esac # Use C for the default configuration in the libtool script LT_SUPPORTED_TAG([CC]) _LT_LANG_C_CONFIG _LT_LANG_DEFAULT_CONFIG _LT_CONFIG_COMMANDS ])# _LT_SETUP # _LT_PREPARE_SED_QUOTE_VARS # -------------------------- # Define a few sed substitution that help us do robust quoting. m4_defun([_LT_PREPARE_SED_QUOTE_VARS], [# Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\([["`\\]]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ]) # _LT_PROG_LTMAIN # --------------- # Note that this code is called both from 'configure', and 'config.status' # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, # 'config.status' has no value for ac_aux_dir unless we are using Automake, # so we pass a copy along to make sure it has a sensible value anyway. m4_defun([_LT_PROG_LTMAIN], [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) ltmain=$ac_aux_dir/ltmain.sh ])# _LT_PROG_LTMAIN # So that we can recreate a full libtool script including additional # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS # in macros and then make a single call at the end using the 'libtool' # label. # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) # ---------------------------------------- # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL_INIT], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_INIT], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_INIT]) # _LT_CONFIG_LIBTOOL([COMMANDS]) # ------------------------------ # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) # ----------------------------------------------------- m4_defun([_LT_CONFIG_SAVE_COMMANDS], [_LT_CONFIG_LIBTOOL([$1]) _LT_CONFIG_LIBTOOL_INIT([$2]) ]) # _LT_FORMAT_COMMENT([COMMENT]) # ----------------------------- # Add leading comment marks to the start of each line, and a trailing # full-stop to the whole comment if one is not present already. m4_define([_LT_FORMAT_COMMENT], [m4_ifval([$1], [ m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) )]) # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) # ------------------------------------------------------------------- # CONFIGNAME is the name given to the value in the libtool script. # VARNAME is the (base) name used in the configure script. # VALUE may be 0, 1 or 2 for a computed quote escaped value based on # VARNAME. Any other value will be used directly. m4_define([_LT_DECL], [lt_if_append_uniq([lt_decl_varnames], [$2], [, ], [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], [m4_ifval([$1], [$1], [$2])]) lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) m4_ifval([$4], [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) lt_dict_add_subkey([lt_decl_dict], [$2], [tagged?], [m4_ifval([$5], [yes], [no])])]) ]) # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) # -------------------------------------------------------- m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_tag_varnames], [_lt_decl_filter([tagged?], [yes], $@)]) # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) # --------------------------------------------------------- m4_define([_lt_decl_filter], [m4_case([$#], [0], [m4_fatal([$0: too few arguments: $#])], [1], [m4_fatal([$0: too few arguments: $#: $1])], [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], [lt_dict_filter([lt_decl_dict], $@)])[]dnl ]) # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) # -------------------------------------------------- m4_define([lt_decl_quote_varnames], [_lt_decl_filter([value], [1], $@)]) # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_dquote_varnames], [_lt_decl_filter([value], [2], $@)]) # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_varnames_tagged], [m4_assert([$# <= 2])dnl _$0(m4_quote(m4_default([$1], [[, ]])), m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) m4_define([_lt_decl_varnames_tagged], [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) # lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_all_varnames], [_$0(m4_quote(m4_default([$1], [[, ]])), m4_if([$2], [], m4_quote(lt_decl_varnames), m4_quote(m4_shift($@))))[]dnl ]) m4_define([_lt_decl_all_varnames], [lt_join($@, lt_decl_varnames_tagged([$1], lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl ]) # _LT_CONFIG_STATUS_DECLARE([VARNAME]) # ------------------------------------ # Quote a variable value, and forward it to 'config.status' so that its # declaration there will have the same value as in 'configure'. VARNAME # must have a single quote delimited value for this to work. m4_define([_LT_CONFIG_STATUS_DECLARE], [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) # _LT_CONFIG_STATUS_DECLARATIONS # ------------------------------ # We delimit libtool config variables with single quotes, so when # we write them to config.status, we have to be sure to quote all # embedded single quotes properly. In configure, this macro expands # each variable declared with _LT_DECL (and _LT_TAGDECL) into: # # ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAGS # ---------------- # Output comment and list of tags supported by the script m4_defun([_LT_LIBTOOL_TAGS], [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl available_tags='_LT_TAGS'dnl ]) # _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) # ----------------------------------- # Extract the dictionary values for VARNAME (optionally with TAG) and # expand to a commented shell variable setting: # # # Some comment about what VAR is for. # visible_name=$lt_internal_name m4_define([_LT_LIBTOOL_DECLARE], [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [description])))[]dnl m4_pushdef([_libtool_name], m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), [0], [_libtool_name=[$]$1], [1], [_libtool_name=$lt_[]$1], [2], [_libtool_name=$lt_[]$1], [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl ]) # _LT_LIBTOOL_CONFIG_VARS # ----------------------- # Produce commented declarations of non-tagged libtool config variables # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' # script. Tagged libtool config variables (even for the LIBTOOL CONFIG # section) are produced by _LT_LIBTOOL_TAG_VARS. m4_defun([_LT_LIBTOOL_CONFIG_VARS], [m4_foreach([_lt_var], m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAG_VARS(TAG) # ------------------------- m4_define([_LT_LIBTOOL_TAG_VARS], [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) # _LT_TAGVAR(VARNAME, [TAGNAME]) # ------------------------------ m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) # _LT_CONFIG_COMMANDS # ------------------- # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of # variables for single and double quote escaping we saved from calls # to _LT_DECL, we can put quote escaped variables declarations # into 'config.status', and then the shell code to quote escape them in # for loops in 'config.status'. Finally, any additional code accumulated # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. m4_defun([_LT_CONFIG_COMMANDS], [AC_PROVIDE_IFELSE([LT_OUTPUT], dnl If the libtool generation code has been placed in $CONFIG_LT, dnl instead of duplicating it all over again into config.status, dnl then we will have config.status run $CONFIG_LT later, so it dnl needs to know what name is stored there: [AC_CONFIG_COMMANDS([libtool], [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], dnl If the libtool generation code is destined for config.status, dnl expand the accumulated commands and init code now: [AC_CONFIG_COMMANDS([libtool], [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) ])#_LT_CONFIG_COMMANDS # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], [ # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' _LT_CONFIG_STATUS_DECLARATIONS LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$[]1 _LTECHO_EOF' } # Quote evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_quote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_dquote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done _LT_OUTPUT_LIBTOOL_INIT ]) # _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) # ------------------------------------ # Generate a child script FILE with all initialization necessary to # reuse the environment learned by the parent script, and make the # file executable. If COMMENT is supplied, it is inserted after the # '#!' sequence but before initialization text begins. After this # macro, additional text can be appended to FILE to form the body of # the child script. The macro ends with non-zero status if the # file could not be fully written (such as if the disk is full). m4_ifdef([AS_INIT_GENERATED], [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], [m4_defun([_LT_GENERATED_FILE_INIT], [m4_require([AS_PREPARE])]dnl [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl [lt_write_fail=0 cat >$1 <<_ASEOF || lt_write_fail=1 #! $SHELL # Generated by $as_me. $2 SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$1 <<\_ASEOF || lt_write_fail=1 AS_SHELL_SANITIZE _AS_PREPARE exec AS_MESSAGE_FD>&1 _ASEOF test 0 = "$lt_write_fail" && chmod +x $1[]dnl m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT # --------- # This macro allows early generation of the libtool script (before # AC_OUTPUT is called), incase it is used in configure for compilation # tests. AC_DEFUN([LT_OUTPUT], [: ${CONFIG_LT=./config.lt} AC_MSG_NOTICE([creating $CONFIG_LT]) _LT_GENERATED_FILE_INIT(["$CONFIG_LT"], [# Run this file to recreate a libtool stub with the current configuration.]) cat >>"$CONFIG_LT" <<\_LTEOF lt_cl_silent=false exec AS_MESSAGE_LOG_FD>>config.log { echo AS_BOX([Running $as_me.]) } >&AS_MESSAGE_LOG_FD lt_cl_help="\ '$as_me' creates a local libtool stub from the current configuration, for use in further configure time tests before the real libtool is generated. Usage: $[0] [[OPTIONS]] -h, --help print this help, then exit -V, --version print version number, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files Report bugs to ." lt_cl_version="\ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) configured by $[0], generated by m4_PACKAGE_STRING. Copyright (C) 2011 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation gives unlimited permision to copy, distribute and modify it." while test 0 != $[#] do case $[1] in --version | --v* | -V ) echo "$lt_cl_version"; exit 0 ;; --help | --h* | -h ) echo "$lt_cl_help"; exit 0 ;; --debug | --d* | -d ) debug=: ;; --quiet | --q* | --silent | --s* | -q ) lt_cl_silent=: ;; -*) AC_MSG_ERROR([unrecognized option: $[1] Try '$[0] --help' for more information.]) ;; *) AC_MSG_ERROR([unrecognized argument: $[1] Try '$[0] --help' for more information.]) ;; esac shift done if $lt_cl_silent; then exec AS_MESSAGE_FD>/dev/null fi _LTEOF cat >>"$CONFIG_LT" <<_LTEOF _LT_OUTPUT_LIBTOOL_COMMANDS_INIT _LTEOF cat >>"$CONFIG_LT" <<\_LTEOF AC_MSG_NOTICE([creating $ofile]) _LT_OUTPUT_LIBTOOL_COMMANDS AS_EXIT(0) _LTEOF chmod +x "$CONFIG_LT" # configure is writing to config.log, but config.lt does its own redirection, # appending to config.log, which fails on DOS, as config.log is still kept # open by configure. Here we exec the FD to /dev/null, effectively closing # config.log, so it can be properly (re)opened and appended to by config.lt. lt_cl_success=: test yes = "$silent" && lt_config_lt_args="$lt_config_lt_args --quiet" exec AS_MESSAGE_LOG_FD>/dev/null $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false exec AS_MESSAGE_LOG_FD>>config.log $lt_cl_success || AS_EXIT(1) ])# LT_OUTPUT # _LT_CONFIG(TAG) # --------------- # If TAG is the built-in tag, create an initial libtool script with a # default configuration from the untagged config vars. Otherwise add code # to config.status for appending the configuration named by TAG from the # matching tagged config vars. m4_defun([_LT_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_CONFIG_SAVE_COMMANDS([ m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl m4_if(_LT_TAG, [C], [ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 _LT_COPYING _LT_LIBTOOL_TAGS # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG _LT_LIBTOOL_CONFIG_VARS _LT_LIBTOOL_TAG_VARS # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE _LT_PREPARE_MUNGE_PATH_LIST _LT_PREPARE_CC_BASENAME # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac _LT_PROG_LTMAIN # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ], [cat <<_LT_EOF >> "$ofile" dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded dnl in a comment (ie after a #). # ### BEGIN LIBTOOL TAG CONFIG: $1 _LT_LIBTOOL_TAG_VARS(_LT_TAG) # ### END LIBTOOL TAG CONFIG: $1 _LT_EOF ])dnl /m4_if ], [m4_if([$1], [], [ PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile'], []) ])dnl /_LT_CONFIG_SAVE_COMMANDS ])# _LT_CONFIG # LT_SUPPORTED_TAG(TAG) # --------------------- # Trace this macro to discover what tags are supported by the libtool # --tag option, using: # autoconf --trace 'LT_SUPPORTED_TAG:$1' AC_DEFUN([LT_SUPPORTED_TAG], []) # C support is built-in for now m4_define([_LT_LANG_C_enabled], []) m4_define([_LT_TAGS], []) # LT_LANG(LANG) # ------------- # Enable libtool support for the given language if not already enabled. AC_DEFUN([LT_LANG], [AC_BEFORE([$0], [LT_OUTPUT])dnl m4_case([$1], [C], [_LT_LANG(C)], [C++], [_LT_LANG(CXX)], [Go], [_LT_LANG(GO)], [Java], [_LT_LANG(GCJ)], [Fortran 77], [_LT_LANG(F77)], [Fortran], [_LT_LANG(FC)], [Windows Resource], [_LT_LANG(RC)], [m4_ifdef([_LT_LANG_]$1[_CONFIG], [_LT_LANG($1)], [m4_fatal([$0: unsupported language: "$1"])])])dnl ])# LT_LANG # _LT_LANG(LANGNAME) # ------------------ m4_defun([_LT_LANG], [m4_ifdef([_LT_LANG_]$1[_enabled], [], [LT_SUPPORTED_TAG([$1])dnl m4_append([_LT_TAGS], [$1 ])dnl m4_define([_LT_LANG_]$1[_enabled], [])dnl _LT_LANG_$1_CONFIG($1)])dnl ])# _LT_LANG m4_ifndef([AC_PROG_GO], [ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_GO. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # m4_defun([AC_PROG_GO], [AC_LANG_PUSH(Go)dnl AC_ARG_VAR([GOC], [Go compiler command])dnl AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl _AC_ARG_VAR_LDFLAGS()dnl AC_CHECK_TOOL(GOC, gccgo) if test -z "$GOC"; then if test -n "$ac_tool_prefix"; then AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) fi fi if test -z "$GOC"; then AC_CHECK_PROG(GOC, gccgo, gccgo, false) fi ])#m4_defun ])#m4_ifndef # _LT_LANG_DEFAULT_CONFIG # ----------------------- m4_defun([_LT_LANG_DEFAULT_CONFIG], [AC_PROVIDE_IFELSE([AC_PROG_CXX], [LT_LANG(CXX)], [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) AC_PROVIDE_IFELSE([AC_PROG_F77], [LT_LANG(F77)], [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) AC_PROVIDE_IFELSE([AC_PROG_FC], [LT_LANG(FC)], [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal dnl pulling things in needlessly. AC_PROVIDE_IFELSE([AC_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([LT_PROG_GCJ], [LT_LANG(GCJ)], [m4_ifdef([AC_PROG_GCJ], [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([A][M_PROG_GCJ], [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([LT_PROG_GCJ], [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) AC_PROVIDE_IFELSE([AC_PROG_GO], [LT_LANG(GO)], [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) AC_PROVIDE_IFELSE([LT_PROG_RC], [LT_LANG(RC)], [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) ])# _LT_LANG_DEFAULT_CONFIG # Obsolete macros: AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_CXX], []) dnl AC_DEFUN([AC_LIBTOOL_F77], []) dnl AC_DEFUN([AC_LIBTOOL_FC], []) dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) dnl AC_DEFUN([AC_LIBTOOL_RC], []) # _LT_TAG_COMPILER # ---------------- m4_defun([_LT_TAG_COMPILER], [AC_REQUIRE([AC_PROG_CC])dnl _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC ])# _LT_TAG_COMPILER # _LT_COMPILER_BOILERPLATE # ------------------------ # Check for compiler boilerplate output or warnings with # the simple compiler test code. m4_defun([_LT_COMPILER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ])# _LT_COMPILER_BOILERPLATE # _LT_LINKER_BOILERPLATE # ---------------------- # Check for linker boilerplate output or warnings with # the simple link test code. m4_defun([_LT_LINKER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* ])# _LT_LINKER_BOILERPLATE # _LT_REQUIRED_DARWIN_CHECKS # ------------------------- m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ case $host_os in rhapsody* | darwin*) AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) AC_CHECK_TOOL([LIPO], [lipo], [:]) AC_CHECK_TOOL([OTOOL], [otool], [:]) AC_CHECK_TOOL([OTOOL64], [otool64], [:]) _LT_DECL([], [DSYMUTIL], [1], [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) _LT_DECL([], [NMEDIT], [1], [Tool to change global to local symbols on Mac OS X]) _LT_DECL([], [LIPO], [1], [Tool to manipulate fat objects and archives on Mac OS X]) _LT_DECL([], [OTOOL], [1], [ldd/readelf like tool for Mach-O binaries on Mac OS X]) _LT_DECL([], [OTOOL64], [1], [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], [lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -rf libconftest.dylib* rm -f conftest.* fi]) AC_CACHE_CHECK([for -exported_symbols_list linker flag], [lt_cv_ld_exported_symbols_list], [lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [lt_cv_ld_exported_symbols_list=yes], [lt_cv_ld_exported_symbols_list=no]) LDFLAGS=$save_LDFLAGS ]) AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], [lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM ]) case $host_os in rhapsody* | darwin1.[[012]]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) case $MACOSX_DEPLOYMENT_TARGET,$host in 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; *) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac ]) # _LT_DARWIN_LINKER_FEATURES([TAG]) # --------------------------------- # Checks for linker and compiler features on darwin m4_defun([_LT_DARWIN_LINKER_FEATURES], [ m4_require([_LT_REQUIRED_DARWIN_CHECKS]) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported if test yes = "$lt_cv_ld_force_load"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) else _LT_TAGVAR(whole_archive_flag_spec, $1)='' fi _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" _LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], [ if test yes != "$lt_cv_apple_cc_single_mod"; then _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else _LT_TAGVAR(ld_shlibs, $1)=no fi ]) # _LT_SYS_MODULE_PATH_AIX([TAGNAME]) # ---------------------------------- # Links a minimal program and checks the executable # for the system default hardcoded library path. In most cases, # this is /usr/lib:/lib, but when the MPI compilers are used # the location of the communication and MPI libs are included too. # If we don't find anything, use the default library path according # to the aix ld manual. # Store the results from the different compilers for each TAGNAME. # Allow to override them for all tags through lt_cv_aix_libpath. m4_defun([_LT_SYS_MODULE_PATH_AIX], [m4_require([_LT_DECL_SED])dnl if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ lt_aix_libpath_sed='[ /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }]' _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi],[]) if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib fi ]) aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) fi ])# _LT_SYS_MODULE_PATH_AIX # _LT_SHELL_INIT(ARG) # ------------------- m4_define([_LT_SHELL_INIT], [m4_divert_text([M4SH-INIT], [$1 ])])# _LT_SHELL_INIT # _LT_PROG_ECHO_BACKSLASH # ----------------------- # Find how we can fake an echo command that does not interpret backslash. # In particular, with Autoconf 2.60 or later we add some code to the start # of the generated configure script that will find a shell with a builtin # printf (that we can use as an echo command). m4_defun([_LT_PROG_ECHO_BACKSLASH], [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO AC_MSG_CHECKING([how to print strings]) # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $[]1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "$*" } case $ECHO in printf*) AC_MSG_RESULT([printf]) ;; print*) AC_MSG_RESULT([print -r]) ;; *) AC_MSG_RESULT([cat]) ;; esac m4_ifdef([_AS_DETECT_SUGGESTED], [_AS_DETECT_SUGGESTED([ test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test "X`printf %s $ECHO`" = "X$ECHO" \ || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) ])# _LT_PROG_ECHO_BACKSLASH # _LT_WITH_SYSROOT # ---------------- AC_DEFUN([_LT_WITH_SYSROOT], [m4_require([_LT_DECL_SED])dnl AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], [Search for dependent libraries within DIR (or the compiler's sysroot if not specified).])], [], [with_sysroot=no]) dnl lt_sysroot will always be passed unquoted. We quote it here dnl in case the user passed a directory name. lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) AC_MSG_RESULT([$with_sysroot]) AC_MSG_ERROR([The sysroot must be an absolute path.]) ;; esac AC_MSG_RESULT([${lt_sysroot:-no}]) _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl [dependent libraries, and where our libraries should be installed.])]) # _LT_ENABLE_LOCK # --------------- m4_defun([_LT_ENABLE_LOCK], [AC_ARG_ENABLE([libtool-lock], [AS_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then if test yes = "$lt_cv_prog_gnu_ld"; then case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then emul=elf case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, [AC_LANG_PUSH(C) AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) AC_LANG_POP]) if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock ])# _LT_ENABLE_LOCK # _LT_PROG_AR # ----------- m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} _LT_DECL([], [AR], [1], [The archiver]) # Use ARFLAGS variable as AR's operation code to sync the variable naming with # Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have # higher priority because thats what people were doing historically (setting # ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS # variable obsoleted/removed. test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} lt_ar_flags=$AR_FLAGS _LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) # Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override # by AR_FLAGS because that was never working and AR_FLAGS is about to die. _LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], [Flags to create an archive]) AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [lt_cv_ar_at_file=no AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' AC_TRY_EVAL([lt_ar_try]) if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a AC_TRY_EVAL([lt_ar_try]) if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a ]) ]) if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi _LT_DECL([], [archiver_list_spec], [1], [How to feed a file listing to the archiver]) ])# _LT_PROG_AR # _LT_CMD_OLD_ARCHIVE # ------------------- m4_defun([_LT_CMD_OLD_ARCHIVE], [_LT_PROG_AR AC_CHECK_TOOL(STRIP, strip, :) test -z "$STRIP" && STRIP=: _LT_DECL([], [STRIP], [1], [A symbol stripping program]) AC_CHECK_TOOL(RANLIB, ranlib, :) test -z "$RANLIB" && RANLIB=: _LT_DECL([], [RANLIB], [1], [Commands used to install an old-style archive]) # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac _LT_DECL([], [old_postinstall_cmds], [2]) _LT_DECL([], [old_postuninstall_cmds], [2]) _LT_TAGDECL([], [old_archive_cmds], [2], [Commands used to build an old-style archive]) _LT_DECL([], [lock_old_archive_extraction], [0], [Whether to use a lock for old archive extraction]) ])# _LT_CMD_OLD_ARCHIVE # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------------------- # Check whether the given compiler option works AC_DEFUN([_LT_COMPILER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi fi $RM conftest* ]) if test yes = "[$]$2"; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) fi ])# _LT_COMPILER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------- # Check whether the given linker option works AC_DEFUN([_LT_LINKER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $3" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&AS_MESSAGE_LOG_FD $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi else $2=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS ]) if test yes = "[$]$2"; then m4_if([$4], , :, [$4]) else m4_if([$5], , :, [$5]) fi ])# _LT_LINKER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) # LT_CMD_MAX_LEN #--------------- AC_DEFUN([LT_CMD_MAX_LEN], [AC_REQUIRE([AC_CANONICAL_HOST])dnl # find the maximum length of command line arguments AC_MSG_CHECKING([the maximum length of command line arguments]) AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | msys* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac ]) if test -n "$lt_cv_sys_max_cmd_len"; then AC_MSG_RESULT($lt_cv_sys_max_cmd_len) else AC_MSG_RESULT(none) fi max_cmd_len=$lt_cv_sys_max_cmd_len _LT_DECL([], [max_cmd_len], [0], [What is the maximum length of a command?]) ])# LT_CMD_MAX_LEN # Old name: AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) # _LT_HEADER_DLFCN # ---------------- m4_defun([_LT_HEADER_DLFCN], [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl ])# _LT_HEADER_DLFCN # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) # ---------------------------------------------------------------- m4_defun([_LT_TRY_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes = "$cross_compiling"; then : [$4] else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF [#line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; }] _LT_EOF if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) $1 ;; x$lt_dlneed_uscore) $2 ;; x$lt_dlunknown|x*) $3 ;; esac else : # compilation failed $3 fi fi rm -fr conftest* ])# _LT_TRY_DLOPEN_SELF # LT_SYS_DLOPEN_SELF # ------------------ AC_DEFUN([LT_SYS_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin* | msys*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ]) ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) AC_CHECK_FUNC([shl_load], [lt_cv_dlopen=shl_load], [AC_CHECK_LIB([dld], [shl_load], [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], [AC_CHECK_FUNC([dlopen], [lt_cv_dlopen=dlopen], [AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], [AC_CHECK_LIB([svld], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], [AC_CHECK_LIB([dld], [dld_link], [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) ]) ]) ]) ]) ]) ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" AC_CACHE_CHECK([whether a program can dlopen itself], lt_cv_dlopen_self, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) ]) if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" AC_CACHE_CHECK([whether a statically linked program can dlopen itself], lt_cv_dlopen_self_static, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) ]) fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi _LT_DECL([dlopen_support], [enable_dlopen], [0], [Whether dlopen is supported]) _LT_DECL([dlopen_self], [enable_dlopen_self], [0], [Whether dlopen of programs is supported]) _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], [Whether dlopen of statically linked programs is supported]) ])# LT_SYS_DLOPEN_SELF # Old name: AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) # _LT_COMPILER_C_O([TAGNAME]) # --------------------------- # Check to see if options -c and -o are simultaneously supported by compiler. # This macro does not hard code the compiler like AC_PROG_CC_C_O. m4_defun([_LT_COMPILER_C_O], [m4_require([_LT_DECL_SED])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes fi fi chmod u+w . 2>&AS_MESSAGE_LOG_FD $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* ]) _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], [Does compiler simultaneously support -c and -o options?]) ])# _LT_COMPILER_C_O # _LT_COMPILER_FILE_LOCKS([TAGNAME]) # ---------------------------------- # Check to see if we can do hard links to lock some files if needed m4_defun([_LT_COMPILER_FILE_LOCKS], [m4_require([_LT_ENABLE_LOCK])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_COMPILER_C_O([$1]) hard_links=nottested if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user AC_MSG_CHECKING([if we can lock with hard links]) hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no AC_MSG_RESULT([$hard_links]) if test no = "$hard_links"; then AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) need_locks=warn fi else need_locks=no fi _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) ])# _LT_COMPILER_FILE_LOCKS # _LT_CHECK_OBJDIR # ---------------- m4_defun([_LT_CHECK_OBJDIR], [AC_CACHE_CHECK([for objdir], [lt_cv_objdir], [rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null]) objdir=$lt_cv_objdir _LT_DECL([], [objdir], [0], [The name of the directory that contains temporary libtool files])dnl m4_pattern_allow([LT_OBJDIR])dnl AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", [Define to the sub-directory where libtool stores uninstalled libraries.]) ])# _LT_CHECK_OBJDIR # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) # -------------------------------------- # Check hardcoding attributes. m4_defun([_LT_LINKER_HARDCODE_LIBPATH], [AC_MSG_CHECKING([how to hardcode library paths into programs]) _LT_TAGVAR(hardcode_action, $1)= if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || test -n "$_LT_TAGVAR(runpath_var, $1)" || test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then # We can hardcode non-existent directories. if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then # Linking always hardcodes the temporary library directory. _LT_TAGVAR(hardcode_action, $1)=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. _LT_TAGVAR(hardcode_action, $1)=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. _LT_TAGVAR(hardcode_action, $1)=unsupported fi AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi _LT_TAGDECL([], [hardcode_action], [0], [How to hardcode a shared library path into an executable]) ])# _LT_LINKER_HARDCODE_LIBPATH # _LT_CMD_STRIPLIB # ---------------- m4_defun([_LT_CMD_STRIPLIB], [m4_require([_LT_DECL_EGREP]) striplib= old_striplib= AC_MSG_CHECKING([whether stripping libraries is possible]) if test -z "$STRIP"; then AC_MSG_RESULT([no]) else if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else case $host_os in darwin*) # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) ;; freebsd*) if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) fi ;; *) AC_MSG_RESULT([no]) ;; esac fi fi _LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) _LT_DECL([], [striplib], [1]) ])# _LT_CMD_STRIPLIB # _LT_PREPARE_MUNGE_PATH_LIST # --------------------------- # Make sure func_munge_path_list() is defined correctly. m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], [[# func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x@S|@2 in x) ;; *:) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" ;; x:*) eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; *::*) eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" ;; *) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; esac } ]])# _LT_PREPARE_PATH_LIST # _LT_SYS_DYNAMIC_LINKER([TAG]) # ----------------------------- # PORTME Fill in your ld.so characteristics m4_defun([_LT_SYS_DYNAMIC_LINKER], [AC_REQUIRE([AC_CANONICAL_HOST])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_OBJDUMP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl AC_MSG_CHECKING([dynamic linker characteristics]) m4_if([$1], [], [ if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[[lt_foo]]++; } if (lt_freq[[lt_foo]] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi]) library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown AC_ARG_VAR([LT_SYS_LIBRARY_PATH], [User-defined run-time library search path.]) case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[[4-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[[01]] | aix4.[[01]].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a[(]lib.so.V[)]' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[[45]]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | msys* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; mingw* | cegcc* | msys*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl* | *,icl*) # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin* | msys*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[[23]].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[[01]]* | freebsdelf3.[[01]]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[[3-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], [lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], [lt_cv_shlibpath_overrides_runpath=yes])]) LDFLAGS=$save_LDFLAGS libdir=$save_libdir ]) shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac AC_MSG_RESULT([$dynamic_linker]) test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH _LT_DECL([], [variables_saved_for_relink], [1], [Variables whose values should be saved in libtool wrapper scripts and restored at link time]) _LT_DECL([], [need_lib_prefix], [0], [Do we need the "lib" prefix for modules?]) _LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) _LT_DECL([], [version_type], [0], [Library versioning type]) _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) _LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) _LT_DECL([], [shlibpath_overrides_runpath], [0], [Is shlibpath searched before the hard-coded library search path?]) _LT_DECL([], [libname_spec], [1], [Format of library name prefix]) _LT_DECL([], [library_names_spec], [1], [[List of archive names. First name is the real one, the rest are links. The last name is the one that the linker finds with -lNAME]]) _LT_DECL([], [soname_spec], [1], [[The coded name of the library, if different from the real name]]) _LT_DECL([], [install_override_mode], [1], [Permission mode override for installation of shared libraries]) _LT_DECL([], [postinstall_cmds], [2], [Command to use after installation of a shared archive]) _LT_DECL([], [postuninstall_cmds], [2], [Command to use after uninstallation of a shared archive]) _LT_DECL([], [finish_cmds], [2], [Commands used to finish a libtool library installation in a directory]) _LT_DECL([], [finish_eval], [1], [[As "finish_cmds", except a single script fragment to be evaled but not shown]]) _LT_DECL([], [hardcode_into_libs], [0], [Whether we should hardcode library paths into libraries]) _LT_DECL([], [sys_lib_search_path_spec], [2], [Compile-time system search path for libraries]) _LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], [Detected run-time system search path for libraries]) _LT_DECL([], [configure_time_lt_sys_library_path], [2], [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) ])# _LT_SYS_DYNAMIC_LINKER # _LT_PATH_TOOL_PREFIX(TOOL) # -------------------------- # find a file program that can recognize shared library AC_DEFUN([_LT_PATH_TOOL_PREFIX], [m4_require([_LT_DECL_EGREP])dnl AC_MSG_CHECKING([for $1]) AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, [case $MAGIC_CMD in [[\\/*] | ?:[\\/]*]) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. ac_dummy="m4_if([$2], , $PATH, [$2])" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$1"; then lt_cv_path_MAGIC_CMD=$ac_dir/"$1" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac]) MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then AC_MSG_RESULT($MAGIC_CMD) else AC_MSG_RESULT(no) fi _LT_DECL([], [MAGIC_CMD], [0], [Used to examine libraries when file_magic_cmd begins with "file"])dnl ])# _LT_PATH_TOOL_PREFIX # Old name: AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) # _LT_PATH_MAGIC # -------------- # find a file program that can recognize a shared library m4_defun([_LT_PATH_MAGIC], [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) else MAGIC_CMD=: fi fi ])# _LT_PATH_MAGIC # LT_PATH_LD # ---------- # find the pathname to the GNU or non-GNU linker AC_DEFUN([LT_PATH_LD], [AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PROG_ECHO_BACKSLASH])dnl AC_ARG_WITH([gnu-ld], [AS_HELP_STRING([--with-gnu-ld], [assume the C compiler uses GNU ld @<:@default=no@:>@])], [test no = "$withval" || with_gnu_ld=yes], [with_gnu_ld=no])dnl ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [[\\/]]* | ?:[[\\/]]*) re_direlt='/[[^/]][[^/]]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &1 conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], [if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi]) rm -f conftest.i conftest2.i conftest.out]) ])# _LT_PATH_DD # _LT_CMD_TRUNCATE # ---------------- # find command to truncate a binary pipe m4_defun([_LT_CMD_TRUNCATE], [m4_require([_LT_PATH_DD]) AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], [printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], [Command to truncate a binary pipe]) ])# _LT_CMD_TRUNCATE # _LT_CHECK_MAGIC_METHOD # ---------------------- # how to check for library dependencies # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_MAGIC_METHOD], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) AC_CACHE_CHECK([how to recognize dependent libraries], lt_cv_deplibs_check_method, [lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[[4-9]]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[[45]]*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin* | msys*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[[3-9]]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac ]) file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown _LT_DECL([], [deplibs_check_method], [1], [Method to check whether dependent libraries are shared objects]) _LT_DECL([], [file_magic_cmd], [1], [Command to use when deplibs_check_method = "file_magic"]) _LT_DECL([], [file_magic_glob], [1], [How to find potential files when deplibs_check_method = "file_magic"]) _LT_DECL([], [want_nocaseglob], [1], [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) ])# _LT_CHECK_MAGIC_METHOD # LT_PATH_NM # ---------- # find the pathname to a BSD- or MS-compatible name lister AC_DEFUN([LT_PATH_NM], [AC_REQUIRE([AC_PROG_CC])dnl AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, [if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi]) if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi AC_SUBST([DUMPBIN]) if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm AC_SUBST([NM]) _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], [lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) cat conftest.out >&AS_MESSAGE_LOG_FD if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest*]) ])# LT_PATH_NM # Old names: AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_PROG_NM], []) dnl AC_DEFUN([AC_PROG_NM], []) # _LT_CHECK_SHAREDLIB_FROM_LINKLIB # -------------------------------- # how to determine the name of the shared library # associated with a specific link library. # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) m4_require([_LT_DECL_DLLTOOL]) AC_CACHE_CHECK([how to associate runtime and link libraries], lt_cv_sharedlib_from_linklib_cmd, [lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac ]) sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO _LT_DECL([], [sharedlib_from_linklib_cmd], [1], [Command to associate shared and link libraries]) ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB # _LT_PATH_MANIFEST_TOOL # ---------------------- # locate the manifest tool m4_defun([_LT_PATH_MANIFEST_TOOL], [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], [lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&AS_MESSAGE_LOG_FD if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest*]) if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl ])# _LT_PATH_MANIFEST_TOOL # _LT_DLL_DEF_P([FILE]) # --------------------- # True iff FILE is a Windows DLL '.def' file. # Keep in sync with func_dll_def_p in the libtool script AC_DEFUN([_LT_DLL_DEF_P], [dnl test DEF = "`$SED -n dnl -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl -e q dnl Only consider the first "real" line $1`" dnl ])# _LT_DLL_DEF_P # LT_LIB_M # -------- # check for math library AC_DEFUN([LT_LIB_M], [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= case $host in *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-msys* | *-*-haiku* | *-*-pw32* | *-*-darwin*) # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") ;; *) AC_CHECK_LIB(m, cos, LIBM=-lm) ;; esac AC_SUBST([LIBM]) ])# LT_LIB_M # Old name: AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_CHECK_LIBM], []) # _LT_COMPILER_NO_RTTI([TAGNAME]) # ------------------------------- m4_defun([_LT_COMPILER_NO_RTTI], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= if test yes = "$GCC"; then case $cc_basename in nvcc*) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; *) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; esac _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], lt_cv_prog_compiler_rtti_exceptions, [-fno-rtti -fno-exceptions], [], [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) fi _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], [Compiler flag to turn off builtin functions]) ])# _LT_COMPILER_NO_RTTI # _LT_CMD_GLOBAL_SYMBOLS # ---------------------- m4_defun([_LT_CMD_GLOBAL_SYMBOLS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([LT_PATH_NM])dnl AC_REQUIRE([LT_PATH_LD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_TAG_COMPILER])dnl # Check for command to grab the raw symbol name followed by C symbol from nm. AC_MSG_CHECKING([command to parse $NM output from $compiler object]) AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], [ # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[[BCDEGRST]]' # Regexp to match symbols that can be accessed directly from C. sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[[BCDT]]' ;; cygwin* | msys* | mingw* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[[ABCDEGRST]]' fi ;; irix* | nonstopux*) symcode='[[BCDEGRST]]' ;; osf*) symcode='[[BCDEGQRST]]' ;; solaris*) symcode='[[BDRT]]' ;; sco3.2v5*) symcode='[[DT]]' ;; sysv4.2uw2*) symcode='[[DT]]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[[ABDT]]' ;; sysv4) symcode='[[DFNSTU]]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[[ABCDGIRSTW]]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT@&t@_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT@&t@_DLSYM_CONST #else # define LT@&t@_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT@&t@_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[[]] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD fi else echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done ]) if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then AC_MSG_RESULT(failed) else AC_MSG_RESULT(ok) fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then nm_file_list_spec='@' fi _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], [Take the output of nm and produce a listing of raw symbols and C names]) _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], [Transform the output of nm in a proper C declaration]) _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], [Transform the output of nm into a list of symbols to manually relocate]) _LT_DECL([global_symbol_to_c_name_address], [lt_cv_sys_global_symbol_to_c_name_address], [1], [Transform the output of nm in a C name address pair]) _LT_DECL([global_symbol_to_c_name_address_lib_prefix], [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], [Transform the output of nm in a C name address pair when lib prefix is needed]) _LT_DECL([nm_interface], [lt_cv_nm_interface], [1], [The name lister interface]) _LT_DECL([], [nm_file_list_spec], [1], [Specify filename containing input files for $NM]) ]) # _LT_CMD_GLOBAL_SYMBOLS # _LT_COMPILER_PIC([TAGNAME]) # --------------------------- m4_defun([_LT_COMPILER_PIC], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_wl, $1)= _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)= m4_if([$1], [CXX], [ # C++ specific cases for pic, static, wl, etc. if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | msys* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac else case $host_os in aix[[4-9]]*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; mingw* | cygwin* | msys* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) ;; dgux*) case $cc_basename in ec++*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; ghcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' if test ia64 != "$host_cpu"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' fi ;; aCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; ecpc* ) # old Intel C++ for x86_64, which still supported -KPIC. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; icpc* ) # Intel C++, used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL 8.0, 9.0 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' ;; *) ;; esac ;; netbsd*) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; cxx*) # Digital/Compaq C++ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; lcc*) # Lucid _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; *) ;; esac ;; vxworks*) ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ], [ if test yes = "$GCC"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC (with -KPIC) is the default. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # Lahey Fortran 8.1. lf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' ;; nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; ccc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All Alpha code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='' ;; *Sun\ F* | *Sun*Fortran*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; *Intel*\ [[CF]]*Compiler*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; *Portland\ Group*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; esac ;; newsos6) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All OSF/1 code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; rdos*) _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; solaris*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; *) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; esac ;; sunos4*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; unicos*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; uts4*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ]) case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" ;; esac AC_CACHE_CHECK([for $compiler option to produce PIC], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) # # Check to make sure the PIC flag actually works. # if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in "" | " "*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; esac], [_LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) fi _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], [Additional compiler flags for building library objects]) _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], [How to pass a linker flag through the compiler]) # # Check to make sure the static flag actually works. # wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), $lt_tmp_static_flag, [], [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], [Compiler flag to prevent dynamic linking]) ])# _LT_COMPILER_PIC # _LT_LINKER_SHLIBS([TAGNAME]) # ---------------------------- # See if the linker supports building shared libraries. m4_defun([_LT_LINKER_SHLIBS], [AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) m4_if([$1], [CXX], [ _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] case $host_os in aix[[4-9]]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds ;; cygwin* | msys* | mingw* | cegcc*) case $cc_basename in cl* | icl*) _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] ;; esac ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac ], [ runpath_var= _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_cmds, $1)= _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(old_archive_from_new_cmds, $1)= _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= _LT_TAGVAR(thread_safe_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list _LT_TAGVAR(include_expsyms, $1)= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. dnl Note also adjust exclude_expsyms for C++ above. extract_expsyms_cmds= case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[[3-9]]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 _LT_TAGVAR(whole_archive_flag_spec, $1)= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; sunos4*) _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then runpath_var= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. _LT_TAGVAR(hardcode_minus_L, $1)=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_TAGVAR(hardcode_direct, $1)=unsupported fi ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; bsdi[[45]]*) _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl* | icl*) # Native MSVC or ICC _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC and ICC wrapper _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' # FIXME: Should let the user specify the lib program. _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; dgux*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly* | midnightbsd*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; hpux9*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) m4_if($1, [], [ # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) _LT_LINKER_OPTION([if $CC understands -b], _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) ;; esac fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], [lt_cv_irix_exported_symbol], [save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" AC_LINK_IFELSE( [AC_LANG_SOURCE( [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], [C++], [[int foo (void) { return 0; }]], [Fortran 77], [[ subroutine foo end]], [Fortran], [[ subroutine foo end]])])], [lt_cv_irix_exported_symbol=yes], [lt_cv_irix_exported_symbol=no]) LDFLAGS=$save_LDFLAGS]) if test yes = "$lt_cv_irix_exported_symbol"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes _LT_TAGVAR(link_all_deplibs, $1)=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(ld_shlibs, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; newsos6) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' fi else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; osf3*) if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' if test yes = "$GCC"; then wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' fi ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4) case $host_vendor in sni) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' _LT_TAGVAR(hardcode_direct, $1)=no ;; motorola) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4.3*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes _LT_TAGVAR(ld_shlibs, $1)=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(ld_shlibs, $1)=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' ;; esac fi fi ]) AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl _LT_DECL([], [extract_expsyms_cmds], [2], [The commands to extract the exported symbol list from a shared archive]) # # Do we need to explicitly link libc? # case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in x|xyes) # Assume -lc should be added _LT_TAGVAR(archive_cmds_need_lc, $1)=yes if test yes,yes = "$GCC,$enable_shared"; then case $_LT_TAGVAR(archive_cmds, $1) in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. AC_CACHE_CHECK([whether -lc should be explicitly linked in], [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), [$RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if AC_TRY_EVAL(ac_compile) 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) _LT_TAGVAR(allow_undefined_flag, $1)= if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) then lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no else lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes fi _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* ]) _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) ;; esac fi ;; esac _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], [Whether or not to add -lc for building shared libraries]) _LT_TAGDECL([allow_libtool_libs_with_static_runtimes], [enable_shared_with_static_runtimes], [0], [Whether or not to disallow shared libs when runtime libs are static]) _LT_TAGDECL([], [export_dynamic_flag_spec], [1], [Compiler flag to allow reflexive dlopens]) _LT_TAGDECL([], [whole_archive_flag_spec], [1], [Compiler flag to generate shared objects directly from archives]) _LT_TAGDECL([], [compiler_needs_object], [1], [Whether the compiler copes with passing no objects directly]) _LT_TAGDECL([], [old_archive_from_new_cmds], [2], [Create an old-style archive from a shared archive]) _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], [Create a temporary old-style archive to link instead of a shared archive]) _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) _LT_TAGDECL([], [archive_expsym_cmds], [2]) _LT_TAGDECL([], [module_cmds], [2], [Commands used to build a loadable module if different from building a shared archive.]) _LT_TAGDECL([], [module_expsym_cmds], [2]) _LT_TAGDECL([], [with_gnu_ld], [1], [Whether we are building with GNU ld or not]) _LT_TAGDECL([], [allow_undefined_flag], [1], [Flag that allows shared libraries with undefined symbols to be built]) _LT_TAGDECL([], [no_undefined_flag], [1], [Flag that enforces no undefined symbols]) _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], [Flag to hardcode $libdir into a binary during linking. This must work even if $libdir does not exist]) _LT_TAGDECL([], [hardcode_libdir_separator], [1], [Whether we need a single "-rpath" flag with a separated argument]) _LT_TAGDECL([], [hardcode_direct], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_direct_absolute], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary and the resulting library dependency is "absolute", i.e impossible to change by setting $shlibpath_var if the library is relocated]) _LT_TAGDECL([], [hardcode_minus_L], [0], [Set to "yes" if using the -LDIR flag during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_shlibpath_var], [0], [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_automatic], [0], [Set to "yes" if building a shared library automatically hardcodes DIR into the library and all subsequent libraries and executables linked against it]) _LT_TAGDECL([], [inherit_rpath], [0], [Set to yes if linker adds runtime paths of dependent libraries to runtime path list]) _LT_TAGDECL([], [link_all_deplibs], [0], [Whether libtool must link a program against all its dependency libraries]) _LT_TAGDECL([], [always_export_symbols], [0], [Set to "yes" if exported symbols are required]) _LT_TAGDECL([], [export_symbols_cmds], [2], [The commands to list exported symbols]) _LT_TAGDECL([], [exclude_expsyms], [1], [Symbols that should not be listed in the preloaded symbols]) _LT_TAGDECL([], [include_expsyms], [1], [Symbols that must always be exported]) _LT_TAGDECL([], [prelink_cmds], [2], [Commands necessary for linking programs (against libraries) with templates]) _LT_TAGDECL([], [postlink_cmds], [2], [Commands necessary for finishing linking programs]) _LT_TAGDECL([], [file_list_spec], [1], [Specify filename containing input files]) dnl FIXME: Not yet implemented dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], dnl [Compiler flag to generate thread safe objects]) ])# _LT_LINKER_SHLIBS # _LT_LANG_C_CONFIG([TAG]) # ------------------------ # Ensure that the configuration variables for a C compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_C_CONFIG], [m4_require([_LT_DECL_EGREP])dnl lt_save_CC=$CC AC_LANG_PUSH(C) # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' _LT_TAG_COMPILER # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) LT_SYS_DLOPEN_SELF _LT_CMD_STRIPLIB # Report what library types will actually be built AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_CONFIG($1) fi AC_LANG_POP CC=$lt_save_CC ])# _LT_LANG_C_CONFIG # _LT_LANG_CXX_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a C++ compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_CXX_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl if test -n "$CXX" && ( test no != "$CXX" && ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || (test g++ != "$CXX"))); then AC_PROG_CXXCPP else _lt_caught_CXX_error=yes fi AC_LANG_PUSH(C++) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} CFLAGS=$CXXFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi if test yes = "$GXX"; then # Set up default GNU C++ configuration LT_PATH_LD # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test yes = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) _LT_TAGVAR(ld_shlibs, $1)=yes case $host_os in aix3*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GXX"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag=$shared_flag' $wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. # The "-G" linker flag allows undefined symbols. _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; cygwin* | msys* | mingw* | pw32* | cegcc*) case $GXX,$cc_basename in ,cl* | no,cl* | ,icl* | no,icl*) # Native MSVC or ICC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ func_to_tool_file "$lt_outputfile"~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; freebsd2.*) # C++ shared libraries reported to be fairly broken before # switch to ELF _LT_TAGVAR(ld_shlibs, $1)=no ;; freebsd-elf*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_TAGVAR(ld_shlibs, $1)=yes ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; hpux9*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; hpux10*|hpux11*) if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) ;; *) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi _LT_TAGVAR(link_all_deplibs, $1)=yes ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc* | ecpc* ) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ $RANLIB $oldlib' _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; m88k*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; *nto* | *qnx*) _LT_TAGVAR(ld_shlibs, $1)=yes ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using # the KAI C++ compiler. case $host in osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; esac ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; cxx*) case $host in osf3*) _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; *) _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ $RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' ;; esac _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' case $host in osf3*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ '"$_LT_TAGVAR(old_archive_cmds, $1)" _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ '"$_LT_TAGVAR(reload_cmds, $1)" ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(GCC, $1)=$GXX _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld fi # test yes != "$_lt_caught_CXX_error" AC_LANG_POP ])# _LT_LANG_CXX_CONFIG # _LT_FUNC_STRIPNAME_CNF # ---------------------- # func_stripname_cnf prefix suffix name # strip PREFIX and SUFFIX off of NAME. # PREFIX and SUFFIX must not contain globbing or regex special # characters, hashes, percent signs, but SUFFIX may contain a leading # dot (in which case that matches only a dot). # # This function is identical to the (non-XSI) version of func_stripname, # except this one can be used by m4 code that may be executed by configure, # rather than the libtool script. m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl AC_REQUIRE([_LT_DECL_SED]) AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) func_stripname_cnf () { case @S|@2 in .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; esac } # func_stripname_cnf ])# _LT_FUNC_STRIPNAME_CNF # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose # compiler output when linking a shared library. # Parse the compiler output and extract the necessary # objects, libraries and library flags. m4_defun([_LT_SYS_HIDDEN_LIBDEPS], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl # Dependencies to place before and after the object being linked: _LT_TAGVAR(predep_objects, $1)= _LT_TAGVAR(postdep_objects, $1)= _LT_TAGVAR(predeps, $1)= _LT_TAGVAR(postdeps, $1)= _LT_TAGVAR(compiler_lib_search_path, $1)= dnl we can't use the lt_simple_compile_test_code here, dnl because it contains code intended for an executable, dnl not a library. It's possible we should let each dnl tag define a new lt_????_link_test_code variable, dnl but it's only used here... m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF int a; void foo (void) { a = 0; } _LT_EOF ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF class Foo { public: Foo (void) { a = 0; } private: int a; }; _LT_EOF ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer*4 a a=0 return end _LT_EOF ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer a a=0 return end _LT_EOF ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF public class foo { private int a; public void bar (void) { a = 0; } }; _LT_EOF ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF package foo func foo() { } _LT_EOF ]) _lt_libdeps_save_CFLAGS=$CFLAGS case "$CC $CFLAGS " in #( *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; esac dnl Parse the compiler output and extract the necessary dnl objects, libraries and library flags. if AC_TRY_EVAL(ac_compile); then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test x-L = "$p" || test x-R = "$p"; then prev=$p continue fi # Expand the sysroot to ease extracting the directories later. if test -z "$prev"; then case $p in -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; esac fi case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac if test no = "$pre_test_object_deps_done"; then case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p else _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$_LT_TAGVAR(postdeps, $1)"; then _LT_TAGVAR(postdeps, $1)=$prev$p else _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" fi fi prev= ;; *.lto.$objext) ;; # Ignore GCC LTO objects *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test no = "$pre_test_object_deps_done"; then if test -z "$_LT_TAGVAR(predep_objects, $1)"; then _LT_TAGVAR(predep_objects, $1)=$p else _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" fi else if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then _LT_TAGVAR(postdep_objects, $1)=$p else _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling $1 test program" fi $RM -f confest.$objext CFLAGS=$_lt_libdeps_save_CFLAGS # PORTME: override above test on systems where it is broken m4_if([$1], [CXX], [case $host_os in interix[[3-9]]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. _LT_TAGVAR(predep_objects,$1)= _LT_TAGVAR(postdep_objects,$1)= _LT_TAGVAR(postdeps,$1)= ;; esac ]) case " $_LT_TAGVAR(postdeps, $1) " in *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; esac _LT_TAGVAR(compiler_lib_search_dirs, $1)= if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi _LT_TAGDECL([], [compiler_lib_search_dirs], [1], [The directories searched by this compiler when creating a shared library]) _LT_TAGDECL([], [predep_objects], [1], [Dependencies to place before and after the objects being linked to create a shared library]) _LT_TAGDECL([], [postdep_objects], [1]) _LT_TAGDECL([], [predeps], [1]) _LT_TAGDECL([], [postdeps], [1]) _LT_TAGDECL([], [compiler_lib_search_path], [1], [The library search path used internally by the compiler when linking a shared library]) ])# _LT_SYS_HIDDEN_LIBDEPS # _LT_LANG_F77_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a Fortran 77 compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_F77_CONFIG], [AC_LANG_PUSH(Fortran 77) if test -z "$F77" || test no = "$F77"; then _lt_disable_F77=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for f77 test sources. ac_ext=f # Object file extension for compiled f77 test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the F77 compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_F77"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${F77-"f77"} CFLAGS=$FFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) GCC=$G77 if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$G77 _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_F77" AC_LANG_POP ])# _LT_LANG_F77_CONFIG # _LT_LANG_FC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for a Fortran compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_FC_CONFIG], [AC_LANG_PUSH(Fortran) if test -z "$FC" || test no = "$FC"; then _lt_disable_FC=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for fc test sources. ac_ext=${ac_fc_srcext-f} # Object file extension for compiled fc test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the FC compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_FC"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${FC-"f95"} CFLAGS=$FCFLAGS compiler=$CC GCC=$ac_cv_fc_compiler_gnu _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_FC" AC_LANG_POP ])# _LT_LANG_FC_CONFIG # _LT_LANG_GCJ_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Java Compiler compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GCJ_CONFIG], [AC_REQUIRE([LT_PROG_GCJ])dnl AC_LANG_SAVE # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GCJ-"gcj"} CFLAGS=$GCJFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # GCJ did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GCJ_CONFIG # _LT_LANG_GO_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Go compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GO_CONFIG], [AC_REQUIRE([LT_PROG_GO])dnl AC_LANG_SAVE # Source file extension for Go test sources. ac_ext=go # Object file extension for compiled Go test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="package main; func main() { }" # Code to be used in simple link tests lt_simple_link_test_code='package main; func main() { }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GOC-"gccgo"} CFLAGS=$GOFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # Go did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GO_CONFIG # _LT_LANG_RC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for the Windows resource compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_RC_CONFIG], [AC_REQUIRE([LT_PROG_RC])dnl AC_LANG_SAVE # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests lt_simple_link_test_code=$lt_simple_compile_test_code # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC= CC=${RC-"windres"} CFLAGS= compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes if test -n "$compiler"; then : _LT_CONFIG($1) fi GCC=$lt_save_GCC AC_LANG_RESTORE CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_RC_CONFIG # LT_PROG_GCJ # ----------- AC_DEFUN([LT_PROG_GCJ], [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], [AC_CHECK_TOOL(GCJ, gcj,) test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" AC_SUBST(GCJFLAGS)])])[]dnl ]) # Old name: AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_GCJ], []) # LT_PROG_GO # ---------- AC_DEFUN([LT_PROG_GO], [AC_CHECK_TOOL(GOC, gccgo,) ]) # LT_PROG_RC # ---------- AC_DEFUN([LT_PROG_RC], [AC_CHECK_TOOL(RC, windres,) ]) # Old name: AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_RC], []) # _LT_DECL_EGREP # -------------- # If we don't have a new enough Autoconf to choose the best grep # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_EGREP], [AC_REQUIRE([AC_PROG_EGREP])dnl AC_REQUIRE([AC_PROG_FGREP])dnl test -z "$GREP" && GREP=grep _LT_DECL([], [GREP], [1], [A grep program that handles long lines]) _LT_DECL([], [EGREP], [1], [An ERE matcher]) _LT_DECL([], [FGREP], [1], [A literal string matcher]) dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too AC_SUBST([GREP]) ]) # _LT_DECL_OBJDUMP # -------------- # If we don't have a new enough Autoconf to choose the best objdump # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_OBJDUMP], [AC_CHECK_TOOL(OBJDUMP, objdump, false) test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) AC_SUBST([OBJDUMP]) ]) # _LT_DECL_DLLTOOL # ---------------- # Ensure DLLTOOL variable is set. m4_defun([_LT_DECL_DLLTOOL], [AC_CHECK_TOOL(DLLTOOL, dlltool, false) test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program]) AC_SUBST([DLLTOOL]) ]) # _LT_DECL_FILECMD # ---------------- # Check for a file(cmd) program that can be used to detect file type and magic m4_defun([_LT_DECL_FILECMD], [AC_CHECK_TOOL([FILECMD], [file], [:]) _LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) ])# _LD_DECL_FILECMD # _LT_DECL_SED # ------------ # Check for a fully-functional sed program, that truncates # as few characters as possible. Prefer GNU sed if found. m4_defun([_LT_DECL_SED], [AC_PROG_SED test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" _LT_DECL([], [SED], [1], [A sed program that does not truncate output]) _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], [Sed that helps us avoid accidentally triggering echo(1) options like -n]) ])# _LT_DECL_SED m4_ifndef([AC_PROG_SED], [ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_SED. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # m4_defun([AC_PROG_SED], [AC_MSG_CHECKING([for a sed that does not truncate output]) AC_CACHE_VAL(lt_cv_path_SED, [# Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" fi done done done IFS=$as_save_IFS lt_ac_max=0 lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do test ! -f "$lt_ac_sed" && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in # Check for GNU sed and select it if it is found. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then lt_cv_path_SED=$lt_ac_sed break fi while true; do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo >>conftest.nl $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough test 10 -lt "$lt_ac_count" && break lt_ac_count=`expr $lt_ac_count + 1` if test "$lt_ac_count" -gt "$lt_ac_max"; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi done done ]) SED=$lt_cv_path_SED AC_SUBST([SED]) AC_MSG_RESULT([$SED]) ])#AC_PROG_SED ])#m4_ifndef # Old name: AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_SED], []) # _LT_CHECK_SHELL_FEATURES # ------------------------ # Find out whether the shell is Bourne or XSI compatible, # or has some other useful features. m4_defun([_LT_CHECK_SHELL_FEATURES], [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl ])# _LT_CHECK_SHELL_FEATURES # _LT_PATH_CONVERSION_FUNCTIONS # ----------------------------- # Determine what file name conversion functions should be used by # func_to_host_file (and, implicitly, by func_to_host_path). These are needed # for certain cross-compile configurations and native mingw. m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_MSG_CHECKING([how to convert $build file names to $host format]) AC_CACHE_VAL(lt_cv_to_host_file_cmd, [case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac ]) to_host_file_cmd=$lt_cv_to_host_file_cmd AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], [0], [convert $build file names to $host format])dnl AC_MSG_CHECKING([how to convert $build file names to toolchain format]) AC_CACHE_VAL(lt_cv_to_tool_file_cmd, [#assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac ]) to_tool_file_cmd=$lt_cv_to_tool_file_cmd AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], [0], [convert $build files to toolchain format])dnl ])# _LT_PATH_CONVERSION_FUNCTIONS # Helper functions for option handling. -*- Autoconf -*- # # Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free # Software Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 8 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) # ------------------------------------------ m4_define([_LT_MANGLE_OPTION], [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) # --------------------------------------- # Set option OPTION-NAME for macro MACRO-NAME, and if there is a # matching handler defined, dispatch to it. Other OPTION-NAMEs are # saved as a flag. m4_define([_LT_SET_OPTION], [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), _LT_MANGLE_DEFUN([$1], [$2]), [m4_warning([Unknown $1 option '$2'])])[]dnl ]) # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) # ------------------------------------------------------------ # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. m4_define([_LT_IF_OPTION], [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) # ------------------------------------------------------- # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME # are set. m4_define([_LT_UNLESS_OPTIONS], [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), [m4_define([$0_found])])])[]dnl m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 ])[]dnl ]) # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) # ---------------------------------------- # OPTION-LIST is a space-separated list of Libtool options associated # with MACRO-NAME. If any OPTION has a matching handler declared with # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about # the unknown option and exit. m4_defun([_LT_SET_OPTIONS], [# Set options m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [_LT_SET_OPTION([$1], _LT_Option)]) m4_if([$1],[LT_INIT],[ dnl dnl Simply set some default values (i.e off) if boolean options were not dnl specified: _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no ]) _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no ]) dnl dnl If no reference was made to various pairs of opposing options, then dnl we run the default mode handler for the pair. For example, if neither dnl 'shared' nor 'disable-shared' was passed, we enable building of shared dnl archives by default: _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], [_LT_ENABLE_FAST_INSTALL]) _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], [_LT_WITH_AIX_SONAME([aix])]) ]) ])# _LT_SET_OPTIONS # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) # ----------------------------------------- m4_define([_LT_MANGLE_DEFUN], [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) # ----------------------------------------------- m4_define([LT_OPTION_DEFINE], [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl ])# LT_OPTION_DEFINE # dlopen # ------ LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes ]) AU_DEFUN([AC_LIBTOOL_DLOPEN], [_LT_SET_OPTION([LT_INIT], [dlopen]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'dlopen' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) # win32-dll # --------- # Declare package support for building win32 dll's. LT_OPTION_DEFINE([LT_INIT], [win32-dll], [enable_win32_dll=yes case $host in *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) AC_CHECK_TOOL(AS, as, false) AC_CHECK_TOOL(DLLTOOL, dlltool, false) AC_CHECK_TOOL(OBJDUMP, objdump, false) ;; esac test -z "$AS" && AS=as _LT_DECL([], [AS], [1], [Assembler program])dnl test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl ])# win32-dll AU_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_REQUIRE([AC_CANONICAL_HOST])dnl _LT_SET_OPTION([LT_INIT], [win32-dll]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'win32-dll' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) # _LT_ENABLE_SHARED([DEFAULT]) # ---------------------------- # implement the --enable-shared flag, and supports the 'shared' and # 'disable-shared' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_SHARED], [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([shared], [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac], [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) _LT_DECL([build_libtool_libs], [enable_shared], [0], [Whether or not to build shared libraries]) ])# _LT_ENABLE_SHARED LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) # Old names: AC_DEFUN([AC_ENABLE_SHARED], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) ]) AC_DEFUN([AC_DISABLE_SHARED], [_LT_SET_OPTION([LT_INIT], [disable-shared]) ]) AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_SHARED], []) dnl AC_DEFUN([AM_DISABLE_SHARED], []) # _LT_ENABLE_STATIC([DEFAULT]) # ---------------------------- # implement the --enable-static flag, and support the 'static' and # 'disable-static' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_STATIC], [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([static], [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac], [enable_static=]_LT_ENABLE_STATIC_DEFAULT) _LT_DECL([build_old_libs], [enable_static], [0], [Whether or not to build static libraries]) ])# _LT_ENABLE_STATIC LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) # Old names: AC_DEFUN([AC_ENABLE_STATIC], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) ]) AC_DEFUN([AC_DISABLE_STATIC], [_LT_SET_OPTION([LT_INIT], [disable-static]) ]) AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_STATIC], []) dnl AC_DEFUN([AM_DISABLE_STATIC], []) # _LT_ENABLE_FAST_INSTALL([DEFAULT]) # ---------------------------------- # implement the --enable-fast-install flag, and support the 'fast-install' # and 'disable-fast-install' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_FAST_INSTALL], [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([fast-install], [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac], [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) _LT_DECL([fast_install], [enable_fast_install], [0], [Whether or not to optimize for fast installation])dnl ])# _LT_ENABLE_FAST_INSTALL LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) # Old names: AU_DEFUN([AC_ENABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'fast-install' option into LT_INIT's first parameter.]) ]) AU_DEFUN([AC_DISABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], [disable-fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'disable-fast-install' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) # _LT_WITH_AIX_SONAME([DEFAULT]) # ---------------------------------- # implement the --with-aix-soname flag, and support the `aix-soname=aix' # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. m4_define([_LT_WITH_AIX_SONAME], [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[[5-9]]*,yes) AC_MSG_CHECKING([which variant of shared library versioning to provide]) AC_ARG_WITH([aix-soname], [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], [case $withval in aix|svr4|both) ;; *) AC_MSG_ERROR([Unknown argument to --with-aix-soname]) ;; esac lt_cv_with_aix_soname=$with_aix_soname], [AC_CACHE_VAL([lt_cv_with_aix_soname], [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) with_aix_soname=$lt_cv_with_aix_soname]) AC_MSG_RESULT([$with_aix_soname]) if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac _LT_DECL([], [shared_archive_member_spec], [0], [Shared archive member basename, for filename based shared library versioning on AIX])dnl ])# _LT_WITH_AIX_SONAME LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) # _LT_WITH_PIC([MODE]) # -------------------- # implement the --with-pic flag, and support the 'pic-only' and 'no-pic' # LT_INIT options. # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. m4_define([_LT_WITH_PIC], [AC_ARG_WITH([pic], [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], [lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac], [pic_mode=m4_default([$1], [default])]) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) # Old name: AU_DEFUN([AC_LIBTOOL_PICMODE], [_LT_SET_OPTION([LT_INIT], [pic-only]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'pic-only' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) m4_define([_LTDL_MODE], []) LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], [m4_define([_LTDL_MODE], [nonrecursive])]) LT_OPTION_DEFINE([LTDL_INIT], [recursive], [m4_define([_LTDL_MODE], [recursive])]) LT_OPTION_DEFINE([LTDL_INIT], [subproject], [m4_define([_LTDL_MODE], [subproject])]) m4_define([_LTDL_TYPE], []) LT_OPTION_DEFINE([LTDL_INIT], [installable], [m4_define([_LTDL_TYPE], [installable])]) LT_OPTION_DEFINE([LTDL_INIT], [convenience], [m4_define([_LTDL_TYPE], [convenience])]) # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software # Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 6 ltsugar.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) # lt_join(SEP, ARG1, [ARG2...]) # ----------------------------- # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their # associated separator. # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier # versions in m4sugar had bugs. m4_define([lt_join], [m4_if([$#], [1], [], [$#], [2], [[$2]], [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) m4_define([_lt_join], [m4_if([$#$2], [2], [], [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) # lt_car(LIST) # lt_cdr(LIST) # ------------ # Manipulate m4 lists. # These macros are necessary as long as will still need to support # Autoconf-2.59, which quotes differently. m4_define([lt_car], [[$1]]) m4_define([lt_cdr], [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], [$#], 1, [], [m4_dquote(m4_shift($@))])]) m4_define([lt_unquote], $1) # lt_append(MACRO-NAME, STRING, [SEPARATOR]) # ------------------------------------------ # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. # Note that neither SEPARATOR nor STRING are expanded; they are appended # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). # No SEPARATOR is output if MACRO-NAME was previously undefined (different # than defined and empty). # # This macro is needed until we can rely on Autoconf 2.62, since earlier # versions of m4sugar mistakenly expanded SEPARATOR but not STRING. m4_define([lt_append], [m4_define([$1], m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) # ---------------------------------------------------------- # Produce a SEP delimited list of all paired combinations of elements of # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list # has the form PREFIXmINFIXSUFFIXn. # Needed until we can rely on m4_combine added in Autoconf 2.62. m4_define([lt_combine], [m4_if(m4_eval([$# > 3]), [1], [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl [[m4_foreach([_Lt_prefix], [$2], [m4_foreach([_Lt_suffix], ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) # ----------------------------------------------------------------------- # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. m4_define([lt_if_append_uniq], [m4_ifdef([$1], [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], [lt_append([$1], [$2], [$3])$4], [$5])], [lt_append([$1], [$2], [$3])$4])]) # lt_dict_add(DICT, KEY, VALUE) # ----------------------------- m4_define([lt_dict_add], [m4_define([$1($2)], [$3])]) # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) # -------------------------------------------- m4_define([lt_dict_add_subkey], [m4_define([$1($2:$3)], [$4])]) # lt_dict_fetch(DICT, KEY, [SUBKEY]) # ---------------------------------- m4_define([lt_dict_fetch], [m4_ifval([$3], m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) # ----------------------------------------------------------------- m4_define([lt_if_dict_fetch], [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], [$5], [$6])]) # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) # -------------------------------------------------------------- m4_define([lt_dict_filter], [m4_if([$5], [], [], [lt_join(m4_quote(m4_default([$4], [[, ]])), lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl ]) # ltversion.m4 -- version numbers -*- Autoconf -*- # # Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation, # Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # @configure_input@ # serial 4245 ltversion.m4 # This file is part of GNU Libtool m4_define([LT_PACKAGE_VERSION], [2.4.7]) m4_define([LT_PACKAGE_REVISION], [2.4.7]) AC_DEFUN([LTVERSION_VERSION], [macro_version='2.4.7' macro_revision='2.4.7' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free # Software Foundation, Inc. # Written by Scott James Remnant, 2004. # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 5 lt~obsolete.m4 # These exist entirely to fool aclocal when bootstrapping libtool. # # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), # which have later been changed to m4_define as they aren't part of the # exported API, or moved to Autoconf or Automake where they belong. # # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us # using a macro with the same name in our local m4/libtool.m4 it'll # pull the old libtool.m4 in (it doesn't see our shiny new m4_define # and doesn't know about Autoconf macros at all.) # # So we provide this file, which has a silly filename so it's always # included after everything else. This provides aclocal with the # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything # because those macros already exist, or will be overwritten later. # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. # # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. # Yes, that means every name once taken will need to remain here until # we give up compatibility with versions before 1.7, at which point # we need to keep only those names which we still refer to. # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- # serial 11 (pkg-config-0.29.1) dnl Copyright © 2004 Scott James Remnant . dnl Copyright © 2012-2015 Dan Nicholson dnl dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by dnl the Free Software Foundation; either version 2 of the License, or dnl (at your option) any later version. dnl dnl This program is distributed in the hope that it will be useful, but dnl WITHOUT ANY WARRANTY; without even the implied warranty of dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl General Public License for more details. dnl dnl You should have received a copy of the GNU General Public License dnl along with this program; if not, write to the Free Software dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA dnl 02111-1307, USA. dnl dnl As a special exception to the GNU General Public License, if you dnl distribute this file as part of a program that contains a dnl configuration script generated by Autoconf, you may include it under dnl the same distribution terms that you use for the rest of that dnl program. dnl PKG_PREREQ(MIN-VERSION) dnl ----------------------- dnl Since: 0.29 dnl dnl Verify that the version of the pkg-config macros are at least dnl MIN-VERSION. Unlike PKG_PROG_PKG_CONFIG, which checks the user's dnl installed version of pkg-config, this checks the developer's version dnl of pkg.m4 when generating configure. dnl dnl To ensure that this macro is defined, also add: dnl m4_ifndef([PKG_PREREQ], dnl [m4_fatal([must install pkg-config 0.29 or later before running autoconf/autogen])]) dnl dnl See the "Since" comment for each macro you use to see what version dnl of the macros you require. m4_defun([PKG_PREREQ], [m4_define([PKG_MACROS_VERSION], [0.29.1]) m4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1, [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])]) ])dnl PKG_PREREQ dnl PKG_PROG_PKG_CONFIG([MIN-VERSION]) dnl ---------------------------------- dnl Since: 0.16 dnl dnl Search for the pkg-config tool and set the PKG_CONFIG variable to dnl first found in the path. Checks that the version of pkg-config found dnl is at least MIN-VERSION. If MIN-VERSION is not specified, 0.9.0 is dnl used since that's the first version where most current features of dnl pkg-config existed. AC_DEFUN([PKG_PROG_PKG_CONFIG], [m4_pattern_forbid([^_?PKG_[A-Z_]+$]) m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$]) m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$]) AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) fi if test -n "$PKG_CONFIG"; then _pkg_min_version=m4_default([$1], [0.9.0]) AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) PKG_CONFIG="" fi fi[]dnl ])dnl PKG_PROG_PKG_CONFIG dnl PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) dnl ------------------------------------------------------------------- dnl Since: 0.18 dnl dnl Check to see whether a particular set of modules exists. Similar to dnl PKG_CHECK_MODULES(), but does not set variables or print errors. dnl dnl Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) dnl only at the first occurence in configure.ac, so if the first place dnl it's called might be skipped (such as if it is within an "if", you dnl have to call PKG_CHECK_EXISTS manually AC_DEFUN([PKG_CHECK_EXISTS], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl if test -n "$PKG_CONFIG" && \ AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then m4_default([$2], [:]) m4_ifvaln([$3], [else $3])dnl fi]) dnl _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) dnl --------------------------------------------- dnl Internal wrapper calling pkg-config via PKG_CONFIG and setting dnl pkg_failed based on the result. m4_define([_PKG_CONFIG], [if test -n "$$1"; then pkg_cv_[]$1="$$1" elif test -n "$PKG_CONFIG"; then PKG_CHECK_EXISTS([$3], [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes ], [pkg_failed=yes]) else pkg_failed=untried fi[]dnl ])dnl _PKG_CONFIG dnl _PKG_SHORT_ERRORS_SUPPORTED dnl --------------------------- dnl Internal check to see if pkg-config supports short errors. AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], [AC_REQUIRE([PKG_PROG_PKG_CONFIG]) if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi[]dnl ])dnl _PKG_SHORT_ERRORS_SUPPORTED dnl PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], dnl [ACTION-IF-NOT-FOUND]) dnl -------------------------------------------------------------- dnl Since: 0.4.0 dnl dnl Note that if there is a possibility the first call to dnl PKG_CHECK_MODULES might not happen, you should be sure to include an dnl explicit call to PKG_PROG_PKG_CONFIG in your configure.ac AC_DEFUN([PKG_CHECK_MODULES], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl pkg_failed=no AC_MSG_CHECKING([for $1]) _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) _PKG_CONFIG([$1][_LIBS], [libs], [$2]) m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS and $1[]_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details.]) if test $pkg_failed = yes; then AC_MSG_RESULT([no]) _PKG_SHORT_ERRORS_SUPPORTED if test $_pkg_short_errors_supported = yes; then $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1` else $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD m4_default([$4], [AC_MSG_ERROR( [Package requirements ($2) were not met: $$1_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. _PKG_TEXT])[]dnl ]) elif test $pkg_failed = untried; then AC_MSG_RESULT([no]) m4_default([$4], [AC_MSG_FAILURE( [The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. _PKG_TEXT To get pkg-config, see .])[]dnl ]) else $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS $1[]_LIBS=$pkg_cv_[]$1[]_LIBS AC_MSG_RESULT([yes]) $3 fi[]dnl ])dnl PKG_CHECK_MODULES dnl PKG_CHECK_MODULES_STATIC(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], dnl [ACTION-IF-NOT-FOUND]) dnl --------------------------------------------------------------------- dnl Since: 0.29 dnl dnl Checks for existence of MODULES and gathers its build flags with dnl static libraries enabled. Sets VARIABLE-PREFIX_CFLAGS from --cflags dnl and VARIABLE-PREFIX_LIBS from --libs. dnl dnl Note that if there is a possibility the first call to dnl PKG_CHECK_MODULES_STATIC might not happen, you should be sure to dnl include an explicit call to PKG_PROG_PKG_CONFIG in your dnl configure.ac. AC_DEFUN([PKG_CHECK_MODULES_STATIC], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl _save_PKG_CONFIG=$PKG_CONFIG PKG_CONFIG="$PKG_CONFIG --static" PKG_CHECK_MODULES($@) PKG_CONFIG=$_save_PKG_CONFIG[]dnl ])dnl PKG_CHECK_MODULES_STATIC dnl PKG_INSTALLDIR([DIRECTORY]) dnl ------------------------- dnl Since: 0.27 dnl dnl Substitutes the variable pkgconfigdir as the location where a module dnl should install pkg-config .pc files. By default the directory is dnl $libdir/pkgconfig, but the default can be changed by passing dnl DIRECTORY. The user can override through the --with-pkgconfigdir dnl parameter. AC_DEFUN([PKG_INSTALLDIR], [m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])]) m4_pushdef([pkg_description], [pkg-config installation directory @<:@]pkg_default[@:>@]) AC_ARG_WITH([pkgconfigdir], [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],, [with_pkgconfigdir=]pkg_default) AC_SUBST([pkgconfigdir], [$with_pkgconfigdir]) m4_popdef([pkg_default]) m4_popdef([pkg_description]) ])dnl PKG_INSTALLDIR dnl PKG_NOARCH_INSTALLDIR([DIRECTORY]) dnl -------------------------------- dnl Since: 0.27 dnl dnl Substitutes the variable noarch_pkgconfigdir as the location where a dnl module should install arch-independent pkg-config .pc files. By dnl default the directory is $datadir/pkgconfig, but the default can be dnl changed by passing DIRECTORY. The user can override through the dnl --with-noarch-pkgconfigdir parameter. AC_DEFUN([PKG_NOARCH_INSTALLDIR], [m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])]) m4_pushdef([pkg_description], [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@]) AC_ARG_WITH([noarch-pkgconfigdir], [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],, [with_noarch_pkgconfigdir=]pkg_default) AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir]) m4_popdef([pkg_default]) m4_popdef([pkg_description]) ])dnl PKG_NOARCH_INSTALLDIR dnl PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE, dnl [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) dnl ------------------------------------------- dnl Since: 0.28 dnl dnl Retrieves the value of the pkg-config variable for the given module. AC_DEFUN([PKG_CHECK_VAR], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl _PKG_CONFIG([$1], [variable="][$3]["], [$2]) AS_VAR_COPY([$1], [pkg_cv_][$1]) AS_VAR_IF([$1], [""], [$5], [$4])dnl ])dnl PKG_CHECK_VAR dnl PKG_WITH_MODULES(VARIABLE-PREFIX, MODULES, dnl [ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND], dnl [DESCRIPTION], [DEFAULT]) dnl ------------------------------------------ dnl dnl Prepare a "--with-" configure option using the lowercase dnl [VARIABLE-PREFIX] name, merging the behaviour of AC_ARG_WITH and dnl PKG_CHECK_MODULES in a single macro. AC_DEFUN([PKG_WITH_MODULES], [ m4_pushdef([with_arg], m4_tolower([$1])) m4_pushdef([description], [m4_default([$5], [build with ]with_arg[ support])]) m4_pushdef([def_arg], [m4_default([$6], [auto])]) m4_pushdef([def_action_if_found], [AS_TR_SH([with_]with_arg)=yes]) m4_pushdef([def_action_if_not_found], [AS_TR_SH([with_]with_arg)=no]) m4_case(def_arg, [yes],[m4_pushdef([with_without], [--without-]with_arg)], [m4_pushdef([with_without],[--with-]with_arg)]) AC_ARG_WITH(with_arg, AS_HELP_STRING(with_without, description[ @<:@default=]def_arg[@:>@]),, [AS_TR_SH([with_]with_arg)=def_arg]) AS_CASE([$AS_TR_SH([with_]with_arg)], [yes],[PKG_CHECK_MODULES([$1],[$2],$3,$4)], [auto],[PKG_CHECK_MODULES([$1],[$2], [m4_n([def_action_if_found]) $3], [m4_n([def_action_if_not_found]) $4])]) m4_popdef([with_arg]) m4_popdef([description]) m4_popdef([def_arg]) ])dnl PKG_WITH_MODULES dnl PKG_HAVE_WITH_MODULES(VARIABLE-PREFIX, MODULES, dnl [DESCRIPTION], [DEFAULT]) dnl ----------------------------------------------- dnl dnl Convenience macro to trigger AM_CONDITIONAL after PKG_WITH_MODULES dnl check._[VARIABLE-PREFIX] is exported as make variable. AC_DEFUN([PKG_HAVE_WITH_MODULES], [ PKG_WITH_MODULES([$1],[$2],,,[$3],[$4]) AM_CONDITIONAL([HAVE_][$1], [test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"]) ])dnl PKG_HAVE_WITH_MODULES dnl PKG_HAVE_DEFINE_WITH_MODULES(VARIABLE-PREFIX, MODULES, dnl [DESCRIPTION], [DEFAULT]) dnl ------------------------------------------------------ dnl dnl Convenience macro to run AM_CONDITIONAL and AC_DEFINE after dnl PKG_WITH_MODULES check. HAVE_[VARIABLE-PREFIX] is exported as make dnl and preprocessor variable. AC_DEFUN([PKG_HAVE_DEFINE_WITH_MODULES], [ PKG_HAVE_WITH_MODULES([$1],[$2],[$3],[$4]) AS_IF([test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"], [AC_DEFINE([HAVE_][$1], 1, [Enable ]m4_tolower([$1])[ support])]) ])dnl PKG_HAVE_DEFINE_WITH_MODULES # Copyright (C) 2002-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_AUTOMAKE_VERSION(VERSION) # ---------------------------- # Automake X.Y traces this macro to ensure aclocal.m4 has been # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version='1.16' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. m4_if([$1], [1.16.5], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) # _AM_AUTOCONF_VERSION(VERSION) # ----------------------------- # aclocal traces this macro to find the Autoconf version. # This is a private macro too. Using m4_define simplifies # the logic in aclocal, which can simply ignore this definition. m4_define([_AM_AUTOCONF_VERSION], []) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.16.5])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to # '$srcdir', '$srcdir/..', or '$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and # therefore $ac_aux_dir as well) can be either absolute or relative, # depending on how configure is run. This is pretty annoying, since # it makes $ac_aux_dir quite unusable in subdirectories: in the top # source directory, any form will work fine, but in subdirectories a # relative path needs to be adjusted first. # # $ac_aux_dir/missing # fails when called from a subdirectory if $ac_aux_dir is relative # $top_srcdir/$ac_aux_dir/missing # fails if $ac_aux_dir is absolute, # fails when called from a subdirectory in a VPATH build with # a relative $ac_aux_dir # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually # harmless because $srcdir is '.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, # iff we strip the leading $srcdir from $ac_aux_dir. That would be: # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` # and then we would define $MISSING as # MISSING="\${SHELL} $am_aux_dir/missing" # This will work as long as MISSING is not called from configure, because # unfortunately $(top_srcdir) has no meaning in configure. # However there are other variables, like CC, which are often used in # configure, and could therefore not use this "fixed" $ac_aux_dir. # # Another solution, used here, is to always expand $ac_aux_dir to an # absolute PATH. The drawback is that using absolute paths prevent a # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl # Expand $ac_aux_dir to an absolute path. am_aux_dir=`cd "$ac_aux_dir" && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ([2.52])dnl m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE])dnl AC_SUBST([$1_FALSE])dnl _AM_SUBST_NOTMAKE([$1_TRUE])dnl _AM_SUBST_NOTMAKE([$1_FALSE])dnl m4_define([_AM_COND_VALUE_$1], [$2])dnl if $2; then $1_TRUE= $1_FALSE='#' else $1_TRUE='#' $1_FALSE= fi AC_CONFIG_COMMANDS_PRE( [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then AC_MSG_ERROR([[conditional "$1" was never defined. Usually this means the macro was only invoked conditionally.]]) fi])]) # Copyright (C) 1999-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing # CC etc. in the Makefile, will ask for an AC_PROG_CC use... # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular # dependency, and given that the user is not expected to run this macro, # just rely on AC_PROG_CC. AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], [$1], [CXX], [depcc="$CXX" am_compiler_list=], [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], [$1], [UPC], [depcc="$UPC" am_compiler_list=], [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_$1_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi am__universal=false m4_case([$1], [CC], [case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac], [CXX], [case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac]) for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_$1_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) AM_CONDITIONAL([am__fastdep$1], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES. AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE([dependency-tracking], [dnl AS_HELP_STRING( [--enable-dependency-tracking], [do not reject slow dependency extractors]) AS_HELP_STRING( [--disable-dependency-tracking], [speeds up one-time build])]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' am__nodep='_no' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl AC_SUBST([am__nodep])dnl _AM_SUBST_NOTMAKE([am__nodep])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [{ # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. # TODO: see whether this extra hack can be removed once we start # requiring Autoconf 2.70 or later. AS_CASE([$CONFIG_FILES], [*\'*], [eval set x "$CONFIG_FILES"], [*], [set x $CONFIG_FILES]) shift # Used to flag and report bootstrapping failures. am_rc=0 for am_mf do # Strip MF so we end up with the name of the file. am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile which includes # dependency-tracking related rules and includes. # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ || continue am_dirpart=`AS_DIRNAME(["$am_mf"])` am_filepart=`AS_BASENAME(["$am_mf"])` AM_RUN_LOG([cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles]) || am_rc=$? done if test $am_rc -ne 0; then AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments for automatic dependency tracking. If GNU make was not used, consider re-running the configure script with MAKE="gmake" (or whatever is necessary). You can also try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking).]) fi AS_UNSET([am_dirpart]) AS_UNSET([am_filepart]) AS_UNSET([am_mf]) AS_UNSET([am_rc]) rm -f conftest-deps.mk } ])# _AM_OUTPUT_DEPENDENCY_COMMANDS # AM_OUTPUT_DEPENDENCY_COMMANDS # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking is enabled. # This creates each '.Po' and '.Plo' makefile fragment that we'll need in # order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. m4_define([AC_PROG_CC], m4_defn([AC_PROG_CC]) [_AM_PROG_CC_C_O ]) # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- # The call with PACKAGE and VERSION arguments is the old style # call (pre autoconf-2.50), which is being phased out. PACKAGE # and VERSION should now be passed to AC_INIT and removed from # the call to AM_INIT_AUTOMAKE. # We support both call styles for the transition. After # the next Automake release, Autoconf can make the AC_INIT # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.65])dnl m4_ifdef([_$0_ALREADY_INIT], [m4_fatal([$0 expanded multiple times ]m4_defn([_$0_ALREADY_INIT]))], [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl # test to see if srcdir already configured if test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], [AC_DIAGNOSE([obsolete], [$0: two- and three-arguments forms are deprecated.]) m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. m4_if( m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]), [ok:ok],, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) AM_MISSING_PROG([AUTOCONF], [autoconf]) AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) AM_MISSING_PROG([AUTOHEADER], [autoheader]) AM_MISSING_PROG([MAKEINFO], [makeinfo]) AC_REQUIRE([AM_PROG_INSTALL_SH])dnl AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl AC_REQUIRE([AC_PROG_MKDIR_P])dnl # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: # # AC_SUBST([mkdir_p], ['$(MKDIR_P)']) # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES([CC])], [m4_define([AC_PROG_CC], m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES([CXX])], [m4_define([AC_PROG_CXX], m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], [_AM_DEPENDENCIES([OBJC])], [m4_define([AC_PROG_OBJC], m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], [_AM_DEPENDENCIES([OBJCXX])], [m4_define([AC_PROG_OBJCXX], m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl ]) # Variables for tags utilities; see am/tags.am if test -z "$CTAGS"; then CTAGS=ctags fi AC_SUBST([CTAGS]) if test -z "$ETAGS"; then ETAGS=etags fi AC_SUBST([ETAGS]) if test -z "$CSCOPE"; then CSCOPE=cscope fi AC_SUBST([CSCOPE]) AC_REQUIRE([AM_SILENT_RULES])dnl dnl The testsuite driver may need to know about EXEEXT, so add the dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. AC_CONFIG_COMMANDS_PRE(dnl [m4_provide_if([_AM_COMPILER_EXEEXT], [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl # POSIX will say in a future version that running "rm -f" with no argument # is OK; and we want to be able to make that assumption in our Makefile # recipes. So use an aggressive probe to check that the usage we want is # actually supported "in the wild" to an acceptable degree. # See automake bug#10828. # To make any issue more visible, cause the running configure to be aborted # by default if the 'rm' program in use doesn't match our expectations; the # user can still override this though. if true; then : OK; else cat >&2 <<'END' Oops! Your 'rm' program seems unable to run without file operands specified on the command line, even when the '-f' option is present. This is contrary to the behaviour of most rm programs out there, and not conforming with the upcoming POSIX standard: Please tell bug-automake@gnu.org about your system, including the value of your $PATH and any error possibly output before this message. This can help us improve future automake versions. END if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then echo 'Configuration will proceed anyway, since you have set the' >&2 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 echo >&2 else cat >&2 <<'END' Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM to "yes", and re-run configure. END AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) fi fi dnl The trailing newline in this macro's definition is deliberate, for dnl backward compatibility and to allow trailing 'dnl'-style comments dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. ]) dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further dnl mangled by Autoconf and run in a shell conditional statement. m4_define([_AC_COMPILER_EXEEXT], m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the # loop where config.status creates the headers, so we can generate # our stamp files there. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers. _am_arg=$1 _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $_am_arg | $_am_arg:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; *) install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi AC_SUBST([install_sh])]) # Copyright (C) 2003-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_MAKE_INCLUDE() # ----------------- # Check whether make has an 'include' directive that can support all # the idioms we need for our automatic dependency tracking code. AC_DEFUN([AM_MAKE_INCLUDE], [AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive]) cat > confinc.mk << 'END' am__doit: @echo this is the am__doit target >confinc.out .PHONY: am__doit END am__include="#" am__quote= # BSD make does it like this. echo '.include "confinc.mk" # ignored' > confmf.BSD # Other make implementations (GNU, Solaris 10, AIX) do it like this. echo 'include confinc.mk # ignored' > confmf.GNU _am_result=no for s in GNU BSD; do AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out]) AS_CASE([$?:`cat confinc.out 2>/dev/null`], ['0:this is the am__doit target'], [AS_CASE([$s], [BSD], [am__include='.include' am__quote='"'], [am__include='include' am__quote=''])]) if test "$am__include" != "#"; then _am_result="yes ($s style)" break fi done rm -f confinc.* confmf.* AC_MSG_RESULT([${_am_result}]) AC_SUBST([am__include])]) AC_SUBST([am__quote])]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN]) $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) # AM_MISSING_HAS_RUN # ------------------ # Define MISSING if not defined so far and test if it is modern enough. # If it is, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl if test x"${MISSING+set}" != xset; then MISSING="\${SHELL} '$am_aux_dir/missing'" fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then am_missing_run="$MISSING " else am_missing_run= AC_MSG_WARN(['missing' script is too old or missing]) fi ]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) # -------------------- # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), [1])]) # _AM_SET_OPTIONS(OPTIONS) # ------------------------ # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) # ------------------------------------------- # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) # Copyright (C) 1999-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_PROG_CC_C_O # --------------- # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC # to automatically call this. AC_DEFUN([_AM_PROG_CC_C_O], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([compile])dnl AC_LANG_PUSH([C])dnl AC_CACHE_CHECK( [whether $CC understands -c and -o together], [am_cv_prog_cc_c_o], [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) # Make sure it works both with $CC and with simple cc. # Following AC_PROG_CC_C_O, we do the test twice because some # compilers refuse to overwrite an existing .o file with -o, # though they will create one. am_cv_prog_cc_c_o=yes for am_i in 1 2; do if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ && test -f conftest2.$ac_objext; then : OK else am_cv_prog_cc_c_o=no break fi done rm -f core conftest* unset am_i]) if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. # But if we don't then we get into trouble of one sort or another. # A longer-term fix would be to have automake use am__CC in this case, # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" CC="$am_aux_dir/compile $CC" fi AC_LANG_POP([C])]) # For backward compatibility. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_RUN_LOG(COMMAND) # ------------------- # Run COMMAND, save the exit status in ac_status, and log it. # (This has been adapted from Autoconf's _AC_RUN_LOG macro.) AC_DEFUN([AM_RUN_LOG], [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD (exit $ac_status); }]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[[\\\"\#\$\&\'\`$am_lf]]*) AC_MSG_ERROR([unsafe absolute working directory name]);; esac case $srcdir in *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; esac # Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( am_has_slept=no for am_try in 1 2; do echo "timestamp, slept: $am_has_slept" > conftest.file set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` if test "$[*]" = "X"; then # -L didn't work. set X `ls -t "$srcdir/configure" conftest.file` fi if test "$[*]" != "X $srcdir/configure conftest.file" \ && test "$[*]" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken alias in your environment]) fi if test "$[2]" = conftest.file || test $am_try -eq 2; then break fi # Just in case. sleep 1 am_has_slept=yes done test "$[2]" = conftest.file ) then # Ok. : else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi AC_MSG_RESULT([yes]) # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= if grep 'slept: no' conftest.file >/dev/null 2>&1; then ( sleep 1 ) & am_sleep_pid=$! fi AC_CONFIG_COMMANDS_PRE( [AC_MSG_CHECKING([that generated files are newer than configure]) if test -n "$am_sleep_pid"; then # Hide warnings about reused PIDs. wait $am_sleep_pid 2>/dev/null fi AC_MSG_RESULT([done])]) rm -f conftest.file ]) # Copyright (C) 2009-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_SILENT_RULES([DEFAULT]) # -------------------------- # Enable less verbose build rules; with the default set to DEFAULT # ("yes" being less verbose, "no" or empty being verbose). AC_DEFUN([AM_SILENT_RULES], [AC_ARG_ENABLE([silent-rules], [dnl AS_HELP_STRING( [--enable-silent-rules], [less verbose build output (undo: "make V=1")]) AS_HELP_STRING( [--disable-silent-rules], [verbose build output (undo: "make V=0")])dnl ]) case $enable_silent_rules in @%:@ ((( yes) AM_DEFAULT_VERBOSITY=0;; no) AM_DEFAULT_VERBOSITY=1;; *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; esac dnl dnl A few 'make' implementations (e.g., NonStop OS and NextStep) dnl do not support nested variable expansions. dnl See automake bug#9928 and bug#10237. am_make=${MAKE-make} AC_CACHE_CHECK([whether $am_make supports nested variables], [am_cv_make_support_nested_variables], [if AS_ECHO([['TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 am__doit: @$(TRUE) .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no fi]) if test $am_cv_make_support_nested_variables = yes; then dnl Using '$V' instead of '$(V)' breaks IRIX make. AM_V='$(V)' AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' else AM_V=$AM_DEFAULT_VERBOSITY AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY fi AC_SUBST([AM_V])dnl AM_SUBST_NOTMAKE([AM_V])dnl AC_SUBST([AM_DEFAULT_V])dnl AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl AC_SUBST([AM_DEFAULT_VERBOSITY])dnl AM_BACKSLASH='\' AC_SUBST([AM_BACKSLASH])dnl _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl ]) # Copyright (C) 2001-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_STRIP # --------------------- # One issue with vendor 'install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we # always use install-sh in "make install-strip", and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl # Installed binaries are usually stripped using 'strip' when the user # run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the 'STRIP' environment variable to overrule this program. dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # Copyright (C) 2006-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_SUBST_NOTMAKE(VARIABLE) # --------------------------- # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. # This macro is traced by Automake. AC_DEFUN([_AM_SUBST_NOTMAKE]) # AM_SUBST_NOTMAKE(VARIABLE) # -------------------------- # Public sister of _AM_SUBST_NOTMAKE. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- # Copyright (C) 2004-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. # FORMAT should be one of 'v7', 'ustar', or 'pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory # $tardir. # tardir=directory && $(am__tar) > result.tar # # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar # AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AC_SUBST([AMTAR], ['$${TAR-tar}']) # We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' m4_if([$1], [v7], [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], [m4_case([$1], [ustar], [# The POSIX 1988 'ustar' format is defined with fixed-size fields. # There is notably a 21 bits limit for the UID and the GID. In fact, # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 # and bug#13588). am_max_uid=2097151 # 2^21 - 1 am_max_gid=$am_max_uid # The $UID and $GID variables are not portable, so we need to resort # to the POSIX-mandated id(1) utility. Errors in the 'id' calls # below are definitely unexpected, so allow the users to see them # (that is, avoid stderr redirection). am_uid=`id -u || echo unknown` am_gid=`id -g || echo unknown` AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) if test $am_uid -le $am_max_uid; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) _am_tools=none fi AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) if test $am_gid -le $am_max_gid; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) _am_tools=none fi], [pax], [], [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Go ahead even if we have the value already cached. We do so because we # need to set the values for the 'am__tar' and 'am__untar' variables. _am_tools=${am_cv_prog_tar_$1-$_am_tools} for _am_tool in $_am_tools; do case $_am_tool in gnutar) for _am_tar in tar gnutar gtar; do AM_RUN_LOG([$_am_tar --version]) && break done am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' am__untar="$_am_tar -xf -" ;; plaintar) # Must skip GNU tar: if it does not support --format= it doesn't create # ustar tarball either. (tar --version) >/dev/null 2>&1 && continue am__tar='tar chf - "$$tardir"' am__tar_='tar chf - "$tardir"' am__untar='tar xf -' ;; pax) am__tar='pax -L -x $1 -w "$$tardir"' am__tar_='pax -L -x $1 -w "$tardir"' am__untar='pax -r' ;; cpio) am__tar='find "$$tardir" -print | cpio -o -H $1 -L' am__tar_='find "$tardir" -print | cpio -o -H $1 -L' am__untar='cpio -i -H $1 -d' ;; none) am__tar=false am__tar_=false am__untar=false ;; esac # If the value was cached, stop now. We just wanted to have am__tar # and am__untar set. test -n "${am_cv_prog_tar_$1}" && break # tar/untar a dummy directory, and stop if the command works. rm -rf conftest.dir mkdir conftest.dir echo GrepMe > conftest.dir/file AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) rm -rf conftest.dir if test -s conftest.tar; then AM_RUN_LOG([$am__untar /dev/null 2>&1 && break fi done rm -rf conftest.dir AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) AC_MSG_RESULT([$am_cv_prog_tar_$1])]) AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR mlterm-3.9.3/android/000077500000000000000000000000001441203364000144435ustar00rootroot00000000000000mlterm-3.9.3/android/AndroidManifest.xml000066400000000000000000000030741441203364000202400ustar00rootroot00000000000000 mlterm-3.9.3/android/build-ant.sh000066400000000000000000000020251441203364000166550ustar00rootroot00000000000000#!/bin/sh if test "$ANDROID_HOME" = ""; then echo "export ANDROID_HOME= in avance." exit 1 #ANDROID_HOME=/cygdrive/c/Program\ Files/Android/android-sdk fi if test "$ANDROID_NDK_HOME" = ""; then echo "export ANDROID_NDK_HOME= in avance." exit 1 #ANDROID_NDK_HOME=/cygdrive/c/Users/${USER}/workspace/android-ndk-r8e fi if test "$JAVA_HOME" = ""; then echo "export JAVA_HOME= in advance." exit 1 #export JAVA_HOME=c:\\Program\ Files\ \(x86\)\\Java\\jdk1.8.0_172 fi # Requires android-11 or later. "${ANDROID_HOME}/tools/android.bat" update project --path . --target android-11 (cd jni ; ${ANDROID_NDK_HOME}/ndk-build APP_ABI=all V=1) ant release jarsigner -verbose -sigalg MD5withRSA -digestalg SHA1 bin/mlterm-release-unsigned.apk mlterm #"${ANDROID_HOME}/platform-tools/adb" connect localhost #"${ANDROID_HOME}/platform-tools/adb" uninstall mlterm.native_activity "${ANDROID_HOME}/platform-tools/adb" install -r bin/mlterm-release-unsigned.apk "${ANDROID_HOME}/platform-tools/adb" logcat mlterm-3.9.3/android/build-gradle.sh000077500000000000000000000013151441203364000173350ustar00rootroot00000000000000#!/bin/sh if test "$ANDROID_HOME" = ""; then echo "export ANDROID_HOME= in avance." exit 1 fi if test "$ANDROID_NDK_HOME" = ""; then echo "export ANDROID_NDK_HOME= in avance." exit 1 fi if test "$JAVA_HOME" = ""; then echo "export JAVA_HOME= in advance." exit 1 fi V=1 ./gradlew assembleRelease jarsigner -verbose -sigalg MD5withRSA -digestalg SHA1 app/build/outputs/apk/release/app-release-unsigned.apk mlterm #"${ANDROID_HOME}/platform-tools/adb" connect localhost #"${ANDROID_HOME}/platform-tools/adb" uninstall mlterm.native_activity "${ANDROID_HOME}/platform-tools/adb" install -r bin/mlterm-release-unsigned.apk "${ANDROID_HOME}/platform-tools/adb" logcat mlterm-3.9.3/android/build.gradle000066400000000000000000000014071441203364000167240ustar00rootroot00000000000000apply plugin: 'com.android.application' android { defaultConfig { minSdkVersion 14 targetSdkVersion 24 compileSdkVersion 24 ndk { abiFilters 'x86', 'armeabi-v7a' } } externalNativeBuild { ndkBuild { path 'src/main/jni/Android.mk' } } buildTypes { debug { externalNativeBuild { ndkBuild { arguments 'LOCAL_CFLAGS_DEB+=-DBL_DEBUG', 'LOCAL_CFLAGS_DEB+=-DDEBUG' } } } release { externalNativeBuild { ndkBuild { } } } } lintOptions { checkReleaseBuilds false abortOnError false } } mlterm-3.9.3/android/build.xml000066400000000000000000000076521441203364000162760ustar00rootroot00000000000000 mlterm-3.9.3/android/jni/000077500000000000000000000000001441203364000152235ustar00rootroot00000000000000mlterm-3.9.3/android/jni/Android.mk000066400000000000000000000226731441203364000171460ustar00rootroot00000000000000LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := mlterm ifneq (,$(wildcard src/main/jni)) JNI_PATH := src/main/jni/ else JNI_PATH := endif ifneq (,$(wildcard $(JNI_PATH)fribidi/fribidi.c)) FRIBIDI_SRC_FILES := fribidi/fribidi.c fribidi/fribidi-arabic.c \ fribidi/fribidi-bidi.c fribidi/fribidi-bidi-types.c \ fribidi/fribidi-deprecated.c fribidi/fribidi-joining.c \ fribidi/fribidi-joining-types.c fribidi/fribidi-mem.c \ fribidi/fribidi-mirroring.c fribidi/fribidi-run.c fribidi/fribidi-shape.c \ vtemu/libctl/vt_bidi.c vtemu/libctl/vt_shape_bidi.c \ vtemu/libctl/vt_line_bidi.c FRIBIDI_CFLAGS := -DUSE_FRIBIDI FRIBIDI_INCLUDES := $(JNI_PATH)fribidi endif ifneq (,$(wildcard $(JNI_PATH)freetype/$(TARGET_ARCH_ABI)/lib/libfreetype.a)) FT_CFLAGS := -DUSE_FREETYPE FT_INCLUDES := $(JNI_PATH)freetype/$(TARGET_ARCH_ABI)/include/freetype2 FT_LDLIBS := $(JNI_PATH)freetype/$(TARGET_ARCH_ABI)/lib/libfreetype.a #FT_LDLIBS := -L$(JNI_PATH)freetype/$(TARGET_ARCH_ABI)/lib #FT_STATICLIBS := freetype ifneq (,$(wildcard $(JNI_PATH)libotf/otfopen.c)) OTL_SRC_FILES := libotf/otfopen.c libotf/otfdrive.c libotf/otferror.c uitoolkit/libotl/otf.c OTL_CFLAGS := -DUSE_OT_LAYOUT -DNO_DYNAMIC_LOAD_OTL OTL_INCLUDES := $(JNI_PATH)libotf $(JNI_PATH)uitoolkit/libotl else OTL_SRC_FILES := OTL_CFLAGS := OTL_INCLUDES := endif else FT_CFLAGS := FT_INCLUDES := FT_LDLIBS := #FT_STATICLIBS := OTL_SRC_FILES := OTL_CFLAGS := endif ifneq (,$(wildcard $(JNI_PATH)libssh2/$(TARGET_ARCH_ABI)/lib/libssh2.a)) LIBSSH2_SRC_FILES := vtemu/vt_pty_ssh.c LIBSSH2_CFLAGS := -DUSE_LIBSSH2 -DNO_DYNAMIC_LOAD_SSH LIBSSH2_INCLUDES := $(JNI_PATH)libssh2/$(TARGET_ARCH_ABI)/include LIBSSH2_LDLIBS := $(JNI_PATH)libssh2/$(TARGET_ARCH_ABI)/lib/libssh2.a $(JNI_PATH)libssh2/$(TARGET_ARCH_ABI)/lib/libcrypto.a -lz #LIBSSH2_LDLIBS := -L$(JNI_PATH)libssh2/$(TARGET_ARCH_ABI)/lib -lz #LIBSSH2_STATICLIBS := ssh2 crypto ifneq (,$(wildcard $(JNI_PATH)protobuf/$(TARGET_ARCH_ABI)/lib/libprotobuf.a)) MOSH_SRC_FILES := vtemu/libptymosh/userinput.pb.cc vtemu/libptymosh/vt_pty_mosh.cpp \ vtemu/libptymosh/hostinput.pb.cc vtemu/libptymosh/transportinstruction.pb.cc \ vtemu/libptymosh/compressor.cc vtemu/libptymosh/network.cc \ vtemu/libptymosh/transportfragment.cc vtemu/libptymosh/base64.cc vtemu/libptymosh/crypto.cc \ vtemu/libptymosh/ocb.cc vtemu/libptymosh/parser.cc vtemu/libptymosh/parseraction.cc \ vtemu/libptymosh/parserstate.cc vtemu/libptymosh/terminal.cc \ vtemu/libptymosh/terminaldispatcher.cc vtemu/libptymosh/terminaldisplay.cc \ vtemu/libptymosh/terminaldisplayinit.cc vtemu/libptymosh/terminalframebuffer.cc \ vtemu/libptymosh/terminalfunctions.cc vtemu/libptymosh/terminaluserinput.cc \ vtemu/libptymosh/timestamp.cc vtemu/libptymosh/completeterminal.cc \ vtemu/libptymosh/user.cc vtemu/libptymosh/terminaloverlay.cc MOSH_INCLUDES := $(JNI_PATH)protobuf/$(TARGET_ARCH_ABI)/include $(JNI_PATH)vtemu/libptymosh # If you use -lc++_shared, add "APP_STL := c++_shared" to Aplication.mk # (See https://developer.android.com/ndk/guides/cpp-support?hl=ja) MOSH_LDLIBS := $(JNI_PATH)protobuf/$(TARGET_ARCH_ABI)/lib/libprotobuf.a -lc++_static else MOSH_SRC_FILES := vtemu/vt_pty_mosh.c endif else LIBSSH2_SRC_FILES := LIBSSH2_CFLAGS := LIBSSH2_INCLUDES := #LIBSSH2_LDLIBS := #LIBSSH2_STATICLIBS := MOSH_SRC_FILES := MOSH_INCLUDES := MOSH_LDLIBS := endif LOCAL_SRC_FILES := baselib/src/bl_map.c baselib/src/bl_args.c \ baselib/src/bl_mem.c baselib/src/bl_conf.c baselib/src/bl_file.c \ baselib/src/bl_path.c baselib/src/bl_conf_io.c baselib/src/bl_str.c \ baselib/src/bl_cycle_index.c baselib/src/bl_langinfo.c baselib/src/bl_time.c \ baselib/src/bl_locale.c baselib/src/bl_privilege.c baselib/src/bl_unistd.c \ baselib/src/bl_sig_child.c baselib/src/bl_dialog.c baselib/src/bl_pty_streams.c \ baselib/src/bl_utmp_none.c baselib/src/bl_dlfcn.c baselib/src/bl_dlfcn_dl.c \ baselib/src/bl_util.c \ encodefilter/src/ef_parser.c encodefilter/src/ef_iso2022_parser.c encodefilter/src/ef_iso8859_parser.c \ encodefilter/src/ef_xct_parser.c encodefilter/src/ef_eucjp_parser.c encodefilter/src/ef_euckr_parser.c \ encodefilter/src/ef_euccn_parser.c encodefilter/src/ef_iso2022jp_parser.c \ encodefilter/src/ef_iso2022kr_parser.c encodefilter/src/ef_sjis_parser.c encodefilter/src/ef_big5_parser.c \ encodefilter/src/ef_euctw_parser.c encodefilter/src/ef_utf16_parser.c encodefilter/src/ef_iso2022cn_parser.c \ encodefilter/src/ef_hz_parser.c encodefilter/src/ef_utf8_parser.c encodefilter/src/ef_johab_parser.c \ encodefilter/src/ef_8bit_parser.c encodefilter/src/ef_utf32_parser.c encodefilter/src/ef_codepoint_parser.c \ encodefilter/src/ef_iso8859_conv.c encodefilter/src/ef_iso2022_conv.c encodefilter/src/ef_iso2022jp_conv.c \ encodefilter/src/ef_iso2022kr_conv.c encodefilter/src/ef_sjis_conv.c encodefilter/src/ef_utf8_conv.c \ encodefilter/src/ef_big5_conv.c encodefilter/src/ef_euctw_conv.c encodefilter/src/ef_iso2022cn_conv.c \ encodefilter/src/ef_hz_conv.c encodefilter/src/ef_utf16_conv.c encodefilter/src/ef_eucjp_conv.c \ encodefilter/src/ef_euckr_conv.c encodefilter/src/ef_euccn_conv.c encodefilter/src/ef_johab_conv.c \ encodefilter/src/ef_8bit_conv.c encodefilter/src/ef_xct_conv.c encodefilter/src/ef_utf32_conv.c \ encodefilter/src/ef_ucs4_map.c encodefilter/src/ef_locale_ucs4_map.c encodefilter/src/ef_zh_cn_map.c \ encodefilter/src/ef_zh_tw_map.c encodefilter/src/ef_zh_hk_map.c encodefilter/src/ef_ko_kr_map.c \ encodefilter/src/ef_viet_map.c encodefilter/src/ef_ja_jp_map.c encodefilter/src/ef_ru_map.c \ encodefilter/src/ef_uk_map.c encodefilter/src/ef_tg_map.c encodefilter/src/ef_ucs_property.c \ encodefilter/src/ef_jis_property.c \ encodefilter/src/ef_char.c encodefilter/src/ef_sjis_env.c encodefilter/src/ef_tblfunc_loader.c \ encodefilter/src/ef_ucs4_iso8859.c encodefilter/src/ef_ucs4_viscii.c \ encodefilter/src/ef_ucs4_tcvn5712_1.c encodefilter/src/ef_ucs4_koi8.c encodefilter/src/ef_ucs4_georgian_ps.c \ encodefilter/src/ef_ucs4_cp125x.c encodefilter/src/ef_ucs4_iscii.c encodefilter/src/ef_ucs4_jisx0201.c \ encodefilter/src/ef_ucs4_jisx0208.c encodefilter/src/ef_ucs4_jisx0212.c encodefilter/src/ef_ucs4_jisx0213.c \ encodefilter/src/ef_ucs4_ksc5601.c encodefilter/src/ef_ucs4_uhc.c encodefilter/src/ef_ucs4_johab.c \ encodefilter/src/ef_ucs4_gb2312.c encodefilter/src/ef_ucs4_gbk.c encodefilter/src/ef_ucs4_big5.c \ encodefilter/src/ef_ucs4_cns11643.c encodefilter/src/ef_gb18030_2000_intern.c \ vtemu/vt_char.c vtemu/vt_str.c vtemu/vt_line.c vtemu/vt_model.c \ vtemu/vt_char_encoding.c vtemu/vt_color.c vtemu/vt_edit.c \ vtemu/vt_line_shape.c vtemu/vt_edit_util.c \ vtemu/vt_edit_scroll.c vtemu/vt_cursor.c vtemu/vt_logical_visual.c \ vtemu/vt_logs.c vtemu/vt_screen.c vtemu/vt_shape.c vtemu/vt_str_parser.c \ vtemu/vt_term.c vtemu/vt_parser.c vtemu/vt_term_manager.c vtemu/vt_bidi.c \ vtemu/vt_config_menu.c vtemu/vt_config_proto.c \ vtemu/vt_termcap.c vtemu/vt_pty.c vtemu/vt_pty_unix.c vtemu/vt_drcs.c \ libind/indian.c libind/lex.split.c vtemu/libctl/vt_iscii.c \ vtemu/libctl/vt_shape_iscii.c vtemu/libctl/vt_line_iscii.c \ vtemu/vt_ot_layout.c vtemu/vt_transfer.c vtemu/zmodem.c \ $(OTL_SRC_FILES) $(FRIBIDI_SRC_FILES) $(LIBSSH2_SRC_FILES) $(MOSH_SRC_FILES) \ uitoolkit/fb/ui.c uitoolkit/fb/ui_font.c uitoolkit/ui_mod_meta_mode.c uitoolkit/ui_shortcut.c \ uitoolkit/ui_bel_mode.c uitoolkit/ui_font_cache.c uitoolkit/ui_picture.c \ uitoolkit/fb/ui_color.c uitoolkit/ui_font_config.c uitoolkit/ui_sb_mode.c \ uitoolkit/ui_color_cache.c uitoolkit/ui_font_manager.c uitoolkit/ui_type_engine.c \ uitoolkit/ui_color_manager.c uitoolkit/fb/ui_gc.c uitoolkit/fb/ui_decsp_font.c \ uitoolkit/fb/ui_connect_dialog.c uitoolkit/ui_im.c uitoolkit/ui_copymode.c \ uitoolkit/fb/ui_window.c uitoolkit/fb/ui_display.c uitoolkit/ui_im_candidate_screen.c \ uitoolkit/ui_screen.c uitoolkit/fb/ui_xic.c uitoolkit/fb/ui_dnd.c \ uitoolkit/ui_im_status_screen.c uitoolkit/ui_screen_manager.c uitoolkit/ui_draw_str.c \ uitoolkit/fb/ui_imagelib.c uitoolkit/ui_event_source.c \ uitoolkit/ui_main_config.c uitoolkit/ui_selection.c \ uitoolkit/ui_layout.c uitoolkit/ui_simple_sb_view.c \ uitoolkit/ui_sb_view_factory.c uitoolkit/ui_scrollbar.c \ uitoolkit/fb/ui_selection_encoding.c uitoolkit/ui_emoji.c uitoolkit/test.c \ main/daemon.c main/main_loop.c main/main.c LOCAL_CFLAGS := -DNO_DYNAMIC_LOAD_TABLE -DNO_DYNAMIC_LOAD_CTL -DSTATIC_LINK_INDIC_TABLES -DUSE_IND $(FRIBIDI_CFLAGS) $(FT_CFLAGS) $(OTL_CFLAGS) $(LIBSSH2_CFLAGS) $(MOSH_CFLAGS) -DLIBDIR=\"/sdcard/.mlterm/lib/\" -DNO_DYNAMIC_LOAD_TYPE -DUSE_TYPE_XCORE -DLIBEXECDIR=\"/sdcard/.mlterm/libexec/\" -DUSE_FRAMEBUFFER -DBUILTIN_IMAGELIB -DNO_DYNAMIC_LOAD_TRANSFER -DUSE_COMPACT_TRUECOLOR $(LOCAL_CFLAGS_DEB) LOCAL_LDLIBS := $(FT_LDLIBS) $(MOSH_LDLIBS) $(LIBSSH2_LDLIBS) -llog -landroid LOCAL_C_INCLUDES := $(JNI_PATH)baselib $(JNI_PATH)encodefilter $(JNI_PATH)vtemu $(JNI_PATH)uitoolkit $(JNI_PATH)libind $(FRIBIDI_INCLUDES) $(FT_INCLUDES) $(OTL_INCLUDES) $(LIBSSH2_INCLUDES) $(MOSH_INCLUDES) LOCAL_STATIC_LIBRARIES := android_native_app_glue #$(FT_STATICLIBS) $(LIBSSH2_STATICLIBS) #APP_ALLOW_MISSING_DEPS := true LOCAL_ALLOW_UNDEFINED_SYMBOLS := true # android ndk disables C++ exception by default. LOCAL_CPPFLAGS := -fexceptions -frtti include $(BUILD_SHARED_LIBRARY) $(call import-module,android/native_app_glue) mlterm-3.9.3/android/jni/bl_config.h000066400000000000000000000030401441203364000173130ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* * Don't include directly this header. * Include bl_def.h (which wraps POSIX and bl_config.h macros) or bl_types.h * (which wraps POSIX and bl_config.h types). */ #ifndef __BL_CONFIG_H__ #define __BL_CONFIG_H__ #define HAVE_GNU_SOURCE #undef HAVE_LANGINFO_H #define HAVE_DL_H #undef HAVE_DLFCN_H #undef HAVE_WINDOWS_H #define HAVE_ERRNO_H #undef WORDS_BIGENDIAN #define HAVE_STRSEP #define HAVE_FGETLN #define HAVE_BASENAME #define HAVE_ALLOCA #define HAVE_ALLOCA_H #undef HAVE_STROPTS_H #undef HAVE_SYS_STROPTS_H #undef HAVE_ISASTREAM #define HAVE_SETUTENT #define HAVE_SETEUID #define HAVE_SETEGID #define HAVE_GETEUID #define HAVE_SETSID #define HAVE_GETUID #define HAVE_GETGID #define HAVE_RECVMSG #define HAVE_SETPGID #define HAVE_SOCKETPAIR #define HAVE_SNPRINTF #undef CONCATABLE_FUNCTION #undef DLFCN_NONE #define HAVE_USLEEP #define HAVE_SETENV #define HAVE_UNSETENV #define HAVE_FLOCK #define HAVE_KILLPG #undef HAVE_POSIX_OPENPT #define HAVE_GETTIMEOFDAY #undef USE_WIN32API #define HAVE_STDINT_H #define REMOVE_FUNCS_MLTERM_UNUSE #define CALLOC_CHECK_OVERFLOW #undef inline #undef const #undef u_char #undef u_short #undef u_int #undef u_long #undef u_int8_t #undef u_int8_t #undef u_int16_t #undef u_int32_t #undef u_int64_t #undef int8_t #undef int8_t #undef int16_t #undef int32_t #undef int64_t #undef ssize_t #undef socklen_t #undef mode_t #undef pid_t #undef uid_t #undef gid_t #undef off_t #undef size_t #endif mlterm-3.9.3/android/jni/bl_debug.h000066400000000000000000000023701441203364000171410ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_DEBUG_H__ #define __BL_DEBUG_H__ #include "bl_def.h" #include "bl_util.h" /* BL_INT_TO_STR */ #include /* for bl_{debug|warn}_printf */ #if 0 #ifdef CONCATABLE_FUNCTION #define BL_DEBUG_TAG "[" __FUNCTION__ "()]" #else #define BL_DEBUG_TAG "[" __FILE__ "]" #endif #else #define BL_DEBUG_TAG "[" __FILE__ ":" BL_INT_TO_STR(__LINE__) "]" #endif #ifdef BL_DEBUG #define BL_TESTIT(func, args) TEST_##func args #define BL_TESTIT_ONCE(func, args) \ { \ static int func##_tested; \ if (!func##_tested) { \ func##_tested = 1; \ TEST_##func args; \ } \ } #else #define BL_TESTIT(func, args) #define BL_TESTIT_ONCE(func, args) #endif #define bl_debug_printf(...) (__android_log_print(ANDROID_LOG_INFO, "", __VA_ARGS__) >= 0) #define bl_warn_printf(...) (__android_log_print(ANDROID_LOG_WARN, "", __VA_ARGS__) >= 0) #define bl_error_printf(...) (__android_log_print(ANDROID_LOG_ERROR, "", __VA_ARGS__) >= 0) #define bl_msg_printf(...) (__android_log_print(ANDROID_LOG_INFO, "", __VA_ARGS__) >= 0) #define bl_set_msg_log_file_name(name) (0) #endif mlterm-3.9.3/android/jni/main.c000066400000000000000000000051451441203364000163200ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include #include #include #include #if 0 #include #endif #include "uitoolkit/fb/ui_display.h" #include "uitoolkit/ui_event_source.h" #ifdef SYSCONFDIR #define CONFIG_PATH SYSCONFDIR #else #define CONFIG_PATH "/etc" #endif #if 0 #define SAVE_DEFAULT_FONT #endif #ifdef SAVE_DEFAULT_FONT /* --- global variables --- */ char *default_font_path; /* --- static functions --- */ static inline void save_default_font(ANativeActivity *activity) { JNIEnv *env; jobject this; jstring jstr; const char *path; if (default_font_path || (*activity->vm)->GetEnv(activity->vm, &env, JNI_VERSION_1_6) != JNI_OK) { return; } this = activity->clazz; jstr = (*env)->CallObjectMethod( env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "saveDefaultFont", "()Ljava/lang/String;")); path = (*env)->GetStringUTFChars(env, jstr, NULL); default_font_path = strdup(path); (*env)->ReleaseStringUTFChars(env, jstr, path); } #endif /* SAVE_DEFAULT_FONT */ static void attach_current_thread(JavaVM *vm) { JNIEnv *env; (*vm)->AttachCurrentThread(vm, &env, NULL); } static void detach_current_thread(JavaVM *vm) { (*vm)->DetachCurrentThread(vm); } static void finish(struct android_app *app) { int ident; int events; struct android_poll_source *source; ui_display_final(); /* Calls ANativeActivity_finish() */ while ((ident = ALooper_pollAll(-1, NULL, &events, (void **)&source)) >= 0 && ui_display_process_event(source, ident)); } /* --- global functions --- */ void android_main(struct android_app *app) { int argc = 1; char *argv[] = {"mlterm"}; #if 0 prctl(PR_SET_DUMPABLE, 1, 0, 0, 0); #endif #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " android_main started.\n"); #endif bl_set_sys_conf_dir(CONFIG_PATH); attach_current_thread(app->activity->vm); #ifdef SAVE_DEFAULT_FONT save_default_font(app->activity); #endif if (ui_display_init(app) && /* ui_display_init() returns 1 only once. */ !main_loop_init(argc, argv)) /* main_loop_init() is called once. */ { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " main_loop_init() failed.\n"); #endif finish(app); } else if (!main_loop_start()) { /* Unable to open any screen. */ finish(app); } /* Only screen objects are closed. */ ui_screen_manager_suspend(); detach_current_thread(app->activity->vm); #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " android_main finished.\n"); #endif } mlterm-3.9.3/android/jni/ui.h000066400000000000000000000262221441203364000160150ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef ___UI_H__ #define ___UI_H__ #include #include #include typedef struct { struct android_app *app; ANativeWindow_Buffer buf; unsigned int bytes_per_pixel; unsigned int yoffset; /* * If AndroidBitmapFormat is changed (such as WINDOW_FORMAT_RGBA_8888), * rgb_info structure should be changed, too. * (See uitoolkit/fb/ui.h) */ struct rgb_info { unsigned int r_limit; unsigned int g_limit; unsigned int b_limit; unsigned int r_offset; unsigned int g_offset; unsigned int b_offset; } rgbinfo; ASensorManager *sensor_man; const ASensor *accel_sensor; ASensorEventQueue *sensor_evqueue; int key_state; int button_state; int lock_state; unsigned int long_press_counter; } Display; #define PIXEL_RED(pixel, rgbinfo) (((pixel) >> (rgbinfo).r_offset) << (rgbinfo).r_limit) #define PIXEL_BLUE(pixel, rgbinfo) (((pixel) >> (rgbinfo).b_offset) << (rgbinfo).b_limit) #define PIXEL_GREEN(pixel, rgbinfo) (((pixel) >> (rgbinfo).g_offset) << (rgbinfo).g_limit) #define RGB_TO_PIXEL(r, g, b, rgbinfo) \ ((((r) >> (rgbinfo).r_limit) << (rgbinfo).r_offset) | \ (((g) >> (rgbinfo).g_limit) << (rgbinfo).g_offset) | \ (((b) >> (rgbinfo).b_limit) << (rgbinfo).b_offset)) /* * If AndroidBitmapFormat is changed (such as WINDOW_FORMAT_RGBA_8888), * ALPHA_TO_PIXEL() should be changed, too. * (See uitoolkit/fb/ui.h) */ #define ALPHA_TO_PIXEL(a, rgbinfo, depth) (0) typedef int XIC; /* dummy */ typedef void *XID; /* dummy */ typedef void *Window; /* dummy */ typedef void *Drawable; /* dummy */ typedef struct { unsigned char *image; unsigned int width; unsigned int height; } * Pixmap; typedef unsigned char *PixmapMask; typedef int GC; /* dummy */ typedef int Font; /* dummy */ typedef int Cursor; /* dummy */ typedef int KeyCode; typedef int KeySym; typedef struct /* Same as definition in X11/X.h */ { int max_keypermod; KeyCode *modifiermap; } XModifierKeymap; typedef struct /* Same as definition in X11/X.h */ { unsigned char byte1; unsigned char byte2; } XChar2b; typedef struct { int type; unsigned int state; KeySym ksym; unsigned int keycode; } XKeyEvent; typedef unsigned long Time; /* Same as definition in X11/X.h */ typedef unsigned long Atom; /* Same as definition in X11/X.h */ typedef struct { int type; Time time; int x; int y; unsigned int state; unsigned int button; } XButtonEvent; typedef struct { int type; Time time; int x; int y; unsigned int state; } XMotionEvent; typedef union { int type; XKeyEvent xkey; XButtonEvent xbutton; XMotionEvent xmotion; } XEvent; typedef int XSelectionRequestEvent; /* dummy */ typedef struct { char *file; int32_t num_glyphs; /* Not used on freetype */ unsigned char *glyphs; /* Cast to unsigned char** on FreeType */ void *glyph_indeces; /* PCF: int16_t*, decsp: int16_t*, FreeType: u_int32_t* */ /* If is_aa is true, don't use glyph_width_bytes except in next_glyph_buf(). */ int32_t glyph_width_bytes; uint16_t width; /* Width of full width characters or max width of half width characters. */ uint16_t width_full; uint16_t height; uint16_t ascent; uint8_t has_each_glyph_width_info; /* for pcf */ int16_t min_char_or_byte2; int16_t max_char_or_byte2; int16_t min_byte1; int16_t max_byte1; int32_t *glyph_offsets; #ifdef USE_FREETYPE /* * XXX * * (fontsize|FONT_BOLD|FONT_ITALIC|FONT_ROTATED) on freetype. * fontsize is 0-0x1ff. */ int32_t format; void *face; uint32_t num_indeces; uint32_t num_glyph_bufs; uint32_t glyph_buf_left; int is_aa; #ifdef USE_FONTCONFIG struct _XFontStruct **compl_xfonts; #endif #endif unsigned int ref_count; } XFontStruct; typedef int XFontSet; /* dummy */ #define None 0L /* Same as definition in X11/X.h */ #define NoSymbol 0L /* Same as definition in X11/X.h */ #define CurrentTime 0L /* Same as definition in X11/X.h */ /* Same as definition in X11/X.h */ #define NoEventMask 0L #define KeyPressMask (1L << 0) #define KeyReleaseMask (1L << 1) #define ButtonPressMask (1L << 2) #define ButtonReleaseMask (1L << 3) #define EnterWindowMask (1L << 4) #define LeaveWindowMask (1L << 5) #define PointerMotionMask (1L << 6) #define PointerMotionHintMask (1L << 7) #define Button1MotionMask (1L << 8) #define Button2MotionMask (1L << 9) #define Button3MotionMask (1L << 10) #define Button4MotionMask (1L << 11) #define Button5MotionMask (1L << 12) #define ButtonMotionMask (1L << 13) #define KeymapStateMask (1L << 14) #define ExposureMask (1L << 15) #define VisibilityChangeMask (1L << 16) #define StructureNotifyMask (1L << 17) #define ResizeRedirectMask (1L << 18) #define SubstructureNotifyMask (1L << 19) #define SubstructureRedirectMask (1L << 20) #define FocusChangeMask (1L << 21) #define PropertyChangeMask (1L << 22) #define ColormapChangeMask (1L << 23) #define OwnerGrabButtonMask (1L << 24) #define ShiftMask (1 << 0) #define LockMask (1 << 1) #define ControlMask (1 << 2) #define Mod1Mask (1 << 3) #define Mod2Mask (1 << 4) #define Mod3Mask (1 << 5) #define Mod4Mask (1 << 6) #define Mod5Mask (1 << 7) #define Button1Mask (1 << 8) #define Button2Mask (1 << 9) #define Button3Mask (1 << 10) #define Button4Mask (1 << 11) #define Button5Mask (1 << 12) #define Button1 1 #define Button2 2 #define Button3 3 #define Button4 4 #define Button5 5 /* Not defined in android/keycode.h */ #define AKEYCODE_ESCAPE 0x6f #define AKEYCODE_CONTROL_LEFT 0x71 #define AKEYCODE_CONTROL_RIGHT 0x72 #define XK_Super_L 0xfffe /* dummy */ #define XK_Super_R 0xfffd /* dummy */ #define XK_Hyper_L 0xfffc /* dummy */ #define XK_Hyper_R 0xfffb /* dummy */ #define XK_BackSpace 0x08 #define XK_Tab 0x09 #define XK_Clear (AKEYCODE_CLEAR + 0x100) #define XK_Linefeed 0xfffa /* dummy */ #define XK_Return 0x0d #define XK_Shift_L (AKEYCODE_SHIFT_LEFT + 0x100) #define XK_Control_L (AKEYCODE_CONTROL_LEFT + 0x100) #define XK_Alt_L (AKEYCODE_ALT_LEFT + 0x100) #define XK_Shift_R (AKEYCODE_SHIFT_RIGHT + 0x100) #define XK_Control_R (AKEYCODE_CONTROL_RIGHT + 0x100) #define XK_Alt_R (AKEYCODE_ALT_RIGHT + 0x100) #define XK_Meta_L 0xfff7 /* dummy */ #define XK_Meta_R 0xfff6 /* dummy */ #define XK_Pause 0xfff5 /* dummy */ #define XK_Shift_Lock 0xfff4 /* dummy */ #define XK_Caps_Lock 0xfff3 /* dummy */ #define XK_Escape 0x1b #define XK_Prior (AKEYCODE_PAGE_UP + 0x100) #define XK_Next (AKEYCODE_PAGE_DOWN + 0x100) #define XK_End 0x17b #define XK_Home 0x17a #define XK_Left (AKEYCODE_DPAD_LEFT + 0x100) #define XK_Up (AKEYCODE_DPAD_UP + 0x100) #define XK_Right (AKEYCODE_DPAD_RIGHT + 0x100) #define XK_Down (AKEYCODE_DPAD_DOWN + 0x100) #define XK_Select 0xfff1 /* dummy */ #define XK_Print 0xfff0 /* dummy */ #define XK_Execute 0xffef /* dummy */ #define XK_Insert 0x17c #define XK_Delete 0x170 #define XK_Help 0xffed /* dummy */ #define XK_F1 0x183 #define XK_F2 0x184 #define XK_F3 0x185 #define XK_F4 0x186 #define XK_F5 0x187 #define XK_F6 0x188 #define XK_F7 0x189 #define XK_F8 0x18a #define XK_F9 0x18b #define XK_F10 0x18c #define XK_F11 0x18d #define XK_F12 0x18e #define XK_F13 0xffe0 /* dummy */ #define XK_F14 0xffdf /* dummy */ #define XK_F15 0xffde /* dummy */ #define XK_F16 0xffdd /* dummy */ #define XK_F17 0xffdc /* dummy */ #define XK_F18 0xffdb /* dummy */ #define XK_F19 0xffda /* dummy */ #define XK_F20 0xffd9 /* dummy */ #define XK_F21 0xffd8 /* dummy */ #define XK_F22 0xffd7 /* dummy */ #define XK_F23 0xffd6 /* dummy */ #define XK_F24 0xffd5 /* dummy */ #define XK_FMAX XK_F12 #define XK_Num_Lock 0xffd4 /* dummy */ #define XK_Scroll_Lock 0xffd3 /* dummy */ #define XK_Find 0xffd2 /* dummy */ #define XK_Menu 0xffd1 /* dummy */ #define XK_Begin 0xffd0 /* dummy */ #define XK_Muhenkan 0xffcf /* dummy */ #define XK_Henkan_Mode 0xffce /* dummy */ #define XK_Zenkaku_Hankaku 0xffcd /* dummy */ #define XK_Hiragana_Katakana 0xffcc /* dummy */ #define XK_KP_Prior 0xffcd /* dummy */ #define XK_KP_Next 0xffcc /* dummy */ #define XK_KP_End 0xffcb /* dummy */ #define XK_KP_Home 0xffca /* dummy */ #define XK_KP_Left 0xffc9 /* dummy */ #define XK_KP_Up 0xffc8 /* dummy */ #define XK_KP_Right 0xffc7 /* dummy */ #define XK_KP_Down 0xffc6 /* dummy */ #define XK_KP_Insert 0xffc5 /* dummy */ #define XK_KP_Delete 0xffc4 /* dummy */ #define XK_KP_F1 0xffc3 /* dummy */ #define XK_KP_F2 0xffc2 /* dummy */ #define XK_KP_F3 0xffc1 /* dummy */ #define XK_KP_F4 0xffc0 /* dummy */ #define XK_KP_Begin 0xffbf /* dummy */ #define XK_KP_Multiply 0xffbe /* dummy */ #define XK_KP_Add 0xffbd /* dummy */ #define XK_KP_Separator 0xffbc /* dummy */ #define XK_KP_Subtract 0xffbb /* dummy */ #define XK_KP_Decimal 0xffba /* dummy */ #define XK_KP_Divide 0xffb9 /* dummy */ #define XK_KP_0 0xffb8 /* dummy */ #define XK_KP_1 0xffb7 /* dummy */ #define XK_KP_2 0xffb6 /* dummy */ #define XK_KP_3 0xffb5 /* dummy */ #define XK_KP_4 0xffb4 /* dummy */ #define XK_KP_5 0xffb3 /* dummy */ #define XK_KP_6 0xffb2 /* dummy */ #define XK_KP_7 0xffb1 /* dummy */ #define XK_KP_8 0xffb0 /* dummy */ #define XK_KP_9 0xffaf /* dummy */ #define IsKeypadKey(ksym) (1) #define IsModifierKey(ksym) (0) #define XK_ISO_Left_Tab 0xffae /* dummy */ /* Same as definition in X11/X.h */ typedef struct { short x; short y; } XPoint; /* XXX dummy */ #define XKeysymToKeycode(disp, ks) (ks) #define XKeycodeToKeysym(disp, kc, i) (kc) #define XKeysymToString(ks) "" #define DisplayString(disp) ":0.0" #define DefaultScreen(disp) (0) #define BlackPixel(disp, screen) (0) #define WhitePixel(disp, screen) (-1) /* Same as definition in X11/cursorfont.h */ #define XC_xterm 152 #define XC_left_ptr 0 /* Same as definition in X11/Xutil.h */ #define NoValue 0x0000 #define XValue 0x0001 #define YValue 0x0002 #define WidthValue 0x0004 #define HeightValue 0x0008 #define AllValues 0x000F #define XNegative 0x0010 #define YNegative 0x0020 int XParseGeometry(char *str, int *x, int *y, unsigned int *width, unsigned int *height); KeySym XStringToKeysym(const char *str); /* === Platform dependent options === */ #define UI_COLOR_HAS_RGB #undef SUPPORT_TRUE_TRANSPARENT_BG #ifdef USE_FREETYPE /* XXX pcf fonts isn't scalable, though... */ #define TYPE_XCORE_SCALABLE #else #undef TYPE_XCORE_SCALABLE #endif #define MANAGE_ROOT_WINDOWS_BY_MYSELF #define MANAGE_SUB_WINDOWS_BY_MYSELF /* See also fb/ui_display.c where ui_picture_display_closed() is never called. */ #define INLINE_PICTURE_MOVABLE_BETWEEN_DISPLAYS #undef SUPPORT_POINT_SIZE_FONT #undef USE_GC #undef CHANGEABLE_CURSOR #undef PLUGIN_MODULE_SUFFIX #undef KEY_REPEAT_BY_MYSELF #undef ROTATABLE_DISPLAY #undef PSEUDO_COLOR_DISPLAY #undef WALL_PICTURE_SIXEL_REPLACES_SYSTEM_PALETTE #undef SUPPORT_URGENT_BELL #undef FORCE_UNICODE #undef NEED_DISPLAY_SYNC_EVERY_TIME #define DRAW_SCREEN_IN_PIXELS #undef NO_DRAW_IMAGE_STRING #define HAVE_PTHREAD #define COMPOSE_DECSP_FONT #ifdef USE_FREETYPE #define USE_REAL_VERTICAL_FONT #else #undef USE_REAL_VERTICAL_FONT #endif #undef NO_DISPLAY_FD #define FLICK_SCROLL #undef UIWINDOW_SUPPORTS_PREEDITING #endif mlterm-3.9.3/android/jni/ui_connect_dialog.c000066400000000000000000000077631441203364000210510ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* Note that protocols except ssh aren't supported if USE_LIBSSH2 is defined. */ #ifdef USE_LIBSSH2 #include #include #include #include #include "../ui_connect_dialog.h" #include "ui_display.h" /* ui_display_show_dialog */ /* --- static variables --- */ static char *d_uri; static char *d_pass; static char *d_exec_cmd; static char *d_privkey; /* --- global functions --- */ int ui_connect_dialog(char **uri, /* Should be free'ed by those who call this. */ char **pass, /* Same as uri. If pass is not input, "" is set. */ char **exec_cmd, /* Same as uri. If exec_cmd is not input, NULL is set. */ char **privkey, /* in/out */ int *x11_fwd, /* in/out */ char *display_name, Window parent_window, char *def_server /* (@)(:)(:). */) { int ret; ui_display_show_dialog(def_server, *privkey); if ((*uri = d_uri)) { *pass = d_pass; *exec_cmd = d_exec_cmd; *privkey = d_privkey; *x11_fwd = 0; ret = 1; } else { free(d_pass); free(d_exec_cmd); free(d_privkey); ret = 0; } d_uri = d_pass = d_exec_cmd = d_privkey = NULL; return ret; } void Java_mlterm_native_1activity_MLActivity_dialogOkClicked(JNIEnv *env, jobject this, jstring user, jstring serv /* can include proto */, jstring port, jstring encoding, jstring pass, jstring exec_cmd, jstring privkey) { const char *s, *u, *p, *e, *k; size_t uri_len, len; s = (*env)->GetStringUTFChars(env, serv, NULL); if (*s == '\0') { (*env)->ReleaseStringUTFChars(env, serv, s); return; } u = (*env)->GetStringUTFChars(env, user, NULL); p = (*env)->GetStringUTFChars(env, port, NULL); e = (*env)->GetStringUTFChars(env, encoding, NULL); uri_len = strlen(s) + 1; if ((len = strlen(u)) > 0) { uri_len += (len + 1); } if ((len = strlen(p)) > 0) { uri_len += (len + 1); } if ((len = strlen(e)) > 0) { uri_len += (len + 1); } if ((d_uri = malloc(uri_len))) { const char *s2 = strstr(s, "://"); if (s2) { s2 += 3; memcpy(d_uri, s, s2 - s); /* copy "://" */ d_uri[s2 - s] = '\0'; } else { s2 = s; *d_uri = '\0'; } if (*u) { strcat(d_uri, u); strcat(d_uri, "@"); } strcat(d_uri, s2); if (*p) { strcat(d_uri, ":"); strcat(d_uri, p); } if (*e) { strcat(d_uri, ":"); strcat(d_uri, e); } } (*env)->ReleaseStringUTFChars(env, serv, s); (*env)->ReleaseStringUTFChars(env, user, u); (*env)->ReleaseStringUTFChars(env, port, p); (*env)->ReleaseStringUTFChars(env, encoding, e); p = (*env)->GetStringUTFChars(env, pass, NULL); e = (*env)->GetStringUTFChars(env, exec_cmd, NULL); k = (*env)->GetStringUTFChars(env, privkey, NULL); d_pass = strdup(p); if (*e != '\0') { d_exec_cmd = strdup(e); } if (*k != '\0') { d_privkey = strdup(k); } (*env)->ReleaseStringUTFChars(env, pass, p); (*env)->ReleaseStringUTFChars(env, exec_cmd, e); (*env)->ReleaseStringUTFChars(env, privkey, k); #if 0 bl_debug_printf( "%s %s %s %s\n", d_uri, d_pass, d_exec_cmd, d_privkey); #endif } #else #include void Java_mlterm_native_1activity_MLActivity_dialogOkClicked(JNIEnv *env, jobject this, jstring user, jstring serv, jstring port, jstring encoding, jstring pass, jstring exec_cmd) { } #endif mlterm-3.9.3/android/jni/ui_display.c000066400000000000000000000730541441203364000175420ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "ui_display.h" #include /* STDIN_FILENO */ #include /* getenv */ #include /* strlen/strcpy */ #include #include #include #include #include #include #include #include "../ui_window.h" #include "../../common/c_animgif.c" #define DISP_IS_INITED (_disp.display) /* --- static functions --- */ static ui_display_t _disp; static Display _display; static int locked; /* --- static functions --- */ static int display_lock(void) { if (locked < 0) { return 0; } else if (!locked) { ANativeWindow_Buffer buf; if (ANativeWindow_lock(_display.app->window, &buf, NULL) != 0) { return 0; } if (_display.buf.bits != buf.bits) { if (_display.buf.bits && _display.buf.height == buf.height && _display.buf.stride == buf.stride) { memcpy(buf.bits, _display.buf.bits, _display.buf.height * _display.buf.stride * _display.bytes_per_pixel); } _display.buf = buf; } locked = 1; } return 1; } static inline u_char *get_fb(int x, int y) { return ((u_char *)_display.buf.bits) + ((_display.yoffset + y) * _display.buf.stride + x) * _display.bytes_per_pixel; } static int kcode_to_ksym(int kcode, int state) { /* US Keyboard */ if (AKEYCODE_0 <= kcode && kcode <= AKEYCODE_9) { if (state & ShiftMask) { char *num_key_shift = ")!@#$%^&*("; return num_key_shift[kcode - AKEYCODE_0]; } else { return kcode + 41; } } else if (AKEYCODE_A <= kcode && kcode <= AKEYCODE_Z) { kcode += 68; if (state & ShiftMask) { kcode -= 0x20; } return kcode; } else { if (state & ShiftMask) { switch (kcode) { case AKEYCODE_COMMA: return '<'; case AKEYCODE_PERIOD: return '>'; case AKEYCODE_SPACE: return ' '; case AKEYCODE_GRAVE: return '~'; case AKEYCODE_MINUS: return '_'; case AKEYCODE_EQUALS: return '+'; case AKEYCODE_LEFT_BRACKET: return '{'; case AKEYCODE_RIGHT_BRACKET: return '}'; case AKEYCODE_BACKSLASH: return '|'; case AKEYCODE_SEMICOLON: return ':'; case AKEYCODE_APOSTROPHE: return '\"'; case AKEYCODE_SLASH: return '?'; } } switch (kcode) { case AKEYCODE_ENTER: return 0x0d; case AKEYCODE_DEL: return 0x08; case AKEYCODE_COMMA: return ','; case AKEYCODE_PERIOD: return '.'; case AKEYCODE_TAB: return '\t'; case AKEYCODE_SPACE: return ' '; case AKEYCODE_GRAVE: return '`'; case AKEYCODE_MINUS: return '-'; case AKEYCODE_EQUALS: return '='; case AKEYCODE_BACKSLASH: return '\\'; case AKEYCODE_LEFT_BRACKET: return '['; case AKEYCODE_RIGHT_BRACKET: return ']'; case AKEYCODE_SEMICOLON: return ';'; case AKEYCODE_APOSTROPHE: return '\''; case AKEYCODE_SLASH: return '/'; case AKEYCODE_AT: return '@'; case AKEYCODE_ESCAPE: return '\x1b'; default: if (kcode == -0x3ed) { /* XXX for Nihongo Full Keyboard */ return XK_Henkan_Mode; } else if (kcode == -0x3ec) { /* XXX for Nihongo Full Keyboard */ return XK_Muhenkan; } else if (kcode < 0) { return 0; } else { return kcode + 0x100; } } } } static int process_key_event(int action, int code) { if (code == AKEYCODE_BACK) { return 0; } if (action == AKEY_EVENT_ACTION_DOWN) { if (code == AKEYCODE_SHIFT_RIGHT || code == AKEYCODE_SHIFT_LEFT) { _display.key_state |= ShiftMask; } #if 0 else if (code == KEY_CAPSLOCK) { if (_display.key_state & ShiftMask) { _display.key_state &= ~ShiftMask; } else { _display.key_state |= ShiftMask; } } #endif else if (code == AKEYCODE_CONTROL_RIGHT || code == AKEYCODE_CONTROL_LEFT) { _display.key_state |= ControlMask; } else if (code == AKEYCODE_ALT_RIGHT || code == AKEYCODE_ALT_LEFT) { _display.key_state |= Mod1Mask; } #if 0 else if (code == KEY_NUMLOCK) { _display.lock_state ^= NLKED; } #endif else { XKeyEvent xev; xev.type = KeyPress; xev.ksym = kcode_to_ksym(code, _display.key_state); xev.keycode = code; xev.state = _display.button_state | _display.key_state; ui_window_receive_event(_disp.roots[0], &xev); } } else if (action == AKEY_EVENT_ACTION_MULTIPLE) { XKeyEvent xev; xev.type = KeyPress; xev.ksym = 0; xev.keycode = 0; xev.state = 0; ui_window_receive_event(_disp.roots[0], &xev); } else /* if( action == AKEY_EVENT_ACTION_UP) */ { if (code == AKEYCODE_SHIFT_RIGHT || code == AKEYCODE_SHIFT_LEFT) { _display.key_state &= ~ShiftMask; } else if (code == AKEYCODE_CONTROL_RIGHT || code == AKEYCODE_CONTROL_LEFT) { _display.key_state &= ~ControlMask; } else if (code == AKEYCODE_ALT_RIGHT || code == AKEYCODE_ALT_LEFT) { _display.key_state &= ~Mod1Mask; } } return 1; } static JNIEnv *get_jni_env(JavaVM *vm) { JNIEnv *env; if ((*vm)->GetEnv(vm, &env, JNI_VERSION_1_6) == JNI_OK) { return env; } else { return NULL; } } static int dialog_cb(bl_dialog_style_t style, const char *msg) { JNIEnv *env; if (style == BL_DIALOG_ALERT && (env = get_jni_env(_display.app->activity->vm))) { jobject this = _display.app->activity->clazz; (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "showMessage", "(Ljava/lang/String;)V"), (*env)->NewStringUTF(env, msg)); return 1; } else { return -1; } } static void show_soft_input(JavaVM *vm) { JNIEnv *env; if ((env = get_jni_env(vm))) { jobject this = _display.app->activity->clazz; (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "showSoftInput", "()V")); } } /* * _disp.roots[1] is ignored. */ static inline ui_window_t *get_window(int x, /* X in display */ int y /* Y in display */ ) { ui_window_t *win; u_int count; for (count = 0; count < _disp.roots[0]->num_children; count++) { if ((win = _disp.roots[0]->children[count])->is_mapped) { if (win->x <= x && x < win->x + ACTUAL_WIDTH(win) && win->y <= y && y < win->y + ACTUAL_HEIGHT(win)) { return win; } } } return _disp.roots[0]; } static int process_mouse_event(int source, int action, int64_t time, int x, int y) { if (source & AINPUT_SOURCE_MOUSE) { static XButtonEvent prev_xev; XButtonEvent xev; ui_window_t *win; switch (action & AMOTION_EVENT_ACTION_POINTER_INDEX_MASK) { case 0x100: _display.button_state = Button1Mask; xev.button = Button1; break; case 0x200: xev.button = Button2; _display.button_state = Button2Mask; break; case 0x300: xev.button = Button3; _display.button_state = Button3Mask; break; case 0x0: default: xev.button = 0; break; } switch (action & AMOTION_EVENT_ACTION_MASK) { case AMOTION_EVENT_ACTION_DOWN: xev.type = ButtonPress; if (xev.button == 0) { xev.button = Button1; _display.button_state = Button1Mask; } break; case AMOTION_EVENT_ACTION_UP: xev.type = ButtonRelease; /* Reset button_state in releasing button. */ _display.button_state = 0; if (xev.button == 0) { xev.button = Button1; } break; case 7 /* AMOTION_EVENT_ACTION_HOVER_MOVE */: case AMOTION_EVENT_ACTION_MOVE: xev.type = MotionNotify; if (_display.long_press_counter > 0) { xev.button = Button1; _display.button_state = Button1Mask; } break; default: return 1; } xev.time = time / 1000000; xev.x = x; xev.y = y; xev.state = _display.key_state; if (xev.type == ButtonPress) { static int click_num; if (xev.x >= _disp.width - _disp.width / 4 && xev.y >= _disp.height - _disp.height / 4) { if (click_num == 0) { click_num = 1; } else /* if( click_num == 1) */ { click_num = 0; #if 0 /* This doesn't work on Android 3.x and 4.x. */ ANativeActivity_showSoftInput(_display.app->activity, ANATIVEACTIVITY_SHOW_SOFT_INPUT_FORCED); #else show_soft_input(_display.app->activity->vm); #endif } } else { click_num = 0; } memset(&prev_xev, 0, sizeof(prev_xev)); } else if (xev.type == MotionNotify) { if (prev_xev.type == MotionNotify && #if 1 prev_xev.x - 3 <= xev.x && xev.x <= prev_xev.x + 3 && prev_xev.y - 3 <= xev.y && xev.y <= prev_xev.y + 3 #else prev_xev.x == xev.x && prev_xev.y == xev.y #endif ) { /* Long click on touch panel sends same MotionNotify events continuously. */ #if 0 bl_debug_printf("Same event is ignored.\n"); #endif if (xev.time >= prev_xev.time + 100) { /* 0.1 sec */ prev_xev = xev; ui_display_idling(NULL); } return 1; } prev_xev = xev; } #if 0 bl_debug_printf( BL_DEBUG_TAG "Button is %s x %d y %d btn %d time %d\n", xev.type == ButtonPress ? "pressed" : (xev.type == MotionNotify ? "motion" : "released"), xev.x, xev.y, xev.button, xev.time); #endif win = get_window(xev.x, xev.y); if (xev.type != ButtonRelease && xev.button == Button1 && /* XXX excludes scrollbar (see x_window_init() called in ui_scrollbar.c) */ win->width > win->min_width && xev.x >= _disp.width - _disp.width / 4 && xev.y >= _disp.height - _disp.height / 4) { /* Start long pressing */ _display.long_press_counter = 1; } else { _display.long_press_counter = 0; } xev.x -= win->x; xev.y -= win->y; ui_window_receive_event(win, &xev); } return 1; } static int32_t on_input_event(struct android_app *app, AInputEvent *event) { switch (AInputEvent_getType(event)) { case AINPUT_EVENT_TYPE_MOTION: #if 0 bl_debug_printf("MOTION %d %d x %d y %d\n", AInputEvent_getSource(event), AMotionEvent_getAction(event), AMotionEvent_getX(event, 0), AMotionEvent_getY(event, 0) - _display.yoffset); #endif return process_mouse_event(AInputEvent_getSource(event), AMotionEvent_getAction(event), AMotionEvent_getEventTime(event), AMotionEvent_getX(event, 0), AMotionEvent_getY(event, 0) - _display.yoffset); case AINPUT_EVENT_TYPE_KEY: #if 0 bl_debug_printf("KEY %d %d\n", AKeyEvent_getScanCode(event), AKeyEvent_getKeyCode(event)); #endif return process_key_event(AKeyEvent_getAction(event), AKeyEvent_getKeyCode(event)); default: return 0; } } static void update_window(ui_window_t *win) { u_int count; ui_window_clear_margin_area(win); if (win->window_exposed) { (*win->window_exposed)(win, 0, 0, win->width, win->height); } for (count = 0; count < win->num_children; count++) { update_window(win->children[count]); } } static void init_window(ANativeWindow *window) { struct rgb_info rgbinfo = {3, 2, 3, 11, 5, 0}; if (_disp.width == 0) { _disp.width = ANativeWindow_getWidth(window); _disp.height = ANativeWindow_getHeight(window); } else { /* Changed in visibleFrameChanged. */ } _disp.depth = 16; _display.bytes_per_pixel = 2; _display.rgbinfo = rgbinfo; /* * If AndroidBitmapFormat is changed (such as WINDOW_FORMAT_RGBA_8888), * 'rgbinfo' structure and ALPHA_TO_PIXEL() should be changed, too. */ ANativeWindow_setBuffersGeometry(window, 0, 0, WINDOW_FORMAT_RGB_565); if (_display.buf.bits) { /* mlterm restarted */ u_int count; _display.buf.bits = NULL; /* In case of locked is 1 here. */ locked = 0; for (count = 0; count < _disp.num_roots; count++) { ui_window_set_mapped_flag(_disp.roots[count], 1); /* In case of restarting */ update_window(_disp.roots[count]); } } } /* ui_event_source.c */ void ui_activity_pause(void); void ui_activity_resume(void); static void on_app_cmd(struct android_app *app, int32_t cmd) { switch (cmd) { case APP_CMD_SAVE_STATE: #ifdef DEBUG bl_debug_printf("SAVE_STATE\n"); #endif break; case APP_CMD_INIT_WINDOW: #ifdef DEBUG bl_debug_printf("INIT_WINDOW\n"); #endif init_window(app->window); break; case APP_CMD_WINDOW_RESIZED: #ifdef DEBUG bl_debug_printf("WINDOW_RESIZED\n"); #endif break; case APP_CMD_TERM_WINDOW: #ifdef DEBUG bl_debug_printf("TERM_WINDOW\n"); #endif { u_int count; for (count = 0; count < _disp.num_roots; count++) { ui_window_set_mapped_flag(_disp.roots[count], 0); } } locked = -1; /* Don't lock until APP_CMD_INIT_WINDOW after restart. */ break; case APP_CMD_WINDOW_REDRAW_NEEDED: #ifdef DEBUG bl_debug_printf("WINDOW_REDRAW_NEEDED\n"); #endif break; case APP_CMD_CONFIG_CHANGED: #ifdef DEBUG bl_debug_printf("CONFIG_CHANGED\n"); #endif case APP_CMD_GAINED_FOCUS: #ifdef DEBUG bl_debug_printf("GAINED_FOCUS\n"); #endif /* When our app gains focus, we start monitoring the accelerometer. */ if (_display.accel_sensor) { ASensorEventQueue_enableSensor(_display.sensor_evqueue, _display.accel_sensor); /* We'd like to get 60 events per second (in us). */ ASensorEventQueue_setEventRate(_display.sensor_evqueue, _display.accel_sensor, (1000L / 60) * 1000); } break; case APP_CMD_LOST_FOCUS: #ifdef DEBUG bl_debug_printf("LOST_FOCUS\n"); #endif /* * When our app loses focus, we stop monitoring the accelerometer. * This is to avoid consuming battery while not being used. */ if (_display.accel_sensor) { ASensorEventQueue_disableSensor(_display.sensor_evqueue, _display.accel_sensor); } break; case APP_CMD_PAUSE: #ifdef DEBUG bl_debug_printf("PAUSE\n"); #endif ui_activity_pause(); break; case APP_CMD_RESUME: #ifdef DEBUG bl_debug_printf("RESUME\n"); #endif ui_activity_resume(); break; } } /* --- global functions --- */ ui_display_t *ui_display_open(char *disp_name, u_int depth) { if (!_disp.name && !(_disp.name = getenv("DISPLAY"))) { _disp.name = ":0.0"; /* Callback should be set before bl_dialog() is called. */ bl_dialog_set_callback(dialog_cb); } _disp.display = &_display; return &_disp; } void ui_display_close(ui_display_t *disp) { if (disp == &_disp) { ui_display_close_all(); } } void ui_display_close_all(void) { if (DISP_IS_INITED) { u_int count; for (count = 0; count < _disp.num_roots; count++) { #if 0 ui_window_unmap(_disp.roots[count]); #endif ui_window_final(_disp.roots[count]); } free(_disp.roots); _disp.roots = NULL; _disp.num_roots = 0; /* DISP_IS_INITED is false from here. */ _disp.display = NULL; /* Other members in _disp is reset in ui_display_init() */ } } int ui_display_show_root(ui_display_t *disp, ui_window_t *root, int x, int y, int hint, char *app_name, char *wm_role, Window parent_window /* Ignored */ ) { void *p; if ((p = realloc(disp->roots, sizeof(ui_window_t *) * (disp->num_roots + 1))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " realloc failed.\n"); #endif return 0; } disp->roots = p; root->disp = disp; root->parent = NULL; root->parent_window = disp->my_window; root->gc = disp->gc; root->x = x; root->y = y; if (app_name) { root->app_name = app_name; } disp->roots[disp->num_roots++] = root; /* Cursor is drawn internally by calling ui_display_put_image(). */ return ui_window_show(root, hint); } int ui_display_remove_root(ui_display_t *disp, ui_window_t *root) { u_int count; for (count = 0; count < disp->num_roots; count++) { if (disp->roots[count] == root) { /* XXX ui_window_unmap resize all windows internally. */ #if 0 ui_window_unmap(root); #endif ui_window_final(root); disp->num_roots--; if (count == disp->num_roots) { disp->roots[count] = NULL; } else { disp->roots[count] = disp->roots[disp->num_roots]; } return 1; } } return 0; } static void perform_long_click(JavaVM *vm) { JNIEnv *env; if ((env = get_jni_env(vm))) { jobject this = _display.app->activity->clazz; (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "performLongClick", "()V")); } } void ui_display_idling(ui_display_t *disp /* ignored */ ) { u_int count; if (_display.long_press_counter > 0) { if (_display.long_press_counter++ == 20) { _display.long_press_counter = 0; perform_long_click(_display.app->activity->vm); } } for (count = 0; count < _disp.num_roots; count++) { ui_window_idling(_disp.roots[count]); } } /* * Folloing functions called from ui_window.c */ int ui_display_own_selection(ui_display_t *disp, ui_window_t *win) { if (_disp.selection_owner) { ui_display_clear_selection(&_disp, _disp.selection_owner); } _disp.selection_owner = win; return 1; } int ui_display_clear_selection(ui_display_t *disp /* can be NULL */, ui_window_t *win) { if (_disp.selection_owner == NULL || _disp.selection_owner != win) { return 0; } if (_disp.selection_owner->selection_cleared) { (*_disp.selection_owner->selection_cleared)(_disp.selection_owner); } _disp.selection_owner = NULL; return 1; } XModifierKeymap *ui_display_get_modifier_mapping(ui_display_t *disp) { return disp->modmap.map; } void ui_display_update_modifier_mapping(ui_display_t *disp, u_int serial) { /* dummy */ } XID ui_display_get_group_leader(ui_display_t *disp) { return None; } void ui_display_rotate(int rotate) {} int ui_display_init(struct android_app *app) { int ret; int ident; int events; struct android_poll_source *source; /* Make sure glue isn't stripped. */ app_dummy(); ret = _display.app ? 0 : 1; _display.app = app; app->onAppCmd = on_app_cmd; do { if ((ident = ALooper_pollAll(-1 /* block forever waiting for events */, NULL, &events, (void **)&source)) >= 0) { /* Process this event. */ if (source) { (*source->process)(app, source); } } } while (!app->window); app->onInputEvent = on_input_event; /* Prepare to monitor accelerometer. */ _display.sensor_man = ASensorManager_getInstance(); _display.accel_sensor = ASensorManager_getDefaultSensor(_display.sensor_man, ASENSOR_TYPE_ACCELEROMETER); _display.sensor_evqueue = ASensorManager_createEventQueue(_display.sensor_man, app->looper, LOOPER_ID_USER, NULL, NULL); return ret; } void ui_display_final(void) { if (locked >= 0) { ASensorManager_destroyEventQueue(_display.sensor_man, _display.sensor_evqueue); _display.accel_sensor = NULL; locked = -1; /* Don't lock until APP_CMD_INIT_WINDOW after restart. */ ANativeActivity_finish(_display.app->activity); } } int ui_display_process_event(struct android_poll_source *source, int ident) { /* Process this event. */ if (source) { (*source->process)(_display.app, source); } /* If a sensor has data, process it now. */ if (ident == LOOPER_ID_USER) { if (_display.accel_sensor) { ASensorEvent event; while (ASensorEventQueue_getEvents(_display.sensor_evqueue, &event, 1) > 0) { #if 0 bl_debug_printf("Accelerometer: x=%f y=%f z=%f", event.acceleration.x, event.acceleration.y, event.acceleration.z); #endif } } } /* Check if we are exiting. */ if (_display.app->destroyRequested) { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " destroy requested.\n"); #endif locked = -1; /* Don't lock until APP_CMD_INIT_WINDOW after restart. */ return 0; } return 1; } void ui_display_unlock(void) { if (locked > 0) { ANativeWindow_unlockAndPost(_display.app->window); locked = 0; } } size_t ui_display_get_str(u_char *seq, size_t seq_len) { JNIEnv *env; jobject this; jstring jstr_key; size_t len; if (!(env = get_jni_env(_display.app->activity->vm))) { return 0; } this = _display.app->activity->clazz; jstr_key = (*env)->GetObjectField(env, this, (*env)->GetFieldID(env, (*env)->GetObjectClass(env, this), "keyString", "Ljava/lang/String;")); if (jstr_key) { const char *key; key = (*env)->GetStringUTFChars(env, jstr_key, NULL); if ((len = strlen(key)) > seq_len) { len = 0; } else { memcpy(seq, key, len); } (*env)->ReleaseStringUTFChars(env, jstr_key, key); } else { len = 0; } return len; } u_long ui_display_get_pixel(ui_display_t *disp, int x, int y) { u_char *fb; fb = get_fb(x, y); if (_display.bytes_per_pixel == 4) { return *((u_int32_t *)fb); } else /* if( _display.bytes_per_pixel == 2) */ { return *((u_int16_t *)fb); } } void ui_display_put_image(ui_display_t *disp, int x, int y, u_char *image, size_t size, int need_fb_pixel) { if (display_lock()) { memcpy(get_fb(x, y), image, size); } } void ui_display_copy_lines(ui_display_t *disp, int src_x, int src_y, int dst_x, int dst_y, u_int width, u_int height) { if (display_lock()) { u_char *src; u_char *dst; u_int copy_len; u_int count; size_t line_length; copy_len = width * _display.bytes_per_pixel; line_length = _display.buf.stride * _display.bytes_per_pixel; if (src_y <= dst_y) { src = get_fb(src_x, src_y + height - 1); dst = get_fb(dst_x, dst_y + height - 1); if (src_y == dst_y) { for (count = 0; count < height; count++) { memmove(dst, src, copy_len); dst -= line_length; src -= line_length; } } else { for (count = 0; count < height; count++) { memcpy(dst, src, copy_len); dst -= line_length; src -= line_length; } } } else { src = get_fb(src_x, src_y); dst = get_fb(dst_x, dst_y); for (count = 0; count < height; count++) { memcpy(dst, src, copy_len); dst += line_length; src += line_length; } } } } u_char *ui_display_get_bitmap(char *path, u_int *width, u_int *height) { JNIEnv *env; jobject this; jintArray jarray; char *image; if (!(env = get_jni_env(_display.app->activity->vm))) { return NULL; } this = _display.app->activity->clazz; image = NULL; if ((jarray = (*env)->CallObjectMethod( env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "getBitmap", "(Ljava/lang/String;II)[I"), (*env)->NewStringUTF(env, path), *width, *height))) { jint len; len = (*env)->GetArrayLength(env, jarray); if ((image = malloc((len - 2) * sizeof(u_int32_t)))) { jint *elems; elems = (*env)->GetIntArrayElements(env, jarray, NULL); *width = elems[len - 2]; *height = elems[len - 1]; memcpy(image, elems, (len - 2) * sizeof(u_int32_t)); (*env)->ReleaseIntArrayElements(env, jarray, elems, 0); } } return image; } void ui_display_request_text_selection(void) { JNIEnv *env; jobject this; if (!(env = get_jni_env(_display.app->activity->vm))) { return; } this = _display.app->activity->clazz; (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "getTextFromClipboard", "()V")); } void ui_display_send_text_selection(u_char *sel_data, size_t sel_len) { u_char *p; JNIEnv *env; jobject this; jstring str; if (!(p = alloca(sel_len + 1))) { return; } sel_data = memcpy(p, sel_data, sel_len); sel_data[sel_len] = '\0'; if (!(env = get_jni_env(_display.app->activity->vm))) { return; } this = _display.app->activity->clazz; (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "setTextToClipboard", "(Ljava/lang/String;)V"), (*env)->NewStringUTF(env, sel_data)); } void ui_display_show_dialog(char *server, char *privkey) { char *server_dup; char *proto; char *user; char *host; char *port; char *encoding; JNIEnv *env; jobject this; if (!(env = get_jni_env(_display.app->activity->vm))) { return; } if (server == NULL || !(server_dup = alloca(strlen(server) + 1)) || !bl_parse_uri(&proto, &user, &host, &port, NULL, &encoding, strcpy(server_dup, server))) { proto = user = host = port = encoding = NULL; } if (!privkey) { char *home; if ((home = bl_get_home_dir()) && (privkey = alloca(strlen(home) + 15 + 1))) { sprintf(privkey, "%s/.mlterm/id_rsa", home); } } this = _display.app->activity->clazz; (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "showConnectDialog", "(Ljava/lang/String;Ljava/lang/String;" "Ljava/lang/String;Ljava/lang/String;" "Ljava/lang/String;Ljava/lang/String;)V"), proto ? (*env)->NewStringUTF(env, proto) : NULL, user ? (*env)->NewStringUTF(env, user) : NULL, host ? (*env)->NewStringUTF(env, host) : NULL, port ? (*env)->NewStringUTF(env, port) : NULL, encoding ? (*env)->NewStringUTF(env, encoding) : NULL, privkey ? (*env)->NewStringUTF(env, privkey) : NULL); } /* Called in the main thread (not in the native activity thread) */ void ui_display_resize(int yoffset, int width, int height, int (*need_resize)(u_int, u_int, u_int, u_int)) { u_int new_width; u_int new_height; #ifdef DEBUG bl_debug_printf("Visible frame changed yoff %d w %d h %d => yoff %d w %d h %d\n", _display.yoffset, _disp.width, _disp.height, yoffset, width, height); #endif if (width < 50 || height < 50) { /* Don't resize because it may be impossible to show any characters. */ return; } _display.yoffset = yoffset; if (_disp.num_roots == 0) { _disp.width = width; _disp.height = height; return; } new_width = width; new_height = height; if (need_resize && !(*need_resize)(_disp.width, _disp.height, new_width, new_height)) { return; } _disp.width = new_width; _disp.height = new_height; ui_window_resize_with_margin(_disp.roots[0], _disp.width, _disp.height, NOTIFY_TO_MYSELF); } /* Called in the main thread (not in the native activity thread) */ void ui_display_update_all(void) { if (_disp.num_roots > 0) { ui_window_update_all(_disp.roots[0]); } } void ui_window_set_mapped_flag(ui_window_t *win, int flag) { u_int count; if (flag == win->is_mapped) { return; } for (count = 0; count < win->num_children; count++) { ui_window_set_mapped_flag(win->children[count], flag); } if (!flag) { win->saved_mapped = win->is_mapped; win->is_mapped = 0; } else { win->is_mapped = win->saved_mapped; } } jstring Java_mlterm_native_1activity_MLActivity_convertToTmpPath( JNIEnv *env, jobject this, jstring jstr /* must be original URL. (Don't specify /sdcard/.mlterm/anim*) */ ) { char *dst_path; char *dir; if (!(dir = bl_get_user_rc_path("mlterm/"))) { return NULL; } if (!(dst_path = alloca(strlen(dir) + 8 + 5 /* hash <= 65535 */ + 1))) { jstr = NULL; } else { const char *src_path; jint hash; src_path = (*env)->GetStringUTFChars(env, jstr, NULL); hash = hash_path(src_path); (*env)->ReleaseStringUTFChars(env, jstr, src_path); sprintf(dst_path, "%sanim%d.gif", dir, hash); jstr = ((*env)->NewStringUTF)(env, dst_path); } free(dir); return jstr; } void Java_mlterm_native_1activity_MLActivity_splitAnimationGif( JNIEnv *env, jobject this, jstring jstr /* must be original URL. (Don't specify /sdcard/.mlterm/anim*) */ ) { const char *str; const char *path; char *dir; char *tmp; int hash; if (!(dir = bl_get_user_rc_path("mlterm/"))) { return; } path = str = (*env)->GetStringUTFChars(env, jstr, NULL); hash = hash_path(path); if (strstr(path, "://") && (tmp = alloca(strlen(dir) + 8 + 5 /* hash <= 65535 */ + 1))) { sprintf(tmp, "%sanim%d.gif", dir, hash); path = tmp; } split_animation_gif(path, dir, hash); free(dir); (*env)->ReleaseStringUTFChars(env, jstr, str); } mlterm-3.9.3/android/jni/ui_display.h000066400000000000000000000036031441203364000175400ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef ___UI_DISPLAY_H__ #define ___UI_DISPLAY_H__ #include #include "../ui_display.h" #define CLKED 1 #define NLKED 2 #define SLKED 4 #define ALKED 8 #define KeyPress 2 /* Private in fb/ */ #define ButtonPress 4 /* Private in fb/ */ #define ButtonRelease 5 /* Private in fb/ */ #define MotionNotify 6 /* Private in fb/ */ #define IM_WINDOW_IS_ACTIVATED(disp) ((disp)->num_roots > 1 && (disp)->roots[1]->is_mapped) /* common functions for ui_window.c */ u_long ui_display_get_pixel(ui_display_t *disp, int x, int y); void ui_display_put_image(ui_display_t *disp, int x, int y, u_char *image, size_t size, int need_fb_pixel); void ui_display_copy_lines(ui_display_t *disp, int src_x, int src_y, int dst_x, int dst_y, u_int width, u_int height); /* common functions for ui_window.c (pseudo color) */ #define ui_display_fill_with(x, y, width, height, pixel) (0) #define ui_cmap_get_closest_color(closest, red, green, blue) (0) #define ui_cmap_get_pixel_rgb(red, green, blue, pixel) (0) /* platform specific functions for ui_window.c */ int ui_display_init(struct android_app *app); void ui_display_final(void); int ui_display_process_event(struct android_poll_source *source, int ident); void ui_display_unlock(void); size_t ui_display_get_str(u_char *seq, size_t seq_len); u_char *ui_display_get_bitmap(char *path, u_int *width, u_int *height); void ui_display_request_text_selection(void); void ui_display_send_text_selection(u_char *sel_data, size_t sel_len); void ui_display_show_dialog(char *server, char *privkey); void ui_display_resize(int yoffset, int width, int height, int (*need_resize)(u_int, u_int, u_int, u_int)); void ui_display_update_all(); void ui_window_set_mapped_flag(ui_window_ptr_t win, int flag); #endif mlterm-3.9.3/android/jni/ui_event_source.c000066400000000000000000000414041441203364000205700ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "ui_event_source.h" #include /* strstr */ #include /* sprintf */ #include /* clock */ #include #include #include #include #include #include "fb/ui_display.h" #include "ui_window.h" #include "ui_screen.h" #define UIWINDOW_OF(term) \ ((term)->parser->xterm_listener ? (term)->parser->xterm_listener->self : NULL) /* msec */ #define TIMEOUT 100 /* --- static variables --- */ static ef_parser_t *utf8_parser; /* main and native activity threads changes commit_text/preedit_text from at the * same time. */ static pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER; static char *cur_preedit_text; static int connect_to_ssh_server; /* --- static functions --- */ static vt_term_t *get_current_term(void) { vt_term_t **terms; u_int num_terms; u_int count; num_terms = vt_get_all_terms(&terms); for (count = 0; count < num_terms; count++) { ui_window_t *win; if (vt_term_is_attached(terms[count]) && (win = UIWINDOW_OF(terms[count])) && win->is_focused) { return terms[count]; } } return NULL; } static void update_ime_text(vt_term_t *term, char *preedit_text, char *commit_text) { u_char buf[128]; size_t len; ui_window_t *win; if (vt_term_is_backscrolling(term)) { return; } if (preedit_text && cur_preedit_text && strcmp(preedit_text, cur_preedit_text) == 0) { return; } vt_term_set_config(term, "use_local_echo", "false"); if ((win = UIWINDOW_OF(term))) { /* XXX If IM plugin is supported, see update_ime_text() in cocoa.m. */ ((ui_screen_t*)win)->is_preediting = 0; } if (!utf8_parser && !(utf8_parser = vt_char_encoding_parser_new(VT_UTF8))) { return; } (*utf8_parser->init)(utf8_parser); if (preedit_text) { if (*preedit_text == '\0') { preedit_text = NULL; } else { if (win) { /* XXX If IM plugin is supported, see update_ime_text() in cocoa.m. */ ((ui_screen_t*)win)->is_preediting = 1; /* Hide cursor (stop blinking) */ } vt_term_set_config(term, "use_local_echo", "true"); (*utf8_parser->set_str)(utf8_parser, preedit_text, strlen(preedit_text)); while (!utf8_parser->is_eos && (len = vt_term_convert_to(term, buf, sizeof(buf), utf8_parser)) > 0) { vt_term_preedit(term, buf, len); } } if (win) { ui_window_update(win, 3); } } else /* if (commit_text) */ { (*utf8_parser->set_str)(utf8_parser, commit_text, strlen(commit_text)); while (!utf8_parser->is_eos && (len = vt_term_convert_to(term, buf, sizeof(buf), utf8_parser)) > 0) { vt_term_write(term, buf, len); } } free(cur_preedit_text); cur_preedit_text = preedit_text ? strdup(preedit_text) : NULL; } static void update_ime_text_on_active_term(char *preedit_text, char *commit_text) { vt_term_t *term; if ((term = get_current_term())) { update_ime_text(term, preedit_text, commit_text); } } static void ALooper_removeFds(ALooper *looper, int *fds, u_int num_fds) { u_int count; for (count = 0; count < num_fds; count++) { ALooper_removeFd(looper, fds[count]); } } static int need_resize(u_int cur_width, /* contains scrollbar width and margin area */ u_int cur_height, /* contains margin area */ u_int new_width, /* contains scrollbar width and margin area */ u_int new_height /* contains margin area */ ) { vt_term_t **terms; u_int num_terms; u_int count; num_terms = vt_get_all_terms(&terms); for (count = 0; count < num_terms; count++) { ui_window_t *win; if (vt_term_is_attached(terms[count]) && (win = UIWINDOW_OF(terms[count])) && win->is_focused) { if (cur_height > new_height) { u_int line_height; if (vt_term_get_vertical_mode(terms[count])) { return 0; } /* XXX */ line_height = win->height / vt_term_get_rows(terms[count]); if (line_height > 1 && win->height < ((vt_term_get_rows(terms[count]) + 1) * (line_height - 1))) { line_height--; } if (new_height <= win->y + line_height || (vt_term_cursor_row(terms[count]) + 1) * line_height + win->y + win->vmargin <= new_height) { return 0; } } break; } } if (cur_width > new_width) { return 0; } else { if (count < num_terms) { vt_term_set_config(terms[count], "use_local_echo", "false"); } return 1; } } /* --- global functions --- */ void ui_event_source_init(void) {} void ui_event_source_final(void) { pthread_mutex_init(&mutex, NULL); free(cur_preedit_text); cur_preedit_text = NULL; connect_to_ssh_server = 0; } int ui_event_source_process(void) { ALooper *looper; int timeout = TIMEOUT; int ident; int events; struct android_poll_source *source; vt_term_t **terms; u_int num_terms; u_int count; static u_int prev_num_terms; static int *fds; static u_int32_t prev_msec; looper = ALooper_forThread(); if ((num_terms = vt_get_all_terms(&terms)) == 0) { ui_display_final(); free(fds); fds = NULL; } else { void *p; if (prev_num_terms != num_terms && (p = realloc(fds, sizeof(int) * num_terms))) { fds = p; } for (count = 0; count < num_terms; count++) { fds[count] = vt_term_get_master_fd(terms[count]); ALooper_addFd(looper, fds[count], 1000 + fds[count], ALOOPER_EVENT_INPUT, NULL, NULL); if (vt_term_is_sending_data(terms[count])) { timeout = 0; } } } prev_num_terms = num_terms; /* * Read all pending events. * Don't block ALooper_pollAll because commit_text or preedit_text can * be changed from main thread. */ ident = ALooper_pollAll(timeout, /* milisec. -1 blocks forever waiting for events */ NULL, &events, (void **)&source); pthread_mutex_lock(&mutex); if (ident >= 0) { struct timespec tm; if (!ui_display_process_event(source, ident)) { ALooper_removeFds(looper, fds, num_terms); prev_num_terms = 0; free(fds); fds = NULL; pthread_mutex_unlock(&mutex); return 0; } for (count = 0; count < num_terms; count++) { if (vt_term_get_master_fd(terms[count]) + 1000 == ident) { ui_window_t *win; if (cur_preedit_text && (win = UIWINDOW_OF(terms[count])) && win->is_focused) { vt_term_set_config(terms[count], "use_local_echo", "false"); } vt_term_parse_vt100_sequence(terms[count]); if (cur_preedit_text && win && win->is_focused) { char *preedit_text; preedit_text = cur_preedit_text; cur_preedit_text = NULL; update_ime_text(terms[count], preedit_text, NULL); } /* * Don't break here because some terms can have * the same master fd. */ } } /* ALooper_pollAll() always returns in less than 100ms on some systems. */ if (clock_gettime(CLOCK_MONOTONIC, &tm) == 0) { u_int32_t now_msec = tm.tv_sec * 1000 + tm.tv_nsec / 1000000; if (now_msec < prev_msec || now_msec > prev_msec + TIMEOUT) { ui_display_idling(NULL); prev_msec = now_msec; } } } else if (timeout == 0) { for (count = 0; count < num_terms; count++) { vt_term_parse_vt100_sequence(terms[count]); } } else /* if (timeout == TIMEOUT) */ { ui_display_idling(NULL); prev_msec += timeout; } if (num_terms > 0) { if (connect_to_ssh_server) { vt_term_t *term = get_current_term(); if (term && term->parser->config_listener) { char cmd[] = "mlclientx --dialog"; (*term->parser->config_listener->exec)(term->parser->config_listener->self, cmd); } connect_to_ssh_server = 0; } ALooper_removeFds(looper, fds, num_terms); } vt_close_dead_terms(); ui_close_dead_screens(); ui_display_unlock(); pthread_mutex_unlock(&mutex); return 1; } /* * fd >= 0 -> Normal file descriptor. handler is invoked if fd is ready. * fd < 0 -> Special ID. handler is invoked at interval of 0.1 sec. */ int ui_event_source_add_fd(int fd, void (*handler)(void)) { return 0; } void ui_event_source_remove_fd(int fd) {} /* Called from ui_display.c (APP_CMD_RESUME) */ void ui_activity_resume(void) { vt_term_t *term; if ((term = get_current_term())) { ui_window_set_mapped_flag(ui_get_root_window(UIWINDOW_OF(term)), 1); } } /* Called from ui_display.c (APP_CMD_PAUSE) */ void ui_activity_pause(void) { vt_term_t *term; if ((term = get_current_term())) { ui_window_set_mapped_flag(ui_get_root_window(UIWINDOW_OF(term)), 0); } } void Java_mlterm_native_1activity_MLActivity_visibleFrameChanged(JNIEnv *env, jobject this, jint yoffset, jint width, jint height) { pthread_mutex_lock(&mutex); ui_display_resize(yoffset, width, height, cur_preedit_text ? need_resize : NULL); pthread_mutex_unlock(&mutex); } void Java_mlterm_native_1activity_MLActivity_commitTextLock(JNIEnv *env, jobject this, jstring jstr) { char *str; pthread_mutex_lock(&mutex); str = (*env)->GetStringUTFChars(env, jstr, NULL); update_ime_text_on_active_term(NULL, str); (*env)->ReleaseStringUTFChars(env, jstr, str); pthread_mutex_unlock(&mutex); } /* Called in the native activity thread for copy&paste. */ void Java_mlterm_native_1activity_MLActivity_commitTextNoLock(JNIEnv *env, jobject this, jstring jstr) { char *str; str = (*env)->GetStringUTFChars(env, jstr, NULL); update_ime_text_on_active_term(NULL, str); (*env)->ReleaseStringUTFChars(env, jstr, str); } void Java_mlterm_native_1activity_MLActivity_preeditText(JNIEnv *env, jobject this, jstring jstr) { char *str; pthread_mutex_lock(&mutex); str = (*env)->GetStringUTFChars(env, jstr, NULL); update_ime_text_on_active_term(str, NULL); (*env)->ReleaseStringUTFChars(env, jstr, str); pthread_mutex_unlock(&mutex); } void Java_mlterm_native_1activity_MLActivity_updateScreen(JNIEnv *env, jobject this) { pthread_mutex_lock(&mutex); ui_display_update_all(); pthread_mutex_unlock(&mutex); } void Java_mlterm_native_1activity_MLActivity_execCommand(JNIEnv *env, jobject this, jstring jcmd) { vt_term_t *term; if ((term = get_current_term()) && term->parser->config_listener) { char *cmd = (*env)->GetStringUTFChars(env, jcmd, NULL); char *p; if (strcmp(cmd, "ssh") == 0) { connect_to_ssh_server = 1; } else if ((p = alloca(strlen(cmd) + 1))) { /* * pthread_mutex_lock() shoule be called here because native activity thread * (which reads pty) works. */ pthread_mutex_lock(&mutex); (*term->parser->config_listener->exec)(term->parser->config_listener->self, strcpy(p, cmd)); pthread_mutex_unlock(&mutex); } (*env)->ReleaseStringUTFChars(env, jcmd, cmd); } } jboolean Java_mlterm_native_1activity_MLActivity_isSSH(JNIEnv *env, jobject this) { #ifdef USE_LIBSSH2 vt_term_t *term; if ((term = get_current_term())) { if (vt_term_get_pty_mode(term) == PTY_SSH) { return JNI_TRUE; } } #endif return JNI_FALSE; } void Java_mlterm_native_1activity_MLPreferenceActivity_setConfig(JNIEnv *env, jobject this, jstring jkey, jstring jval) { vt_term_t *term; if ((term = get_current_term()) && term->parser->config_listener) { char *key = (*env)->GetStringUTFChars(env, jkey, NULL); char *val = (*env)->GetStringUTFChars(env, jval, NULL); char *val2; char *path; /* XXX */ if (strcmp(key, "col_size_of_width_a") == 0) { if (strcmp(val, "true") == 0) { val2 = "2"; } else { val2 = "1"; } } else { val2 = val; } #ifdef USE_LIBSSH2 if (strcmp(key, "start_with_local_pty") == 0) { start_with_local_pty = (strcmp(val2, "true") == 0); } else #endif { /* * This function is called while main activity stops (preference activity is active). * But pthread_mutex_lock() shoule be called here because native activity thread * (which reads pty) works. */ pthread_mutex_lock(&mutex); (*term->parser->config_listener->set)(term->parser->config_listener->self, NULL, key, val2); pthread_mutex_unlock(&mutex); } /* Following is the same processing as config_protocol_set() in vt_parser.c */ if (/* XXX */ strcmp(key, "xim") != 0 && (path = bl_get_user_rc_path("mlterm/main"))) { bl_conf_write_t *conf; conf = bl_conf_write_open(path); free(path); if (conf) { bl_conf_io_write(conf, key, val2); bl_conf_write_close(conf); (*term->parser->config_listener->saved)(); } } (*env)->ReleaseStringUTFChars(env, jkey, key); (*env)->ReleaseStringUTFChars(env, jval, val); } } /* * This is called while main activity stops (preference activity is active), so * pthread_mutex_lock() is not called. */ void Java_mlterm_native_1activity_MLPreferenceActivity_setDefaultFontConfig(JNIEnv *env, jobject this, jstring jfont) { vt_term_t *term; if ((term = get_current_term()) && term->parser->config_listener) { char *font = (*env)->GetStringUTFChars(env, jfont, NULL); (*term->parser->config_listener->set_font)(term->parser->config_listener->self, NULL, "USASCII", font, 1); (*term->parser->config_listener->set_font)(term->parser->config_listener->self, NULL, "DEFAULT", font, 1); (*env)->ReleaseStringUTFChars(env, jfont, font); } } /* See vt_pty_intern.h */ char *android_config_response; jboolean Java_mlterm_native_1activity_MLPreferenceActivity_getBoolConfig(JNIEnv *env, jobject this, jstring jkey) { vt_term_t *term; if ((term = get_current_term())) { char *key = (*env)->GetStringUTFChars(env, jkey, NULL); size_t key_len = strlen(key); (*term->parser->config_listener->get)(term->parser->config_listener->self, NULL, key, 1); (*env)->ReleaseStringUTFChars(env, jkey, key); if (android_config_response) { /* XXX */ char *val = strstr(android_config_response, "col_size_of_width_a") ? "2" : "true"; int flag = (strncmp(android_config_response + 1 + key_len + 1, val, strlen(val)) == 0); free(android_config_response); android_config_response = NULL; return flag; } } return 0; } jstring Java_mlterm_native_1activity_MLPreferenceActivity_getStrConfig(JNIEnv *env, jobject this, jstring jkey) { vt_term_t *term; if ((term = get_current_term())) { char *key = (*env)->GetStringUTFChars(env, jkey, NULL); size_t key_len = strlen(key); jstring jval = NULL; (*term->parser->config_listener->get)(term->parser->config_listener->self, NULL, key, 1); if (android_config_response) { if (strncmp(android_config_response + 1, key, key_len) == 0) { /* \n -> \0 */ android_config_response[strlen(android_config_response) - 1] = '\0'; jval = (*env)->NewStringUTF(env, android_config_response + 1 + key_len + 1); } free(android_config_response); android_config_response = NULL; } (*env)->ReleaseStringUTFChars(env, jkey, key); return jval; } return NULL; } jstring Java_mlterm_native_1activity_MLPreferenceActivity_getDefaultFontConfig(JNIEnv *env, jobject this) { vt_term_t *term; if ((term = get_current_term())) { (*term->parser->config_listener->get_font)(term->parser->config_listener->self, NULL, "USASCII", 1); if (android_config_response) { char *p; if ((p = strrchr(android_config_response, '='))) { jstring jfont; /* \n -> \0 */ p[strlen(p) - 1] = '\0'; if (*p) { jfont = (*env)->NewStringUTF(env, p + 1); } else { jfont = NULL; } free(android_config_response); android_config_response = NULL; return jfont; } } } return NULL; } mlterm-3.9.3/android/jni/ui_xic.c000066400000000000000000000045201441203364000166500ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "../ui_xic.h" #include /* --- static variables --- */ static int is_ascii_input; /* --- global functions --- */ int ui_xic_activate(ui_window_t *win, char *xim_name, char *xim_locale) { return 1; } int ui_xic_deactivate(ui_window_t *win) { return 1; } char *ui_xic_get_xim_name(ui_window_t *win) { return ""; } char *ui_xic_get_default_xim_name(void) { return ""; } int ui_xic_fg_color_changed(ui_window_t *win) { return 0; } int ui_xic_bg_color_changed(ui_window_t *win) { return 0; } int ui_xic_font_set_changed(ui_window_t *win) { return 0; } int ui_xic_resized(ui_window_t *win) { return 0; } int ui_xic_set_spot(ui_window_t *win) { return 0; } size_t ui_xic_get_str(ui_window_t *win, u_char *seq, size_t seq_len, ef_parser_t **parser, KeySym *keysym, XKeyEvent *event) { return 0; } size_t ui_xic_get_utf8_str(ui_window_t *win, u_char *seq, size_t seq_len, ef_parser_t **parser, KeySym *keysym, XKeyEvent *event) { return 0; } int ui_xic_filter_event(ui_window_t *win, /* Should be root window. */ XEvent *event) { return 0; } int ui_xic_set_focus(ui_window_t *win) { return 1; } int ui_xic_unset_focus(ui_window_t *win) { return 1; } int ui_xic_is_active(ui_window_t *win) { return is_ascii_input == 0; } int ui_xic_switch_mode(ui_window_t *win) { JNIEnv *env; jobject this; if ((*win->disp->display->app->activity->vm)->GetEnv(win->disp->display->app->activity->vm, &env, JNI_VERSION_1_6) != JNI_OK) { return 0; } this = win->disp->display->app->activity->clazz; if (is_ascii_input) { (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "normalInput", "()V")); is_ascii_input = 0; } else { (*env)->CallVoidMethod(env, this, (*env)->GetMethodID(env, (*env)->GetObjectClass(env, this), "asciiInput", "()V")); is_ascii_input = 1; } } #if 0 /* * ui_xim.c <-> ui_xic.c communication functions * Not necessary in fb. */ int x_xim_activated(ui_window_t *win) { return 1; } int x_xim_destroyed(ui_window_t *win) { return 1; } #endif mlterm-3.9.3/android/jni/version.h000066400000000000000000000012131441203364000170560ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __VERSION_H__ #define __VERSION_H__ #include #define MAJOR_VERSION 3 #define MINOR_VERSION 9 #define REVISION 3 #define PATCH_LEVEL 0 #if 0 #define CHANGE_DATE "pre/@CHANGE_DATE@" #elif 0 #define CHANGE_DATE "post/@CHANGE_DATE@" #else #define CHANGE_DATE "" #endif #define VERSION \ BL_INT_TO_STR(MAJOR_VERSION) "." BL_INT_TO_STR(MINOR_VERSION) "." BL_INT_TO_STR(REVISION) #if PATCH_LEVEL == 0 #define DETAIL_VERSION VERSION " " CHANGE_DATE #else #define DETAIL_VERSION VERSION " patch level " BL_INT_TO_STR(PATCH_LEVEL) " " CHANGE_DATE #endif #endif mlterm-3.9.3/android/prepare-ant.sh000077500000000000000000000037011441203364000172210ustar00rootroot00000000000000#!/bin/sh if [ $# != 1 ]; then echo "Usage: prepare.sh [android project path]" echo "(prepare.sh ~/work/mlterm-x.x.x/android => setup at ~/work/mlterm-x.x.x/android)" echo "(prepare.sh . => setup at the current directory)" exit 1 fi PROJECT_PATH=$1 echo "Prepare to build for android. (project: ${PROJECT_PATH})" echo "Press enter key to continue." read IN mkdir -p ${PROJECT_PATH} cp build-ant.sh ${PROJECT_PATH}/ chmod 755 ${PROJECT_PATH}/build-ant.sh cp *.xml ${PROJECT_PATH}/ mkdir -p ${PROJECT_PATH}/jni/baselib/pobl ${PROJECT_PATH}/jni/baselib/src cp ../baselib/src/*.[ch] ${PROJECT_PATH}/jni/baselib/src/ cp jni/bl_*.h ${PROJECT_PATH}/jni/baselib/src/ cp ${PROJECT_PATH}/jni/baselib/src/*.h ${PROJECT_PATH}/jni/baselib/pobl/ mkdir -p ${PROJECT_PATH}/jni/encodefilter/mef cp -R ../encodefilter/src ../encodefilter/module ${PROJECT_PATH}/jni/encodefilter cp ${PROJECT_PATH}/jni/encodefilter/src/*.h ${PROJECT_PATH}/jni/encodefilter/mef/ cp -R ../libind ${PROJECT_PATH}/jni/ cp -R ../vtemu ${PROJECT_PATH}/jni/ mkdir -p ${PROJECT_PATH}/jni/uitoolkit/fb mkdir -p ${PROJECT_PATH}/jni/uitoolkit/libotl cp ../uitoolkit/*.[ch] ${PROJECT_PATH}/jni/uitoolkit cp ../uitoolkit/fb/*.[ch] ${PROJECT_PATH}/jni/uitoolkit/fb cp ../uitoolkit/libotl/*.[ch] ${PROJECT_PATH}/jni/uitoolkit/libotl mkdir -p ${PROJECT_PATH}/jni/main cp ../main/*.[ch] ${PROJECT_PATH}/jni/main/ mkdir -p ${PROJECT_PATH}/jni/common cp ../common/c_imagelib.c ${PROJECT_PATH}/jni/common/ cp ../common/c_sixel.c ${PROJECT_PATH}/jni/common/ cp ../common/c_animgif.c ${PROJECT_PATH}/jni/common/ cp jni/Android.mk ${PROJECT_PATH}/jni/ cp jni/ui_event_source.c ${PROJECT_PATH}/jni/uitoolkit/ cp jni/ui.h jni/ui_display.[ch] jni/ui_connect_dialog.c ${PROJECT_PATH}/jni/uitoolkit/fb/ cp jni/main.c jni/version.h ${PROJECT_PATH}/jni/main/ mkdir -p ${PROJECT_PATH}/src/mlterm/native_activity cp src/mlterm/native_activity/*.java ${PROJECT_PATH}/src/mlterm/native_activity/ cp -R res ${PROJECT_PATH}/ echo "done." mlterm-3.9.3/android/prepare-gradle.sh000077500000000000000000000132401441203364000176740ustar00rootroot00000000000000#!/bin/sh if [ $# != 1 -a $# != 3 ]; then echo "Usage: prepare.sh [android project path]" echo " prepare.sh [android project path] [mosh src path] [openssl src path]" echo "(prepare.sh ~/work/mlterm-x.x.x/android => setup at ~/work/mlterm-x.x.x/android)" echo "(prepare.sh . => setup at the current directory)" exit 1 fi PROJECT_PATH=$1 echo "Prepare to build for android. (project: ${PROJECT_PATH})" echo "Press enter key to continue." read IN if [ $# = 3 ]; then MOSH_SRC_PATH=$2 OPENSSL_SRC_PATH=$3 if [ ! -d ${MOSH_SRC_PATH} ]; then echo "${MOSH_SRC_PATH} doesn't exist." exit 1 elif [ ! -d ${OPENSSL_SRC_PATH}/include/openssl ]; then echo "${OPENSSL_SRC_PATH}/include/openssl doesn't exist." exit 1 fi mkdir -p ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh CRYPTO_FILES="ae.h base64.cc base64.h byteorder.h crypto.cc crypto.h ocb.cc prng.h" STATESYNC_FILES="completeterminal.cc completeterminal.h user.cc user.h" NETWORK_FILES="compressor.cc compressor.h network.cc network.h networktransport.h \ networktransport-impl.h transportfragment.cc transportfragment.h \ transportsender.h transportsender-impl.h transportstate.h" UTIL_FILES="dos_assert.h fatal_assert.h shared.h timestamp.cc timestamp.h" PROTOBUFS_FILES="hostinput.pb.cc hostinput.pb.h transportinstruction.pb.cc \ transportinstruction.pb.h userinput.pb.cc userinput.pb.h" TERMINAL_FILES="parseraction.cc parseraction.h parser.cc parser.h parserstate.cc \ parserstatefamily.h parserstate.h parsertransition.h terminal.cc \ terminaldispatcher.cc terminaldispatcher.h terminaldisplay.cc terminaldisplay.h \ terminalframebuffer.cc terminalframebuffer.h terminalfunctions.cc \ terminal.h terminaluserinput.cc terminaluserinput.h" FRONTEND_FILES="terminaloverlay.cc terminaloverlay.h" for f in $CRYPTO_FILES; do cp ${MOSH_SRC_PATH}/src/crypto/$f ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh done for f in $STATESYNC_FILES; do cp ${MOSH_SRC_PATH}/src/statesync/$f ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh done for f in $NETWORK_FILES; do cp ${MOSH_SRC_PATH}/src/network/$f ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh done for f in $UTIL_FILES; do cp ${MOSH_SRC_PATH}/src/util/$f ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh done for f in $PROTOBUFS_FILES; do cp ${MOSH_SRC_PATH}/src/protobufs/$f ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh done for f in $TERMINAL_FILES; do cp ${MOSH_SRC_PATH}/src/terminal/$f ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh done for f in $FRONTEND_FILES; do cp ${MOSH_SRC_PATH}/src/frontend/$f ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh done cp ${MOSH_SRC_PATH}/config.h ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh echo "Comment out \"#define HAVE_TR1_MEMORY 1\" in vtemu/libptymosh/config.h" cp -r ${OPENSSL_SRC_PATH}/include/openssl ${PROJECT_PATH}/app/src/main/jni/vtemu/libptymosh else mkdir -p ${PROJECT_PATH}/app/src/main fi (cd ${PROJECT_PATH}; rm build.gradle settings.gradle app/build.gradle; gradle init) if [ $? != 0 ]; then echo "Install and setup gradle in advance." exit 1 fi cp build-gradle.sh ${PROJECT_PATH}/ chmod 755 ${PROJECT_PATH}/build-gradle.sh cp AndroidManifest.xml ${PROJECT_PATH}/app/src/main mkdir -p ${PROJECT_PATH}/app/src/main/jni/baselib/pobl ${PROJECT_PATH}/app/src/main/jni/baselib/src cp ../baselib/src/*.[ch] ${PROJECT_PATH}/app/src/main/jni/baselib/src/ cp jni/bl_*.h ${PROJECT_PATH}/app/src/main/jni/baselib/src/ cp ${PROJECT_PATH}/app/src/main/jni/baselib/src/*.h ${PROJECT_PATH}/app/src/main/jni/baselib/pobl/ mkdir -p ${PROJECT_PATH}/app/src/main/jni/encodefilter/mef cp -R ../encodefilter/src ../encodefilter/module ${PROJECT_PATH}/app/src/main/jni/encodefilter cp ${PROJECT_PATH}/app/src/main/jni/encodefilter/src/*.h ${PROJECT_PATH}/app/src/main/jni/encodefilter/mef/ cp -R ../libind ${PROJECT_PATH}/app/src/main/jni/ cp -R ../vtemu ${PROJECT_PATH}/app/src/main/jni/ mkdir -p ${PROJECT_PATH}/app/src/main/jni/uitoolkit/fb mkdir -p ${PROJECT_PATH}/app/src/main/jni/uitoolkit/libotl cp ../uitoolkit/*.[ch] ${PROJECT_PATH}/app/src/main/jni/uitoolkit cp ../uitoolkit/fb/*.[ch] ${PROJECT_PATH}/app/src/main/jni/uitoolkit/fb cp ../uitoolkit/libotl/*.[ch] ${PROJECT_PATH}/app/src/main/jni/uitoolkit/libotl mkdir -p ${PROJECT_PATH}/app/src/main/jni/main cp ../main/*.[ch] ${PROJECT_PATH}/app/src/main/jni/main/ mkdir -p ${PROJECT_PATH}/app/src/main/jni/common cp ../common/c_imagelib.c ${PROJECT_PATH}/app/src/main/jni/common/ cp ../common/c_sixel.c ${PROJECT_PATH}/app/src/main/jni/common/ cp ../common/c_animgif.c ${PROJECT_PATH}/app/src/main/jni/common/ cp jni/Android.mk ${PROJECT_PATH}/app/src/main/jni/ cp jni/ui_event_source.c ${PROJECT_PATH}/app/src/main/jni/uitoolkit/ cp jni/ui.h jni/ui_display.[ch] jni/ui_connect_dialog.c ${PROJECT_PATH}/app/src/main/jni/uitoolkit/fb/ cp jni/main.c jni/version.h ${PROJECT_PATH}/app/src/main/jni/main/ mkdir -p ${PROJECT_PATH}/app/src/main/java/mlterm/native_activity cp src/mlterm/native_activity/*.java ${PROJECT_PATH}/app/src/main/java/mlterm/native_activity/ cp -R res ${PROJECT_PATH}/app/src/main GRADLE_VER=`gradle --version|sed -n 's/Gradle \([0-9.]*\)/\1/p'` cat << END > ${PROJECT_PATH}/build.gradle buildscript { repositories { jcenter() //google() maven { url 'https://maven.google.com/' name 'Google' } } dependencies { classpath 'com.android.tools.build:gradle:$GRADLE_VER' } } allprojects { repositories { jcenter() //google() maven { url 'https://maven.google.com/' name 'Google' } } } END echo "include ':app'" > ${PROJECT_PATH}/settings.gradle cp build.gradle ${PROJECT_PATH}/app echo "done." mlterm-3.9.3/android/res/000077500000000000000000000000001441203364000152345ustar00rootroot00000000000000mlterm-3.9.3/android/res/values/000077500000000000000000000000001441203364000165335ustar00rootroot00000000000000mlterm-3.9.3/android/res/values/strings.xml000066400000000000000000000001641441203364000207470ustar00rootroot00000000000000 mlterm mlterm-3.9.3/android/src/000077500000000000000000000000001441203364000152325ustar00rootroot00000000000000mlterm-3.9.3/android/src/mlterm/000077500000000000000000000000001441203364000165325ustar00rootroot00000000000000mlterm-3.9.3/android/src/mlterm/native_activity/000077500000000000000000000000001441203364000217345ustar00rootroot00000000000000mlterm-3.9.3/android/src/mlterm/native_activity/MLActivity.java000066400000000000000000000744461441203364000246430ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ package mlterm.native_activity; import android.app.NativeActivity; import android.view.KeyEvent; import android.view.WindowManager; import android.view.WindowManager.LayoutParams; import android.view.inputmethod.InputMethodManager; import android.view.inputmethod.InputConnection; import android.view.inputmethod.CompletionInfo; import android.view.inputmethod.BaseInputConnection; import android.view.inputmethod.EditorInfo; import android.view.inputmethod.CorrectionInfo; import android.view.View; import android.view.ViewGroup; import android.view.ContextMenu; import android.view.MenuInflater; import android.view.MenuItem; import android.view.View.OnClickListener; import android.text.InputType; import android.content.Context; import android.content.ClipboardManager; import android.content.ClipData; import android.content.ClipDescription; import android.content.Intent; import android.os.Bundle; import android.os.Handler; import android.graphics.Rect; import android.graphics.BitmapFactory; import android.graphics.Bitmap; import android.util.AttributeSet; import java.net.URI; import java.net.URL; import java.io.*; import android.widget.EditText; import android.widget.TextView; import android.widget.LinearLayout; import android.widget.TableLayout; import android.widget.TableRow; import android.widget.Button; import android.widget.AdapterView.AdapterContextMenuInfo; import android.widget.Toast; import android.content.DialogInterface; import android.app.AlertDialog; import android.app.Dialog; import android.graphics.Color; public class MLActivity extends NativeActivity { static { System.loadLibrary("mlterm"); } private native void visibleFrameChanged(int yoffset, int width, int height); private native void commitTextLock(String str); private native void commitTextNoLock(String str); private native void preeditText(String str); private native String convertToTmpPath(String path); private native void splitAnimationGif(String path); private native void dialogOkClicked(String user, String serv /* can include proto */, String port, String encoding, String pass, String cmd, String privkey); private native void updateScreen(); private native void execCommand(String cmd); private native boolean isSSH(); private String keyString; private View contentView; private int inputType = InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_FLAG_MULTI_LINE; private int imeOptions = EditorInfo.IME_FLAG_NO_ENTER_ACTION | EditorInfo.IME_ACTION_DONE | EditorInfo.IME_FLAG_NO_FULLSCREEN; private ClipboardManager clipMan; private Thread nativeThread; private boolean needRedraw = false; private class TextInputConnection extends BaseInputConnection { public TextInputConnection(View v, boolean fulledit) { super(v, fulledit); } @Override public boolean commitText(CharSequence text, int newCursorPosition) { super.commitText(text, newCursorPosition); if (nativeThread == null) { commitTextLock(text.toString()); } return true; } @Override public boolean commitCompletion(CompletionInfo text) { super.commitCompletion(text); if (nativeThread == null) { commitTextLock(text.getText().toString()); } return true; } @Override public boolean commitCorrection(CorrectionInfo correctionInfo) { super.commitCorrection(correctionInfo); if (nativeThread == null) { commitTextLock(correctionInfo.getNewText().toString()); } return true; } @Override public boolean setComposingText(CharSequence text, int newCursorPosition) { super.setComposingText(text, newCursorPosition); if (nativeThread == null) { preeditText(text.toString()); } return true; } @Override public boolean finishComposingText() { super.finishComposingText(); if (nativeThread == null) { preeditText(""); } return true; } } private class NativeContentView extends View { public NativeContentView(Context context) { super(context); } public NativeContentView(Context context, AttributeSet attrs) { super(context, attrs); } @Override public boolean onCheckIsTextEditor() { return true; } @Override public InputConnection onCreateInputConnection(EditorInfo outAttrs) { outAttrs.inputType = inputType; outAttrs.imeOptions = imeOptions; return new TextInputConnection(this, true); } } private void asciiInput() { //inputType &= ~InputType.TYPE_TEXT_FLAG_MULTI_LINE; if (false) { inputType |= InputType.TYPE_TEXT_VARIATION_URI; } else { inputType |= InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD; } imeOptions |= 0x80000000; /* EditorInfo.IME_FLAG_FORCE_ASCII ; (API level 16) */ ((InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE)).restartInput(contentView); } private void normalInput() { //inputType |= InputType.TYPE_TEXT_FLAG_MULTI_LINE; if (false) { inputType &= ~InputType.TYPE_TEXT_VARIATION_URI; } else { inputType &= ~InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD; } imeOptions &= ~0x80000000; /* EditorInfo.IME_FLAG_FORCE_ASCII ; (API level 16) */ ((InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE)).restartInput(contentView); } private void showSoftInput() { ((InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE)) .showSoftInput(contentView, InputMethodManager.SHOW_FORCED); } private void setTextToClipboard(String str) { ClipData.Item item = new ClipData.Item(str); String[] mimeType = new String[1]; mimeType[0] = ClipDescription.MIMETYPE_TEXT_PLAIN; ClipData cd = new ClipData(new ClipDescription("text_data", mimeType), item); clipMan.setPrimaryClip(cd); } private void getTextFromClipboard() { ClipData cd = clipMan.getPrimaryClip(); if (cd != null) { ClipData.Item item = cd.getItemAt(0); commitTextNoLock(item.getText().toString()); } } @Override public boolean dispatchKeyEvent(KeyEvent event) { if (event.getAction() == KeyEvent.ACTION_MULTIPLE) { keyString = event.getCharacters(); } return super.dispatchKeyEvent(event); } @Override protected void onCreate(Bundle state) { super.onCreate(state); getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_VISIBLE); if (false) { /* setContentView() is called in NativeActivity.onCreate(). */ contentView = ((ViewGroup) findViewById(android.R.id.content)).getChildAt(0); } else { contentView = new NativeContentView(this); setContentView(contentView); contentView.getViewTreeObserver().addOnGlobalLayoutListener(this); } contentView.setFocusable(true); contentView.setFocusableInTouchMode(true); contentView.requestFocus(); registerForContextMenu(contentView); /* android-11 or later */ getWindow().getDecorView().addOnLayoutChangeListener(new View.OnLayoutChangeListener() { @Override public void onLayoutChange(View v, int left, int top, int right, int bottom, int oldLeft, int oldTop, int oldRight, int oldBottom) { Rect r = new Rect(); v.getWindowVisibleDisplayFrame(r); if (nativeThread == null) { visibleFrameChanged(r.top, r.right, r.bottom - r.top); } } }); /* * It is prohibited to call getSystemService(CLIPBOARD_SERVICE) * in native activity thread. */ clipMan = (ClipboardManager) getSystemService(Context.CLIPBOARD_SERVICE); } @Override protected void onSaveInstanceState(Bundle state) { if (nativeThread != null) { synchronized(nativeThread) { nativeThread.notifyAll(); /* AlertDialog is ignored if home button is pressed. */ } } super.onSaveInstanceState(state); } @Override protected void onPause() { if (nativeThread != null) { synchronized(nativeThread) { nativeThread.notifyAll(); /* AlertDialog is ignored if back button is pressed. */ } } super.onPause(); ((InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE)) .hideSoftInputFromWindow(contentView.getWindowToken(), 0); needRedraw = true; /* See APP_CMD_PAUSE in ui_display.c */ } @Override protected void onStop() { super.onStop(); needRedraw = false; } @Override protected void onResume() { super.onResume(); if (needRedraw) { updateScreen(); needRedraw = false; } /* See APP_CMD_RESUME in ui_display.c */ } @Override protected void onRestart() { super.onRestart(); showSoftInput(); } private void performLongClick() { runOnUiThread(new Runnable() { @Override public void run() { contentView.performLongClick(); } }); } private final int MENU_PASTE_ID = 0; private final int MENU_NEWSCREEN_ID = 1; private final int MENU_LOCALPTY_ID = 2; private final int MENU_SSH_ID = 3; private final int MENU_VSPLIT_ID = 4; private final int MENU_HSPLIT_ID = 5; private final int MENU_NEXTPTY_ID = 6; private final int MENU_PREVPTY_ID = 7; private final int MENU_UPDATESCREEN_ID = 8; private final int MENU_CLOSESCREEN_ID = 9; private final int MENU_ZMODEM_START_ID = 10; private final int MENU_RESET_ID = 11; private final int MENU_SCP_ID = 12; private final int MENU_CONFIG_ID = 13; private final int MENU_CANCEL_ID = 14; @Override public void onCreateContextMenu(ContextMenu menu, View view, ContextMenu.ContextMenuInfo info) { super.onCreateContextMenu(menu, view, info); /* menu.setHeaderTitle("Menu"); */ menu.add(0, MENU_PASTE_ID, 0, "Paste from clipboard"); menu.add(0, MENU_NEWSCREEN_ID, 0, "Open new screen"); menu.add(0, MENU_LOCALPTY_ID, 0, "Open local pty"); menu.add(0, MENU_SSH_ID, 0, "Connect to SSH server"); if (isSSH()) { menu.add(0, MENU_SCP_ID, 0, "SCP"); } menu.add(0, MENU_VSPLIT_ID, 0, "Split screen vertically"); menu.add(0, MENU_HSPLIT_ID, 0, "Split screen horizontally"); menu.add(0, MENU_NEXTPTY_ID, 0, "Next pty"); menu.add(0, MENU_PREVPTY_ID, 0, "Previous pty"); menu.add(0, MENU_UPDATESCREEN_ID, 0, "Update screen"); menu.add(0, MENU_CLOSESCREEN_ID, 0, "Close splitted screen"); menu.add(0, MENU_ZMODEM_START_ID, 0, "Start zmodem"); menu.add(0, MENU_RESET_ID, 0, "Reset terminal"); menu.add(0, MENU_CONFIG_ID, 0, "Configuration"); menu.add(0, MENU_CANCEL_ID, 0, "Cancel"); } @Override public boolean onContextItemSelected(MenuItem item) { switch (item.getItemId()) { case MENU_PASTE_ID: getTextFromClipboard(); return true; case MENU_NEWSCREEN_ID: execCommand("open_pty"); return true; case MENU_LOCALPTY_ID: execCommand("mlclientx --serv="); return true; case MENU_SSH_ID: execCommand("ssh"); return true; case MENU_VSPLIT_ID: execCommand("vsplit_screen"); return true; case MENU_HSPLIT_ID: execCommand("hsplit_screen"); return true; case MENU_NEXTPTY_ID: execCommand("next_pty"); return true; case MENU_PREVPTY_ID: execCommand("prev_pty"); return true; case MENU_UPDATESCREEN_ID: updateScreen(); return true; case MENU_CLOSESCREEN_ID: execCommand("close_screen"); return true; case MENU_ZMODEM_START_ID: execCommand("zmodem_start"); return true; case MENU_RESET_ID: execCommand("full_reset"); return true; case MENU_SCP_ID: showDialog(2); /* SCP dialog */ return true; case MENU_CONFIG_ID: Intent intent = new Intent(this, MLPreferenceActivity.class); startActivity(intent); return true; default: return super.onContextItemSelected(item); } } private String saveDefaultFont() { File file = getFileStreamPath("unifont.pcf"); if (!file.exists() || /* If unifont.pcf is older than apk, rewrite unifont.pcf. */ (new File(getApplicationInfo().publicSourceDir)).lastModified() > file.lastModified()) { try { InputStream is = getResources().getAssets().open("unifont.pcf"); OutputStream os = openFileOutput("unifont.pcf", 0); int len; byte[] buf = new byte[102400]; while ((len = is.read(buf)) >= 0) { os.write(buf, 0, len); } os.close(); is.close(); System.err.println("unifont.pcf written.\n"); } catch (Exception e) { } } return file.getPath(); } private int[] getBitmap(String path, int width, int height) { try { InputStream is; if (path.indexOf("://") != -1) { URL url = new URL(path); is = url.openConnection().getInputStream(); if (path.indexOf(".gif") != -1) { String tmp = convertToTmpPath(path); OutputStream os = new FileOutputStream(tmp); int len; byte[] buf = new byte[10240]; while ((len = is.read(buf)) >= 0) { os.write(buf, 0, len); } os.close(); is.close(); splitAnimationGif(path); is = new FileInputStream(tmp); } } else { if (path.indexOf("mlterm/anim") == -1 && path.indexOf(".gif") != -1) { splitAnimationGif(path); } is = new FileInputStream(path); } Bitmap bmp = BitmapFactory.decodeStream(is); /* decodeStream() can return null. */ if (bmp != null) { if (width != 0 && height != 0) { bmp = Bitmap.createScaledBitmap(bmp, width, height, false); } width = bmp.getWidth(); height = bmp.getHeight(); int[] pixels = new int[width * height + 2]; bmp.getPixels(pixels, 0, width, 0, 0, width, height); pixels[pixels.length - 2] = width; pixels[pixels.length - 1] = height; return pixels; } } catch (Exception e) { System.err.println(e); } return null; } private LinearLayout makeTextEntry(String title, EditText edit) { LinearLayout layout = new LinearLayout(this); layout.setOrientation(LinearLayout.HORIZONTAL); TextView label = new TextView(this); label.setBackgroundColor(Color.TRANSPARENT); label.setText(title); layout.addView(label, new LinearLayout.LayoutParams(LinearLayout.LayoutParams.FILL_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT, 2)); layout.addView(edit, new LinearLayout.LayoutParams(LinearLayout.LayoutParams.FILL_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT, 1)); return layout; } private EditText serv_edit; private EditText port_edit; private EditText user_edit; private EditText pass_edit; private EditText encoding_edit; private EditText cmd_edit; private EditText privkey_edit; private LinearLayout connectDialogLayout; private TableLayout servListDialogLayout; private boolean openLocalPty = false; @Override protected Dialog onCreateDialog(int id) { if (id == 1) { Dialog dialog = new AlertDialog.Builder(this) .setIcon(android.R.drawable.ic_dialog_info) .setTitle("Connect to SSH Server") .setView(connectDialogLayout) .setPositiveButton("Connect", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int whichButton) { dialogOkClicked(user_edit.getText().toString(), serv_edit.getText().toString(), port_edit.getText().toString(), encoding_edit.getText().toString(), pass_edit.getText().toString(), cmd_edit.getText().toString(), privkey_edit.getText().toString()); } }) .setNegativeButton("Local", null) .create(); dialog.setOnDismissListener(new DialogInterface.OnDismissListener() { public void onDismiss(DialogInterface dialog) { if (nativeThread != null) { synchronized(nativeThread) { nativeThread.notifyAll(); } } } }); return dialog; } else if (id == 3) { Dialog dialog = new AlertDialog.Builder(this) .setIcon(android.R.drawable.ic_dialog_info) .setTitle("Server List") .setView(servListDialogLayout) .setPositiveButton("Save&Next", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int whichButton) { writeServerList(); } }) .setNegativeButton("Local", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int whichButton) { openLocalPty = true; } }) .create(); dialog.setOnDismissListener(new DialogInterface.OnDismissListener() { public void onDismiss(DialogInterface dialog) { if (nativeThread != null) { synchronized(nativeThread) { nativeThread.notifyAll(); } } } }); return dialog; } else if (id == 2) { final EditText remote_edit; final EditText local_edit; LinearLayout layout = new LinearLayout(this); layout.setOrientation(LinearLayout.VERTICAL); LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.FILL_PARENT, LinearLayout.LayoutParams.FILL_PARENT); remote_edit = new EditText(this); remote_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); layout.addView(makeTextEntry("Remote", remote_edit), params); local_edit = new EditText(this); local_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); layout.addView(makeTextEntry("Local ", local_edit), params); Dialog dialog = new AlertDialog.Builder(this) .setIcon(android.R.drawable.ic_dialog_info) .setTitle("Source file path / Dest dir path") .setView(layout) .setPositiveButton("Send", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int whichButton) { execCommand("scp \"local:" + local_edit.getText().toString() + "\" \"remote:" + remote_edit.getText().toString() + "\""); } }) .setNeutralButton("Receive", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int whichButton) { execCommand("scp \"remote:" + remote_edit.getText().toString() + "\" \"local:" + local_edit.getText().toString() + "\""); } }) .setNegativeButton("Cancel", null) .create(); return dialog; } else { return null; } } /* 0: Select, 1:Server, 2:User, 3:Port, 4:Encoding, 5: Privkey, 6: X, 7: + */ private final int SERVER_LIST_COLUMNS = 8; /* See bl_get_home_dir() in bl_path.c */ private String getServerListConfig() throws IOException { String configDir; File file = new File("/sdcard"); if (file.isDirectory()) { configDir = "/sdcard/.mlterm"; } else { file = new File("/mnt/sdcard"); if (file.isDirectory()) { configDir = "/mnt/sdcard/.mlterm"; } else { file = new File("/extsdcard"); if (file.isDirectory()) { configDir = "/extsdcard"; } else { showMessage("Config dir not found"); throw new IOException(); } } } file = new File(configDir); if (!file.exists()) { try { file.mkdir(); } catch (Exception e) { showMessage("Failed to make " + configDir); throw new IOException(); } } return configDir + "/servers"; } private void writeServerList() { try { FileWriter out = new FileWriter(getServerListConfig()); int num = servListDialogLayout.getChildCount(); for (int count = 1 /* skip title */; count < num; count++) { TableRow tableRow = (TableRow)servListDialogLayout.getChildAt(count); if (tableRow.getChildCount() == SERVER_LIST_COLUMNS) { String server = ((EditText)tableRow.getChildAt(1)).getText().toString(); if (!server.isEmpty()) { int proto_end = server.indexOf("://"); if (proto_end == -1) { out.write("ssh://"); } else { out.write(server.substring(0, proto_end + 3)); server = server.substring(proto_end + 3); } String user = ((EditText)tableRow.getChildAt(2)).getText().toString(); if (!user.isEmpty()) { out.write(user); out.write("@"); } out.write(server); String port = ((EditText)tableRow.getChildAt(3)).getText().toString(); if (!port.isEmpty()) { out.write(":"); out.write(port); } out.write("\t"); out.write(((EditText)tableRow.getChildAt(4)).getText().toString()); out.write("\t"); out.write(((EditText)tableRow.getChildAt(5)).getText().toString()); out.write("\tEOL\n"); } } } out.close(); } catch (IOException e) { //e.printStackTrace(); } } private void addServerToTable(URI uri, String encoding, String privkey, int index) { final TableRow tableRow = new TableRow(this); final EditText e_serv = new EditText(this); final EditText e_user = new EditText(this); final EditText e_port = new EditText(this); final EditText e_encoding = new EditText(this); final EditText e_privkey = new EditText(this); if (uri != null) { String proto = uri.getScheme(); if (proto.equals("mosh")) { e_serv.setText("mosh://" + uri.getHost()); } else { e_serv.setText(uri.getHost()); } e_user.setText(uri.getUserInfo()); int port = uri.getPort(); if (port != -1) { e_port.setText(String.valueOf(port)); } } if (encoding != null) { e_encoding.setText(encoding); } if (privkey != null) { e_privkey.setText(privkey); } Button button = new Button(this); button.setText("Select"); button.setOnClickListener(new OnClickListener() { public void onClick(View v) { writeServerList(); serv_edit = e_serv; user_edit = e_user; port_edit = e_port; encoding_edit = e_encoding; privkey_edit = e_privkey; dismissDialog(3); } }); tableRow.addView(button); tableRow.addView(e_serv); tableRow.addView(e_user); tableRow.addView(e_port); tableRow.addView(e_encoding); tableRow.addView(e_privkey); button = new Button(this); button.setText("X"); button.setOnClickListener(new OnClickListener() { public void onClick(View v) { servListDialogLayout.removeView(tableRow); } }); tableRow.addView(button); button = new Button(this); button.setText("+"); button.setOnClickListener(new OnClickListener() { public void onClick(View v) { int num = servListDialogLayout.getChildCount(); for (int count = 1; count < num; count++) { if (servListDialogLayout.getChildAt(count) == tableRow) { addServerToTable(null, null, null, count); break; } } } }); tableRow.addView(button); if (index >= 0) { servListDialogLayout.addView(tableRow, index); } else { servListDialogLayout.addView(tableRow); } } private void showServerList() { servListDialogLayout = new TableLayout(this); TableRow tableRow = new TableRow(this); String title[] = { "", "Server", "User", "Port", "Encoding", "Privkey", "", "" }; for (int count = 0; count < title.length; count++) { TextView text = new TextView(this); text.setText(title[count]); tableRow.addView(text); } servListDialogLayout.addView(tableRow); try { BufferedReader in = new BufferedReader(new FileReader(getServerListConfig())); String line; while ((line = in.readLine()) != null) { String[] list = line.split("\t"); if (list.length == 4) { /* list[3] == "EOL" */ try { /* Can throw IllegalArgumentException or NullPointerException */ URI uri = URI.create(list[0]); addServerToTable(uri, list[1], list[2], -1); } catch (Exception e) { //e.printStackTrace(); } } } in.close(); } catch (FileNotFoundException e) { } catch (IOException e) { } /* Empty entry at the end */ addServerToTable(null, null, null, -1); /* 1:Server, 2:User, 3:Port, 4:Encoding, 5: Privkey, 6: X, 7: + */ for (int index = 1; index < SERVER_LIST_COLUMNS; index++) { servListDialogLayout.setColumnShrinkable(index, true); } synchronized(nativeThread) { runOnUiThread(new Runnable() { @Override public void run() { showDialog(3); } }); try { nativeThread.wait(); } catch (InterruptedException e) {} } removeDialog(1); servListDialogLayout = null; } /* Called from native activity thread */ private void showConnectDialog(String proto, String user, String serv, String port, String encoding, String privkey) { nativeThread = Thread.currentThread(); if (serv == null) { showServerList(); if (openLocalPty) { nativeThread = null; openLocalPty = false; return; } } connectDialogLayout = new LinearLayout(this); connectDialogLayout.setOrientation(LinearLayout.VERTICAL); LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.FILL_PARENT, LinearLayout.LayoutParams.FILL_PARENT); /* * showServerList() can set serv_edit, user_edit, port_edit, encoding_edit * and privkey_edit. */ if (serv_edit != null) { serv = serv_edit.getText().toString(); proto = null; /* Prefer the value of showServerList() */ } if (user_edit != null) { user = user_edit.getText().toString(); } if (port_edit != null) { port = port_edit.getText().toString(); } if (encoding_edit != null) { encoding = encoding_edit.getText().toString(); } if (privkey_edit != null) { privkey = privkey_edit.getText().toString(); } serv_edit = new EditText(this); serv_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); connectDialogLayout.addView(makeTextEntry("Server ", serv_edit), params); port_edit = new EditText(this); port_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); connectDialogLayout.addView(makeTextEntry("Port ", port_edit), params); user_edit = new EditText(this); user_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); connectDialogLayout.addView(makeTextEntry("User ", user_edit), params); pass_edit = new EditText(this); pass_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_PASSWORD); connectDialogLayout.addView(makeTextEntry("Password ", pass_edit), params); encoding_edit = new EditText(this); encoding_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD); connectDialogLayout.addView(makeTextEntry("Encoding ", encoding_edit), params); cmd_edit = new EditText(this); cmd_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); connectDialogLayout.addView(makeTextEntry("Exec Cmd ", cmd_edit), params); privkey_edit = new EditText(this); privkey_edit.setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); connectDialogLayout.addView(makeTextEntry("Priv key ", privkey_edit), params); boolean serv_value_is_set; if (serv != null && !serv.isEmpty()) { if (proto == null) { serv_edit.setText(serv, TextView.BufferType.NORMAL); } else { serv_edit.setText(proto + "://" + serv, TextView.BufferType.NORMAL); } serv_value_is_set = true; } else { serv_value_is_set = false; } if (port != null && !port.isEmpty()) { port_edit.setText(port, TextView.BufferType.NORMAL); } final EditText focus_edit; if (user != null && !user.isEmpty()) { user_edit.setText(user, TextView.BufferType.NORMAL); if (serv_value_is_set) { focus_edit = pass_edit; } else { focus_edit = null; } } else { if (serv_value_is_set) { focus_edit = user_edit; } else { focus_edit = null; } } if (encoding != null && !encoding.isEmpty()) { encoding_edit.setText(encoding, TextView.BufferType.NORMAL); } if (privkey != null && !privkey.isEmpty()) { privkey_edit.setText(privkey, TextView.BufferType.NORMAL); } synchronized(nativeThread) { runOnUiThread(new Runnable() { @Override public void run() { if (focus_edit != null) { focus_edit.requestFocus(); } showDialog(1); } }); try { nativeThread.wait(); } catch (InterruptedException e) {} } nativeThread = null; removeDialog(1); serv_edit = port_edit = user_edit = pass_edit = encoding_edit = cmd_edit = privkey_edit = null; connectDialogLayout = null; } /* Called from native activity thread or UI thread (from context menu) */ private void showMessage(String message) { final Context ctx = this; final String msg = message; runOnUiThread(new Runnable() { @Override public void run() { Toast.makeText(ctx, msg, Toast.LENGTH_LONG).show(); } }); } } mlterm-3.9.3/android/src/mlterm/native_activity/MLPreferenceActivity.java000066400000000000000000000135711441203364000266320ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ package mlterm.native_activity; import android.preference.PreferenceActivity; import android.preference.CheckBoxPreference; import android.preference.EditTextPreference; import android.preference.ListPreference; import android.preference.Preference; import android.preference.Preference.OnPreferenceChangeListener; import android.preference.PreferenceScreen; import android.preference.PreferenceCategory; import android.os.Bundle; import android.text.InputType; import android.widget.TextView; public class MLPreferenceActivity extends PreferenceActivity { private native void setConfig(String key, String val); private native void setDefaultFontConfig(String font); private native boolean getBoolConfig(String key); private native String getStrConfig(String key); private native String getDefaultFontConfig(); private void addCheckBox(PreferenceCategory category, final String key, String title) { CheckBoxPreference checkbox = new CheckBoxPreference(this); checkbox.setTitle(title); checkbox.setPersistent(false); checkbox.setChecked(getBoolConfig(key)); checkbox.setOnPreferenceChangeListener(new OnPreferenceChangeListener() { @Override public boolean onPreferenceChange(Preference preference, Object newValue) { boolean checked = (Boolean)newValue; if (checked) { setConfig(key, "true"); } else { setConfig(key, "false"); } return true; } }); category.addPreference(checkbox); } private void addEditText(PreferenceCategory category, final String key, String title, int type) { EditTextPreference edit = new EditTextPreference(this); edit.setTitle(title); edit.setPersistent(false); edit.getEditText().setInputType(type); edit.setSummary(getStrConfig(key)); edit.setOnPreferenceChangeListener(new OnPreferenceChangeListener() { @Override public boolean onPreferenceChange(Preference preference, Object newValue) { setConfig(key, newValue.toString()); ((EditTextPreference)preference).setSummary(getStrConfig(key)); return true; } }); category.addPreference(edit); } private void addFontEditText(PreferenceCategory category) { EditTextPreference edit = new EditTextPreference(this); edit.setTitle("Font path"); edit.setPersistent(false); edit.getEditText().setInputType(InputType.TYPE_CLASS_TEXT); edit.setSummary(getDefaultFontConfig()); edit.setOnPreferenceChangeListener(new OnPreferenceChangeListener() { @Override public boolean onPreferenceChange(Preference preference, Object newValue) { setDefaultFontConfig(newValue.toString()); ((EditTextPreference)preference).setSummary(getDefaultFontConfig()); return true; } }); category.addPreference(edit); } private void addList(PreferenceCategory category, final String key, String title, CharSequence[] entries) { ListPreference list = new ListPreference(this); String value = getStrConfig(key); list.setTitle(title); list.setPersistent(false); list.setEntries(entries); list.setEntryValues(entries); list.setSummary(value); int index = 0; if (value != null) { while (true) { if (value.contentEquals(entries[index])) { break; } else if (++index >= entries.length) { index = 0; break; } } } list.setValueIndex(index); list.setOnPreferenceChangeListener(new OnPreferenceChangeListener() { @Override public boolean onPreferenceChange(Preference preference, Object newValue) { setConfig(key, newValue.toString()); ((ListPreference)preference).setSummary(getStrConfig(key)); return true; } }); category.addPreference(list); } @Override public void onCreate(Bundle state) { super.onCreate(state); PreferenceScreen screen = getPreferenceManager().createPreferenceScreen(this); setPreferenceScreen(screen); PreferenceCategory category = new PreferenceCategory(this); screen.addPreference(category); addCheckBox(category, "start_with_local_pty", "Don't show SSH dialog on startup"); addEditText(category, "fontsize", "Font size", InputType.TYPE_CLASS_NUMBER); addFontEditText(category); addEditText(category, "encoding", "Encoding", InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD); addCheckBox(category, "col_size_of_width_a", "Ambiguouswidth = fullwidth"); addEditText(category, "line_space", "Line space", InputType.TYPE_CLASS_NUMBER); addEditText(category, "letter_space", "Character space", InputType.TYPE_CLASS_NUMBER); addEditText(category, "fg_color", "Foreground Color", InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD); addEditText(category, "bg_color", "Background Color", InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD); addEditText(category, "wall_picture", "Wall picture", InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_VARIATION_URI); addEditText(category, "alpha", "Alpha", InputType.TYPE_CLASS_NUMBER); CharSequence[] entries1 = { "right", "left", "none", "autohide" }; addList(category, "scrollbar_mode", "Scrollbar", entries1); /* TYPE_TEXT_VARIATION_VISIBLE_PASSWORD is for "unlimited" */ addEditText(category, "logsize", "Backlog size", /* InputType.TYPE_CLASS_NUMBER */ InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD); CharSequence[] entries2 = { "none", "cjk", "mongol" }; addList(category, "vertical_mode", "Vertical mode", entries2); addEditText(category, "screen_width_ratio", "Screen size ratio against font size", InputType.TYPE_CLASS_NUMBER); } } mlterm-3.9.3/baselib/000077500000000000000000000000001441203364000144245ustar00rootroot00000000000000mlterm-3.9.3/baselib/Makefile.in000066400000000000000000000002211441203364000164640ustar00rootroot00000000000000all .DEFAULT: cd src ; $(MAKE) $@ distclean : clean rm -f Makefile config.log config.cache config.status libtool src/Makefile src/bl_config.h mlterm-3.9.3/baselib/aclocal.m4000066400000000000000000012112321441203364000162660ustar00rootroot00000000000000# generated automatically by aclocal 1.16.5 -*- Autoconf -*- # Copyright (C) 1996-2021 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # # Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software # Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. m4_define([_LT_COPYING], [dnl # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . ]) # serial 59 LT_INIT # LT_PREREQ(VERSION) # ------------------ # Complain and exit if this libtool version is less that VERSION. m4_defun([LT_PREREQ], [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, [m4_default([$3], [m4_fatal([Libtool version $1 or higher is required], 63)])], [$2])]) # _LT_CHECK_BUILDDIR # ------------------ # Complain if the absolute build directory name contains unusual characters m4_defun([_LT_CHECK_BUILDDIR], [case `pwd` in *\ * | *\ *) AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; esac ]) # LT_INIT([OPTIONS]) # ------------------ AC_DEFUN([LT_INIT], [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl AC_BEFORE([$0], [LTDL_INIT])dnl m4_require([_LT_CHECK_BUILDDIR])dnl dnl Autoconf doesn't catch unexpanded LT_ macros by default: m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 dnl unless we require an AC_DEFUNed macro: AC_REQUIRE([LTOPTIONS_VERSION])dnl AC_REQUIRE([LTSUGAR_VERSION])dnl AC_REQUIRE([LTVERSION_VERSION])dnl AC_REQUIRE([LTOBSOLETE_VERSION])dnl m4_require([_LT_PROG_LTMAIN])dnl _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) dnl Parse OPTIONS _LT_SET_OPTIONS([$0], [$1]) # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' AC_SUBST(LIBTOOL)dnl _LT_SETUP # Only expand once: m4_define([LT_INIT]) ])# LT_INIT # Old names: AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PROG_LIBTOOL], []) dnl AC_DEFUN([AM_PROG_LIBTOOL], []) # _LT_PREPARE_CC_BASENAME # ----------------------- m4_defun([_LT_PREPARE_CC_BASENAME], [ # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in @S|@*""; do case $cc_temp in compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } ])# _LT_PREPARE_CC_BASENAME # _LT_CC_BASENAME(CC) # ------------------- # It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, # but that macro is also expanded into generated libtool script, which # arranges for $SED and $ECHO to be set by different means. m4_defun([_LT_CC_BASENAME], [m4_require([_LT_PREPARE_CC_BASENAME])dnl AC_REQUIRE([_LT_DECL_SED])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl func_cc_basename $1 cc_basename=$func_cc_basename_result ]) # _LT_FILEUTILS_DEFAULTS # ---------------------- # It is okay to use these file commands and assume they have been set # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. m4_defun([_LT_FILEUTILS_DEFAULTS], [: ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} ])# _LT_FILEUTILS_DEFAULTS # _LT_SETUP # --------- m4_defun([_LT_SETUP], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl dnl _LT_DECL([], [host_alias], [0], [The host system])dnl _LT_DECL([], [host], [0])dnl _LT_DECL([], [host_os], [0])dnl dnl _LT_DECL([], [build_alias], [0], [The build system])dnl _LT_DECL([], [build], [0])dnl _LT_DECL([], [build_os], [0])dnl dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl dnl AC_REQUIRE([AC_PROG_LN_S])dnl test -z "$LN_S" && LN_S="ln -s" _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl dnl AC_REQUIRE([LT_CMD_MAX_LEN])dnl _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl m4_require([_LT_CMD_RELOAD])dnl m4_require([_LT_DECL_FILECMD])dnl m4_require([_LT_CHECK_MAGIC_METHOD])dnl m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_WITH_SYSROOT])dnl m4_require([_LT_CMD_TRUNCATE])dnl _LT_CONFIG_LIBTOOL_INIT([ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi ]) if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi _LT_CHECK_OBJDIR m4_require([_LT_TAG_COMPILER])dnl case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC and # ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o _LT_CC_BASENAME([$compiler]) # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then _LT_PATH_MAGIC fi ;; esac # Use C for the default configuration in the libtool script LT_SUPPORTED_TAG([CC]) _LT_LANG_C_CONFIG _LT_LANG_DEFAULT_CONFIG _LT_CONFIG_COMMANDS ])# _LT_SETUP # _LT_PREPARE_SED_QUOTE_VARS # -------------------------- # Define a few sed substitution that help us do robust quoting. m4_defun([_LT_PREPARE_SED_QUOTE_VARS], [# Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\([["`\\]]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ]) # _LT_PROG_LTMAIN # --------------- # Note that this code is called both from 'configure', and 'config.status' # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, # 'config.status' has no value for ac_aux_dir unless we are using Automake, # so we pass a copy along to make sure it has a sensible value anyway. m4_defun([_LT_PROG_LTMAIN], [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) ltmain=$ac_aux_dir/ltmain.sh ])# _LT_PROG_LTMAIN # So that we can recreate a full libtool script including additional # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS # in macros and then make a single call at the end using the 'libtool' # label. # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) # ---------------------------------------- # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL_INIT], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_INIT], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_INIT]) # _LT_CONFIG_LIBTOOL([COMMANDS]) # ------------------------------ # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) # ----------------------------------------------------- m4_defun([_LT_CONFIG_SAVE_COMMANDS], [_LT_CONFIG_LIBTOOL([$1]) _LT_CONFIG_LIBTOOL_INIT([$2]) ]) # _LT_FORMAT_COMMENT([COMMENT]) # ----------------------------- # Add leading comment marks to the start of each line, and a trailing # full-stop to the whole comment if one is not present already. m4_define([_LT_FORMAT_COMMENT], [m4_ifval([$1], [ m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) )]) # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) # ------------------------------------------------------------------- # CONFIGNAME is the name given to the value in the libtool script. # VARNAME is the (base) name used in the configure script. # VALUE may be 0, 1 or 2 for a computed quote escaped value based on # VARNAME. Any other value will be used directly. m4_define([_LT_DECL], [lt_if_append_uniq([lt_decl_varnames], [$2], [, ], [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], [m4_ifval([$1], [$1], [$2])]) lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) m4_ifval([$4], [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) lt_dict_add_subkey([lt_decl_dict], [$2], [tagged?], [m4_ifval([$5], [yes], [no])])]) ]) # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) # -------------------------------------------------------- m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_tag_varnames], [_lt_decl_filter([tagged?], [yes], $@)]) # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) # --------------------------------------------------------- m4_define([_lt_decl_filter], [m4_case([$#], [0], [m4_fatal([$0: too few arguments: $#])], [1], [m4_fatal([$0: too few arguments: $#: $1])], [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], [lt_dict_filter([lt_decl_dict], $@)])[]dnl ]) # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) # -------------------------------------------------- m4_define([lt_decl_quote_varnames], [_lt_decl_filter([value], [1], $@)]) # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_dquote_varnames], [_lt_decl_filter([value], [2], $@)]) # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_varnames_tagged], [m4_assert([$# <= 2])dnl _$0(m4_quote(m4_default([$1], [[, ]])), m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) m4_define([_lt_decl_varnames_tagged], [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) # lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_all_varnames], [_$0(m4_quote(m4_default([$1], [[, ]])), m4_if([$2], [], m4_quote(lt_decl_varnames), m4_quote(m4_shift($@))))[]dnl ]) m4_define([_lt_decl_all_varnames], [lt_join($@, lt_decl_varnames_tagged([$1], lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl ]) # _LT_CONFIG_STATUS_DECLARE([VARNAME]) # ------------------------------------ # Quote a variable value, and forward it to 'config.status' so that its # declaration there will have the same value as in 'configure'. VARNAME # must have a single quote delimited value for this to work. m4_define([_LT_CONFIG_STATUS_DECLARE], [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) # _LT_CONFIG_STATUS_DECLARATIONS # ------------------------------ # We delimit libtool config variables with single quotes, so when # we write them to config.status, we have to be sure to quote all # embedded single quotes properly. In configure, this macro expands # each variable declared with _LT_DECL (and _LT_TAGDECL) into: # # ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAGS # ---------------- # Output comment and list of tags supported by the script m4_defun([_LT_LIBTOOL_TAGS], [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl available_tags='_LT_TAGS'dnl ]) # _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) # ----------------------------------- # Extract the dictionary values for VARNAME (optionally with TAG) and # expand to a commented shell variable setting: # # # Some comment about what VAR is for. # visible_name=$lt_internal_name m4_define([_LT_LIBTOOL_DECLARE], [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [description])))[]dnl m4_pushdef([_libtool_name], m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), [0], [_libtool_name=[$]$1], [1], [_libtool_name=$lt_[]$1], [2], [_libtool_name=$lt_[]$1], [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl ]) # _LT_LIBTOOL_CONFIG_VARS # ----------------------- # Produce commented declarations of non-tagged libtool config variables # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' # script. Tagged libtool config variables (even for the LIBTOOL CONFIG # section) are produced by _LT_LIBTOOL_TAG_VARS. m4_defun([_LT_LIBTOOL_CONFIG_VARS], [m4_foreach([_lt_var], m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAG_VARS(TAG) # ------------------------- m4_define([_LT_LIBTOOL_TAG_VARS], [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) # _LT_TAGVAR(VARNAME, [TAGNAME]) # ------------------------------ m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) # _LT_CONFIG_COMMANDS # ------------------- # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of # variables for single and double quote escaping we saved from calls # to _LT_DECL, we can put quote escaped variables declarations # into 'config.status', and then the shell code to quote escape them in # for loops in 'config.status'. Finally, any additional code accumulated # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. m4_defun([_LT_CONFIG_COMMANDS], [AC_PROVIDE_IFELSE([LT_OUTPUT], dnl If the libtool generation code has been placed in $CONFIG_LT, dnl instead of duplicating it all over again into config.status, dnl then we will have config.status run $CONFIG_LT later, so it dnl needs to know what name is stored there: [AC_CONFIG_COMMANDS([libtool], [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], dnl If the libtool generation code is destined for config.status, dnl expand the accumulated commands and init code now: [AC_CONFIG_COMMANDS([libtool], [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) ])#_LT_CONFIG_COMMANDS # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], [ # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' _LT_CONFIG_STATUS_DECLARATIONS LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$[]1 _LTECHO_EOF' } # Quote evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_quote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_dquote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done _LT_OUTPUT_LIBTOOL_INIT ]) # _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) # ------------------------------------ # Generate a child script FILE with all initialization necessary to # reuse the environment learned by the parent script, and make the # file executable. If COMMENT is supplied, it is inserted after the # '#!' sequence but before initialization text begins. After this # macro, additional text can be appended to FILE to form the body of # the child script. The macro ends with non-zero status if the # file could not be fully written (such as if the disk is full). m4_ifdef([AS_INIT_GENERATED], [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], [m4_defun([_LT_GENERATED_FILE_INIT], [m4_require([AS_PREPARE])]dnl [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl [lt_write_fail=0 cat >$1 <<_ASEOF || lt_write_fail=1 #! $SHELL # Generated by $as_me. $2 SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$1 <<\_ASEOF || lt_write_fail=1 AS_SHELL_SANITIZE _AS_PREPARE exec AS_MESSAGE_FD>&1 _ASEOF test 0 = "$lt_write_fail" && chmod +x $1[]dnl m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT # --------- # This macro allows early generation of the libtool script (before # AC_OUTPUT is called), incase it is used in configure for compilation # tests. AC_DEFUN([LT_OUTPUT], [: ${CONFIG_LT=./config.lt} AC_MSG_NOTICE([creating $CONFIG_LT]) _LT_GENERATED_FILE_INIT(["$CONFIG_LT"], [# Run this file to recreate a libtool stub with the current configuration.]) cat >>"$CONFIG_LT" <<\_LTEOF lt_cl_silent=false exec AS_MESSAGE_LOG_FD>>config.log { echo AS_BOX([Running $as_me.]) } >&AS_MESSAGE_LOG_FD lt_cl_help="\ '$as_me' creates a local libtool stub from the current configuration, for use in further configure time tests before the real libtool is generated. Usage: $[0] [[OPTIONS]] -h, --help print this help, then exit -V, --version print version number, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files Report bugs to ." lt_cl_version="\ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) configured by $[0], generated by m4_PACKAGE_STRING. Copyright (C) 2011 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation gives unlimited permision to copy, distribute and modify it." while test 0 != $[#] do case $[1] in --version | --v* | -V ) echo "$lt_cl_version"; exit 0 ;; --help | --h* | -h ) echo "$lt_cl_help"; exit 0 ;; --debug | --d* | -d ) debug=: ;; --quiet | --q* | --silent | --s* | -q ) lt_cl_silent=: ;; -*) AC_MSG_ERROR([unrecognized option: $[1] Try '$[0] --help' for more information.]) ;; *) AC_MSG_ERROR([unrecognized argument: $[1] Try '$[0] --help' for more information.]) ;; esac shift done if $lt_cl_silent; then exec AS_MESSAGE_FD>/dev/null fi _LTEOF cat >>"$CONFIG_LT" <<_LTEOF _LT_OUTPUT_LIBTOOL_COMMANDS_INIT _LTEOF cat >>"$CONFIG_LT" <<\_LTEOF AC_MSG_NOTICE([creating $ofile]) _LT_OUTPUT_LIBTOOL_COMMANDS AS_EXIT(0) _LTEOF chmod +x "$CONFIG_LT" # configure is writing to config.log, but config.lt does its own redirection, # appending to config.log, which fails on DOS, as config.log is still kept # open by configure. Here we exec the FD to /dev/null, effectively closing # config.log, so it can be properly (re)opened and appended to by config.lt. lt_cl_success=: test yes = "$silent" && lt_config_lt_args="$lt_config_lt_args --quiet" exec AS_MESSAGE_LOG_FD>/dev/null $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false exec AS_MESSAGE_LOG_FD>>config.log $lt_cl_success || AS_EXIT(1) ])# LT_OUTPUT # _LT_CONFIG(TAG) # --------------- # If TAG is the built-in tag, create an initial libtool script with a # default configuration from the untagged config vars. Otherwise add code # to config.status for appending the configuration named by TAG from the # matching tagged config vars. m4_defun([_LT_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_CONFIG_SAVE_COMMANDS([ m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl m4_if(_LT_TAG, [C], [ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 _LT_COPYING _LT_LIBTOOL_TAGS # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG _LT_LIBTOOL_CONFIG_VARS _LT_LIBTOOL_TAG_VARS # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE _LT_PREPARE_MUNGE_PATH_LIST _LT_PREPARE_CC_BASENAME # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac _LT_PROG_LTMAIN # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ], [cat <<_LT_EOF >> "$ofile" dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded dnl in a comment (ie after a #). # ### BEGIN LIBTOOL TAG CONFIG: $1 _LT_LIBTOOL_TAG_VARS(_LT_TAG) # ### END LIBTOOL TAG CONFIG: $1 _LT_EOF ])dnl /m4_if ], [m4_if([$1], [], [ PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile'], []) ])dnl /_LT_CONFIG_SAVE_COMMANDS ])# _LT_CONFIG # LT_SUPPORTED_TAG(TAG) # --------------------- # Trace this macro to discover what tags are supported by the libtool # --tag option, using: # autoconf --trace 'LT_SUPPORTED_TAG:$1' AC_DEFUN([LT_SUPPORTED_TAG], []) # C support is built-in for now m4_define([_LT_LANG_C_enabled], []) m4_define([_LT_TAGS], []) # LT_LANG(LANG) # ------------- # Enable libtool support for the given language if not already enabled. AC_DEFUN([LT_LANG], [AC_BEFORE([$0], [LT_OUTPUT])dnl m4_case([$1], [C], [_LT_LANG(C)], [C++], [_LT_LANG(CXX)], [Go], [_LT_LANG(GO)], [Java], [_LT_LANG(GCJ)], [Fortran 77], [_LT_LANG(F77)], [Fortran], [_LT_LANG(FC)], [Windows Resource], [_LT_LANG(RC)], [m4_ifdef([_LT_LANG_]$1[_CONFIG], [_LT_LANG($1)], [m4_fatal([$0: unsupported language: "$1"])])])dnl ])# LT_LANG # _LT_LANG(LANGNAME) # ------------------ m4_defun([_LT_LANG], [m4_ifdef([_LT_LANG_]$1[_enabled], [], [LT_SUPPORTED_TAG([$1])dnl m4_append([_LT_TAGS], [$1 ])dnl m4_define([_LT_LANG_]$1[_enabled], [])dnl _LT_LANG_$1_CONFIG($1)])dnl ])# _LT_LANG m4_ifndef([AC_PROG_GO], [ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_GO. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # m4_defun([AC_PROG_GO], [AC_LANG_PUSH(Go)dnl AC_ARG_VAR([GOC], [Go compiler command])dnl AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl _AC_ARG_VAR_LDFLAGS()dnl AC_CHECK_TOOL(GOC, gccgo) if test -z "$GOC"; then if test -n "$ac_tool_prefix"; then AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) fi fi if test -z "$GOC"; then AC_CHECK_PROG(GOC, gccgo, gccgo, false) fi ])#m4_defun ])#m4_ifndef # _LT_LANG_DEFAULT_CONFIG # ----------------------- m4_defun([_LT_LANG_DEFAULT_CONFIG], [AC_PROVIDE_IFELSE([AC_PROG_CXX], [LT_LANG(CXX)], [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) AC_PROVIDE_IFELSE([AC_PROG_F77], [LT_LANG(F77)], [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) AC_PROVIDE_IFELSE([AC_PROG_FC], [LT_LANG(FC)], [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal dnl pulling things in needlessly. AC_PROVIDE_IFELSE([AC_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([LT_PROG_GCJ], [LT_LANG(GCJ)], [m4_ifdef([AC_PROG_GCJ], [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([A][M_PROG_GCJ], [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([LT_PROG_GCJ], [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) AC_PROVIDE_IFELSE([AC_PROG_GO], [LT_LANG(GO)], [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) AC_PROVIDE_IFELSE([LT_PROG_RC], [LT_LANG(RC)], [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) ])# _LT_LANG_DEFAULT_CONFIG # Obsolete macros: AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_CXX], []) dnl AC_DEFUN([AC_LIBTOOL_F77], []) dnl AC_DEFUN([AC_LIBTOOL_FC], []) dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) dnl AC_DEFUN([AC_LIBTOOL_RC], []) # _LT_TAG_COMPILER # ---------------- m4_defun([_LT_TAG_COMPILER], [AC_REQUIRE([AC_PROG_CC])dnl _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC ])# _LT_TAG_COMPILER # _LT_COMPILER_BOILERPLATE # ------------------------ # Check for compiler boilerplate output or warnings with # the simple compiler test code. m4_defun([_LT_COMPILER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ])# _LT_COMPILER_BOILERPLATE # _LT_LINKER_BOILERPLATE # ---------------------- # Check for linker boilerplate output or warnings with # the simple link test code. m4_defun([_LT_LINKER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* ])# _LT_LINKER_BOILERPLATE # _LT_REQUIRED_DARWIN_CHECKS # ------------------------- m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ case $host_os in rhapsody* | darwin*) AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) AC_CHECK_TOOL([LIPO], [lipo], [:]) AC_CHECK_TOOL([OTOOL], [otool], [:]) AC_CHECK_TOOL([OTOOL64], [otool64], [:]) _LT_DECL([], [DSYMUTIL], [1], [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) _LT_DECL([], [NMEDIT], [1], [Tool to change global to local symbols on Mac OS X]) _LT_DECL([], [LIPO], [1], [Tool to manipulate fat objects and archives on Mac OS X]) _LT_DECL([], [OTOOL], [1], [ldd/readelf like tool for Mach-O binaries on Mac OS X]) _LT_DECL([], [OTOOL64], [1], [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], [lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -rf libconftest.dylib* rm -f conftest.* fi]) AC_CACHE_CHECK([for -exported_symbols_list linker flag], [lt_cv_ld_exported_symbols_list], [lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [lt_cv_ld_exported_symbols_list=yes], [lt_cv_ld_exported_symbols_list=no]) LDFLAGS=$save_LDFLAGS ]) AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], [lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM ]) case $host_os in rhapsody* | darwin1.[[012]]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) case $MACOSX_DEPLOYMENT_TARGET,$host in 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; *) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac ]) # _LT_DARWIN_LINKER_FEATURES([TAG]) # --------------------------------- # Checks for linker and compiler features on darwin m4_defun([_LT_DARWIN_LINKER_FEATURES], [ m4_require([_LT_REQUIRED_DARWIN_CHECKS]) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported if test yes = "$lt_cv_ld_force_load"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) else _LT_TAGVAR(whole_archive_flag_spec, $1)='' fi _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" _LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], [ if test yes != "$lt_cv_apple_cc_single_mod"; then _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else _LT_TAGVAR(ld_shlibs, $1)=no fi ]) # _LT_SYS_MODULE_PATH_AIX([TAGNAME]) # ---------------------------------- # Links a minimal program and checks the executable # for the system default hardcoded library path. In most cases, # this is /usr/lib:/lib, but when the MPI compilers are used # the location of the communication and MPI libs are included too. # If we don't find anything, use the default library path according # to the aix ld manual. # Store the results from the different compilers for each TAGNAME. # Allow to override them for all tags through lt_cv_aix_libpath. m4_defun([_LT_SYS_MODULE_PATH_AIX], [m4_require([_LT_DECL_SED])dnl if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ lt_aix_libpath_sed='[ /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }]' _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi],[]) if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib fi ]) aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) fi ])# _LT_SYS_MODULE_PATH_AIX # _LT_SHELL_INIT(ARG) # ------------------- m4_define([_LT_SHELL_INIT], [m4_divert_text([M4SH-INIT], [$1 ])])# _LT_SHELL_INIT # _LT_PROG_ECHO_BACKSLASH # ----------------------- # Find how we can fake an echo command that does not interpret backslash. # In particular, with Autoconf 2.60 or later we add some code to the start # of the generated configure script that will find a shell with a builtin # printf (that we can use as an echo command). m4_defun([_LT_PROG_ECHO_BACKSLASH], [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO AC_MSG_CHECKING([how to print strings]) # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $[]1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "$*" } case $ECHO in printf*) AC_MSG_RESULT([printf]) ;; print*) AC_MSG_RESULT([print -r]) ;; *) AC_MSG_RESULT([cat]) ;; esac m4_ifdef([_AS_DETECT_SUGGESTED], [_AS_DETECT_SUGGESTED([ test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test "X`printf %s $ECHO`" = "X$ECHO" \ || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) ])# _LT_PROG_ECHO_BACKSLASH # _LT_WITH_SYSROOT # ---------------- AC_DEFUN([_LT_WITH_SYSROOT], [m4_require([_LT_DECL_SED])dnl AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], [Search for dependent libraries within DIR (or the compiler's sysroot if not specified).])], [], [with_sysroot=no]) dnl lt_sysroot will always be passed unquoted. We quote it here dnl in case the user passed a directory name. lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) AC_MSG_RESULT([$with_sysroot]) AC_MSG_ERROR([The sysroot must be an absolute path.]) ;; esac AC_MSG_RESULT([${lt_sysroot:-no}]) _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl [dependent libraries, and where our libraries should be installed.])]) # _LT_ENABLE_LOCK # --------------- m4_defun([_LT_ENABLE_LOCK], [AC_ARG_ENABLE([libtool-lock], [AS_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then if test yes = "$lt_cv_prog_gnu_ld"; then case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then emul=elf case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, [AC_LANG_PUSH(C) AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) AC_LANG_POP]) if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock ])# _LT_ENABLE_LOCK # _LT_PROG_AR # ----------- m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} _LT_DECL([], [AR], [1], [The archiver]) # Use ARFLAGS variable as AR's operation code to sync the variable naming with # Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have # higher priority because thats what people were doing historically (setting # ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS # variable obsoleted/removed. test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} lt_ar_flags=$AR_FLAGS _LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) # Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override # by AR_FLAGS because that was never working and AR_FLAGS is about to die. _LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], [Flags to create an archive]) AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [lt_cv_ar_at_file=no AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' AC_TRY_EVAL([lt_ar_try]) if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a AC_TRY_EVAL([lt_ar_try]) if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a ]) ]) if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi _LT_DECL([], [archiver_list_spec], [1], [How to feed a file listing to the archiver]) ])# _LT_PROG_AR # _LT_CMD_OLD_ARCHIVE # ------------------- m4_defun([_LT_CMD_OLD_ARCHIVE], [_LT_PROG_AR AC_CHECK_TOOL(STRIP, strip, :) test -z "$STRIP" && STRIP=: _LT_DECL([], [STRIP], [1], [A symbol stripping program]) AC_CHECK_TOOL(RANLIB, ranlib, :) test -z "$RANLIB" && RANLIB=: _LT_DECL([], [RANLIB], [1], [Commands used to install an old-style archive]) # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac _LT_DECL([], [old_postinstall_cmds], [2]) _LT_DECL([], [old_postuninstall_cmds], [2]) _LT_TAGDECL([], [old_archive_cmds], [2], [Commands used to build an old-style archive]) _LT_DECL([], [lock_old_archive_extraction], [0], [Whether to use a lock for old archive extraction]) ])# _LT_CMD_OLD_ARCHIVE # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------------------- # Check whether the given compiler option works AC_DEFUN([_LT_COMPILER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi fi $RM conftest* ]) if test yes = "[$]$2"; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) fi ])# _LT_COMPILER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------- # Check whether the given linker option works AC_DEFUN([_LT_LINKER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $3" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&AS_MESSAGE_LOG_FD $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi else $2=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS ]) if test yes = "[$]$2"; then m4_if([$4], , :, [$4]) else m4_if([$5], , :, [$5]) fi ])# _LT_LINKER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) # LT_CMD_MAX_LEN #--------------- AC_DEFUN([LT_CMD_MAX_LEN], [AC_REQUIRE([AC_CANONICAL_HOST])dnl # find the maximum length of command line arguments AC_MSG_CHECKING([the maximum length of command line arguments]) AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | msys* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac ]) if test -n "$lt_cv_sys_max_cmd_len"; then AC_MSG_RESULT($lt_cv_sys_max_cmd_len) else AC_MSG_RESULT(none) fi max_cmd_len=$lt_cv_sys_max_cmd_len _LT_DECL([], [max_cmd_len], [0], [What is the maximum length of a command?]) ])# LT_CMD_MAX_LEN # Old name: AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) # _LT_HEADER_DLFCN # ---------------- m4_defun([_LT_HEADER_DLFCN], [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl ])# _LT_HEADER_DLFCN # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) # ---------------------------------------------------------------- m4_defun([_LT_TRY_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes = "$cross_compiling"; then : [$4] else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF [#line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; }] _LT_EOF if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) $1 ;; x$lt_dlneed_uscore) $2 ;; x$lt_dlunknown|x*) $3 ;; esac else : # compilation failed $3 fi fi rm -fr conftest* ])# _LT_TRY_DLOPEN_SELF # LT_SYS_DLOPEN_SELF # ------------------ AC_DEFUN([LT_SYS_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin* | msys*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ]) ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) AC_CHECK_FUNC([shl_load], [lt_cv_dlopen=shl_load], [AC_CHECK_LIB([dld], [shl_load], [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], [AC_CHECK_FUNC([dlopen], [lt_cv_dlopen=dlopen], [AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], [AC_CHECK_LIB([svld], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], [AC_CHECK_LIB([dld], [dld_link], [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) ]) ]) ]) ]) ]) ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" AC_CACHE_CHECK([whether a program can dlopen itself], lt_cv_dlopen_self, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) ]) if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" AC_CACHE_CHECK([whether a statically linked program can dlopen itself], lt_cv_dlopen_self_static, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) ]) fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi _LT_DECL([dlopen_support], [enable_dlopen], [0], [Whether dlopen is supported]) _LT_DECL([dlopen_self], [enable_dlopen_self], [0], [Whether dlopen of programs is supported]) _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], [Whether dlopen of statically linked programs is supported]) ])# LT_SYS_DLOPEN_SELF # Old name: AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) # _LT_COMPILER_C_O([TAGNAME]) # --------------------------- # Check to see if options -c and -o are simultaneously supported by compiler. # This macro does not hard code the compiler like AC_PROG_CC_C_O. m4_defun([_LT_COMPILER_C_O], [m4_require([_LT_DECL_SED])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes fi fi chmod u+w . 2>&AS_MESSAGE_LOG_FD $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* ]) _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], [Does compiler simultaneously support -c and -o options?]) ])# _LT_COMPILER_C_O # _LT_COMPILER_FILE_LOCKS([TAGNAME]) # ---------------------------------- # Check to see if we can do hard links to lock some files if needed m4_defun([_LT_COMPILER_FILE_LOCKS], [m4_require([_LT_ENABLE_LOCK])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_COMPILER_C_O([$1]) hard_links=nottested if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user AC_MSG_CHECKING([if we can lock with hard links]) hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no AC_MSG_RESULT([$hard_links]) if test no = "$hard_links"; then AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) need_locks=warn fi else need_locks=no fi _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) ])# _LT_COMPILER_FILE_LOCKS # _LT_CHECK_OBJDIR # ---------------- m4_defun([_LT_CHECK_OBJDIR], [AC_CACHE_CHECK([for objdir], [lt_cv_objdir], [rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null]) objdir=$lt_cv_objdir _LT_DECL([], [objdir], [0], [The name of the directory that contains temporary libtool files])dnl m4_pattern_allow([LT_OBJDIR])dnl AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", [Define to the sub-directory where libtool stores uninstalled libraries.]) ])# _LT_CHECK_OBJDIR # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) # -------------------------------------- # Check hardcoding attributes. m4_defun([_LT_LINKER_HARDCODE_LIBPATH], [AC_MSG_CHECKING([how to hardcode library paths into programs]) _LT_TAGVAR(hardcode_action, $1)= if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || test -n "$_LT_TAGVAR(runpath_var, $1)" || test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then # We can hardcode non-existent directories. if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then # Linking always hardcodes the temporary library directory. _LT_TAGVAR(hardcode_action, $1)=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. _LT_TAGVAR(hardcode_action, $1)=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. _LT_TAGVAR(hardcode_action, $1)=unsupported fi AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi _LT_TAGDECL([], [hardcode_action], [0], [How to hardcode a shared library path into an executable]) ])# _LT_LINKER_HARDCODE_LIBPATH # _LT_CMD_STRIPLIB # ---------------- m4_defun([_LT_CMD_STRIPLIB], [m4_require([_LT_DECL_EGREP]) striplib= old_striplib= AC_MSG_CHECKING([whether stripping libraries is possible]) if test -z "$STRIP"; then AC_MSG_RESULT([no]) else if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else case $host_os in darwin*) # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) ;; freebsd*) if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) fi ;; *) AC_MSG_RESULT([no]) ;; esac fi fi _LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) _LT_DECL([], [striplib], [1]) ])# _LT_CMD_STRIPLIB # _LT_PREPARE_MUNGE_PATH_LIST # --------------------------- # Make sure func_munge_path_list() is defined correctly. m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], [[# func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x@S|@2 in x) ;; *:) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" ;; x:*) eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; *::*) eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" ;; *) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; esac } ]])# _LT_PREPARE_PATH_LIST # _LT_SYS_DYNAMIC_LINKER([TAG]) # ----------------------------- # PORTME Fill in your ld.so characteristics m4_defun([_LT_SYS_DYNAMIC_LINKER], [AC_REQUIRE([AC_CANONICAL_HOST])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_OBJDUMP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl AC_MSG_CHECKING([dynamic linker characteristics]) m4_if([$1], [], [ if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[[lt_foo]]++; } if (lt_freq[[lt_foo]] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi]) library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown AC_ARG_VAR([LT_SYS_LIBRARY_PATH], [User-defined run-time library search path.]) case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[[4-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[[01]] | aix4.[[01]].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a[(]lib.so.V[)]' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[[45]]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | msys* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; mingw* | cegcc* | msys*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl* | *,icl*) # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin* | msys*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[[23]].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[[01]]* | freebsdelf3.[[01]]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[[3-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], [lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], [lt_cv_shlibpath_overrides_runpath=yes])]) LDFLAGS=$save_LDFLAGS libdir=$save_libdir ]) shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac AC_MSG_RESULT([$dynamic_linker]) test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH _LT_DECL([], [variables_saved_for_relink], [1], [Variables whose values should be saved in libtool wrapper scripts and restored at link time]) _LT_DECL([], [need_lib_prefix], [0], [Do we need the "lib" prefix for modules?]) _LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) _LT_DECL([], [version_type], [0], [Library versioning type]) _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) _LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) _LT_DECL([], [shlibpath_overrides_runpath], [0], [Is shlibpath searched before the hard-coded library search path?]) _LT_DECL([], [libname_spec], [1], [Format of library name prefix]) _LT_DECL([], [library_names_spec], [1], [[List of archive names. First name is the real one, the rest are links. The last name is the one that the linker finds with -lNAME]]) _LT_DECL([], [soname_spec], [1], [[The coded name of the library, if different from the real name]]) _LT_DECL([], [install_override_mode], [1], [Permission mode override for installation of shared libraries]) _LT_DECL([], [postinstall_cmds], [2], [Command to use after installation of a shared archive]) _LT_DECL([], [postuninstall_cmds], [2], [Command to use after uninstallation of a shared archive]) _LT_DECL([], [finish_cmds], [2], [Commands used to finish a libtool library installation in a directory]) _LT_DECL([], [finish_eval], [1], [[As "finish_cmds", except a single script fragment to be evaled but not shown]]) _LT_DECL([], [hardcode_into_libs], [0], [Whether we should hardcode library paths into libraries]) _LT_DECL([], [sys_lib_search_path_spec], [2], [Compile-time system search path for libraries]) _LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], [Detected run-time system search path for libraries]) _LT_DECL([], [configure_time_lt_sys_library_path], [2], [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) ])# _LT_SYS_DYNAMIC_LINKER # _LT_PATH_TOOL_PREFIX(TOOL) # -------------------------- # find a file program that can recognize shared library AC_DEFUN([_LT_PATH_TOOL_PREFIX], [m4_require([_LT_DECL_EGREP])dnl AC_MSG_CHECKING([for $1]) AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, [case $MAGIC_CMD in [[\\/*] | ?:[\\/]*]) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. ac_dummy="m4_if([$2], , $PATH, [$2])" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$1"; then lt_cv_path_MAGIC_CMD=$ac_dir/"$1" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac]) MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then AC_MSG_RESULT($MAGIC_CMD) else AC_MSG_RESULT(no) fi _LT_DECL([], [MAGIC_CMD], [0], [Used to examine libraries when file_magic_cmd begins with "file"])dnl ])# _LT_PATH_TOOL_PREFIX # Old name: AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) # _LT_PATH_MAGIC # -------------- # find a file program that can recognize a shared library m4_defun([_LT_PATH_MAGIC], [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) else MAGIC_CMD=: fi fi ])# _LT_PATH_MAGIC # LT_PATH_LD # ---------- # find the pathname to the GNU or non-GNU linker AC_DEFUN([LT_PATH_LD], [AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PROG_ECHO_BACKSLASH])dnl AC_ARG_WITH([gnu-ld], [AS_HELP_STRING([--with-gnu-ld], [assume the C compiler uses GNU ld @<:@default=no@:>@])], [test no = "$withval" || with_gnu_ld=yes], [with_gnu_ld=no])dnl ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [[\\/]]* | ?:[[\\/]]*) re_direlt='/[[^/]][[^/]]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &1 conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], [if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi]) rm -f conftest.i conftest2.i conftest.out]) ])# _LT_PATH_DD # _LT_CMD_TRUNCATE # ---------------- # find command to truncate a binary pipe m4_defun([_LT_CMD_TRUNCATE], [m4_require([_LT_PATH_DD]) AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], [printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], [Command to truncate a binary pipe]) ])# _LT_CMD_TRUNCATE # _LT_CHECK_MAGIC_METHOD # ---------------------- # how to check for library dependencies # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_MAGIC_METHOD], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) AC_CACHE_CHECK([how to recognize dependent libraries], lt_cv_deplibs_check_method, [lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[[4-9]]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[[45]]*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin* | msys*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[[3-9]]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac ]) file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown _LT_DECL([], [deplibs_check_method], [1], [Method to check whether dependent libraries are shared objects]) _LT_DECL([], [file_magic_cmd], [1], [Command to use when deplibs_check_method = "file_magic"]) _LT_DECL([], [file_magic_glob], [1], [How to find potential files when deplibs_check_method = "file_magic"]) _LT_DECL([], [want_nocaseglob], [1], [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) ])# _LT_CHECK_MAGIC_METHOD # LT_PATH_NM # ---------- # find the pathname to a BSD- or MS-compatible name lister AC_DEFUN([LT_PATH_NM], [AC_REQUIRE([AC_PROG_CC])dnl AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, [if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi]) if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi AC_SUBST([DUMPBIN]) if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm AC_SUBST([NM]) _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], [lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) cat conftest.out >&AS_MESSAGE_LOG_FD if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest*]) ])# LT_PATH_NM # Old names: AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_PROG_NM], []) dnl AC_DEFUN([AC_PROG_NM], []) # _LT_CHECK_SHAREDLIB_FROM_LINKLIB # -------------------------------- # how to determine the name of the shared library # associated with a specific link library. # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) m4_require([_LT_DECL_DLLTOOL]) AC_CACHE_CHECK([how to associate runtime and link libraries], lt_cv_sharedlib_from_linklib_cmd, [lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac ]) sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO _LT_DECL([], [sharedlib_from_linklib_cmd], [1], [Command to associate shared and link libraries]) ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB # _LT_PATH_MANIFEST_TOOL # ---------------------- # locate the manifest tool m4_defun([_LT_PATH_MANIFEST_TOOL], [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], [lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&AS_MESSAGE_LOG_FD if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest*]) if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl ])# _LT_PATH_MANIFEST_TOOL # _LT_DLL_DEF_P([FILE]) # --------------------- # True iff FILE is a Windows DLL '.def' file. # Keep in sync with func_dll_def_p in the libtool script AC_DEFUN([_LT_DLL_DEF_P], [dnl test DEF = "`$SED -n dnl -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl -e q dnl Only consider the first "real" line $1`" dnl ])# _LT_DLL_DEF_P # LT_LIB_M # -------- # check for math library AC_DEFUN([LT_LIB_M], [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= case $host in *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-msys* | *-*-haiku* | *-*-pw32* | *-*-darwin*) # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") ;; *) AC_CHECK_LIB(m, cos, LIBM=-lm) ;; esac AC_SUBST([LIBM]) ])# LT_LIB_M # Old name: AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_CHECK_LIBM], []) # _LT_COMPILER_NO_RTTI([TAGNAME]) # ------------------------------- m4_defun([_LT_COMPILER_NO_RTTI], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= if test yes = "$GCC"; then case $cc_basename in nvcc*) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; *) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; esac _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], lt_cv_prog_compiler_rtti_exceptions, [-fno-rtti -fno-exceptions], [], [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) fi _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], [Compiler flag to turn off builtin functions]) ])# _LT_COMPILER_NO_RTTI # _LT_CMD_GLOBAL_SYMBOLS # ---------------------- m4_defun([_LT_CMD_GLOBAL_SYMBOLS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([LT_PATH_NM])dnl AC_REQUIRE([LT_PATH_LD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_TAG_COMPILER])dnl # Check for command to grab the raw symbol name followed by C symbol from nm. AC_MSG_CHECKING([command to parse $NM output from $compiler object]) AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], [ # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[[BCDEGRST]]' # Regexp to match symbols that can be accessed directly from C. sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[[BCDT]]' ;; cygwin* | msys* | mingw* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[[ABCDEGRST]]' fi ;; irix* | nonstopux*) symcode='[[BCDEGRST]]' ;; osf*) symcode='[[BCDEGQRST]]' ;; solaris*) symcode='[[BDRT]]' ;; sco3.2v5*) symcode='[[DT]]' ;; sysv4.2uw2*) symcode='[[DT]]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[[ABDT]]' ;; sysv4) symcode='[[DFNSTU]]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[[ABCDGIRSTW]]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT@&t@_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT@&t@_DLSYM_CONST #else # define LT@&t@_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT@&t@_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[[]] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD fi else echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done ]) if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then AC_MSG_RESULT(failed) else AC_MSG_RESULT(ok) fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then nm_file_list_spec='@' fi _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], [Take the output of nm and produce a listing of raw symbols and C names]) _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], [Transform the output of nm in a proper C declaration]) _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], [Transform the output of nm into a list of symbols to manually relocate]) _LT_DECL([global_symbol_to_c_name_address], [lt_cv_sys_global_symbol_to_c_name_address], [1], [Transform the output of nm in a C name address pair]) _LT_DECL([global_symbol_to_c_name_address_lib_prefix], [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], [Transform the output of nm in a C name address pair when lib prefix is needed]) _LT_DECL([nm_interface], [lt_cv_nm_interface], [1], [The name lister interface]) _LT_DECL([], [nm_file_list_spec], [1], [Specify filename containing input files for $NM]) ]) # _LT_CMD_GLOBAL_SYMBOLS # _LT_COMPILER_PIC([TAGNAME]) # --------------------------- m4_defun([_LT_COMPILER_PIC], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_wl, $1)= _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)= m4_if([$1], [CXX], [ # C++ specific cases for pic, static, wl, etc. if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | msys* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac else case $host_os in aix[[4-9]]*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; mingw* | cygwin* | msys* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) ;; dgux*) case $cc_basename in ec++*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; ghcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' if test ia64 != "$host_cpu"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' fi ;; aCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; ecpc* ) # old Intel C++ for x86_64, which still supported -KPIC. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; icpc* ) # Intel C++, used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL 8.0, 9.0 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' ;; *) ;; esac ;; netbsd*) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; cxx*) # Digital/Compaq C++ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; lcc*) # Lucid _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; *) ;; esac ;; vxworks*) ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ], [ if test yes = "$GCC"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC (with -KPIC) is the default. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # Lahey Fortran 8.1. lf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' ;; nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; ccc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All Alpha code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='' ;; *Sun\ F* | *Sun*Fortran*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; *Intel*\ [[CF]]*Compiler*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; *Portland\ Group*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; esac ;; newsos6) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All OSF/1 code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; rdos*) _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; solaris*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; *) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; esac ;; sunos4*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; unicos*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; uts4*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ]) case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" ;; esac AC_CACHE_CHECK([for $compiler option to produce PIC], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) # # Check to make sure the PIC flag actually works. # if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in "" | " "*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; esac], [_LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) fi _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], [Additional compiler flags for building library objects]) _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], [How to pass a linker flag through the compiler]) # # Check to make sure the static flag actually works. # wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), $lt_tmp_static_flag, [], [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], [Compiler flag to prevent dynamic linking]) ])# _LT_COMPILER_PIC # _LT_LINKER_SHLIBS([TAGNAME]) # ---------------------------- # See if the linker supports building shared libraries. m4_defun([_LT_LINKER_SHLIBS], [AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) m4_if([$1], [CXX], [ _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] case $host_os in aix[[4-9]]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds ;; cygwin* | msys* | mingw* | cegcc*) case $cc_basename in cl* | icl*) _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] ;; esac ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac ], [ runpath_var= _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_cmds, $1)= _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(old_archive_from_new_cmds, $1)= _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= _LT_TAGVAR(thread_safe_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list _LT_TAGVAR(include_expsyms, $1)= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. dnl Note also adjust exclude_expsyms for C++ above. extract_expsyms_cmds= case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[[3-9]]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 _LT_TAGVAR(whole_archive_flag_spec, $1)= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; sunos4*) _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then runpath_var= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. _LT_TAGVAR(hardcode_minus_L, $1)=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_TAGVAR(hardcode_direct, $1)=unsupported fi ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; bsdi[[45]]*) _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl* | icl*) # Native MSVC or ICC _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC and ICC wrapper _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' # FIXME: Should let the user specify the lib program. _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; dgux*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly* | midnightbsd*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; hpux9*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) m4_if($1, [], [ # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) _LT_LINKER_OPTION([if $CC understands -b], _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) ;; esac fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], [lt_cv_irix_exported_symbol], [save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" AC_LINK_IFELSE( [AC_LANG_SOURCE( [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], [C++], [[int foo (void) { return 0; }]], [Fortran 77], [[ subroutine foo end]], [Fortran], [[ subroutine foo end]])])], [lt_cv_irix_exported_symbol=yes], [lt_cv_irix_exported_symbol=no]) LDFLAGS=$save_LDFLAGS]) if test yes = "$lt_cv_irix_exported_symbol"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes _LT_TAGVAR(link_all_deplibs, $1)=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(ld_shlibs, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; newsos6) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' fi else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; osf3*) if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' if test yes = "$GCC"; then wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' fi ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4) case $host_vendor in sni) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' _LT_TAGVAR(hardcode_direct, $1)=no ;; motorola) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4.3*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes _LT_TAGVAR(ld_shlibs, $1)=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(ld_shlibs, $1)=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' ;; esac fi fi ]) AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl _LT_DECL([], [extract_expsyms_cmds], [2], [The commands to extract the exported symbol list from a shared archive]) # # Do we need to explicitly link libc? # case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in x|xyes) # Assume -lc should be added _LT_TAGVAR(archive_cmds_need_lc, $1)=yes if test yes,yes = "$GCC,$enable_shared"; then case $_LT_TAGVAR(archive_cmds, $1) in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. AC_CACHE_CHECK([whether -lc should be explicitly linked in], [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), [$RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if AC_TRY_EVAL(ac_compile) 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) _LT_TAGVAR(allow_undefined_flag, $1)= if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) then lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no else lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes fi _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* ]) _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) ;; esac fi ;; esac _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], [Whether or not to add -lc for building shared libraries]) _LT_TAGDECL([allow_libtool_libs_with_static_runtimes], [enable_shared_with_static_runtimes], [0], [Whether or not to disallow shared libs when runtime libs are static]) _LT_TAGDECL([], [export_dynamic_flag_spec], [1], [Compiler flag to allow reflexive dlopens]) _LT_TAGDECL([], [whole_archive_flag_spec], [1], [Compiler flag to generate shared objects directly from archives]) _LT_TAGDECL([], [compiler_needs_object], [1], [Whether the compiler copes with passing no objects directly]) _LT_TAGDECL([], [old_archive_from_new_cmds], [2], [Create an old-style archive from a shared archive]) _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], [Create a temporary old-style archive to link instead of a shared archive]) _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) _LT_TAGDECL([], [archive_expsym_cmds], [2]) _LT_TAGDECL([], [module_cmds], [2], [Commands used to build a loadable module if different from building a shared archive.]) _LT_TAGDECL([], [module_expsym_cmds], [2]) _LT_TAGDECL([], [with_gnu_ld], [1], [Whether we are building with GNU ld or not]) _LT_TAGDECL([], [allow_undefined_flag], [1], [Flag that allows shared libraries with undefined symbols to be built]) _LT_TAGDECL([], [no_undefined_flag], [1], [Flag that enforces no undefined symbols]) _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], [Flag to hardcode $libdir into a binary during linking. This must work even if $libdir does not exist]) _LT_TAGDECL([], [hardcode_libdir_separator], [1], [Whether we need a single "-rpath" flag with a separated argument]) _LT_TAGDECL([], [hardcode_direct], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_direct_absolute], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary and the resulting library dependency is "absolute", i.e impossible to change by setting $shlibpath_var if the library is relocated]) _LT_TAGDECL([], [hardcode_minus_L], [0], [Set to "yes" if using the -LDIR flag during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_shlibpath_var], [0], [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_automatic], [0], [Set to "yes" if building a shared library automatically hardcodes DIR into the library and all subsequent libraries and executables linked against it]) _LT_TAGDECL([], [inherit_rpath], [0], [Set to yes if linker adds runtime paths of dependent libraries to runtime path list]) _LT_TAGDECL([], [link_all_deplibs], [0], [Whether libtool must link a program against all its dependency libraries]) _LT_TAGDECL([], [always_export_symbols], [0], [Set to "yes" if exported symbols are required]) _LT_TAGDECL([], [export_symbols_cmds], [2], [The commands to list exported symbols]) _LT_TAGDECL([], [exclude_expsyms], [1], [Symbols that should not be listed in the preloaded symbols]) _LT_TAGDECL([], [include_expsyms], [1], [Symbols that must always be exported]) _LT_TAGDECL([], [prelink_cmds], [2], [Commands necessary for linking programs (against libraries) with templates]) _LT_TAGDECL([], [postlink_cmds], [2], [Commands necessary for finishing linking programs]) _LT_TAGDECL([], [file_list_spec], [1], [Specify filename containing input files]) dnl FIXME: Not yet implemented dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], dnl [Compiler flag to generate thread safe objects]) ])# _LT_LINKER_SHLIBS # _LT_LANG_C_CONFIG([TAG]) # ------------------------ # Ensure that the configuration variables for a C compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_C_CONFIG], [m4_require([_LT_DECL_EGREP])dnl lt_save_CC=$CC AC_LANG_PUSH(C) # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' _LT_TAG_COMPILER # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) LT_SYS_DLOPEN_SELF _LT_CMD_STRIPLIB # Report what library types will actually be built AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_CONFIG($1) fi AC_LANG_POP CC=$lt_save_CC ])# _LT_LANG_C_CONFIG # _LT_LANG_CXX_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a C++ compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_CXX_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl if test -n "$CXX" && ( test no != "$CXX" && ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || (test g++ != "$CXX"))); then AC_PROG_CXXCPP else _lt_caught_CXX_error=yes fi AC_LANG_PUSH(C++) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} CFLAGS=$CXXFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi if test yes = "$GXX"; then # Set up default GNU C++ configuration LT_PATH_LD # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test yes = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) _LT_TAGVAR(ld_shlibs, $1)=yes case $host_os in aix3*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GXX"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag=$shared_flag' $wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. # The "-G" linker flag allows undefined symbols. _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; cygwin* | msys* | mingw* | pw32* | cegcc*) case $GXX,$cc_basename in ,cl* | no,cl* | ,icl* | no,icl*) # Native MSVC or ICC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ func_to_tool_file "$lt_outputfile"~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; freebsd2.*) # C++ shared libraries reported to be fairly broken before # switch to ELF _LT_TAGVAR(ld_shlibs, $1)=no ;; freebsd-elf*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_TAGVAR(ld_shlibs, $1)=yes ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; hpux9*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; hpux10*|hpux11*) if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) ;; *) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi _LT_TAGVAR(link_all_deplibs, $1)=yes ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc* | ecpc* ) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ $RANLIB $oldlib' _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; m88k*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; *nto* | *qnx*) _LT_TAGVAR(ld_shlibs, $1)=yes ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using # the KAI C++ compiler. case $host in osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; esac ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; cxx*) case $host in osf3*) _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; *) _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ $RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' ;; esac _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' case $host in osf3*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ '"$_LT_TAGVAR(old_archive_cmds, $1)" _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ '"$_LT_TAGVAR(reload_cmds, $1)" ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(GCC, $1)=$GXX _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld fi # test yes != "$_lt_caught_CXX_error" AC_LANG_POP ])# _LT_LANG_CXX_CONFIG # _LT_FUNC_STRIPNAME_CNF # ---------------------- # func_stripname_cnf prefix suffix name # strip PREFIX and SUFFIX off of NAME. # PREFIX and SUFFIX must not contain globbing or regex special # characters, hashes, percent signs, but SUFFIX may contain a leading # dot (in which case that matches only a dot). # # This function is identical to the (non-XSI) version of func_stripname, # except this one can be used by m4 code that may be executed by configure, # rather than the libtool script. m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl AC_REQUIRE([_LT_DECL_SED]) AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) func_stripname_cnf () { case @S|@2 in .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; esac } # func_stripname_cnf ])# _LT_FUNC_STRIPNAME_CNF # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose # compiler output when linking a shared library. # Parse the compiler output and extract the necessary # objects, libraries and library flags. m4_defun([_LT_SYS_HIDDEN_LIBDEPS], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl # Dependencies to place before and after the object being linked: _LT_TAGVAR(predep_objects, $1)= _LT_TAGVAR(postdep_objects, $1)= _LT_TAGVAR(predeps, $1)= _LT_TAGVAR(postdeps, $1)= _LT_TAGVAR(compiler_lib_search_path, $1)= dnl we can't use the lt_simple_compile_test_code here, dnl because it contains code intended for an executable, dnl not a library. It's possible we should let each dnl tag define a new lt_????_link_test_code variable, dnl but it's only used here... m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF int a; void foo (void) { a = 0; } _LT_EOF ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF class Foo { public: Foo (void) { a = 0; } private: int a; }; _LT_EOF ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer*4 a a=0 return end _LT_EOF ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer a a=0 return end _LT_EOF ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF public class foo { private int a; public void bar (void) { a = 0; } }; _LT_EOF ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF package foo func foo() { } _LT_EOF ]) _lt_libdeps_save_CFLAGS=$CFLAGS case "$CC $CFLAGS " in #( *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; esac dnl Parse the compiler output and extract the necessary dnl objects, libraries and library flags. if AC_TRY_EVAL(ac_compile); then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test x-L = "$p" || test x-R = "$p"; then prev=$p continue fi # Expand the sysroot to ease extracting the directories later. if test -z "$prev"; then case $p in -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; esac fi case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac if test no = "$pre_test_object_deps_done"; then case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p else _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$_LT_TAGVAR(postdeps, $1)"; then _LT_TAGVAR(postdeps, $1)=$prev$p else _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" fi fi prev= ;; *.lto.$objext) ;; # Ignore GCC LTO objects *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test no = "$pre_test_object_deps_done"; then if test -z "$_LT_TAGVAR(predep_objects, $1)"; then _LT_TAGVAR(predep_objects, $1)=$p else _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" fi else if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then _LT_TAGVAR(postdep_objects, $1)=$p else _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling $1 test program" fi $RM -f confest.$objext CFLAGS=$_lt_libdeps_save_CFLAGS # PORTME: override above test on systems where it is broken m4_if([$1], [CXX], [case $host_os in interix[[3-9]]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. _LT_TAGVAR(predep_objects,$1)= _LT_TAGVAR(postdep_objects,$1)= _LT_TAGVAR(postdeps,$1)= ;; esac ]) case " $_LT_TAGVAR(postdeps, $1) " in *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; esac _LT_TAGVAR(compiler_lib_search_dirs, $1)= if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi _LT_TAGDECL([], [compiler_lib_search_dirs], [1], [The directories searched by this compiler when creating a shared library]) _LT_TAGDECL([], [predep_objects], [1], [Dependencies to place before and after the objects being linked to create a shared library]) _LT_TAGDECL([], [postdep_objects], [1]) _LT_TAGDECL([], [predeps], [1]) _LT_TAGDECL([], [postdeps], [1]) _LT_TAGDECL([], [compiler_lib_search_path], [1], [The library search path used internally by the compiler when linking a shared library]) ])# _LT_SYS_HIDDEN_LIBDEPS # _LT_LANG_F77_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a Fortran 77 compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_F77_CONFIG], [AC_LANG_PUSH(Fortran 77) if test -z "$F77" || test no = "$F77"; then _lt_disable_F77=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for f77 test sources. ac_ext=f # Object file extension for compiled f77 test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the F77 compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_F77"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${F77-"f77"} CFLAGS=$FFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) GCC=$G77 if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$G77 _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_F77" AC_LANG_POP ])# _LT_LANG_F77_CONFIG # _LT_LANG_FC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for a Fortran compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_FC_CONFIG], [AC_LANG_PUSH(Fortran) if test -z "$FC" || test no = "$FC"; then _lt_disable_FC=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for fc test sources. ac_ext=${ac_fc_srcext-f} # Object file extension for compiled fc test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the FC compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_FC"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${FC-"f95"} CFLAGS=$FCFLAGS compiler=$CC GCC=$ac_cv_fc_compiler_gnu _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_FC" AC_LANG_POP ])# _LT_LANG_FC_CONFIG # _LT_LANG_GCJ_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Java Compiler compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GCJ_CONFIG], [AC_REQUIRE([LT_PROG_GCJ])dnl AC_LANG_SAVE # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GCJ-"gcj"} CFLAGS=$GCJFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # GCJ did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GCJ_CONFIG # _LT_LANG_GO_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Go compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GO_CONFIG], [AC_REQUIRE([LT_PROG_GO])dnl AC_LANG_SAVE # Source file extension for Go test sources. ac_ext=go # Object file extension for compiled Go test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="package main; func main() { }" # Code to be used in simple link tests lt_simple_link_test_code='package main; func main() { }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GOC-"gccgo"} CFLAGS=$GOFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # Go did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GO_CONFIG # _LT_LANG_RC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for the Windows resource compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_RC_CONFIG], [AC_REQUIRE([LT_PROG_RC])dnl AC_LANG_SAVE # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests lt_simple_link_test_code=$lt_simple_compile_test_code # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC= CC=${RC-"windres"} CFLAGS= compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes if test -n "$compiler"; then : _LT_CONFIG($1) fi GCC=$lt_save_GCC AC_LANG_RESTORE CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_RC_CONFIG # LT_PROG_GCJ # ----------- AC_DEFUN([LT_PROG_GCJ], [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], [AC_CHECK_TOOL(GCJ, gcj,) test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" AC_SUBST(GCJFLAGS)])])[]dnl ]) # Old name: AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_GCJ], []) # LT_PROG_GO # ---------- AC_DEFUN([LT_PROG_GO], [AC_CHECK_TOOL(GOC, gccgo,) ]) # LT_PROG_RC # ---------- AC_DEFUN([LT_PROG_RC], [AC_CHECK_TOOL(RC, windres,) ]) # Old name: AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_RC], []) # _LT_DECL_EGREP # -------------- # If we don't have a new enough Autoconf to choose the best grep # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_EGREP], [AC_REQUIRE([AC_PROG_EGREP])dnl AC_REQUIRE([AC_PROG_FGREP])dnl test -z "$GREP" && GREP=grep _LT_DECL([], [GREP], [1], [A grep program that handles long lines]) _LT_DECL([], [EGREP], [1], [An ERE matcher]) _LT_DECL([], [FGREP], [1], [A literal string matcher]) dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too AC_SUBST([GREP]) ]) # _LT_DECL_OBJDUMP # -------------- # If we don't have a new enough Autoconf to choose the best objdump # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_OBJDUMP], [AC_CHECK_TOOL(OBJDUMP, objdump, false) test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) AC_SUBST([OBJDUMP]) ]) # _LT_DECL_DLLTOOL # ---------------- # Ensure DLLTOOL variable is set. m4_defun([_LT_DECL_DLLTOOL], [AC_CHECK_TOOL(DLLTOOL, dlltool, false) test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program]) AC_SUBST([DLLTOOL]) ]) # _LT_DECL_FILECMD # ---------------- # Check for a file(cmd) program that can be used to detect file type and magic m4_defun([_LT_DECL_FILECMD], [AC_CHECK_TOOL([FILECMD], [file], [:]) _LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) ])# _LD_DECL_FILECMD # _LT_DECL_SED # ------------ # Check for a fully-functional sed program, that truncates # as few characters as possible. Prefer GNU sed if found. m4_defun([_LT_DECL_SED], [AC_PROG_SED test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" _LT_DECL([], [SED], [1], [A sed program that does not truncate output]) _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], [Sed that helps us avoid accidentally triggering echo(1) options like -n]) ])# _LT_DECL_SED m4_ifndef([AC_PROG_SED], [ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_SED. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # m4_defun([AC_PROG_SED], [AC_MSG_CHECKING([for a sed that does not truncate output]) AC_CACHE_VAL(lt_cv_path_SED, [# Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" fi done done done IFS=$as_save_IFS lt_ac_max=0 lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do test ! -f "$lt_ac_sed" && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in # Check for GNU sed and select it if it is found. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then lt_cv_path_SED=$lt_ac_sed break fi while true; do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo >>conftest.nl $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough test 10 -lt "$lt_ac_count" && break lt_ac_count=`expr $lt_ac_count + 1` if test "$lt_ac_count" -gt "$lt_ac_max"; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi done done ]) SED=$lt_cv_path_SED AC_SUBST([SED]) AC_MSG_RESULT([$SED]) ])#AC_PROG_SED ])#m4_ifndef # Old name: AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_SED], []) # _LT_CHECK_SHELL_FEATURES # ------------------------ # Find out whether the shell is Bourne or XSI compatible, # or has some other useful features. m4_defun([_LT_CHECK_SHELL_FEATURES], [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl ])# _LT_CHECK_SHELL_FEATURES # _LT_PATH_CONVERSION_FUNCTIONS # ----------------------------- # Determine what file name conversion functions should be used by # func_to_host_file (and, implicitly, by func_to_host_path). These are needed # for certain cross-compile configurations and native mingw. m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_MSG_CHECKING([how to convert $build file names to $host format]) AC_CACHE_VAL(lt_cv_to_host_file_cmd, [case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac ]) to_host_file_cmd=$lt_cv_to_host_file_cmd AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], [0], [convert $build file names to $host format])dnl AC_MSG_CHECKING([how to convert $build file names to toolchain format]) AC_CACHE_VAL(lt_cv_to_tool_file_cmd, [#assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac ]) to_tool_file_cmd=$lt_cv_to_tool_file_cmd AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], [0], [convert $build files to toolchain format])dnl ])# _LT_PATH_CONVERSION_FUNCTIONS # Helper functions for option handling. -*- Autoconf -*- # # Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free # Software Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 8 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) # ------------------------------------------ m4_define([_LT_MANGLE_OPTION], [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) # --------------------------------------- # Set option OPTION-NAME for macro MACRO-NAME, and if there is a # matching handler defined, dispatch to it. Other OPTION-NAMEs are # saved as a flag. m4_define([_LT_SET_OPTION], [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), _LT_MANGLE_DEFUN([$1], [$2]), [m4_warning([Unknown $1 option '$2'])])[]dnl ]) # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) # ------------------------------------------------------------ # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. m4_define([_LT_IF_OPTION], [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) # ------------------------------------------------------- # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME # are set. m4_define([_LT_UNLESS_OPTIONS], [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), [m4_define([$0_found])])])[]dnl m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 ])[]dnl ]) # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) # ---------------------------------------- # OPTION-LIST is a space-separated list of Libtool options associated # with MACRO-NAME. If any OPTION has a matching handler declared with # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about # the unknown option and exit. m4_defun([_LT_SET_OPTIONS], [# Set options m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [_LT_SET_OPTION([$1], _LT_Option)]) m4_if([$1],[LT_INIT],[ dnl dnl Simply set some default values (i.e off) if boolean options were not dnl specified: _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no ]) _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no ]) dnl dnl If no reference was made to various pairs of opposing options, then dnl we run the default mode handler for the pair. For example, if neither dnl 'shared' nor 'disable-shared' was passed, we enable building of shared dnl archives by default: _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], [_LT_ENABLE_FAST_INSTALL]) _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], [_LT_WITH_AIX_SONAME([aix])]) ]) ])# _LT_SET_OPTIONS # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) # ----------------------------------------- m4_define([_LT_MANGLE_DEFUN], [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) # ----------------------------------------------- m4_define([LT_OPTION_DEFINE], [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl ])# LT_OPTION_DEFINE # dlopen # ------ LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes ]) AU_DEFUN([AC_LIBTOOL_DLOPEN], [_LT_SET_OPTION([LT_INIT], [dlopen]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'dlopen' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) # win32-dll # --------- # Declare package support for building win32 dll's. LT_OPTION_DEFINE([LT_INIT], [win32-dll], [enable_win32_dll=yes case $host in *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) AC_CHECK_TOOL(AS, as, false) AC_CHECK_TOOL(DLLTOOL, dlltool, false) AC_CHECK_TOOL(OBJDUMP, objdump, false) ;; esac test -z "$AS" && AS=as _LT_DECL([], [AS], [1], [Assembler program])dnl test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl ])# win32-dll AU_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_REQUIRE([AC_CANONICAL_HOST])dnl _LT_SET_OPTION([LT_INIT], [win32-dll]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'win32-dll' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) # _LT_ENABLE_SHARED([DEFAULT]) # ---------------------------- # implement the --enable-shared flag, and supports the 'shared' and # 'disable-shared' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_SHARED], [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([shared], [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac], [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) _LT_DECL([build_libtool_libs], [enable_shared], [0], [Whether or not to build shared libraries]) ])# _LT_ENABLE_SHARED LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) # Old names: AC_DEFUN([AC_ENABLE_SHARED], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) ]) AC_DEFUN([AC_DISABLE_SHARED], [_LT_SET_OPTION([LT_INIT], [disable-shared]) ]) AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_SHARED], []) dnl AC_DEFUN([AM_DISABLE_SHARED], []) # _LT_ENABLE_STATIC([DEFAULT]) # ---------------------------- # implement the --enable-static flag, and support the 'static' and # 'disable-static' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_STATIC], [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([static], [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac], [enable_static=]_LT_ENABLE_STATIC_DEFAULT) _LT_DECL([build_old_libs], [enable_static], [0], [Whether or not to build static libraries]) ])# _LT_ENABLE_STATIC LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) # Old names: AC_DEFUN([AC_ENABLE_STATIC], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) ]) AC_DEFUN([AC_DISABLE_STATIC], [_LT_SET_OPTION([LT_INIT], [disable-static]) ]) AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_STATIC], []) dnl AC_DEFUN([AM_DISABLE_STATIC], []) # _LT_ENABLE_FAST_INSTALL([DEFAULT]) # ---------------------------------- # implement the --enable-fast-install flag, and support the 'fast-install' # and 'disable-fast-install' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_FAST_INSTALL], [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([fast-install], [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac], [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) _LT_DECL([fast_install], [enable_fast_install], [0], [Whether or not to optimize for fast installation])dnl ])# _LT_ENABLE_FAST_INSTALL LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) # Old names: AU_DEFUN([AC_ENABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'fast-install' option into LT_INIT's first parameter.]) ]) AU_DEFUN([AC_DISABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], [disable-fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'disable-fast-install' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) # _LT_WITH_AIX_SONAME([DEFAULT]) # ---------------------------------- # implement the --with-aix-soname flag, and support the `aix-soname=aix' # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. m4_define([_LT_WITH_AIX_SONAME], [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[[5-9]]*,yes) AC_MSG_CHECKING([which variant of shared library versioning to provide]) AC_ARG_WITH([aix-soname], [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], [case $withval in aix|svr4|both) ;; *) AC_MSG_ERROR([Unknown argument to --with-aix-soname]) ;; esac lt_cv_with_aix_soname=$with_aix_soname], [AC_CACHE_VAL([lt_cv_with_aix_soname], [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) with_aix_soname=$lt_cv_with_aix_soname]) AC_MSG_RESULT([$with_aix_soname]) if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac _LT_DECL([], [shared_archive_member_spec], [0], [Shared archive member basename, for filename based shared library versioning on AIX])dnl ])# _LT_WITH_AIX_SONAME LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) # _LT_WITH_PIC([MODE]) # -------------------- # implement the --with-pic flag, and support the 'pic-only' and 'no-pic' # LT_INIT options. # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. m4_define([_LT_WITH_PIC], [AC_ARG_WITH([pic], [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], [lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac], [pic_mode=m4_default([$1], [default])]) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) # Old name: AU_DEFUN([AC_LIBTOOL_PICMODE], [_LT_SET_OPTION([LT_INIT], [pic-only]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'pic-only' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) m4_define([_LTDL_MODE], []) LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], [m4_define([_LTDL_MODE], [nonrecursive])]) LT_OPTION_DEFINE([LTDL_INIT], [recursive], [m4_define([_LTDL_MODE], [recursive])]) LT_OPTION_DEFINE([LTDL_INIT], [subproject], [m4_define([_LTDL_MODE], [subproject])]) m4_define([_LTDL_TYPE], []) LT_OPTION_DEFINE([LTDL_INIT], [installable], [m4_define([_LTDL_TYPE], [installable])]) LT_OPTION_DEFINE([LTDL_INIT], [convenience], [m4_define([_LTDL_TYPE], [convenience])]) # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software # Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 6 ltsugar.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) # lt_join(SEP, ARG1, [ARG2...]) # ----------------------------- # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their # associated separator. # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier # versions in m4sugar had bugs. m4_define([lt_join], [m4_if([$#], [1], [], [$#], [2], [[$2]], [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) m4_define([_lt_join], [m4_if([$#$2], [2], [], [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) # lt_car(LIST) # lt_cdr(LIST) # ------------ # Manipulate m4 lists. # These macros are necessary as long as will still need to support # Autoconf-2.59, which quotes differently. m4_define([lt_car], [[$1]]) m4_define([lt_cdr], [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], [$#], 1, [], [m4_dquote(m4_shift($@))])]) m4_define([lt_unquote], $1) # lt_append(MACRO-NAME, STRING, [SEPARATOR]) # ------------------------------------------ # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. # Note that neither SEPARATOR nor STRING are expanded; they are appended # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). # No SEPARATOR is output if MACRO-NAME was previously undefined (different # than defined and empty). # # This macro is needed until we can rely on Autoconf 2.62, since earlier # versions of m4sugar mistakenly expanded SEPARATOR but not STRING. m4_define([lt_append], [m4_define([$1], m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) # ---------------------------------------------------------- # Produce a SEP delimited list of all paired combinations of elements of # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list # has the form PREFIXmINFIXSUFFIXn. # Needed until we can rely on m4_combine added in Autoconf 2.62. m4_define([lt_combine], [m4_if(m4_eval([$# > 3]), [1], [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl [[m4_foreach([_Lt_prefix], [$2], [m4_foreach([_Lt_suffix], ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) # ----------------------------------------------------------------------- # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. m4_define([lt_if_append_uniq], [m4_ifdef([$1], [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], [lt_append([$1], [$2], [$3])$4], [$5])], [lt_append([$1], [$2], [$3])$4])]) # lt_dict_add(DICT, KEY, VALUE) # ----------------------------- m4_define([lt_dict_add], [m4_define([$1($2)], [$3])]) # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) # -------------------------------------------- m4_define([lt_dict_add_subkey], [m4_define([$1($2:$3)], [$4])]) # lt_dict_fetch(DICT, KEY, [SUBKEY]) # ---------------------------------- m4_define([lt_dict_fetch], [m4_ifval([$3], m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) # ----------------------------------------------------------------- m4_define([lt_if_dict_fetch], [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], [$5], [$6])]) # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) # -------------------------------------------------------------- m4_define([lt_dict_filter], [m4_if([$5], [], [], [lt_join(m4_quote(m4_default([$4], [[, ]])), lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl ]) # ltversion.m4 -- version numbers -*- Autoconf -*- # # Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation, # Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # @configure_input@ # serial 4245 ltversion.m4 # This file is part of GNU Libtool m4_define([LT_PACKAGE_VERSION], [2.4.7]) m4_define([LT_PACKAGE_REVISION], [2.4.7]) AC_DEFUN([LTVERSION_VERSION], [macro_version='2.4.7' macro_revision='2.4.7' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free # Software Foundation, Inc. # Written by Scott James Remnant, 2004. # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 5 lt~obsolete.m4 # These exist entirely to fool aclocal when bootstrapping libtool. # # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), # which have later been changed to m4_define as they aren't part of the # exported API, or moved to Autoconf or Automake where they belong. # # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us # using a macro with the same name in our local m4/libtool.m4 it'll # pull the old libtool.m4 in (it doesn't see our shiny new m4_define # and doesn't know about Autoconf macros at all.) # # So we provide this file, which has a silly filename so it's always # included after everything else. This provides aclocal with the # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything # because those macros already exist, or will be overwritten later. # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. # # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. # Yes, that means every name once taken will need to remain here until # we give up compatibility with versions before 1.7, at which point # we need to keep only those names which we still refer to. # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) mlterm-3.9.3/baselib/configure000077500000000000000000015772541441203364000163600ustar00rootroot00000000000000#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.69. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. # # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # Use a proper internal environment variable to ensure we don't fall # into an infinite loop, continuously re-executing ourselves. if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then _as_can_reexec=no; export _as_can_reexec; # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 as_fn_exit 255 fi # We don't want this to propagate to other subprocesses. { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi " as_required="as_fn_return () { (exit \$1); } as_fn_success () { as_fn_return 0; } as_fn_failure () { as_fn_return 1; } as_fn_ret_success () { return 0; } as_fn_ret_failure () { return 1; } exitcode=0 as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || exit 1 test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 test \$(( 1 + 1 )) = 2 || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. as_shell=$as_dir/$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : CONFIG_SHELL=$as_shell as_have_required=yes if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : break 2 fi fi done;; esac as_found=false done $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : CONFIG_SHELL=$SHELL as_have_required=yes fi; } IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : export CONFIG_SHELL # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 exit 255 fi if test x$as_have_required = xno; then : $as_echo "$0: This script requires a shell more modern than all" $as_echo "$0: the shells that I found on your system." if test x${ZSH_VERSION+set} = xset ; then $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, $0: including any error possibly output before this $0: message. Then install a modern shell, or manually run $0: the script under such a shell if you do have one." fi exit 1 fi fi fi SHELL=${CONFIG_SHELL-/bin/sh} export SHELL # Unset more variables known to interfere with behavior of common tools. CLICOLOR_FORCE= GREP_OPTIONS= unset CLICOLOR_FORCE GREP_OPTIONS ## --------------------- ## ## M4sh Shell Functions. ## ## --------------------- ## # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits as_lineno_1=$LINENO as_lineno_1a=$LINENO as_lineno_2=$LINENO as_lineno_2a=$LINENO eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # If we had to re-execute with $CONFIG_SHELL, we're ensured to have # already done that, so ensure we don't try to do so again and fall # in an infinite loop. This has already happened in practice. _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" SHELL=${CONFIG_SHELL-/bin/sh} test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= # Identity of this package. PACKAGE_NAME= PACKAGE_TARNAME= PACKAGE_VERSION= PACKAGE_STRING= PACKAGE_BUGREPORT= PACKAGE_URL= # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_subst_vars='LTLIBOBJS LIBOBJS pobl_top_builddir_suffix pobl_top_srcdir_suffix UTMP_CFLAGS UTMP_LIBS UTMP_NAME PTY_NAME NO_UNDEFINED_FLAG DL_CFLAGS DL_LIBS DL_LOADER XPG4_LIBS ALLOCA LT_SYS_LIBRARY_PATH OTOOL64 OTOOL LIPO NMEDIT DSYMUTIL MANIFEST_TOOL AWK RANLIB STRIP ac_ct_AR AR FILECMD LN_S NM ac_ct_DUMPBIN DUMPBIN LD FGREP EGREP GREP SED LIBTOOL OBJDUMP DLLTOOL AS DEB_CFLAGS INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM CPP OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CC CFLAGS host_os host_vendor host_cpu host build_os build_vendor build_cpu build target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking enable_debug with_libtool enable_shared enable_static with_pic enable_fast_install with_aix_soname with_gnu_ld with_sysroot enable_libtool_lock enable_largefile with_libltdl enable_pty_helper with_utmp with_funcs_mlterm_unuse ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CPP LT_SYS_LIBRARY_PATH' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *=) ac_optarg= ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) as_fn_error $? "unrecognized option: \`$ac_option' Try \`$0 --help' for more information" ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures this package to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-debug debug [default=disabled] --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) --disable-largefile omit support for large files --enable-pty-helper use pty helper [default=disabled] Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-libtool[=ARG] libtool path [default=without] --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use both] --with-aix-soname=aix|svr4|both shared library versioning (aka "SONAME") variant to provide on AIX, [default=aix]. --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-sysroot[=DIR] Search for dependent libraries within DIR (or the compiler's sysroot if not specified). --with-libltdl[=PREFIX] load modules with libltdl [default=without] --with-utmp[=ARG] utmp (utempter,sysv,login,bsd,none) --without-funcs-mlterm-unuse remove functions mlterm does not use [default=with] Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor LT_SYS_LIBRARY_PATH User-defined run-time library search path. Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to the package provider. _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF configure generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi ## ------------------------ ## ## Autoconf initialization. ## ## ------------------------ ## # ac_fn_c_try_compile LINENO # -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile # ac_fn_c_try_cpp LINENO # ---------------------- # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp # ac_fn_c_try_link LINENO # ----------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists and can be compiled using the include files in # INCLUDES, setting the cache variable VAR accordingly. ac_fn_c_check_header_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile # ac_fn_c_try_run LINENO # ---------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes # that executables *can* be run. ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then : ac_retval=0 else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Define $2 to an innocuous variant, in case declares $2. For example, HP-UX 11i declares gettimeofday. */ #define $2 innocuous_$2 /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $2 (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $2 /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $2 (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$2 || defined __stub___$2 choke me #endif int main () { return $2 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists, giving a warning if it cannot be compiled using # the include files in INCLUDES and setting the cache variable VAR # accordingly. ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } else # Is the header compilable? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 $as_echo_n "checking $2 usability... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_header_compiler=yes else ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 $as_echo "$ac_header_compiler" >&6; } # Is the header present? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 $as_echo_n "checking $2 presence... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$2> _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : ac_header_preproc=yes else ac_header_preproc=no fi rm -f conftest.err conftest.i conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( yes:no: ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; no:yes:* ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel # ac_fn_c_check_type LINENO TYPE VAR INCLUDES # ------------------------------------------- # Tests whether TYPE exists after having included INCLUDES, setting cache # variable VAR accordingly. ac_fn_c_check_type () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=no" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { if (sizeof ($2)) return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { if (sizeof (($2))) return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else eval "$3=yes" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_type cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by $as_me, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. $as_echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi as_fn_append ac_configure_args " '$ac_arg'" ;; esac done done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo $as_echo "## ---------------- ## ## Cache variables. ## ## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo $as_echo "## ----------------- ## ## Output variables. ## ## ----------------- ##" echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then $as_echo "## ------------------- ## ## File substitutions. ## ## ------------------- ##" echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then $as_echo "## ----------- ## ## confdefs.h. ## ## ----------- ##" echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h $as_echo "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_URL "$PACKAGE_URL" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then # We do not want a PATH search for config.site. case $CONFIG_SITE in #(( -*) ac_site_file1=./$CONFIG_SITE;; */*) ac_site_file1=$CONFIG_SITE;; *) ac_site_file1=./$CONFIG_SITE;; esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" \ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "failed to load site script $ac_site_file See \`config.log' for more details" "$LINENO" 5; } fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) as_fn_append ac_configure_args " '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## ## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_config_headers="$ac_config_headers src/bl_config.h" ac_aux_dir= for ac_dir in script "$srcdir"/script; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then as_fn_error $? "cannot find install-sh, install.sh, or shtool in script \"$srcdir\"/script" "$LINENO" 5 fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } if ${ac_cv_build+:} false; then : $as_echo_n "(cached) " >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 $as_echo "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } if ${ac_cv_host+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac # for CFLAGS="..." ./configure ... ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { { ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi if test -z "$ac_file"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of executables: cannot compile and link See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details" "$LINENO" 5; } fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of object files: cannot compile See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # if --with-libtool is specified, cpp isn't detected. ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 $as_echo_n "checking how to run the C preprocessor... " >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in #(( ./ | .// | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' #detect glibc cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { #ifdef __GLIBC__ #else #error int boil\[-1\]; #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : $as_echo "#define HAVE_GNU_SOURCE 1" >>confdefs.h fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext # # --- debug --- # # Check whether --enable-debug was given. if test "${enable_debug+set}" = set; then : enableval=$enable_debug; debug=$enable_debug fi if test "$debug" = yes ; then DEB_CFLAGS="-DDEBUG -DBL_DEBUG" fi # # --- libtool --- # enable_win32_dll=yes case $host in *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. set dummy ${ac_tool_prefix}as; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AS+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AS"; then ac_cv_prog_AS="$AS" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AS="${ac_tool_prefix}as" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AS=$ac_cv_prog_AS if test -n "$AS"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 $as_echo "$AS" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_AS"; then ac_ct_AS=$AS # Extract the first word of "as", so it can be a program name with args. set dummy as; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_AS+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_AS"; then ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AS="as" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AS=$ac_cv_prog_ac_ct_AS if test -n "$ac_ct_AS"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5 $as_echo "$ac_ct_AS" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_AS" = x; then AS="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac AS=$ac_ct_AS fi else AS="$ac_cv_prog_AS" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. set dummy ${ac_tool_prefix}dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DLLTOOL"; then ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DLLTOOL=$ac_cv_prog_DLLTOOL if test -n "$DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 $as_echo "$DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DLLTOOL"; then ac_ct_DLLTOOL=$DLLTOOL # Extract the first word of "dlltool", so it can be a program name with args. set dummy dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DLLTOOL"; then ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DLLTOOL="dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL if test -n "$ac_ct_DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 $as_echo "$ac_ct_DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DLLTOOL" = x; then DLLTOOL="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DLLTOOL=$ac_ct_DLLTOOL fi else DLLTOOL="$ac_cv_prog_DLLTOOL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. set dummy ${ac_tool_prefix}objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 $as_echo "$OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OBJDUMP"; then ac_ct_OBJDUMP=$OBJDUMP # Extract the first word of "objdump", so it can be a program name with args. set dummy objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OBJDUMP"; then ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OBJDUMP="objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP if test -n "$ac_ct_OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 $as_echo "$ac_ct_OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then OBJDUMP="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OBJDUMP=$ac_ct_OBJDUMP fi else OBJDUMP="$ac_cv_prog_OBJDUMP" fi ;; esac test -z "$AS" && AS=as test -z "$DLLTOOL" && DLLTOOL=dlltool test -z "$OBJDUMP" && OBJDUMP=objdump enable_dlopen=yes # Check whether --with-libtool was given. if test "${with_libtool+set}" = set; then : withval=$with_libtool; libtool=$with_libtool fi if test "${libtool}" != "" ; then LIBTOOL=${libtool} else case `pwd` in *\ * | *\ *) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; esac macro_version='2.4.7' macro_revision='2.4.7' ltmain=$ac_aux_dir/ltmain.sh # Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\(["`$\\]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\(["`\\]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 $as_echo_n "checking how to print strings... " >&6; } # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "" } case $ECHO in printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 $as_echo "printf" >&6; } ;; print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 $as_echo "print -r" >&6; } ;; *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 $as_echo "cat" >&6; } ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 $as_echo_n "checking for a sed that does not truncate output... " >&6; } if ${ac_cv_path_SED+:} false; then : $as_echo_n "(cached) " >&6 else ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for ac_i in 1 2 3 4 5 6 7; do ac_script="$ac_script$as_nl$ac_script" done echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed { ac_script=; unset ac_script;} if test -z "$SED"; then ac_path_SED_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_SED" || continue # Check for GNU ac_path_SED and select it if it is found. # Check for GNU $ac_path_SED case `"$ac_path_SED" --version 2>&1` in *GNU*) ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo '' >> "conftest.nl" "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_SED_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_SED="$ac_path_SED" ac_path_SED_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_SED_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_SED"; then as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 fi else ac_cv_path_SED=$SED fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 $as_echo "$ac_cv_path_SED" >&6; } SED="$ac_cv_path_SED" rm -f conftest.sed test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 $as_echo "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else if test -z "$EGREP"; then ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 $as_echo_n "checking for fgrep... " >&6; } if ${ac_cv_path_FGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 then ac_cv_path_FGREP="$GREP -F" else if test -z "$FGREP"; then ac_path_FGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in fgrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_FGREP" || continue # Check for GNU ac_path_FGREP and select it if it is found. # Check for GNU $ac_path_FGREP case `"$ac_path_FGREP" --version 2>&1` in *GNU*) ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'FGREP' >> "conftest.nl" "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_FGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_FGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_FGREP"; then as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_FGREP=$FGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 $as_echo "$ac_cv_path_FGREP" >&6; } FGREP="$ac_cv_path_FGREP" test -z "$GREP" && GREP=grep # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then : withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 $as_echo_n "checking for ld used by $CC... " >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 $as_echo_n "checking for GNU ld... " >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi if ${lt_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 $as_echo "$LD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } if ${lt_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 $as_echo "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } if ${lt_cv_path_NM+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 $as_echo "$lt_cv_path_NM" >&6; } if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else if test -n "$ac_tool_prefix"; then for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DUMPBIN+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DUMPBIN"; then ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DUMPBIN=$ac_cv_prog_DUMPBIN if test -n "$DUMPBIN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 $as_echo "$DUMPBIN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$DUMPBIN" && break done fi if test -z "$DUMPBIN"; then ac_ct_DUMPBIN=$DUMPBIN for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DUMPBIN"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN if test -n "$ac_ct_DUMPBIN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 $as_echo "$ac_ct_DUMPBIN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_DUMPBIN" && break done if test "x$ac_ct_DUMPBIN" = x; then DUMPBIN=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DUMPBIN=$ac_ct_DUMPBIN fi fi case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 $as_echo_n "checking the name lister ($NM) interface... " >&6; } if ${lt_cv_nm_interface+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: output\"" >&5) cat conftest.out >&5 if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 $as_echo "$lt_cv_nm_interface" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 $as_echo_n "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 $as_echo "no, using $LN_S" >&6; } fi # find the maximum length of command line arguments { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 $as_echo_n "checking the maximum length of command line arguments... " >&6; } if ${lt_cv_sys_max_cmd_len+:} false; then : $as_echo_n "(cached) " >&6 else i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | msys* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[ ]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac fi if test -n "$lt_cv_sys_max_cmd_len"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 $as_echo "$lt_cv_sys_max_cmd_len" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 $as_echo "none" >&6; } fi max_cmd_len=$lt_cv_sys_max_cmd_len : ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 $as_echo_n "checking how to convert $build file names to $host format... " >&6; } if ${lt_cv_to_host_file_cmd+:} false; then : $as_echo_n "(cached) " >&6 else case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac fi to_host_file_cmd=$lt_cv_to_host_file_cmd { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 $as_echo "$lt_cv_to_host_file_cmd" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } if ${lt_cv_to_tool_file_cmd+:} false; then : $as_echo_n "(cached) " >&6 else #assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac fi to_tool_file_cmd=$lt_cv_to_tool_file_cmd { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 $as_echo "$lt_cv_to_tool_file_cmd" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 $as_echo_n "checking for $LD option to reload object files... " >&6; } if ${lt_cv_ld_reload_flag+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_reload_flag='-r' fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 $as_echo "$lt_cv_ld_reload_flag" >&6; } reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; *) reload_flag=" $reload_flag" ;; esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) if test yes != "$GCC"; then reload_cmds=false fi ;; darwin*) if test yes = "$GCC"; then reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi ;; esac if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}file", so it can be a program name with args. set dummy ${ac_tool_prefix}file; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_FILECMD+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$FILECMD"; then ac_cv_prog_FILECMD="$FILECMD" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_FILECMD="${ac_tool_prefix}file" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi FILECMD=$ac_cv_prog_FILECMD if test -n "$FILECMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILECMD" >&5 $as_echo "$FILECMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_FILECMD"; then ac_ct_FILECMD=$FILECMD # Extract the first word of "file", so it can be a program name with args. set dummy file; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_FILECMD+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_FILECMD"; then ac_cv_prog_ac_ct_FILECMD="$ac_ct_FILECMD" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_FILECMD="file" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_FILECMD=$ac_cv_prog_ac_ct_FILECMD if test -n "$ac_ct_FILECMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_FILECMD" >&5 $as_echo "$ac_ct_FILECMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_FILECMD" = x; then FILECMD=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac FILECMD=$ac_ct_FILECMD fi else FILECMD="$ac_cv_prog_FILECMD" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. set dummy ${ac_tool_prefix}objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 $as_echo "$OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OBJDUMP"; then ac_ct_OBJDUMP=$OBJDUMP # Extract the first word of "objdump", so it can be a program name with args. set dummy objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OBJDUMP"; then ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OBJDUMP="objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP if test -n "$ac_ct_OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 $as_echo "$ac_ct_OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then OBJDUMP="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OBJDUMP=$ac_ct_OBJDUMP fi else OBJDUMP="$ac_cv_prog_OBJDUMP" fi test -z "$OBJDUMP" && OBJDUMP=objdump { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 $as_echo_n "checking how to recognize dependent libraries... " >&6; } if ${lt_cv_deplibs_check_method+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[4-9]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[45]*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin* | msys*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[3-9]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 $as_echo "$lt_cv_deplibs_check_method" >&6; } file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. set dummy ${ac_tool_prefix}dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DLLTOOL"; then ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DLLTOOL=$ac_cv_prog_DLLTOOL if test -n "$DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 $as_echo "$DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DLLTOOL"; then ac_ct_DLLTOOL=$DLLTOOL # Extract the first word of "dlltool", so it can be a program name with args. set dummy dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DLLTOOL"; then ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DLLTOOL="dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL if test -n "$ac_ct_DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 $as_echo "$ac_ct_DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DLLTOOL" = x; then DLLTOOL="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DLLTOOL=$ac_ct_DLLTOOL fi else DLLTOOL="$ac_cv_prog_DLLTOOL" fi test -z "$DLLTOOL" && DLLTOOL=dlltool { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 $as_echo_n "checking how to associate runtime and link libraries... " >&6; } if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO if test -n "$ac_tool_prefix"; then for ac_prog in ar do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AR"; then ac_cv_prog_AR="$AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AR="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AR=$ac_cv_prog_AR if test -n "$AR"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 $as_echo "$AR" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AR" && break done fi if test -z "$AR"; then ac_ct_AR=$AR for ac_prog in ar do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 $as_echo "$ac_ct_AR" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_AR" && break done if test "x$ac_ct_AR" = x; then AR="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac AR=$ac_ct_AR fi fi : ${AR=ar} # Use ARFLAGS variable as AR's operation code to sync the variable naming with # Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have # higher priority because thats what people were doing historically (setting # ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS # variable obsoleted/removed. test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} lt_ar_flags=$AR_FLAGS # Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override # by AR_FLAGS because that was never working and AR_FLAGS is about to die. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 $as_echo_n "checking for archiver @FILE support... " >&6; } if ${lt_cv_ar_at_file+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ar_at_file=no cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 $as_echo "$lt_cv_ar_at_file" >&6; } if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi test -z "$STRIP" && STRIP=: if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. set dummy ${ac_tool_prefix}ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$RANLIB"; then ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 $as_echo "$RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_RANLIB"; then ac_ct_RANLIB=$RANLIB # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_RANLIB"; then ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 $as_echo "$ac_ct_RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_RANLIB" = x; then RANLIB=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac RANLIB=$ac_ct_RANLIB fi else RANLIB="$ac_cv_prog_RANLIB" fi test -z "$RANLIB" && RANLIB=: # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Check for command to grab the raw symbol name followed by C symbol from nm. { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } if ${lt_cv_sys_global_symbol_pipe+:} false; then : $as_echo_n "(cached) " >&6 else # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[BCDEGRST]' # Regexp to match symbols that can be accessed directly from C. sympat='\([_A-Za-z][_A-Za-z0-9]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[BCDT]' ;; cygwin* | msys* | mingw* | pw32* | cegcc*) symcode='[ABCDGISTW]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[ABCDEGRST]' fi ;; irix* | nonstopux*) symcode='[BCDEGRST]' ;; osf*) symcode='[BCDEGQRST]' ;; solaris*) symcode='[BDRT]' ;; sco3.2v5*) symcode='[DT]' ;; sysv4.2uw2*) symcode='[DT]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[ABDT]' ;; sysv4) symcode='[DFNSTU]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[ABCDGIRSTW]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK '"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx" else lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then # Now try to grab the symbols. nlist=conftest.nm if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT_DLSYM_CONST #else # define LT_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done fi if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 $as_echo "failed" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 $as_echo "ok" >&6; } fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then nm_file_list_spec='@' fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 $as_echo_n "checking for sysroot... " >&6; } # Check whether --with-sysroot was given. if test "${with_sysroot+set}" = set; then : withval=$with_sysroot; else with_sysroot=no fi lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 $as_echo "$with_sysroot" >&6; } as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 $as_echo "${lt_sysroot:-no}" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 $as_echo_n "checking for a working dd... " >&6; } if ${ac_cv_path_lt_DD+:} false; then : $as_echo_n "(cached) " >&6 else printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} if test -z "$lt_DD"; then ac_path_lt_DD_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in dd; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_lt_DD" || continue if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi $ac_path_lt_DD_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_lt_DD"; then : fi else ac_cv_path_lt_DD=$lt_DD fi rm -f conftest.i conftest2.i conftest.out fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 $as_echo "$ac_cv_path_lt_DD" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 $as_echo_n "checking how to truncate binary pipes... " >&6; } if ${lt_cv_truncate_bin+:} false; then : $as_echo_n "(cached) " >&6 else printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 $as_echo "$lt_cv_truncate_bin" >&6; } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then : enableval=$enable_libtool_lock; fi test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then if test yes = "$lt_cv_prog_gnu_ld"; then case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then emul=elf case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 $as_echo_n "checking whether the C compiler needs -belf... " >&6; } if ${lt_cv_cc_needs_belf+:} false; then : $as_echo_n "(cached) " >&6 else ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_cc_needs_belf=yes else lt_cv_cc_needs_belf=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 $as_echo "$lt_cv_cc_needs_belf" >&6; } if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. set dummy ${ac_tool_prefix}mt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$MANIFEST_TOOL"; then ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL if test -n "$MANIFEST_TOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 $as_echo "$MANIFEST_TOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_MANIFEST_TOOL"; then ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL # Extract the first word of "mt", so it can be a program name with args. set dummy mt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_MANIFEST_TOOL"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL if test -n "$ac_ct_MANIFEST_TOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_MANIFEST_TOOL" = x; then MANIFEST_TOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL fi else MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" fi test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } if ${lt_cv_path_mainfest_tool+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&5 if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 $as_echo "$lt_cv_path_mainfest_tool" >&6; } if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi case $host_os in rhapsody* | darwin*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DSYMUTIL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DSYMUTIL"; then ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DSYMUTIL=$ac_cv_prog_DSYMUTIL if test -n "$DSYMUTIL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 $as_echo "$DSYMUTIL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DSYMUTIL"; then ac_ct_DSYMUTIL=$DSYMUTIL # Extract the first word of "dsymutil", so it can be a program name with args. set dummy dsymutil; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DSYMUTIL"; then ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL if test -n "$ac_ct_DSYMUTIL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 $as_echo "$ac_ct_DSYMUTIL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DSYMUTIL" = x; then DSYMUTIL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DSYMUTIL=$ac_ct_DSYMUTIL fi else DSYMUTIL="$ac_cv_prog_DSYMUTIL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. set dummy ${ac_tool_prefix}nmedit; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_NMEDIT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$NMEDIT"; then ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi NMEDIT=$ac_cv_prog_NMEDIT if test -n "$NMEDIT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 $as_echo "$NMEDIT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_NMEDIT"; then ac_ct_NMEDIT=$NMEDIT # Extract the first word of "nmedit", so it can be a program name with args. set dummy nmedit; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_NMEDIT"; then ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_NMEDIT="nmedit" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT if test -n "$ac_ct_NMEDIT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 $as_echo "$ac_ct_NMEDIT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_NMEDIT" = x; then NMEDIT=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac NMEDIT=$ac_ct_NMEDIT fi else NMEDIT="$ac_cv_prog_NMEDIT" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. set dummy ${ac_tool_prefix}lipo; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$LIPO"; then ac_cv_prog_LIPO="$LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_LIPO="${ac_tool_prefix}lipo" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi LIPO=$ac_cv_prog_LIPO if test -n "$LIPO"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 $as_echo "$LIPO" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_LIPO"; then ac_ct_LIPO=$LIPO # Extract the first word of "lipo", so it can be a program name with args. set dummy lipo; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_LIPO"; then ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_LIPO="lipo" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO if test -n "$ac_ct_LIPO"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 $as_echo "$ac_ct_LIPO" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_LIPO" = x; then LIPO=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac LIPO=$ac_ct_LIPO fi else LIPO="$ac_cv_prog_LIPO" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. set dummy ${ac_tool_prefix}otool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL"; then ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL="${ac_tool_prefix}otool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL=$ac_cv_prog_OTOOL if test -n "$OTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 $as_echo "$OTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL"; then ac_ct_OTOOL=$OTOOL # Extract the first word of "otool", so it can be a program name with args. set dummy otool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL"; then ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL="otool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL if test -n "$ac_ct_OTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 $as_echo "$ac_ct_OTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OTOOL" = x; then OTOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL=$ac_ct_OTOOL fi else OTOOL="$ac_cv_prog_OTOOL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. set dummy ${ac_tool_prefix}otool64; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL64"; then ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL64=$ac_cv_prog_OTOOL64 if test -n "$OTOOL64"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 $as_echo "$OTOOL64" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL64"; then ac_ct_OTOOL64=$OTOOL64 # Extract the first word of "otool64", so it can be a program name with args. set dummy otool64; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL64"; then ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL64="otool64" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 if test -n "$ac_ct_OTOOL64"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 $as_echo "$ac_ct_OTOOL64" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OTOOL64" = x; then OTOOL64=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL64=$ac_ct_OTOOL64 fi else OTOOL64="$ac_cv_prog_OTOOL64" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 $as_echo_n "checking for -single_module linker flag... " >&6; } if ${lt_cv_apple_cc_single_mod+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&5 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&5 # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&5 fi rm -rf libconftest.dylib* rm -f conftest.* fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 $as_echo "$lt_cv_apple_cc_single_mod" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } if ${lt_cv_ld_exported_symbols_list+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_ld_exported_symbols_list=yes else lt_cv_ld_exported_symbols_list=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 $as_echo_n "checking for -force_load linker flag... " >&6; } if ${lt_cv_ld_force_load+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 echo "$AR $AR_FLAGS libconftest.a conftest.o" >&5 $AR $AR_FLAGS libconftest.a conftest.o 2>&5 echo "$RANLIB libconftest.a" >&5 $RANLIB libconftest.a 2>&5 cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&5 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&5 fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 $as_echo "$lt_cv_ld_force_load" >&6; } case $host_os in rhapsody* | darwin1.[012]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) case $MACOSX_DEPLOYMENT_TARGET,$host in 10.[012],*|,*powerpc*-darwin[5-8]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; *) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default " if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in dlfcn.h do : ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default " if test "x$ac_cv_header_dlfcn_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_DLFCN_H 1 _ACEOF fi done # Set options # Check whether --enable-shared was given. if test "${enable_shared+set}" = set; then : enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac else enable_shared=yes fi # Check whether --enable-static was given. if test "${enable_static+set}" = set; then : enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac else enable_static=yes fi # Check whether --with-pic was given. if test "${with_pic+set}" = set; then : withval=$with_pic; lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac else pic_mode=default fi # Check whether --enable-fast-install was given. if test "${enable_fast_install+set}" = set; then : enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac else enable_fast_install=yes fi shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[5-9]*,yes) { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; } # Check whether --with-aix-soname was given. if test "${with_aix_soname+set}" = set; then : withval=$with_aix_soname; case $withval in aix|svr4|both) ;; *) as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 ;; esac lt_cv_with_aix_soname=$with_aix_soname else if ${lt_cv_with_aix_soname+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_with_aix_soname=aix fi with_aix_soname=$lt_cv_with_aix_soname fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 $as_echo "$with_aix_soname" >&6; } if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' test -z "$LN_S" && LN_S="ln -s" if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 $as_echo_n "checking for objdir... " >&6; } if ${lt_cv_objdir+:} false; then : $as_echo_n "(cached) " >&6 else rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 $as_echo "$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir cat >>confdefs.h <<_ACEOF #define LT_OBJDIR "$lt_cv_objdir/" _ACEOF case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC and # ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o func_cc_basename $compiler cc_basename=$func_cc_basename_result # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/${ac_tool_prefix}file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 $as_echo_n "checking for file... " >&6; } if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi else MAGIC_CMD=: fi fi fi ;; esac # Use C for the default configuration in the libtool script lt_save_CC=$CC ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o objext=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* if test -n "$compiler"; then lt_prog_compiler_no_builtin_flag= if test yes = "$GCC"; then case $cc_basename in nvcc*) lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; *) lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl= lt_prog_compiler_pic= lt_prog_compiler_static= if test yes = "$GCC"; then lt_prog_compiler_wl='-Wl,' lt_prog_compiler_static='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' fi lt_prog_compiler_pic='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support lt_prog_compiler_pic='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. lt_prog_compiler_static= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) lt_prog_compiler_pic='-fPIC' ;; esac ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic=-Kconform_pic fi ;; *) lt_prog_compiler_pic='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 lt_prog_compiler_wl='-Xlinker ' if test -n "$lt_prog_compiler_pic"; then lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' else lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; esac ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; # Lahey Fortran 8.1. lf95*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='--shared' lt_prog_compiler_static='--static' ;; nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; ccc*) lt_prog_compiler_wl='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-qpic' lt_prog_compiler_static='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='' ;; *Sun\ F* | *Sun*Fortran*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Wl,' ;; *Intel*\ [CF]*Compiler*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; *Portland\ Group*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; esac ;; esac ;; newsos6) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static='-non_shared' ;; rdos*) lt_prog_compiler_static='-non_shared' ;; solaris*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) lt_prog_compiler_wl='-Qoption ld ';; *) lt_prog_compiler_wl='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl='-Qoption ld ' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic='-Kconform_pic' lt_prog_compiler_static='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; unicos*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_can_build_shared=no ;; uts4*) lt_prog_compiler_pic='-pic' lt_prog_compiler_static='-Bstatic' ;; *) lt_prog_compiler_can_build_shared=no ;; esac fi case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic= ;; *) lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 $as_echo_n "checking for $compiler option to produce PIC... " >&6; } if ${lt_cv_prog_compiler_pic+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic=$lt_prog_compiler_pic fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 $as_echo "$lt_cv_prog_compiler_pic" >&6; } lt_prog_compiler_pic=$lt_cv_prog_compiler_pic # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } if ${lt_cv_prog_compiler_pic_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; } if test yes = "$lt_cv_prog_compiler_pic_works"; then case $lt_prog_compiler_pic in "" | " "*) ;; *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; esac else lt_prog_compiler_pic= lt_prog_compiler_can_build_shared=no fi fi # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } if ${lt_cv_prog_compiler_static_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_static_works=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works=yes fi else lt_cv_prog_compiler_static_works=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 $as_echo "$lt_cv_prog_compiler_static_works" >&6; } if test yes = "$lt_cv_prog_compiler_static_works"; then : else lt_prog_compiler_static= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } hard_links=nottested if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 $as_echo_n "checking if we can lock with hard links... " >&6; } hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 $as_echo "$hard_links" >&6; } if test no = "$hard_links"; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } runpath_var= allow_undefined_flag= always_export_symbols=no archive_cmds= archive_expsym_cmds= compiler_needs_object=no enable_shared_with_static_runtimes=no export_dynamic_flag_spec= export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' hardcode_automatic=no hardcode_direct=no hardcode_direct_absolute=no hardcode_libdir_flag_spec= hardcode_libdir_separator= hardcode_minus_L=no hardcode_shlibpath_var=unsupported inherit_rpath=no link_all_deplibs=unknown module_cmds= module_expsym_cmds= old_archive_from_new_cmds= old_archive_from_expsyms_cmds= thread_safe_flag_spec= whole_archive_flag_spec= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; esac ld_shlibs=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; *\ \(GNU\ Binutils\)\ [3-9]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' export_dynamic_flag_spec='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else whole_archive_flag_spec= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then allow_undefined_flag=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else ld_shlibs=no fi ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' export_dynamic_flag_spec='$wl--export-all-symbols' allow_undefined_flag=unsupported always_export_symbols=no enable_shared_with_static_runtimes=yes export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs=no fi ;; haiku*) archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' link_all_deplibs=yes ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes file_list_spec='@' ;; interix[3-9]*) hardcode_direct=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 whole_archive_flag_spec= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes ;; esac case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) export_dynamic_flag_spec='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else ld_shlibs=no fi ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac if test no = "$ld_shlibs"; then runpath_var= hardcode_libdir_flag_spec= export_dynamic_flag_spec= whole_archive_flag_spec= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag=unsupported always_export_symbols=yes archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct=unsupported fi ;; aix[4-9]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds='' hardcode_direct=yes hardcode_direct_absolute=yes hardcode_libdir_separator=':' link_all_deplibs=yes file_list_spec='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. hardcode_direct=no hardcode_direct_absolute=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L=yes hardcode_libdir_flag_spec='-L$libdir' hardcode_libdir_separator= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi export_dynamic_flag_spec='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag='-berok' # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath_+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib' allow_undefined_flag="-z nodefs" archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath_+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag=' $wl-bernotok' allow_undefined_flag=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec='$convenience' fi archive_cmds_need_lc=yes archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; bsdi[45]*) export_dynamic_flag_spec=-rdynamic ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl* | icl*) # Native MSVC or ICC hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported always_export_symbols=yes file_list_spec='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, )='true' enable_shared_with_static_runtimes=yes exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib old_postinstall_cmds='chmod 644 $oldlib' postlink_cmds='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC and ICC wrapper hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_from_new_cmds='true' # FIXME: Should let the user specify the lib program. old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' enable_shared_with_static_runtimes=yes ;; esac ;; darwin* | rhapsody*) archive_cmds_need_lc=no hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported if test yes = "$lt_cv_ld_force_load"; then whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' else whole_archive_flag_spec='' fi link_all_deplibs=yes allow_undefined_flag=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" archive_expsym_cmds="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" module_expsym_cmds="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" else ld_shlibs=no fi ;; dgux*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly* | midnightbsd*) archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; hpux9*) if test yes = "$GCC"; then archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes export_dynamic_flag_spec='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 $as_echo_n "checking if $CC understands -b... " >&6; } if ${lt_cv_prog_compiler__b+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler__b=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -b" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler__b=yes fi else lt_cv_prog_compiler__b=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 $as_echo "$lt_cv_prog_compiler__b" >&6; } if test yes = "$lt_cv_prog_compiler__b"; then archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi ;; esac fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: case $host_cpu in hppa*64*|ia64*) hardcode_direct=no hardcode_shlibpath_var=no ;; *) hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } if ${lt_cv_irix_exported_symbol+:} false; then : $as_echo_n "(cached) " >&6 else save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int foo (void) { return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_irix_exported_symbol=yes else lt_cv_irix_exported_symbol=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 $as_echo "$lt_cv_irix_exported_symbol" >&6; } if test yes = "$lt_cv_irix_exported_symbol"; then archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi else archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: inherit_rpath=yes link_all_deplibs=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler ld_shlibs=yes archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; newsos6) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: hardcode_shlibpath_var=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then hardcode_direct=yes hardcode_shlibpath_var=no hardcode_direct_absolute=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' else archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='$wl-rpath,$libdir' fi else ld_shlibs=no fi ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes file_list_spec='@' ;; osf3*) if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' fi archive_cmds_need_lc='no' hardcode_libdir_separator=: ;; solaris*) no_undefined_flag=' -z defs' if test yes = "$GCC"; then wlarc='$wl' archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi hardcode_libdir_flag_spec='-R$libdir' hardcode_shlibpath_var=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else whole_archive_flag_spec='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec='-L$libdir' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; sysv4) case $host_vendor in sni) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds='$CC -r -o $output$reload_objs' hardcode_direct=no ;; motorola) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var=no ;; sysv4.3*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no export_dynamic_flag_spec='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag='$wl-z,text' archive_cmds_need_lc=no hardcode_shlibpath_var=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag='$wl-z,text' allow_undefined_flag='$wl-z,nodefs' archive_cmds_need_lc=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-R,$libdir' hardcode_libdir_separator=':' link_all_deplibs=yes export_dynamic_flag_spec='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) export_dynamic_flag_spec='$wl-Blargedynsym' ;; esac fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 $as_echo "$ld_shlibs" >&6; } test no = "$ld_shlibs" && can_build_shared=no with_gnu_ld=$with_gnu_ld # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc" in x|xyes) # Assume -lc should be added archive_cmds_need_lc=yes if test yes,yes = "$GCC,$enable_shared"; then case $archive_cmds in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } if ${lt_cv_archive_cmds_need_lc+:} false; then : $as_echo_n "(cached) " >&6 else $RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl pic_flag=$lt_prog_compiler_pic compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag allow_undefined_flag= if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then lt_cv_archive_cmds_need_lc=no else lt_cv_archive_cmds_need_lc=yes fi allow_undefined_flag=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; } archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc ;; esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 $as_echo_n "checking dynamic linker characteristics... " >&6; } if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[lt_foo]++; } if (lt_freq[lt_foo] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([A-Za-z]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[4-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a(lib.so.V)' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | msys* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" ;; mingw* | cegcc* | msys*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl* | *,icl*) # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin* | msys*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[23].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[3-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. hardcode_libdir_flag_spec='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH if ${lt_cv_shlibpath_overrides_runpath+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : lt_cv_shlibpath_overrides_runpath=yes fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS libdir=$save_libdir fi shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 $as_echo "$dynamic_linker" >&6; } test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 $as_echo_n "checking how to hardcode library paths into programs... " >&6; } hardcode_action= if test -n "$hardcode_libdir_flag_spec" || test -n "$runpath_var" || test yes = "$hardcode_automatic"; then # We can hardcode non-existent directories. if test no != "$hardcode_direct" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" && test no != "$hardcode_minus_L"; then # Linking always hardcodes the temporary library directory. hardcode_action=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action=unsupported fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 $as_echo "$hardcode_action" >&6; } if test relink = "$hardcode_action" || test yes = "$inherit_rpath"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin* | msys*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 $as_echo_n "checking for dlopen in -ldl... " >&6; } if ${ac_cv_lib_dl_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dl_dlopen=yes else ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" if test "x$ac_cv_func_shl_load" = xyes; then : lt_cv_dlopen=shl_load else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 $as_echo_n "checking for shl_load in -ldld... " >&6; } if ${ac_cv_lib_dld_shl_load+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shl_load (); int main () { return shl_load (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dld_shl_load=yes else ac_cv_lib_dld_shl_load=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 $as_echo "$ac_cv_lib_dld_shl_load" >&6; } if test "x$ac_cv_lib_dld_shl_load" = xyes; then : lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld else ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" if test "x$ac_cv_func_dlopen" = xyes; then : lt_cv_dlopen=dlopen else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 $as_echo_n "checking for dlopen in -ldl... " >&6; } if ${ac_cv_lib_dl_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dl_dlopen=yes else ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 $as_echo_n "checking for dlopen in -lsvld... " >&6; } if ${ac_cv_lib_svld_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsvld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_svld_dlopen=yes else ac_cv_lib_svld_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 $as_echo "$ac_cv_lib_svld_dlopen" >&6; } if test "x$ac_cv_lib_svld_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 $as_echo_n "checking for dld_link in -ldld... " >&6; } if ${ac_cv_lib_dld_dld_link+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dld_link (); int main () { return dld_link (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dld_dld_link=yes else ac_cv_lib_dld_dld_link=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 $as_echo "$ac_cv_lib_dld_dld_link" >&6; } if test "x$ac_cv_lib_dld_dld_link" = xyes; then : lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld fi fi fi fi fi fi ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 $as_echo_n "checking whether a program can dlopen itself... " >&6; } if ${lt_cv_dlopen_self+:} false; then : $as_echo_n "(cached) " >&6 else if test yes = "$cross_compiling"; then : lt_cv_dlopen_self=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 $as_echo "$lt_cv_dlopen_self" >&6; } if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } if ${lt_cv_dlopen_self_static+:} false; then : $as_echo_n "(cached) " >&6 else if test yes = "$cross_compiling"; then : lt_cv_dlopen_self_static=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 $as_echo "$lt_cv_dlopen_self_static" >&6; } fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi striplib= old_striplib= { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 $as_echo_n "checking whether stripping libraries is possible... " >&6; } if test -z "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } else if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else case $host_os in darwin*) # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } ;; freebsd*) if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi ;; *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } ;; esac fi fi # Report what library types will actually be built { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 $as_echo_n "checking if libtool supports shared libraries... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 $as_echo "$can_build_shared" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 $as_echo_n "checking whether to build shared libraries... " >&6; } test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 $as_echo "$enable_shared" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 $as_echo_n "checking whether to build static libraries... " >&6; } # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 $as_echo "$enable_static" >&6; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC=$lt_save_CC ac_config_commands="$ac_config_commands libtool" # Only expand once: LIBTOOL='${top_builddir}/libtool' fi # # --- Checks for header files --- # # NOTE: if --with-libtool is specified, stdc header isn't detected. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi for ac_header in langinfo.h dlfcn.h dl.h stropts.h sys/stropts.h stdint.h windows.h errno.h stdint.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done # # --- Checks for library functions --- # for ac_func in strsep fgetln basename isastream seteuid setegid geteuid getegid setsid snprintf usleep setenv unsetenv flock getuid getgid getpwuid recvmsg setpgid socketpair killpg gettimeofday do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" if test "x$ac_cv_type_size_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define size_t unsigned int _ACEOF fi # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 $as_echo_n "checking for working alloca.h... " >&6; } if ${ac_cv_working_alloca_h+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { char *p = (char *) alloca (2 * sizeof (int)); if (p) return 0; ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_working_alloca_h=yes else ac_cv_working_alloca_h=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 $as_echo "$ac_cv_working_alloca_h" >&6; } if test $ac_cv_working_alloca_h = yes; then $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 $as_echo_n "checking for alloca... " >&6; } if ${ac_cv_func_alloca_works+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __GNUC__ # define alloca __builtin_alloca #else # ifdef _MSC_VER # include # define alloca _alloca # elif defined(__NetBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(__OpenBSD__) # include # else # ifdef HAVE_ALLOCA_H # include # else # ifdef _AIX #pragma alloca # else # ifndef alloca /* predefined by HP cc +Olibcalls */ void *alloca (size_t); # endif # endif # endif # endif #endif int main () { char *p = (char *) alloca (1); if (p) return 0; ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_func_alloca_works=yes else ac_cv_func_alloca_works=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 $as_echo "$ac_cv_func_alloca_works" >&6; } if test $ac_cv_func_alloca_works = yes; then $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h else # The SVR3 libPW and SVR4 libucb both contain incompatible functions # that cause trouble. Some versions do not even contain alloca or # contain a buggy version. If you still want to use their alloca, # use ar to extract alloca.o from them instead of compiling alloca.c. ALLOCA=\${LIBOBJDIR}alloca.$ac_objext $as_echo "#define C_ALLOCA 1" >>confdefs.h { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } if ${ac_cv_os_cray+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined CRAY && ! defined CRAY2 webecray #else wenotbecray #endif _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "webecray" >/dev/null 2>&1; then : ac_cv_os_cray=yes else ac_cv_os_cray=no fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 $as_echo "$ac_cv_os_cray" >&6; } if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define CRAY_STACKSEG_END $ac_func _ACEOF break fi done fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 $as_echo_n "checking stack direction for C alloca... " >&6; } if ${ac_cv_c_stack_direction+:} false; then : $as_echo_n "(cached) " >&6 else if test "$cross_compiling" = yes; then : ac_cv_c_stack_direction=0 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int find_stack_direction (int *addr, int depth) { int dir, dummy = 0; if (! addr) addr = &dummy; *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; dir = depth ? find_stack_direction (addr, depth - 1) : 0; return dir + dummy; } int main (int argc, char **argv) { return find_stack_direction (0, argc + !argv + 20) < 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_c_stack_direction=1 else ac_cv_c_stack_direction=-1 fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 $as_echo "$ac_cv_c_stack_direction" >&6; } cat >>confdefs.h <<_ACEOF #define STACK_DIRECTION $ac_cv_c_stack_direction _ACEOF fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 $as_echo_n "checking for inline... " >&6; } if ${ac_cv_c_inline+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; static $ac_kw foo_t static_foo () {return 0; } $ac_kw foo_t foo () {return 0; } #endif _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_inline=$ac_kw fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_inline" != no && break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 $as_echo "$ac_cv_c_inline" >&6; } case $ac_cv_c_inline in inline | yes) ;; *) case $ac_cv_c_inline in no) ac_val=;; *) ac_val=$ac_cv_c_inline;; esac cat >>confdefs.h <<_ACEOF #ifndef __cplusplus #define inline $ac_val #endif _ACEOF ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 $as_echo_n "checking for an ANSI C-conforming const... " >&6; } if ${ac_cv_c_const+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __cplusplus /* Ultrix mips cc rejects this sort of thing. */ typedef int charset[2]; const charset cs = { 0, 0 }; /* SunOS 4.1.1 cc rejects this. */ char const *const *pcpcc; char **ppc; /* NEC SVR4.0.2 mips cc rejects this. */ struct point {int x, y;}; static struct point const zero = {0,0}; /* AIX XL C 1.02.0.0 rejects this. It does not let you subtract one const X* pointer from another in an arm of an if-expression whose if-part is not a constant expression */ const char *g = "string"; pcpcc = &g + (g ? g-g : 0); /* HPUX 7.0 cc rejects these. */ ++pcpcc; ppc = (char**) pcpcc; pcpcc = (char const *const *) ppc; { /* SCO 3.2v4 cc rejects this sort of thing. */ char tx; char *t = &tx; char const *s = 0 ? (char *) 0 : (char const *) 0; *t++ = 0; if (s) return 0; } { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ int x[] = {25, 17}; const int *foo = &x[0]; ++foo; } { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ typedef const int *iptr; iptr p = 0; ++p; } { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ struct s { int j; const int *ap[3]; } bx; struct s *b = &bx; b->j = 5; } { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ const int foo = 10; if (!foo) return 0; } return !cs[0] && !zero.x; #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_const=yes else ac_cv_c_const=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 $as_echo "$ac_cv_c_const" >&6; } if test $ac_cv_c_const = no; then $as_echo "#define const /**/" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } if ${ac_cv_c_bigendian+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_bigendian=unknown # See if we're dealing with a universal compiler. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __APPLE_CC__ not a universal capable compiler #endif typedef int dummy; _ACEOF if ac_fn_c_try_compile "$LINENO"; then : # Check for potential -arch flags. It is not universal unless # there are at least two -arch flags with different values. ac_arch= ac_prev= for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do if test -n "$ac_prev"; then case $ac_word in i?86 | x86_64 | ppc | ppc64) if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then ac_arch=$ac_word else ac_cv_c_bigendian=universal break fi ;; esac ac_prev= elif test "x$ac_word" = "x-arch"; then ac_prev=arch fi done fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_c_bigendian = unknown; then # See if sys/param.h defines the BYTE_ORDER macro. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ && LITTLE_ENDIAN) bogus endian macros #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : # It does; now see whether it defined to BIG_ENDIAN or not. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { #if BYTE_ORDER != BIG_ENDIAN not big endian #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_bigendian=yes else ac_cv_c_bigendian=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi if test $ac_cv_c_bigendian = unknown; then # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) bogus endian macros #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : # It does; now see whether it defined to _BIG_ENDIAN or not. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { #ifndef _BIG_ENDIAN not big endian #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_bigendian=yes else ac_cv_c_bigendian=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi if test $ac_cv_c_bigendian = unknown; then # Compile a test program. if test "$cross_compiling" = yes; then : # Try to guess by grepping values from an object file. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; int use_ascii (int i) { return ascii_mm[i] + ascii_ii[i]; } short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; int use_ebcdic (int i) { return ebcdic_mm[i] + ebcdic_ii[i]; } extern int foo; int main () { return use_ascii (foo) == use_ebcdic (foo); ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then ac_cv_c_bigendian=yes fi if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then if test "$ac_cv_c_bigendian" = unknown; then ac_cv_c_bigendian=no else # finding both strings is unlikely to happen, but who knows? ac_cv_c_bigendian=unknown fi fi fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int main () { /* Are we little or big endian? From Harbison&Steele. */ union { long int l; char c[sizeof (long int)]; } u; u.l = 1; return u.c[sizeof (long int) - 1] == 1; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_c_bigendian=no else ac_cv_c_bigendian=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 $as_echo "$ac_cv_c_bigendian" >&6; } case $ac_cv_c_bigendian in #( yes) $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h ;; #( no) ;; #( universal) $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h ;; #( *) as_fn_error $? "unknown endianness presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; esac # Check whether --enable-largefile was given. if test "${enable_largefile+set}" = set; then : enableval=$enable_largefile; fi if test "$enable_largefile" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 $as_echo_n "checking for special C compiler options needed for large files... " >&6; } if ${ac_cv_sys_largefile_CC+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_sys_largefile_CC=no if test "$GCC" != yes; then ac_save_CC=$CC while :; do # IRIX 6.2 and later do not support large files by default, # so use the C compiler's -n32 option if that helps. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : break fi rm -f core conftest.err conftest.$ac_objext CC="$CC -n32" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_largefile_CC=' -n32'; break fi rm -f core conftest.err conftest.$ac_objext break done CC=$ac_save_CC rm -f conftest.$ac_ext fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 $as_echo "$ac_cv_sys_largefile_CC" >&6; } if test "$ac_cv_sys_largefile_CC" != no; then CC=$CC$ac_cv_sys_largefile_CC fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } if ${ac_cv_sys_file_offset_bits+:} false; then : $as_echo_n "(cached) " >&6 else while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_file_offset_bits=no; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _FILE_OFFSET_BITS 64 #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_file_offset_bits=64; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_sys_file_offset_bits=unknown break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 $as_echo "$ac_cv_sys_file_offset_bits" >&6; } case $ac_cv_sys_file_offset_bits in #( no | unknown) ;; *) cat >>confdefs.h <<_ACEOF #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits _ACEOF ;; esac rm -rf conftest* if test $ac_cv_sys_file_offset_bits = unknown; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } if ${ac_cv_sys_large_files+:} false; then : $as_echo_n "(cached) " >&6 else while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_large_files=no; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _LARGE_FILES 1 #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_large_files=1; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_sys_large_files=unknown break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 $as_echo "$ac_cv_sys_large_files" >&6; } case $ac_cv_sys_large_files in #( no | unknown) ;; *) cat >>confdefs.h <<_ACEOF #define _LARGE_FILES $ac_cv_sys_large_files _ACEOF ;; esac rm -rf conftest* fi fi # for OpenServer 6.0.0 ac_fn_c_check_header_mongrel "$LINENO" "sys/bitypes.h" "ac_cv_header_sys_bitypes_h" "$ac_includes_default" if test "x$ac_cv_header_sys_bitypes_h" = xyes; then : ac_includes_default="\ $ac_includes_default #include " HAVE_SYS_BITYPES_H=1 $as_echo "#define HAVE_SYS_BITYPES_H 1" >>confdefs.h fi ac_fn_c_check_type "$LINENO" "u_char" "ac_cv_type_u_char" "$ac_includes_default" if test "x$ac_cv_type_u_char" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_char unsigned char _ACEOF fi ac_fn_c_check_type "$LINENO" "u_short" "ac_cv_type_u_short" "$ac_includes_default" if test "x$ac_cv_type_u_short" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_short unsigned short _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int" "ac_cv_type_u_int" "$ac_includes_default" if test "x$ac_cv_type_u_int" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int unsigned int _ACEOF fi ac_fn_c_check_type "$LINENO" "u_long" "ac_cv_type_u_long" "$ac_includes_default" if test "x$ac_cv_type_u_long" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_long unsigned long _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int8_t" "ac_cv_type_u_int8_t" "$ac_includes_default" if test "x$ac_cv_type_u_int8_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int8_t unsigned char _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int16_t" "ac_cv_type_u_int16_t" "$ac_includes_default" if test "x$ac_cv_type_u_int16_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int16_t unsigned short _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" "$ac_includes_default" if test "x$ac_cv_type_u_int32_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int32_t unsigned int _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int64_t" "ac_cv_type_u_int64_t" "$ac_includes_default" if test "x$ac_cv_type_u_int64_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int64_t unsigned long _ACEOF fi ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" if test "x$ac_cv_type_int8_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int8_t char _ACEOF fi ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" if test "x$ac_cv_type_int16_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int16_t short _ACEOF fi ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" if test "x$ac_cv_type_int32_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int32_t int _ACEOF fi ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default" if test "x$ac_cv_type_int64_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int64_t long _ACEOF fi ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" if test "x$ac_cv_type_ssize_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define ssize_t int _ACEOF fi ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" if test "x$ac_cv_type_mode_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define mode_t int _ACEOF fi ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" if test "x$ac_cv_type_pid_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define pid_t int _ACEOF fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 $as_echo_n "checking for uid_t in sys/types.h... " >&6; } if ${ac_cv_type_uid_t+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "uid_t" >/dev/null 2>&1; then : ac_cv_type_uid_t=yes else ac_cv_type_uid_t=no fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 $as_echo "$ac_cv_type_uid_t" >&6; } if test $ac_cv_type_uid_t = no; then $as_echo "#define uid_t int" >>confdefs.h $as_echo "#define gid_t int" >>confdefs.h fi ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" if test "x$ac_cv_type_off_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define off_t long int _ACEOF fi ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" if test "x$ac_cv_type_size_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define size_t unsigned int _ACEOF fi # # --- Platform dependent stuff --- # bl_cv_cygwin=no bl_cv_mingw=no bl_cv_win32=no case "${host_os}" in cygwin*) bl_cv_cygwin=yes case "${CC} ${CFLAGS}" in *mno-cygwin* | *-mingw*) bl_cv_win32=yes $as_echo "#define USE_WIN32API /**/" >>confdefs.h ;; *) ;; esac ;; mingw*) bl_cv_mingw=yes if test ! -f "/lib/libmsys-1.0.dll.a" ; then case "${lt_cv_path_LD}" in *-msys*) ;; *) bl_cv_win32=yes $as_echo "#define USE_WIN32API /**/" >>confdefs.h ;; esac fi ;; *) ;; esac # # --- socklen_t --- # # NOTE: #define _BSDTYPES_DEFINED is necessary because AC_TRY_COMPILE defines # u_char, u_short and so on before #include . # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5 $as_echo_n "checking for socklen_t... " >&6; } if ${bl_cv_socklen_ident+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include int main () { socklen_t len ; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : bl_cv_socklen_ident=yes else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _BSDTYPES_DEFINED #include int main () { socklen_t len ; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : bl_cv_socklen_ident=yes else bl_cv_socklen_ident=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bl_cv_socklen_ident" >&5 $as_echo "$bl_cv_socklen_ident" >&6; } if test "${bl_cv_socklen_ident}" = "no" ; then $as_echo "#define socklen_t unsigned int" >>confdefs.h fi # # --- Check if concatenation of string literals with __FUNCTION__ is supported. --- # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __FUNCTION__" >&5 $as_echo_n "checking for __FUNCTION__... " >&6; } if ${bl_cv_func_ident+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { char * p = "[" __FUNCTION__ "]" ; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : bl_cv_func_ident=yes else bl_cv_func_ident=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bl_cv_func_ident" >&5 $as_echo "$bl_cv_func_ident" >&6; } if test "${bl_cv_func_ident}" = "yes" ; then $as_echo "#define CONCATABLE_FUNCTION /**/" >>confdefs.h fi # # --- Check for libxpg4 (for FreeBSD) --- # for ac_func in setlocale do : ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale" if test "x$ac_cv_func_setlocale" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SETLOCALE 1 _ACEOF fi done if test "x$ac_cv_func_setlocale" = xno ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setlocale in -lxpg4" >&5 $as_echo_n "checking for setlocale in -lxpg4... " >&6; } if ${ac_cv_lib_xpg4_setlocale+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lxpg4 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char setlocale (); int main () { return setlocale (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_xpg4_setlocale=yes else ac_cv_lib_xpg4_setlocale=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xpg4_setlocale" >&5 $as_echo "$ac_cv_lib_xpg4_setlocale" >&6; } if test "x$ac_cv_lib_xpg4_setlocale" = xyes; then : XPG4_LIBS=-lxpg4 fi fi # # --- Checks for dynamic linking loader --- # DL_LOADER=none DL_LIBS= DL_CFLAGS= # lt_dlopenext in libltdl # Check whether --with-libltdl was given. if test "${with_libltdl+set}" = set; then : withval=$with_libltdl; else with_libltdl=no fi if test "x$with_libltdl" != "xno" ; then if test "x$with_libltdl" != "xyes"; then DL_CFLAGS="-I$with_libltdl/include" bl_libltdl_libdir="-L$with_libltdl/lib" fi bl_ldflags_save="$LDFLAGS" LDFLAGS="$LDFLAGS $bl_libltdl_libdir" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lt_dlopenext in -lltdl" >&5 $as_echo_n "checking for lt_dlopenext in -lltdl... " >&6; } if ${ac_cv_lib_ltdl_lt_dlopenext+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lltdl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char lt_dlopenext (); int main () { return lt_dlopenext (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ltdl_lt_dlopenext=yes else ac_cv_lib_ltdl_lt_dlopenext=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ltdl_lt_dlopenext" >&5 $as_echo "$ac_cv_lib_ltdl_lt_dlopenext" >&6; } if test "x$ac_cv_lib_ltdl_lt_dlopenext" = xyes; then : DL_LOADER=ltdl DL_LIBS="$bl_libltdl_libdir -lltdl" else echo "" echo "Could not find libltdl" echo "" exit 1 fi LDFLAGS="$bl_ldflags_save" fi # lt_cv_dlopen is set by AC_LIBTOOL_DLOPEN if test "$DL_LOADER" = none ; then case "${lt_cv_dlopen}" in # LoadLibrary (Windows) LoadLibrary) DL_LOADER=win32 ;; # shl_load (HP-UX) shl_load) DL_LOADER=dld ;; # dlopen (UNIX98) dlopen) DL_LOADER=dl ;; # What is dld_link? Does anybody know? dld_link) DL_LOADER=none ;; *) DL_LOADER=none ;; esac DL_LIBS="${DL_LIBS} ${lt_cv_dlopen_libs}" if test "$DL_LOADER" = none ; then # NSLinkModule (darwin) ac_fn_c_check_func "$LINENO" "NSLinkModule" "ac_cv_func_NSLinkModule" if test "x$ac_cv_func_NSLinkModule" = xyes; then : DL_LOADER=dyld DL_LIBS= fi fi # cygwin hack # (AC_LIBTOOL_DLOPEN tell lt_cv_dlopen == dlopen but use bl_dlcfn_win32.c.) # On msys2, use dlopen because bl_dlfcn_win32 doesn't work correctly. if test "$bl_cv_cygwin" = "yes"; then DL_LOADER=win32 fi fi if test "$DL_LOADER" = none ; then $as_echo "#define DLFCN_NONE /**/" >>confdefs.h fi # # --- check for undefined symbol --- # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for undefined symbol" >&5 $as_echo_n "checking for undefined symbol... " >&6; } if test "x$allow_undefined_flag" = "xunsupported" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: not supported" >&5 $as_echo "not supported" >&6; } NO_UNDEFINED_FLAG="-no-undefined" else { $as_echo "$as_me:${as_lineno-$LINENO}: result: supported" >&5 $as_echo "supported" >&6; } NO_UNDEFINED_FLAG="" fi # # --- pty check --- # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pty/tty type" >&5 $as_echo_n "checking for pty/tty type... " >&6; } if test "$bl_cv_win32" = "yes" ; then bl_cv_pty=none elif test "$bl_cv_mingw" = "yes" ; then bl_cv_pty=streams elif test "$host" = "$build" ; then ac_fn_c_check_func "$LINENO" "posix_openpt" "ac_cv_func_posix_openpt" if test "x$ac_cv_func_posix_openpt" = xyes; then : if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run test program while cross compiling See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return posix_openpt(O_RDWR | O_NOCTTY) == -1; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : $as_echo "#define HAVE_POSIX_OPENPT /**/" >>confdefs.h bl_cv_pty=streams else bl_cv_pty=bsd fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi else bl_cv_pty=bsd fi if test "$bl_cv_pty" = "bsd" ; then if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run test program while cross compiling See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return open( "/dev/ptmx", O_RDWR | O_NOCTTY, 0) == -1; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : bl_cv_pty=streams fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi else # cross compiling ac_fn_c_check_func "$LINENO" "posix_openpt" "ac_cv_func_posix_openpt" if test "x$ac_cv_func_posix_openpt" = xyes; then : $as_echo "#define HAVE_POSIX_OPENPT /**/" >>confdefs.h bl_cv_pty=streams else bl_cv_pty=bsd fi fi # Check whether --enable-pty_helper was given. if test "${enable_pty_helper+set}" = set; then : enableval=$enable_pty_helper; pty_helper=$enable_pty_helper fi if test "$pty_helper" = yes ; then if test "$bl_cv_pty" = streams ; then bl_cv_pty=helper else echo "" echo "** WARNING **" echo " pty helper is not supported in bsd-style pty system." echo "" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bl_cv_pty" >&5 $as_echo "$bl_cv_pty" >&6; } PTY_NAME="${bl_cv_pty}" # # --- checks for utmp --- # # Check whether --with-utmp was given. if test "${with_utmp+set}" = set; then : withval=$with_utmp; utmp_type=$with_utmp fi UTMP_NAME= UTMP_LIBS= if test "$bl_cv_pty" = helper -o "$bl_cv_mingw" = yes -o "$bl_cv_cygwin" = yes -o "$host_os" = "msys" -o "$host_os" = "haiku"; then UTMP_NAME=none UTMP_LIBS= fi # libutempter if test "$utmp_type" = "" -o "$utmp_type" = "utempter"; then if test -z "$UTMP_NAME"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for utempter_add_record in -lutempter" >&5 $as_echo_n "checking for utempter_add_record in -lutempter... " >&6; } if ${ac_cv_lib_utempter_utempter_add_record+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lutempter $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char utempter_add_record (); int main () { return utempter_add_record (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_utempter_utempter_add_record=yes else ac_cv_lib_utempter_utempter_add_record=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_utempter_utempter_add_record" >&5 $as_echo "$ac_cv_lib_utempter_utempter_add_record" >&6; } if test "x$ac_cv_lib_utempter_utempter_add_record" = xyes; then : UTMP_NAME=utmper UTMP_LIBS="-lutempter" UTMP_CFLAGS="-DUTEMPTER_NEW_API" fi fi if test -z "$UTMP_NAME"; then # FreeBSD { $as_echo "$as_me:${as_lineno-$LINENO}: checking for utempter_add_record in -lulog" >&5 $as_echo_n "checking for utempter_add_record in -lulog... " >&6; } if ${ac_cv_lib_ulog_utempter_add_record+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lulog $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char utempter_add_record (); int main () { return utempter_add_record (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ulog_utempter_add_record=yes else ac_cv_lib_ulog_utempter_add_record=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ulog_utempter_add_record" >&5 $as_echo "$ac_cv_lib_ulog_utempter_add_record" >&6; } if test "x$ac_cv_lib_ulog_utempter_add_record" = xyes; then : UTMP_NAME=utmper UTMP_LIBS="-lulog" UTMP_CFLAGS="-DUTEMPTER_NEW_API" fi fi if test -z "$UTMP_NAME" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addToUtmp in -lutempter" >&5 $as_echo_n "checking for addToUtmp in -lutempter... " >&6; } if ${ac_cv_lib_utempter_addToUtmp+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lutempter $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char addToUtmp (); int main () { return addToUtmp (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_utempter_addToUtmp=yes else ac_cv_lib_utempter_addToUtmp=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_utempter_addToUtmp" >&5 $as_echo "$ac_cv_lib_utempter_addToUtmp" >&6; } if test "x$ac_cv_lib_utempter_addToUtmp" = xyes; then : UTMP_NAME=utmper UTMP_LIBS="-lutempter -lutil" fi fi fi # setutxent() (SysV) if test "$utmp_type" = "" -o "$utmp_type" = "sysv"; then if test -z "$UTMP_NAME"; then ac_fn_c_check_func "$LINENO" "setutxent" "ac_cv_func_setutxent" if test "x$ac_cv_func_setutxent" = xyes; then : UTMP_NAME=sysv UTMP_LIBS= UTMP_CFLAGS=-DUSE_UTMPX fi fi # setutent() (SysV) if test -z "$UTMP_NAME"; then ac_fn_c_check_func "$LINENO" "setutent" "ac_cv_func_setutent" if test "x$ac_cv_func_setutent" = xyes; then : UTMP_NAME=sysv UTMP_LIBS= fi fi fi # libutil if test "$utmp_type" = "" -o "$utmp_type" = "login"; then if test -z "$UTMP_NAME" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for logout in -lutil" >&5 $as_echo_n "checking for logout in -lutil... " >&6; } if ${ac_cv_lib_util_logout+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lutil $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char logout (); int main () { return logout (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_util_logout=yes else ac_cv_lib_util_logout=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_logout" >&5 $as_echo "$ac_cv_lib_util_logout" >&6; } if test "x$ac_cv_lib_util_logout" = xyes; then : UTMP_NAME=login UTMP_LIBS=-lutil fi fi fi # other (BSD) if test "$utmp_type" = "" -o "$utmp_type" = "bsd"; then if test -z "$UTMP_NAME" ; then UTMP_NAME=bsd UTMP_LIBS= fi fi if test -z "$UTMP_NAME" ; then UTMP_NAME=none UTMP_LIBS= fi # # --- remove functions mlterm doesn't use --- # # Check whether --with-funcs-mlterm-unuse was given. if test "${with_funcs_mlterm_unuse+set}" = set; then : withval=$with_funcs_mlterm_unuse; funcs_mlterm_unuse=$with_funcs_mlterm_unuse else funcs_mlterm_unuse="yes" fi if test "$funcs_mlterm_unuse" = "no" ; then $as_echo "#define REMOVE_FUNCS_MLTERM_UNUSE /**/" >>confdefs.h fi # # --- check for malloc --- # if test "$host" = "$build"; then if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run test program while cross compiling See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main() { return calloc(8, ((1 << (sizeof(size_t) * 8 - 1)) + 1)) ? 1 : 0 ; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : $as_echo "#define CALLOC_CHECK_OVERFLOW 1" >>confdefs.h fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi ac_config_files="$ac_config_files Makefile src/Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then if test "x$cache_file" != "x/dev/null"; then { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} if test ! -f "$cache_file" || test -h "$cache_file"; then cat confcache >"$cache_file" else case $cache_file in #( */* | ?:*) mv -f confcache "$cache_file"$$ && mv -f "$cache_file"$$ "$cache_file" ;; #( *) mv -f confcache "$cache_file" ;; esac fi fi else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= U= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`$as_echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs : "${CONFIG_STATUS=./config.status}" ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 ## ----------------------------------- ## ## Main body of $CONFIG_STATUS script. ## ## ----------------------------------- ## _ASEOF test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by $as_me, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac case $ac_config_headers in *" "*) set x $ac_config_headers; shift; ac_config_headers=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to the package provider." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ config.status configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" Copyright (C) 2012 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' AWK='$AWK' test -n "\$AWK" || AWK=awk _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 do case $1 in --*=?*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; --*=) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg= ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) $as_echo "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) $as_echo "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; '') as_fn_error $? "missing file argument" ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_HEADERS " '$ac_optarg'" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header as_fn_error $? "ambiguous option: \`$1' Try \`$0 --help' for more information.";; --help | --hel | -h ) $as_echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) as_fn_error $? "unrecognized option: \`$1' Try \`$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX $as_echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`' DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`' SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' FILECMD='`$ECHO "$FILECMD" | $SED "$delay_single_quote_subst"`' deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' lt_ar_flags='`$ECHO "$lt_ar_flags" | $SED "$delay_single_quote_subst"`' AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`' nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`' objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`' configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`' hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$1 _LTECHO_EOF' } # Quote evaled strings. for var in AS \ DLLTOOL \ OBJDUMP \ SHELL \ ECHO \ PATH_SEPARATOR \ SED \ GREP \ EGREP \ FGREP \ LD \ NM \ LN_S \ lt_SP2NL \ lt_NL2SP \ reload_flag \ FILECMD \ deplibs_check_method \ file_magic_cmd \ file_magic_glob \ want_nocaseglob \ sharedlib_from_linklib_cmd \ AR \ archiver_list_spec \ STRIP \ RANLIB \ CC \ CFLAGS \ compiler \ lt_cv_sys_global_symbol_pipe \ lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_import \ lt_cv_sys_global_symbol_to_c_name_address \ lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ lt_cv_nm_interface \ nm_file_list_spec \ lt_cv_truncate_bin \ lt_prog_compiler_no_builtin_flag \ lt_prog_compiler_pic \ lt_prog_compiler_wl \ lt_prog_compiler_static \ lt_cv_prog_compiler_c_o \ need_locks \ MANIFEST_TOOL \ DSYMUTIL \ NMEDIT \ LIPO \ OTOOL \ OTOOL64 \ shrext_cmds \ export_dynamic_flag_spec \ whole_archive_flag_spec \ compiler_needs_object \ with_gnu_ld \ allow_undefined_flag \ no_undefined_flag \ hardcode_libdir_flag_spec \ hardcode_libdir_separator \ exclude_expsyms \ include_expsyms \ file_list_spec \ variables_saved_for_relink \ libname_spec \ library_names_spec \ soname_spec \ install_override_mode \ finish_eval \ old_striplib \ striplib; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in reload_cmds \ old_postinstall_cmds \ old_postuninstall_cmds \ old_archive_cmds \ extract_expsyms_cmds \ old_archive_from_new_cmds \ old_archive_from_expsyms_cmds \ archive_cmds \ archive_expsym_cmds \ module_cmds \ module_expsym_cmds \ export_symbols_cmds \ prelink_cmds \ postlink_cmds \ postinstall_cmds \ postuninstall_cmds \ finish_cmds \ sys_lib_search_path_spec \ configure_time_dlsearch_path \ configure_time_lt_sys_library_path; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done ac_aux_dir='$ac_aux_dir' # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile' _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "src/bl_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/bl_config.h" ;; "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= ac_tmp= trap 'exit_status=$? : "${ac_tmp:=$tmp}" { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status ' 0 trap 'as_fn_exit 1' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. # This happens for instance with `./config.status config.h'. if test -n "$CONFIG_FILES"; then ac_cr=`echo X | tr X '\015'` # On cygwin, bash can eat \r inside `` if the user requested igncr. # But we know of no other shell where ac_cr would be empty at this # point, so we can use a bashism as a fallback. if test "x$ac_cr" = x; then eval ac_cr=\$\'\\r\' fi ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then ac_cs_awk_cr='\\r' else ac_cs_awk_cr=$ac_cr fi echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF { echo "cat >conf$$subs.awk <<_ACEOF" && echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && echo "_ACEOF" } >conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h s/^/S["/; s/!.*/"]=/ p g s/^[^!]*!// :repl t repl s/'"$ac_delim"'$// t delim :nl h s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p n b repl :more1 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t nl :delim h s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p b :more2 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t delim ' >$CONFIG_STATUS || ac_write_fail=1 rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" } { line = $ 0 nfields = split(line, field, "@") substed = 0 len = length(field[1]) for (i = 2; i < nfields; i++) { key = field[i] keylen = length(key) if (S_is_set[key]) { value = S[key] line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) len += length(value) + length(field[++i]) substed = 1 } else len += 1 + keylen } print line } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF # VPATH may cause trouble with some makes, so we remove sole $(srcdir), # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ h s/// s/^/:/ s/[ ]*$/:/ s/:\$(srcdir):/:/g s/:\${srcdir}:/:/g s/:@srcdir@:/:/g s/^:*// s/:*$// x s/\(=[ ]*\).*/\1/ G s/\n// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" # Set up the scripts for CONFIG_HEADERS section. # No need to generate them if there are no CONFIG_HEADERS. # This happens for instance with `./config.status Makefile'. if test -n "$CONFIG_HEADERS"; then cat >"$ac_tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF # Transform confdefs.h into an awk script `defines.awk', embedded as # here-document in config.status, that substitutes the proper values into # config.h.in to produce config.h. # Create a delimiter string that does not exist in confdefs.h, to ease # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do ac_tt=`sed -n "/$ac_delim/p" confdefs.h` if test -z "$ac_tt"; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done # For the awk script, D is an array of macro values keyed by name, # likewise P contains macro parameters if any. Preserve backslash # newline sequences. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* sed -n ' s/.\{148\}/&'"$ac_delim"'/g t rset :rset s/^[ ]*#[ ]*define[ ][ ]*/ / t def d :def s/\\$// t bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3"/p s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p d :bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3\\\\\\n"\\/p t cont s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p t cont d :cont n s/.\{148\}/&'"$ac_delim"'/g t clear :clear s/\\$// t bsnlc s/["\\]/\\&/g; s/^/"/; s/$/"/p d :bsnlc s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p b cont ' >$CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 for (key in D) D_is_set[key] = 1 FS = "" } /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { line = \$ 0 split(line, arg, " ") if (arg[1] == "#") { defundef = arg[2] mac1 = arg[3] } else { defundef = substr(arg[1], 2) mac1 = arg[2] } split(mac1, mac2, "(") #) macro = mac2[1] prefix = substr(line, 1, index(line, defundef) - 1) if (D_is_set[macro]) { # Preserve the white space surrounding the "#". print prefix "define", macro P[macro] D[macro] next } else { # Replace #undef with comments. This is necessary, for example, # in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. if (defundef == "undef") { print "/*", prefix defundef, macro, "*/" next } } } { print } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 fi # test -n "$CONFIG_HEADERS" eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" shift for ac_tag do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$ac_tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`$as_echo "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$ac_tmp/stdin" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= ac_sed_dataroot=' /datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@top_build_prefix@&$ac_top_build_prefix&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t $ac_datarootdir_hack " eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ "$ac_tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&2;} rm -f "$ac_tmp/stdin" case $ac_file in -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; esac \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; :H) # # CONFIG_HEADER # if test x"$ac_file" != x-; then { $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" } >"$ac_tmp/config.h" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" mv "$ac_tmp/config.h" "$ac_file" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ || as_fn_error $? "could not create -" "$LINENO" 5 fi ;; :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "libtool":C) # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # The names of the tagged configurations supported by this script. available_tags='' # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG # Assembler program. AS=$lt_AS # DLL creation program. DLLTOOL=$lt_DLLTOOL # Object dumper program. OBJDUMP=$lt_OBJDUMP # Which release of libtool.m4 was used? macro_version=$macro_version macro_revision=$macro_revision # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # What type of objects to build. pic_mode=$pic_mode # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # Shared archive member basename,for filename based shared library versioning on AIX. shared_archive_member_spec=$shared_archive_member_spec # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # An echo program that protects backslashes. ECHO=$lt_ECHO # The PATH separator for the build system. PATH_SEPARATOR=$lt_PATH_SEPARATOR # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # A sed program that does not truncate output. SED=$lt_SED # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="\$SED -e 1s/^X//" # A grep program that handles long lines. GREP=$lt_GREP # An ERE matcher. EGREP=$lt_EGREP # A literal string matcher. FGREP=$lt_FGREP # A BSD- or MS-compatible name lister. NM=$lt_NM # Whether we need soft or hard links. LN_S=$lt_LN_S # What is the maximum length of a command? max_cmd_len=$max_cmd_len # Object file suffix (normally "o"). objext=$ac_objext # Executable file suffix (normally ""). exeext=$exeext # whether the shell understands "unset". lt_unset=$lt_unset # turn spaces into newlines. SP2NL=$lt_lt_SP2NL # turn newlines into spaces. NL2SP=$lt_lt_NL2SP # convert \$build file names to \$host format. to_host_file_cmd=$lt_cv_to_host_file_cmd # convert \$build files to toolchain format. to_tool_file_cmd=$lt_cv_to_tool_file_cmd # A file(cmd) program that detects file types. FILECMD=$lt_FILECMD # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method = "file_magic". file_magic_cmd=$lt_file_magic_cmd # How to find potential files when deplibs_check_method = "file_magic". file_magic_glob=$lt_file_magic_glob # Find potential files using nocaseglob when deplibs_check_method = "file_magic". want_nocaseglob=$lt_want_nocaseglob # Command to associate shared and link libraries. sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd # The archiver. AR=$lt_AR # Flags to create an archive (by configure). lt_ar_flags=$lt_ar_flags # Flags to create an archive. AR_FLAGS=\${ARFLAGS-"\$lt_ar_flags"} # How to feed a file listing to the archiver. archiver_list_spec=$lt_archiver_list_spec # A symbol stripping program. STRIP=$lt_STRIP # Commands used to install an old-style archive. RANLIB=$lt_RANLIB old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Whether to use a lock for old archive extraction. lock_old_archive_extraction=$lock_old_archive_extraction # A C compiler. LTCC=$lt_CC # LTCC compiler flags. LTCFLAGS=$lt_CFLAGS # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration. global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm into a list of symbols to manually relocate. global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import # Transform the output of nm in a C name address pair. global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # Transform the output of nm in a C name address pair when lib prefix is needed. global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix # The name lister interface. nm_interface=$lt_lt_cv_nm_interface # Specify filename containing input files for \$NM. nm_file_list_spec=$lt_nm_file_list_spec # The root where to search for dependent libraries,and where our libraries should be installed. lt_sysroot=$lt_sysroot # Command to truncate a binary pipe. lt_truncate_bin=$lt_lt_cv_truncate_bin # The name of the directory that contains temporary libtool files. objdir=$objdir # Used to examine libraries when file_magic_cmd begins with "file". MAGIC_CMD=$MAGIC_CMD # Must we lock files when doing compilation? need_locks=$lt_need_locks # Manifest tool. MANIFEST_TOOL=$lt_MANIFEST_TOOL # Tool to manipulate archived DWARF debug symbol files on Mac OS X. DSYMUTIL=$lt_DSYMUTIL # Tool to change global to local symbols on Mac OS X. NMEDIT=$lt_NMEDIT # Tool to manipulate fat objects and archives on Mac OS X. LIPO=$lt_LIPO # ldd/readelf like tool for Mach-O binaries on Mac OS X. OTOOL=$lt_OTOOL # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. OTOOL64=$lt_OTOOL64 # Old archive suffix (normally "a"). libext=$libext # Shared library suffix (normally ".so"). shrext_cmds=$lt_shrext_cmds # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Variables whose values should be saved in libtool wrapper scripts and # restored at link time. variables_saved_for_relink=$lt_variables_saved_for_relink # Do we need the "lib" prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Library versioning type. version_type=$version_type # Shared library runtime path variable. runpath_var=$runpath_var # Shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Permission mode override for installation of shared libraries. install_override_mode=$lt_install_override_mode # Command to use after installation of a shared archive. postinstall_cmds=$lt_postinstall_cmds # Command to use after uninstallation of a shared archive. postuninstall_cmds=$lt_postuninstall_cmds # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # As "finish_cmds", except a single script fragment to be evaled but # not shown. finish_eval=$lt_finish_eval # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Compile-time system search path for libraries. sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Detected run-time system search path for libraries. sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path # Explicit LT_SYS_LIBRARY_PATH set during ./configure time. configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # The linker used to build libraries. LD=$lt_LD # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds # A language specific compiler. CC=$lt_compiler # Is the compiler the GNU compiler? with_gcc=$GCC # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc # Whether or not to disallow shared libs when runtime libs are static. allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec # Whether the compiler copes with passing no objects directly. compiler_needs_object=$lt_compiler_needs_object # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds # Commands used to build a shared archive. archive_cmds=$lt_archive_cmds archive_expsym_cmds=$lt_archive_expsym_cmds # Commands used to build a loadable module if different from building # a shared archive. module_cmds=$lt_module_cmds module_expsym_cmds=$lt_module_expsym_cmds # Whether we are building with GNU ld or not. with_gnu_ld=$lt_with_gnu_ld # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag # Flag that enforces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec # Whether we need a single "-rpath" flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary. hardcode_direct=$hardcode_direct # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary and the resulting library dependency is # "absolute",i.e impossible to change by setting \$shlibpath_var if the # library is relocated. hardcode_direct_absolute=$hardcode_direct_absolute # Set to "yes" if using the -LDIR flag during linking hardcodes DIR # into the resulting binary. hardcode_minus_L=$hardcode_minus_L # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR # into the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var # Set to "yes" if building a shared library automatically hardcodes DIR # into the library and all subsequent libraries and executables linked # against it. hardcode_automatic=$hardcode_automatic # Set to yes if linker adds runtime paths of dependent libraries # to runtime path list. inherit_rpath=$inherit_rpath # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs # Set to "yes" if exported symbols are required. always_export_symbols=$always_export_symbols # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms # Symbols that must always be exported. include_expsyms=$lt_include_expsyms # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds # Commands necessary for finishing linking programs. postlink_cmds=$lt_postlink_cmds # Specify filename containing input files. file_list_spec=$lt_file_list_spec # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac ltmain=$ac_aux_dir/ltmain.sh # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ;; esac done # for ac_tag as_fn_exit 0 _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || as_fn_exit 1 fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi mlterm-3.9.3/baselib/configure.in000066400000000000000000000222751441203364000167450ustar00rootroot00000000000000# -*- mode:sh; sh-basic-offset:2; tab-width:2; indent-tabs-mode:t -*- AC_INIT() AC_CONFIG_HEADER(src/bl_config.h) AC_CONFIG_AUX_DIR(script) AC_CANONICAL_HOST AC_CANONICAL_BUILD # for CFLAGS="..." ./configure ... AC_SUBST(CFLAGS) AC_PROG_CC # if --with-libtool is specified, cpp isn't detected. AC_PROG_CPP AC_PROG_INSTALL #detect glibc AC_TRY_COMPILE([#include ], [ #ifdef __GLIBC__ #else #error int boil\[-1\]; #endif ], AC_DEFINE(HAVE_GNU_SOURCE)) # # --- debug --- # AC_ARG_ENABLE(debug, [ --enable-debug debug @<:@default=disabled@:>@], debug=$enable_debug) if test "$debug" = yes ; then DEB_CFLAGS="-DDEBUG -DBL_DEBUG" fi AC_SUBST(DEB_CFLAGS) # # --- libtool --- # AC_LIBTOOL_WIN32_DLL AC_LIBTOOL_DLOPEN AC_ARG_WITH(libtool, [ --with-libtool@<:@=ARG@:>@ libtool path @<:@default=without@:>@], libtool=$with_libtool) if test "${libtool}" != "" ; then LIBTOOL=${libtool} else AM_PROG_LIBTOOL LIBTOOL='${top_builddir}/libtool' fi AC_SUBST(LIBTOOL) # # --- Checks for header files --- # # NOTE: if --with-libtool is specified, stdc header isn't detected. AC_HEADER_STDC AC_CHECK_HEADERS(langinfo.h dlfcn.h dl.h stropts.h sys/stropts.h stdint.h windows.h errno.h stdint.h) # # --- Checks for library functions --- # AC_CHECK_FUNCS(strsep fgetln basename isastream seteuid setegid geteuid getegid setsid snprintf usleep setenv unsetenv flock getuid getgid getpwuid recvmsg setpgid socketpair killpg gettimeofday) AC_FUNC_ALLOCA AC_C_INLINE AC_C_CONST AC_C_BIGENDIAN AC_SYS_LARGEFILE # for OpenServer 6.0.0 AC_CHECK_HEADER(sys/bitypes.h, [ ac_includes_default="\ $ac_includes_default #include " HAVE_SYS_BITYPES_H=1 AC_DEFINE(HAVE_SYS_BITYPES_H) ]) AC_CHECK_TYPE(u_char,unsigned char) AC_CHECK_TYPE(u_short,unsigned short) AC_CHECK_TYPE(u_int,unsigned int) AC_CHECK_TYPE(u_long,unsigned long) AC_CHECK_TYPE(u_int8_t,unsigned char) AC_CHECK_TYPE(u_int16_t,unsigned short) AC_CHECK_TYPE(u_int32_t,unsigned int) AC_CHECK_TYPE(u_int64_t,unsigned long) AC_CHECK_TYPE(int8_t,char) AC_CHECK_TYPE(int16_t,short) AC_CHECK_TYPE(int32_t,int) AC_CHECK_TYPE(int64_t,long) AC_CHECK_TYPE(ssize_t,int) AC_TYPE_MODE_T AC_TYPE_PID_T AC_TYPE_UID_T AC_TYPE_OFF_T AC_TYPE_SIZE_T # # --- Platform dependent stuff --- # bl_cv_cygwin=no bl_cv_mingw=no bl_cv_win32=no case "${host_os}" in cygwin*) bl_cv_cygwin=yes case "${CC} ${CFLAGS}" in *mno-cygwin* | *-mingw*) bl_cv_win32=yes AC_DEFINE(USE_WIN32API,,"USE_WIN32API") ;; *) ;; esac ;; mingw*) bl_cv_mingw=yes if test ! -f "/lib/libmsys-1.0.dll.a" ; then case "${lt_cv_path_LD}" in *-msys*) ;; *) bl_cv_win32=yes AC_DEFINE(USE_WIN32API,,"USE_WIN32API") ;; esac fi ;; *) ;; esac # # --- socklen_t --- # # NOTE: #define _BSDTYPES_DEFINED is necessary because AC_TRY_COMPILE defines # u_char, u_short and so on before #include . # AC_CACHE_CHECK(for socklen_t, bl_cv_socklen_ident, [AC_TRY_COMPILE( [ #include #include #include ], [ socklen_t len ; ], bl_cv_socklen_ident=yes, [AC_TRY_COMPILE( [ #define _BSDTYPES_DEFINED #include ], [ socklen_t len ; ], bl_cv_socklen_ident=yes, bl_cv_socklen_ident=no)])]) if test "${bl_cv_socklen_ident}" = "no" ; then AC_DEFINE(socklen_t, unsigned int, "socklen_t") fi # # --- Check if concatenation of string literals with __FUNCTION__ is supported. --- # AC_CACHE_CHECK(for __FUNCTION__, bl_cv_func_ident,[ AC_TRY_COMPILE(, [ char * p = "[" __FUNCTION__ "]" ; ] , bl_cv_func_ident=yes,bl_cv_func_ident=no)]) if test "${bl_cv_func_ident}" = "yes" ; then AC_DEFINE(CONCATABLE_FUNCTION,,"CONCATABLE_FUNCTION") fi # # --- Check for libxpg4 (for FreeBSD) --- # AC_CHECK_FUNCS(setlocale) if test "x$ac_cv_func_setlocale" = xno ; then AC_CHECK_LIB(xpg4, setlocale, XPG4_LIBS=-lxpg4) AC_SUBST(XPG4_LIBS) fi # # --- Checks for dynamic linking loader --- # DL_LOADER=none DL_LIBS= DL_CFLAGS= # lt_dlopenext in libltdl AC_ARG_WITH(libltdl, [ --with-libltdl@<:@=PREFIX@:>@ load modules with libltdl @<:@default=without@:>@],, [with_libltdl=no]) if test "x$with_libltdl" != "xno" ; then if test "x$with_libltdl" != "xyes"; then DL_CFLAGS="-I$with_libltdl/include" bl_libltdl_libdir="-L$with_libltdl/lib" fi bl_ldflags_save="$LDFLAGS" LDFLAGS="$LDFLAGS $bl_libltdl_libdir" AC_CHECK_LIB(ltdl, lt_dlopenext, [ DL_LOADER=ltdl DL_LIBS="$bl_libltdl_libdir -lltdl" ],[ echo "" echo "Could not find libltdl" echo "" exit 1]) LDFLAGS="$bl_ldflags_save" fi # lt_cv_dlopen is set by AC_LIBTOOL_DLOPEN if test "$DL_LOADER" = none ; then case "${lt_cv_dlopen}" in # LoadLibrary (Windows) LoadLibrary) DL_LOADER=win32 ;; # shl_load (HP-UX) shl_load) DL_LOADER=dld ;; # dlopen (UNIX98) dlopen) DL_LOADER=dl ;; # What is dld_link? Does anybody know? dld_link) DL_LOADER=none ;; *) DL_LOADER=none ;; esac DL_LIBS="${DL_LIBS} ${lt_cv_dlopen_libs}" if test "$DL_LOADER" = none ; then # NSLinkModule (darwin) AC_CHECK_FUNC(NSLinkModule, [ DL_LOADER=dyld DL_LIBS= ], []) fi # cygwin hack # (AC_LIBTOOL_DLOPEN tell lt_cv_dlopen == dlopen but use bl_dlcfn_win32.c.) # On msys2, use dlopen because bl_dlfcn_win32 doesn't work correctly. if test "$bl_cv_cygwin" = "yes"; then DL_LOADER=win32 fi fi AC_SUBST(DL_LOADER) AC_SUBST(DL_LIBS) AC_SUBST(DL_CFLAGS) if test "$DL_LOADER" = none ; then AC_DEFINE(DLFCN_NONE,,"DLFCN_NONE") fi # # --- check for undefined symbol --- # AC_MSG_CHECKING([for undefined symbol]) if test "x$allow_undefined_flag" = "xunsupported" ; then AC_MSG_RESULT([not supported]) NO_UNDEFINED_FLAG="-no-undefined" else AC_MSG_RESULT(supported) NO_UNDEFINED_FLAG="" fi AC_SUBST(NO_UNDEFINED_FLAG) # # --- pty check --- # AC_MSG_CHECKING(for pty/tty type) if test "$bl_cv_win32" = "yes" ; then bl_cv_pty=none elif test "$bl_cv_mingw" = "yes" ; then bl_cv_pty=streams elif test "$host" = "$build" ; then AC_CHECK_FUNC(posix_openpt, [AC_RUN_IFELSE([AC_LANG_PROGRAM([#include ], [return posix_openpt(O_RDWR | O_NOCTTY) == -1;])], [ AC_DEFINE(HAVE_POSIX_OPENPT,,"HAVE_POSIX_OPENPT") bl_cv_pty=streams ], [bl_cv_pty=bsd])], [bl_cv_pty=bsd]) if test "$bl_cv_pty" = "bsd" ; then AC_RUN_IFELSE( [AC_LANG_PROGRAM([#include ], [return open( "/dev/ptmx", O_RDWR | O_NOCTTY, 0) == -1;])], [bl_cv_pty=streams]) fi else # cross compiling AC_CHECK_FUNC(posix_openpt, [ AC_DEFINE(HAVE_POSIX_OPENPT,,"HAVE_POSIX_OPENPT") bl_cv_pty=streams ], [bl_cv_pty=bsd]) fi AC_ARG_ENABLE(pty_helper, [ --enable-pty-helper use pty helper @<:@default=disabled@:>@], pty_helper=$enable_pty_helper) if test "$pty_helper" = yes ; then if test "$bl_cv_pty" = streams ; then bl_cv_pty=helper else echo "" echo "** WARNING **" echo " pty helper is not supported in bsd-style pty system." echo "" fi fi AC_MSG_RESULT($bl_cv_pty) PTY_NAME="${bl_cv_pty}" AC_SUBST(PTY_NAME) # # --- checks for utmp --- # AC_ARG_WITH(utmp, [ --with-utmp@<:@=ARG@:>@ utmp (utempter,sysv,login,bsd,none)], utmp_type=$with_utmp) UTMP_NAME= UTMP_LIBS= if test "$bl_cv_pty" = helper -o "$bl_cv_mingw" = yes -o "$bl_cv_cygwin" = yes -o "$host_os" = "msys" -o "$host_os" = "haiku"; then UTMP_NAME=none UTMP_LIBS= fi # libutempter if test "$utmp_type" = "" -o "$utmp_type" = "utempter"; then if test -z "$UTMP_NAME"; then AC_CHECK_LIB(utempter, utempter_add_record, [ UTMP_NAME=utmper UTMP_LIBS="-lutempter" UTMP_CFLAGS="-DUTEMPTER_NEW_API" ], []) fi if test -z "$UTMP_NAME"; then # FreeBSD AC_CHECK_LIB(ulog, utempter_add_record, [ UTMP_NAME=utmper UTMP_LIBS="-lulog" UTMP_CFLAGS="-DUTEMPTER_NEW_API" ], []) fi if test -z "$UTMP_NAME" ; then AC_CHECK_LIB(utempter, addToUtmp, [ UTMP_NAME=utmper UTMP_LIBS="-lutempter -lutil" ]) fi fi # setutxent() (SysV) if test "$utmp_type" = "" -o "$utmp_type" = "sysv"; then if test -z "$UTMP_NAME"; then AC_CHECK_FUNC(setutxent, [ UTMP_NAME=sysv UTMP_LIBS= UTMP_CFLAGS=-DUSE_UTMPX ], []) fi # setutent() (SysV) if test -z "$UTMP_NAME"; then AC_CHECK_FUNC(setutent, [ UTMP_NAME=sysv UTMP_LIBS= ], []) fi fi # libutil if test "$utmp_type" = "" -o "$utmp_type" = "login"; then if test -z "$UTMP_NAME" ; then AC_CHECK_LIB(util, logout, [ UTMP_NAME=login UTMP_LIBS=-lutil ], []) fi fi # other (BSD) if test "$utmp_type" = "" -o "$utmp_type" = "bsd"; then if test -z "$UTMP_NAME" ; then UTMP_NAME=bsd UTMP_LIBS= fi fi if test -z "$UTMP_NAME" ; then UTMP_NAME=none UTMP_LIBS= fi AC_SUBST(UTMP_NAME) AC_SUBST(UTMP_LIBS) AC_SUBST(UTMP_CFLAGS) # # --- remove functions mlterm doesn't use --- # AC_ARG_WITH(funcs-mlterm-unuse, [ --without-funcs-mlterm-unuse remove functions mlterm does not use @<:@default=with@:>@], funcs_mlterm_unuse=$with_funcs_mlterm_unuse,funcs_mlterm_unuse="yes") if test "$funcs_mlterm_unuse" = "no" ; then AC_DEFINE(REMOVE_FUNCS_MLTERM_UNUSE,,"REMOVE_FUNCS_MLTERM_UNUSE") fi # # --- check for malloc --- # if test "$host" = "$build"; then AC_TRY_RUN( [ #include int main() { return calloc(8, ((1 << (sizeof(size_t) * 8 - 1)) + 1)) ? 1 : 0 ; } ], AC_DEFINE(CALLOC_CHECK_OVERFLOW)) fi AC_SUBST(pobl_top_srcdir_suffix) AC_SUBST(pobl_top_builddir_suffix) AC_OUTPUT(Makefile src/Makefile) mlterm-3.9.3/baselib/script/000077500000000000000000000000001441203364000157305ustar00rootroot00000000000000mlterm-3.9.3/baselib/script/config.guess000077500000000000000000001414221441203364000202540ustar00rootroot00000000000000#! /bin/sh # Attempt to guess a canonical system name. # Copyright 1992-2023 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale timestamp='2023-01-01' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that # program. This Exception is an additional permission under section 7 # of the GNU General Public License, version 3 ("GPLv3"). # # Originally written by Per Bothner; maintained since 2000 by Ben Elliston. # # You can get the latest version of this script from: # https://git.savannah.gnu.org/cgit/config.git/plain/config.guess # # Please send patches to . # The "shellcheck disable" line above the timestamp inhibits complaints # about features and limitations of the classic Bourne shell that were # superseded or lifted in POSIX. However, this script identifies a wide # variety of pre-POSIX systems that do not have POSIX shells at all, and # even some reasonably current systems (Solaris 10 as case-in-point) still # have a pre-POSIX /bin/sh. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright 1992-2023 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi # Just in case it came from the environment. GUESS= # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. tmp= # shellcheck disable=SC2172 trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15 set_cc_for_build() { # prevent multiple calls if $tmp is already set test "$tmp" && return 0 : "${TMPDIR=/tmp}" # shellcheck disable=SC2039,SC3028 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } dummy=$tmp/dummy case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in ,,) echo "int x;" > "$dummy.c" for driver in cc gcc c89 c99 ; do if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then CC_FOR_BUILD=$driver break fi done if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac } # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if test -f /.attbin/uname ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown case $UNAME_SYSTEM in Linux|GNU|GNU/*) LIBC=unknown set_cc_for_build cat <<-EOF > "$dummy.c" #include #if defined(__UCLIBC__) LIBC=uclibc #elif defined(__dietlibc__) LIBC=dietlibc #elif defined(__GLIBC__) LIBC=gnu #else #include /* First heuristic to detect musl libc. */ #ifdef __DEFINED_va_list LIBC=musl #endif #endif EOF cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` eval "$cc_set_libc" # Second heuristic to detect musl libc. if [ "$LIBC" = unknown ] && command -v ldd >/dev/null && ldd --version 2>&1 | grep -q ^musl; then LIBC=musl fi # If the system lacks a compiler, then just pick glibc. # We could probably try harder. if [ "$LIBC" = unknown ]; then LIBC=gnu fi ;; esac # Note: order is significant - the case branches are not exclusive. case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ /sbin/sysctl -n hw.machine_arch 2>/dev/null || \ /usr/sbin/sysctl -n hw.machine_arch 2>/dev/null || \ echo unknown)` case $UNAME_MACHINE_ARCH in aarch64eb) machine=aarch64_be-unknown ;; armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; earmv*) arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` machine=${arch}${endian}-unknown ;; *) machine=$UNAME_MACHINE_ARCH-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently (or will in the future) and ABI. case $UNAME_MACHINE_ARCH in earm*) os=netbsdelf ;; arm*|i386|m68k|ns32k|sh3*|sparc|vax) set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ELF__ then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # Determine ABI tags. case $UNAME_MACHINE_ARCH in earm*) expr='s/^earmv[0-9]/-eabi/;s/eb$//' abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case $UNAME_VERSION in Debian*) release='-gnu' ;; *) release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. GUESS=$machine-${os}${release}${abi-} ;; *:Bitrig:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-bitrig$UNAME_RELEASE ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-openbsd$UNAME_RELEASE ;; *:SecBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/SecBSD.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-secbsd$UNAME_RELEASE ;; *:LibertyBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` GUESS=$UNAME_MACHINE_ARCH-unknown-libertybsd$UNAME_RELEASE ;; *:MidnightBSD:*:*) GUESS=$UNAME_MACHINE-unknown-midnightbsd$UNAME_RELEASE ;; *:ekkoBSD:*:*) GUESS=$UNAME_MACHINE-unknown-ekkobsd$UNAME_RELEASE ;; *:SolidBSD:*:*) GUESS=$UNAME_MACHINE-unknown-solidbsd$UNAME_RELEASE ;; *:OS108:*:*) GUESS=$UNAME_MACHINE-unknown-os108_$UNAME_RELEASE ;; macppc:MirBSD:*:*) GUESS=powerpc-unknown-mirbsd$UNAME_RELEASE ;; *:MirBSD:*:*) GUESS=$UNAME_MACHINE-unknown-mirbsd$UNAME_RELEASE ;; *:Sortix:*:*) GUESS=$UNAME_MACHINE-unknown-sortix ;; *:Twizzler:*:*) GUESS=$UNAME_MACHINE-unknown-twizzler ;; *:Redox:*:*) GUESS=$UNAME_MACHINE-unknown-redox ;; mips:OSF1:*.*) GUESS=mips-dec-osf1 ;; alpha:OSF1:*:*) # Reset EXIT trap before exiting to avoid spurious non-zero exit code. trap '' 0 case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case $ALPHA_CPU_TYPE in "EV4 (21064)") UNAME_MACHINE=alpha ;; "EV4.5 (21064)") UNAME_MACHINE=alpha ;; "LCA4 (21066/21068)") UNAME_MACHINE=alpha ;; "EV5 (21164)") UNAME_MACHINE=alphaev5 ;; "EV5.6 (21164A)") UNAME_MACHINE=alphaev56 ;; "EV5.6 (21164PC)") UNAME_MACHINE=alphapca56 ;; "EV5.7 (21164PC)") UNAME_MACHINE=alphapca57 ;; "EV6 (21264)") UNAME_MACHINE=alphaev6 ;; "EV6.7 (21264A)") UNAME_MACHINE=alphaev67 ;; "EV6.8CB (21264C)") UNAME_MACHINE=alphaev68 ;; "EV6.8AL (21264B)") UNAME_MACHINE=alphaev68 ;; "EV6.8CX (21264D)") UNAME_MACHINE=alphaev68 ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE=alphaev69 ;; "EV7 (21364)") UNAME_MACHINE=alphaev7 ;; "EV7.9 (21364A)") UNAME_MACHINE=alphaev79 ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. OSF_REL=`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` GUESS=$UNAME_MACHINE-dec-osf$OSF_REL ;; Amiga*:UNIX_System_V:4.0:*) GUESS=m68k-unknown-sysv4 ;; *:[Aa]miga[Oo][Ss]:*:*) GUESS=$UNAME_MACHINE-unknown-amigaos ;; *:[Mm]orph[Oo][Ss]:*:*) GUESS=$UNAME_MACHINE-unknown-morphos ;; *:OS/390:*:*) GUESS=i370-ibm-openedition ;; *:z/VM:*:*) GUESS=s390-ibm-zvmoe ;; *:OS400:*:*) GUESS=powerpc-ibm-os400 ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) GUESS=arm-acorn-riscix$UNAME_RELEASE ;; arm*:riscos:*:*|arm*:RISCOS:*:*) GUESS=arm-unknown-riscos ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) GUESS=hppa1.1-hitachi-hiuxmpp ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. case `(/bin/universe) 2>/dev/null` in att) GUESS=pyramid-pyramid-sysv3 ;; *) GUESS=pyramid-pyramid-bsd ;; esac ;; NILE*:*:*:dcosx) GUESS=pyramid-pyramid-svr4 ;; DRS?6000:unix:4.0:6*) GUESS=sparc-icl-nx6 ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in sparc) GUESS=sparc-icl-nx7 ;; esac ;; s390x:SunOS:*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=$UNAME_MACHINE-ibm-solaris2$SUN_REL ;; sun4H:SunOS:5.*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=sparc-hal-solaris2$SUN_REL ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=sparc-sun-solaris2$SUN_REL ;; i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) GUESS=i386-pc-auroraux$UNAME_RELEASE ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) set_cc_for_build SUN_ARCH=i386 # If there is a compiler, see if it is configured for 64-bit objects. # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. # This test works for both compilers. if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -m64 -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then SUN_ARCH=x86_64 fi fi SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=$SUN_ARCH-pc-solaris2$SUN_REL ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=sparc-sun-solaris3$SUN_REL ;; sun4*:SunOS:*:*) case `/usr/bin/arch -k` in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` GUESS=sparc-sun-sunos$SUN_REL ;; sun3*:SunOS:*:*) GUESS=m68k-sun-sunos$UNAME_RELEASE ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 case `/bin/arch` in sun3) GUESS=m68k-sun-sunos$UNAME_RELEASE ;; sun4) GUESS=sparc-sun-sunos$UNAME_RELEASE ;; esac ;; aushp:SunOS:*:*) GUESS=sparc-auspex-sunos$UNAME_RELEASE ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) GUESS=m68k-atari-mint$UNAME_RELEASE ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) GUESS=m68k-atari-mint$UNAME_RELEASE ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) GUESS=m68k-atari-mint$UNAME_RELEASE ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) GUESS=m68k-milan-mint$UNAME_RELEASE ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) GUESS=m68k-hades-mint$UNAME_RELEASE ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) GUESS=m68k-unknown-mint$UNAME_RELEASE ;; m68k:machten:*:*) GUESS=m68k-apple-machten$UNAME_RELEASE ;; powerpc:machten:*:*) GUESS=powerpc-apple-machten$UNAME_RELEASE ;; RISC*:Mach:*:*) GUESS=mips-dec-mach_bsd4.3 ;; RISC*:ULTRIX:*:*) GUESS=mips-dec-ultrix$UNAME_RELEASE ;; VAX*:ULTRIX*:*:*) GUESS=vax-dec-ultrix$UNAME_RELEASE ;; 2020:CLIX:*:* | 2430:CLIX:*:*) GUESS=clipper-intergraph-clix$UNAME_RELEASE ;; mips:*:*:UMIPS | mips:*:*:RISCos) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`"$dummy" "$dummyarg"` && { echo "$SYSTEM_NAME"; exit; } GUESS=mips-mips-riscos$UNAME_RELEASE ;; Motorola:PowerMAX_OS:*:*) GUESS=powerpc-motorola-powermax ;; Motorola:*:4.3:PL8-*) GUESS=powerpc-harris-powermax ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) GUESS=powerpc-harris-powermax ;; Night_Hawk:Power_UNIX:*:*) GUESS=powerpc-harris-powerunix ;; m88k:CX/UX:7*:*) GUESS=m88k-harris-cxux7 ;; m88k:*:4*:R4*) GUESS=m88k-motorola-sysv4 ;; m88k:*:3*:R3*) GUESS=m88k-motorola-sysv3 ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110 then if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \ test "$TARGET_BINARY_INTERFACE"x = x then GUESS=m88k-dg-dgux$UNAME_RELEASE else GUESS=m88k-dg-dguxbcs$UNAME_RELEASE fi else GUESS=i586-dg-dgux$UNAME_RELEASE fi ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) GUESS=m88k-dolphin-sysv3 ;; M88*:*:R3*:*) # Delta 88k system running SVR3 GUESS=m88k-motorola-sysv3 ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) GUESS=m88k-tektronix-sysv3 ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) GUESS=m68k-tektronix-bsd ;; *:IRIX*:*:*) IRIX_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/g'` GUESS=mips-sgi-irix$IRIX_REL ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. GUESS=romp-ibm-aix # uname -m gives an 8 hex-code CPU id ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) GUESS=i386-ibm-aix ;; ia64:AIX:*:*) if test -x /usr/bin/oslevel ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi GUESS=$UNAME_MACHINE-ibm-aix$IBM_REV ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` then GUESS=$SYSTEM_NAME else GUESS=rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then GUESS=rs6000-ibm-aix3.2.4 else GUESS=rs6000-ibm-aix3.2 fi ;; *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if test -x /usr/bin/lslpp ; then IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | \ awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` else IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi GUESS=$IBM_ARCH-ibm-aix$IBM_REV ;; *:AIX:*:*) GUESS=rs6000-ibm-aix ;; ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) GUESS=romp-ibm-bsd4.4 ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and GUESS=romp-ibm-bsd$UNAME_RELEASE # 4.3 with uname added to ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) GUESS=rs6000-bull-bosx ;; DPX/2?00:B.O.S.:*:*) GUESS=m68k-bull-sysv3 ;; 9000/[34]??:4.3bsd:1.*:*) GUESS=m68k-hp-bsd ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) GUESS=m68k-hp-bsd4.4 ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` case $UNAME_MACHINE in 9000/31?) HP_ARCH=m68000 ;; 9000/[34]??) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if test -x /usr/bin/getconf; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case $sc_cpu_version in 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case $sc_kernel_bits in 32) HP_ARCH=hppa2.0n ;; 64) HP_ARCH=hppa2.0w ;; '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 esac ;; esac fi if test "$HP_ARCH" = ""; then set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if test "$HP_ARCH" = hppa2.0w then set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler # generating 64-bit code. GNU and HP use different nomenclature: # # $ CC_FOR_BUILD=cc ./config.guess # => hppa2.0w-hp-hpux11.23 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | grep -q __LP64__ then HP_ARCH=hppa2.0w else HP_ARCH=hppa64 fi fi GUESS=$HP_ARCH-hp-hpux$HPUX_REV ;; ia64:HP-UX:*:*) HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` GUESS=ia64-hp-hpux$HPUX_REV ;; 3050*:HI-UX:*:*) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } GUESS=unknown-hitachi-hiuxwe2 ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) GUESS=hppa1.1-hp-bsd ;; 9000/8??:4.3bsd:*:*) GUESS=hppa1.0-hp-bsd ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) GUESS=hppa1.0-hp-mpeix ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) GUESS=hppa1.1-hp-osf ;; hp8??:OSF1:*:*) GUESS=hppa1.0-hp-osf ;; i*86:OSF1:*:*) if test -x /usr/sbin/sysversion ; then GUESS=$UNAME_MACHINE-unknown-osf1mk else GUESS=$UNAME_MACHINE-unknown-osf1 fi ;; parisc*:Lites*:*:*) GUESS=hppa1.1-hp-lites ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) GUESS=c1-convex-bsd ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) GUESS=c34-convex-bsd ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) GUESS=c38-convex-bsd ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) GUESS=c4-convex-bsd ;; CRAY*Y-MP:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=ymp-cray-unicos$CRAY_REL ;; CRAY*[A-Z]90:*:*:*) echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=t90-cray-unicos$CRAY_REL ;; CRAY*T3E:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=alphaev5-cray-unicosmk$CRAY_REL ;; CRAY*SV1:*:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=sv1-cray-unicos$CRAY_REL ;; *:UNICOS/mp:*:*) CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` GUESS=craynv-cray-unicosmp$CRAY_REL ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` GUESS=${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` GUESS=sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) GUESS=$UNAME_MACHINE-pc-bsdi$UNAME_RELEASE ;; sparc*:BSD/OS:*:*) GUESS=sparc-unknown-bsdi$UNAME_RELEASE ;; *:BSD/OS:*:*) GUESS=$UNAME_MACHINE-unknown-bsdi$UNAME_RELEASE ;; arm:FreeBSD:*:*) UNAME_PROCESSOR=`uname -p` set_cc_for_build if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabi else FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabihf fi ;; *:FreeBSD:*:*) UNAME_PROCESSOR=`/usr/bin/uname -p` case $UNAME_PROCESSOR in amd64) UNAME_PROCESSOR=x86_64 ;; i386) UNAME_PROCESSOR=i586 ;; esac FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL ;; i*:CYGWIN*:*) GUESS=$UNAME_MACHINE-pc-cygwin ;; *:MINGW64*:*) GUESS=$UNAME_MACHINE-pc-mingw64 ;; *:MINGW*:*) GUESS=$UNAME_MACHINE-pc-mingw32 ;; *:MSYS*:*) GUESS=$UNAME_MACHINE-pc-msys ;; i*:PW*:*) GUESS=$UNAME_MACHINE-pc-pw32 ;; *:SerenityOS:*:*) GUESS=$UNAME_MACHINE-pc-serenity ;; *:Interix*:*) case $UNAME_MACHINE in x86) GUESS=i586-pc-interix$UNAME_RELEASE ;; authenticamd | genuineintel | EM64T) GUESS=x86_64-unknown-interix$UNAME_RELEASE ;; IA64) GUESS=ia64-unknown-interix$UNAME_RELEASE ;; esac ;; i*:UWIN*:*) GUESS=$UNAME_MACHINE-pc-uwin ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) GUESS=x86_64-pc-cygwin ;; prep*:SunOS:5.*:*) SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` GUESS=powerpcle-unknown-solaris2$SUN_REL ;; *:GNU:*:*) # the GNU system GNU_ARCH=`echo "$UNAME_MACHINE" | sed -e 's,[-/].*$,,'` GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's,/.*$,,'` GUESS=$GNU_ARCH-unknown-$LIBC$GNU_REL ;; *:GNU/*:*:*) # other systems with GNU libc and userland GNU_SYS=`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"` GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_MACHINE-unknown-$GNU_SYS$GNU_REL-$LIBC ;; x86_64:[Mm]anagarm:*:*|i?86:[Mm]anagarm:*:*) GUESS="$UNAME_MACHINE-pc-managarm-mlibc" ;; *:[Mm]anagarm:*:*) GUESS="$UNAME_MACHINE-unknown-managarm-mlibc" ;; *:Minix:*:*) GUESS=$UNAME_MACHINE-unknown-minix ;; aarch64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC=gnulibc1 ; fi GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; arc:Linux:*:* | arceb:Linux:*:* | arc32:Linux:*:* | arc64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; arm*:Linux:*:*) set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then GUESS=$UNAME_MACHINE-unknown-linux-$LIBC else if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabi else GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabihf fi fi ;; avr32*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; cris:Linux:*:*) GUESS=$UNAME_MACHINE-axis-linux-$LIBC ;; crisv32:Linux:*:*) GUESS=$UNAME_MACHINE-axis-linux-$LIBC ;; e2k:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; frv:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; hexagon:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; i*86:Linux:*:*) GUESS=$UNAME_MACHINE-pc-linux-$LIBC ;; ia64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; k1om:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; loongarch32:Linux:*:* | loongarch64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; m32r*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; m68*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; mips:Linux:*:* | mips64:Linux:*:*) set_cc_for_build IS_GLIBC=0 test x"${LIBC}" = xgnu && IS_GLIBC=1 sed 's/^ //' << EOF > "$dummy.c" #undef CPU #undef mips #undef mipsel #undef mips64 #undef mips64el #if ${IS_GLIBC} && defined(_ABI64) LIBCABI=gnuabi64 #else #if ${IS_GLIBC} && defined(_ABIN32) LIBCABI=gnuabin32 #else LIBCABI=${LIBC} #endif #endif #if ${IS_GLIBC} && defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 CPU=mipsisa64r6 #else #if ${IS_GLIBC} && !defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 CPU=mipsisa32r6 #else #if defined(__mips64) CPU=mips64 #else CPU=mips #endif #endif #endif #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) MIPS_ENDIAN=el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) MIPS_ENDIAN= #else MIPS_ENDIAN= #endif #endif EOF cc_set_vars=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'` eval "$cc_set_vars" test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; } ;; mips64el:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; openrisc*:Linux:*:*) GUESS=or1k-unknown-linux-$LIBC ;; or32:Linux:*:* | or1k*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; padre:Linux:*:*) GUESS=sparc-unknown-linux-$LIBC ;; parisc64:Linux:*:* | hppa64:Linux:*:*) GUESS=hppa64-unknown-linux-$LIBC ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) GUESS=hppa1.1-unknown-linux-$LIBC ;; PA8*) GUESS=hppa2.0-unknown-linux-$LIBC ;; *) GUESS=hppa-unknown-linux-$LIBC ;; esac ;; ppc64:Linux:*:*) GUESS=powerpc64-unknown-linux-$LIBC ;; ppc:Linux:*:*) GUESS=powerpc-unknown-linux-$LIBC ;; ppc64le:Linux:*:*) GUESS=powerpc64le-unknown-linux-$LIBC ;; ppcle:Linux:*:*) GUESS=powerpcle-unknown-linux-$LIBC ;; riscv32:Linux:*:* | riscv32be:Linux:*:* | riscv64:Linux:*:* | riscv64be:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; s390:Linux:*:* | s390x:Linux:*:*) GUESS=$UNAME_MACHINE-ibm-linux-$LIBC ;; sh64*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; sh*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; sparc:Linux:*:* | sparc64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; tile*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; vax:Linux:*:*) GUESS=$UNAME_MACHINE-dec-linux-$LIBC ;; x86_64:Linux:*:*) set_cc_for_build CPU=$UNAME_MACHINE LIBCABI=$LIBC if test "$CC_FOR_BUILD" != no_compiler_found; then ABI=64 sed 's/^ //' << EOF > "$dummy.c" #ifdef __i386__ ABI=x86 #else #ifdef __ILP32__ ABI=x32 #endif #endif EOF cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` eval "$cc_set_abi" case $ABI in x86) CPU=i686 ;; x32) LIBCABI=${LIBC}x32 ;; esac fi GUESS=$CPU-pc-linux-$LIBCABI ;; xtensa*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. GUESS=i386-sequent-sysv4 ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. GUESS=$UNAME_MACHINE-pc-os2-emx ;; i*86:XTS-300:*:STOP) GUESS=$UNAME_MACHINE-unknown-stop ;; i*86:atheos:*:*) GUESS=$UNAME_MACHINE-unknown-atheos ;; i*86:syllable:*:*) GUESS=$UNAME_MACHINE-pc-syllable ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) GUESS=i386-unknown-lynxos$UNAME_RELEASE ;; i*86:*DOS:*:*) GUESS=$UNAME_MACHINE-pc-msdosdjgpp ;; i*86:*:4.*:*) UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then GUESS=$UNAME_MACHINE-univel-sysv$UNAME_REL else GUESS=$UNAME_MACHINE-pc-sysv$UNAME_REL fi ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac GUESS=$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 GUESS=$UNAME_MACHINE-pc-sco$UNAME_REL else GUESS=$UNAME_MACHINE-pc-sysv32 fi ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about # the processor, so we play safe by assuming i586. # Note: whatever this is, it MUST be the same as what config.sub # prints for the "djgpp" host, or else GDB configure will decide that # this is a cross-build. GUESS=i586-pc-msdosdjgpp ;; Intel:Mach:3*:*) GUESS=i386-pc-mach3 ;; paragon:*:*:*) GUESS=i860-intel-osf1 ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then GUESS=i860-stardent-sysv$UNAME_RELEASE # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. GUESS=i860-unknown-sysv$UNAME_RELEASE # Unknown i860-SVR4 fi ;; mini*:CTIX:SYS*5:*) # "miniframe" GUESS=m68010-convergent-sysv ;; mc68k:UNIX:SYSTEM5:3.51m) GUESS=m68k-convergent-sysv ;; M680?0:D-NIX:5.3:*) GUESS=m68k-diab-dnix ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; NCR*:*:4.2:* | MPRAS*:*:4.2:*) OS_REL='.3' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) GUESS=m68k-unknown-lynxos$UNAME_RELEASE ;; mc68030:UNIX_System_V:4.*:*) GUESS=m68k-atari-sysv4 ;; TSUNAMI:LynxOS:2.*:*) GUESS=sparc-unknown-lynxos$UNAME_RELEASE ;; rs6000:LynxOS:2.*:*) GUESS=rs6000-unknown-lynxos$UNAME_RELEASE ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) GUESS=powerpc-unknown-lynxos$UNAME_RELEASE ;; SM[BE]S:UNIX_SV:*:*) GUESS=mips-dde-sysv$UNAME_RELEASE ;; RM*:ReliantUNIX-*:*:*) GUESS=mips-sni-sysv4 ;; RM*:SINIX-*:*:*) GUESS=mips-sni-sysv4 ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` GUESS=$UNAME_MACHINE-sni-sysv4 else GUESS=ns32k-sni-sysv fi ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says GUESS=i586-unisys-sysv4 ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm GUESS=hppa1.1-stratus-sysv4 ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. GUESS=i860-stratus-sysv4 ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. GUESS=$UNAME_MACHINE-stratus-vos ;; *:VOS:*:*) # From Paul.Green@stratus.com. GUESS=hppa1.1-stratus-vos ;; mc68*:A/UX:*:*) GUESS=m68k-apple-aux$UNAME_RELEASE ;; news*:NEWS-OS:6*:*) GUESS=mips-sony-newsos6 ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if test -d /usr/nec; then GUESS=mips-nec-sysv$UNAME_RELEASE else GUESS=mips-unknown-sysv$UNAME_RELEASE fi ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. GUESS=powerpc-be-beos ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. GUESS=powerpc-apple-beos ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. GUESS=i586-pc-beos ;; BePC:Haiku:*:*) # Haiku running on Intel PC compatible. GUESS=i586-pc-haiku ;; ppc:Haiku:*:*) # Haiku running on Apple PowerPC GUESS=powerpc-apple-haiku ;; *:Haiku:*:*) # Haiku modern gcc (not bound by BeOS compat) GUESS=$UNAME_MACHINE-unknown-haiku ;; SX-4:SUPER-UX:*:*) GUESS=sx4-nec-superux$UNAME_RELEASE ;; SX-5:SUPER-UX:*:*) GUESS=sx5-nec-superux$UNAME_RELEASE ;; SX-6:SUPER-UX:*:*) GUESS=sx6-nec-superux$UNAME_RELEASE ;; SX-7:SUPER-UX:*:*) GUESS=sx7-nec-superux$UNAME_RELEASE ;; SX-8:SUPER-UX:*:*) GUESS=sx8-nec-superux$UNAME_RELEASE ;; SX-8R:SUPER-UX:*:*) GUESS=sx8r-nec-superux$UNAME_RELEASE ;; SX-ACE:SUPER-UX:*:*) GUESS=sxace-nec-superux$UNAME_RELEASE ;; Power*:Rhapsody:*:*) GUESS=powerpc-apple-rhapsody$UNAME_RELEASE ;; *:Rhapsody:*:*) GUESS=$UNAME_MACHINE-apple-rhapsody$UNAME_RELEASE ;; arm64:Darwin:*:*) GUESS=aarch64-apple-darwin$UNAME_RELEASE ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` case $UNAME_PROCESSOR in unknown) UNAME_PROCESSOR=powerpc ;; esac if command -v xcode-select > /dev/null 2> /dev/null && \ ! xcode-select --print-path > /dev/null 2> /dev/null ; then # Avoid executing cc if there is no toolchain installed as # cc will be a stub that puts up a graphical alert # prompting the user to install developer tools. CC_FOR_BUILD=no_compiler_found else set_cc_for_build fi if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then case $UNAME_PROCESSOR in i386) UNAME_PROCESSOR=x86_64 ;; powerpc) UNAME_PROCESSOR=powerpc64 ;; esac fi # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_PPC >/dev/null then UNAME_PROCESSOR=powerpc fi elif test "$UNAME_PROCESSOR" = i386 ; then # uname -m returns i386 or x86_64 UNAME_PROCESSOR=$UNAME_MACHINE fi GUESS=$UNAME_PROCESSOR-apple-darwin$UNAME_RELEASE ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = x86; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi GUESS=$UNAME_PROCESSOR-$UNAME_MACHINE-nto-qnx$UNAME_RELEASE ;; *:QNX:*:4*) GUESS=i386-pc-qnx ;; NEO-*:NONSTOP_KERNEL:*:*) GUESS=neo-tandem-nsk$UNAME_RELEASE ;; NSE-*:NONSTOP_KERNEL:*:*) GUESS=nse-tandem-nsk$UNAME_RELEASE ;; NSR-*:NONSTOP_KERNEL:*:*) GUESS=nsr-tandem-nsk$UNAME_RELEASE ;; NSV-*:NONSTOP_KERNEL:*:*) GUESS=nsv-tandem-nsk$UNAME_RELEASE ;; NSX-*:NONSTOP_KERNEL:*:*) GUESS=nsx-tandem-nsk$UNAME_RELEASE ;; *:NonStop-UX:*:*) GUESS=mips-compaq-nonstopux ;; BS2000:POSIX*:*:*) GUESS=bs2000-siemens-sysv ;; DS/*:UNIX_System_V:*:*) GUESS=$UNAME_MACHINE-$UNAME_SYSTEM-$UNAME_RELEASE ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "${cputype-}" = 386; then UNAME_MACHINE=i386 elif test "x${cputype-}" != x; then UNAME_MACHINE=$cputype fi GUESS=$UNAME_MACHINE-unknown-plan9 ;; *:TOPS-10:*:*) GUESS=pdp10-unknown-tops10 ;; *:TENEX:*:*) GUESS=pdp10-unknown-tenex ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) GUESS=pdp10-dec-tops20 ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) GUESS=pdp10-xkl-tops20 ;; *:TOPS-20:*:*) GUESS=pdp10-unknown-tops20 ;; *:ITS:*:*) GUESS=pdp10-unknown-its ;; SEI:*:*:SEIUX) GUESS=mips-sei-seiux$UNAME_RELEASE ;; *:DragonFly:*:*) DRAGONFLY_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` GUESS=$UNAME_MACHINE-unknown-dragonfly$DRAGONFLY_REL ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case $UNAME_MACHINE in A*) GUESS=alpha-dec-vms ;; I*) GUESS=ia64-dec-vms ;; V*) GUESS=vax-dec-vms ;; esac ;; *:XENIX:*:SysV) GUESS=i386-pc-xenix ;; i*86:skyos:*:*) SKYOS_REL=`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'` GUESS=$UNAME_MACHINE-pc-skyos$SKYOS_REL ;; i*86:rdos:*:*) GUESS=$UNAME_MACHINE-pc-rdos ;; i*86:Fiwix:*:*) GUESS=$UNAME_MACHINE-pc-fiwix ;; *:AROS:*:*) GUESS=$UNAME_MACHINE-unknown-aros ;; x86_64:VMkernel:*:*) GUESS=$UNAME_MACHINE-unknown-esx ;; amd64:Isilon\ OneFS:*:*) GUESS=x86_64-unknown-onefs ;; *:Unleashed:*:*) GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE ;; esac # Do we have a guess based on uname results? if test "x$GUESS" != x; then echo "$GUESS" exit fi # No uname command or uname output not recognized. set_cc_for_build cat > "$dummy.c" < #include #endif #if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) #if defined (vax) || defined (__vax) || defined (__vax__) || defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) #include #if defined(_SIZE_T_) || defined(SIGLOST) #include #endif #endif #endif main () { #if defined (sony) #if defined (MIPSEB) /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, I don't know.... */ printf ("mips-sony-bsd\n"); exit (0); #else #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 "4" #else "" #endif ); exit (0); #endif #endif #if defined (NeXT) #if !defined (__ARCHITECTURE__) #define __ARCHITECTURE__ "m68k" #endif int version; version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); exit (0); #endif #if defined (MULTIMAX) || defined (n16) #if defined (UMAXV) printf ("ns32k-encore-sysv\n"); exit (0); #else #if defined (CMU) printf ("ns32k-encore-mach\n"); exit (0); #else printf ("ns32k-encore-bsd\n"); exit (0); #endif #endif #endif #if defined (__386BSD__) printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent) #if defined (i386) printf ("i386-sequent-dynix\n"); exit (0); #endif #if defined (ns32000) printf ("ns32k-sequent-dynix\n"); exit (0); #endif #endif #if defined (_SEQUENT_) struct utsname un; uname(&un); if (strncmp(un.version, "V2", 2) == 0) { printf ("i386-sequent-ptx2\n"); exit (0); } if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ printf ("i386-sequent-ptx1\n"); exit (0); } printf ("i386-sequent-ptx\n"); exit (0); #endif #if defined (vax) #if !defined (ultrix) #include #if defined (BSD) #if BSD == 43 printf ("vax-dec-bsd4.3\n"); exit (0); #else #if BSD == 199006 printf ("vax-dec-bsd4.3reno\n"); exit (0); #else printf ("vax-dec-bsd\n"); exit (0); #endif #endif #else printf ("vax-dec-bsd\n"); exit (0); #endif #else #if defined(_SIZE_T_) || defined(SIGLOST) struct utsname un; uname (&un); printf ("vax-dec-ultrix%s\n", un.release); exit (0); #else printf ("vax-dec-ultrix\n"); exit (0); #endif #endif #endif #if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) #if defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) #if defined(_SIZE_T_) || defined(SIGLOST) struct utsname *un; uname (&un); printf ("mips-dec-ultrix%s\n", un.release); exit (0); #else printf ("mips-dec-ultrix\n"); exit (0); #endif #endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; } echo "$0: unable to guess system type" >&2 case $UNAME_MACHINE:$UNAME_SYSTEM in mips:Linux | mips64:Linux) # If we got here on MIPS GNU/Linux, output extra information. cat >&2 <&2 <&2 </dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = "$UNAME_MACHINE" UNAME_RELEASE = "$UNAME_RELEASE" UNAME_SYSTEM = "$UNAME_SYSTEM" UNAME_VERSION = "$UNAME_VERSION" EOF fi exit 1 # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: mlterm-3.9.3/baselib/script/config.sub000077500000000000000000001057521441203364000177250ustar00rootroot00000000000000#! /bin/sh # Configuration validation subroutine script. # Copyright 1992-2023 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale timestamp='2023-01-21' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that # program. This Exception is an additional permission under section 7 # of the GNU General Public License, version 3 ("GPLv3"). # Please send patches to . # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # You can get the latest version of this script from: # https://git.savannah.gnu.org/cgit/config.git/plain/config.sub # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. # The "shellcheck disable" line above the timestamp inhibits complaints # about features and limitations of the classic Bourne shell that were # superseded or lifted in POSIX. However, this script identifies a wide # variety of pre-POSIX systems that do not have POSIX shells at all, and # even some reasonably current systems (Solaris 10 as case-in-point) still # have a pre-POSIX /bin/sh. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS Canonicalize a configuration name. Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright 1992-2023 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; *local*) # First pass through any local machine types. echo "$1" exit ;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Split fields of configuration type # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read field1 field2 field3 field4 <&2 exit 1 ;; *-*-*-*) basic_machine=$field1-$field2 basic_os=$field3-$field4 ;; *-*-*) # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two # parts maybe_os=$field2-$field3 case $maybe_os in nto-qnx* | linux-* | uclinux-uclibc* \ | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \ | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \ | storm-chaos* | os2-emx* | rtmk-nova* | managarm-*) basic_machine=$field1 basic_os=$maybe_os ;; android-linux) basic_machine=$field1-unknown basic_os=linux-android ;; *) basic_machine=$field1-$field2 basic_os=$field3 ;; esac ;; *-*) # A lone config we happen to match not fitting any pattern case $field1-$field2 in decstation-3100) basic_machine=mips-dec basic_os= ;; *-*) # Second component is usually, but not always the OS case $field2 in # Prevent following clause from handling this valid os sun*os*) basic_machine=$field1 basic_os=$field2 ;; zephyr*) basic_machine=$field1-unknown basic_os=$field2 ;; # Manufacturers dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \ | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \ | unicom* | ibm* | next | hp | isi* | apollo | altos* \ | convergent* | ncr* | news | 32* | 3600* | 3100* \ | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \ | ultra | tti* | harris | dolphin | highlevel | gould \ | cbm | ns | masscomp | apple | axis | knuth | cray \ | microblaze* | sim | cisco \ | oki | wec | wrs | winbond) basic_machine=$field1-$field2 basic_os= ;; *) basic_machine=$field1 basic_os=$field2 ;; esac ;; esac ;; *) # Convert single-component short-hands not valid as part of # multi-component configurations. case $field1 in 386bsd) basic_machine=i386-pc basic_os=bsd ;; a29khif) basic_machine=a29k-amd basic_os=udi ;; adobe68k) basic_machine=m68010-adobe basic_os=scout ;; alliant) basic_machine=fx80-alliant basic_os= ;; altos | altos3068) basic_machine=m68k-altos basic_os= ;; am29k) basic_machine=a29k-none basic_os=bsd ;; amdahl) basic_machine=580-amdahl basic_os=sysv ;; amiga) basic_machine=m68k-unknown basic_os= ;; amigaos | amigados) basic_machine=m68k-unknown basic_os=amigaos ;; amigaunix | amix) basic_machine=m68k-unknown basic_os=sysv4 ;; apollo68) basic_machine=m68k-apollo basic_os=sysv ;; apollo68bsd) basic_machine=m68k-apollo basic_os=bsd ;; aros) basic_machine=i386-pc basic_os=aros ;; aux) basic_machine=m68k-apple basic_os=aux ;; balance) basic_machine=ns32k-sequent basic_os=dynix ;; blackfin) basic_machine=bfin-unknown basic_os=linux ;; cegcc) basic_machine=arm-unknown basic_os=cegcc ;; convex-c1) basic_machine=c1-convex basic_os=bsd ;; convex-c2) basic_machine=c2-convex basic_os=bsd ;; convex-c32) basic_machine=c32-convex basic_os=bsd ;; convex-c34) basic_machine=c34-convex basic_os=bsd ;; convex-c38) basic_machine=c38-convex basic_os=bsd ;; cray) basic_machine=j90-cray basic_os=unicos ;; crds | unos) basic_machine=m68k-crds basic_os= ;; da30) basic_machine=m68k-da30 basic_os= ;; decstation | pmax | pmin | dec3100 | decstatn) basic_machine=mips-dec basic_os= ;; delta88) basic_machine=m88k-motorola basic_os=sysv3 ;; dicos) basic_machine=i686-pc basic_os=dicos ;; djgpp) basic_machine=i586-pc basic_os=msdosdjgpp ;; ebmon29k) basic_machine=a29k-amd basic_os=ebmon ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson basic_os=ose ;; gmicro) basic_machine=tron-gmicro basic_os=sysv ;; go32) basic_machine=i386-pc basic_os=go32 ;; h8300hms) basic_machine=h8300-hitachi basic_os=hms ;; h8300xray) basic_machine=h8300-hitachi basic_os=xray ;; h8500hms) basic_machine=h8500-hitachi basic_os=hms ;; harris) basic_machine=m88k-harris basic_os=sysv3 ;; hp300 | hp300hpux) basic_machine=m68k-hp basic_os=hpux ;; hp300bsd) basic_machine=m68k-hp basic_os=bsd ;; hppaosf) basic_machine=hppa1.1-hp basic_os=osf ;; hppro) basic_machine=hppa1.1-hp basic_os=proelf ;; i386mach) basic_machine=i386-mach basic_os=mach ;; isi68 | isi) basic_machine=m68k-isi basic_os=sysv ;; m68knommu) basic_machine=m68k-unknown basic_os=linux ;; magnum | m3230) basic_machine=mips-mips basic_os=sysv ;; merlin) basic_machine=ns32k-utek basic_os=sysv ;; mingw64) basic_machine=x86_64-pc basic_os=mingw64 ;; mingw32) basic_machine=i686-pc basic_os=mingw32 ;; mingw32ce) basic_machine=arm-unknown basic_os=mingw32ce ;; monitor) basic_machine=m68k-rom68k basic_os=coff ;; morphos) basic_machine=powerpc-unknown basic_os=morphos ;; moxiebox) basic_machine=moxie-unknown basic_os=moxiebox ;; msdos) basic_machine=i386-pc basic_os=msdos ;; msys) basic_machine=i686-pc basic_os=msys ;; mvs) basic_machine=i370-ibm basic_os=mvs ;; nacl) basic_machine=le32-unknown basic_os=nacl ;; ncr3000) basic_machine=i486-ncr basic_os=sysv4 ;; netbsd386) basic_machine=i386-pc basic_os=netbsd ;; netwinder) basic_machine=armv4l-rebel basic_os=linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony basic_os=newsos ;; news1000) basic_machine=m68030-sony basic_os=newsos ;; necv70) basic_machine=v70-nec basic_os=sysv ;; nh3000) basic_machine=m68k-harris basic_os=cxux ;; nh[45]000) basic_machine=m88k-harris basic_os=cxux ;; nindy960) basic_machine=i960-intel basic_os=nindy ;; mon960) basic_machine=i960-intel basic_os=mon960 ;; nonstopux) basic_machine=mips-compaq basic_os=nonstopux ;; os400) basic_machine=powerpc-ibm basic_os=os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson basic_os=ose ;; os68k) basic_machine=m68k-none basic_os=os68k ;; paragon) basic_machine=i860-intel basic_os=osf ;; parisc) basic_machine=hppa-unknown basic_os=linux ;; psp) basic_machine=mipsallegrexel-sony basic_os=psp ;; pw32) basic_machine=i586-unknown basic_os=pw32 ;; rdos | rdos64) basic_machine=x86_64-pc basic_os=rdos ;; rdos32) basic_machine=i386-pc basic_os=rdos ;; rom68k) basic_machine=m68k-rom68k basic_os=coff ;; sa29200) basic_machine=a29k-amd basic_os=udi ;; sei) basic_machine=mips-sei basic_os=seiux ;; sequent) basic_machine=i386-sequent basic_os= ;; sps7) basic_machine=m68k-bull basic_os=sysv2 ;; st2000) basic_machine=m68k-tandem basic_os= ;; stratus) basic_machine=i860-stratus basic_os=sysv4 ;; sun2) basic_machine=m68000-sun basic_os= ;; sun2os3) basic_machine=m68000-sun basic_os=sunos3 ;; sun2os4) basic_machine=m68000-sun basic_os=sunos4 ;; sun3) basic_machine=m68k-sun basic_os= ;; sun3os3) basic_machine=m68k-sun basic_os=sunos3 ;; sun3os4) basic_machine=m68k-sun basic_os=sunos4 ;; sun4) basic_machine=sparc-sun basic_os= ;; sun4os3) basic_machine=sparc-sun basic_os=sunos3 ;; sun4os4) basic_machine=sparc-sun basic_os=sunos4 ;; sun4sol2) basic_machine=sparc-sun basic_os=solaris2 ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun basic_os= ;; sv1) basic_machine=sv1-cray basic_os=unicos ;; symmetry) basic_machine=i386-sequent basic_os=dynix ;; t3e) basic_machine=alphaev5-cray basic_os=unicos ;; t90) basic_machine=t90-cray basic_os=unicos ;; toad1) basic_machine=pdp10-xkl basic_os=tops20 ;; tpf) basic_machine=s390x-ibm basic_os=tpf ;; udi29k) basic_machine=a29k-amd basic_os=udi ;; ultra3) basic_machine=a29k-nyu basic_os=sym1 ;; v810 | necv810) basic_machine=v810-nec basic_os=none ;; vaxv) basic_machine=vax-dec basic_os=sysv ;; vms) basic_machine=vax-dec basic_os=vms ;; vsta) basic_machine=i386-pc basic_os=vsta ;; vxworks960) basic_machine=i960-wrs basic_os=vxworks ;; vxworks68) basic_machine=m68k-wrs basic_os=vxworks ;; vxworks29k) basic_machine=a29k-wrs basic_os=vxworks ;; xbox) basic_machine=i686-pc basic_os=mingw32 ;; ymp) basic_machine=ymp-cray basic_os=unicos ;; *) basic_machine=$1 basic_os= ;; esac ;; esac # Decode 1-component or ad-hoc basic machines case $basic_machine in # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) cpu=hppa1.1 vendor=winbond ;; op50n) cpu=hppa1.1 vendor=oki ;; op60c) cpu=hppa1.1 vendor=oki ;; ibm*) cpu=i370 vendor=ibm ;; orion105) cpu=clipper vendor=highlevel ;; mac | mpw | mac-mpw) cpu=m68k vendor=apple ;; pmac | pmac-mpw) cpu=powerpc vendor=apple ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) cpu=m68000 vendor=att ;; 3b*) cpu=we32k vendor=att ;; bluegene*) cpu=powerpc vendor=ibm basic_os=cnk ;; decsystem10* | dec10*) cpu=pdp10 vendor=dec basic_os=tops10 ;; decsystem20* | dec20*) cpu=pdp10 vendor=dec basic_os=tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) cpu=m68k vendor=motorola ;; dpx2*) cpu=m68k vendor=bull basic_os=sysv3 ;; encore | umax | mmax) cpu=ns32k vendor=encore ;; elxsi) cpu=elxsi vendor=elxsi basic_os=${basic_os:-bsd} ;; fx2800) cpu=i860 vendor=alliant ;; genix) cpu=ns32k vendor=ns ;; h3050r* | hiux*) cpu=hppa1.1 vendor=hitachi basic_os=hiuxwe2 ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) cpu=hppa1.0 vendor=hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) cpu=m68000 vendor=hp ;; hp9k3[2-9][0-9]) cpu=m68k vendor=hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) cpu=hppa1.0 vendor=hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) cpu=hppa1.1 vendor=hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp cpu=hppa1.1 vendor=hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp cpu=hppa1.1 vendor=hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) cpu=hppa1.1 vendor=hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) cpu=hppa1.0 vendor=hp ;; i*86v32) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=sysv32 ;; i*86v4*) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=sysv4 ;; i*86v) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=sysv ;; i*86sol2) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc basic_os=solaris2 ;; j90 | j90-cray) cpu=j90 vendor=cray basic_os=${basic_os:-unicos} ;; iris | iris4d) cpu=mips vendor=sgi case $basic_os in irix*) ;; *) basic_os=irix4 ;; esac ;; miniframe) cpu=m68000 vendor=convergent ;; *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*) cpu=m68k vendor=atari basic_os=mint ;; news-3600 | risc-news) cpu=mips vendor=sony basic_os=newsos ;; next | m*-next) cpu=m68k vendor=next case $basic_os in openstep*) ;; nextstep*) ;; ns2*) basic_os=nextstep2 ;; *) basic_os=nextstep3 ;; esac ;; np1) cpu=np1 vendor=gould ;; op50n-* | op60c-*) cpu=hppa1.1 vendor=oki basic_os=proelf ;; pa-hitachi) cpu=hppa1.1 vendor=hitachi basic_os=hiuxwe2 ;; pbd) cpu=sparc vendor=tti ;; pbb) cpu=m68k vendor=tti ;; pc532) cpu=ns32k vendor=pc532 ;; pn) cpu=pn vendor=gould ;; power) cpu=power vendor=ibm ;; ps2) cpu=i386 vendor=ibm ;; rm[46]00) cpu=mips vendor=siemens ;; rtpc | rtpc-*) cpu=romp vendor=ibm ;; sde) cpu=mipsisa32 vendor=sde basic_os=${basic_os:-elf} ;; simso-wrs) cpu=sparclite vendor=wrs basic_os=vxworks ;; tower | tower-32) cpu=m68k vendor=ncr ;; vpp*|vx|vx-*) cpu=f301 vendor=fujitsu ;; w65) cpu=w65 vendor=wdc ;; w89k-*) cpu=hppa1.1 vendor=winbond basic_os=proelf ;; none) cpu=none vendor=none ;; leon|leon[3-9]) cpu=sparc vendor=$basic_machine ;; leon-*|leon[3-9]-*) cpu=sparc vendor=`echo "$basic_machine" | sed 's/-.*//'` ;; *-*) # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read cpu vendor <&2 exit 1 ;; esac ;; esac # Here we canonicalize certain aliases for manufacturers. case $vendor in digital*) vendor=dec ;; commodore*) vendor=cbm ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if test x$basic_os != x then # First recognize some ad-hoc cases, or perhaps split kernel-os, or else just # set os. case $basic_os in gnu/linux*) kernel=linux os=`echo "$basic_os" | sed -e 's|gnu/linux|gnu|'` ;; os2-emx) kernel=os2 os=`echo "$basic_os" | sed -e 's|os2-emx|emx|'` ;; nto-qnx*) kernel=nto os=`echo "$basic_os" | sed -e 's|nto-qnx|qnx|'` ;; *-*) # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read kernel os <&2 exit 1 ;; esac # As a final step for OS-related things, validate the OS-kernel combination # (given a valid OS), if there is a kernel. case $kernel-$os in linux-gnu* | linux-dietlibc* | linux-android* | linux-newlib* \ | linux-musl* | linux-relibc* | linux-uclibc* | linux-mlibc* ) ;; uclinux-uclibc* ) ;; managarm-mlibc* | managarm-kernel* ) ;; -dietlibc* | -newlib* | -musl* | -relibc* | -uclibc* | -mlibc* ) # These are just libc implementations, not actual OSes, and thus # require a kernel. echo "Invalid configuration \`$1': libc \`$os' needs explicit kernel." 1>&2 exit 1 ;; -kernel* ) echo "Invalid configuration \`$1': \`$os' needs explicit kernel." 1>&2 exit 1 ;; *-kernel* ) echo "Invalid configuration \`$1': \`$kernel' does not support \`$os'." 1>&2 exit 1 ;; kfreebsd*-gnu* | kopensolaris*-gnu*) ;; vxworks-simlinux | vxworks-simwindows | vxworks-spe) ;; nto-qnx*) ;; os2-emx) ;; *-eabi* | *-gnueabi*) ;; -*) # Blank kernel with real OS is always fine. ;; *-*) echo "Invalid configuration \`$1': Kernel \`$kernel' not known to work with OS \`$os'." 1>&2 exit 1 ;; esac # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. case $vendor in unknown) case $cpu-$os in *-riscix*) vendor=acorn ;; *-sunos*) vendor=sun ;; *-cnk* | *-aix*) vendor=ibm ;; *-beos*) vendor=be ;; *-hpux*) vendor=hp ;; *-mpeix*) vendor=hp ;; *-hiux*) vendor=hitachi ;; *-unos*) vendor=crds ;; *-dgux*) vendor=dg ;; *-luna*) vendor=omron ;; *-genix*) vendor=ns ;; *-clix*) vendor=intergraph ;; *-mvs* | *-opened*) vendor=ibm ;; *-os400*) vendor=ibm ;; s390-* | s390x-*) vendor=ibm ;; *-ptx*) vendor=sequent ;; *-tpf*) vendor=ibm ;; *-vxsim* | *-vxworks* | *-windiss*) vendor=wrs ;; *-aux*) vendor=apple ;; *-hms*) vendor=hitachi ;; *-mpw* | *-macos*) vendor=apple ;; *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*) vendor=atari ;; *-vos*) vendor=stratus ;; esac ;; esac echo "$cpu-$vendor-${kernel:+$kernel-}$os" exit # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: mlterm-3.9.3/baselib/script/install-sh000077500000000000000000000357761441203364000177560ustar00rootroot00000000000000#!/bin/sh # install - install a program, script, or datafile scriptversion=2020-11-14.01; # UTC # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 X Consortium # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to # deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or # sell copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # # Except as contained in this notice, the name of the X Consortium shall not # be used in advertising or otherwise to promote the sale, use or other deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # 'make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. tab=' ' nl=' ' IFS=" $tab$nl" # Set DOITPROG to "echo" to test this script. doit=${DOITPROG-} doit_exec=${doit:-exec} # Put in absolute file names if you don't have them in your path; # or use environment vars. chgrpprog=${CHGRPPROG-chgrp} chmodprog=${CHMODPROG-chmod} chownprog=${CHOWNPROG-chown} cmpprog=${CMPPROG-cmp} cpprog=${CPPROG-cp} mkdirprog=${MKDIRPROG-mkdir} mvprog=${MVPROG-mv} rmprog=${RMPROG-rm} stripprog=${STRIPPROG-strip} posix_mkdir= # Desired mode of installed file. mode=0755 # Create dirs (including intermediate dirs) using mode 755. # This is like GNU 'install' as of coreutils 8.32 (2020). mkdir_umask=22 backupsuffix= chgrpcmd= chmodcmd=$chmodprog chowncmd= mvcmd=$mvprog rmcmd="$rmprog -f" stripcmd= src= dst= dir_arg= dst_arg= copy_on_change=false is_target_a_directory=possibly usage="\ Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE or: $0 [OPTION]... SRCFILES... DIRECTORY or: $0 [OPTION]... -t DIRECTORY SRCFILES... or: $0 [OPTION]... -d DIRECTORIES... In the 1st form, copy SRCFILE to DSTFILE. In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. In the 4th, create DIRECTORIES. Options: --help display this help and exit. --version display version info and exit. -c (ignored) -C install only if different (preserve data modification time) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. -p pass -p to $cpprog. -s $stripprog installed files. -S SUFFIX attempt to back up existing files, with suffix SUFFIX. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG By default, rm is invoked with -f; when overridden with RMPROG, it's up to you to specify -f if you want it. If -S is not specified, no backups are attempted. Email bug reports to bug-automake@gnu.org. Automake home page: https://www.gnu.org/software/automake/ " while test $# -ne 0; do case $1 in -c) ;; -C) copy_on_change=true;; -d) dir_arg=true;; -g) chgrpcmd="$chgrpprog $2" shift;; --help) echo "$usage"; exit $?;; -m) mode=$2 case $mode in *' '* | *"$tab"* | *"$nl"* | *'*'* | *'?'* | *'['*) echo "$0: invalid mode: $mode" >&2 exit 1;; esac shift;; -o) chowncmd="$chownprog $2" shift;; -p) cpprog="$cpprog -p";; -s) stripcmd=$stripprog;; -S) backupsuffix="$2" shift;; -t) is_target_a_directory=always dst_arg=$2 # Protect names problematic for 'test' and other utilities. case $dst_arg in -* | [=\(\)!]) dst_arg=./$dst_arg;; esac shift;; -T) is_target_a_directory=never;; --version) echo "$0 $scriptversion"; exit $?;; --) shift break;; -*) echo "$0: invalid option: $1" >&2 exit 1;; *) break;; esac shift done # We allow the use of options -d and -T together, by making -d # take the precedence; this is for compatibility with GNU install. if test -n "$dir_arg"; then if test -n "$dst_arg"; then echo "$0: target directory not allowed when installing a directory." >&2 exit 1 fi fi if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then # When -d is used, all remaining arguments are directories to create. # When -t is used, the destination is already specified. # Otherwise, the last argument is the destination. Remove it from $@. for arg do if test -n "$dst_arg"; then # $@ is not empty: it contains at least $arg. set fnord "$@" "$dst_arg" shift # fnord fi shift # arg dst_arg=$arg # Protect names problematic for 'test' and other utilities. case $dst_arg in -* | [=\(\)!]) dst_arg=./$dst_arg;; esac done fi if test $# -eq 0; then if test -z "$dir_arg"; then echo "$0: no input file specified." >&2 exit 1 fi # It's OK to call 'install-sh -d' without argument. # This can happen when creating conditional directories. exit 0 fi if test -z "$dir_arg"; then if test $# -gt 1 || test "$is_target_a_directory" = always; then if test ! -d "$dst_arg"; then echo "$0: $dst_arg: Is not a directory." >&2 exit 1 fi fi fi if test -z "$dir_arg"; then do_exit='(exit $ret); exit $ret' trap "ret=129; $do_exit" 1 trap "ret=130; $do_exit" 2 trap "ret=141; $do_exit" 13 trap "ret=143; $do_exit" 15 # Set umask so as not to create temps with too-generous modes. # However, 'strip' requires both read and write access to temps. case $mode in # Optimize common cases. *644) cp_umask=133;; *755) cp_umask=22;; *[0-7]) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw='% 200' fi cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; *) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw=,u+rw fi cp_umask=$mode$u_plus_rw;; esac fi for src do # Protect names problematic for 'test' and other utilities. case $src in -* | [=\(\)!]) src=./$src;; esac if test -n "$dir_arg"; then dst=$src dstdir=$dst test -d "$dstdir" dstdir_status=$? # Don't chown directories that already exist. if test $dstdir_status = 0; then chowncmd="" fi else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if test ! -f "$src" && test ! -d "$src"; then echo "$0: $src does not exist." >&2 exit 1 fi if test -z "$dst_arg"; then echo "$0: no destination specified." >&2 exit 1 fi dst=$dst_arg # If destination is a directory, append the input filename. if test -d "$dst"; then if test "$is_target_a_directory" = never; then echo "$0: $dst_arg: Is a directory" >&2 exit 1 fi dstdir=$dst dstbase=`basename "$src"` case $dst in */) dst=$dst$dstbase;; *) dst=$dst/$dstbase;; esac dstdir_status=0 else dstdir=`dirname "$dst"` test -d "$dstdir" dstdir_status=$? fi fi case $dstdir in */) dstdirslash=$dstdir;; *) dstdirslash=$dstdir/;; esac obsolete_mkdir_used=false if test $dstdir_status != 0; then case $posix_mkdir in '') # With -d, create the new directory with the user-specified mode. # Otherwise, rely on $mkdir_umask. if test -n "$dir_arg"; then mkdir_mode=-m$mode else mkdir_mode= fi posix_mkdir=false # The $RANDOM variable is not portable (e.g., dash). Use it # here however when possible just to lower collision chance. tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ trap ' ret=$? rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null exit $ret ' 0 # Because "mkdir -p" follows existing symlinks and we likely work # directly in world-writeable /tmp, make sure that the '$tmpdir' # directory is successfully created first before we actually test # 'mkdir -p'. if (umask $mkdir_umask && $mkdirprog $mkdir_mode "$tmpdir" && exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 then if test -z "$dir_arg" || { # Check for POSIX incompatibilities with -m. # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or # other-writable bit of parent directory when it shouldn't. # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. test_tmpdir="$tmpdir/a" ls_ld_tmpdir=`ls -ld "$test_tmpdir"` case $ls_ld_tmpdir in d????-?r-*) different_mode=700;; d????-?--*) different_mode=755;; *) false;; esac && $mkdirprog -m$different_mode -p -- "$test_tmpdir" && { ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"` test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" } } then posix_mkdir=: fi rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" else # Remove any dirs left behind by ancient mkdir implementations. rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null fi trap '' 0;; esac if $posix_mkdir && ( umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" ) then : else # mkdir does not conform to POSIX, # or it failed possibly due to a race condition. Create the # directory the slow way, step by step, checking for races as we go. case $dstdir in /*) prefix='/';; [-=\(\)!]*) prefix='./';; *) prefix='';; esac oIFS=$IFS IFS=/ set -f set fnord $dstdir shift set +f IFS=$oIFS prefixes= for d do test X"$d" = X && continue prefix=$prefix$d if test -d "$prefix"; then prefixes= else if $posix_mkdir; then (umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break # Don't fail if two instances are running concurrently. test -d "$prefix" || exit 1 else case $prefix in *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; *) qprefix=$prefix;; esac prefixes="$prefixes '$qprefix'" fi fi prefix=$prefix/ done if test -n "$prefixes"; then # Don't fail if two instances are running concurrently. (umask $mkdir_umask && eval "\$doit_exec \$mkdirprog $prefixes") || test -d "$dstdir" || exit 1 obsolete_mkdir_used=true fi fi fi if test -n "$dir_arg"; then { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 else # Make a couple of temp file names in the proper directory. dsttmp=${dstdirslash}_inst.$$_ rmtmp=${dstdirslash}_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 # Copy the file name to the temp name. (umask $cp_umask && { test -z "$stripcmd" || { # Create $dsttmp read-write so that cp doesn't create it read-only, # which would cause strip to fail. if test -z "$doit"; then : >"$dsttmp" # No need to fork-exec 'touch'. else $doit touch "$dsttmp" fi } } && $doit_exec $cpprog "$src" "$dsttmp") && # and set any options; do chmod last to preserve setuid bits. # # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $cpprog $src $dsttmp" command. # { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && # If -C, don't bother to copy if it wouldn't change the file. if $copy_on_change && old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && set -f && set X $old && old=:$2:$4:$5:$6 && set X $new && new=:$2:$4:$5:$6 && set +f && test "$old" = "$new" && $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 then rm -f "$dsttmp" else # If $backupsuffix is set, and the file being installed # already exists, attempt a backup. Don't worry if it fails, # e.g., if mv doesn't support -f. if test -n "$backupsuffix" && test -f "$dst"; then $doit $mvcmd -f "$dst" "$dst$backupsuffix" 2>/dev/null fi # Rename the file to the real destination. $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || # The rename failed, perhaps because mv can't rename something else # to itself, or perhaps because mv is so ancient that it does not # support -f. { # Now remove or move aside any old file at destination location. # We try this two ways since rm can't unlink itself on some # systems and the destination file might be busy for other # reasons. In this case, the final cleanup might fail but the new # file should still install successfully. { test ! -f "$dst" || $doit $rmcmd "$dst" 2>/dev/null || { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && { $doit $rmcmd "$rmtmp" 2>/dev/null; :; } } || { echo "$0: cannot unlink or rename $dst" >&2 (exit 1); exit 1 } } && # Now rename the file to the real destination. $doit $mvcmd "$dsttmp" "$dst" } fi || exit 1 trap '' 0 fi done # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: mlterm-3.9.3/baselib/script/ltmain.sh000077500000000000000000012123531441203364000175620ustar00rootroot00000000000000#! /usr/bin/env sh ## DO NOT EDIT - This file generated from ./build-aux/ltmain.in ## by inline-source v2019-02-19.15 # libtool (GNU libtool) 2.4.7 # Provide generalized library-building support services. # Written by Gordon Matzigkeit , 1996 # Copyright (C) 1996-2019, 2021-2022 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, # if you distribute this file as part of a program or library that # is built using GNU Libtool, you may include this file under the # same distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . PROGRAM=libtool PACKAGE=libtool VERSION=2.4.7 package_revision=2.4.7 ## ------ ## ## Usage. ## ## ------ ## # Run './libtool --help' for help with using this script from the # command line. ## ------------------------------- ## ## User overridable command paths. ## ## ------------------------------- ## # After configure completes, it has a better idea of some of the # shell tools we need than the defaults used by the functions shared # with bootstrap, so set those here where they can still be over- # ridden by the user, but otherwise take precedence. : ${AUTOCONF="autoconf"} : ${AUTOMAKE="automake"} ## -------------------------- ## ## Source external libraries. ## ## -------------------------- ## # Much of our low-level functionality needs to be sourced from external # libraries, which are installed to $pkgauxdir. # Set a version string for this script. scriptversion=2019-02-19.15; # UTC # General shell script boiler plate, and helper functions. # Written by Gary V. Vaughan, 2004 # This is free software. There is NO warranty; not even for # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # # Copyright (C) 2004-2019, 2021 Bootstrap Authors # # This file is dual licensed under the terms of the MIT license # , and GPL version 2 or later # . You must apply one of # these licenses when using or redistributing this software or any of # the files within it. See the URLs above, or the file `LICENSE` # included in the Bootstrap distribution for the full license texts. # Please report bugs or propose patches to: # ## ------ ## ## Usage. ## ## ------ ## # Evaluate this file near the top of your script to gain access to # the functions and variables defined here: # # . `echo "$0" | ${SED-sed} 's|[^/]*$||'`/build-aux/funclib.sh # # If you need to override any of the default environment variable # settings, do that before evaluating this file. ## -------------------- ## ## Shell normalisation. ## ## -------------------- ## # Some shells need a little help to be as Bourne compatible as possible. # Before doing anything else, make sure all that help has been provided! DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # NLS nuisances: We save the old values in case they are required later. _G_user_locale= _G_safe_locale= for _G_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test set = \"\${$_G_var+set}\"; then save_$_G_var=\$$_G_var $_G_var=C export $_G_var _G_user_locale=\"$_G_var=\\\$save_\$_G_var; \$_G_user_locale\" _G_safe_locale=\"$_G_var=C; \$_G_safe_locale\" fi" done # These NLS vars are set unconditionally (bootstrap issue #24). Unset those # in case the environment reset is needed later and the $save_* variant is not # defined (see the code above). LC_ALL=C LANGUAGE=C export LANGUAGE LC_ALL # Make sure IFS has a sensible default sp=' ' nl=' ' IFS="$sp $nl" # There are apparently some retarded systems that use ';' as a PATH separator! if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # func_unset VAR # -------------- # Portably unset VAR. # In some shells, an 'unset VAR' statement leaves a non-zero return # status if VAR is already unset, which might be problematic if the # statement is used at the end of a function (thus poisoning its return # value) or when 'set -e' is active (causing even a spurious abort of # the script in this case). func_unset () { { eval $1=; (eval unset $1) >/dev/null 2>&1 && eval unset $1 || : ; } } # Make sure CDPATH doesn't cause `cd` commands to output the target dir. func_unset CDPATH # Make sure ${,E,F}GREP behave sanely. func_unset GREP_OPTIONS ## ------------------------- ## ## Locate command utilities. ## ## ------------------------- ## # func_executable_p FILE # ---------------------- # Check that FILE is an executable regular file. func_executable_p () { test -f "$1" && test -x "$1" } # func_path_progs PROGS_LIST CHECK_FUNC [PATH] # -------------------------------------------- # Search for either a program that responds to --version with output # containing "GNU", or else returned by CHECK_FUNC otherwise, by # trying all the directories in PATH with each of the elements of # PROGS_LIST. # # CHECK_FUNC should accept the path to a candidate program, and # set $func_check_prog_result if it truncates its output less than # $_G_path_prog_max characters. func_path_progs () { _G_progs_list=$1 _G_check_func=$2 _G_PATH=${3-"$PATH"} _G_path_prog_max=0 _G_path_prog_found=false _G_save_IFS=$IFS; IFS=${PATH_SEPARATOR-:} for _G_dir in $_G_PATH; do IFS=$_G_save_IFS test -z "$_G_dir" && _G_dir=. for _G_prog_name in $_G_progs_list; do for _exeext in '' .EXE; do _G_path_prog=$_G_dir/$_G_prog_name$_exeext func_executable_p "$_G_path_prog" || continue case `"$_G_path_prog" --version 2>&1` in *GNU*) func_path_progs_result=$_G_path_prog _G_path_prog_found=: ;; *) $_G_check_func $_G_path_prog func_path_progs_result=$func_check_prog_result ;; esac $_G_path_prog_found && break 3 done done done IFS=$_G_save_IFS test -z "$func_path_progs_result" && { echo "no acceptable sed could be found in \$PATH" >&2 exit 1 } } # We want to be able to use the functions in this file before configure # has figured out where the best binaries are kept, which means we have # to search for them ourselves - except when the results are already set # where we skip the searches. # Unless the user overrides by setting SED, search the path for either GNU # sed, or the sed that truncates its output the least. test -z "$SED" && { _G_sed_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for _G_i in 1 2 3 4 5 6 7; do _G_sed_script=$_G_sed_script$nl$_G_sed_script done echo "$_G_sed_script" 2>/dev/null | sed 99q >conftest.sed _G_sed_script= func_check_prog_sed () { _G_path_prog=$1 _G_count=0 printf 0123456789 >conftest.in while : do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo '' >> conftest.nl "$_G_path_prog" -f conftest.sed conftest.out 2>/dev/null || break diff conftest.out conftest.nl >/dev/null 2>&1 || break _G_count=`expr $_G_count + 1` if test "$_G_count" -gt "$_G_path_prog_max"; then # Best one so far, save it but keep looking for a better one func_check_prog_result=$_G_path_prog _G_path_prog_max=$_G_count fi # 10*(2^10) chars as input seems more than enough test 10 -lt "$_G_count" && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out } func_path_progs "sed gsed" func_check_prog_sed "$PATH:/usr/xpg4/bin" rm -f conftest.sed SED=$func_path_progs_result } # Unless the user overrides by setting GREP, search the path for either GNU # grep, or the grep that truncates its output the least. test -z "$GREP" && { func_check_prog_grep () { _G_path_prog=$1 _G_count=0 _G_path_prog_max=0 printf 0123456789 >conftest.in while : do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo 'GREP' >> conftest.nl "$_G_path_prog" -e 'GREP$' -e '-(cannot match)-' conftest.out 2>/dev/null || break diff conftest.out conftest.nl >/dev/null 2>&1 || break _G_count=`expr $_G_count + 1` if test "$_G_count" -gt "$_G_path_prog_max"; then # Best one so far, save it but keep looking for a better one func_check_prog_result=$_G_path_prog _G_path_prog_max=$_G_count fi # 10*(2^10) chars as input seems more than enough test 10 -lt "$_G_count" && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out } func_path_progs "grep ggrep" func_check_prog_grep "$PATH:/usr/xpg4/bin" GREP=$func_path_progs_result } ## ------------------------------- ## ## User overridable command paths. ## ## ------------------------------- ## # All uppercase variable names are used for environment variables. These # variables can be overridden by the user before calling a script that # uses them if a suitable command of that name is not already available # in the command search PATH. : ${CP="cp -f"} : ${ECHO="printf %s\n"} : ${EGREP="$GREP -E"} : ${FGREP="$GREP -F"} : ${LN_S="ln -s"} : ${MAKE="make"} : ${MKDIR="mkdir"} : ${MV="mv -f"} : ${RM="rm -f"} : ${SHELL="${CONFIG_SHELL-/bin/sh}"} ## -------------------- ## ## Useful sed snippets. ## ## -------------------- ## sed_dirname='s|/[^/]*$||' sed_basename='s|^.*/||' # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. sed_quote_subst='s|\([`"$\\]\)|\\\1|g' # Same as above, but do not quote variable references. sed_double_quote_subst='s/\(["`\\]\)/\\\1/g' # Sed substitution that turns a string into a regex matching for the # string literally. sed_make_literal_regex='s|[].[^$\\*\/]|\\&|g' # Sed substitution that converts a w32 file name or path # that contains forward slashes, into one that contains # (escaped) backslashes. A very naive implementation. sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' # Re-'\' parameter expansions in output of sed_double_quote_subst that # were '\'-ed in input to the same. If an odd number of '\' preceded a # '$' in input to sed_double_quote_subst, that '$' was protected from # expansion. Since each input '\' is now two '\'s, look for any number # of runs of four '\'s followed by two '\'s and then a '$'. '\' that '$'. _G_bs='\\' _G_bs2='\\\\' _G_bs4='\\\\\\\\' _G_dollar='\$' sed_double_backslash="\ s/$_G_bs4/&\\ /g s/^$_G_bs2$_G_dollar/$_G_bs&/ s/\\([^$_G_bs]\\)$_G_bs2$_G_dollar/\\1$_G_bs2$_G_bs$_G_dollar/g s/\n//g" # require_check_ifs_backslash # --------------------------- # Check if we can use backslash as IFS='\' separator, and set # $check_ifs_backshlash_broken to ':' or 'false'. require_check_ifs_backslash=func_require_check_ifs_backslash func_require_check_ifs_backslash () { _G_save_IFS=$IFS IFS='\' _G_check_ifs_backshlash='a\\b' for _G_i in $_G_check_ifs_backshlash do case $_G_i in a) check_ifs_backshlash_broken=false ;; '') break ;; *) check_ifs_backshlash_broken=: break ;; esac done IFS=$_G_save_IFS require_check_ifs_backslash=: } ## ----------------- ## ## Global variables. ## ## ----------------- ## # Except for the global variables explicitly listed below, the following # functions in the '^func_' namespace, and the '^require_' namespace # variables initialised in the 'Resource management' section, sourcing # this file will not pollute your global namespace with anything # else. There's no portable way to scope variables in Bourne shell # though, so actually running these functions will sometimes place # results into a variable named after the function, and often use # temporary variables in the '^_G_' namespace. If you are careful to # avoid using those namespaces casually in your sourcing script, things # should continue to work as you expect. And, of course, you can freely # overwrite any of the functions or variables defined here before # calling anything to customize them. EXIT_SUCCESS=0 EXIT_FAILURE=1 EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. # Allow overriding, eg assuming that you follow the convention of # putting '$debug_cmd' at the start of all your functions, you can get # bash to show function call trace with: # # debug_cmd='eval echo "${FUNCNAME[0]} $*" >&2' bash your-script-name debug_cmd=${debug_cmd-":"} exit_cmd=: # By convention, finish your script with: # # exit $exit_status # # so that you can set exit_status to non-zero if you want to indicate # something went wrong during execution without actually bailing out at # the point of failure. exit_status=$EXIT_SUCCESS # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh # is ksh but when the shell is invoked as "sh" and the current value of # the _XPG environment variable is not equal to 1 (one), the special # positional parameter $0, within a function call, is the name of the # function. progpath=$0 # The name of this program. progname=`$ECHO "$progpath" |$SED "$sed_basename"` # Make sure we have an absolute progpath for reexecution: case $progpath in [\\/]*|[A-Za-z]:\\*) ;; *[\\/]*) progdir=`$ECHO "$progpath" |$SED "$sed_dirname"` progdir=`cd "$progdir" && pwd` progpath=$progdir/$progname ;; *) _G_IFS=$IFS IFS=${PATH_SEPARATOR-:} for progdir in $PATH; do IFS=$_G_IFS test -x "$progdir/$progname" && break done IFS=$_G_IFS test -n "$progdir" || progdir=`pwd` progpath=$progdir/$progname ;; esac ## ----------------- ## ## Standard options. ## ## ----------------- ## # The following options affect the operation of the functions defined # below, and should be set appropriately depending on run-time para- # meters passed on the command line. opt_dry_run=false opt_quiet=false opt_verbose=false # Categories 'all' and 'none' are always available. Append any others # you will pass as the first argument to func_warning from your own # code. warning_categories= # By default, display warnings according to 'opt_warning_types'. Set # 'warning_func' to ':' to elide all warnings, or func_fatal_error to # treat the next displayed warning as a fatal error. warning_func=func_warn_and_continue # Set to 'all' to display all warnings, 'none' to suppress all # warnings, or a space delimited list of some subset of # 'warning_categories' to display only the listed warnings. opt_warning_types=all ## -------------------- ## ## Resource management. ## ## -------------------- ## # This section contains definitions for functions that each ensure a # particular resource (a file, or a non-empty configuration variable for # example) is available, and if appropriate to extract default values # from pertinent package files. Call them using their associated # 'require_*' variable to ensure that they are executed, at most, once. # # It's entirely deliberate that calling these functions can set # variables that don't obey the namespace limitations obeyed by the rest # of this file, in order that that they be as useful as possible to # callers. # require_term_colors # ------------------- # Allow display of bold text on terminals that support it. require_term_colors=func_require_term_colors func_require_term_colors () { $debug_cmd test -t 1 && { # COLORTERM and USE_ANSI_COLORS environment variables take # precedence, because most terminfo databases neglect to describe # whether color sequences are supported. test -n "${COLORTERM+set}" && : ${USE_ANSI_COLORS="1"} if test 1 = "$USE_ANSI_COLORS"; then # Standard ANSI escape sequences tc_reset='' tc_bold=''; tc_standout='' tc_red=''; tc_green='' tc_blue=''; tc_cyan='' else # Otherwise trust the terminfo database after all. test -n "`tput sgr0 2>/dev/null`" && { tc_reset=`tput sgr0` test -n "`tput bold 2>/dev/null`" && tc_bold=`tput bold` tc_standout=$tc_bold test -n "`tput smso 2>/dev/null`" && tc_standout=`tput smso` test -n "`tput setaf 1 2>/dev/null`" && tc_red=`tput setaf 1` test -n "`tput setaf 2 2>/dev/null`" && tc_green=`tput setaf 2` test -n "`tput setaf 4 2>/dev/null`" && tc_blue=`tput setaf 4` test -n "`tput setaf 5 2>/dev/null`" && tc_cyan=`tput setaf 5` } fi } require_term_colors=: } ## ----------------- ## ## Function library. ## ## ----------------- ## # This section contains a variety of useful functions to call in your # scripts. Take note of the portable wrappers for features provided by # some modern shells, which will fall back to slower equivalents on # less featureful shells. # func_append VAR VALUE # --------------------- # Append VALUE onto the existing contents of VAR. # We should try to minimise forks, especially on Windows where they are # unreasonably slow, so skip the feature probes when bash or zsh are # being used: if test set = "${BASH_VERSION+set}${ZSH_VERSION+set}"; then : ${_G_HAVE_ARITH_OP="yes"} : ${_G_HAVE_XSI_OPS="yes"} # The += operator was introduced in bash 3.1 case $BASH_VERSION in [12].* | 3.0 | 3.0*) ;; *) : ${_G_HAVE_PLUSEQ_OP="yes"} ;; esac fi # _G_HAVE_PLUSEQ_OP # Can be empty, in which case the shell is probed, "yes" if += is # useable or anything else if it does not work. test -z "$_G_HAVE_PLUSEQ_OP" \ && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null \ && _G_HAVE_PLUSEQ_OP=yes if test yes = "$_G_HAVE_PLUSEQ_OP" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_append () { $debug_cmd eval "$1+=\$2" }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_append () { $debug_cmd eval "$1=\$$1\$2" } fi # func_append_quoted VAR VALUE # ---------------------------- # Quote VALUE and append to the end of shell variable VAR, separated # by a space. if test yes = "$_G_HAVE_PLUSEQ_OP"; then eval 'func_append_quoted () { $debug_cmd func_quote_arg pretty "$2" eval "$1+=\\ \$func_quote_arg_result" }' else func_append_quoted () { $debug_cmd func_quote_arg pretty "$2" eval "$1=\$$1\\ \$func_quote_arg_result" } fi # func_append_uniq VAR VALUE # -------------------------- # Append unique VALUE onto the existing contents of VAR, assuming # entries are delimited by the first character of VALUE. For example: # # func_append_uniq options " --another-option option-argument" # # will only append to $options if " --another-option option-argument " # is not already present somewhere in $options already (note spaces at # each end implied by leading space in second argument). func_append_uniq () { $debug_cmd eval _G_current_value='`$ECHO $'$1'`' _G_delim=`expr "$2" : '\(.\)'` case $_G_delim$_G_current_value$_G_delim in *"$2$_G_delim"*) ;; *) func_append "$@" ;; esac } # func_arith TERM... # ------------------ # Set func_arith_result to the result of evaluating TERMs. test -z "$_G_HAVE_ARITH_OP" \ && (eval 'test 2 = $(( 1 + 1 ))') 2>/dev/null \ && _G_HAVE_ARITH_OP=yes if test yes = "$_G_HAVE_ARITH_OP"; then eval 'func_arith () { $debug_cmd func_arith_result=$(( $* )) }' else func_arith () { $debug_cmd func_arith_result=`expr "$@"` } fi # func_basename FILE # ------------------ # Set func_basename_result to FILE with everything up to and including # the last / stripped. if test yes = "$_G_HAVE_XSI_OPS"; then # If this shell supports suffix pattern removal, then use it to avoid # forking. Hide the definitions single quotes in case the shell chokes # on unsupported syntax... _b='func_basename_result=${1##*/}' _d='case $1 in */*) func_dirname_result=${1%/*}$2 ;; * ) func_dirname_result=$3 ;; esac' else # ...otherwise fall back to using sed. _b='func_basename_result=`$ECHO "$1" |$SED "$sed_basename"`' _d='func_dirname_result=`$ECHO "$1" |$SED "$sed_dirname"` if test "X$func_dirname_result" = "X$1"; then func_dirname_result=$3 else func_append func_dirname_result "$2" fi' fi eval 'func_basename () { $debug_cmd '"$_b"' }' # func_dirname FILE APPEND NONDIR_REPLACEMENT # ------------------------------------------- # Compute the dirname of FILE. If nonempty, add APPEND to the result, # otherwise set result to NONDIR_REPLACEMENT. eval 'func_dirname () { $debug_cmd '"$_d"' }' # func_dirname_and_basename FILE APPEND NONDIR_REPLACEMENT # -------------------------------------------------------- # Perform func_basename and func_dirname in a single function # call: # dirname: Compute the dirname of FILE. If nonempty, # add APPEND to the result, otherwise set result # to NONDIR_REPLACEMENT. # value returned in "$func_dirname_result" # basename: Compute filename of FILE. # value retuned in "$func_basename_result" # For efficiency, we do not delegate to the functions above but instead # duplicate the functionality here. eval 'func_dirname_and_basename () { $debug_cmd '"$_b"' '"$_d"' }' # func_echo ARG... # ---------------- # Echo program name prefixed message. func_echo () { $debug_cmd _G_message=$* func_echo_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_IFS $ECHO "$progname: $_G_line" done IFS=$func_echo_IFS } # func_echo_all ARG... # -------------------- # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "$*" } # func_echo_infix_1 INFIX ARG... # ------------------------------ # Echo program name, followed by INFIX on the first line, with any # additional lines not showing INFIX. func_echo_infix_1 () { $debug_cmd $require_term_colors _G_infix=$1; shift _G_indent=$_G_infix _G_prefix="$progname: $_G_infix: " _G_message=$* # Strip color escape sequences before counting printable length for _G_tc in "$tc_reset" "$tc_bold" "$tc_standout" "$tc_red" "$tc_green" "$tc_blue" "$tc_cyan" do test -n "$_G_tc" && { _G_esc_tc=`$ECHO "$_G_tc" | $SED "$sed_make_literal_regex"` _G_indent=`$ECHO "$_G_indent" | $SED "s|$_G_esc_tc||g"` } done _G_indent="$progname: "`echo "$_G_indent" | $SED 's|.| |g'`" " ## exclude from sc_prohibit_nested_quotes func_echo_infix_1_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_infix_1_IFS $ECHO "$_G_prefix$tc_bold$_G_line$tc_reset" >&2 _G_prefix=$_G_indent done IFS=$func_echo_infix_1_IFS } # func_error ARG... # ----------------- # Echo program name prefixed message to standard error. func_error () { $debug_cmd $require_term_colors func_echo_infix_1 " $tc_standout${tc_red}error$tc_reset" "$*" >&2 } # func_fatal_error ARG... # ----------------------- # Echo program name prefixed message to standard error, and exit. func_fatal_error () { $debug_cmd func_error "$*" exit $EXIT_FAILURE } # func_grep EXPRESSION FILENAME # ----------------------------- # Check whether EXPRESSION matches any line of FILENAME, without output. func_grep () { $debug_cmd $GREP "$1" "$2" >/dev/null 2>&1 } # func_len STRING # --------------- # Set func_len_result to the length of STRING. STRING may not # start with a hyphen. test -z "$_G_HAVE_XSI_OPS" \ && (eval 'x=a/b/c; test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ && _G_HAVE_XSI_OPS=yes if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_len () { $debug_cmd func_len_result=${#1} }' else func_len () { $debug_cmd func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` } fi # func_mkdir_p DIRECTORY-PATH # --------------------------- # Make sure the entire path to DIRECTORY-PATH is available. func_mkdir_p () { $debug_cmd _G_directory_path=$1 _G_dir_list= if test -n "$_G_directory_path" && test : != "$opt_dry_run"; then # Protect directory names starting with '-' case $_G_directory_path in -*) _G_directory_path=./$_G_directory_path ;; esac # While some portion of DIR does not yet exist... while test ! -d "$_G_directory_path"; do # ...make a list in topmost first order. Use a colon delimited # list incase some portion of path contains whitespace. _G_dir_list=$_G_directory_path:$_G_dir_list # If the last portion added has no slash in it, the list is done case $_G_directory_path in */*) ;; *) break ;; esac # ...otherwise throw away the child directory and loop _G_directory_path=`$ECHO "$_G_directory_path" | $SED -e "$sed_dirname"` done _G_dir_list=`$ECHO "$_G_dir_list" | $SED 's|:*$||'` func_mkdir_p_IFS=$IFS; IFS=: for _G_dir in $_G_dir_list; do IFS=$func_mkdir_p_IFS # mkdir can fail with a 'File exist' error if two processes # try to create one of the directories concurrently. Don't # stop in that case! $MKDIR "$_G_dir" 2>/dev/null || : done IFS=$func_mkdir_p_IFS # Bail out if we (or some other process) failed to create a directory. test -d "$_G_directory_path" || \ func_fatal_error "Failed to create '$1'" fi } # func_mktempdir [BASENAME] # ------------------------- # Make a temporary directory that won't clash with other running # libtool processes, and avoids race conditions if possible. If # given, BASENAME is the basename for that directory. func_mktempdir () { $debug_cmd _G_template=${TMPDIR-/tmp}/${1-$progname} if test : = "$opt_dry_run"; then # Return a directory name, but don't create it in dry-run mode _G_tmpdir=$_G_template-$$ else # If mktemp works, use that first and foremost _G_tmpdir=`mktemp -d "$_G_template-XXXXXXXX" 2>/dev/null` if test ! -d "$_G_tmpdir"; then # Failing that, at least try and use $RANDOM to avoid a race _G_tmpdir=$_G_template-${RANDOM-0}$$ func_mktempdir_umask=`umask` umask 0077 $MKDIR "$_G_tmpdir" umask $func_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure test -d "$_G_tmpdir" || \ func_fatal_error "cannot create temporary directory '$_G_tmpdir'" fi $ECHO "$_G_tmpdir" } # func_normal_abspath PATH # ------------------------ # Remove doubled-up and trailing slashes, "." path components, # and cancel out any ".." path components in PATH after making # it an absolute path. func_normal_abspath () { $debug_cmd # These SED scripts presuppose an absolute path with a trailing slash. _G_pathcar='s|^/\([^/]*\).*$|\1|' _G_pathcdr='s|^/[^/]*||' _G_removedotparts=':dotsl s|/\./|/|g t dotsl s|/\.$|/|' _G_collapseslashes='s|/\{1,\}|/|g' _G_finalslash='s|/*$|/|' # Start from root dir and reassemble the path. func_normal_abspath_result= func_normal_abspath_tpath=$1 func_normal_abspath_altnamespace= case $func_normal_abspath_tpath in "") # Empty path, that just means $cwd. func_stripname '' '/' "`pwd`" func_normal_abspath_result=$func_stripname_result return ;; # The next three entries are used to spot a run of precisely # two leading slashes without using negated character classes; # we take advantage of case's first-match behaviour. ///*) # Unusual form of absolute path, do nothing. ;; //*) # Not necessarily an ordinary path; POSIX reserves leading '//' # and for example Cygwin uses it to access remote file shares # over CIFS/SMB, so we conserve a leading double slash if found. func_normal_abspath_altnamespace=/ ;; /*) # Absolute path, do nothing. ;; *) # Relative path, prepend $cwd. func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath ;; esac # Cancel out all the simple stuff to save iterations. We also want # the path to end with a slash for ease of parsing, so make sure # there is one (and only one) here. func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_removedotparts" -e "$_G_collapseslashes" -e "$_G_finalslash"` while :; do # Processed it all yet? if test / = "$func_normal_abspath_tpath"; then # If we ascended to the root using ".." the result may be empty now. if test -z "$func_normal_abspath_result"; then func_normal_abspath_result=/ fi break fi func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_pathcar"` func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_pathcdr"` # Figure out what to do with it case $func_normal_abspath_tcomponent in "") # Trailing empty path component, ignore it. ;; ..) # Parent dir; strip last assembled component from result. func_dirname "$func_normal_abspath_result" func_normal_abspath_result=$func_dirname_result ;; *) # Actual path component, append it. func_append func_normal_abspath_result "/$func_normal_abspath_tcomponent" ;; esac done # Restore leading double-slash if one was found on entry. func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result } # func_notquiet ARG... # -------------------- # Echo program name prefixed message only when not in quiet mode. func_notquiet () { $debug_cmd $opt_quiet || func_echo ${1+"$@"} # A bug in bash halts the script if the last line of a function # fails when set -e is in force, so we need another command to # work around that: : } # func_relative_path SRCDIR DSTDIR # -------------------------------- # Set func_relative_path_result to the relative path from SRCDIR to DSTDIR. func_relative_path () { $debug_cmd func_relative_path_result= func_normal_abspath "$1" func_relative_path_tlibdir=$func_normal_abspath_result func_normal_abspath "$2" func_relative_path_tbindir=$func_normal_abspath_result # Ascend the tree starting from libdir while :; do # check if we have found a prefix of bindir case $func_relative_path_tbindir in $func_relative_path_tlibdir) # found an exact match func_relative_path_tcancelled= break ;; $func_relative_path_tlibdir*) # found a matching prefix func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" func_relative_path_tcancelled=$func_stripname_result if test -z "$func_relative_path_result"; then func_relative_path_result=. fi break ;; *) func_dirname $func_relative_path_tlibdir func_relative_path_tlibdir=$func_dirname_result if test -z "$func_relative_path_tlibdir"; then # Have to descend all the way to the root! func_relative_path_result=../$func_relative_path_result func_relative_path_tcancelled=$func_relative_path_tbindir break fi func_relative_path_result=../$func_relative_path_result ;; esac done # Now calculate path; take care to avoid doubling-up slashes. func_stripname '' '/' "$func_relative_path_result" func_relative_path_result=$func_stripname_result func_stripname '/' '/' "$func_relative_path_tcancelled" if test -n "$func_stripname_result"; then func_append func_relative_path_result "/$func_stripname_result" fi # Normalisation. If bindir is libdir, return '.' else relative path. if test -n "$func_relative_path_result"; then func_stripname './' '' "$func_relative_path_result" func_relative_path_result=$func_stripname_result fi test -n "$func_relative_path_result" || func_relative_path_result=. : } # func_quote_portable EVAL ARG # ---------------------------- # Internal function to portably implement func_quote_arg. Note that we still # keep attention to performance here so we as much as possible try to avoid # calling sed binary (so far O(N) complexity as long as func_append is O(1)). func_quote_portable () { $debug_cmd $require_check_ifs_backslash func_quote_portable_result=$2 # one-time-loop (easy break) while true do if $1; then func_quote_portable_result=`$ECHO "$2" | $SED \ -e "$sed_double_quote_subst" -e "$sed_double_backslash"` break fi # Quote for eval. case $func_quote_portable_result in *[\\\`\"\$]*) # Fallback to sed for $func_check_bs_ifs_broken=:, or when the string # contains the shell wildcard characters. case $check_ifs_backshlash_broken$func_quote_portable_result in :*|*[\[\*\?]*) func_quote_portable_result=`$ECHO "$func_quote_portable_result" \ | $SED "$sed_quote_subst"` break ;; esac func_quote_portable_old_IFS=$IFS for _G_char in '\' '`' '"' '$' do # STATE($1) PREV($2) SEPARATOR($3) set start "" "" func_quote_portable_result=dummy"$_G_char$func_quote_portable_result$_G_char"dummy IFS=$_G_char for _G_part in $func_quote_portable_result do case $1 in quote) func_append func_quote_portable_result "$3$2" set quote "$_G_part" "\\$_G_char" ;; start) set first "" "" func_quote_portable_result= ;; first) set quote "$_G_part" "" ;; esac done done IFS=$func_quote_portable_old_IFS ;; *) ;; esac break done func_quote_portable_unquoted_result=$func_quote_portable_result case $func_quote_portable_result in # double-quote args containing shell metacharacters to delay # word splitting, command substitution and variable expansion # for a subsequent eval. # many bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") func_quote_portable_result=\"$func_quote_portable_result\" ;; esac } # func_quotefast_eval ARG # ----------------------- # Quote one ARG (internal). This is equivalent to 'func_quote_arg eval ARG', # but optimized for speed. Result is stored in $func_quotefast_eval. if test xyes = `(x=; printf -v x %q yes; echo x"$x") 2>/dev/null`; then printf -v _GL_test_printf_tilde %q '~' if test '\~' = "$_GL_test_printf_tilde"; then func_quotefast_eval () { printf -v func_quotefast_eval_result %q "$1" } else # Broken older Bash implementations. Make those faster too if possible. func_quotefast_eval () { case $1 in '~'*) func_quote_portable false "$1" func_quotefast_eval_result=$func_quote_portable_result ;; *) printf -v func_quotefast_eval_result %q "$1" ;; esac } fi else func_quotefast_eval () { func_quote_portable false "$1" func_quotefast_eval_result=$func_quote_portable_result } fi # func_quote_arg MODEs ARG # ------------------------ # Quote one ARG to be evaled later. MODEs argument may contain zero or more # specifiers listed below separated by ',' character. This function returns two # values: # i) func_quote_arg_result # double-quoted (when needed), suitable for a subsequent eval # ii) func_quote_arg_unquoted_result # has all characters that are still active within double # quotes backslashified. Available only if 'unquoted' is specified. # # Available modes: # ---------------- # 'eval' (default) # - escape shell special characters # 'expand' # - the same as 'eval'; but do not quote variable references # 'pretty' # - request aesthetic output, i.e. '"a b"' instead of 'a\ b'. This might # be used later in func_quote to get output like: 'echo "a b"' instead # of 'echo a\ b'. This is slower than default on some shells. # 'unquoted' # - produce also $func_quote_arg_unquoted_result which does not contain # wrapping double-quotes. # # Examples for 'func_quote_arg pretty,unquoted string': # # string | *_result | *_unquoted_result # ------------+-----------------------+------------------- # " | \" | \" # a b | "a b" | a b # "a b" | "\"a b\"" | \"a b\" # * | "*" | * # z="${x-$y}" | "z=\"\${x-\$y}\"" | z=\"\${x-\$y}\" # # Examples for 'func_quote_arg pretty,unquoted,expand string': # # string | *_result | *_unquoted_result # --------------+---------------------+-------------------- # z="${x-$y}" | "z=\"${x-$y}\"" | z=\"${x-$y}\" func_quote_arg () { _G_quote_expand=false case ,$1, in *,expand,*) _G_quote_expand=: ;; esac case ,$1, in *,pretty,*|*,expand,*|*,unquoted,*) func_quote_portable $_G_quote_expand "$2" func_quote_arg_result=$func_quote_portable_result func_quote_arg_unquoted_result=$func_quote_portable_unquoted_result ;; *) # Faster quote-for-eval for some shells. func_quotefast_eval "$2" func_quote_arg_result=$func_quotefast_eval_result ;; esac } # func_quote MODEs ARGs... # ------------------------ # Quote all ARGs to be evaled later and join them into single command. See # func_quote_arg's description for more info. func_quote () { $debug_cmd _G_func_quote_mode=$1 ; shift func_quote_result= while test 0 -lt $#; do func_quote_arg "$_G_func_quote_mode" "$1" if test -n "$func_quote_result"; then func_append func_quote_result " $func_quote_arg_result" else func_append func_quote_result "$func_quote_arg_result" fi shift done } # func_stripname PREFIX SUFFIX NAME # --------------------------------- # strip PREFIX and SUFFIX from NAME, and store in func_stripname_result. # PREFIX and SUFFIX must not contain globbing or regex special # characters, hashes, percent signs, but SUFFIX may contain a leading # dot (in which case that matches only a dot). if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_stripname () { $debug_cmd # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are # positional parameters, so assign one to ordinary variable first. func_stripname_result=$3 func_stripname_result=${func_stripname_result#"$1"} func_stripname_result=${func_stripname_result%"$2"} }' else func_stripname () { $debug_cmd case $2 in .*) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%\\\\$2\$%%"`;; *) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%$2\$%%"`;; esac } fi # func_show_eval CMD [FAIL_EXP] # ----------------------------- # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP # is given, then evaluate it. func_show_eval () { $debug_cmd _G_cmd=$1 _G_fail_exp=${2-':'} func_quote_arg pretty,expand "$_G_cmd" eval "func_notquiet $func_quote_arg_result" $opt_dry_run || { eval "$_G_cmd" _G_status=$? if test 0 -ne "$_G_status"; then eval "(exit $_G_status); $_G_fail_exp" fi } } # func_show_eval_locale CMD [FAIL_EXP] # ------------------------------------ # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP # is given, then evaluate it. Use the saved locale for evaluation. func_show_eval_locale () { $debug_cmd _G_cmd=$1 _G_fail_exp=${2-':'} $opt_quiet || { func_quote_arg expand,pretty "$_G_cmd" eval "func_echo $func_quote_arg_result" } $opt_dry_run || { eval "$_G_user_locale $_G_cmd" _G_status=$? eval "$_G_safe_locale" if test 0 -ne "$_G_status"; then eval "(exit $_G_status); $_G_fail_exp" fi } } # func_tr_sh # ---------- # Turn $1 into a string suitable for a shell variable name. # Result is stored in $func_tr_sh_result. All characters # not in the set a-zA-Z0-9_ are replaced with '_'. Further, # if $1 begins with a digit, a '_' is prepended as well. func_tr_sh () { $debug_cmd case $1 in [0-9]* | *[!a-zA-Z0-9_]*) func_tr_sh_result=`$ECHO "$1" | $SED -e 's/^\([0-9]\)/_\1/' -e 's/[^a-zA-Z0-9_]/_/g'` ;; * ) func_tr_sh_result=$1 ;; esac } # func_verbose ARG... # ------------------- # Echo program name prefixed message in verbose mode only. func_verbose () { $debug_cmd $opt_verbose && func_echo "$*" : } # func_warn_and_continue ARG... # ----------------------------- # Echo program name prefixed warning message to standard error. func_warn_and_continue () { $debug_cmd $require_term_colors func_echo_infix_1 "${tc_red}warning$tc_reset" "$*" >&2 } # func_warning CATEGORY ARG... # ---------------------------- # Echo program name prefixed warning message to standard error. Warning # messages can be filtered according to CATEGORY, where this function # elides messages where CATEGORY is not listed in the global variable # 'opt_warning_types'. func_warning () { $debug_cmd # CATEGORY must be in the warning_categories list! case " $warning_categories " in *" $1 "*) ;; *) func_internal_error "invalid warning category '$1'" ;; esac _G_category=$1 shift case " $opt_warning_types " in *" $_G_category "*) $warning_func ${1+"$@"} ;; esac } # func_sort_ver VER1 VER2 # ----------------------- # 'sort -V' is not generally available. # Note this deviates from the version comparison in automake # in that it treats 1.5 < 1.5.0, and treats 1.4.4a < 1.4-p3a # but this should suffice as we won't be specifying old # version formats or redundant trailing .0 in bootstrap.conf. # If we did want full compatibility then we should probably # use m4_version_compare from autoconf. func_sort_ver () { $debug_cmd printf '%s\n%s\n' "$1" "$2" \ | sort -t. -k 1,1n -k 2,2n -k 3,3n -k 4,4n -k 5,5n -k 6,6n -k 7,7n -k 8,8n -k 9,9n } # func_lt_ver PREV CURR # --------------------- # Return true if PREV and CURR are in the correct order according to # func_sort_ver, otherwise false. Use it like this: # # func_lt_ver "$prev_ver" "$proposed_ver" || func_fatal_error "..." func_lt_ver () { $debug_cmd test "x$1" = x`func_sort_ver "$1" "$2" | $SED 1q` } # Local variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" # time-stamp-time-zone: "UTC" # End: #! /bin/sh # A portable, pluggable option parser for Bourne shell. # Written by Gary V. Vaughan, 2010 # This is free software. There is NO warranty; not even for # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # # Copyright (C) 2010-2019, 2021 Bootstrap Authors # # This file is dual licensed under the terms of the MIT license # , and GPL version 2 or later # . You must apply one of # these licenses when using or redistributing this software or any of # the files within it. See the URLs above, or the file `LICENSE` # included in the Bootstrap distribution for the full license texts. # Please report bugs or propose patches to: # # Set a version string for this script. scriptversion=2019-02-19.15; # UTC ## ------ ## ## Usage. ## ## ------ ## # This file is a library for parsing options in your shell scripts along # with assorted other useful supporting features that you can make use # of too. # # For the simplest scripts you might need only: # # #!/bin/sh # . relative/path/to/funclib.sh # . relative/path/to/options-parser # scriptversion=1.0 # func_options ${1+"$@"} # eval set dummy "$func_options_result"; shift # ...rest of your script... # # In order for the '--version' option to work, you will need to have a # suitably formatted comment like the one at the top of this file # starting with '# Written by ' and ending with '# Copyright'. # # For '-h' and '--help' to work, you will also need a one line # description of your script's purpose in a comment directly above the # '# Written by ' line, like the one at the top of this file. # # The default options also support '--debug', which will turn on shell # execution tracing (see the comment above debug_cmd below for another # use), and '--verbose' and the func_verbose function to allow your script # to display verbose messages only when your user has specified # '--verbose'. # # After sourcing this file, you can plug in processing for additional # options by amending the variables from the 'Configuration' section # below, and following the instructions in the 'Option parsing' # section further down. ## -------------- ## ## Configuration. ## ## -------------- ## # You should override these variables in your script after sourcing this # file so that they reflect the customisations you have added to the # option parser. # The usage line for option parsing errors and the start of '-h' and # '--help' output messages. You can embed shell variables for delayed # expansion at the time the message is displayed, but you will need to # quote other shell meta-characters carefully to prevent them being # expanded when the contents are evaled. usage='$progpath [OPTION]...' # Short help message in response to '-h' and '--help'. Add to this or # override it after sourcing this library to reflect the full set of # options your script accepts. usage_message="\ --debug enable verbose shell tracing -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] -v, --verbose verbosely report processing --version print version information and exit -h, --help print short or long help message and exit " # Additional text appended to 'usage_message' in response to '--help'. long_help_message=" Warning categories include: 'all' show all warnings 'none' turn off all the warnings 'error' warnings are treated as fatal errors" # Help message printed before fatal option parsing errors. fatal_help="Try '\$progname --help' for more information." ## ------------------------- ## ## Hook function management. ## ## ------------------------- ## # This section contains functions for adding, removing, and running hooks # in the main code. A hook is just a list of function names that can be # run in order later on. # func_hookable FUNC_NAME # ----------------------- # Declare that FUNC_NAME will run hooks added with # 'func_add_hook FUNC_NAME ...'. func_hookable () { $debug_cmd func_append hookable_fns " $1" } # func_add_hook FUNC_NAME HOOK_FUNC # --------------------------------- # Request that FUNC_NAME call HOOK_FUNC before it returns. FUNC_NAME must # first have been declared "hookable" by a call to 'func_hookable'. func_add_hook () { $debug_cmd case " $hookable_fns " in *" $1 "*) ;; *) func_fatal_error "'$1' does not accept hook functions." ;; esac eval func_append ${1}_hooks '" $2"' } # func_remove_hook FUNC_NAME HOOK_FUNC # ------------------------------------ # Remove HOOK_FUNC from the list of hook functions to be called by # FUNC_NAME. func_remove_hook () { $debug_cmd eval ${1}_hooks='`$ECHO "\$'$1'_hooks" |$SED "s| '$2'||"`' } # func_propagate_result FUNC_NAME_A FUNC_NAME_B # --------------------------------------------- # If the *_result variable of FUNC_NAME_A _is set_, assign its value to # *_result variable of FUNC_NAME_B. func_propagate_result () { $debug_cmd func_propagate_result_result=: if eval "test \"\${${1}_result+set}\" = set" then eval "${2}_result=\$${1}_result" else func_propagate_result_result=false fi } # func_run_hooks FUNC_NAME [ARG]... # --------------------------------- # Run all hook functions registered to FUNC_NAME. # It's assumed that the list of hook functions contains nothing more # than a whitespace-delimited list of legal shell function names, and # no effort is wasted trying to catch shell meta-characters or preserve # whitespace. func_run_hooks () { $debug_cmd case " $hookable_fns " in *" $1 "*) ;; *) func_fatal_error "'$1' does not support hook functions." ;; esac eval _G_hook_fns=\$$1_hooks; shift for _G_hook in $_G_hook_fns; do func_unset "${_G_hook}_result" eval $_G_hook '${1+"$@"}' func_propagate_result $_G_hook func_run_hooks if $func_propagate_result_result; then eval set dummy "$func_run_hooks_result"; shift fi done } ## --------------- ## ## Option parsing. ## ## --------------- ## # In order to add your own option parsing hooks, you must accept the # full positional parameter list from your hook function. You may remove # or edit any options that you action, and then pass back the remaining # unprocessed options in '_result', escaped # suitably for 'eval'. # # The '_result' variable is automatically unset # before your hook gets called; for best performance, only set the # *_result variable when necessary (i.e. don't call the 'func_quote' # function unnecessarily because it can be an expensive operation on some # machines). # # Like this: # # my_options_prep () # { # $debug_cmd # # # Extend the existing usage message. # usage_message=$usage_message' # -s, --silent don'\''t print informational messages # ' # # No change in '$@' (ignored completely by this hook). Leave # # my_options_prep_result variable intact. # } # func_add_hook func_options_prep my_options_prep # # # my_silent_option () # { # $debug_cmd # # args_changed=false # # # Note that, for efficiency, we parse as many options as we can # # recognise in a loop before passing the remainder back to the # # caller on the first unrecognised argument we encounter. # while test $# -gt 0; do # opt=$1; shift # case $opt in # --silent|-s) opt_silent=: # args_changed=: # ;; # # Separate non-argument short options: # -s*) func_split_short_opt "$_G_opt" # set dummy "$func_split_short_opt_name" \ # "-$func_split_short_opt_arg" ${1+"$@"} # shift # args_changed=: # ;; # *) # Make sure the first unrecognised option "$_G_opt" # # is added back to "$@" in case we need it later, # # if $args_changed was set to 'true'. # set dummy "$_G_opt" ${1+"$@"}; shift; break ;; # esac # done # # # Only call 'func_quote' here if we processed at least one argument. # if $args_changed; then # func_quote eval ${1+"$@"} # my_silent_option_result=$func_quote_result # fi # } # func_add_hook func_parse_options my_silent_option # # # my_option_validation () # { # $debug_cmd # # $opt_silent && $opt_verbose && func_fatal_help "\ # '--silent' and '--verbose' options are mutually exclusive." # } # func_add_hook func_validate_options my_option_validation # # You'll also need to manually amend $usage_message to reflect the extra # options you parse. It's preferable to append if you can, so that # multiple option parsing hooks can be added safely. # func_options_finish [ARG]... # ---------------------------- # Finishing the option parse loop (call 'func_options' hooks ATM). func_options_finish () { $debug_cmd func_run_hooks func_options ${1+"$@"} func_propagate_result func_run_hooks func_options_finish } # func_options [ARG]... # --------------------- # All the functions called inside func_options are hookable. See the # individual implementations for details. func_hookable func_options func_options () { $debug_cmd _G_options_quoted=false for my_func in options_prep parse_options validate_options options_finish do func_unset func_${my_func}_result func_unset func_run_hooks_result eval func_$my_func '${1+"$@"}' func_propagate_result func_$my_func func_options if $func_propagate_result_result; then eval set dummy "$func_options_result"; shift _G_options_quoted=: fi done $_G_options_quoted || { # As we (func_options) are top-level options-parser function and # nobody quoted "$@" for us yet, we need to do it explicitly for # caller. func_quote eval ${1+"$@"} func_options_result=$func_quote_result } } # func_options_prep [ARG]... # -------------------------- # All initialisations required before starting the option parse loop. # Note that when calling hook functions, we pass through the list of # positional parameters. If a hook function modifies that list, and # needs to propagate that back to rest of this script, then the complete # modified list must be put in 'func_run_hooks_result' before returning. func_hookable func_options_prep func_options_prep () { $debug_cmd # Option defaults: opt_verbose=false opt_warning_types= func_run_hooks func_options_prep ${1+"$@"} func_propagate_result func_run_hooks func_options_prep } # func_parse_options [ARG]... # --------------------------- # The main option parsing loop. func_hookable func_parse_options func_parse_options () { $debug_cmd _G_parse_options_requote=false # this just eases exit handling while test $# -gt 0; do # Defer to hook functions for initial option parsing, so they # get priority in the event of reusing an option name. func_run_hooks func_parse_options ${1+"$@"} func_propagate_result func_run_hooks func_parse_options if $func_propagate_result_result; then eval set dummy "$func_parse_options_result"; shift # Even though we may have changed "$@", we passed the "$@" array # down into the hook and it quoted it for us (because we are in # this if-branch). No need to quote it again. _G_parse_options_requote=false fi # Break out of the loop if we already parsed every option. test $# -gt 0 || break # We expect that one of the options parsed in this function matches # and thus we remove _G_opt from "$@" and need to re-quote. _G_match_parse_options=: _G_opt=$1 shift case $_G_opt in --debug|-x) debug_cmd='set -x' func_echo "enabling shell trace mode" >&2 $debug_cmd ;; --no-warnings|--no-warning|--no-warn) set dummy --warnings none ${1+"$@"} shift ;; --warnings|--warning|-W) if test $# = 0 && func_missing_arg $_G_opt; then _G_parse_options_requote=: break fi case " $warning_categories $1" in *" $1 "*) # trailing space prevents matching last $1 above func_append_uniq opt_warning_types " $1" ;; *all) opt_warning_types=$warning_categories ;; *none) opt_warning_types=none warning_func=: ;; *error) opt_warning_types=$warning_categories warning_func=func_fatal_error ;; *) func_fatal_error \ "unsupported warning category: '$1'" ;; esac shift ;; --verbose|-v) opt_verbose=: ;; --version) func_version ;; -\?|-h) func_usage ;; --help) func_help ;; # Separate optargs to long options (plugins may need this): --*=*) func_split_equals "$_G_opt" set dummy "$func_split_equals_lhs" \ "$func_split_equals_rhs" ${1+"$@"} shift ;; # Separate optargs to short options: -W*) func_split_short_opt "$_G_opt" set dummy "$func_split_short_opt_name" \ "$func_split_short_opt_arg" ${1+"$@"} shift ;; # Separate non-argument short options: -\?*|-h*|-v*|-x*) func_split_short_opt "$_G_opt" set dummy "$func_split_short_opt_name" \ "-$func_split_short_opt_arg" ${1+"$@"} shift ;; --) _G_parse_options_requote=: ; break ;; -*) func_fatal_help "unrecognised option: '$_G_opt'" ;; *) set dummy "$_G_opt" ${1+"$@"}; shift _G_match_parse_options=false break ;; esac if $_G_match_parse_options; then _G_parse_options_requote=: fi done if $_G_parse_options_requote; then # save modified positional parameters for caller func_quote eval ${1+"$@"} func_parse_options_result=$func_quote_result fi } # func_validate_options [ARG]... # ------------------------------ # Perform any sanity checks on option settings and/or unconsumed # arguments. func_hookable func_validate_options func_validate_options () { $debug_cmd # Display all warnings if -W was not given. test -n "$opt_warning_types" || opt_warning_types=" $warning_categories" func_run_hooks func_validate_options ${1+"$@"} func_propagate_result func_run_hooks func_validate_options # Bail if the options were screwed! $exit_cmd $EXIT_FAILURE } ## ----------------- ## ## Helper functions. ## ## ----------------- ## # This section contains the helper functions used by the rest of the # hookable option parser framework in ascii-betical order. # func_fatal_help ARG... # ---------------------- # Echo program name prefixed message to standard error, followed by # a help hint, and exit. func_fatal_help () { $debug_cmd eval \$ECHO \""Usage: $usage"\" eval \$ECHO \""$fatal_help"\" func_error ${1+"$@"} exit $EXIT_FAILURE } # func_help # --------- # Echo long help message to standard output and exit. func_help () { $debug_cmd func_usage_message $ECHO "$long_help_message" exit 0 } # func_missing_arg ARGNAME # ------------------------ # Echo program name prefixed message to standard error and set global # exit_cmd. func_missing_arg () { $debug_cmd func_error "Missing argument for '$1'." exit_cmd=exit } # func_split_equals STRING # ------------------------ # Set func_split_equals_lhs and func_split_equals_rhs shell variables # after splitting STRING at the '=' sign. test -z "$_G_HAVE_XSI_OPS" \ && (eval 'x=a/b/c; test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ && _G_HAVE_XSI_OPS=yes if test yes = "$_G_HAVE_XSI_OPS" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_split_equals () { $debug_cmd func_split_equals_lhs=${1%%=*} func_split_equals_rhs=${1#*=} if test "x$func_split_equals_lhs" = "x$1"; then func_split_equals_rhs= fi }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_split_equals () { $debug_cmd func_split_equals_lhs=`expr "x$1" : 'x\([^=]*\)'` func_split_equals_rhs= test "x$func_split_equals_lhs=" = "x$1" \ || func_split_equals_rhs=`expr "x$1" : 'x[^=]*=\(.*\)$'` } fi #func_split_equals # func_split_short_opt SHORTOPT # ----------------------------- # Set func_split_short_opt_name and func_split_short_opt_arg shell # variables after splitting SHORTOPT after the 2nd character. if test yes = "$_G_HAVE_XSI_OPS" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_split_short_opt () { $debug_cmd func_split_short_opt_arg=${1#??} func_split_short_opt_name=${1%"$func_split_short_opt_arg"} }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_split_short_opt () { $debug_cmd func_split_short_opt_name=`expr "x$1" : 'x\(-.\)'` func_split_short_opt_arg=`expr "x$1" : 'x-.\(.*\)$'` } fi #func_split_short_opt # func_usage # ---------- # Echo short help message to standard output and exit. func_usage () { $debug_cmd func_usage_message $ECHO "Run '$progname --help |${PAGER-more}' for full usage" exit 0 } # func_usage_message # ------------------ # Echo short help message to standard output. func_usage_message () { $debug_cmd eval \$ECHO \""Usage: $usage"\" echo $SED -n 's|^# || /^Written by/{ x;p;x } h /^Written by/q' < "$progpath" echo eval \$ECHO \""$usage_message"\" } # func_version # ------------ # Echo version message to standard output and exit. # The version message is extracted from the calling file's header # comments, with leading '# ' stripped: # 1. First display the progname and version # 2. Followed by the header comment line matching /^# Written by / # 3. Then a blank line followed by the first following line matching # /^# Copyright / # 4. Immediately followed by any lines between the previous matches, # except lines preceding the intervening completely blank line. # For example, see the header comments of this file. func_version () { $debug_cmd printf '%s\n' "$progname $scriptversion" $SED -n ' /^# Written by /!b s|^# ||; p; n :fwd2blnk /./ { n b fwd2blnk } p; n :holdwrnt s|^# || s|^# *$|| /^Copyright /!{ /./H n b holdwrnt } s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2| G s|\(\n\)\n*|\1|g p; q' < "$progpath" exit $? } # Local variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-pattern: "30/scriptversion=%:y-%02m-%02d.%02H; # UTC" # time-stamp-time-zone: "UTC" # End: # Set a version string. scriptversion='(GNU libtool) 2.4.7' # func_echo ARG... # ---------------- # Libtool also displays the current mode in messages, so override # funclib.sh func_echo with this custom definition. func_echo () { $debug_cmd _G_message=$* func_echo_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_IFS $ECHO "$progname${opt_mode+: $opt_mode}: $_G_line" done IFS=$func_echo_IFS } # func_warning ARG... # ------------------- # Libtool warnings are not categorized, so override funclib.sh # func_warning with this simpler definition. func_warning () { $debug_cmd $warning_func ${1+"$@"} } ## ---------------- ## ## Options parsing. ## ## ---------------- ## # Hook in the functions to make sure our own options are parsed during # the option parsing loop. usage='$progpath [OPTION]... [MODE-ARG]...' # Short help message in response to '-h'. usage_message="Options: --config show all configuration variables --debug enable verbose shell tracing -n, --dry-run display commands without modifying any files --features display basic configuration information and exit --mode=MODE use operation mode MODE --no-warnings equivalent to '-Wnone' --preserve-dup-deps don't remove duplicate dependency libraries --quiet, --silent don't print informational messages --tag=TAG use configuration variables from tag TAG -v, --verbose print more informational messages than default --version print version information -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] -h, --help, --help-all print short, long, or detailed help message " # Additional text appended to 'usage_message' in response to '--help'. func_help () { $debug_cmd func_usage_message $ECHO "$long_help_message MODE must be one of the following: clean remove files from the build directory compile compile a source file into a libtool object execute automatically set library path, then run a program finish complete the installation of libtool libraries install install libraries or executables link create a library or an executable uninstall remove libraries from an installed directory MODE-ARGS vary depending on the MODE. When passed as first option, '--mode=MODE' may be abbreviated as 'MODE' or a unique abbreviation of that. Try '$progname --help --mode=MODE' for a more detailed description of MODE. When reporting a bug, please describe a test case to reproduce it and include the following information: host-triplet: $host shell: $SHELL compiler: $LTCC compiler flags: $LTCFLAGS linker: $LD (gnu? $with_gnu_ld) version: $progname (GNU libtool) 2.4.7 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` Report bugs to . GNU libtool home page: . General help using GNU software: ." exit 0 } # func_lo2o OBJECT-NAME # --------------------- # Transform OBJECT-NAME from a '.lo' suffix to the platform specific # object suffix. lo2o=s/\\.lo\$/.$objext/ o2lo=s/\\.$objext\$/.lo/ if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_lo2o () { case $1 in *.lo) func_lo2o_result=${1%.lo}.$objext ;; * ) func_lo2o_result=$1 ;; esac }' # func_xform LIBOBJ-OR-SOURCE # --------------------------- # Transform LIBOBJ-OR-SOURCE from a '.o' or '.c' (or otherwise) # suffix to a '.lo' libtool-object suffix. eval 'func_xform () { func_xform_result=${1%.*}.lo }' else # ...otherwise fall back to using sed. func_lo2o () { func_lo2o_result=`$ECHO "$1" | $SED "$lo2o"` } func_xform () { func_xform_result=`$ECHO "$1" | $SED 's|\.[^.]*$|.lo|'` } fi # func_fatal_configuration ARG... # ------------------------------- # Echo program name prefixed message to standard error, followed by # a configuration failure hint, and exit. func_fatal_configuration () { func_fatal_error ${1+"$@"} \ "See the $PACKAGE documentation for more information." \ "Fatal configuration error." } # func_config # ----------- # Display the configuration for all the tags in this script. func_config () { re_begincf='^# ### BEGIN LIBTOOL' re_endcf='^# ### END LIBTOOL' # Default configuration. $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" # Now print the configurations for the tags. for tagname in $taglist; do $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" done exit $? } # func_features # ------------- # Display the features supported by this script. func_features () { echo "host: $host" if test yes = "$build_libtool_libs"; then echo "enable shared libraries" else echo "disable shared libraries" fi if test yes = "$build_old_libs"; then echo "enable static libraries" else echo "disable static libraries" fi exit $? } # func_enable_tag TAGNAME # ----------------------- # Verify that TAGNAME is valid, and either flag an error and exit, or # enable the TAGNAME tag. We also add TAGNAME to the global $taglist # variable here. func_enable_tag () { # Global variable: tagname=$1 re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" sed_extractcf=/$re_begincf/,/$re_endcf/p # Validate tagname. case $tagname in *[!-_A-Za-z0-9,/]*) func_fatal_error "invalid tag name: $tagname" ;; esac # Don't test for the "default" C tag, as we know it's # there but not specially marked. case $tagname in CC) ;; *) if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then taglist="$taglist $tagname" # Evaluate the configuration. Be careful to quote the path # and the sed script, to avoid splitting on whitespace, but # also don't use non-portable quotes within backquotes within # quotes we have to do it in 2 steps: extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` eval "$extractedcf" else func_error "ignoring unknown tag $tagname" fi ;; esac } # func_check_version_match # ------------------------ # Ensure that we are using m4 macros, and libtool script from the same # release of libtool. func_check_version_match () { if test "$package_revision" != "$macro_revision"; then if test "$VERSION" != "$macro_version"; then if test -z "$macro_version"; then cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, but the $progname: definition of this LT_INIT comes from an older release. $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION $progname: and run autoconf again. _LT_EOF else cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, but the $progname: definition of this LT_INIT comes from $PACKAGE $macro_version. $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION $progname: and run autoconf again. _LT_EOF fi else cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, $progname: but the definition of this LT_INIT comes from revision $macro_revision. $progname: You should recreate aclocal.m4 with macros from revision $package_revision $progname: of $PACKAGE $VERSION and run autoconf again. _LT_EOF fi exit $EXIT_MISMATCH fi } # libtool_options_prep [ARG]... # ----------------------------- # Preparation for options parsed by libtool. libtool_options_prep () { $debug_mode # Option defaults: opt_config=false opt_dlopen= opt_dry_run=false opt_help=false opt_mode= opt_preserve_dup_deps=false opt_quiet=false nonopt= preserve_args= _G_rc_lt_options_prep=: # Shorthand for --mode=foo, only valid as the first argument case $1 in clean|clea|cle|cl) shift; set dummy --mode clean ${1+"$@"}; shift ;; compile|compil|compi|comp|com|co|c) shift; set dummy --mode compile ${1+"$@"}; shift ;; execute|execut|execu|exec|exe|ex|e) shift; set dummy --mode execute ${1+"$@"}; shift ;; finish|finis|fini|fin|fi|f) shift; set dummy --mode finish ${1+"$@"}; shift ;; install|instal|insta|inst|ins|in|i) shift; set dummy --mode install ${1+"$@"}; shift ;; link|lin|li|l) shift; set dummy --mode link ${1+"$@"}; shift ;; uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) shift; set dummy --mode uninstall ${1+"$@"}; shift ;; *) _G_rc_lt_options_prep=false ;; esac if $_G_rc_lt_options_prep; then # Pass back the list of options. func_quote eval ${1+"$@"} libtool_options_prep_result=$func_quote_result fi } func_add_hook func_options_prep libtool_options_prep # libtool_parse_options [ARG]... # --------------------------------- # Provide handling for libtool specific options. libtool_parse_options () { $debug_cmd _G_rc_lt_parse_options=false # Perform our own loop to consume as many options as possible in # each iteration. while test $# -gt 0; do _G_match_lt_parse_options=: _G_opt=$1 shift case $_G_opt in --dry-run|--dryrun|-n) opt_dry_run=: ;; --config) func_config ;; --dlopen|-dlopen) opt_dlopen="${opt_dlopen+$opt_dlopen }$1" shift ;; --preserve-dup-deps) opt_preserve_dup_deps=: ;; --features) func_features ;; --finish) set dummy --mode finish ${1+"$@"}; shift ;; --help) opt_help=: ;; --help-all) opt_help=': help-all' ;; --mode) test $# = 0 && func_missing_arg $_G_opt && break opt_mode=$1 case $1 in # Valid mode arguments: clean|compile|execute|finish|install|link|relink|uninstall) ;; # Catch anything else as an error *) func_error "invalid argument for $_G_opt" exit_cmd=exit break ;; esac shift ;; --no-silent|--no-quiet) opt_quiet=false func_append preserve_args " $_G_opt" ;; --no-warnings|--no-warning|--no-warn) opt_warning=false func_append preserve_args " $_G_opt" ;; --no-verbose) opt_verbose=false func_append preserve_args " $_G_opt" ;; --silent|--quiet) opt_quiet=: opt_verbose=false func_append preserve_args " $_G_opt" ;; --tag) test $# = 0 && func_missing_arg $_G_opt && break opt_tag=$1 func_append preserve_args " $_G_opt $1" func_enable_tag "$1" shift ;; --verbose|-v) opt_quiet=false opt_verbose=: func_append preserve_args " $_G_opt" ;; # An option not handled by this hook function: *) set dummy "$_G_opt" ${1+"$@"} ; shift _G_match_lt_parse_options=false break ;; esac $_G_match_lt_parse_options && _G_rc_lt_parse_options=: done if $_G_rc_lt_parse_options; then # save modified positional parameters for caller func_quote eval ${1+"$@"} libtool_parse_options_result=$func_quote_result fi } func_add_hook func_parse_options libtool_parse_options # libtool_validate_options [ARG]... # --------------------------------- # Perform any sanity checks on option settings and/or unconsumed # arguments. libtool_validate_options () { # save first non-option argument if test 0 -lt $#; then nonopt=$1 shift fi # preserve --debug test : = "$debug_cmd" || func_append preserve_args " --debug" case $host in # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452 # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788 *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*) # don't eliminate duplications in $postdeps and $predeps opt_duplicate_compiler_generated_deps=: ;; *) opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps ;; esac $opt_help || { # Sanity checks first: func_check_version_match test yes != "$build_libtool_libs" \ && test yes != "$build_old_libs" \ && func_fatal_configuration "not configured to build any kind of library" # Darwin sucks eval std_shrext=\"$shrext_cmds\" # Only execute mode is allowed to have -dlopen flags. if test -n "$opt_dlopen" && test execute != "$opt_mode"; then func_error "unrecognized option '-dlopen'" $ECHO "$help" 1>&2 exit $EXIT_FAILURE fi # Change the help message to a mode-specific one. generic_help=$help help="Try '$progname --help --mode=$opt_mode' for more information." } # Pass back the unparsed argument list func_quote eval ${1+"$@"} libtool_validate_options_result=$func_quote_result } func_add_hook func_validate_options libtool_validate_options # Process options as early as possible so that --help and --version # can return quickly. func_options ${1+"$@"} eval set dummy "$func_options_result"; shift ## ----------- ## ## Main. ## ## ----------- ## magic='%%%MAGIC variable%%%' magic_exe='%%%MAGIC EXE variable%%%' # Global variables. extracted_archives= extracted_serial=0 # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. exec_cmd= # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $1 _LTECHO_EOF' } # func_generated_by_libtool # True iff stdin has been generated by Libtool. This function is only # a basic sanity check; it will hardly flush out determined imposters. func_generated_by_libtool_p () { $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 } # func_lalib_p file # True iff FILE is a libtool '.la' library or '.lo' object file. # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_lalib_p () { test -f "$1" && $SED -e 4q "$1" 2>/dev/null | func_generated_by_libtool_p } # func_lalib_unsafe_p file # True iff FILE is a libtool '.la' library or '.lo' object file. # This function implements the same check as func_lalib_p without # resorting to external programs. To this end, it redirects stdin and # closes it afterwards, without saving the original file descriptor. # As a safety measure, use it only where a negative result would be # fatal anyway. Works if 'file' does not exist. func_lalib_unsafe_p () { lalib_p=no if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then for lalib_p_l in 1 2 3 4 do read lalib_p_line case $lalib_p_line in \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; esac done exec 0<&5 5<&- fi test yes = "$lalib_p" } # func_ltwrapper_script_p file # True iff FILE is a libtool wrapper script # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_script_p () { test -f "$1" && $lt_truncate_bin < "$1" 2>/dev/null | func_generated_by_libtool_p } # func_ltwrapper_executable_p file # True iff FILE is a libtool wrapper executable # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_executable_p () { func_ltwrapper_exec_suffix= case $1 in *.exe) ;; *) func_ltwrapper_exec_suffix=.exe ;; esac $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 } # func_ltwrapper_scriptname file # Assumes file is an ltwrapper_executable # uses $file to determine the appropriate filename for a # temporary ltwrapper_script. func_ltwrapper_scriptname () { func_dirname_and_basename "$1" "" "." func_stripname '' '.exe' "$func_basename_result" func_ltwrapper_scriptname_result=$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper } # func_ltwrapper_p file # True iff FILE is a libtool wrapper script or wrapper executable # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_p () { func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" } # func_execute_cmds commands fail_cmd # Execute tilde-delimited COMMANDS. # If FAIL_CMD is given, eval that upon failure. # FAIL_CMD may read-access the current command in variable CMD! func_execute_cmds () { $debug_cmd save_ifs=$IFS; IFS='~' for cmd in $1; do IFS=$sp$nl eval cmd=\"$cmd\" IFS=$save_ifs func_show_eval "$cmd" "${2-:}" done IFS=$save_ifs } # func_source file # Source FILE, adding directory component if necessary. # Note that it is not necessary on cygwin/mingw to append a dot to # FILE even if both FILE and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # 'FILE.' does not work on cygwin managed mounts. func_source () { $debug_cmd case $1 in */* | *\\*) . "$1" ;; *) . "./$1" ;; esac } # func_resolve_sysroot PATH # Replace a leading = in PATH with a sysroot. Store the result into # func_resolve_sysroot_result func_resolve_sysroot () { func_resolve_sysroot_result=$1 case $func_resolve_sysroot_result in =*) func_stripname '=' '' "$func_resolve_sysroot_result" func_resolve_sysroot_result=$lt_sysroot$func_stripname_result ;; esac } # func_replace_sysroot PATH # If PATH begins with the sysroot, replace it with = and # store the result into func_replace_sysroot_result. func_replace_sysroot () { case $lt_sysroot:$1 in ?*:"$lt_sysroot"*) func_stripname "$lt_sysroot" '' "$1" func_replace_sysroot_result='='$func_stripname_result ;; *) # Including no sysroot. func_replace_sysroot_result=$1 ;; esac } # func_infer_tag arg # Infer tagged configuration to use if any are available and # if one wasn't chosen via the "--tag" command line option. # Only attempt this if the compiler in the base compile # command doesn't match the default compiler. # arg is usually of the form 'gcc ...' func_infer_tag () { $debug_cmd if test -n "$available_tags" && test -z "$tagname"; then CC_quoted= for arg in $CC; do func_append_quoted CC_quoted "$arg" done CC_expanded=`func_echo_all $CC` CC_quoted_expanded=`func_echo_all $CC_quoted` case $@ in # Blanks in the command may have been stripped by the calling shell, # but not from the CC environment variable when configure was run. " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) for z in $available_tags; do if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then # Evaluate the configuration. eval "`$SED -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" CC_quoted= for arg in $CC; do # Double-quote args containing other shell metacharacters. func_append_quoted CC_quoted "$arg" done CC_expanded=`func_echo_all $CC` CC_quoted_expanded=`func_echo_all $CC_quoted` case "$@ " in " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) # The compiler in the base compile command matches # the one in the tagged configuration. # Assume this is the tagged configuration we want. tagname=$z break ;; esac fi done # If $tagname still isn't set, then no tagged configuration # was found and let the user know that the "--tag" command # line option must be used. if test -z "$tagname"; then func_echo "unable to infer tagged configuration" func_fatal_error "specify a tag with '--tag'" # else # func_verbose "using $tagname tagged configuration" fi ;; esac fi } # func_write_libtool_object output_name pic_name nonpic_name # Create a libtool object file (analogous to a ".la" file), # but don't create it if we're doing a dry run. func_write_libtool_object () { write_libobj=$1 if test yes = "$build_libtool_libs"; then write_lobj=\'$2\' else write_lobj=none fi if test yes = "$build_old_libs"; then write_oldobj=\'$3\' else write_oldobj=none fi $opt_dry_run || { cat >${write_libobj}T </dev/null` if test "$?" -eq 0 && test -n "$func_convert_core_file_wine_to_w32_tmp"; then func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | $SED -e "$sed_naive_backslashify"` else func_convert_core_file_wine_to_w32_result= fi fi } # end: func_convert_core_file_wine_to_w32 # func_convert_core_path_wine_to_w32 ARG # Helper function used by path conversion functions when $build is *nix, and # $host is mingw, cygwin, or some other w32 environment. Relies on a correctly # configured wine environment available, with the winepath program in $build's # $PATH. Assumes ARG has no leading or trailing path separator characters. # # ARG is path to be converted from $build format to win32. # Result is available in $func_convert_core_path_wine_to_w32_result. # Unconvertible file (directory) names in ARG are skipped; if no directory names # are convertible, then the result may be empty. func_convert_core_path_wine_to_w32 () { $debug_cmd # unfortunately, winepath doesn't convert paths, only file names func_convert_core_path_wine_to_w32_result= if test -n "$1"; then oldIFS=$IFS IFS=: for func_convert_core_path_wine_to_w32_f in $1; do IFS=$oldIFS func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" if test -n "$func_convert_core_file_wine_to_w32_result"; then if test -z "$func_convert_core_path_wine_to_w32_result"; then func_convert_core_path_wine_to_w32_result=$func_convert_core_file_wine_to_w32_result else func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" fi fi done IFS=$oldIFS fi } # end: func_convert_core_path_wine_to_w32 # func_cygpath ARGS... # Wrapper around calling the cygpath program via LT_CYGPATH. This is used when # when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) # $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or # (2), returns the Cygwin file name or path in func_cygpath_result (input # file name or path is assumed to be in w32 format, as previously converted # from $build's *nix or MSYS format). In case (3), returns the w32 file name # or path in func_cygpath_result (input file name or path is assumed to be in # Cygwin format). Returns an empty string on error. # # ARGS are passed to cygpath, with the last one being the file name or path to # be converted. # # Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH # environment variable; do not put it in $PATH. func_cygpath () { $debug_cmd if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` if test "$?" -ne 0; then # on failure, ensure result is empty func_cygpath_result= fi else func_cygpath_result= func_error "LT_CYGPATH is empty or specifies non-existent file: '$LT_CYGPATH'" fi } #end: func_cygpath # func_convert_core_msys_to_w32 ARG # Convert file name or path ARG from MSYS format to w32 format. Return # result in func_convert_core_msys_to_w32_result. func_convert_core_msys_to_w32 () { $debug_cmd # awkward: cmd appends spaces to result func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | $SED -e 's/[ ]*$//' -e "$sed_naive_backslashify"` } #end: func_convert_core_msys_to_w32 # func_convert_file_check ARG1 ARG2 # Verify that ARG1 (a file name in $build format) was converted to $host # format in ARG2. Otherwise, emit an error message, but continue (resetting # func_to_host_file_result to ARG1). func_convert_file_check () { $debug_cmd if test -z "$2" && test -n "$1"; then func_error "Could not determine host file name corresponding to" func_error " '$1'" func_error "Continuing, but uninstalled executables may not work." # Fallback: func_to_host_file_result=$1 fi } # end func_convert_file_check # func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH # Verify that FROM_PATH (a path in $build format) was converted to $host # format in TO_PATH. Otherwise, emit an error message, but continue, resetting # func_to_host_file_result to a simplistic fallback value (see below). func_convert_path_check () { $debug_cmd if test -z "$4" && test -n "$3"; then func_error "Could not determine the host path corresponding to" func_error " '$3'" func_error "Continuing, but uninstalled executables may not work." # Fallback. This is a deliberately simplistic "conversion" and # should not be "improved". See libtool.info. if test "x$1" != "x$2"; then lt_replace_pathsep_chars="s|$1|$2|g" func_to_host_path_result=`echo "$3" | $SED -e "$lt_replace_pathsep_chars"` else func_to_host_path_result=$3 fi fi } # end func_convert_path_check # func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG # Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT # and appending REPL if ORIG matches BACKPAT. func_convert_path_front_back_pathsep () { $debug_cmd case $4 in $1 ) func_to_host_path_result=$3$func_to_host_path_result ;; esac case $4 in $2 ) func_append func_to_host_path_result "$3" ;; esac } # end func_convert_path_front_back_pathsep ################################################## # $build to $host FILE NAME CONVERSION FUNCTIONS # ################################################## # invoked via '$to_host_file_cmd ARG' # # In each case, ARG is the path to be converted from $build to $host format. # Result will be available in $func_to_host_file_result. # func_to_host_file ARG # Converts the file name ARG from $build format to $host format. Return result # in func_to_host_file_result. func_to_host_file () { $debug_cmd $to_host_file_cmd "$1" } # end func_to_host_file # func_to_tool_file ARG LAZY # converts the file name ARG from $build format to toolchain format. Return # result in func_to_tool_file_result. If the conversion in use is listed # in (the comma separated) LAZY, no conversion takes place. func_to_tool_file () { $debug_cmd case ,$2, in *,"$to_tool_file_cmd",*) func_to_tool_file_result=$1 ;; *) $to_tool_file_cmd "$1" func_to_tool_file_result=$func_to_host_file_result ;; esac } # end func_to_tool_file # func_convert_file_noop ARG # Copy ARG to func_to_host_file_result. func_convert_file_noop () { func_to_host_file_result=$1 } # end func_convert_file_noop # func_convert_file_msys_to_w32 ARG # Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic # conversion to w32 is not available inside the cwrapper. Returns result in # func_to_host_file_result. func_convert_file_msys_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_msys_to_w32 "$1" func_to_host_file_result=$func_convert_core_msys_to_w32_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_msys_to_w32 # func_convert_file_cygwin_to_w32 ARG # Convert file name ARG from Cygwin to w32 format. Returns result in # func_to_host_file_result. func_convert_file_cygwin_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then # because $build is cygwin, we call "the" cygpath in $PATH; no need to use # LT_CYGPATH in this case. func_to_host_file_result=`cygpath -m "$1"` fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_cygwin_to_w32 # func_convert_file_nix_to_w32 ARG # Convert file name ARG from *nix to w32 format. Requires a wine environment # and a working winepath. Returns result in func_to_host_file_result. func_convert_file_nix_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_file_wine_to_w32 "$1" func_to_host_file_result=$func_convert_core_file_wine_to_w32_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_nix_to_w32 # func_convert_file_msys_to_cygwin ARG # Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. # Returns result in func_to_host_file_result. func_convert_file_msys_to_cygwin () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_msys_to_w32 "$1" func_cygpath -u "$func_convert_core_msys_to_w32_result" func_to_host_file_result=$func_cygpath_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_msys_to_cygwin # func_convert_file_nix_to_cygwin ARG # Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed # in a wine environment, working winepath, and LT_CYGPATH set. Returns result # in func_to_host_file_result. func_convert_file_nix_to_cygwin () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. func_convert_core_file_wine_to_w32 "$1" func_cygpath -u "$func_convert_core_file_wine_to_w32_result" func_to_host_file_result=$func_cygpath_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_nix_to_cygwin ############################################# # $build to $host PATH CONVERSION FUNCTIONS # ############################################# # invoked via '$to_host_path_cmd ARG' # # In each case, ARG is the path to be converted from $build to $host format. # The result will be available in $func_to_host_path_result. # # Path separators are also converted from $build format to $host format. If # ARG begins or ends with a path separator character, it is preserved (but # converted to $host format) on output. # # All path conversion functions are named using the following convention: # file name conversion function : func_convert_file_X_to_Y () # path conversion function : func_convert_path_X_to_Y () # where, for any given $build/$host combination the 'X_to_Y' value is the # same. If conversion functions are added for new $build/$host combinations, # the two new functions must follow this pattern, or func_init_to_host_path_cmd # will break. # func_init_to_host_path_cmd # Ensures that function "pointer" variable $to_host_path_cmd is set to the # appropriate value, based on the value of $to_host_file_cmd. to_host_path_cmd= func_init_to_host_path_cmd () { $debug_cmd if test -z "$to_host_path_cmd"; then func_stripname 'func_convert_file_' '' "$to_host_file_cmd" to_host_path_cmd=func_convert_path_$func_stripname_result fi } # func_to_host_path ARG # Converts the path ARG from $build format to $host format. Return result # in func_to_host_path_result. func_to_host_path () { $debug_cmd func_init_to_host_path_cmd $to_host_path_cmd "$1" } # end func_to_host_path # func_convert_path_noop ARG # Copy ARG to func_to_host_path_result. func_convert_path_noop () { func_to_host_path_result=$1 } # end func_convert_path_noop # func_convert_path_msys_to_w32 ARG # Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic # conversion to w32 is not available inside the cwrapper. Returns result in # func_to_host_path_result. func_convert_path_msys_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # Remove leading and trailing path separator characters from ARG. MSYS # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; # and winepath ignores them completely. func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" func_to_host_path_result=$func_convert_core_msys_to_w32_result func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_msys_to_w32 # func_convert_path_cygwin_to_w32 ARG # Convert path ARG from Cygwin to w32 format. Returns result in # func_to_host_file_result. func_convert_path_cygwin_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_cygwin_to_w32 # func_convert_path_nix_to_w32 ARG # Convert path ARG from *nix to w32 format. Requires a wine environment and # a working winepath. Returns result in func_to_host_file_result. func_convert_path_nix_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" func_to_host_path_result=$func_convert_core_path_wine_to_w32_result func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_nix_to_w32 # func_convert_path_msys_to_cygwin ARG # Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. # Returns result in func_to_host_file_result. func_convert_path_msys_to_cygwin () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" func_cygpath -u -p "$func_convert_core_msys_to_w32_result" func_to_host_path_result=$func_cygpath_result func_convert_path_check : : \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" : "$1" fi } # end func_convert_path_msys_to_cygwin # func_convert_path_nix_to_cygwin ARG # Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a # a wine environment, working winepath, and LT_CYGPATH set. Returns result in # func_to_host_file_result. func_convert_path_nix_to_cygwin () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # Remove leading and trailing path separator characters from # ARG. msys behavior is inconsistent here, cygpath turns them # into '.;' and ';.', and winepath ignores them completely. func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" func_to_host_path_result=$func_cygpath_result func_convert_path_check : : \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" : "$1" fi } # end func_convert_path_nix_to_cygwin # func_dll_def_p FILE # True iff FILE is a Windows DLL '.def' file. # Keep in sync with _LT_DLL_DEF_P in libtool.m4 func_dll_def_p () { $debug_cmd func_dll_def_p_tmp=`$SED -n \ -e 's/^[ ]*//' \ -e '/^\(;.*\)*$/d' \ -e 's/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p' \ -e q \ "$1"` test DEF = "$func_dll_def_p_tmp" } # func_mode_compile arg... func_mode_compile () { $debug_cmd # Get the compilation command and the source file. base_compile= srcfile=$nonopt # always keep a non-empty value in "srcfile" suppress_opt=yes suppress_output= arg_mode=normal libobj= later= pie_flag= for arg do case $arg_mode in arg ) # do not "continue". Instead, add this to base_compile lastarg=$arg arg_mode=normal ;; target ) libobj=$arg arg_mode=normal continue ;; normal ) # Accept any command-line options. case $arg in -o) test -n "$libobj" && \ func_fatal_error "you cannot specify '-o' more than once" arg_mode=target continue ;; -pie | -fpie | -fPIE) func_append pie_flag " $arg" continue ;; -shared | -static | -prefer-pic | -prefer-non-pic) func_append later " $arg" continue ;; -no-suppress) suppress_opt=no continue ;; -Xcompiler) arg_mode=arg # the next one goes into the "base_compile" arg list continue # The current "srcfile" will either be retained or ;; # replaced later. I would guess that would be a bug. -Wc,*) func_stripname '-Wc,' '' "$arg" args=$func_stripname_result lastarg= save_ifs=$IFS; IFS=, for arg in $args; do IFS=$save_ifs func_append_quoted lastarg "$arg" done IFS=$save_ifs func_stripname ' ' '' "$lastarg" lastarg=$func_stripname_result # Add the arguments to base_compile. func_append base_compile " $lastarg" continue ;; *) # Accept the current argument as the source file. # The previous "srcfile" becomes the current argument. # lastarg=$srcfile srcfile=$arg ;; esac # case $arg ;; esac # case $arg_mode # Aesthetically quote the previous argument. func_append_quoted base_compile "$lastarg" done # for arg case $arg_mode in arg) func_fatal_error "you must specify an argument for -Xcompile" ;; target) func_fatal_error "you must specify a target with '-o'" ;; *) # Get the name of the library object. test -z "$libobj" && { func_basename "$srcfile" libobj=$func_basename_result } ;; esac # Recognize several different file suffixes. # If the user specifies -o file.o, it is replaced with file.lo case $libobj in *.[cCFSifmso] | \ *.ada | *.adb | *.ads | *.asm | \ *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) func_xform "$libobj" libobj=$func_xform_result ;; esac case $libobj in *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; *) func_fatal_error "cannot determine name of library object from '$libobj'" ;; esac func_infer_tag $base_compile for arg in $later; do case $arg in -shared) test yes = "$build_libtool_libs" \ || func_fatal_configuration "cannot build a shared library" build_old_libs=no continue ;; -static) build_libtool_libs=no build_old_libs=yes continue ;; -prefer-pic) pic_mode=yes continue ;; -prefer-non-pic) pic_mode=no continue ;; esac done func_quote_arg pretty "$libobj" test "X$libobj" != "X$func_quote_arg_result" \ && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ && func_warning "libobj name '$libobj' may not contain shell special characters." func_dirname_and_basename "$obj" "/" "" objname=$func_basename_result xdir=$func_dirname_result lobj=$xdir$objdir/$objname test -z "$base_compile" && \ func_fatal_help "you must specify a compilation command" # Delete any leftover library objects. if test yes = "$build_old_libs"; then removelist="$obj $lobj $libobj ${libobj}T" else removelist="$lobj $libobj ${libobj}T" fi # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in cygwin* | mingw* | pw32* | os2* | cegcc*) pic_mode=default ;; esac if test no = "$pic_mode" && test pass_all != "$deplibs_check_method"; then # non-PIC code in shared libraries is not supported pic_mode=default fi # Calculate the filename of the output object if compiler does # not support -o with -c if test no = "$compiler_c_o"; then output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.$objext lockfile=$output_obj.lock else output_obj= need_locks=no lockfile= fi # Lock this critical section if it is needed # We use this script file to make the link, it avoids creating a new file if test yes = "$need_locks"; then until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do func_echo "Waiting for $lockfile to be removed" sleep 2 done elif test warn = "$need_locks"; then if test -f "$lockfile"; then $ECHO "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi func_append removelist " $output_obj" $ECHO "$srcfile" > "$lockfile" fi $opt_dry_run || $RM $removelist func_append removelist " $lockfile" trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 srcfile=$func_to_tool_file_result func_quote_arg pretty "$srcfile" qsrcfile=$func_quote_arg_result # Only build a PIC object if we are building libtool libraries. if test yes = "$build_libtool_libs"; then # Without this assignment, base_compile gets emptied. fbsd_hideous_sh_bug=$base_compile if test no != "$pic_mode"; then command="$base_compile $qsrcfile $pic_flag" else # Don't build PIC code command="$base_compile $qsrcfile" fi func_mkdir_p "$xdir$objdir" if test -z "$output_obj"; then # Place PIC objects in $objdir func_append command " -o $lobj" fi func_show_eval_locale "$command" \ 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' if test warn = "$need_locks" && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi # Just move the object if needed, then go on to compile the next one if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then func_show_eval '$MV "$output_obj" "$lobj"' \ 'error=$?; $opt_dry_run || $RM $removelist; exit $error' fi # Allow error messages only from the first compilation. if test yes = "$suppress_opt"; then suppress_output=' >/dev/null 2>&1' fi fi # Only build a position-dependent object if we build old libraries. if test yes = "$build_old_libs"; then if test yes != "$pic_mode"; then # Don't build PIC code command="$base_compile $qsrcfile$pie_flag" else command="$base_compile $qsrcfile $pic_flag" fi if test yes = "$compiler_c_o"; then func_append command " -o $obj" fi # Suppress compiler output if we already did a PIC compilation. func_append command "$suppress_output" func_show_eval_locale "$command" \ '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' if test warn = "$need_locks" && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi # Just move the object if needed if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then func_show_eval '$MV "$output_obj" "$obj"' \ 'error=$?; $opt_dry_run || $RM $removelist; exit $error' fi fi $opt_dry_run || { func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" # Unlock the critical section if it was locked if test no != "$need_locks"; then removelist=$lockfile $RM "$lockfile" fi } exit $EXIT_SUCCESS } $opt_help || { test compile = "$opt_mode" && func_mode_compile ${1+"$@"} } func_mode_help () { # We need to display help for each of the modes. case $opt_mode in "") # Generic help is extracted from the usage comments # at the start of this file. func_help ;; clean) $ECHO \ "Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... Remove files from the build directory. RM is the name of the program to use to delete files associated with each FILE (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed to RM. If FILE is a libtool library, object or program, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; compile) $ECHO \ "Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE Compile a source file into a libtool library object. This mode accepts the following additional options: -o OUTPUT-FILE set the output file name to OUTPUT-FILE -no-suppress do not suppress compiler output for multiple passes -prefer-pic try to build PIC objects only -prefer-non-pic try to build non-PIC objects only -shared do not build a '.o' file suitable for static linking -static only build a '.o' file suitable for static linking -Wc,FLAG -Xcompiler FLAG pass FLAG directly to the compiler COMPILE-COMMAND is a command to be used in creating a 'standard' object file from the given SOURCEFILE. The output file name is determined by removing the directory component from SOURCEFILE, then substituting the C source code suffix '.c' with the library object suffix, '.lo'." ;; execute) $ECHO \ "Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... Automatically set library path, then run a program. This mode accepts the following additional options: -dlopen FILE add the directory containing FILE to the library path This mode sets the library path environment variable according to '-dlopen' flags. If any of the ARGS are libtool executable wrappers, then they are translated into their corresponding uninstalled binary, and any of their required library directories are added to the library path. Then, COMMAND is executed, with ARGS as arguments." ;; finish) $ECHO \ "Usage: $progname [OPTION]... --mode=finish [LIBDIR]... Complete the installation of libtool libraries. Each LIBDIR is a directory that contains libtool libraries. The commands that this mode executes may require superuser privileges. Use the '--dry-run' option if you just want to see what would be executed." ;; install) $ECHO \ "Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... Install executables or libraries. INSTALL-COMMAND is the installation command. The first component should be either the 'install' or 'cp' program. The following components of INSTALL-COMMAND are treated specially: -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation The rest of the components are interpreted as arguments to that command (only BSD-compatible install options are recognized)." ;; link) $ECHO \ "Usage: $progname [OPTION]... --mode=link LINK-COMMAND... Link object files or libraries together to form another library, or to create an executable program. LINK-COMMAND is a command using the C compiler that you would use to create a program from several object files. The following components of LINK-COMMAND are treated specially: -all-static do not do any dynamic linking at all -avoid-version do not add a version suffix if possible -bindir BINDIR specify path to binaries directory (for systems where libraries must be found in the PATH setting at runtime) -dlopen FILE '-dlpreopen' FILE if it cannot be dlopened at runtime -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) -export-symbols SYMFILE try to export only the symbols listed in SYMFILE -export-symbols-regex REGEX try to export only the symbols matching REGEX -LLIBDIR search LIBDIR for required installed libraries -lNAME OUTPUT-FILE requires the installed library libNAME -module build a library that can dlopened -no-fast-install disable the fast-install mode -no-install link a not-installable executable -no-undefined declare that a library does not refer to external symbols -o OUTPUT-FILE create OUTPUT-FILE from the specified objects -objectlist FILE use a list of object files found in FILE to specify objects -os2dllname NAME force a short DLL name on OS/2 (no effect on other OSes) -precious-files-regex REGEX don't remove output files matching REGEX -release RELEASE specify package release information -rpath LIBDIR the created library will eventually be installed in LIBDIR -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries -shared only do dynamic linking of libtool libraries -shrext SUFFIX override the standard shared library file extension -static do not do any dynamic linking of uninstalled libtool libraries -static-libtool-libs do not do any dynamic linking of libtool libraries -version-info CURRENT[:REVISION[:AGE]] specify library version info [each variable defaults to 0] -weak LIBNAME declare that the target provides the LIBNAME interface -Wc,FLAG -Xcompiler FLAG pass linker-specific FLAG directly to the compiler -Wa,FLAG -Xassembler FLAG pass linker-specific FLAG directly to the assembler -Wl,FLAG -Xlinker FLAG pass linker-specific FLAG directly to the linker -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) All other options (arguments beginning with '-') are ignored. Every other argument is treated as a filename. Files ending in '.la' are treated as uninstalled libtool libraries, other files are standard or library object files. If the OUTPUT-FILE ends in '.la', then a libtool library is created, only library objects ('.lo' files) may be specified, and '-rpath' is required, except when creating a convenience library. If OUTPUT-FILE ends in '.a' or '.lib', then a standard library is created using 'ar' and 'ranlib', or on Windows using 'lib'. If OUTPUT-FILE ends in '.lo' or '.$objext', then a reloadable object file is created, otherwise an executable program is created." ;; uninstall) $ECHO \ "Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... Remove libraries from an installation directory. RM is the name of the program to use to delete files associated with each FILE (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed to RM. If FILE is a libtool library, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; *) func_fatal_help "invalid operation mode '$opt_mode'" ;; esac echo $ECHO "Try '$progname --help' for more information about other modes." } # Now that we've collected a possible --mode arg, show help if necessary if $opt_help; then if test : = "$opt_help"; then func_mode_help else { func_help noexit for opt_mode in compile link execute install finish uninstall clean; do func_mode_help done } | $SED -n '1p; 2,$s/^Usage:/ or: /p' { func_help noexit for opt_mode in compile link execute install finish uninstall clean; do echo func_mode_help done } | $SED '1d /^When reporting/,/^Report/{ H d } $x /information about other modes/d /more detailed .*MODE/d s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' fi exit $? fi # func_mode_execute arg... func_mode_execute () { $debug_cmd # The first argument is the command name. cmd=$nonopt test -z "$cmd" && \ func_fatal_help "you must specify a COMMAND" # Handle -dlopen flags immediately. for file in $opt_dlopen; do test -f "$file" \ || func_fatal_help "'$file' is not a file" dir= case $file in *.la) func_resolve_sysroot "$file" file=$func_resolve_sysroot_result # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$file" \ || func_fatal_help "'$lib' is not a valid libtool archive" # Read the libtool library. dlname= library_names= func_source "$file" # Skip this library if it cannot be dlopened. if test -z "$dlname"; then # Warn if it was a shared library. test -n "$library_names" && \ func_warning "'$file' was not linked with '-export-dynamic'" continue fi func_dirname "$file" "" "." dir=$func_dirname_result if test -f "$dir/$objdir/$dlname"; then func_append dir "/$objdir" else if test ! -f "$dir/$dlname"; then func_fatal_error "cannot find '$dlname' in '$dir' or '$dir/$objdir'" fi fi ;; *.lo) # Just add the directory containing the .lo file. func_dirname "$file" "" "." dir=$func_dirname_result ;; *) func_warning "'-dlopen' is ignored for non-libtool libraries and objects" continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir=$absdir # Now add the directory to shlibpath_var. if eval "test -z \"\$$shlibpath_var\""; then eval "$shlibpath_var=\"\$dir\"" else eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" fi done # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic=$magic # Check if any of the arguments is a wrapper script. args= for file do case $file in -* | *.la | *.lo ) ;; *) # Do a test to see if this is really a libtool program. if func_ltwrapper_script_p "$file"; then func_source "$file" # Transform arg to wrapped name. file=$progdir/$program elif func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" func_source "$func_ltwrapper_scriptname_result" # Transform arg to wrapped name. file=$progdir/$program fi ;; esac # Quote arguments (to preserve shell metacharacters). func_append_quoted args "$file" done if $opt_dry_run; then # Display what would be done. if test -n "$shlibpath_var"; then eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" echo "export $shlibpath_var" fi $ECHO "$cmd$args" exit $EXIT_SUCCESS else if test -n "$shlibpath_var"; then # Export the shlibpath_var. eval "export $shlibpath_var" fi # Restore saved environment variables for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test \"\${save_$lt_var+set}\" = set; then $lt_var=\$save_$lt_var; export $lt_var else $lt_unset $lt_var fi" done # Now prepare to actually exec the command. exec_cmd=\$cmd$args fi } test execute = "$opt_mode" && func_mode_execute ${1+"$@"} # func_mode_finish arg... func_mode_finish () { $debug_cmd libs= libdirs= admincmds= for opt in "$nonopt" ${1+"$@"} do if test -d "$opt"; then func_append libdirs " $opt" elif test -f "$opt"; then if func_lalib_unsafe_p "$opt"; then func_append libs " $opt" else func_warning "'$opt' is not a valid libtool archive" fi else func_fatal_error "invalid argument '$opt'" fi done if test -n "$libs"; then if test -n "$lt_sysroot"; then sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" else sysroot_cmd= fi # Remove sysroot references if $opt_dry_run; then for lib in $libs; do echo "removing references to $lt_sysroot and '=' prefixes from $lib" done else tmpdir=`func_mktempdir` for lib in $libs; do $SED -e "$sysroot_cmd s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ > $tmpdir/tmp-la mv -f $tmpdir/tmp-la $lib done ${RM}r "$tmpdir" fi fi if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. func_execute_cmds "$finish_cmds" 'admincmds="$admincmds '"$cmd"'"' fi if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" $opt_dry_run || eval "$cmds" || func_append admincmds " $cmds" fi done fi # Exit here if they wanted silent mode. $opt_quiet && exit $EXIT_SUCCESS if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then echo "----------------------------------------------------------------------" echo "Libraries have been installed in:" for libdir in $libdirs; do $ECHO " $libdir" done echo echo "If you ever happen to want to link against installed libraries" echo "in a given directory, LIBDIR, you must either use libtool, and" echo "specify the full pathname of the library, or use the '-LLIBDIR'" echo "flag during linking and do at least one of the following:" if test -n "$shlibpath_var"; then echo " - add LIBDIR to the '$shlibpath_var' environment variable" echo " during execution" fi if test -n "$runpath_var"; then echo " - add LIBDIR to the '$runpath_var' environment variable" echo " during linking" fi if test -n "$hardcode_libdir_flag_spec"; then libdir=LIBDIR eval flag=\"$hardcode_libdir_flag_spec\" $ECHO " - use the '$flag' linker flag" fi if test -n "$admincmds"; then $ECHO " - have your system administrator run these commands:$admincmds" fi if test -f /etc/ld.so.conf; then echo " - have your system administrator add LIBDIR to '/etc/ld.so.conf'" fi echo echo "See any operating system documentation about shared libraries for" case $host in solaris2.[6789]|solaris2.1[0-9]) echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" echo "pages." ;; *) echo "more information, such as the ld(1) and ld.so(8) manual pages." ;; esac echo "----------------------------------------------------------------------" fi exit $EXIT_SUCCESS } test finish = "$opt_mode" && func_mode_finish ${1+"$@"} # func_mode_install arg... func_mode_install () { $debug_cmd # There may be an optional sh(1) argument at the beginning of # install_prog (especially on Windows NT). if test "$SHELL" = "$nonopt" || test /bin/sh = "$nonopt" || # Allow the use of GNU shtool's install command. case $nonopt in *shtool*) :;; *) false;; esac then # Aesthetically quote it. func_quote_arg pretty "$nonopt" install_prog="$func_quote_arg_result " arg=$1 shift else install_prog= arg=$nonopt fi # The real first argument should be the name of the installation program. # Aesthetically quote it. func_quote_arg pretty "$arg" func_append install_prog "$func_quote_arg_result" install_shared_prog=$install_prog case " $install_prog " in *[\\\ /]cp\ *) install_cp=: ;; *) install_cp=false ;; esac # We need to accept at least all the BSD install flags. dest= files= opts= prev= install_type= isdir=false stripme= no_mode=: for arg do arg2= if test -n "$dest"; then func_append files " $dest" dest=$arg continue fi case $arg in -d) isdir=: ;; -f) if $install_cp; then :; else prev=$arg fi ;; -g | -m | -o) prev=$arg ;; -s) stripme=" -s" continue ;; -*) ;; *) # If the previous option needed an argument, then skip it. if test -n "$prev"; then if test X-m = "X$prev" && test -n "$install_override_mode"; then arg2=$install_override_mode no_mode=false fi prev= else dest=$arg continue fi ;; esac # Aesthetically quote the argument. func_quote_arg pretty "$arg" func_append install_prog " $func_quote_arg_result" if test -n "$arg2"; then func_quote_arg pretty "$arg2" fi func_append install_shared_prog " $func_quote_arg_result" done test -z "$install_prog" && \ func_fatal_help "you must specify an install program" test -n "$prev" && \ func_fatal_help "the '$prev' option requires an argument" if test -n "$install_override_mode" && $no_mode; then if $install_cp; then :; else func_quote_arg pretty "$install_override_mode" func_append install_shared_prog " -m $func_quote_arg_result" fi fi if test -z "$files"; then if test -z "$dest"; then func_fatal_help "no file or destination specified" else func_fatal_help "you must specify a destination" fi fi # Strip any trailing slash from the destination. func_stripname '' '/' "$dest" dest=$func_stripname_result # Check to see that the destination is a directory. test -d "$dest" && isdir=: if $isdir; then destdir=$dest destname= else func_dirname_and_basename "$dest" "" "." destdir=$func_dirname_result destname=$func_basename_result # Not a directory, so check to see that there is only one file specified. set dummy $files; shift test "$#" -gt 1 && \ func_fatal_help "'$dest' is not a directory" fi case $destdir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) for file in $files; do case $file in *.lo) ;; *) func_fatal_help "'$destdir' must be an absolute directory name" ;; esac done ;; esac # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic=$magic staticlibs= future_libdirs= current_libdirs= for file in $files; do # Do each installation. case $file in *.$libext) # Do the static libraries later. func_append staticlibs " $file" ;; *.la) func_resolve_sysroot "$file" file=$func_resolve_sysroot_result # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$file" \ || func_fatal_help "'$file' is not a valid libtool archive" library_names= old_library= relink_command= func_source "$file" # Add the libdir to current_libdirs if it is the destination. if test "X$destdir" = "X$libdir"; then case "$current_libdirs " in *" $libdir "*) ;; *) func_append current_libdirs " $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; *) func_append future_libdirs " $libdir" ;; esac fi func_dirname "$file" "/" "" dir=$func_dirname_result func_append dir "$objdir" if test -n "$relink_command"; then # Determine the prefix the user has applied to our future dir. inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that # are installed to the same prefix. # At present, this check doesn't affect windows .dll's that # are installed into $libdir/../bin (currently, that works fine) # but it's something to keep an eye on. test "$inst_prefix_dir" = "$destdir" && \ func_fatal_error "error: cannot install '$file' to a directory not ending in $libdir" if test -n "$inst_prefix_dir"; then # Stick the inst_prefix_dir data into the link command. relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` else relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` fi func_warning "relinking '$file'" func_show_eval "$relink_command" \ 'func_fatal_error "error: relink '\''$file'\'' with the above command before installing it"' fi # See the names of the shared library. set dummy $library_names; shift if test -n "$1"; then realname=$1 shift srcname=$realname test -n "$relink_command" && srcname=${realname}T # Install the shared library and build the symlinks. func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ 'exit $?' tstripme=$stripme case $host_os in cygwin* | mingw* | pw32* | cegcc*) case $realname in *.dll.a) tstripme= ;; esac ;; os2*) case $realname in *_dll.a) tstripme= ;; esac ;; esac if test -n "$tstripme" && test -n "$striplib"; then func_show_eval "$striplib $destdir/$realname" 'exit $?' fi if test "$#" -gt 0; then # Delete the old symlinks, and create new ones. # Try 'ln -sf' first, because the 'ln' binary might depend on # the symlink we replace! Solaris /bin/ln does not understand -f, # so we also need to try rm && ln -s. for linkname do test "$linkname" != "$realname" \ && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" done fi # Do each command in the postinstall commands. lib=$destdir/$realname func_execute_cmds "$postinstall_cmds" 'exit $?' fi # Install the pseudo-library for information purposes. func_basename "$file" name=$func_basename_result instname=$dir/${name}i func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' # Maybe install the static library, too. test -n "$old_library" && func_append staticlibs " $dir/$old_library" ;; *.lo) # Install (i.e. copy) a libtool object. # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile=$destdir/$destname else func_basename "$file" destfile=$func_basename_result destfile=$destdir/$destfile fi # Deduce the name of the destination old-style object file. case $destfile in *.lo) func_lo2o "$destfile" staticdest=$func_lo2o_result ;; *.$objext) staticdest=$destfile destfile= ;; *) func_fatal_help "cannot copy a libtool object to '$destfile'" ;; esac # Install the libtool object if requested. test -n "$destfile" && \ func_show_eval "$install_prog $file $destfile" 'exit $?' # Install the old object if enabled. if test yes = "$build_old_libs"; then # Deduce the name of the old-style object file. func_lo2o "$file" staticobj=$func_lo2o_result func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' fi exit $EXIT_SUCCESS ;; *) # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile=$destdir/$destname else func_basename "$file" destfile=$func_basename_result destfile=$destdir/$destfile fi # If the file is missing, and there is a .exe on the end, strip it # because it is most likely a libtool script we actually want to # install stripped_ext= case $file in *.exe) if test ! -f "$file"; then func_stripname '' '.exe' "$file" file=$func_stripname_result stripped_ext=.exe fi ;; esac # Do a test to see if this is really a libtool program. case $host in *cygwin* | *mingw*) if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" wrapper=$func_ltwrapper_scriptname_result else func_stripname '' '.exe' "$file" wrapper=$func_stripname_result fi ;; *) wrapper=$file ;; esac if func_ltwrapper_script_p "$wrapper"; then notinst_deplibs= relink_command= func_source "$wrapper" # Check the variables that should have been set. test -z "$generated_by_libtool_version" && \ func_fatal_error "invalid libtool wrapper script '$wrapper'" finalize=: for lib in $notinst_deplibs; do # Check to see that each library is installed. libdir= if test -f "$lib"; then func_source "$lib" fi libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'` if test -n "$libdir" && test ! -f "$libfile"; then func_warning "'$lib' has not been installed in '$libdir'" finalize=false fi done relink_command= func_source "$wrapper" outputname= if test no = "$fast_install" && test -n "$relink_command"; then $opt_dry_run || { if $finalize; then tmpdir=`func_mktempdir` func_basename "$file$stripped_ext" file=$func_basename_result outputname=$tmpdir/$file # Replace the output file specification. relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` $opt_quiet || { func_quote_arg expand,pretty "$relink_command" eval "func_echo $func_quote_arg_result" } if eval "$relink_command"; then : else func_error "error: relink '$file' with the above command before installing it" $opt_dry_run || ${RM}r "$tmpdir" continue fi file=$outputname else func_warning "cannot relink '$file'" fi } else # Install the binary that we compiled earlier. file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` fi fi # remove .exe since cygwin /usr/bin/install will append another # one anyway case $install_prog,$host in */usr/bin/install*,*cygwin*) case $file:$destfile in *.exe:*.exe) # this is ok ;; *.exe:*) destfile=$destfile.exe ;; *:*.exe) func_stripname '' '.exe' "$destfile" destfile=$func_stripname_result ;; esac ;; esac func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' $opt_dry_run || if test -n "$outputname"; then ${RM}r "$tmpdir" fi ;; esac done for file in $staticlibs; do func_basename "$file" name=$func_basename_result # Set up the ranlib parameters. oldlib=$destdir/$name func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 tool_oldlib=$func_to_tool_file_result func_show_eval "$install_prog \$file \$oldlib" 'exit $?' if test -n "$stripme" && test -n "$old_striplib"; then func_show_eval "$old_striplib $tool_oldlib" 'exit $?' fi # Do each command in the postinstall commands. func_execute_cmds "$old_postinstall_cmds" 'exit $?' done test -n "$future_libdirs" && \ func_warning "remember to run '$progname --finish$future_libdirs'" if test -n "$current_libdirs"; then # Maybe just do a dry run. $opt_dry_run && current_libdirs=" -n$current_libdirs" exec_cmd='$SHELL "$progpath" $preserve_args --finish$current_libdirs' else exit $EXIT_SUCCESS fi } test install = "$opt_mode" && func_mode_install ${1+"$@"} # func_generate_dlsyms outputname originator pic_p # Extract symbols from dlprefiles and create ${outputname}S.o with # a dlpreopen symbol table. func_generate_dlsyms () { $debug_cmd my_outputname=$1 my_originator=$2 my_pic_p=${3-false} my_prefix=`$ECHO "$my_originator" | $SED 's%[^a-zA-Z0-9]%_%g'` my_dlsyms= if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then if test -n "$NM" && test -n "$global_symbol_pipe"; then my_dlsyms=${my_outputname}S.c else func_error "not configured to extract global symbols from dlpreopened files" fi fi if test -n "$my_dlsyms"; then case $my_dlsyms in "") ;; *.c) # Discover the nlist of each of the dlfiles. nlist=$output_objdir/$my_outputname.nm func_show_eval "$RM $nlist ${nlist}S ${nlist}T" # Parse the name list into a source file. func_verbose "creating $output_objdir/$my_dlsyms" $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ /* $my_dlsyms - symbol resolution table for '$my_outputname' dlsym emulation. */ /* Generated by $PROGRAM (GNU $PACKAGE) $VERSION */ #ifdef __cplusplus extern \"C\" { #endif #if defined __GNUC__ && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) #pragma GCC diagnostic ignored \"-Wstrict-prototypes\" #endif /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT_DLSYM_CONST #else # define LT_DLSYM_CONST const #endif #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) /* External symbol declarations for the compiler. */\ " if test yes = "$dlself"; then func_verbose "generating symbol list for '$output'" $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" # Add our own program objects to the symbol list. progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` for progfile in $progfiles; do func_to_tool_file "$progfile" func_convert_file_msys_to_w32 func_verbose "extracting global C symbols from '$func_to_tool_file_result'" $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then $opt_dry_run || { eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' } fi if test -n "$export_symbols_regex"; then $opt_dry_run || { eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' } fi # Prepare the list of exported symbols if test -z "$export_symbols"; then export_symbols=$output_objdir/$outputname.exp $opt_dry_run || { $RM $export_symbols eval "$SED -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; esac } else $opt_dry_run || { eval "$SED -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' case $host in *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; esac } fi fi for dlprefile in $dlprefiles; do func_verbose "extracting global C symbols from '$dlprefile'" func_basename "$dlprefile" name=$func_basename_result case $host in *cygwin* | *mingw* | *cegcc* ) # if an import library, we need to obtain dlname if func_win32_import_lib_p "$dlprefile"; then func_tr_sh "$dlprefile" eval "curr_lafile=\$libfile_$func_tr_sh_result" dlprefile_dlbasename= if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then # Use subshell, to avoid clobbering current variable values dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` if test -n "$dlprefile_dlname"; then func_basename "$dlprefile_dlname" dlprefile_dlbasename=$func_basename_result else # no lafile. user explicitly requested -dlpreopen . $sharedlib_from_linklib_cmd "$dlprefile" dlprefile_dlbasename=$sharedlib_from_linklib_result fi fi $opt_dry_run || { if test -n "$dlprefile_dlbasename"; then eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' else func_warning "Could not compute DLL name from $name" eval '$ECHO ": $name " >> "$nlist"' fi func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" } else # not an import lib $opt_dry_run || { eval '$ECHO ": $name " >> "$nlist"' func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" } fi ;; *) $opt_dry_run || { eval '$ECHO ": $name " >> "$nlist"' func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" } ;; esac done $opt_dry_run || { # Make sure we have at least an empty file. test -f "$nlist" || : > "$nlist" if test -n "$exclude_expsyms"; then $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T $MV "$nlist"T "$nlist" fi # Try sorting and uniquifying the output. if $GREP -v "^: " < "$nlist" | if sort -k 3 /dev/null 2>&1; then sort -k 3 else sort +2 fi | uniq > "$nlist"S; then : else $GREP -v "^: " < "$nlist" > "$nlist"S fi if test -f "$nlist"S; then eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' else echo '/* NONE */' >> "$output_objdir/$my_dlsyms" fi func_show_eval '$RM "${nlist}I"' if test -n "$global_symbol_to_import"; then eval "$global_symbol_to_import"' < "$nlist"S > "$nlist"I' fi echo >> "$output_objdir/$my_dlsyms" "\ /* The mapping between symbol names and symbols. */ typedef struct { const char *name; void *address; } lt_dlsymlist; extern LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[];\ " if test -s "$nlist"I; then echo >> "$output_objdir/$my_dlsyms" "\ static void lt_syminit(void) { LT_DLSYM_CONST lt_dlsymlist *symbol = lt_${my_prefix}_LTX_preloaded_symbols; for (; symbol->name; ++symbol) {" $SED 's/.*/ if (STREQ (symbol->name, \"&\")) symbol->address = (void *) \&&;/' < "$nlist"I >> "$output_objdir/$my_dlsyms" echo >> "$output_objdir/$my_dlsyms" "\ } }" fi echo >> "$output_objdir/$my_dlsyms" "\ LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[] = { {\"$my_originator\", (void *) 0}," if test -s "$nlist"I; then echo >> "$output_objdir/$my_dlsyms" "\ {\"@INIT@\", (void *) <_syminit}," fi case $need_lib_prefix in no) eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" ;; *) eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" ;; esac echo >> "$output_objdir/$my_dlsyms" "\ {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt_${my_prefix}_LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif\ " } # !$opt_dry_run pic_flag_for_symtable= case "$compile_command " in *" -static "*) ;; *) case $host in # compiling the symbol table file with pic_flag works around # a FreeBSD bug that causes programs to crash when -lm is # linked before any other PIC object. But we must not use # pic_flag when linking with -static. The problem exists in # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; *-*-hpux*) pic_flag_for_symtable=" $pic_flag" ;; *) $my_pic_p && pic_flag_for_symtable=" $pic_flag" ;; esac ;; esac symtab_cflags= for arg in $LTCFLAGS; do case $arg in -pie | -fpie | -fPIE) ;; *) func_append symtab_cflags " $arg" ;; esac done # Now compile the dynamic symbol file. func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' # Clean up the generated files. func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T" "${nlist}I"' # Transform the symbol file into the correct name. symfileobj=$output_objdir/${my_outputname}S.$objext case $host in *cygwin* | *mingw* | *cegcc* ) if test -f "$output_objdir/$my_outputname.def"; then compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` else compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` fi ;; *) compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` ;; esac ;; *) func_fatal_error "unknown suffix for '$my_dlsyms'" ;; esac else # We keep going just in case the user didn't refer to # lt_preloaded_symbols. The linker will fail if global_symbol_pipe # really was required. # Nullify the symbol file. compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` fi } # func_cygming_gnu_implib_p ARG # This predicate returns with zero status (TRUE) if # ARG is a GNU/binutils-style import library. Returns # with nonzero status (FALSE) otherwise. func_cygming_gnu_implib_p () { $debug_cmd func_to_tool_file "$1" func_convert_file_msys_to_w32 func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` test -n "$func_cygming_gnu_implib_tmp" } # func_cygming_ms_implib_p ARG # This predicate returns with zero status (TRUE) if # ARG is an MS-style import library. Returns # with nonzero status (FALSE) otherwise. func_cygming_ms_implib_p () { $debug_cmd func_to_tool_file "$1" func_convert_file_msys_to_w32 func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` test -n "$func_cygming_ms_implib_tmp" } # func_win32_libid arg # return the library type of file 'arg' # # Need a lot of goo to handle *both* DLLs and import libs # Has to be a shell function in order to 'eat' the argument # that is supplied when $file_magic_command is called. # Despite the name, also deal with 64 bit binaries. func_win32_libid () { $debug_cmd win32_libid_type=unknown win32_fileres=`file -L $1 2>/dev/null` case $win32_fileres in *ar\ archive\ import\ library*) # definitely import win32_libid_type="x86 archive import" ;; *ar\ archive*) # could be an import, or static # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then case $nm_interface in "MS dumpbin") if func_cygming_ms_implib_p "$1" || func_cygming_gnu_implib_p "$1" then win32_nmres=import else win32_nmres= fi ;; *) func_to_tool_file "$1" func_convert_file_msys_to_w32 win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | $SED -n -e ' 1,100{ / I /{ s|.*|import| p q } }'` ;; esac case $win32_nmres in import*) win32_libid_type="x86 archive import";; *) win32_libid_type="x86 archive static";; esac fi ;; *DLL*) win32_libid_type="x86 DLL" ;; *executable*) # but shell scripts are "executable" too... case $win32_fileres in *MS\ Windows\ PE\ Intel*) win32_libid_type="x86 DLL" ;; esac ;; esac $ECHO "$win32_libid_type" } # func_cygming_dll_for_implib ARG # # Platform-specific function to extract the # name of the DLL associated with the specified # import library ARG. # Invoked by eval'ing the libtool variable # $sharedlib_from_linklib_cmd # Result is available in the variable # $sharedlib_from_linklib_result func_cygming_dll_for_implib () { $debug_cmd sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` } # func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs # # The is the core of a fallback implementation of a # platform-specific function to extract the name of the # DLL associated with the specified import library LIBNAME. # # SECTION_NAME is either .idata$6 or .idata$7, depending # on the platform and compiler that created the implib. # # Echos the name of the DLL associated with the # specified import library. func_cygming_dll_for_implib_fallback_core () { $debug_cmd match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` $OBJDUMP -s --section "$1" "$2" 2>/dev/null | $SED '/^Contents of section '"$match_literal"':/{ # Place marker at beginning of archive member dllname section s/.*/====MARK====/ p d } # These lines can sometimes be longer than 43 characters, but # are always uninteresting /:[ ]*file format pe[i]\{,1\}-/d /^In archive [^:]*:/d # Ensure marker is printed /^====MARK====/p # Remove all lines with less than 43 characters /^.\{43\}/!d # From remaining lines, remove first 43 characters s/^.\{43\}//' | $SED -n ' # Join marker and all lines until next marker into a single line /^====MARK====/ b para H $ b para b :para x s/\n//g # Remove the marker s/^====MARK====// # Remove trailing dots and whitespace s/[\. \t]*$// # Print /./p' | # we now have a list, one entry per line, of the stringified # contents of the appropriate section of all members of the # archive that possess that section. Heuristic: eliminate # all those that have a first or second character that is # a '.' (that is, objdump's representation of an unprintable # character.) This should work for all archives with less than # 0x302f exports -- but will fail for DLLs whose name actually # begins with a literal '.' or a single character followed by # a '.'. # # Of those that remain, print the first one. $SED -e '/^\./d;/^.\./d;q' } # func_cygming_dll_for_implib_fallback ARG # Platform-specific function to extract the # name of the DLL associated with the specified # import library ARG. # # This fallback implementation is for use when $DLLTOOL # does not support the --identify-strict option. # Invoked by eval'ing the libtool variable # $sharedlib_from_linklib_cmd # Result is available in the variable # $sharedlib_from_linklib_result func_cygming_dll_for_implib_fallback () { $debug_cmd if func_cygming_gnu_implib_p "$1"; then # binutils import library sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` elif func_cygming_ms_implib_p "$1"; then # ms-generated import library sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` else # unknown sharedlib_from_linklib_result= fi } # func_extract_an_archive dir oldlib func_extract_an_archive () { $debug_cmd f_ex_an_ar_dir=$1; shift f_ex_an_ar_oldlib=$1 if test yes = "$lock_old_archive_extraction"; then lockfile=$f_ex_an_ar_oldlib.lock until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do func_echo "Waiting for $lockfile to be removed" sleep 2 done fi func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ 'stat=$?; rm -f "$lockfile"; exit $stat' if test yes = "$lock_old_archive_extraction"; then $opt_dry_run || rm -f "$lockfile" fi if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then : else func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" fi } # func_extract_archives gentop oldlib ... func_extract_archives () { $debug_cmd my_gentop=$1; shift my_oldlibs=${1+"$@"} my_oldobjs= my_xlib= my_xabs= my_xdir= for my_xlib in $my_oldlibs; do # Extract the objects. case $my_xlib in [\\/]* | [A-Za-z]:[\\/]*) my_xabs=$my_xlib ;; *) my_xabs=`pwd`"/$my_xlib" ;; esac func_basename "$my_xlib" my_xlib=$func_basename_result my_xlib_u=$my_xlib while :; do case " $extracted_archives " in *" $my_xlib_u "*) func_arith $extracted_serial + 1 extracted_serial=$func_arith_result my_xlib_u=lt$extracted_serial-$my_xlib ;; *) break ;; esac done extracted_archives="$extracted_archives $my_xlib_u" my_xdir=$my_gentop/$my_xlib_u func_mkdir_p "$my_xdir" case $host in *-darwin*) func_verbose "Extracting $my_xabs" # Do not bother doing anything if just a dry run $opt_dry_run || { darwin_orig_dir=`pwd` cd $my_xdir || exit $? darwin_archive=$my_xabs darwin_curdir=`pwd` func_basename "$darwin_archive" darwin_base_archive=$func_basename_result darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` if test -n "$darwin_arches"; then darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` darwin_arch= func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" for darwin_arch in $darwin_arches; do func_mkdir_p "unfat-$$/$darwin_base_archive-$darwin_arch" $LIPO -thin $darwin_arch -output "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" "$darwin_archive" cd "unfat-$$/$darwin_base_archive-$darwin_arch" func_extract_an_archive "`pwd`" "$darwin_base_archive" cd "$darwin_curdir" $RM "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" done # $darwin_arches ## Okay now we've a bunch of thin objects, gotta fatten them up :) darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$sed_basename" | sort -u` darwin_file= darwin_files= for darwin_file in $darwin_filelist; do darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` $LIPO -create -output "$darwin_file" $darwin_files done # $darwin_filelist $RM -rf unfat-$$ cd "$darwin_orig_dir" else cd $darwin_orig_dir func_extract_an_archive "$my_xdir" "$my_xabs" fi # $darwin_arches } # !$opt_dry_run ;; *) func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` done func_extract_archives_result=$my_oldobjs } # func_emit_wrapper [arg=no] # # Emit a libtool wrapper script on stdout. # Don't directly open a file because we may want to # incorporate the script contents within a cygwin/mingw # wrapper executable. Must ONLY be called from within # func_mode_link because it depends on a number of variables # set therein. # # ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR # variable will take. If 'yes', then the emitted script # will assume that the directory where it is stored is # the $objdir directory. This is a cygwin/mingw-specific # behavior. func_emit_wrapper () { func_emit_wrapper_arg1=${1-no} $ECHO "\ #! $SHELL # $output - temporary wrapper script for $objdir/$outputname # Generated by $PROGRAM (GNU $PACKAGE) $VERSION # # The $output program cannot be directly executed until all the libtool # libraries that it depends on are installed. # # This wrapper script should never be moved out of the build directory. # If it is, it will not operate correctly. # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. sed_quote_subst='$sed_quote_subst' # Be Bourne compatible if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH relink_command=\"$relink_command\" # This environment variable determines our operation mode. if test \"\$libtool_install_magic\" = \"$magic\"; then # install mode needs the following variables: generated_by_libtool_version='$macro_version' notinst_deplibs='$notinst_deplibs' else # When we are sourced in execute mode, \$file and \$ECHO are already set. if test \"\$libtool_execute_magic\" != \"$magic\"; then file=\"\$0\"" func_quote_arg pretty "$ECHO" qECHO=$func_quote_arg_result $ECHO "\ # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$1 _LTECHO_EOF' } ECHO=$qECHO fi # Very basic option parsing. These options are (a) specific to # the libtool wrapper, (b) are identical between the wrapper # /script/ and the wrapper /executable/ that is used only on # windows platforms, and (c) all begin with the string "--lt-" # (application programs are unlikely to have options that match # this pattern). # # There are only two supported options: --lt-debug and # --lt-dump-script. There is, deliberately, no --lt-help. # # The first argument to this parsing function should be the # script's $0 value, followed by "$@". lt_option_debug= func_parse_lt_options () { lt_script_arg0=\$0 shift for lt_opt do case \"\$lt_opt\" in --lt-debug) lt_option_debug=1 ;; --lt-dump-script) lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` cat \"\$lt_dump_D/\$lt_dump_F\" exit 0 ;; --lt-*) \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 exit 1 ;; esac done # Print the debug banner immediately: if test -n \"\$lt_option_debug\"; then echo \"$outputname:$output:\$LINENO: libtool wrapper (GNU $PACKAGE) $VERSION\" 1>&2 fi } # Used when --lt-debug. Prints its arguments to stdout # (redirection is the responsibility of the caller) func_lt_dump_args () { lt_dump_args_N=1; for lt_arg do \$ECHO \"$outputname:$output:\$LINENO: newargv[\$lt_dump_args_N]: \$lt_arg\" lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` done } # Core function for launching the target application func_exec_program_core () { " case $host in # Backslashes separate directories on plain windows *-*-mingw | *-*-os2* | *-cegcc*) $ECHO "\ if test -n \"\$lt_option_debug\"; then \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir\\\\\$program\" 1>&2 func_lt_dump_args \${1+\"\$@\"} 1>&2 fi exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} " ;; *) $ECHO "\ if test -n \"\$lt_option_debug\"; then \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir/\$program\" 1>&2 func_lt_dump_args \${1+\"\$@\"} 1>&2 fi exec \"\$progdir/\$program\" \${1+\"\$@\"} " ;; esac $ECHO "\ \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 exit 1 } # A function to encapsulate launching the target application # Strips options in the --lt-* namespace from \$@ and # launches target application with the remaining arguments. func_exec_program () { case \" \$* \" in *\\ --lt-*) for lt_wr_arg do case \$lt_wr_arg in --lt-*) ;; *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; esac shift done ;; esac func_exec_program_core \${1+\"\$@\"} } # Parse options func_parse_lt_options \"\$0\" \${1+\"\$@\"} # Find the directory that this script lives in. thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` while test -n \"\$file\"; do destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` # If there was a directory component, then change thisdir. if test \"x\$destdir\" != \"x\$file\"; then case \"\$destdir\" in [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; *) thisdir=\"\$thisdir/\$destdir\" ;; esac fi file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` done # Usually 'no', except on cygwin/mingw when embedded into # the cwrapper. WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then # special case for '.' if test \"\$thisdir\" = \".\"; then thisdir=\`pwd\` fi # remove .libs from thisdir case \"\$thisdir\" in *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; $objdir ) thisdir=. ;; esac fi # Try to get the absolute directory name. absdir=\`cd \"\$thisdir\" && pwd\` test -n \"\$absdir\" && thisdir=\"\$absdir\" " if test yes = "$fast_install"; then $ECHO "\ program=lt-'$outputname'$exeext progdir=\"\$thisdir/$objdir\" if test ! -f \"\$progdir/\$program\" || { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | $SED 1q\`; \\ test \"X\$file\" != \"X\$progdir/\$program\"; }; then file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $MKDIR \"\$progdir\" else $RM \"\$progdir/\$file\" fi" $ECHO "\ # relink executable if necessary if test -n \"\$relink_command\"; then if relink_command_output=\`eval \$relink_command 2>&1\`; then : else \$ECHO \"\$relink_command_output\" >&2 $RM \"\$progdir/\$file\" exit 1 fi fi $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || { $RM \"\$progdir/\$program\"; $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } $RM \"\$progdir/\$file\" fi" else $ECHO "\ program='$outputname' progdir=\"\$thisdir/$objdir\" " fi $ECHO "\ if test -f \"\$progdir/\$program\"; then" # fixup the dll searchpath if we need to. # # Fix the DLL searchpath if we need to. Do this before prepending # to shlibpath, because on Windows, both are PATH and uninstalled # libraries must come first. if test -n "$dllsearchpath"; then $ECHO "\ # Add the dll search path components to the executable PATH PATH=$dllsearchpath:\$PATH " fi # Export our shlibpath_var if we have one. if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then $ECHO "\ # Add our own library path to $shlibpath_var $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" # Some systems cannot cope with colon-terminated $shlibpath_var # The second colon is a workaround for a bug in BeOS R4 sed $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` export $shlibpath_var " fi $ECHO "\ if test \"\$libtool_execute_magic\" != \"$magic\"; then # Run the actual program with our arguments. func_exec_program \${1+\"\$@\"} fi else # The program doesn't exist. \$ECHO \"\$0: error: '\$progdir/\$program' does not exist\" 1>&2 \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 exit 1 fi fi\ " } # func_emit_cwrapperexe_src # emit the source code for a wrapper executable on stdout # Must ONLY be called from within func_mode_link because # it depends on a number of variable set therein. func_emit_cwrapperexe_src () { cat < #include #ifdef _MSC_VER # include # include # include #else # include # include # ifdef __CYGWIN__ # include # endif #endif #include #include #include #include #include #include #include #include #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) /* declarations of non-ANSI functions */ #if defined __MINGW32__ # ifdef __STRICT_ANSI__ int _putenv (const char *); # endif #elif defined __CYGWIN__ # ifdef __STRICT_ANSI__ char *realpath (const char *, char *); int putenv (char *); int setenv (const char *, const char *, int); # endif /* #elif defined other_platform || defined ... */ #endif /* portability defines, excluding path handling macros */ #if defined _MSC_VER # define setmode _setmode # define stat _stat # define chmod _chmod # define getcwd _getcwd # define putenv _putenv # define S_IXUSR _S_IEXEC #elif defined __MINGW32__ # define setmode _setmode # define stat _stat # define chmod _chmod # define getcwd _getcwd # define putenv _putenv #elif defined __CYGWIN__ # define HAVE_SETENV # define FOPEN_WB "wb" /* #elif defined other platforms ... */ #endif #if defined PATH_MAX # define LT_PATHMAX PATH_MAX #elif defined MAXPATHLEN # define LT_PATHMAX MAXPATHLEN #else # define LT_PATHMAX 1024 #endif #ifndef S_IXOTH # define S_IXOTH 0 #endif #ifndef S_IXGRP # define S_IXGRP 0 #endif /* path handling portability macros */ #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' #endif #if defined _WIN32 || defined __MSDOS__ || defined __DJGPP__ || \ defined __OS2__ # define HAVE_DOS_BASED_FILE_SYSTEM # define FOPEN_WB "wb" # ifndef DIR_SEPARATOR_2 # define DIR_SEPARATOR_2 '\\' # endif # ifndef PATH_SEPARATOR_2 # define PATH_SEPARATOR_2 ';' # endif #endif #ifndef DIR_SEPARATOR_2 # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) #else /* DIR_SEPARATOR_2 */ # define IS_DIR_SEPARATOR(ch) \ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ #ifndef PATH_SEPARATOR_2 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) #else /* PATH_SEPARATOR_2 */ # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) #endif /* PATH_SEPARATOR_2 */ #ifndef FOPEN_WB # define FOPEN_WB "w" #endif #ifndef _O_BINARY # define _O_BINARY 0 #endif #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free (stale); stale = 0; } \ } while (0) #if defined LT_DEBUGWRAPPER static int lt_debug = 1; #else static int lt_debug = 0; #endif const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ void *xmalloc (size_t num); char *xstrdup (const char *string); const char *base_name (const char *name); char *find_executable (const char *wrapper); char *chase_symlinks (const char *pathspec); int make_executable (const char *path); int check_executable (const char *path); char *strendzap (char *str, const char *pat); void lt_debugprintf (const char *file, int line, const char *fmt, ...); void lt_fatal (const char *file, int line, const char *message, ...); static const char *nonnull (const char *s); static const char *nonempty (const char *s); void lt_setenv (const char *name, const char *value); char *lt_extend_str (const char *orig_value, const char *add, int to_end); void lt_update_exe_path (const char *name, const char *value); void lt_update_lib_path (const char *name, const char *value); char **prepare_spawn (char **argv); void lt_dump_script (FILE *f); EOF cat <= 0) && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) return 1; else return 0; } int make_executable (const char *path) { int rval = 0; struct stat st; lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", nonempty (path)); if ((!path) || (!*path)) return 0; if (stat (path, &st) >= 0) { rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); } return rval; } /* Searches for the full path of the wrapper. Returns newly allocated full path name if found, NULL otherwise Does not chase symlinks, even on platforms that support them. */ char * find_executable (const char *wrapper) { int has_slash = 0; const char *p; const char *p_next; /* static buffer for getcwd */ char tmp[LT_PATHMAX + 1]; size_t tmp_len; char *concat_name; lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", nonempty (wrapper)); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* Absolute path? */ #if defined HAVE_DOS_BASED_FILE_SYSTEM if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') { concat_name = xstrdup (wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } else { #endif if (IS_DIR_SEPARATOR (wrapper[0])) { concat_name = xstrdup (wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } #if defined HAVE_DOS_BASED_FILE_SYSTEM } #endif for (p = wrapper; *p; p++) if (*p == '/') { has_slash = 1; break; } if (!has_slash) { /* no slashes; search PATH */ const char *path = getenv ("PATH"); if (path != NULL) { for (p = path; *p; p = p_next) { const char *q; size_t p_len; for (q = p; *q; q++) if (IS_PATH_SEPARATOR (*q)) break; p_len = (size_t) (q - p); p_next = (*q == '\0' ? q : q + 1); if (p_len == 0) { /* empty path: current directory */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", nonnull (strerror (errno))); tmp_len = strlen (tmp); concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); } else { concat_name = XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, p, p_len); concat_name[p_len] = '/'; strcpy (concat_name + p_len + 1, wrapper); } if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } } /* not found in PATH; assume curdir */ } /* Relative path | not found in path: prepend cwd */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", nonnull (strerror (errno))); tmp_len = strlen (tmp); concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); return NULL; } char * chase_symlinks (const char *pathspec) { #ifndef S_ISLNK return xstrdup (pathspec); #else char buf[LT_PATHMAX]; struct stat s; char *tmp_pathspec = xstrdup (pathspec); char *p; int has_symlinks = 0; while (strlen (tmp_pathspec) && !has_symlinks) { lt_debugprintf (__FILE__, __LINE__, "checking path component for symlinks: %s\n", tmp_pathspec); if (lstat (tmp_pathspec, &s) == 0) { if (S_ISLNK (s.st_mode) != 0) { has_symlinks = 1; break; } /* search backwards for last DIR_SEPARATOR */ p = tmp_pathspec + strlen (tmp_pathspec) - 1; while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) p--; if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) { /* no more DIR_SEPARATORS left */ break; } *p = '\0'; } else { lt_fatal (__FILE__, __LINE__, "error accessing file \"%s\": %s", tmp_pathspec, nonnull (strerror (errno))); } } XFREE (tmp_pathspec); if (!has_symlinks) { return xstrdup (pathspec); } tmp_pathspec = realpath (pathspec, buf); if (tmp_pathspec == 0) { lt_fatal (__FILE__, __LINE__, "could not follow symlinks for %s", pathspec); } return xstrdup (tmp_pathspec); #endif } char * strendzap (char *str, const char *pat) { size_t len, patlen; assert (str != NULL); assert (pat != NULL); len = strlen (str); patlen = strlen (pat); if (patlen <= len) { str += len - patlen; if (STREQ (str, pat)) *str = '\0'; } return str; } void lt_debugprintf (const char *file, int line, const char *fmt, ...) { va_list args; if (lt_debug) { (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); va_start (args, fmt); (void) vfprintf (stderr, fmt, args); va_end (args); } } static void lt_error_core (int exit_status, const char *file, int line, const char *mode, const char *message, va_list ap) { fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); vfprintf (stderr, message, ap); fprintf (stderr, ".\n"); if (exit_status >= 0) exit (exit_status); } void lt_fatal (const char *file, int line, const char *message, ...) { va_list ap; va_start (ap, message); lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); va_end (ap); } static const char * nonnull (const char *s) { return s ? s : "(null)"; } static const char * nonempty (const char *s) { return (s && !*s) ? "(empty)" : nonnull (s); } void lt_setenv (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_setenv) setting '%s' to '%s'\n", nonnull (name), nonnull (value)); { #ifdef HAVE_SETENV /* always make a copy, for consistency with !HAVE_SETENV */ char *str = xstrdup (value); setenv (name, str, 1); #else size_t len = strlen (name) + 1 + strlen (value) + 1; char *str = XMALLOC (char, len); sprintf (str, "%s=%s", name, value); if (putenv (str) != EXIT_SUCCESS) { XFREE (str); } #endif } } char * lt_extend_str (const char *orig_value, const char *add, int to_end) { char *new_value; if (orig_value && *orig_value) { size_t orig_value_len = strlen (orig_value); size_t add_len = strlen (add); new_value = XMALLOC (char, add_len + orig_value_len + 1); if (to_end) { strcpy (new_value, orig_value); strcpy (new_value + orig_value_len, add); } else { strcpy (new_value, add); strcpy (new_value + add_len, orig_value); } } else { new_value = xstrdup (add); } return new_value; } void lt_update_exe_path (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", nonnull (name), nonnull (value)); if (name && *name && value && *value) { char *new_value = lt_extend_str (getenv (name), value, 0); /* some systems can't cope with a ':'-terminated path #' */ size_t len = strlen (new_value); while ((len > 0) && IS_PATH_SEPARATOR (new_value[len-1])) { new_value[--len] = '\0'; } lt_setenv (name, new_value); XFREE (new_value); } } void lt_update_lib_path (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", nonnull (name), nonnull (value)); if (name && *name && value && *value) { char *new_value = lt_extend_str (getenv (name), value, 0); lt_setenv (name, new_value); XFREE (new_value); } } EOF case $host_os in mingw*) cat <<"EOF" /* Prepares an argument vector before calling spawn(). Note that spawn() does not by itself call the command interpreter (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); GetVersionEx(&v); v.dwPlatformId == VER_PLATFORM_WIN32_NT; }) ? "cmd.exe" : "command.com"). Instead it simply concatenates the arguments, separated by ' ', and calls CreateProcess(). We must quote the arguments since Win32 CreateProcess() interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a special way: - Space and tab are interpreted as delimiters. They are not treated as delimiters if they are surrounded by double quotes: "...". - Unescaped double quotes are removed from the input. Their only effect is that within double quotes, space and tab are treated like normal characters. - Backslashes not followed by double quotes are not special. - But 2*n+1 backslashes followed by a double quote become n backslashes followed by a double quote (n >= 0): \" -> " \\\" -> \" \\\\\" -> \\" */ #define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" #define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" char ** prepare_spawn (char **argv) { size_t argc; char **new_argv; size_t i; /* Count number of arguments. */ for (argc = 0; argv[argc] != NULL; argc++) ; /* Allocate new argument vector. */ new_argv = XMALLOC (char *, argc + 1); /* Put quoted arguments into the new argument vector. */ for (i = 0; i < argc; i++) { const char *string = argv[i]; if (string[0] == '\0') new_argv[i] = xstrdup ("\"\""); else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) { int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); size_t length; unsigned int backslashes; const char *s; char *quoted_string; char *p; length = 0; backslashes = 0; if (quote_around) length++; for (s = string; *s != '\0'; s++) { char c = *s; if (c == '"') length += backslashes + 1; length++; if (c == '\\') backslashes++; else backslashes = 0; } if (quote_around) length += backslashes + 1; quoted_string = XMALLOC (char, length + 1); p = quoted_string; backslashes = 0; if (quote_around) *p++ = '"'; for (s = string; *s != '\0'; s++) { char c = *s; if (c == '"') { unsigned int j; for (j = backslashes + 1; j > 0; j--) *p++ = '\\'; } *p++ = c; if (c == '\\') backslashes++; else backslashes = 0; } if (quote_around) { unsigned int j; for (j = backslashes; j > 0; j--) *p++ = '\\'; *p++ = '"'; } *p = '\0'; new_argv[i] = quoted_string; } else new_argv[i] = (char *) string; } new_argv[argc] = NULL; return new_argv; } EOF ;; esac cat <<"EOF" void lt_dump_script (FILE* f) { EOF func_emit_wrapper yes | $SED -n -e ' s/^\(.\{79\}\)\(..*\)/\1\ \2/ h s/\([\\"]\)/\\\1/g s/$/\\n/ s/\([^\n]*\).*/ fputs ("\1", f);/p g D' cat <<"EOF" } EOF } # end: func_emit_cwrapperexe_src # func_win32_import_lib_p ARG # True if ARG is an import lib, as indicated by $file_magic_cmd func_win32_import_lib_p () { $debug_cmd case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in *import*) : ;; *) false ;; esac } # func_suncc_cstd_abi # !!ONLY CALL THIS FOR SUN CC AFTER $compile_command IS FULLY EXPANDED!! # Several compiler flags select an ABI that is incompatible with the # Cstd library. Avoid specifying it if any are in CXXFLAGS. func_suncc_cstd_abi () { $debug_cmd case " $compile_command " in *" -compat=g "*|*\ -std=c++[0-9][0-9]\ *|*" -library=stdcxx4 "*|*" -library=stlport4 "*) suncc_use_cstd_abi=no ;; *) suncc_use_cstd_abi=yes ;; esac } # func_mode_link arg... func_mode_link () { $debug_cmd case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) # It is impossible to link a dll without this setting, and # we shouldn't force the makefile maintainer to figure out # what system we are compiling for in order to pass an extra # flag for every libtool invocation. # allow_undefined=no # FIXME: Unfortunately, there are problems with the above when trying # to make a dll that has undefined symbols, in which case not # even a static library is built. For now, we need to specify # -no-undefined on the libtool link line when we can be certain # that all symbols are satisfied, otherwise we get a static library. allow_undefined=yes ;; *) allow_undefined=yes ;; esac libtool_args=$nonopt base_compile="$nonopt $@" compile_command=$nonopt finalize_command=$nonopt compile_rpath= finalize_rpath= compile_shlibpath= finalize_shlibpath= convenience= old_convenience= deplibs= old_deplibs= compiler_flags= linker_flags= dllsearchpath= lib_search_path=`pwd` inst_prefix_dir= new_inherited_linker_flags= avoid_version=no bindir= dlfiles= dlprefiles= dlself=no export_dynamic=no export_symbols= export_symbols_regex= generated= libobjs= ltlibs= module=no no_install=no objs= os2dllname= non_pic_objects= precious_files_regex= prefer_static_libs=no preload=false prev= prevarg= release= rpath= xrpath= perm_rpath= temp_rpath= thread_safe=no vinfo= vinfo_number=no weak_libs= single_module=$wl-single_module func_infer_tag $base_compile # We need to know -static, to get the right output filenames. for arg do case $arg in -shared) test yes != "$build_libtool_libs" \ && func_fatal_configuration "cannot build a shared library" build_old_libs=no break ;; -all-static | -static | -static-libtool-libs) case $arg in -all-static) if test yes = "$build_libtool_libs" && test -z "$link_static_flag"; then func_warning "complete static linking is impossible in this configuration" fi if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; -static) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=built ;; -static-libtool-libs) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; esac build_libtool_libs=no build_old_libs=yes break ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # Go through the arguments, transforming them on the way. while test "$#" -gt 0; do arg=$1 shift func_quote_arg pretty,unquoted "$arg" qarg=$func_quote_arg_unquoted_result func_append libtool_args " $func_quote_arg_result" # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in output) func_append compile_command " @OUTPUT@" func_append finalize_command " @OUTPUT@" ;; esac case $prev in bindir) bindir=$arg prev= continue ;; dlfiles|dlprefiles) $preload || { # Add the symbol object into the linking commands. func_append compile_command " @SYMFILE@" func_append finalize_command " @SYMFILE@" preload=: } case $arg in *.la | *.lo) ;; # We handle these cases below. force) if test no = "$dlself"; then dlself=needless export_dynamic=yes fi prev= continue ;; self) if test dlprefiles = "$prev"; then dlself=yes elif test dlfiles = "$prev" && test yes != "$dlopen_self"; then dlself=yes else dlself=needless export_dynamic=yes fi prev= continue ;; *) if test dlfiles = "$prev"; then func_append dlfiles " $arg" else func_append dlprefiles " $arg" fi prev= continue ;; esac ;; expsyms) export_symbols=$arg test -f "$arg" \ || func_fatal_error "symbol file '$arg' does not exist" prev= continue ;; expsyms_regex) export_symbols_regex=$arg prev= continue ;; framework) case $host in *-*-darwin*) case "$deplibs " in *" $qarg.ltframework "*) ;; *) func_append deplibs " $qarg.ltframework" # this is fixed later ;; esac ;; esac prev= continue ;; inst_prefix) inst_prefix_dir=$arg prev= continue ;; mllvm) # Clang does not use LLVM to link, so we can simply discard any # '-mllvm $arg' options when doing the link step. prev= continue ;; objectlist) if test -f "$arg"; then save_arg=$arg moreargs= for fil in `cat "$save_arg"` do # func_append moreargs " $fil" arg=$fil # A libtool-controlled object. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" if test -z "$pic_object" || test -z "$non_pic_object" || test none = "$pic_object" && test none = "$non_pic_object"; then func_fatal_error "cannot find name of object for '$arg'" fi # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result if test none != "$pic_object"; then # Prepend the subdirectory the object is found in. pic_object=$xdir$pic_object if test dlfiles = "$prev"; then if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then func_append dlfiles " $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test dlprefiles = "$prev"; then # Preload the old-style object. func_append dlprefiles " $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg=$pic_object fi # Non-PIC object. if test none != "$non_pic_object"; then # Prepend the subdirectory the object is found in. non_pic_object=$xdir$non_pic_object # A standard non-PIC object func_append non_pic_objects " $non_pic_object" if test -z "$pic_object" || test none = "$pic_object"; then arg=$non_pic_object fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object=$pic_object func_append non_pic_objects " $non_pic_object" fi else # Only an error if not doing a dry-run. if $opt_dry_run; then # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result func_lo2o "$arg" pic_object=$xdir$objdir/$func_lo2o_result non_pic_object=$xdir$func_lo2o_result func_append libobjs " $pic_object" func_append non_pic_objects " $non_pic_object" else func_fatal_error "'$arg' is not a valid libtool object" fi fi done else func_fatal_error "link input file '$arg' does not exist" fi arg=$save_arg prev= continue ;; os2dllname) os2dllname=$arg prev= continue ;; precious_regex) precious_files_regex=$arg prev= continue ;; release) release=-$arg prev= continue ;; rpath | xrpath) # We need an absolute path. case $arg in [\\/]* | [A-Za-z]:[\\/]*) ;; *) func_fatal_error "only absolute run-paths are allowed" ;; esac if test rpath = "$prev"; then case "$rpath " in *" $arg "*) ;; *) func_append rpath " $arg" ;; esac else case "$xrpath " in *" $arg "*) ;; *) func_append xrpath " $arg" ;; esac fi prev= continue ;; shrext) shrext_cmds=$arg prev= continue ;; weak) func_append weak_libs " $arg" prev= continue ;; xassembler) func_append compiler_flags " -Xassembler $qarg" prev= func_append compile_command " -Xassembler $qarg" func_append finalize_command " -Xassembler $qarg" continue ;; xcclinker) func_append linker_flags " $qarg" func_append compiler_flags " $qarg" prev= func_append compile_command " $qarg" func_append finalize_command " $qarg" continue ;; xcompiler) func_append compiler_flags " $qarg" prev= func_append compile_command " $qarg" func_append finalize_command " $qarg" continue ;; xlinker) func_append linker_flags " $qarg" func_append compiler_flags " $wl$qarg" prev= func_append compile_command " $wl$qarg" func_append finalize_command " $wl$qarg" continue ;; *) eval "$prev=\"\$arg\"" prev= continue ;; esac fi # test -n "$prev" prevarg=$arg case $arg in -all-static) if test -n "$link_static_flag"; then # See comment for -static flag below, for more details. func_append compile_command " $link_static_flag" func_append finalize_command " $link_static_flag" fi continue ;; -allow-undefined) # FIXME: remove this flag sometime in the future. func_fatal_error "'-allow-undefined' must not be used because it is the default" ;; -avoid-version) avoid_version=yes continue ;; -bindir) prev=bindir continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -export-dynamic) export_dynamic=yes continue ;; -export-symbols | -export-symbols-regex) if test -n "$export_symbols" || test -n "$export_symbols_regex"; then func_fatal_error "more than one -exported-symbols argument is not allowed" fi if test X-export-symbols = "X$arg"; then prev=expsyms else prev=expsyms_regex fi continue ;; -framework) prev=framework continue ;; -inst-prefix-dir) prev=inst_prefix continue ;; # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* # so, if we see these flags be careful not to treat them like -L -L[A-Z][A-Z]*:*) case $with_gcc/$host in no/*-*-irix* | /*-*-irix*) func_append compile_command " $arg" func_append finalize_command " $arg" ;; esac continue ;; -L*) func_stripname "-L" '' "$arg" if test -z "$func_stripname_result"; then if test "$#" -gt 0; then func_fatal_error "require no space between '-L' and '$1'" else func_fatal_error "need path for '-L' option" fi fi func_resolve_sysroot "$func_stripname_result" dir=$func_resolve_sysroot_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) absdir=`cd "$dir" && pwd` test -z "$absdir" && \ func_fatal_error "cannot determine absolute directory name of '$dir'" dir=$absdir ;; esac case "$deplibs " in *" -L$dir "* | *" $arg "*) # Will only happen for absolute or sysroot arguments ;; *) # Preserve sysroot, but never include relative directories case $dir in [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; *) func_append deplibs " -L$dir" ;; esac func_append lib_search_path " $dir" ;; esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; ::) dllsearchpath=$dir;; *) func_append dllsearchpath ":$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; ::) dllsearchpath=$testbindir;; *) func_append dllsearchpath ":$testbindir";; esac ;; esac continue ;; -l*) if test X-lc = "X$arg" || test X-lm = "X$arg"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) # These systems don't actually have a C or math library (as such) continue ;; *-*-os2*) # These systems don't actually have a C library (as such) test X-lc = "X$arg" && continue ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig* | *-*-midnightbsd*) # Do not include libc due to us having libc/libc_r. test X-lc = "X$arg" && continue ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C and math libraries are in the System framework func_append deplibs " System.ltframework" continue ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype test X-lc = "X$arg" && continue ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work test X-lc = "X$arg" && continue ;; esac elif test X-lc_r = "X$arg"; then case $host in *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig* | *-*-midnightbsd*) # Do not include libc_r directly, use -pthread flag. continue ;; esac fi func_append deplibs " $arg" continue ;; -mllvm) prev=mllvm continue ;; -module) module=yes continue ;; # Tru64 UNIX uses -model [arg] to determine the layout of C++ # classes, name mangling, and exception handling. # Darwin uses the -arch flag to determine output architecture. -model|-arch|-isysroot|--sysroot) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" prev=xcompiler continue ;; # Solaris ld rejects as of 11.4. Refer to Oracle bug 22985199. -pthread) case $host in *solaris2*) ;; *) case "$new_inherited_linker_flags " in *" $arg "*) ;; * ) func_append new_inherited_linker_flags " $arg" ;; esac ;; esac continue ;; -mt|-mthreads|-kthread|-Kthread|-pthreads|--thread-safe \ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" case "$new_inherited_linker_flags " in *" $arg "*) ;; * ) func_append new_inherited_linker_flags " $arg" ;; esac continue ;; -multi_module) single_module=$wl-multi_module continue ;; -no-fast-install) fast_install=no continue ;; -no-install) case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) # The PATH hackery in wrapper scripts is required on Windows # and Darwin in order for the loader to find any dlls it needs. func_warning "'-no-install' is ignored for $host" func_warning "assuming '-no-fast-install' instead" fast_install=no ;; *) no_install=yes ;; esac continue ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -os2dllname) prev=os2dllname continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -R*) func_stripname '-R' '' "$arg" dir=$func_stripname_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; =*) func_stripname '=' '' "$dir" dir=$lt_sysroot$func_stripname_result ;; *) func_fatal_error "only absolute run-paths are allowed" ;; esac case "$xrpath " in *" $dir "*) ;; *) func_append xrpath " $dir" ;; esac continue ;; -shared) # The effects of -shared are defined in a previous loop. continue ;; -shrext) prev=shrext continue ;; -static | -static-libtool-libs) # The effects of -static are defined in a previous loop. # We used to do the same as -all-static on platforms that # didn't have a PIC flag, but the assumption that the effects # would be equivalent was wrong. It would break on at least # Digital Unix and AIX. continue ;; -thread-safe) thread_safe=yes continue ;; -version-info) prev=vinfo continue ;; -version-number) prev=vinfo vinfo_number=yes continue ;; -weak) prev=weak continue ;; -Wc,*) func_stripname '-Wc,' '' "$arg" args=$func_stripname_result arg= save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs func_quote_arg pretty "$flag" func_append arg " $func_quote_arg_result" func_append compiler_flags " $func_quote_arg_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" arg=$func_stripname_result ;; -Wl,*) func_stripname '-Wl,' '' "$arg" args=$func_stripname_result arg= save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs func_quote_arg pretty "$flag" func_append arg " $wl$func_quote_arg_result" func_append compiler_flags " $wl$func_quote_arg_result" func_append linker_flags " $func_quote_arg_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" arg=$func_stripname_result ;; -Xassembler) prev=xassembler continue ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # -msg_* for osf cc -msg_*) func_quote_arg pretty "$arg" arg=$func_quote_arg_result ;; # Flags to be passed through unchanged, with rationale: # -64, -mips[0-9] enable 64-bit mode for the SGI compiler # -r[0-9][0-9]* specify processor for the SGI compiler # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler # +DA*, +DD* enable 64-bit mode for the HP compiler # -q* compiler args for the IBM compiler # -m*, -t[45]*, -txscale* architecture-specific flags for GCC # -F/path path to uninstalled frameworks, gcc on darwin # -p, -pg, --coverage, -fprofile-* profiling flags for GCC # -fstack-protector* stack protector flags for GCC # @file GCC response files # -tp=* Portland pgcc target processor selection # --sysroot=* for sysroot support # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization # -specs=* GCC specs files # -stdlib=* select c++ std lib with clang # -fsanitize=* Clang/GCC memory and address sanitizer # -fuse-ld=* Linker select flags for GCC # -Wa,* Pass flags directly to the assembler -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \ -specs=*|-fsanitize=*|-fuse-ld=*|-Wa,*) func_quote_arg pretty "$arg" arg=$func_quote_arg_result func_append compile_command " $arg" func_append finalize_command " $arg" func_append compiler_flags " $arg" continue ;; -Z*) if test os2 = "`expr $host : '.*\(os2\)'`"; then # OS/2 uses -Zxxx to specify OS/2-specific options compiler_flags="$compiler_flags $arg" func_append compile_command " $arg" func_append finalize_command " $arg" case $arg in -Zlinker | -Zstack) prev=xcompiler ;; esac continue else # Otherwise treat like 'Some other compiler flag' below func_quote_arg pretty "$arg" arg=$func_quote_arg_result fi ;; # Some other compiler flag. -* | +*) func_quote_arg pretty "$arg" arg=$func_quote_arg_result ;; *.$objext) # A standard object. func_append objs " $arg" ;; *.lo) # A libtool-controlled object. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" if test -z "$pic_object" || test -z "$non_pic_object" || test none = "$pic_object" && test none = "$non_pic_object"; then func_fatal_error "cannot find name of object for '$arg'" fi # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result test none = "$pic_object" || { # Prepend the subdirectory the object is found in. pic_object=$xdir$pic_object if test dlfiles = "$prev"; then if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then func_append dlfiles " $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test dlprefiles = "$prev"; then # Preload the old-style object. func_append dlprefiles " $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg=$pic_object } # Non-PIC object. if test none != "$non_pic_object"; then # Prepend the subdirectory the object is found in. non_pic_object=$xdir$non_pic_object # A standard non-PIC object func_append non_pic_objects " $non_pic_object" if test -z "$pic_object" || test none = "$pic_object"; then arg=$non_pic_object fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object=$pic_object func_append non_pic_objects " $non_pic_object" fi else # Only an error if not doing a dry-run. if $opt_dry_run; then # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result func_lo2o "$arg" pic_object=$xdir$objdir/$func_lo2o_result non_pic_object=$xdir$func_lo2o_result func_append libobjs " $pic_object" func_append non_pic_objects " $non_pic_object" else func_fatal_error "'$arg' is not a valid libtool object" fi fi ;; *.$libext) # An archive. func_append deplibs " $arg" func_append old_deplibs " $arg" continue ;; *.la) # A libtool-controlled library. func_resolve_sysroot "$arg" if test dlfiles = "$prev"; then # This library was specified with -dlopen. func_append dlfiles " $func_resolve_sysroot_result" prev= elif test dlprefiles = "$prev"; then # The library was specified with -dlpreopen. func_append dlprefiles " $func_resolve_sysroot_result" prev= else func_append deplibs " $func_resolve_sysroot_result" fi continue ;; # Some other compiler argument. *) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. func_quote_arg pretty "$arg" arg=$func_quote_arg_result ;; esac # arg # Now actually substitute the argument into the commands. if test -n "$arg"; then func_append compile_command " $arg" func_append finalize_command " $arg" fi done # argument parsing loop test -n "$prev" && \ func_fatal_help "the '$prevarg' option requires an argument" if test yes = "$export_dynamic" && test -n "$export_dynamic_flag_spec"; then eval arg=\"$export_dynamic_flag_spec\" func_append compile_command " $arg" func_append finalize_command " $arg" fi oldlibs= # calculate the name of the file, without its directory func_basename "$output" outputname=$func_basename_result libobjs_save=$libobjs if test -n "$shlibpath_var"; then # get the directories listed in $shlibpath_var eval shlib_search_path=\`\$ECHO \"\$$shlibpath_var\" \| \$SED \'s/:/ /g\'\` else shlib_search_path= fi eval sys_lib_search_path=\"$sys_lib_search_path_spec\" eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" # Definition is injected by LT_CONFIG during libtool generation. func_munge_path_list sys_lib_dlsearch_path "$LT_SYS_LIBRARY_PATH" func_dirname "$output" "/" "" output_objdir=$func_dirname_result$objdir func_to_tool_file "$output_objdir/" tool_output_objdir=$func_to_tool_file_result # Create the object directory. func_mkdir_p "$output_objdir" # Determine the type of output case $output in "") func_fatal_help "you must specify an output file" ;; *.$libext) linkmode=oldlib ;; *.lo | *.$objext) linkmode=obj ;; *.la) linkmode=lib ;; *) linkmode=prog ;; # Anything else should be a program. esac specialdeplibs= libs= # Find all interdependent deplibs by searching for libraries # that are linked more than once (e.g. -la -lb -la) for deplib in $deplibs; do if $opt_preserve_dup_deps; then case "$libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append libs " $deplib" done if test lib = "$linkmode"; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # Compute libraries that are listed more than once in $predeps # $postdeps and mark them as special (i.e., whose duplicates are # not to be eliminated). pre_post_deps= if $opt_duplicate_compiler_generated_deps; then for pre_post_dep in $predeps $postdeps; do case "$pre_post_deps " in *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; esac func_append pre_post_deps " $pre_post_dep" done fi pre_post_deps= fi deplibs= newdependency_libs= newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries notinst_path= # paths that contain not-installed libtool libraries case $linkmode in lib) passes="conv dlpreopen link" for file in $dlfiles $dlprefiles; do case $file in *.la) ;; *) func_fatal_help "libraries can '-dlopen' only libtool libraries: $file" ;; esac done ;; prog) compile_deplibs= finalize_deplibs= alldeplibs=false newdlfiles= newdlprefiles= passes="conv scan dlopen dlpreopen link" ;; *) passes="conv" ;; esac for pass in $passes; do # The preopen pass in lib mode reverses $deplibs; put it back here # so that -L comes before libs that need it for instance... if test lib,link = "$linkmode,$pass"; then ## FIXME: Find the place where the list is rebuilt in the wrong ## order, and fix it there properly tmp_deplibs= for deplib in $deplibs; do tmp_deplibs="$deplib $tmp_deplibs" done deplibs=$tmp_deplibs fi if test lib,link = "$linkmode,$pass" || test prog,scan = "$linkmode,$pass"; then libs=$deplibs deplibs= fi if test prog = "$linkmode"; then case $pass in dlopen) libs=$dlfiles ;; dlpreopen) libs=$dlprefiles ;; link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; esac fi if test lib,dlpreopen = "$linkmode,$pass"; then # Collect and forward deplibs of preopened libtool libs for lib in $dlprefiles; do # Ignore non-libtool-libs dependency_libs= func_resolve_sysroot "$lib" case $lib in *.la) func_source "$func_resolve_sysroot_result" ;; esac # Collect preopened libtool deplibs, except any this library # has declared as weak libs for deplib in $dependency_libs; do func_basename "$deplib" deplib_base=$func_basename_result case " $weak_libs " in *" $deplib_base "*) ;; *) func_append deplibs " $deplib" ;; esac done done libs=$dlprefiles fi if test dlopen = "$pass"; then # Collect dlpreopened libraries save_deplibs=$deplibs deplibs= fi for deplib in $libs; do lib= found=false case $deplib in -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else func_append compiler_flags " $deplib" if test lib = "$linkmode"; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi continue ;; -l*) if test lib != "$linkmode" && test prog != "$linkmode"; then func_warning "'-l' is ignored for archives/objects" continue fi func_stripname '-l' '' "$deplib" name=$func_stripname_result if test lib = "$linkmode"; then searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" else searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" fi for searchdir in $searchdirs; do for search_ext in .la $std_shrext .so .a; do # Search the libtool library lib=$searchdir/lib$name$search_ext if test -f "$lib"; then if test .la = "$search_ext"; then found=: else found=false fi break 2 fi done done if $found; then # deplib is a libtool library # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, # We need to do some special things here, and not later. if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $deplib "*) if func_lalib_p "$lib"; then library_names= old_library= func_source "$lib" for l in $old_library $library_names; do ll=$l done if test "X$ll" = "X$old_library"; then # only static version available found=false func_dirname "$lib" "" "." ladir=$func_dirname_result lib=$ladir/$old_library if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" fi continue fi fi ;; *) ;; esac fi else # deplib doesn't seem to be a libtool library if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" fi continue fi ;; # -l *.ltframework) if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" if test lib = "$linkmode"; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi continue ;; -L*) case $linkmode in lib) deplibs="$deplib $deplibs" test conv = "$pass" && continue newdependency_libs="$deplib $newdependency_libs" func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; prog) if test conv = "$pass"; then deplibs="$deplib $deplibs" continue fi if test scan = "$pass"; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; *) func_warning "'-L' is ignored for archives/objects" ;; esac # linkmode continue ;; # -L -R*) if test link = "$pass"; then func_stripname '-R' '' "$deplib" func_resolve_sysroot "$func_stripname_result" dir=$func_resolve_sysroot_result # Make sure the xrpath contains only unique directories. case "$xrpath " in *" $dir "*) ;; *) func_append xrpath " $dir" ;; esac fi deplibs="$deplib $deplibs" continue ;; *.la) func_resolve_sysroot "$deplib" lib=$func_resolve_sysroot_result ;; *.$libext) if test conv = "$pass"; then deplibs="$deplib $deplibs" continue fi case $linkmode in lib) # Linking convenience modules into shared libraries is allowed, # but linking other static libraries is non-portable. case " $dlpreconveniencelibs " in *" $deplib "*) ;; *) valid_a_lib=false case $deplibs_check_method in match_pattern*) set dummy $deplibs_check_method; shift match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then valid_a_lib=: fi ;; pass_all) valid_a_lib=: ;; esac if $valid_a_lib; then echo $ECHO "*** Warning: Linking the shared library $output against the" $ECHO "*** static library $deplib is not portable!" deplibs="$deplib $deplibs" else echo $ECHO "*** Warning: Trying to link with static lib archive $deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because the file extensions .$libext of this argument makes me believe" echo "*** that it is just a static archive that I should not use here." fi ;; esac continue ;; prog) if test link != "$pass"; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi continue ;; esac # linkmode ;; # *.$libext *.lo | *.$objext) if test conv = "$pass"; then deplibs="$deplib $deplibs" elif test prog = "$linkmode"; then if test dlpreopen = "$pass" || test yes != "$dlopen_support" || test no = "$build_libtool_libs"; then # If there is no dlopen support or we're linking statically, # we need to preload. func_append newdlprefiles " $deplib" compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else func_append newdlfiles " $deplib" fi fi continue ;; %DEPLIBS%) alldeplibs=: continue ;; esac # case $deplib $found || test -f "$lib" \ || func_fatal_error "cannot find the library '$lib' or unhandled argument '$deplib'" # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$lib" \ || func_fatal_error "'$lib' is not a valid libtool archive" func_dirname "$lib" "" "." ladir=$func_dirname_result dlname= dlopen= dlpreopen= libdir= library_names= old_library= inherited_linker_flags= # If the library was installed with an old release of libtool, # it will not redefine variables installed, or shouldnotlink installed=yes shouldnotlink=no avoidtemprpath= # Read the .la file func_source "$lib" # Convert "-framework foo" to "foo.ltframework" if test -n "$inherited_linker_flags"; then tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do case " $new_inherited_linker_flags " in *" $tmp_inherited_linker_flag "*) ;; *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; esac done fi dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` if test lib,link = "$linkmode,$pass" || test prog,scan = "$linkmode,$pass" || { test prog != "$linkmode" && test lib != "$linkmode"; }; then test -n "$dlopen" && func_append dlfiles " $dlopen" test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" fi if test conv = "$pass"; then # Only check for convenience libraries deplibs="$lib $deplibs" if test -z "$libdir"; then if test -z "$old_library"; then func_fatal_error "cannot find name of link library for '$lib'" fi # It is a libtool convenience library, so add in its objects. func_append convenience " $ladir/$objdir/$old_library" func_append old_convenience " $ladir/$objdir/$old_library" elif test prog != "$linkmode" && test lib != "$linkmode"; then func_fatal_error "'$lib' is not a convenience library" fi tmp_libs= for deplib in $dependency_libs; do deplibs="$deplib $deplibs" if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append tmp_libs " $deplib" done continue fi # $pass = conv # Get the name of the library we link against. linklib= if test -n "$old_library" && { test yes = "$prefer_static_libs" || test built,no = "$prefer_static_libs,$installed"; }; then linklib=$old_library else for l in $old_library $library_names; do linklib=$l done fi if test -z "$linklib"; then func_fatal_error "cannot find name of link library for '$lib'" fi # This library was specified with -dlopen. if test dlopen = "$pass"; then test -z "$libdir" \ && func_fatal_error "cannot -dlopen a convenience library: '$lib'" if test -z "$dlname" || test yes != "$dlopen_support" || test no = "$build_libtool_libs" then # If there is no dlname, no dlopen support or we're linking # statically, we need to preload. We also need to preload any # dependent libraries so libltdl's deplib preloader doesn't # bomb out in the load deplibs phase. func_append dlprefiles " $lib $dependency_libs" else func_append newdlfiles " $lib" fi continue fi # $pass = dlopen # We need an absolute path. case $ladir in [\\/]* | [A-Za-z]:[\\/]*) abs_ladir=$ladir ;; *) abs_ladir=`cd "$ladir" && pwd` if test -z "$abs_ladir"; then func_warning "cannot determine absolute directory name of '$ladir'" func_warning "passing it literally to the linker, although it might fail" abs_ladir=$ladir fi ;; esac func_basename "$lib" laname=$func_basename_result # Find the relevant object directory and library name. if test yes = "$installed"; then if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then func_warning "library '$lib' was moved." dir=$ladir absdir=$abs_ladir libdir=$abs_ladir else dir=$lt_sysroot$libdir absdir=$lt_sysroot$libdir fi test yes = "$hardcode_automatic" && avoidtemprpath=yes else if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then dir=$ladir absdir=$abs_ladir # Remove this search path later func_append notinst_path " $abs_ladir" else dir=$ladir/$objdir absdir=$abs_ladir/$objdir # Remove this search path later func_append notinst_path " $abs_ladir" fi fi # $installed = yes func_stripname 'lib' '.la' "$laname" name=$func_stripname_result # This library was specified with -dlpreopen. if test dlpreopen = "$pass"; then if test -z "$libdir" && test prog = "$linkmode"; then func_fatal_error "only libraries may -dlpreopen a convenience library: '$lib'" fi case $host in # special handling for platforms with PE-DLLs. *cygwin* | *mingw* | *cegcc* ) # Linker will automatically link against shared library if both # static and shared are present. Therefore, ensure we extract # symbols from the import library if a shared library is present # (otherwise, the dlopen module name will be incorrect). We do # this by putting the import library name into $newdlprefiles. # We recover the dlopen module name by 'saving' the la file # name in a special purpose variable, and (later) extracting the # dlname from the la file. if test -n "$dlname"; then func_tr_sh "$dir/$linklib" eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" func_append newdlprefiles " $dir/$linklib" else func_append newdlprefiles " $dir/$old_library" # Keep a list of preopened convenience libraries to check # that they are being used correctly in the link pass. test -z "$libdir" && \ func_append dlpreconveniencelibs " $dir/$old_library" fi ;; * ) # Prefer using a static library (so that no silly _DYNAMIC symbols # are required to link). if test -n "$old_library"; then func_append newdlprefiles " $dir/$old_library" # Keep a list of preopened convenience libraries to check # that they are being used correctly in the link pass. test -z "$libdir" && \ func_append dlpreconveniencelibs " $dir/$old_library" # Otherwise, use the dlname, so that lt_dlopen finds it. elif test -n "$dlname"; then func_append newdlprefiles " $dir/$dlname" else func_append newdlprefiles " $dir/$linklib" fi ;; esac fi # $pass = dlpreopen if test -z "$libdir"; then # Link the convenience library if test lib = "$linkmode"; then deplibs="$dir/$old_library $deplibs" elif test prog,link = "$linkmode,$pass"; then compile_deplibs="$dir/$old_library $compile_deplibs" finalize_deplibs="$dir/$old_library $finalize_deplibs" else deplibs="$lib $deplibs" # used for prog,scan pass fi continue fi if test prog = "$linkmode" && test link != "$pass"; then func_append newlib_search_path " $ladir" deplibs="$lib $deplibs" linkalldeplibs=false if test no != "$link_all_deplibs" || test -z "$library_names" || test no = "$build_libtool_libs"; then linkalldeplibs=: fi tmp_libs= for deplib in $dependency_libs; do case $deplib in -L*) func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; esac # Need to link against all dependency_libs? if $linkalldeplibs; then deplibs="$deplib $deplibs" else # Need to hardcode shared library paths # or/and link against static libraries newdependency_libs="$deplib $newdependency_libs" fi if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append tmp_libs " $deplib" done # for deplib continue fi # $linkmode = prog... if test prog,link = "$linkmode,$pass"; then if test -n "$library_names" && { { test no = "$prefer_static_libs" || test built,yes = "$prefer_static_libs,$installed"; } || test -z "$old_library"; }; then # We need to hardcode the library path if test -n "$shlibpath_var" && test -z "$avoidtemprpath"; then # Make sure the rpath contains only unique directories. case $temp_rpath: in *"$absdir:"*) ;; *) func_append temp_rpath "$absdir:" ;; esac fi # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) func_append compile_rpath " $absdir" ;; esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac ;; esac fi # $linkmode,$pass = prog,link... if $alldeplibs && { test pass_all = "$deplibs_check_method" || { test yes = "$build_libtool_libs" && test -n "$library_names"; }; }; then # We only need to search for static libraries continue fi fi link_static=no # Whether the deplib will be linked statically use_static_libs=$prefer_static_libs if test built = "$use_static_libs" && test yes = "$installed"; then use_static_libs=no fi if test -n "$library_names" && { test no = "$use_static_libs" || test -z "$old_library"; }; then case $host in *cygwin* | *mingw* | *cegcc* | *os2*) # No point in relinking DLLs because paths are not encoded func_append notinst_deplibs " $lib" need_relink=no ;; *) if test no = "$installed"; then func_append notinst_deplibs " $lib" need_relink=yes fi ;; esac # This is a shared library # Warn about portability, can't link against -module's on some # systems (darwin). Don't bleat about dlopened modules though! dlopenmodule= for dlpremoduletest in $dlprefiles; do if test "X$dlpremoduletest" = "X$lib"; then dlopenmodule=$dlpremoduletest break fi done if test -z "$dlopenmodule" && test yes = "$shouldnotlink" && test link = "$pass"; then echo if test prog = "$linkmode"; then $ECHO "*** Warning: Linking the executable $output against the loadable module" else $ECHO "*** Warning: Linking the shared library $output against the loadable module" fi $ECHO "*** $linklib is not portable!" fi if test lib = "$linkmode" && test yes = "$hardcode_into_libs"; then # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) func_append compile_rpath " $absdir" ;; esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac ;; esac fi if test -n "$old_archive_from_expsyms_cmds"; then # figure out the soname set dummy $library_names shift realname=$1 shift libname=`eval "\\$ECHO \"$libname_spec\""` # use dlname if we got it. it's perfectly good, no? if test -n "$dlname"; then soname=$dlname elif test -n "$soname_spec"; then # bleh windows case $host in *cygwin* | mingw* | *cegcc* | *os2*) func_arith $current - $age major=$func_arith_result versuffix=-$major ;; esac eval soname=\"$soname_spec\" else soname=$realname fi # Make a new name for the extract_expsyms_cmds to use soroot=$soname func_basename "$soroot" soname=$func_basename_result func_stripname 'lib' '.dll' "$soname" newlib=libimp-$func_stripname_result.a # If the library has no export list, then create one now if test -f "$output_objdir/$soname-def"; then : else func_verbose "extracting exported symbol list from '$soname'" func_execute_cmds "$extract_expsyms_cmds" 'exit $?' fi # Create $newlib if test -f "$output_objdir/$newlib"; then :; else func_verbose "generating import library for '$soname'" func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' fi # make sure the library variables are pointing to the new library dir=$output_objdir linklib=$newlib fi # test -n "$old_archive_from_expsyms_cmds" if test prog = "$linkmode" || test relink != "$opt_mode"; then add_shlibpath= add_dir= add= lib_linked=yes case $hardcode_action in immediate | unsupported) if test no = "$hardcode_direct"; then add=$dir/$linklib case $host in *-*-sco3.2v5.0.[024]*) add_dir=-L$dir ;; *-*-sysv4*uw2*) add_dir=-L$dir ;; *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ *-*-unixware7*) add_dir=-L$dir ;; *-*-darwin* ) # if the lib is a (non-dlopened) module then we cannot # link against it, someone is ignoring the earlier warnings if /usr/bin/file -L $add 2> /dev/null | $GREP ": [^:]* bundle" >/dev/null; then if test "X$dlopenmodule" != "X$lib"; then $ECHO "*** Warning: lib $linklib is a module, not a shared library" if test -z "$old_library"; then echo echo "*** And there doesn't seem to be a static archive available" echo "*** The link will probably fail, sorry" else add=$dir/$old_library fi elif test -n "$old_library"; then add=$dir/$old_library fi fi esac elif test no = "$hardcode_minus_L"; then case $host in *-*-sunos*) add_shlibpath=$dir ;; esac add_dir=-L$dir add=-l$name elif test no = "$hardcode_shlibpath_var"; then add_shlibpath=$dir add=-l$name else lib_linked=no fi ;; relink) if test yes = "$hardcode_direct" && test no = "$hardcode_direct_absolute"; then add=$dir/$linklib elif test yes = "$hardcode_minus_L"; then add_dir=-L$absdir # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi add=-l$name elif test yes = "$hardcode_shlibpath_var"; then add_shlibpath=$dir add=-l$name else lib_linked=no fi ;; *) lib_linked=no ;; esac if test yes != "$lib_linked"; then func_fatal_configuration "unsupported hardcode properties" fi if test -n "$add_shlibpath"; then case :$compile_shlibpath: in *":$add_shlibpath:"*) ;; *) func_append compile_shlibpath "$add_shlibpath:" ;; esac fi if test prog = "$linkmode"; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" if test yes != "$hardcode_direct" && test yes != "$hardcode_minus_L" && test yes = "$hardcode_shlibpath_var"; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) func_append finalize_shlibpath "$libdir:" ;; esac fi fi fi if test prog = "$linkmode" || test relink = "$opt_mode"; then add_shlibpath= add_dir= add= # Finalize command for both is simple: just hardcode it. if test yes = "$hardcode_direct" && test no = "$hardcode_direct_absolute"; then add=$libdir/$linklib elif test yes = "$hardcode_minus_L"; then add_dir=-L$libdir add=-l$name elif test yes = "$hardcode_shlibpath_var"; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) func_append finalize_shlibpath "$libdir:" ;; esac add=-l$name elif test yes = "$hardcode_automatic"; then if test -n "$inst_prefix_dir" && test -f "$inst_prefix_dir$libdir/$linklib"; then add=$inst_prefix_dir$libdir/$linklib else add=$libdir/$linklib fi else # We cannot seem to hardcode it, guess we'll fake it. add_dir=-L$libdir # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi add=-l$name fi if test prog = "$linkmode"; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" fi fi elif test prog = "$linkmode"; then # Here we assume that one of hardcode_direct or hardcode_minus_L # is not unsupported. This is valid on all known static and # shared platforms. if test unsupported != "$hardcode_direct"; then test -n "$old_library" && linklib=$old_library compile_deplibs="$dir/$linklib $compile_deplibs" finalize_deplibs="$dir/$linklib $finalize_deplibs" else compile_deplibs="-l$name -L$dir $compile_deplibs" finalize_deplibs="-l$name -L$dir $finalize_deplibs" fi elif test yes = "$build_libtool_libs"; then # Not a shared library if test pass_all != "$deplibs_check_method"; then # We're trying link a shared library against a static one # but the system doesn't support it. # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. echo $ECHO "*** Warning: This system cannot link to static lib archive $lib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have." if test yes = "$module"; then echo "*** But as you try to build a module library, libtool will still create " echo "*** a static module, that should work as long as the dlopening application" echo "*** is linked with the -dlopen flag to resolve symbols at runtime." if test -z "$global_symbol_pipe"; then echo echo "*** However, this would only work if libtool was able to extract symbol" echo "*** lists from a program, using 'nm' or equivalent, but libtool could" echo "*** not find such a program. So, this module is probably useless." echo "*** 'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi else deplibs="$dir/$old_library $deplibs" link_static=yes fi fi # link shared/static library? if test lib = "$linkmode"; then if test -n "$dependency_libs" && { test yes != "$hardcode_into_libs" || test yes = "$build_old_libs" || test yes = "$link_static"; }; then # Extract -R from dependency_libs temp_deplibs= for libdir in $dependency_libs; do case $libdir in -R*) func_stripname '-R' '' "$libdir" temp_xrpath=$func_stripname_result case " $xrpath " in *" $temp_xrpath "*) ;; *) func_append xrpath " $temp_xrpath";; esac;; *) func_append temp_deplibs " $libdir";; esac done dependency_libs=$temp_deplibs fi func_append newlib_search_path " $absdir" # Link against this library test no = "$link_static" && newdependency_libs="$abs_ladir/$laname $newdependency_libs" # ... and its dependency_libs tmp_libs= for deplib in $dependency_libs; do newdependency_libs="$deplib $newdependency_libs" case $deplib in -L*) func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result";; *) func_resolve_sysroot "$deplib" ;; esac if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $func_resolve_sysroot_result "*) func_append specialdeplibs " $func_resolve_sysroot_result" ;; esac fi func_append tmp_libs " $func_resolve_sysroot_result" done if test no != "$link_all_deplibs"; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do path= case $deplib in -L*) path=$deplib ;; *.la) func_resolve_sysroot "$deplib" deplib=$func_resolve_sysroot_result func_dirname "$deplib" "" "." dir=$func_dirname_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) absdir=$dir ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then func_warning "cannot determine absolute directory name of '$dir'" absdir=$dir fi ;; esac if $GREP "^installed=no" $deplib > /dev/null; then case $host in *-*-darwin*) depdepl= eval deplibrary_names=`$SED -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` if test -n "$deplibrary_names"; then for tmp in $deplibrary_names; do depdepl=$tmp done if test -f "$absdir/$objdir/$depdepl"; then depdepl=$absdir/$objdir/$depdepl darwin_install_name=`$OTOOL -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` if test -z "$darwin_install_name"; then darwin_install_name=`$OTOOL64 -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` fi func_append compiler_flags " $wl-dylib_file $wl$darwin_install_name:$depdepl" func_append linker_flags " -dylib_file $darwin_install_name:$depdepl" path= fi fi ;; *) path=-L$absdir/$objdir ;; esac else eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` test -z "$libdir" && \ func_fatal_error "'$deplib' is not a valid libtool archive" test "$absdir" != "$libdir" && \ func_warning "'$deplib' seems to be moved" path=-L$absdir fi ;; esac case " $deplibs " in *" $path "*) ;; *) deplibs="$path $deplibs" ;; esac done fi # link_all_deplibs != no fi # linkmode = lib done # for deplib in $libs if test link = "$pass"; then if test prog = "$linkmode"; then compile_deplibs="$new_inherited_linker_flags $compile_deplibs" finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" else compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` fi fi dependency_libs=$newdependency_libs if test dlpreopen = "$pass"; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do deplibs="$deplib $deplibs" done fi if test dlopen != "$pass"; then test conv = "$pass" || { # Make sure lib_search_path contains only unique directories. lib_search_path= for dir in $newlib_search_path; do case "$lib_search_path " in *" $dir "*) ;; *) func_append lib_search_path " $dir" ;; esac done newlib_search_path= } if test prog,link = "$linkmode,$pass"; then vars="compile_deplibs finalize_deplibs" else vars=deplibs fi for var in $vars dependency_libs; do # Add libraries to $var in reverse order eval tmp_libs=\"\$$var\" new_libs= for deplib in $tmp_libs; do # FIXME: Pedantically, this is the right thing to do, so # that some nasty dependency loop isn't accidentally # broken: #new_libs="$deplib $new_libs" # Pragmatically, this seems to cause very few problems in # practice: case $deplib in -L*) new_libs="$deplib $new_libs" ;; -R*) ;; *) # And here is the reason: when a library appears more # than once as an explicit dependence of a library, or # is implicitly linked in more than once by the # compiler, it is considered special, and multiple # occurrences thereof are not removed. Compare this # with having the same library being listed as a # dependency of multiple other libraries: in this case, # we know (pedantically, we assume) the library does not # need to be listed more than once, so we keep only the # last copy. This is not always right, but it is rare # enough that we require users that really mean to play # such unportable linking tricks to link the library # using -Wl,-lname, so that libtool does not consider it # for duplicate removal. case " $specialdeplibs " in *" $deplib "*) new_libs="$deplib $new_libs" ;; *) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$deplib $new_libs" ;; esac ;; esac ;; esac done tmp_libs= for deplib in $new_libs; do case $deplib in -L*) case " $tmp_libs " in *" $deplib "*) ;; *) func_append tmp_libs " $deplib" ;; esac ;; *) func_append tmp_libs " $deplib" ;; esac done eval $var=\"$tmp_libs\" done # for var fi # Add Sun CC postdeps if required: test CXX = "$tagname" && { case $host_os in linux*) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 func_suncc_cstd_abi if test no != "$suncc_use_cstd_abi"; then func_append postdeps ' -library=Cstd -library=Crun' fi ;; esac ;; solaris*) func_cc_basename "$CC" case $func_cc_basename_result in CC* | sunCC*) func_suncc_cstd_abi if test no != "$suncc_use_cstd_abi"; then func_append postdeps ' -library=Cstd -library=Crun' fi ;; esac ;; esac } # Last step: remove runtime libs from dependency_libs # (they stay in deplibs) tmp_libs= for i in $dependency_libs; do case " $predeps $postdeps $compiler_lib_search_path " in *" $i "*) i= ;; esac if test -n "$i"; then func_append tmp_libs " $i" fi done dependency_libs=$tmp_libs done # for pass if test prog = "$linkmode"; then dlfiles=$newdlfiles fi if test prog = "$linkmode" || test lib = "$linkmode"; then dlprefiles=$newdlprefiles fi case $linkmode in oldlib) if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then func_warning "'-dlopen' is ignored for archives" fi case " $deplibs" in *\ -l* | *\ -L*) func_warning "'-l' and '-L' are ignored for archives" ;; esac test -n "$rpath" && \ func_warning "'-rpath' is ignored for archives" test -n "$xrpath" && \ func_warning "'-R' is ignored for archives" test -n "$vinfo" && \ func_warning "'-version-info/-version-number' is ignored for archives" test -n "$release" && \ func_warning "'-release' is ignored for archives" test -n "$export_symbols$export_symbols_regex" && \ func_warning "'-export-symbols' is ignored for archives" # Now set the variables for building old libraries. build_libtool_libs=no oldlibs=$output func_append objs "$old_deplibs" ;; lib) # Make sure we only generate libraries of the form 'libNAME.la'. case $outputname in lib*) func_stripname 'lib' '.la' "$outputname" name=$func_stripname_result eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" ;; *) test no = "$module" \ && func_fatal_help "libtool library '$output' must begin with 'lib'" if test no != "$need_lib_prefix"; then # Add the "lib" prefix for modules if required func_stripname '' '.la' "$outputname" name=$func_stripname_result eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" else func_stripname '' '.la' "$outputname" libname=$func_stripname_result fi ;; esac if test -n "$objs"; then if test pass_all != "$deplibs_check_method"; then func_fatal_error "cannot build libtool library '$output' from non-libtool objects on this host:$objs" else echo $ECHO "*** Warning: Linking the shared library $output against the non-libtool" $ECHO "*** objects $objs is not portable!" func_append libobjs " $objs" fi fi test no = "$dlself" \ || func_warning "'-dlopen self' is ignored for libtool libraries" set dummy $rpath shift test 1 -lt "$#" \ && func_warning "ignoring multiple '-rpath's for a libtool library" install_libdir=$1 oldlibs= if test -z "$rpath"; then if test yes = "$build_libtool_libs"; then # Building a libtool convenience library. # Some compilers have problems with a '.al' extension so # convenience libraries should have the same extension an # archive normally would. oldlibs="$output_objdir/$libname.$libext $oldlibs" build_libtool_libs=convenience build_old_libs=yes fi test -n "$vinfo" && \ func_warning "'-version-info/-version-number' is ignored for convenience libraries" test -n "$release" && \ func_warning "'-release' is ignored for convenience libraries" else # Parse the version information argument. save_ifs=$IFS; IFS=: set dummy $vinfo 0 0 0 shift IFS=$save_ifs test -n "$7" && \ func_fatal_help "too many parameters to '-version-info'" # convert absolute version numbers to libtool ages # this retains compatibility with .la files and attempts # to make the code below a bit more comprehensible case $vinfo_number in yes) number_major=$1 number_minor=$2 number_revision=$3 # # There are really only two kinds -- those that # use the current revision as the major version # and those that subtract age and use age as # a minor version. But, then there is irix # that has an extra 1 added just for fun # case $version_type in # correct linux to gnu/linux during the next big refactor darwin|freebsd-elf|linux|midnightbsd-elf|osf|windows|none) func_arith $number_major + $number_minor current=$func_arith_result age=$number_minor revision=$number_revision ;; freebsd-aout|qnx|sunos) current=$number_major revision=$number_minor age=0 ;; irix|nonstopux) func_arith $number_major + $number_minor current=$func_arith_result age=$number_minor revision=$number_minor lt_irix_increment=no ;; esac ;; no) current=$1 revision=$2 age=$3 ;; esac # Check that each of the things are valid numbers. case $current in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "CURRENT '$current' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac case $revision in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "REVISION '$revision' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac case $age in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "AGE '$age' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac if test "$age" -gt "$current"; then func_error "AGE '$age' is greater than the current interface number '$current'" func_fatal_error "'$vinfo' is not valid version information" fi # Calculate the version variables. major= versuffix= verstring= case $version_type in none) ;; darwin) # Like Linux, but with the current version available in # verstring for coding it into the library header func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision # Darwin ld doesn't like 0 for these options... func_arith $current + 1 minor_current=$func_arith_result xlcverstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" # On Darwin other compilers case $CC in nagfor*) verstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" ;; *) verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" ;; esac ;; freebsd-aout) major=.$current versuffix=.$current.$revision ;; freebsd-elf | midnightbsd-elf) func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision ;; irix | nonstopux) if test no = "$lt_irix_increment"; then func_arith $current - $age else func_arith $current - $age + 1 fi major=$func_arith_result case $version_type in nonstopux) verstring_prefix=nonstopux ;; *) verstring_prefix=sgi ;; esac verstring=$verstring_prefix$major.$revision # Add in all the interfaces that we are compatible with. loop=$revision while test 0 -ne "$loop"; do func_arith $revision - $loop iface=$func_arith_result func_arith $loop - 1 loop=$func_arith_result verstring=$verstring_prefix$major.$iface:$verstring done # Before this point, $major must not contain '.'. major=.$major versuffix=$major.$revision ;; linux) # correct to gnu/linux during the next big refactor func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision ;; osf) func_arith $current - $age major=.$func_arith_result versuffix=.$current.$age.$revision verstring=$current.$age.$revision # Add in all the interfaces that we are compatible with. loop=$age while test 0 -ne "$loop"; do func_arith $current - $loop iface=$func_arith_result func_arith $loop - 1 loop=$func_arith_result verstring=$verstring:$iface.0 done # Make executables depend on our current version. func_append verstring ":$current.0" ;; qnx) major=.$current versuffix=.$current ;; sco) major=.$current versuffix=.$current ;; sunos) major=.$current versuffix=.$current.$revision ;; windows) # Use '-' rather than '.', since we only want one # extension on DOS 8.3 file systems. func_arith $current - $age major=$func_arith_result versuffix=-$major ;; *) func_fatal_configuration "unknown library version type '$version_type'" ;; esac # Clear the version info if we defaulted, and they specified a release. if test -z "$vinfo" && test -n "$release"; then major= case $version_type in darwin) # we can't check for "0.0" in archive_cmds due to quoting # problems, so we reset it completely verstring= ;; *) verstring=0.0 ;; esac if test no = "$need_version"; then versuffix= else versuffix=.0.0 fi fi # Remove version info from name if versioning should be avoided if test yes,no = "$avoid_version,$need_version"; then major= versuffix= verstring= fi # Check to see if the archive will have undefined symbols. if test yes = "$allow_undefined"; then if test unsupported = "$allow_undefined_flag"; then if test yes = "$build_old_libs"; then func_warning "undefined symbols not allowed in $host shared libraries; building static only" build_libtool_libs=no else func_fatal_error "can't build $host shared library unless -no-undefined is specified" fi fi else # Don't allow undefined symbols. allow_undefined_flag=$no_undefined_flag fi fi func_generate_dlsyms "$libname" "$libname" : func_append libobjs " $symfileobj" test " " = "$libobjs" && libobjs= if test relink != "$opt_mode"; then # Remove our outputs, but don't remove object files since they # may have been created when compiling PIC objects. removelist= tempremovelist=`$ECHO "$output_objdir/*"` for p in $tempremovelist; do case $p in *.$objext | *.gcno) ;; $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/$libname$release.*) if test -n "$precious_files_regex"; then if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 then continue fi fi func_append removelist " $p" ;; *) ;; esac done test -n "$removelist" && \ func_show_eval "${RM}r \$removelist" fi # Now set the variables for building old libraries. if test yes = "$build_old_libs" && test convenience != "$build_libtool_libs"; then func_append oldlibs " $output_objdir/$libname.$libext" # Transform .lo files to .o files. oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; $lo2o" | $NL2SP` fi # Eliminate all temporary directories. #for path in $notinst_path; do # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` #done if test -n "$xrpath"; then # If the user specified any rpath flags, then add them. temp_xrpath= for libdir in $xrpath; do func_replace_sysroot "$libdir" func_append temp_xrpath " -R$func_replace_sysroot_result" case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac done if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then dependency_libs="$temp_xrpath $dependency_libs" fi fi # Make sure dlfiles contains only unique files that won't be dlpreopened old_dlfiles=$dlfiles dlfiles= for lib in $old_dlfiles; do case " $dlprefiles $dlfiles " in *" $lib "*) ;; *) func_append dlfiles " $lib" ;; esac done # Make sure dlprefiles contains only unique files old_dlprefiles=$dlprefiles dlprefiles= for lib in $old_dlprefiles; do case "$dlprefiles " in *" $lib "*) ;; *) func_append dlprefiles " $lib" ;; esac done if test yes = "$build_libtool_libs"; then if test -n "$rpath"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) # these systems don't actually have a c library (as such)! ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C library is in the System framework func_append deplibs " System.ltframework" ;; *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-midnightbsd*) # Do not include libc due to us having libc/libc_r. ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work ;; *) # Add libc to deplibs on all other systems if necessary. if test yes = "$build_libtool_need_lc"; then func_append deplibs " -lc" fi ;; esac fi # Transform deplibs into only deplibs that can be linked in shared. name_save=$name libname_save=$libname release_save=$release versuffix_save=$versuffix major_save=$major # I'm not sure if I'm treating the release correctly. I think # release should show up in the -l (ie -lgmp5) so we don't want to # add it in twice. Is that correct? release= versuffix= major= newdeplibs= droppeddeps=no case $deplibs_check_method in pass_all) # Don't check for shared/static. Everything works. # This might be a little naive. We might want to check # whether the library exists or not. But this is on # osf3 & osf4 and I'm not really sure... Just # implementing what was already the behavior. newdeplibs=$deplibs ;; test_compile) # This code stresses the "libraries are programs" paradigm to its # limits. Maybe even breaks it. We compile a program, linking it # against the deplibs as a proxy for the library. Then we can check # whether they linked in statically or dynamically with ldd. $opt_dry_run || $RM conftest.c cat > conftest.c </dev/null` $nocaseglob else potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` fi for potent_lib in $potential_libs; do # Follow soft links. if ls -lLd "$potent_lib" 2>/dev/null | $GREP " -> " >/dev/null; then continue fi # The statement above tries to avoid entering an # endless loop below, in case of cyclic links. # We might still enter an endless loop, since a link # loop can be closed while we follow links, # but so what? potlib=$potent_lib while test -h "$potlib" 2>/dev/null; do potliblink=`ls -ld $potlib | $SED 's/.* -> //'` case $potliblink in [\\/]* | [A-Za-z]:[\\/]*) potlib=$potliblink;; *) potlib=`$ECHO "$potlib" | $SED 's|[^/]*$||'`"$potliblink";; esac done if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | $SED -e 10q | $EGREP "$file_magic_regex" > /dev/null; then func_append newdeplibs " $a_deplib" a_deplib= break 2 fi done done fi if test -n "$a_deplib"; then droppeddeps=yes echo $ECHO "*** Warning: linker path does not have real file for library $a_deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib"; then $ECHO "*** with $libname but no candidates were found. (...for file magic test)" else $ECHO "*** with $libname and none of the candidates passed a file format test" $ECHO "*** using a file magic. Last file checked: $potlib" fi fi ;; *) # Add a -L argument. func_append newdeplibs " $a_deplib" ;; esac done # Gone through all deplibs. ;; match_pattern*) set dummy $deplibs_check_method; shift match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` for a_deplib in $deplibs; do case $a_deplib in -l*) func_stripname -l '' "$a_deplib" name=$func_stripname_result if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $a_deplib "*) func_append newdeplibs " $a_deplib" a_deplib= ;; esac fi if test -n "$a_deplib"; then libname=`eval "\\$ECHO \"$libname_spec\""` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do potential_libs=`ls $i/$libname[.-]* 2>/dev/null` for potent_lib in $potential_libs; do potlib=$potent_lib # see symlink-check above in file_magic test if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ $EGREP "$match_pattern_regex" > /dev/null; then func_append newdeplibs " $a_deplib" a_deplib= break 2 fi done done fi if test -n "$a_deplib"; then droppeddeps=yes echo $ECHO "*** Warning: linker path does not have real file for library $a_deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib"; then $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" else $ECHO "*** with $libname and none of the candidates passed a file format test" $ECHO "*** using a regex pattern. Last file checked: $potlib" fi fi ;; *) # Add a -L argument. func_append newdeplibs " $a_deplib" ;; esac done # Gone through all deplibs. ;; none | unknown | *) newdeplibs= tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` if test yes = "$allow_libtool_libs_with_static_runtimes"; then for i in $predeps $postdeps; do # can't use Xsed below, because $i might contain '/' tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s|$i||"` done fi case $tmp_deplibs in *[!\ \ ]*) echo if test none = "$deplibs_check_method"; then echo "*** Warning: inter-library dependencies are not supported in this platform." else echo "*** Warning: inter-library dependencies are not known to be supported." fi echo "*** All declared inter-library dependencies are being dropped." droppeddeps=yes ;; esac ;; esac versuffix=$versuffix_save major=$major_save release=$release_save libname=$libname_save name=$name_save case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library with the System framework newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` ;; esac if test yes = "$droppeddeps"; then if test yes = "$module"; then echo echo "*** Warning: libtool could not satisfy all declared inter-library" $ECHO "*** dependencies of module $libname. Therefore, libtool will create" echo "*** a static module, that should work as long as the dlopening" echo "*** application is linked with the -dlopen flag." if test -z "$global_symbol_pipe"; then echo echo "*** However, this would only work if libtool was able to extract symbol" echo "*** lists from a program, using 'nm' or equivalent, but libtool could" echo "*** not find such a program. So, this module is probably useless." echo "*** 'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then oldlibs=$output_objdir/$libname.$libext build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi else echo "*** The inter-library dependencies that have been dropped here will be" echo "*** automatically added whenever a program is linked with this library" echo "*** or is declared to -dlopen it." if test no = "$allow_undefined"; then echo echo "*** Since this library must not contain undefined symbols," echo "*** because either the platform does not support them or" echo "*** it was explicitly requested with -no-undefined," echo "*** libtool will only create a static version of it." if test no = "$build_old_libs"; then oldlibs=$output_objdir/$libname.$libext build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi fi fi # Done checking deplibs! deplibs=$newdeplibs fi # Time to change all our "foo.ltframework" stuff back to "-framework foo" case $host in *-*-darwin*) newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $deplibs " in *" -L$path/$objdir "*) func_append new_libs " -L$path/$objdir" ;; esac ;; esac done for deplib in $deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) func_append new_libs " $deplib" ;; esac ;; *) func_append new_libs " $deplib" ;; esac done deplibs=$new_libs # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # Test again, we may have decided not to build it any more if test yes = "$build_libtool_libs"; then # Remove $wl instances when linking with ld. # FIXME: should test the right _cmds variable. case $archive_cmds in *\$LD\ *) wl= ;; esac if test yes = "$hardcode_into_libs"; then # Hardcode the library paths hardcode_libdirs= dep_rpath= rpath=$finalize_rpath test relink = "$opt_mode" || rpath=$compile_rpath$rpath for libdir in $rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then func_replace_sysroot "$libdir" libdir=$func_replace_sysroot_result if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append dep_rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) func_append perm_rpath " $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" fi if test -n "$runpath_var" && test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do func_append rpath "$dir:" done eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" fi test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" fi shlibpath=$finalize_shlibpath test relink = "$opt_mode" || shlibpath=$compile_shlibpath$shlibpath if test -n "$shlibpath"; then eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" fi # Get the real and link names of the library. eval shared_ext=\"$shrext_cmds\" eval library_names=\"$library_names_spec\" set dummy $library_names shift realname=$1 shift if test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname=$realname fi if test -z "$dlname"; then dlname=$soname fi lib=$output_objdir/$realname linknames= for link do func_append linknames " $link" done # Use standard objects if they are pic test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` test "X$libobjs" = "X " && libobjs= delfiles= if test -n "$export_symbols" && test -n "$include_expsyms"; then $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" export_symbols=$output_objdir/$libname.uexp func_append delfiles " $export_symbols" fi orig_export_symbols= case $host_os in cygwin* | mingw* | cegcc*) if test -n "$export_symbols" && test -z "$export_symbols_regex"; then # exporting using user supplied symfile func_dll_def_p "$export_symbols" || { # and it's NOT already a .def file. Must figure out # which of the given symbols are data symbols and tag # them as such. So, trigger use of export_symbols_cmds. # export_symbols gets reassigned inside the "prepare # the list of exported symbols" if statement, so the # include_expsyms logic still works. orig_export_symbols=$export_symbols export_symbols= always_export_symbols=yes } fi ;; esac # Prepare the list of exported symbols if test -z "$export_symbols"; then if test yes = "$always_export_symbols" || test -n "$export_symbols_regex"; then func_verbose "generating symbol list for '$libname.la'" export_symbols=$output_objdir/$libname.exp $opt_dry_run || $RM $export_symbols cmds=$export_symbols_cmds save_ifs=$IFS; IFS='~' for cmd1 in $cmds; do IFS=$save_ifs # Take the normal branch if the nm_file_list_spec branch # doesn't work or if tool conversion is not needed. case $nm_file_list_spec~$to_tool_file_cmd in *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) try_normal_branch=yes eval cmd=\"$cmd1\" func_len " $cmd" len=$func_len_result ;; *) try_normal_branch=no ;; esac if test yes = "$try_normal_branch" \ && { test "$len" -lt "$max_cmd_len" \ || test "$max_cmd_len" -le -1; } then func_show_eval "$cmd" 'exit $?' skipped_export=false elif test -n "$nm_file_list_spec"; then func_basename "$output" output_la=$func_basename_result save_libobjs=$libobjs save_output=$output output=$output_objdir/$output_la.nm func_to_tool_file "$output" libobjs=$nm_file_list_spec$func_to_tool_file_result func_append delfiles " $output" func_verbose "creating $NM input file list: $output" for obj in $save_libobjs; do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" done > "$output" eval cmd=\"$cmd1\" func_show_eval "$cmd" 'exit $?' output=$save_output libobjs=$save_libobjs skipped_export=false else # The command line is too long to execute in one step. func_verbose "using reloadable object file for export list..." skipped_export=: # Break out early, otherwise skipped_export may be # set to false by a later but shorter cmd. break fi done IFS=$save_ifs if test -n "$export_symbols_regex" && test : != "$skipped_export"; then func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' func_show_eval '$MV "${export_symbols}T" "$export_symbols"' fi fi fi if test -n "$export_symbols" && test -n "$include_expsyms"; then tmp_export_symbols=$export_symbols test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test : != "$skipped_export" && test -n "$orig_export_symbols"; then # The given exports_symbols file has to be filtered, so filter it. func_verbose "filter symbol list for '$libname.la' to tag DATA exports" # FIXME: $output_objdir/$libname.filter potentially contains lots of # 's' commands, which not all seds can handle. GNU sed should be fine # though. Also, the filter scales superlinearly with the number of # global variables. join(1) would be nice here, but unfortunately # isn't a blessed tool. $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter func_append delfiles " $export_symbols $output_objdir/$libname.filter" export_symbols=$output_objdir/$libname.def $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols fi tmp_deplibs= for test_deplib in $deplibs; do case " $convenience " in *" $test_deplib "*) ;; *) func_append tmp_deplibs " $test_deplib" ;; esac done deplibs=$tmp_deplibs if test -n "$convenience"; then if test -n "$whole_archive_flag_spec" && test yes = "$compiler_needs_object" && test -z "$libobjs"; then # extract the archives, so we have objects to list. # TODO: could optimize this to just extract one archive. whole_archive_flag_spec= fi if test -n "$whole_archive_flag_spec"; then save_libobjs=$libobjs eval libobjs=\"\$libobjs $whole_archive_flag_spec\" test "X$libobjs" = "X " && libobjs= else gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $convenience func_append libobjs " $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= fi fi if test yes = "$thread_safe" && test -n "$thread_safe_flag_spec"; then eval flag=\"$thread_safe_flag_spec\" func_append linker_flags " $flag" fi # Make a backup of the uninstalled library when relinking if test relink = "$opt_mode"; then $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? fi # Do each of the archive commands. if test yes = "$module" && test -n "$module_cmds"; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then eval test_cmds=\"$module_expsym_cmds\" cmds=$module_expsym_cmds else eval test_cmds=\"$module_cmds\" cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then eval test_cmds=\"$archive_expsym_cmds\" cmds=$archive_expsym_cmds else eval test_cmds=\"$archive_cmds\" cmds=$archive_cmds fi fi if test : != "$skipped_export" && func_len " $test_cmds" && len=$func_len_result && test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then : else # The command line is too long to link in one step, link piecewise # or, if using GNU ld and skipped_export is not :, use a linker # script. # Save the value of $output and $libobjs because we want to # use them later. If we have whole_archive_flag_spec, we # want to use save_libobjs as it was before # whole_archive_flag_spec was expanded, because we can't # assume the linker understands whole_archive_flag_spec. # This may have to be revisited, in case too many # convenience libraries get linked in and end up exceeding # the spec. if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then save_libobjs=$libobjs fi save_output=$output func_basename "$output" output_la=$func_basename_result # Clear the reloadable object creation command queue and # initialize k to one. test_cmds= concat_cmds= objlist= last_robj= k=1 if test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then output=$output_objdir/$output_la.lnkscript func_verbose "creating GNU ld script: $output" echo 'INPUT (' > $output for obj in $save_libobjs do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" >> $output done echo ')' >> $output func_append delfiles " $output" func_to_tool_file "$output" output=$func_to_tool_file_result elif test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then output=$output_objdir/$output_la.lnk func_verbose "creating linker input file list: $output" : > $output set x $save_libobjs shift firstobj= if test yes = "$compiler_needs_object"; then firstobj="$1 " shift fi for obj do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" >> $output done func_append delfiles " $output" func_to_tool_file "$output" output=$firstobj\"$file_list_spec$func_to_tool_file_result\" else if test -n "$save_libobjs"; then func_verbose "creating reloadable object files..." output=$output_objdir/$output_la-$k.$objext eval test_cmds=\"$reload_cmds\" func_len " $test_cmds" len0=$func_len_result len=$len0 # Loop over the list of objects to be linked. for obj in $save_libobjs do func_len " $obj" func_arith $len + $func_len_result len=$func_arith_result if test -z "$objlist" || test "$len" -lt "$max_cmd_len"; then func_append objlist " $obj" else # The command $test_cmds is almost too long, add a # command to the queue. if test 1 -eq "$k"; then # The first file doesn't have a previous command to add. reload_objs=$objlist eval concat_cmds=\"$reload_cmds\" else # All subsequent reloadable object files will link in # the last one created. reload_objs="$objlist $last_robj" eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" fi last_robj=$output_objdir/$output_la-$k.$objext func_arith $k + 1 k=$func_arith_result output=$output_objdir/$output_la-$k.$objext objlist=" $obj" func_len " $last_robj" func_arith $len0 + $func_len_result len=$func_arith_result fi done # Handle the remaining objects by creating one last # reloadable object file. All subsequent reloadable object # files will link in the last one created. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ reload_objs="$objlist $last_robj" eval concat_cmds=\"\$concat_cmds$reload_cmds\" if test -n "$last_robj"; then eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" fi func_append delfiles " $output" else output= fi ${skipped_export-false} && { func_verbose "generating symbol list for '$libname.la'" export_symbols=$output_objdir/$libname.exp $opt_dry_run || $RM $export_symbols libobjs=$output # Append the command to create the export file. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" if test -n "$last_robj"; then eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" fi } test -n "$save_libobjs" && func_verbose "creating a temporary reloadable object file: $output" # Loop through the commands generated above and execute them. save_ifs=$IFS; IFS='~' for cmd in $concat_cmds; do IFS=$save_ifs $opt_quiet || { func_quote_arg expand,pretty "$cmd" eval "func_echo $func_quote_arg_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test relink = "$opt_mode"; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) fi exit $lt_exit } done IFS=$save_ifs if test -n "$export_symbols_regex" && ${skipped_export-false}; then func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' func_show_eval '$MV "${export_symbols}T" "$export_symbols"' fi fi ${skipped_export-false} && { if test -n "$export_symbols" && test -n "$include_expsyms"; then tmp_export_symbols=$export_symbols test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test -n "$orig_export_symbols"; then # The given exports_symbols file has to be filtered, so filter it. func_verbose "filter symbol list for '$libname.la' to tag DATA exports" # FIXME: $output_objdir/$libname.filter potentially contains lots of # 's' commands, which not all seds can handle. GNU sed should be fine # though. Also, the filter scales superlinearly with the number of # global variables. join(1) would be nice here, but unfortunately # isn't a blessed tool. $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter func_append delfiles " $export_symbols $output_objdir/$libname.filter" export_symbols=$output_objdir/$libname.def $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols fi } libobjs=$output # Restore the value of output. output=$save_output if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then eval libobjs=\"\$libobjs $whole_archive_flag_spec\" test "X$libobjs" = "X " && libobjs= fi # Expand the library linking commands again to reset the # value of $libobjs for piecewise linking. # Do each of the archive commands. if test yes = "$module" && test -n "$module_cmds"; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then cmds=$module_expsym_cmds else cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then cmds=$archive_expsym_cmds else cmds=$archive_cmds fi fi fi if test -n "$delfiles"; then # Append the command to remove temporary files to $cmds. eval cmds=\"\$cmds~\$RM $delfiles\" fi # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $dlprefiles func_append libobjs " $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= fi save_ifs=$IFS; IFS='~' for cmd in $cmds; do IFS=$sp$nl eval cmd=\"$cmd\" IFS=$save_ifs $opt_quiet || { func_quote_arg expand,pretty "$cmd" eval "func_echo $func_quote_arg_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test relink = "$opt_mode"; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) fi exit $lt_exit } done IFS=$save_ifs # Restore the uninstalled library and exit if test relink = "$opt_mode"; then $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? if test -n "$convenience"; then if test -z "$whole_archive_flag_spec"; then func_show_eval '${RM}r "$gentop"' fi fi exit $EXIT_SUCCESS fi # Create links to the real library. for linkname in $linknames; do if test "$realname" != "$linkname"; then func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' fi done # If -module or -export-dynamic was specified, set the dlname. if test yes = "$module" || test yes = "$export_dynamic"; then # On all known operating systems, these are identical. dlname=$soname fi fi ;; obj) if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then func_warning "'-dlopen' is ignored for objects" fi case " $deplibs" in *\ -l* | *\ -L*) func_warning "'-l' and '-L' are ignored for objects" ;; esac test -n "$rpath" && \ func_warning "'-rpath' is ignored for objects" test -n "$xrpath" && \ func_warning "'-R' is ignored for objects" test -n "$vinfo" && \ func_warning "'-version-info' is ignored for objects" test -n "$release" && \ func_warning "'-release' is ignored for objects" case $output in *.lo) test -n "$objs$old_deplibs" && \ func_fatal_error "cannot build library object '$output' from non-libtool objects" libobj=$output func_lo2o "$libobj" obj=$func_lo2o_result ;; *) libobj= obj=$output ;; esac # Delete the old objects. $opt_dry_run || $RM $obj $libobj # Objects from convenience libraries. This assumes # single-version convenience libraries. Whenever we create # different ones for PIC/non-PIC, this we'll have to duplicate # the extraction. reload_conv_objs= gentop= # if reload_cmds runs $LD directly, get rid of -Wl from # whole_archive_flag_spec and hope we can get by with turning comma # into space. case $reload_cmds in *\$LD[\ \$]*) wl= ;; esac if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" test -n "$wl" || tmp_whole_archive_flags=`$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` reload_conv_objs=$reload_objs\ $tmp_whole_archive_flags else gentop=$output_objdir/${obj}x func_append generated " $gentop" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi # If we're not building shared, we need to use non_pic_objs test yes = "$build_libtool_libs" || libobjs=$non_pic_objects # Create the old-style object. reload_objs=$objs$old_deplibs' '`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; /\.lib$/d; $lo2o" | $NL2SP`' '$reload_conv_objs output=$obj func_execute_cmds "$reload_cmds" 'exit $?' # Exit if we aren't doing a library object file. if test -z "$libobj"; then if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi exit $EXIT_SUCCESS fi test yes = "$build_libtool_libs" || { if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi # Create an invalid libtool object if no PIC, so that we don't # accidentally link it into a program. # $show "echo timestamp > $libobj" # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? exit $EXIT_SUCCESS } if test -n "$pic_flag" || test default != "$pic_mode"; then # Only do commands if we really have different PIC objects. reload_objs="$libobjs $reload_conv_objs" output=$libobj func_execute_cmds "$reload_cmds" 'exit $?' fi if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi exit $EXIT_SUCCESS ;; prog) case $host in *cygwin*) func_stripname '' '.exe' "$output" output=$func_stripname_result.exe;; esac test -n "$vinfo" && \ func_warning "'-version-info' is ignored for programs" test -n "$release" && \ func_warning "'-release' is ignored for programs" $preload \ && test unknown,unknown,unknown = "$dlopen_support,$dlopen_self,$dlopen_self_static" \ && func_warning "'LT_INIT([dlopen])' not used. Assuming no dlopen support." case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` ;; esac case $host in *-*-darwin*) # Don't allow lazy linking, it breaks C++ global constructors # But is supposedly fixed on 10.4 or later (yay!). if test CXX = "$tagname"; then case ${MACOSX_DEPLOYMENT_TARGET-10.0} in 10.[0123]) func_append compile_command " $wl-bind_at_load" func_append finalize_command " $wl-bind_at_load" ;; esac fi # Time to change all our "foo.ltframework" stuff back to "-framework foo" compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $compile_deplibs " in *" -L$path/$objdir "*) func_append new_libs " -L$path/$objdir" ;; esac ;; esac done for deplib in $compile_deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) func_append new_libs " $deplib" ;; esac ;; *) func_append new_libs " $deplib" ;; esac done compile_deplibs=$new_libs func_append compile_command " $compile_deplibs" func_append finalize_command " $finalize_deplibs" if test -n "$rpath$xrpath"; then # If the user specified any rpath flags, then add them. for libdir in $rpath $xrpath; do # This is the magic to use -rpath. case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac done fi # Now hardcode the library paths rpath= hardcode_libdirs= for libdir in $compile_rpath $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) func_append perm_rpath " $libdir" ;; esac fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$libdir" | $SED -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; ::) dllsearchpath=$libdir;; *) func_append dllsearchpath ":$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; ::) dllsearchpath=$testbindir;; *) func_append dllsearchpath ":$testbindir";; esac ;; esac done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval rpath=\" $hardcode_libdir_flag_spec\" fi compile_rpath=$rpath rpath= hardcode_libdirs= for libdir in $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$finalize_perm_rpath " in *" $libdir "*) ;; *) func_append finalize_perm_rpath " $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval rpath=\" $hardcode_libdir_flag_spec\" fi finalize_rpath=$rpath if test -n "$libobjs" && test yes = "$build_old_libs"; then # Transform all the library objects into standard objects. compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` fi func_generate_dlsyms "$outputname" "@PROGRAM@" false # template prelinking step if test -n "$prelink_cmds"; then func_execute_cmds "$prelink_cmds" 'exit $?' fi wrappers_required=: case $host in *cegcc* | *mingw32ce*) # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. wrappers_required=false ;; *cygwin* | *mingw* ) test yes = "$build_libtool_libs" || wrappers_required=false ;; *) if test no = "$need_relink" || test yes != "$build_libtool_libs"; then wrappers_required=false fi ;; esac $wrappers_required || { # Replace the output file specification. compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` link_command=$compile_command$compile_rpath # We have no uninstalled library dependencies, so finalize right now. exit_status=0 func_show_eval "$link_command" 'exit_status=$?' if test -n "$postlink_cmds"; then func_to_tool_file "$output" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi # Delete the generated files. if test -f "$output_objdir/${outputname}S.$objext"; then func_show_eval '$RM "$output_objdir/${outputname}S.$objext"' fi exit $exit_status } if test -n "$compile_shlibpath$finalize_shlibpath"; then compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" fi if test -n "$finalize_shlibpath"; then finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" fi compile_var= finalize_var= if test -n "$runpath_var"; then if test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do func_append rpath "$dir:" done compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi if test -n "$finalize_perm_rpath"; then # We should set the runpath_var. rpath= for dir in $finalize_perm_rpath; do func_append rpath "$dir:" done finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi fi if test yes = "$no_install"; then # We don't need to create a wrapper script. link_command=$compile_var$compile_command$compile_rpath # Replace the output file specification. link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` # Delete the old output file. $opt_dry_run || $RM $output # Link the executable and exit func_show_eval "$link_command" 'exit $?' if test -n "$postlink_cmds"; then func_to_tool_file "$output" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi exit $EXIT_SUCCESS fi case $hardcode_action,$fast_install in relink,*) # Fast installation is not supported link_command=$compile_var$compile_command$compile_rpath relink_command=$finalize_var$finalize_command$finalize_rpath func_warning "this platform does not like uninstalled shared libraries" func_warning "'$output' will be relinked during installation" ;; *,yes) link_command=$finalize_var$compile_command$finalize_rpath relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` ;; *,no) link_command=$compile_var$compile_command$compile_rpath relink_command=$finalize_var$finalize_command$finalize_rpath ;; *,needless) link_command=$finalize_var$compile_command$finalize_rpath relink_command= ;; esac # Replace the output file specification. link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname func_show_eval "$link_command" 'exit $?' if test -n "$postlink_cmds"; then func_to_tool_file "$output_objdir/$outputname" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi # Now create the wrapper script. func_verbose "creating $output" # Quote the relink command for shipping. if test -n "$relink_command"; then # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else func_quote_arg pretty "$var_value" relink_command="$var=$func_quote_arg_result; export $var; $relink_command" fi done func_quote eval cd "`pwd`" func_quote_arg pretty,unquoted "($func_quote_result; $relink_command)" relink_command=$func_quote_arg_unquoted_result fi # Only actually do things if not in dry run mode. $opt_dry_run || { # win32 will think the script is a binary if it has # a .exe suffix, so we strip it off here. case $output in *.exe) func_stripname '' '.exe' "$output" output=$func_stripname_result ;; esac # test for cygwin because mv fails w/o .exe extensions case $host in *cygwin*) exeext=.exe func_stripname '' '.exe' "$outputname" outputname=$func_stripname_result ;; *) exeext= ;; esac case $host in *cygwin* | *mingw* ) func_dirname_and_basename "$output" "" "." output_name=$func_basename_result output_path=$func_dirname_result cwrappersource=$output_path/$objdir/lt-$output_name.c cwrapper=$output_path/$output_name.exe $RM $cwrappersource $cwrapper trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 func_emit_cwrapperexe_src > $cwrappersource # The wrapper executable is built using the $host compiler, # because it contains $host paths and files. If cross- # compiling, it, like the target executable, must be # executed on the $host or under an emulation environment. $opt_dry_run || { $LTCC $LTCFLAGS -o $cwrapper $cwrappersource $STRIP $cwrapper } # Now, create the wrapper script for func_source use: func_ltwrapper_scriptname $cwrapper $RM $func_ltwrapper_scriptname_result trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 $opt_dry_run || { # note: this script will not be executed, so do not chmod. if test "x$build" = "x$host"; then $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result else func_emit_wrapper no > $func_ltwrapper_scriptname_result fi } ;; * ) $RM $output trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 func_emit_wrapper no > $output chmod +x $output ;; esac } exit $EXIT_SUCCESS ;; esac # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do case $build_libtool_libs in convenience) oldobjs="$libobjs_save $symfileobj" addlibs=$convenience build_libtool_libs=no ;; module) oldobjs=$libobjs_save addlibs=$old_convenience build_libtool_libs=no ;; *) oldobjs="$old_deplibs $non_pic_objects" $preload && test -f "$symfileobj" \ && func_append oldobjs " $symfileobj" addlibs=$old_convenience ;; esac if test -n "$addlibs"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $addlibs func_append oldobjs " $func_extract_archives_result" fi # Do each command in the archive commands. if test -n "$old_archive_from_new_cmds" && test yes = "$build_libtool_libs"; then cmds=$old_archive_from_new_cmds else # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $dlprefiles func_append oldobjs " $func_extract_archives_result" fi # POSIX demands no paths to be encoded in archives. We have # to avoid creating archives with duplicate basenames if we # might have to extract them afterwards, e.g., when creating a # static archive out of a convenience library, or when linking # the entirety of a libtool archive into another (currently # not supported by libtool). if (for obj in $oldobjs do func_basename "$obj" $ECHO "$func_basename_result" done | sort | sort -uc >/dev/null 2>&1); then : else echo "copying selected object files to avoid basename conflicts..." gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_mkdir_p "$gentop" save_oldobjs=$oldobjs oldobjs= counter=1 for obj in $save_oldobjs do func_basename "$obj" objbase=$func_basename_result case " $oldobjs " in " ") oldobjs=$obj ;; *[\ /]"$objbase "*) while :; do # Make sure we don't pick an alternate name that also # overlaps. newobj=lt$counter-$objbase func_arith $counter + 1 counter=$func_arith_result case " $oldobjs " in *[\ /]"$newobj "*) ;; *) if test ! -f "$gentop/$newobj"; then break; fi ;; esac done func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" func_append oldobjs " $gentop/$newobj" ;; *) func_append oldobjs " $obj" ;; esac done fi func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 tool_oldlib=$func_to_tool_file_result eval cmds=\"$old_archive_cmds\" func_len " $cmds" len=$func_len_result if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then cmds=$old_archive_cmds elif test -n "$archiver_list_spec"; then func_verbose "using command file archive linking..." for obj in $oldobjs do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" done > $output_objdir/$libname.libcmd func_to_tool_file "$output_objdir/$libname.libcmd" oldobjs=" $archiver_list_spec$func_to_tool_file_result" cmds=$old_archive_cmds else # the command line is too long to link in one step, link in parts func_verbose "using piecewise archive linking..." save_RANLIB=$RANLIB RANLIB=: objlist= concat_cmds= save_oldobjs=$oldobjs oldobjs= # Is there a better way of finding the last object in the list? for obj in $save_oldobjs do last_oldobj=$obj done eval test_cmds=\"$old_archive_cmds\" func_len " $test_cmds" len0=$func_len_result len=$len0 for obj in $save_oldobjs do func_len " $obj" func_arith $len + $func_len_result len=$func_arith_result func_append objlist " $obj" if test "$len" -lt "$max_cmd_len"; then : else # the above command should be used before it gets too long oldobjs=$objlist if test "$obj" = "$last_oldobj"; then RANLIB=$save_RANLIB fi test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\$concat_cmds$old_archive_cmds\" objlist= len=$len0 fi done RANLIB=$save_RANLIB oldobjs=$objlist if test -z "$oldobjs"; then eval cmds=\"\$concat_cmds\" else eval cmds=\"\$concat_cmds~\$old_archive_cmds\" fi fi fi func_execute_cmds "$cmds" 'exit $?' done test -n "$generated" && \ func_show_eval "${RM}r$generated" # Now create the libtool archive. case $output in *.la) old_library= test yes = "$build_old_libs" && old_library=$libname.$libext func_verbose "creating $output" # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else func_quote_arg pretty,unquoted "$var_value" relink_command="$var=$func_quote_arg_unquoted_result; export $var; $relink_command" fi done # Quote the link command for shipping. func_quote eval cd "`pwd`" relink_command="($func_quote_result; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" func_quote_arg pretty,unquoted "$relink_command" relink_command=$func_quote_arg_unquoted_result if test yes = "$hardcode_automatic"; then relink_command= fi # Only create the output if not a dry run. $opt_dry_run || { for installed in no yes; do if test yes = "$installed"; then if test -z "$install_libdir"; then break fi output=$output_objdir/${outputname}i # Replace all uninstalled libtool libraries with the installed ones newdependency_libs= for deplib in $dependency_libs; do case $deplib in *.la) func_basename "$deplib" name=$func_basename_result func_resolve_sysroot "$deplib" eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` test -z "$libdir" && \ func_fatal_error "'$deplib' is not a valid libtool archive" func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" ;; -L*) func_stripname -L '' "$deplib" func_replace_sysroot "$func_stripname_result" func_append newdependency_libs " -L$func_replace_sysroot_result" ;; -R*) func_stripname -R '' "$deplib" func_replace_sysroot "$func_stripname_result" func_append newdependency_libs " -R$func_replace_sysroot_result" ;; *) func_append newdependency_libs " $deplib" ;; esac done dependency_libs=$newdependency_libs newdlfiles= for lib in $dlfiles; do case $lib in *.la) func_basename "$lib" name=$func_basename_result eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` test -z "$libdir" && \ func_fatal_error "'$lib' is not a valid libtool archive" func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" ;; *) func_append newdlfiles " $lib" ;; esac done dlfiles=$newdlfiles newdlprefiles= for lib in $dlprefiles; do case $lib in *.la) # Only pass preopened files to the pseudo-archive (for # eventual linking with the app. that links it) if we # didn't already link the preopened objects directly into # the library: func_basename "$lib" name=$func_basename_result eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` test -z "$libdir" && \ func_fatal_error "'$lib' is not a valid libtool archive" func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" ;; esac done dlprefiles=$newdlprefiles else newdlfiles= for lib in $dlfiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; *) abs=`pwd`"/$lib" ;; esac func_append newdlfiles " $abs" done dlfiles=$newdlfiles newdlprefiles= for lib in $dlprefiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; *) abs=`pwd`"/$lib" ;; esac func_append newdlprefiles " $abs" done dlprefiles=$newdlprefiles fi $RM $output # place dlname in correct position for cygwin # In fact, it would be nice if we could use this code for all target # systems that can't hard-code library paths into their executables # and that have no shared library path variable independent of PATH, # but it turns out we can't easily determine that from inspecting # libtool variables, so we have to hard-code the OSs to which it # applies here; at the moment, that means platforms that use the PE # object format with DLL files. See the long comment at the top of # tests/bindir.at for full details. tdlname=$dlname case $host,$output,$installed,$module,$dlname in *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) # If a -bindir argument was supplied, place the dll there. if test -n "$bindir"; then func_relative_path "$install_libdir" "$bindir" tdlname=$func_relative_path_result/$dlname else # Otherwise fall back on heuristic. tdlname=../bin/$dlname fi ;; esac $ECHO > $output "\ # $outputname - a libtool library file # Generated by $PROGRAM (GNU $PACKAGE) $VERSION # # Please DO NOT delete this file! # It is necessary for linking the library. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Linker flags that cannot go in dependency_libs. inherited_linker_flags='$new_inherited_linker_flags' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Names of additional weak libraries provided by this library weak_library_names='$weak_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # Directory that this library needs to be installed in: libdir='$install_libdir'" if test no,yes = "$installed,$need_relink"; then $ECHO >> $output "\ relink_command=\"$relink_command\"" fi done } # Do a symbolic link so that the libtool archive can be found in # LD_LIBRARY_PATH before the program is installed. func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' ;; esac exit $EXIT_SUCCESS } if test link = "$opt_mode" || test relink = "$opt_mode"; then func_mode_link ${1+"$@"} fi # func_mode_uninstall arg... func_mode_uninstall () { $debug_cmd RM=$nonopt files= rmforce=false exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic=$magic for arg do case $arg in -f) func_append RM " $arg"; rmforce=: ;; -*) func_append RM " $arg" ;; *) func_append files " $arg" ;; esac done test -z "$RM" && \ func_fatal_help "you must specify an RM program" rmdirs= for file in $files; do func_dirname "$file" "" "." dir=$func_dirname_result if test . = "$dir"; then odir=$objdir else odir=$dir/$objdir fi func_basename "$file" name=$func_basename_result test uninstall = "$opt_mode" && odir=$dir # Remember odir for removal later, being careful to avoid duplicates if test clean = "$opt_mode"; then case " $rmdirs " in *" $odir "*) ;; *) func_append rmdirs " $odir" ;; esac fi # Don't error if the file doesn't exist and rm -f was used. if { test -L "$file"; } >/dev/null 2>&1 || { test -h "$file"; } >/dev/null 2>&1 || test -f "$file"; then : elif test -d "$file"; then exit_status=1 continue elif $rmforce; then continue fi rmfiles=$file case $name in *.la) # Possibly a libtool archive, so verify it. if func_lalib_p "$file"; then func_source $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do func_append rmfiles " $odir/$n" done test -n "$old_library" && func_append rmfiles " $odir/$old_library" case $opt_mode in clean) case " $library_names " in *" $dlname "*) ;; *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; esac test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. func_execute_cmds "$postuninstall_cmds" '$rmforce || exit_status=1' fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. func_execute_cmds "$old_postuninstall_cmds" '$rmforce || exit_status=1' fi # FIXME: should reinstall the best remaining shared library. ;; esac fi ;; *.lo) # Possibly a libtool object, so verify it. if func_lalib_p "$file"; then # Read the .lo file func_source $dir/$name # Add PIC object to the list of files to remove. if test -n "$pic_object" && test none != "$pic_object"; then func_append rmfiles " $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. if test -n "$non_pic_object" && test none != "$non_pic_object"; then func_append rmfiles " $dir/$non_pic_object" fi fi ;; *) if test clean = "$opt_mode"; then noexename=$name case $file in *.exe) func_stripname '' '.exe' "$file" file=$func_stripname_result func_stripname '' '.exe' "$name" noexename=$func_stripname_result # $file with .exe has already been added to rmfiles, # add $file without .exe func_append rmfiles " $file" ;; esac # Do a test to see if this is a libtool program. if func_ltwrapper_p "$file"; then if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" relink_command= func_source $func_ltwrapper_scriptname_result func_append rmfiles " $func_ltwrapper_scriptname_result" else relink_command= func_source $dir/$noexename fi # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles func_append rmfiles " $odir/$name $odir/${name}S.$objext" if test yes = "$fast_install" && test -n "$relink_command"; then func_append rmfiles " $odir/lt-$name" fi if test "X$noexename" != "X$name"; then func_append rmfiles " $odir/lt-$noexename.c" fi fi fi ;; esac func_show_eval "$RM $rmfiles" 'exit_status=1' done # Try to remove the $objdir's in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then func_show_eval "rmdir $dir >/dev/null 2>&1" fi done exit $exit_status } if test uninstall = "$opt_mode" || test clean = "$opt_mode"; then func_mode_uninstall ${1+"$@"} fi test -z "$opt_mode" && { help=$generic_help func_fatal_help "you must specify a MODE" } test -z "$exec_cmd" && \ func_fatal_help "invalid operation mode '$opt_mode'" if test -n "$exec_cmd"; then eval exec "$exec_cmd" exit $EXIT_FAILURE fi exit $exit_status # The TAGs below are defined such that we never get into a situation # where we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared build_libtool_libs=no build_old_libs=yes # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: mlterm-3.9.3/baselib/src/000077500000000000000000000000001441203364000152135ustar00rootroot00000000000000mlterm-3.9.3/baselib/src/Makefile.in000066400000000000000000000050121441203364000172560ustar00rootroot00000000000000top_builddir = ..@pobl_top_builddir_suffix@ top_srcdir = @top_srcdir@@pobl_top_srcdir_suffix@ prefix = @prefix@ exec_prefix = @exec_prefix@ libdir = @libdir@ bindir = @bindir@ libexecdir = @libexecdir@ LIBDIR = $(DESTDIR)$(libdir) INCDIR = $(DESTDIR)$(prefix)/include VPATH = $(top_srcdir)/src INCDIR_TMP = ../include CC = @CC@ INSTALL = @INSTALL@ LIBTOOL = @LIBTOOL@ CFLAGS = $(CFLAGS_LOCAL) @DEB_CFLAGS@ @CFLAGS@ @CPPFLAGS@ @DL_CFLAGS@ @UTMP_CFLAGS@ \ -DLIBEXECDIR=\"${libexecdir}\" -DBINDIR=\"${bindir}\" LIBS = $(LIBS_LOCAL) @XPG4_LIBS@ @DL_LIBS@ @UTMP_LIBS@ COMOBJ = bl_debug.o bl_map.o bl_args.o bl_mem.o bl_conf.o bl_file.o bl_path.o \ bl_conf_io.o bl_str.o bl_cycle_index.o bl_langinfo.o bl_time.o bl_locale.o \ bl_privilege.o bl_unistd.o bl_sig_child.o bl_dialog.o bl_dlfcn.o bl_util.o DEPOBJ = bl_pty_@PTY_NAME@.o bl_utmp_@UTMP_NAME@.o bl_dlfcn_@DL_LOADER@.o OBJ = $(COMOBJ) $(DEPOBJ) INC = $(COMOBJ:.o=.h) bl_slist.h bl_types.h bl_util.h bl_def.h bl_net.h bl_pty.h bl_utmp.h bl_dlfcn.h LIBTOOL_CC = $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) LIBTOOL_LINK = $(LIBTOOL) --mode=link $(CC) $(LIBS) @LDFLAGS@ LIBTOOL_INSTALL = $(LIBTOOL) --mode=install $(INSTALL) LIBNAME=libpobl LIBNAME_DEB=libpobl_deb MAJOR = 2 MINOR = 1 SUBDIRS = config util io collection sys i18n all : $(LIBNAME).la collect-headers debug : $(MAKE) LIBNAME=$(LIBNAME_DEB) $(LIBNAME_DEB).a install : install-inc install-la install-inc : $(INCDIR)/pobl cp $(INCDIR_TMP)/pobl/*.h $(INCDIR)/pobl install-la : $(LIBDIR) $(LIBTOOL_INSTALL) $(LIBNAME).la $(LIBDIR) install-ar : $(LIBDIR) $(LIBTOOL_INSTALL) $(LIBNAME).a $(LIBDIR) install-deb : $(MAKE) LIBNAME=$(LIBNAME_DEB) $(OVERRIDE_MACROS) install-ar uninstall: rm -rf $(LIBDIR)/*pobl.* $(INCDIR)/pobl $(INCDIR)/pobl : mkdir -p $(INCDIR)/pobl $(LIBDIR) : mkdir -p $(LIBDIR) $(INCDIR_TMP)/pobl : mkdir -p $(INCDIR_TMP)/pobl collect-headers: $(INCDIR_TMP)/pobl $(INC) bl_config.h for file in $(INC) ; do \ if test -f $${file} ; \ then cp $${file} $(INCDIR_TMP)/pobl ; \ else cp $(top_srcdir)/src/$${file} $(INCDIR_TMP)/pobl ; \ fi \ done cp bl_config.h $(INCDIR_TMP)/pobl touch collect-headers wc : find . -name "*.[ch]" -a \! -name "test_*" | xargs wc -l .SUFFIXES: .c.o .c.o: $(LIBTOOL_CC) -I. -c $< $(LIBNAME).la : $(OBJ) $(LIBTOOL_LINK) -o $(LIBNAME).la $(OBJ:.o=.lo) -rpath $(libdir) \ @NO_UNDEFINED_FLAG@ -version-info $(MAJOR):$(MINOR):0 $(LIBNAME).a : $(OBJ) $(LIBTOOL_LINK) -o $(LIBNAME).a $(OBJ) clean : rm -rf $(INCDIR_TMP) .libs $(OBJ) $(OBJ:.o=.lo) *.la *.a collect-headers mlterm-3.9.3/baselib/src/bl_args.c000066400000000000000000000053001441203364000167660ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_args.h" #include /* strchr */ #include "bl_debug.h" #if 0 #define __DEBUG #endif /* --- global functions --- */ /* * supported option syntax. * * -x(=xxx) * --x(=xxx) * -xxx(=xxx) * --xxx(=xxx) * * "--" cancels parsing options. * * !! NOTICE !! * after bl_parse_options(), argv points to an argument next to a successfully * parsed one. */ int bl_parse_options(char **opt, char **opt_val, int *argc, char ***argv) { char *arg_p; if (*argc == 0 || (arg_p = (*argv)[0]) == NULL) { /* end of argv */ return 0; } if (*arg_p != '-') { /* not option */ return 0; } arg_p++; if (*arg_p == '-') { arg_p++; if (*arg_p == '\0') { /* "--" */ return 0; } } *opt = arg_p; if ((arg_p = strchr(arg_p, '=')) == NULL) { *opt_val = NULL; } else { *arg_p = '\0'; *opt_val = arg_p + 1; } (*argv)++; (*argc)--; return 1; } int bl_arg_str_to_array(char **argv, int *argc, char *args) { char *args_dup; char *p; /* * parsing options. */ *argc = 0; args_dup = args; if ((args = alloca(strlen(args) + 1)) == NULL) { return 0; } strcpy(args, args_dup); p = args_dup; while (*args) { int quoted; while (*args == ' ' /* || *args == '\t' */) { if (*(++args) == '\0') { goto parse_end; } } if (*args == '\"' || *args == '\'') { quoted = 1; args++; } else { quoted = 0; } while (*args) { if (quoted) { if (*args == '\"' || *args == '\'') { args++; break; } } else { if (*args == ' ' /* || *args == '\t' */) { args++; break; } } if (*args == '\\' && (args[1] == '\"' || args[1] == '\'' || (!quoted && (args[1] == ' ' /* || args[1] == '\t' */)))) { *(p++) = *(++args); } else { *(p++) = *args; } args++; } *(p++) = '\0'; argv[(*argc)++] = args_dup; args_dup = p; } parse_end: /* NULL terminator (POSIX exec family style) */ argv[*argc] = NULL; return 1; } #ifdef BL_DEBUG #include void TEST_bl_args(void) { int argc; char **argv; char args[] = "mlclient -l \"hoge fuga \\\" \" \' a b c \' \\\' \\\" a\\ b \"a\\ b\""; char *argv_correct[] = {"mlclient", "-l", "hoge fuga \" ", " a b c ", "\'", "\"", "a b", "a\\ b"}; int count; argv = bl_argv_alloca(args); bl_arg_str_to_array(argv, &argc, args); for (count = 0; count < argc; count++) { assert(strcmp(argv_correct[count], argv[count]) == 0); } bl_msg_printf("PASS bl_args test.\n"); } #endif mlterm-3.9.3/baselib/src/bl_args.h000066400000000000000000000011211441203364000167700ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_ARGS_H__ #define __BL_ARGS_H__ #include "bl_mem.h" /* alloca */ #include "bl_str.h" /* bl_count_char_in_str */ int bl_parse_options(char **opt, char **opt_val, int *argc, char ***argv); /* * '\t' is not recognized as separator. * If you try to recognize '\t', don't forget to add checking "-e\t" in * set_config("mlclient") in ui_screen.c. */ #define bl_argv_alloca(args) alloca(sizeof(char*) * (bl_count_char_in_str((args), ' ') + 2)) int bl_arg_str_to_array(char **argv, int *argc, char *args); #endif mlterm-3.9.3/baselib/src/bl_conf.c000066400000000000000000000275011441203364000167660ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_conf.h" #include #include /* memset */ #include "bl_str.h" /* bl_str_sep/strdup */ #include "bl_mem.h" /* malloc/alloca */ #include "bl_file.h" #include "bl_conf_io.h" #include "bl_args.h" #include "bl_util.h" /* DIGIT_STR_LEN */ #define CH2IDX(ch) ((ch)-0x20) #if 0 #define __DEBUG #endif /* --- static variables --- */ static const char *prog_path; static const char *prog_name; static const char *prog_version; /* --- static functions --- */ static void __exit(bl_conf_t *conf, int status) { #ifdef DEBUG bl_conf_destroy(conf); bl_mem_free_all(); #endif exit(status); } static void version(bl_conf_t *conf) { printf("%s version %s\n", prog_name, prog_version); } static void usage(bl_conf_t *conf) { int count; bl_arg_opt_t *end_opt; printf("usage: %s", prog_name); for (count = 0; count < conf->num_opts; count++) { if (conf->arg_opts[count] != NULL && conf->arg_opts[count]->opt != conf->end_opt) { printf(" [options]"); break; } } if (conf->end_opt > 0) { printf(" -%c ...", conf->end_opt); } printf("\n\noptions:\n"); end_opt = NULL; for (count = 0; count < conf->num_opts; count++) { if (conf->arg_opts[count] != NULL) { if (conf->arg_opts[count]->opt == conf->end_opt) { end_opt = conf->arg_opts[count]; } else { char *str; size_t len; len = 3 + 8 + 1; if (conf->arg_opts[count]->long_opt) { len += (3 + strlen(conf->arg_opts[count]->long_opt) + 1); } if ((str = alloca(len)) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " alloca() failed.\n"); #endif return; } /* 3 bytes */ if (conf->arg_opts[count]->opt) { sprintf(str, " -%c", conf->arg_opts[count]->opt); } else { strcpy(str, " "); } if (conf->arg_opts[count]->long_opt) { /* 3 bytes */ strcat(str, conf->arg_opts[count]->opt ? "/--" : " --"); strcat(str, conf->arg_opts[count]->long_opt); } if (conf->arg_opts[count]->is_boolean) { /* 8 bytes or ... */ strcat(str, "(=bool) "); } else { /* 7 bytes */ strcat(str, "=value "); } printf("%-20s: %s\n", str, conf->arg_opts[count]->help); } } } if (end_opt) { printf("\nend option:\n -%c", end_opt->opt); if (end_opt->long_opt) { printf(" --%s", end_opt->long_opt); } printf(" ... : %s\n", end_opt->help); } printf("\nnotice:\n"); printf("(=bool) is \"=true\" or \"=false\".\n"); } static bl_conf_entry_t *create_new_conf_entry(bl_conf_t *conf, char *key) { bl_conf_entry_t *entry; int result; if ((entry = malloc(sizeof(bl_conf_entry_t))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " malloc() failed.\n"); #endif return NULL; } memset(entry, 0, sizeof(bl_conf_entry_t)); if ((key = strdup(key)) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " strdup() failed.\n"); #endif free(entry); return NULL; } bl_map_set(result, conf->conf_entries, key, entry); if (!result) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " bl_map_set() failed.\n"); #endif free(key); free(entry); return NULL; } return entry; } /* --- global functions --- */ void bl_init_prog(const char *path, /* should be static data */ const char *version /* should be static data */) { prog_path = path; if ((prog_name = strrchr(path, '/')) || (prog_name = strrchr(path, '\\'))) { prog_name++; } else { prog_name = prog_path; } prog_version = version; } const char *bl_get_prog_path(void) { return prog_path; } bl_conf_t *bl_conf_new(void) { bl_conf_t *conf; if ((conf = malloc(sizeof(bl_conf_t))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " malloc() failed.\n"); #endif return NULL; } conf->num_opts = 0x60; if ((conf->arg_opts = malloc(conf->num_opts * sizeof(bl_arg_opt_t *))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " malloc() failed.\n"); #endif free(conf); return NULL; } memset(conf->arg_opts, 0, conf->num_opts * sizeof(bl_arg_opt_t *)); conf->end_opt = '\0'; bl_map_new_with_size(char *, bl_conf_entry_t *, conf->conf_entries, bl_map_hash_str, bl_map_compare_str_nocase, 16); return conf; } void bl_conf_destroy(bl_conf_t *conf) { int count; BL_PAIR(bl_conf_entry) * pairs; u_int size; for (count = 0; count < conf->num_opts; count++) { if (conf->arg_opts[count]) { free(conf->arg_opts[count]); } } free(conf->arg_opts); bl_map_get_pairs_array(conf->conf_entries, pairs, size); for (count = 0; count < size; count++) { free(pairs[count]->key); free(pairs[count]->value->value); #ifndef REMOVE_FUNCS_MLTERM_UNUSE free(pairs[count]->value->default_value); #endif free(pairs[count]->value); } bl_map_destroy(conf->conf_entries); free(conf); } int bl_conf_add_opt(bl_conf_t *conf, char short_opt, /* '\0' is accepted */ const char *long_opt, /* should be static data. NULL is accepted */ int is_boolean, char *key, /* should be static data */ const char *help /* should be static data */) { bl_arg_opt_t **opt; if (short_opt == '\0') { bl_arg_opt_t **arg_opts; if (long_opt == NULL) { /* it is not accepted that both opt and long_opt are NULL. */ return 0; } if ((arg_opts = realloc(conf->arg_opts, (conf->num_opts + 1) * sizeof(bl_arg_opt_t *))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " realloc() failed.\n"); #endif return 0; } conf->arg_opts = arg_opts; opt = &arg_opts[conf->num_opts++]; *opt = NULL; } else if (short_opt < ' ') { return 0; } else { opt = &conf->arg_opts[CH2IDX(short_opt)]; } if (*opt == NULL) { if ((*opt = malloc(sizeof(bl_arg_opt_t))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " malloc() failed.\n"); #endif return 0; } } (*opt)->opt = short_opt; (*opt)->long_opt = long_opt; (*opt)->key = key; (*opt)->is_boolean = is_boolean; (*opt)->help = help; return 1; } int bl_conf_set_end_opt(bl_conf_t *conf, char opt, const char *long_opt, /* should be static data */ char *key, /* should be static data */ const char *help /* should be static data */) { conf->end_opt = opt; /* is_boolean is always true */ return bl_conf_add_opt(conf, opt, long_opt, 1, key, help); } int bl_conf_parse_args(bl_conf_t *conf, int *argc, char ***argv, int ignore_unknown_opt) { char *opt_name; char *opt_val; BL_PAIR(bl_conf_entry) pair; bl_conf_entry_t *entry; /* passing argv[0] 'cause it may be the program name. */ (*argv)++; (*argc)--; while (bl_parse_options(&opt_name, &opt_val, argc, argv)) { char short_opt; bl_arg_opt_t *opt; if (strlen(opt_name) == 1) { short_opt = *opt_name; if (short_opt < ' ' || (opt = conf->arg_opts[CH2IDX(short_opt)]) == NULL) { if (ignore_unknown_opt) { continue; } goto error_with_msg; } } else if (strlen(opt_name) > 1) { /* long opt -> short opt */ int count; opt = NULL; for (count = 0; count < conf->num_opts; count++) { if (conf->arg_opts[count] && conf->arg_opts[count]->long_opt && strcmp(opt_name, conf->arg_opts[count]->long_opt) == 0) { opt = conf->arg_opts[count]; break; } } if (!opt) { if (ignore_unknown_opt) { continue; } goto error_with_msg; } short_opt = opt->opt; } else { if (ignore_unknown_opt) { continue; } goto error_with_msg; } bl_map_get(conf->conf_entries, opt->key, pair); if (!pair) { if ((entry = create_new_conf_entry(conf, opt->key)) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " create_new_conf_entry() failed.\n"); #endif return 0; } } else { entry = pair->value; if (entry->value) { free(entry->value); } } if (short_opt == 'h') { usage(conf); __exit(conf, 1); } else if (short_opt == 'v') { version(conf); __exit(conf, 1); } if (opt->is_boolean) { if (opt_val) { /* "-[opt]=true" format */ entry->value = strdup(opt_val); } else if (*argc && (*argv)[0] != NULL && (strcmp((*argv)[0], "true") == 0 || strcmp((*argv)[0], "false") == 0)) { /* "-[opt] true" format */ entry->value = strdup((*argv)[0]); (*argv)++; (*argc)--; } else { /* "-[opt]" format */ entry->value = strdup("true"); } } else { if (opt_val == NULL) { /* "-[opt] [opt_val]" format */ if (*argc == 0 || (*argv)[0] == NULL) { bl_msg_printf("%s option requires value.\n", opt_name); entry->value = NULL; goto error; } entry->value = strdup((*argv)[0]); (*argv)++; (*argc)--; } else { /* "-[opt]=[opt_val]" format */ entry->value = strdup(opt_val); } } if (short_opt == conf->end_opt) { /* the value of conf->end_opt should be "true" */ break; } } return 1; error_with_msg: bl_msg_printf("%s is unknown option.\n", opt_name); error: usage(conf); return 0; } int bl_conf_write(bl_conf_t *conf, const char *filename) { FILE *to; BL_PAIR(bl_conf_entry) * pairs; u_int size; int count; if (!(to = fopen(filename, "w"))) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " %s couldn't be opened.\n", filename); #endif return 0; } bl_map_get_pairs_array(conf->conf_entries, pairs, size); for (count = 0; count < size; count++) { fprintf(to, "%s = %s\n", pairs[count]->key, pairs[count]->value->value #ifndef REMOVE_FUNCS_MLTERM_UNUSE ? pairs[count]->value->value : pairs[count]->value->default_value #endif ); } fclose(to); return 1; } int bl_conf_read(bl_conf_t *conf, const char *filename) { bl_file_t *from; char *key; char *value; bl_conf_entry_t *entry; BL_PAIR(bl_conf_entry) pair; if (!(from = bl_file_open(filename, "r"))) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " %s couldn't be opened.\n", filename); #endif return 0; } while (bl_conf_io_read(from, &key, &value)) { value = strdup(value); bl_map_get(conf->conf_entries, key, pair); if (!pair) { if ((entry = create_new_conf_entry(conf, key)) == NULL) { free(value); return 0; } } else { entry = pair->value; if (entry->value) { free(entry->value); } } entry->value = value; } bl_file_close(from); return 1; } char *bl_conf_get_value(bl_conf_t *conf, char *key) { BL_PAIR(bl_conf_entry) pair; bl_map_get(conf->conf_entries, key, pair); if (!pair) { #ifdef __DEBUG bl_warn_printf(BL_DEBUG_TAG " no such key[%s] in conf map.\n", key); #endif return NULL; } else { return pair->value->value #ifndef REMOVE_FUNCS_MLTERM_UNUSE ? pair->value->value : pair->value->default_value #endif ; } } #ifndef REMOVE_FUNCS_MLTERM_UNUSE int bl_conf_set_default_value(bl_conf_t *conf, char *key, char *default_value) { bl_conf_entry_t *entry; BL_PAIR(bl_conf_entry) pair; key = strdup(key); bl_map_get(conf->conf_entries, key, pair); if (!pair) { if ((entry = create_new_conf_entry(conf, key)) == NULL) { return 0; } } else { entry = pair->value; free(entry->default_value); } entry->default_value = default_value; return 1; } #endif mlterm-3.9.3/baselib/src/bl_conf.h000066400000000000000000000032051441203364000167660ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_CONF_H__ #define __BL_CONF_H__ #include "bl_def.h" /* REMOVE_FUNCS_MLTERM_UNUSE */ #include "bl_types.h" #include "bl_map.h" /* * all members should be allocated on the caller side. */ typedef struct bl_arg_opt { char opt; const char *long_opt; int is_boolean; char *key; const char *help; } bl_arg_opt_t; /* * all members are allocated internally. */ typedef struct bl_conf_entry { char *value; #ifndef REMOVE_FUNCS_MLTERM_UNUSE char *default_value; #endif } bl_conf_entry_t; BL_MAP_TYPEDEF(bl_conf_entry, char *, bl_conf_entry_t *); typedef struct bl_conf { bl_arg_opt_t **arg_opts; /* 0x20 - 0x7f */ int num_opts; char end_opt; BL_MAP(bl_conf_entry) conf_entries; } bl_conf_t; void bl_init_prog(const char *path, const char *version); const char *bl_get_prog_path(void); bl_conf_t *bl_conf_new(void); void bl_conf_destroy(bl_conf_t *conf); int bl_conf_add_opt(bl_conf_t *conf, char short_opt, const char *long_opt, int is_boolean, char *key, const char *help); int bl_conf_set_end_opt(bl_conf_t *conf, char opt, const char *long_opt, char *key, const char *help); int bl_conf_parse_args(bl_conf_t *conf, int *argc, char ***argv, int ignore_unknown_opt); int bl_conf_write(bl_conf_t *conf, const char *filename); int bl_conf_read(bl_conf_t *conf, const char *filename); char *bl_conf_get_value(bl_conf_t *conf, char *key); #ifndef REMOVE_FUNCS_MLTERM_UNUSE int bl_conf_set_default_value(bl_conf_t *conf, char *key, char *default_value); #endif char *bl_conf_get_version(bl_conf_t *conf); #endif mlterm-3.9.3/baselib/src/bl_conf_io.c000066400000000000000000000131571441203364000174570ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_conf_io.h" #include /* sprintf */ #include /* strlen */ #include /* getenv */ #ifndef USE_WIN32API #include #endif #include "bl_str.h" /* bl_str_sep/bl_str_chop_spaces */ #include "bl_mem.h" /* malloc */ #include "bl_path.h" #include "bl_debug.h" /* --- static variables --- */ static const char *sysconfdir; /* --- global functions --- */ void bl_set_sys_conf_dir(const char *dir) { sysconfdir = dir; } char *bl_get_sys_rc_path(const char *rcfile) { char *rcpath; if (sysconfdir == NULL) { return NULL; } if ((rcpath = malloc(strlen(sysconfdir) + 1 + strlen(rcfile) + 1)) == NULL) { return NULL; } #ifdef USE_WIN32API sprintf(rcpath, "%s\\%s", sysconfdir, rcfile); #else sprintf(rcpath, "%s/%s", sysconfdir, rcfile); #endif return rcpath; } char *bl_get_user_rc_path(const char *rcfile) { char *homedir; char *dotrcpath; #ifndef USE_WIN32API char *xdg_cfg; size_t base_len; #endif #ifdef DEBUG if ((homedir = getenv("CONF_DIR"))) { bl_msg_printf("using %s as an user config dir.\n", homedir); /* conf path is overridden */; } else #endif if ((homedir = bl_get_home_dir()) == NULL) { return NULL; } #ifdef USE_WIN32API /* Enough for "%s\%s" */ if ((dotrcpath = malloc(strlen(homedir) + 1 + strlen(rcfile) + 1))) { /* subdir doesn't contain "." in win32 native. */ sprintf(dotrcpath, "%s\\%s", homedir, rcfile); } #else base_len = strlen(homedir) + 9; /* %s/.config/ */ if ((xdg_cfg = getenv("XDG_CONFIG_HOME"))) { if (*xdg_cfg) { size_t len = strlen(xdg_cfg); if (base_len < len + 1) { base_len = len + 1; /* %s/ */ } } else { xdg_cfg = NULL; } } /* Enough for "%s/.config/%s" */ if ((dotrcpath = malloc(base_len + strlen(rcfile) + 1))) { char *p; if (xdg_cfg) { sprintf(dotrcpath, "%s/%s", xdg_cfg, rcfile); } else { sprintf(dotrcpath, "%s/.config/%s", homedir, rcfile); } p = strrchr(dotrcpath, '/'); if (p >= dotrcpath + base_len) { struct stat st; *p = '\0'; if (stat(dotrcpath, &st) == 0) { *p = '/'; /* ~/.config/mlterm exists. */ goto end; } } sprintf(dotrcpath, "%s/.%s", homedir, rcfile); } end: #endif return dotrcpath; } bl_conf_write_t *bl_conf_write_open(const char *path) { bl_conf_write_t *conf; bl_file_t *from; if ((conf = malloc(sizeof(bl_conf_write_t))) == NULL) { return conf; } if ((conf->lines = malloc(sizeof(char *) * 128)) == NULL) { free(conf); return NULL; } conf->num = 0; conf->scale = 1; from = bl_file_open(path, "r"); if (from) { while (1) { char *line; size_t len; if (conf->num >= conf->scale * 128) { void *p; if ((p = realloc(conf->lines, sizeof(char *) * 128 * (conf->scale + 1))) == NULL) { goto error; } conf->scale++; conf->lines = p; } if ((line = bl_file_get_line(from, &len)) == NULL) { break; } conf->lines[conf->num++] = strdup(line); } bl_file_close(from); } if ((conf->path = strdup(path)) == NULL) { goto error; } return conf; error: { u_int count; for (count = 0; count < conf->num; count++) { free(conf->lines[count]); } } free(conf->lines); free(conf); return NULL; } int bl_conf_io_write(bl_conf_write_t *conf, const char *key, const char *val) { u_int count; char *p; if (key == NULL) { return 0; } if (val == NULL) { val = "\0"; } for (count = 0; count < conf->num; count++) { if (*conf->lines[count] == '#') { continue; } p = conf->lines[count]; while (*p == ' ' || *p == '\t') { p++; } if (strncmp(p, key, strlen(key)) != 0) { continue; } if ((p = malloc(strlen(key) + strlen(val) + 4)) == NULL) { continue; } sprintf(p, "%s = %s", key, val); free(conf->lines[count]); conf->lines[count] = p; return 1; } if (conf->num + 1 >= conf->scale * 128) { void *p; if ((p = realloc(conf->lines, sizeof(char *) * 128 * (++conf->scale))) == NULL) { return 0; } conf->lines = p; } if ((p = malloc(strlen(key) + strlen(val) + 4)) == NULL) { return 0; } sprintf(p, "%s = %s", key, val); conf->lines[conf->num++] = p; return 1; } void bl_conf_write_close(bl_conf_write_t *conf) { FILE *fp; if (conf->num > 0 && (fp = bl_fopen_with_mkdir(conf->path, "w"))) { u_int count; for (count = 0; count < conf->num; count++) { fprintf(fp, "%s\n", conf->lines[count]); free(conf->lines[count]); } fclose(fp); } free(conf->path); free(conf->lines); free(conf); } int bl_conf_io_read(bl_file_t *from, char **key, char **val) { char *line; size_t len; while (1) { if ((line = bl_file_get_line(from, &len)) == NULL) { return 0; } if (len == 0 || *line == '#') { /* empty line or comment out */ continue; } /* * finding key */ while (*line == ' ' || *line == '\t') { line++; } *key = bl_str_sep(&line, "="); if (line == NULL) { /* not a conf line */ continue; } *key = bl_str_chop_spaces(*key); /* * finding value */ while (*line == ' ' || *line == '\t') { line++; } *val = bl_str_chop_spaces(line); /* Remove #comment after key=value. */ if ((line = strrchr(line, '#')) && (*(--line) == ' ' || *line == '\t')) { *line = '\0'; *val = bl_str_chop_spaces(*val); } return 1; } } mlterm-3.9.3/baselib/src/bl_conf_io.h000066400000000000000000000012051441203364000174530ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_CONF_IO_H__ #define __BL_CONF_IO_H__ #include "bl_file.h" typedef struct bl_conf_write { char *path; char **lines; u_int scale; u_int num; } bl_conf_write_t; void bl_set_sys_conf_dir(const char *dir); char *bl_get_sys_rc_path(const char *rcfile); char *bl_get_user_rc_path(const char *rcfile); bl_conf_write_t *bl_conf_write_open(const char *path); int bl_conf_io_write(bl_conf_write_t *conf, const char *key, const char *val); void bl_conf_write_close(bl_conf_write_t *conf); int bl_conf_io_read(bl_file_t *from, char **key, char **val); #endif mlterm-3.9.3/baselib/src/bl_config.h.in000066400000000000000000000035331441203364000177170ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* * Don't include directly this header. * Include bl_def.h (which wraps POSIX and bl_config.h macros) or bl_types.h * (which wraps POSIX and bl_config.h types). */ #ifndef __BL_CONFIG_H__ #define __BL_CONFIG_H__ #undef HAVE_GNU_SOURCE #undef HAVE_LANGINFO_H #undef HAVE_DL_H #undef HAVE_DLFCN_H #undef HAVE_WINDOWS_H #undef HAVE_ERRNO_H #undef HAVE_STDINT_H #undef HAVE_SYS_BITYPES_H /* AC_C_BIGENDIAN */ #undef WORDS_BIGENDIAN /* AC_SYS_LARGEFILE */ #undef _FILE_OFFSET_BITS #undef _LARGE_FILES #undef HAVE_STRSEP #undef HAVE_FGETLN #undef HAVE_BASENAME #undef HAVE_ALLOCA #undef HAVE_ALLOCA_H #undef HAVE_STROPTS_H #undef HAVE_SYS_STROPTS_H #undef HAVE_ISASTREAM #undef HAVE_SETUTENT #undef HAVE_SETEUID #undef HAVE_SETEGID #undef HAVE_GETEUID #undef HAVE_SETSID #undef HAVE_GETUID #undef HAVE_GETGID #undef HAVE_GETPWUID #undef HAVE_RECVMSG #undef HAVE_SETPGID #undef HAVE_SOCKETPAIR #undef HAVE_SNPRINTF #undef CONCATABLE_FUNCTION #undef DLFCN_NONE #undef HAVE_USLEEP #undef HAVE_SETENV #undef HAVE_UNSETENV #undef HAVE_FLOCK #undef HAVE_KILLPG #undef HAVE_POSIX_OPENPT #undef HAVE_GETTIMEOFDAY #undef USE_WIN32API #undef HAVE_STDINT_H #undef REMOVE_FUNCS_MLTERM_UNUSE #undef CALLOC_CHECK_OVERFLOW #undef inline #undef const #if defined(USE_WIN32API) && !defined(_BSDTYPES_DEFINED) /* XXX winsock2.h typedefs u_char, u_short, u_int if _BSDTYPES_DEFINED is * undefined. */ #define _BSDTYPES_DEFINED #endif #undef u_char #undef u_short #undef u_int #undef u_long #undef u_int8_t #undef u_int8_t #undef u_int16_t #undef u_int32_t #undef u_int64_t #undef int8_t #undef int8_t #undef int16_t #undef int32_t #undef int64_t #undef ssize_t #undef socklen_t #undef mode_t #undef pid_t #undef uid_t #undef gid_t #undef off_t #undef size_t #endif mlterm-3.9.3/baselib/src/bl_cycle_index.c000066400000000000000000000051621441203364000203260ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_cycle_index.h" #include "bl_mem.h" #include "bl_debug.h" /* --- global functions --- */ bl_cycle_index_t *bl_cycle_index_new(u_int size) { bl_cycle_index_t *cycle; if (size == 0) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " the size of cycle index should be greater than 0.\n"); #endif return NULL; } if ((cycle = malloc(sizeof(bl_cycle_index_t))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " malloc() failed.\n"); #endif return NULL; } cycle->size = size; cycle->start = 0; cycle->next = 0; cycle->is_init = 1; return cycle; } void bl_cycle_index_destroy(bl_cycle_index_t *cycle) { free(cycle); } void bl_cycle_index_reset(bl_cycle_index_t *cycle) { cycle->start = 0; cycle->next = 0; cycle->is_init = 1; } void bl_cycle_index_rollback(bl_cycle_index_t *cycle, u_int num) { if (bl_get_filled_cycle_index(cycle) <= num) { cycle->is_init = 1; cycle->next = cycle->start; } else { if (cycle->next < num) { cycle->next += cycle->size; } cycle->next -= num; } } /* * !! Notice !! * this resets the "start" member 0. */ void bl_cycle_index_change_size(bl_cycle_index_t *cycle, u_int new_size) { u_int filled; if ((filled = bl_get_filled_cycle_index(cycle)) == 0) { cycle->size = new_size; bl_cycle_index_reset(cycle); return; } cycle->size = new_size; cycle->start = 0; if (filled >= new_size) { cycle->next = 0; } else { cycle->next = filled; } } u_int bl_get_cycle_index_size(bl_cycle_index_t *cycle) { return cycle->size; } u_int bl_get_filled_cycle_index(bl_cycle_index_t *cycle) { if (cycle->is_init) { return 0; } else if (cycle->next == cycle->start) { return cycle->size; } else if (cycle->next > cycle->start) { return cycle->next - cycle->start; } else { return cycle->next + cycle->size - cycle->start; } } int bl_cycle_index_of(bl_cycle_index_t *cycle, int at) { if (cycle->start + at >= cycle->size) { if (cycle->start + at - cycle->size >= cycle->size) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " index(%d) is strange.\n", at); #endif return -1; } else { return cycle->start + at - cycle->size; } } else { return cycle->start + at; } } int bl_next_cycle_index(bl_cycle_index_t *cycle) { int next; if (cycle->is_init) { cycle->is_init = 0; } else if (cycle->next == cycle->start) { if (++cycle->start == cycle->size) { cycle->start = 0; } } next = cycle->next; if (++cycle->next == cycle->size) { cycle->next = 0; } return next; } mlterm-3.9.3/baselib/src/bl_cycle_index.h000066400000000000000000000014431441203364000203310ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_CYCLE_INDEX_H__ #define __BL_CYCLE_INDEX_H__ #include "bl_types.h" /* size_t */ typedef struct bl_cycle_index { int start; int next; int is_init; u_int size; } bl_cycle_index_t; bl_cycle_index_t *bl_cycle_index_new(u_int size); void bl_cycle_index_destroy(bl_cycle_index_t *cycle); void bl_cycle_index_reset(bl_cycle_index_t *cycle); void bl_cycle_index_rollback(bl_cycle_index_t *cycle, u_int num); void bl_cycle_index_change_size(bl_cycle_index_t *cycle, u_int new_size); u_int bl_get_cycle_index_size(bl_cycle_index_t *cycle); u_int bl_get_filled_cycle_index(bl_cycle_index_t *cycle); int bl_cycle_index_of(bl_cycle_index_t *cycle, int at); int bl_next_cycle_index(bl_cycle_index_t *cycle); #endif mlterm-3.9.3/baselib/src/bl_debug.c000066400000000000000000000066711441203364000171340ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* Don't include bl_debug.h because macros in android/jni/bl_debug.h causes compiling error. */ #include "bl_def.h" /* HAVE_ERRNO_H */ #include #include #include /* strlen */ #include /* getpid */ #include /* time/ctime */ #ifdef HAVE_ERRNO_H #include #endif #include "bl_mem.h" /* alloca */ #include "bl_util.h" /* DIGIT_STR_LEN */ #include "bl_conf_io.h" /* bl_get_user_rc_path */ #if 0 #define __DEBUG #endif /* --- static variables --- */ static char *log_file_path; /* --- static functions --- */ static FILE *open_msg_file(void) { FILE *fp; if (log_file_path && (fp = fopen(log_file_path, "a+"))) { char ch; time_t tm; char *time_str; if (fseek(fp, -1, SEEK_END) == 0) { if (fread(&ch, 1, 1, fp) == 1 && ch != '\n') { fseek(fp, 0, SEEK_SET); return fp; } fseek(fp, 0, SEEK_SET); } tm = time(NULL); time_str = ctime(&tm); time_str[19] = '\0'; time_str += 4; fprintf(fp, "%s[%d] ", time_str, getpid()); return fp; } return stderr; } static void close_msg_file(FILE *fp) { if (fp != stderr) { fclose(fp); } else { #ifdef USE_WIN32API fflush(fp); #endif } } #if defined(__APPLE__) && defined(USE_NSLOG) #include static int debug_printf(const char *prefix, const char *format, va_list arg_list) { CFStringRef cffmt = CFStringCreateWithCString(NULL, format, kCFStringEncodingUTF8); NSLog(cffmt, arg_list); return 1; } #else static int debug_printf(const char *prefix, const char *format, va_list arg_list) { size_t prefix_len; int ret; FILE *fp; if ((prefix_len = strlen(prefix)) > 0) { char *new_format; if ((new_format = alloca(prefix_len + strlen(format) + 1)) == NULL) { /* error */ return 0; } sprintf(new_format, "%s%s", prefix, format); format = new_format; } fp = open_msg_file(); ret = vfprintf(fp, format, arg_list); close_msg_file(fp); return ret; } #endif /* --- global functions --- */ /* * this is usually used between #ifdef __DEBUG ... #endif */ int bl_debug_printf(const char *format, ...) { va_list arg_list; va_start(arg_list, format); return debug_printf("DEBUG: ", format, arg_list); } /* * this is usually used between #ifdef DEBUG ... #endif */ int bl_warn_printf(const char *format, ...) { va_list arg_list; va_start(arg_list, format); return debug_printf("WARN: ", format, arg_list); } /* * this is usually used without #ifdef ... #endif */ int bl_error_printf(const char *format, ...) { va_list arg_list; char *prefix; int ret; va_start(arg_list, format); #ifdef HAVE_ERRNO_H if (errno != 0) { char *error; error = strerror(errno); if (!(prefix = alloca(6 + strlen(error) + 3 + 1))) { ret = 0; goto end; } sprintf(prefix, "ERROR(%s): ", error); } else #endif { prefix = "ERROR: "; } ret = debug_printf(prefix, format, arg_list); end: va_end(arg_list); return ret; } /* * for noticing message. */ int bl_msg_printf(const char *format, ...) { va_list arg_list; va_start(arg_list, format); return debug_printf("", format, arg_list); } int bl_set_msg_log_file_name(const char *name) { free(log_file_path); if (name && *name) { log_file_path = bl_get_user_rc_path(name); } else { log_file_path = NULL; } return 1; } mlterm-3.9.3/baselib/src/bl_debug.h000066400000000000000000000020561441203364000171320ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_DEBUG_H__ #define __BL_DEBUG_H__ #include "bl_def.h" #include "bl_util.h" /* BL_INT_TO_STR */ /* for bl_{debug|warn}_printf */ #if 0 #ifdef CONCATABLE_FUNCTION #define BL_DEBUG_TAG "[" __FUNCTION__ "()]" #else #define BL_DEBUG_TAG "[" __FILE__ "]" #endif #else #define BL_DEBUG_TAG "[" __FILE__ ":" BL_INT_TO_STR(__LINE__) "]" #endif #ifdef BL_DEBUG #define BL_TESTIT(func, args) TEST_##func args #define BL_TESTIT_ONCE(func, args) \ { \ static int func##_tested; \ if (!func##_tested) { \ func##_tested = 1; \ TEST_##func args; \ } \ } #else #define BL_TESTIT(func, args) #define BL_TESTIT_ONCE(func, args) #endif int bl_debug_printf(const char *format, ...); int bl_warn_printf(const char *format, ...); int bl_error_printf(const char *format, ...); int bl_msg_printf(const char *format, ...); int bl_set_msg_log_file_name(const char *name); #endif mlterm-3.9.3/baselib/src/bl_def.h000066400000000000000000000013421441203364000165770ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_DEF_H__ #define __BL_DEF_H__ /* various AC_DEFINEs are defined in bl_config.h */ #include "bl_config.h" #include /* PATH_MAX,SIZE_MAX */ #ifdef HAVE_STDINT_H #include /* SIZE_MAX on some platforms */ #endif #ifndef PATH_MAX #ifndef _POSIX_PATH_MAX #define _POSIX_PATH_MAX 255 #endif #define PATH_MAX _POSIX_PATH_MAX #endif #ifndef SIZE_MAX #ifdef SIZE_T_MAX #define SIZE_MAX SIZE_T_MAX #else #define SIZE_MAX ((size_t)-1) #endif #endif #ifndef SSIZE_MAX #define(SIZE_MAX / 2) #endif #if 0 /* Check integer overflow. Use this with malloc or alloca. */ #define _X(a, b) ((a) > SIZE_MAX / (b) ? SIZE_MAX : (a) * (b)) #endif #endif mlterm-3.9.3/baselib/src/bl_dialog.c000066400000000000000000000011771441203364000173010ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dialog.h" #include "bl_debug.h" /* --- static variables --- */ static int (*callback)(bl_dialog_style_t, const char *); /* --- global functions --- */ void bl_dialog_set_callback(int (*cb)(bl_dialog_style_t, const char *)) { callback = cb; } #if 0 int bl_dialog_set_exec_file(bl_dialog_style_t style, const char *path) { return 1; } #endif int bl_dialog(bl_dialog_style_t style, const char *msg) { int ret; if (callback && (ret = (*callback)(style, msg)) != -1) { return ret; } else { bl_msg_printf("%s\n", msg); return -1; } } mlterm-3.9.3/baselib/src/bl_dialog.h000066400000000000000000000007511441203364000173030ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_DIALOG_H__ typedef enum { BL_DIALOG_OKCANCEL = 0, BL_DIALOG_ALERT = 1, } bl_dialog_style_t; /* * 'callback' can be called from multiple thread contexts. * Check whether the current thread is a main thread or not, if gui toolkit * doesn't support it. */ void bl_dialog_set_callback(int (*callback)(bl_dialog_style_t, const char *)); int bl_dialog(bl_dialog_style_t style, const char *msg); #endif mlterm-3.9.3/baselib/src/bl_dlfcn.c000066400000000000000000000020101441203364000171130ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dlfcn.h" #include /* atexit, realloc(Don't include bl_mem.h) */ #include "bl_types.h" /* u_int */ /* --- static variables --- */ static bl_dl_handle_t *handles; static u_int num_handles; /* --- global functions --- */ int bl_dl_close_at_exit(bl_dl_handle_t handle) { void *p; if (!(p = realloc(handles, sizeof(bl_dl_handle_t) * (num_handles + 1)))) { return 0; } handles = p; #if 0 if (num_handles == 0) { atexit(bl_dl_close_all); } else #endif { u_int count; for (count = 0; count < num_handles; count++) { if (handles[count] == handle) { bl_dl_close(handle); return 1; } } } handles[num_handles++] = handle; return 1; } void bl_dl_close_all(void) { u_int count; /* Close from the last loaded library. */ for (count = num_handles; count > 0; count--) { bl_dl_close(handles[count - 1]); } num_handles = 0; free(handles); handles = NULL; } mlterm-3.9.3/baselib/src/bl_dlfcn.h000066400000000000000000000007251441203364000171330ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_DLFCN_H__ #define __BL_DLFCN_H__ #include "bl_def.h" typedef void *bl_dl_handle_t; bl_dl_handle_t bl_dl_open(const char *dirpath, const char *name); void bl_dl_close(bl_dl_handle_t handle); void *bl_dl_func_symbol(bl_dl_handle_t handle, const char *symbol); int bl_dl_is_module(const char *name); int bl_dl_close_at_exit(bl_dl_handle_t handle); void bl_dl_close_all(void); #endif mlterm-3.9.3/baselib/src/bl_dlfcn_dl.c000066400000000000000000000037101441203364000176020ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dlfcn.h" #include /* NULL */ #include /* strlen */ #include "bl_mem.h" /* alloca() */ #ifdef DEBUG #include "bl_debug.h" #endif #include /* --- global functions --- */ bl_dl_handle_t bl_dl_open(const char *dirpath, const char *name) { char *path; void *ret; if ((path = alloca(strlen(dirpath) + strlen(name) + 7)) == NULL) { return NULL; } #ifdef DEBUG bl_debug_printf("Loading %slib%s.so\n", dirpath, name); #endif /* * libfoo.so --> foo.so --> libfoo.sl --> foo.sl */ sprintf(path, "%slib%s.so", dirpath, name); if ((ret = dlopen(path, RTLD_LAZY))) { return (bl_dl_handle_t)ret; } #ifndef __APPLE__ sprintf(path, "%slib%s.sl", dirpath, name); if ((ret = dlopen(path, RTLD_LAZY))) { return (bl_dl_handle_t)ret; } sprintf(path, "%s%s.so", dirpath, name); if ((ret = dlopen(path, RTLD_LAZY))) { return (bl_dl_handle_t)ret; } sprintf(path, "%s%s.sl", dirpath, name); if ((ret = dlopen(path, RTLD_LAZY))) { return (bl_dl_handle_t)ret; } #else { const char *p; /* XXX Hack */ if ((strcmp((p = dirpath + strlen(dirpath) - 4), "mef/") == 0 || strcmp((p -= 3), "mlterm/") == 0) && (path = alloca(21 + strlen(p) + 3 + strlen(name) + 3 + 1))) { sprintf(path, "@executable_path/lib/%slib%s.so", p, name); } else { return NULL; } if ((ret = dlopen(path, RTLD_LAZY))) { return (bl_dl_handle_t)ret; } } #endif return NULL; } void bl_dl_close(bl_dl_handle_t handle) { dlclose(handle); } void *bl_dl_func_symbol(bl_dl_handle_t handle, const char *symbol) { return dlsym(handle, symbol); } int bl_dl_is_module(const char *name) { size_t len; if (!name) { return 0; } if ((len = strlen(name)) < 3) { return 0; } if (strcmp(&name[len - 3], ".so") == 0 || strcmp(&name[len - 3], ".sl") == 0) { return 1; } return 0; } mlterm-3.9.3/baselib/src/bl_dlfcn_dld.c000066400000000000000000000023471441203364000177530ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dlfcn.h" #include /* NULL */ #include /* strlen */ #include "bl_mem.h" /* alloca() */ #include /* --- global functions --- */ bl_dl_handle_t bl_dl_open(const char *dirpath, const char *name) { char *path; shl_t handle; if ((path = alloca(strlen(dirpath) + strlen(name) + 7)) == NULL) { return NULL; } /* * libfoo.sl --> foo.sl */ sprintf(path, "%slib%s.sl", dirpath, name); if ((handle = shl_load(path, BIND_DEFERRED, 0x0))) { return (bl_dl_handle_t)handle; } sprintf(path, "%s%s.sl", dirpath, name); if ((handle = shl_load(path, BIND_DEFERRED, 0x0))) { return (bl_dl_handle_t)handle; } return NULL; } void bl_dl_close(bl_dl_handle_t handle) { shl_unload((shl_t)handle); } void *bl_dl_func_symbol(bl_dl_handle_t handle, const char *symbol) { void *func; if (shl_findsym((shl_t *)&handle, symbol, TYPE_PROCEDURE, &func) == -1) { return NULL; } return func; } int bl_dl_is_module(const char *name) { size_t len; if (!name) { return 0; } if ((len = strlen(name)) < 3) { return 0; } if (strcmp(&name[len - 3], ".sl") == 0) { return 1; } return 0; } mlterm-3.9.3/baselib/src/bl_dlfcn_dyld.c000066400000000000000000000072301441203364000201400ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dlfcn.h" #include /* NULL */ #include /* strlen */ #include "bl_mem.h" /* alloca() */ #include "bl_slist.h" #ifdef DEBUG #include "bl_debug.h" #endif #include typedef struct loaded_module { bl_dl_handle_t handle; char *dirpath; char *name; u_int ref_count; struct loaded_module *next; } loaded_module_t; /* --- static functions --- */ static loaded_module_t *module_list = NULL; /* --- global functions --- */ bl_dl_handle_t bl_dl_open(const char *dirpath, const char *name) { NSObjectFileImage file_image; NSObjectFileImageReturnCode ret; loaded_module_t *module; bl_dl_handle_t handle; char *path; module = module_list; while (module) { if (strcmp(module->dirpath, dirpath) == 0 && strcmp(module->name, name) == 0) { module->ref_count++; return module->handle; } module = bl_slist_next(module); } if (!(module = malloc(sizeof(loaded_module_t)))) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " malloc failed.\n"); #endif return NULL; } module->dirpath = strdup(dirpath); module->name = strdup(name); module->ref_count = 0; if ((path = alloca(strlen(dirpath) + strlen(name) + 7)) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " alloca() failed.\n"); #endif return NULL; } /* * libfoo.so --> foo.so */ sprintf(path, "%slib%s.so", dirpath, name); if ((ret = NSCreateObjectFileImageFromFile(path, &file_image)) != NSObjectFileImageSuccess) { sprintf(path, "%s%s.so", dirpath, name); if ((ret = NSCreateObjectFileImageFromFile(path, &file_image)) != NSObjectFileImageSuccess) { goto error; } } handle = (bl_dl_handle_t)NSLinkModule(file_image, path, NSLINKMODULE_OPTION_BINDNOW); if (!handle) { goto error; } bl_slist_insert_head(module_list, module); module->handle = handle; module->ref_count++; return handle; error: if (module) { free(module->dirpath); free(module->name); free(module); } return NULL; } void bl_dl_close(bl_dl_handle_t handle) { loaded_module_t *module; if (!module_list) { return; } module = module_list; while (module) { if (module->handle == handle) { module->ref_count--; if (module->ref_count) { return; } break; } module = bl_slist_next(module); } if (NSUnLinkModule((NSModule)module->handle, NSUNLINKMODULE_OPTION_NONE) == 0) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " NSUnLinkModule() failed.\n"); #endif return; } bl_slist_remove(module_list, module); free(module->dirpath); free(module->name); free(module); } void *bl_dl_func_symbol(bl_dl_handle_t unused, const char *symbol) { NSSymbol nssymbol = NULL; char *symbol_name; if ((symbol_name = alloca(strlen(symbol) + 2)) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " alloca() failed.\n"); #endif return NULL; } sprintf(symbol_name, "_%s", symbol); if (!NSIsSymbolNameDefined(symbol_name)) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " NSIsSymbolNameDefined() failed. [symbol_name: %s]\n", symbol_name); #endif return NULL; } if ((nssymbol = NSLookupAndBindSymbol(symbol_name)) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " NSLookupAndBindSymbol() failed. [symbol_name: %s]\n", symbol_name); #endif return NULL; } return NSAddressOfSymbol(nssymbol); } int bl_dl_is_module(const char *name) { size_t len; if (!name) { return 0; } if ((len = strlen(name)) < 3) { return 0; } if (strcmp(&name[len - 3], ".so") == 0) { return 1; } return 0; } mlterm-3.9.3/baselib/src/bl_dlfcn_ltdl.c000066400000000000000000000024571441203364000201510ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dlfcn.h" #include /* NULL */ #include /* strlen */ #include "bl_mem.h" /* alloca() */ #include static int ready_sym_table = 0; /* --- global functions --- */ bl_dl_handle_t bl_dl_open(const char *dirpath, const char *name) { lt_dlhandle handle; char *path; if (!ready_sym_table) { LTDL_SET_PRELOADED_SYMBOLS(); ready_sym_table = 1; } if (lt_dlinit()) { return NULL; } if ((path = alloca(strlen(dirpath) + strlen(name) + 4)) == NULL) { return NULL; } /* * libfoo -> foo */ sprintf(path, "%slib%s", dirpath, name); if ((handle = lt_dlopenext(path))) { return (bl_dl_handle_t)handle; } sprintf(path, "%s%s", dirpath, name); if ((handle = lt_dlopenext(path))) { return (bl_dl_handle_t)handle; } return NULL; } void bl_dl_close(bl_dl_handle_t handle) { lt_dlclose((lt_dlhandle)handle); lt_dlexit(); } void *bl_dl_func_symbol(bl_dl_handle_t handle, const char *symbol) { return lt_dlsym((lt_dlhandle)handle, symbol); } int bl_dl_is_module(const char *name) { size_t len; if (!name) { return 0; } if ((len = strlen(name)) < 3) { return 0; } if (strcmp(&name[len - 3], ".la") == 0) { return 1; } return 0; } mlterm-3.9.3/baselib/src/bl_dlfcn_none.c000066400000000000000000000006711441203364000201450ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dlfcn.h" #include /* NULL */ /* --- global functions --- */ /* * dummy codes */ bl_dl_handle_t bl_dl_open(const char *dirpath, const char *name) { return NULL; } void bl_dl_close(bl_dl_handle_t handle) {} void *bl_dl_func_symbol(bl_dl_handle_t handle, const char *symbol) { return NULL; } int bl_dl_is_module(const char *name) { return 0; } mlterm-3.9.3/baselib/src/bl_dlfcn_win32.c000066400000000000000000000047411441203364000201520ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_dlfcn.h" #include /* NULL */ #include /* strlen */ #include "bl_mem.h" /* alloca() */ #if defined(__CYGWIN__) || defined(__MSYS__) #include "bl_path.h" /* bl_conv_to_win32_path */ #endif #undef _WIN32_WINNT #define _WIN32_WINNT 0x0502 /* for SetDllDirectory */ #include #include /* SetDllDirectory */ /* --- static functions --- */ static int initialized; /* --- global functions --- */ bl_dl_handle_t bl_dl_open(const char *dirpath, const char *name) { HMODULE module; char *path; #if defined(__CYGWIN__) || defined(__MSYS__) /* MAX_PATH which is 260 (3+255+1+1) is defined in win32 alone. */ char winpath[MAX_PATH]; #endif #ifdef SetDllDirectory /* Defined in winbase.h as SetDllDirectoryA or \ SetDllDirectoryW */ if (!initialized) { SetDllDirectory(""); /* Don't load library at CWD. */ initialized = 1; } #endif if ((path = alloca(strlen(dirpath) + strlen(name) + 8)) == NULL) { return NULL; } #if defined(__CYGWIN__) sprintf(path, "%scyg%s.dll", dirpath, name); if (bl_conv_to_win32_path(path, winpath, sizeof(winpath)) < 0) { goto next_step; } path = winpath; #elif defined(__MSYS__) sprintf(path, "%slib%s.dll", dirpath, name); if (bl_conv_to_win32_path(path, winpath, sizeof(winpath)) < 0) { goto next_step; } path = winpath; #else sprintf(path, "%slib%s.dll", dirpath, name); if ((module = LoadLibraryA(path))) { return (bl_dl_handle_t)module; } /* Assume cygwin(-mno-cygwin) */ sprintf(path, "%scyg%s.dll", dirpath, name); #endif if ((module = LoadLibraryA(path))) { return (bl_dl_handle_t)module; } #if defined(__CYGWIN__) || defined(__MSYS__) next_step: sprintf(path, "%s%s.dll", dirpath, name); if (bl_conv_to_win32_path(path, winpath, sizeof(winpath)) < 0) { return NULL; } path = winpath; #else sprintf(path, "%s%s.dll", dirpath, name); #endif if ((module = LoadLibraryA(path))) { return (bl_dl_handle_t)module; } return NULL; } void bl_dl_close(bl_dl_handle_t handle) { FreeLibrary((HMODULE)handle); } void *bl_dl_func_symbol(bl_dl_handle_t handle, const char *symbol) { return GetProcAddress((HMODULE)handle, symbol); } int bl_dl_is_module(const char *name) { size_t len; if (!name) { return 0; } if ((len = strlen(name)) < 4) { return 0; } if (strcmp(&name[len - 4], ".dll") == 0) { return 1; } return 0; } mlterm-3.9.3/baselib/src/bl_file.c000066400000000000000000000112301441203364000167500ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_file.h" #include /* fcntl() */ #include /* flock() */ #include /* memcpy */ #include #include /* stat */ #include "bl_mem.h" /* malloc */ #include "bl_debug.h" #define BUF_UNIT_SIZE 512 /* --- global functions --- */ bl_file_t *bl_file_new(FILE* fp) { bl_file_t *file; if ((file = malloc(sizeof(bl_file_t))) == NULL) { return NULL; } file->file = fp; file->buffer = NULL; #ifndef HAVE_FGETLN file->buf_size = 0; #endif return file; } void bl_file_destroy(bl_file_t *file) { /* not fclose(file->fp) */ free(file->buffer); free(file); } bl_file_t *bl_file_open(const char *file_path, const char *mode) { FILE* fp; if ((fp = fopen(file_path, mode)) == NULL) { return NULL; } return bl_file_new(fp); } void bl_file_close(bl_file_t *file) { fclose(file->file); bl_file_destroy(file); } FILE* bl_fopen_with_mkdir(const char *file_path, const char *mode) { FILE* fp; char *p; if ((fp = fopen(file_path, mode))) { return fp; } if ((p = alloca(strlen(file_path) + 1)) == NULL || !bl_mkdir_for_file(strcpy(p, file_path), 0700)) { return NULL; } return fopen(file_path, mode); } #ifdef HAVE_FGETLN char *bl_file_get_line(bl_file_t *from, size_t *len) { char *line; if ((line = fgetln(from->file, len)) == NULL) { return NULL; } if (line[*len - 1] == '\n') { if (*len > 1 && line[*len - 2] == '\r') { (*len) -= 2; /* \r\n -> \0\n */ } else { (*len)--; /* \n -> \0 */ } } else { void *p; /* If 'line' doesn't end with '\n', append '\0' to it. */ if ((p = realloc(from->buffer, *len + 1)) == NULL) { return NULL; } line = memcpy((from->buffer = p), line, *len); } line[*len] = '\0'; return line; } #else /* * This behaves like fgetln(). * * This returns the pointer to the beginning of line , and it becomes invalid * after the next bl_file_get_line() (whether successful or not) or as soon as * bl_file_close() is executed. */ char *bl_file_get_line(bl_file_t *from, size_t *len) { size_t filled; int c; filled = 0; if ((c = fgetc(from->file)) < 0) { return NULL; } while (1) { if (filled == from->buf_size) { void *p; if ((p = realloc(from->buffer, from->buf_size + BUF_UNIT_SIZE)) == NULL) { return NULL; } from->buffer = p; from->buf_size += BUF_UNIT_SIZE; } if (c == '\n') { if (filled > 0 && from->buffer[filled - 1] == '\r') { filled--; } break; } else { from->buffer[filled++] = c; } if ((c = fgetc(from->file)) < 0) { break; } } from->buffer[filled] = '\0'; *len = filled; return from->buffer; } #endif #if defined(HAVE_FLOCK) && defined(LOCK_EX) && defined(LOCK_UN) int bl_file_lock(int fd) { if (flock(fd, LOCK_EX) == -1) { return 0; } else { return 1; } } int bl_file_unlock(int fd) { if (flock(fd, LOCK_UN) == -1) { return 0; } else { return 1; } } #else int bl_file_lock(int fd) { return 0; } int bl_file_unlock(int fd) { return 0; } #endif #ifdef F_GETFD int bl_file_set_cloexec(int fd) { int old_flags; old_flags = fcntl(fd, F_GETFD); if (old_flags == -1) { return 0; } if (!(old_flags & FD_CLOEXEC) && (fcntl(fd, F_SETFD, old_flags | FD_CLOEXEC) == -1)) { return 0; } return 1; } int bl_file_unset_cloexec(int fd) { int old_flags; old_flags = fcntl(fd, F_GETFD); if (old_flags == -1) { return 0; } if ((old_flags & FD_CLOEXEC) && (fcntl(fd, F_SETFD, old_flags & (~FD_CLOEXEC)) == -1)) { return 0; } return 1; } #else /* F_GETFD */ int bl_file_set_cloexec(int fd) { /* do nothing */ return 0; } int bl_file_unset_cloexec(int fd) { /* do nothing */ return 0; } #endif /* * /a/b/c => mkdir /a ; mkdir /a/b * /a/b/c/ => mkdir /a ; mkdir /a/b ; mkdir /a/b/c * /a => do nothing */ int bl_mkdir_for_file(char *file_path, /* Not const. Don't specify read only data. */ mode_t dir_mode) { char *p; p = file_path + 1; while (*p) { if (*p == '/' #ifdef USE_WIN32API || *p == '\\' #endif ) { struct stat s; char c; c = *p; /* save */ *p = '\0'; if (stat(file_path, &s) != 0) { if (errno == ENOENT && #ifdef USE_WIN32API mkdir(file_path) != 0 #else mkdir(file_path, dir_mode) != 0 #endif ) { bl_msg_printf("Failed to mkdir %s\n", file_path); *p = c; /* restore */ return 0; } } *p = c; /* restore */ } p++; } return 1; } mlterm-3.9.3/baselib/src/bl_file.h000066400000000000000000000014561441203364000167660ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_FILE_H__ #define __BL_FILE_H__ #include #include "bl_types.h" /* size_t */ #include "bl_def.h" /* HAVE_FGETLN */ typedef struct bl_file { FILE* file; char *buffer; #ifndef HAVE_FGETLN size_t buf_size; #endif } bl_file_t; bl_file_t *bl_file_new(FILE* fp); void bl_file_destroy(bl_file_t *file); bl_file_t *bl_file_open(const char *file_path, const char *mode); void bl_file_close(bl_file_t *file); FILE* bl_fopen_with_mkdir(const char *file_path, const char *mode); char *bl_file_get_line(bl_file_t *from, size_t *len); int bl_file_lock(int fd); int bl_file_unlock(int fd); int bl_file_set_cloexec(int fd); int bl_file_unset_cloexec(int fd); int bl_mkdir_for_file(char *file_path, mode_t mode); #endif mlterm-3.9.3/baselib/src/bl_langinfo.c000066400000000000000000000003561441203364000176350ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_langinfo.h" #ifdef USE_BUILTIN_LANGINFO /* --- global functions --- */ char* __bl_langinfo(nl_item item) { return ""; } #endif /* USE_BUILTIN_LANGINFO */ mlterm-3.9.3/baselib/src/bl_langinfo.h000066400000000000000000000027641441203364000176470ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_LANGINFO_H__ #define __BL_LANGINFO_H__ #include "bl_def.h" #ifdef HAVE_LANGINFO_H #include #endif #ifdef CODESET #define bl_langinfo(item) nl_langinfo(item) #else /* CODESET */ /* * same as NetBSD 1.5 langinfo.h (revision 1.5) */ typedef long nl_item; #define D_T_FMT 0 #define D_FMT 1 #define T_FMT 2 #define T_FMT_AMPM 3 #define AM_STR 4 #define PM_STR 5 #define DAY_1 6 #define DAY_2 7 #define DAY_3 8 #define DAY_4 9 #define DAY_5 10 #define DAY_6 11 #define DAY_7 12 #define ABDAY_1 13 #define ABDAY_2 14 #define ABDAY_3 15 #define ABDAY_4 16 #define ABDAY_1 13 #define ABDAY_2 14 #define ABDAY_3 15 #define ABDAY_4 16 #define ABDAY_5 17 #define ABDAY_6 18 #define ABDAY_7 19 #define MON_1 20 #define MON_2 21 #define MON_3 22 #define MON_4 23 #define MON_5 24 #define MON_6 25 #define MON_7 26 #define MON_8 27 #define MON_9 28 #define MON_10 29 #define MON_11 30 #define MON_12 31 #define ABMON_1 32 #define ABMON_2 33 #define ABMON_3 34 #define ABMON_4 35 #define ABMON_5 36 #define ABMON_6 37 #define ABMON_7 38 #define ABMON_8 39 #define ABMON_9 40 #define ABMON_10 41 #define ABMON_11 42 #define ABMON_12 43 #define RADIXCHAR 44 #define THOUSEP 45 #define YESSTR 46 #define YESEXPR 47 #define NOSTR 48 #define NOEXPR 49 #define CRNCYSTR 50 #define CODESET 51 #define USE_BUILTIN_LANGINFO #define bl_langinfo(item) __bl_langinfo(item) char *__bl_langinfo(nl_item item); #endif /* CODESET */ #endif mlterm-3.9.3/baselib/src/bl_locale.c000066400000000000000000000147401441203364000173010ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_locale.h" #include /* sprintf */ #include /* setlocale() */ /* for bl_get_codeset_win32() */ #ifdef HAVE_WINDOWS_H #include #endif #include "bl_langinfo.h" /* bl_langinfo() */ #include "bl_debug.h" #include "bl_mem.h" /* alloca */ #include "bl_str.h" #include "bl_util.h" /* BL_MIN */ #if 0 #define __DEBUG #endif typedef struct lang_codeset_table { char *lang; char *codeset; } lang_codeset_table_t; typedef struct alias_codeset_table { char *codeset; char *locale; char *alias; } alias_codeset_table_t; /* --- static variables --- */ static char *sys_locale = NULL; static char *sys_lang = NULL; static char *sys_country = NULL; static char *sys_codeset = NULL; /* for sys_lang and sys_country memory */ static char *sys_lang_country = NULL; #ifndef USE_WIN32API static lang_codeset_table_t lang_codeset_table[] = { { "en", "ISO8859-1", }, { "da", "ISO8859-1", }, { "de", "ISO8859-1", }, { "fi", "ISO8859-1", }, { "fr", "ISO8859-1", }, { "is", "ISO8859-1", }, { "it", "ISO8859-1", }, { "nl", "ISO8859-1", }, { "no", "ISO8859-1", }, { "pt", "ISO8859-1", }, { "sv", "ISO8859-1", }, { "cs", "ISO8859-2", }, { "hr", "ISO8859-2", }, { "hu", "ISO8859-2", }, { "la", "ISO8859-2", }, { "lt", "ISO8859-2", }, { "pl", "ISO8859-2", }, { "sl", "ISO8859-2", }, { "el", "ISO8859-7", }, { "ru", "KOI8-R", }, { "uk", "KOI8-U", }, { "vi", "VISCII", }, { "th", "TIS-620", }, { "ja", "eucJP", }, { "ko", "eucKR", }, { "zh_CN", "eucCN", }, { "zh_TW", "Big5", }, { "zh_HK", "Big5HKSCS", }, }; #endif static alias_codeset_table_t alias_codeset_table[] = { { "EUC", "ja_JP.EUC", "eucJP", }, { "EUC", "ko_KR.EUC", "eucKR", }, }; /* --- global functions --- */ int bl_locale_init(const char *locale) { char *locale_p; int result; if (sys_locale && locale && strcmp(locale, sys_locale) == 0) { return 1; } if ((locale = setlocale(LC_CTYPE, locale)) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " setlocale() failed.\n"); #endif if (sys_locale) { /* restoring locale info. nothing is changed. */ setlocale(LC_CTYPE, sys_locale); return 0; } else if ((locale = getenv("LC_ALL")) == NULL && (locale = getenv("LC_CTYPE")) == NULL && (locale = getenv("LANG")) == NULL) { /* nothing is changed */ return 0; } result = 0; } else { result = 1; } if (sys_locale) { free(sys_locale); sys_locale = NULL; } if (sys_lang_country) { free(sys_lang_country); sys_lang_country = NULL; } /* * If external library calls setlocale(), this 'locale' variable * can be free'ed, so strdup() shoule be called. */ sys_locale = strdup(locale); if ((locale_p = sys_lang_country = strdup(locale)) == NULL) { sys_locale = NULL; return 0; } if ((sys_lang = bl_str_sep(&locale_p, "_")) == NULL) { /* this never happends */ return 0; } sys_country = bl_str_sep(&locale_p, "."); sys_codeset = bl_langinfo(CODESET); if (strcmp(sys_codeset, "") == 0) { if (locale_p && *locale_p) { sys_codeset = locale_p; } else { sys_codeset = NULL; } } if (sys_codeset) { /* * normalizing codeset name. */ int count; for (count = 0; count < BL_ARRAY_SIZE(alias_codeset_table); count++) { if (strcmp(sys_codeset, alias_codeset_table[count].codeset) == 0 && strcmp(locale, alias_codeset_table[count].locale) == 0) { sys_codeset = alias_codeset_table[count].alias; break; } } } #ifdef __DEBUG bl_debug_printf("locale setttings -> locale %s lang %s country %s codeset %s\n", sys_locale, sys_lang, sys_country, sys_codeset); #endif return result; } void bl_locale_final(void) { if (sys_locale) { free(sys_locale); sys_locale = NULL; } if (sys_lang_country) { free(sys_lang_country); sys_lang_country = NULL; } } char *bl_get_locale(void) { if (sys_locale) { return sys_locale; } else { return "C"; } } char *bl_get_lang(void) { if (sys_lang) { return sys_lang; } else { return "en"; } } char *bl_get_country(void) { if (sys_country) { return sys_country; } else { return "US"; } } #ifndef USE_WIN32API char *bl_get_codeset(void) { if (sys_codeset) { return sys_codeset; } else if (sys_lang) { int count; char *lang; u_int lang_len; lang_len = strlen(sys_lang) + 1; if (sys_country) { /* "+ 1" is for '_' */ lang_len += strlen(sys_country) + 1; } if ((lang = alloca(lang_len)) == NULL) { return "ISO8859-1"; } if (sys_country) { sprintf(lang, "%s_%s", sys_lang, sys_country); } else { sprintf(lang, "%s", sys_lang); } #ifdef __DEBUG bl_debug_printf("lang -> %s\n", lang); #endif for (count = 0; count < BL_ARRAY_SIZE(lang_codeset_table); count++) { if (strncmp(lang, lang_codeset_table[count].lang, /* lang_len *- 1* is excluing NULL */ BL_MIN(lang_len - 1, strlen(lang_codeset_table[count].lang))) == 0) { return lang_codeset_table[count].codeset; } } } return "ISO8859-1"; } #endif /* USE_WIN32API */ #ifdef HAVE_WINDOWS_H typedef struct cp_cs_table { int codepage; char *codeset; } cp_cs_table_t; static cp_cs_table_t cp_cs_table[] = { { 1250, "CP1250", }, /* EastEurope_CHARSET */ { 1251, "CP1251", }, /* RUSSIAN_CHARSET */ { 1252, "CP1252", }, /* ANSI_CHARSET */ { 1253, "CP1253", }, /* GREEK_CHARSET */ { 1254, "CP1254", }, /* TURKISH_CHARSET */ { 1255, "CP1255", }, /* HEBREW_CHARSET */ { 1256, "CP1256", }, /* ARABIC_CHARSET */ { 1257, "CP1257", }, /* BALTIC_CHARSET */ { 1258, "CP1258", }, /* VIETNAMESE_CHARSET */ { 874, "ISO8859-11", }, /* THAI_CHARSET XXX CP874 is extended from ISO8859-11 */ { 932, "SJIS", }, /* SHIFTJIS_CHARSET */ { 936, "GBK", }, /* GB2313_CHARSET */ { 949, "UHC", }, /* HANGEUL_CHARSET */ { 950, "BIG5", }, /* CHINESEBIG5_CHARSET */ }; char *bl_get_codeset_win32(void) { int count; int codepage; codepage = GetACP(); for (count = 0; count < BL_ARRAY_SIZE(cp_cs_table); count++) { if (cp_cs_table[count].codepage == codepage) { return cp_cs_table[count].codeset; } } return "ISO8859-1"; } #endif /* HAVE_WINDOWS_H */ mlterm-3.9.3/baselib/src/bl_locale.h000066400000000000000000000012601441203364000172770ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_LOCALE_H__ #define __BL_LOCALE_H__ #include "bl_def.h" /* HAVE_WINDOWS_H */ int bl_locale_init(const char *locale); void bl_locale_final(void); char *bl_get_locale(void); /* * lang/country/codeset are decided as below , not decided only by setlocale(). * Be careful to use them. * * * setlocale() (=> nl_langinfo(CODESET)) => LC_ALL => LC_CTYPE => LANG */ char *bl_get_lang(void); char *bl_get_country(void); #ifdef USE_WIN32API #define bl_get_codeset bl_get_codeset_win32 #else char *bl_get_codeset(void); #endif #ifdef HAVE_WINDOWS_H char *bl_get_codeset_win32(void); #endif #endif mlterm-3.9.3/baselib/src/bl_map.c000066400000000000000000000047331441203364000166200ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_map.h" #include /* strcmp */ #include "bl_util.h" /* BL_ARRAY_SIZE */ /* --- global functions --- */ int bl_map_rehash(int hash_key, u_int size) { if (++hash_key >= size) { return 0; } else { return hash_key; } } int bl_map_hash_str(char *key, u_int size) { int hash_key; hash_key = 0; while (*key) { hash_key += *key++; } return hash_key % size; } int bl_map_hash_int(int key, u_int size) { return key % size; } int bl_map_hash_int_fast(int key, u_int size /* == 2^n */ ) { return key & (size - 1); } int bl_map_compare_str(char *key1, char *key2) { return (strcmp(key1, key2) == 0); } int bl_map_compare_str_nocase(char *key1, char *key2) { return (strcasecmp(key1, key2) == 0); } int bl_map_compare_int(int key1, int key2) { return (key1 == key2); } #ifdef BL_DEBUG #include #undef DEFAULT_MAP_SIZE #define DEFAULT_MAP_SIZE 4 #undef MAP_MARGIN_SIZE #define MAP_MARGIN_SIZE 2 BL_MAP_TYPEDEF(test, int, char *); void TEST_bl_map(void) { BL_MAP(test) map; BL_PAIR(test) pair; BL_PAIR(test) * array; u_int size; int result; int key; char *table[] = { "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", }; bl_map_new_with_size(int, char *, map, bl_map_hash_int, bl_map_compare_int, DEFAULT_MAP_SIZE); for (key = 0; key < BL_ARRAY_SIZE(table); key++) { bl_map_set(result, map, key * 3, table[key]); } assert(map->map_size == ((BL_ARRAY_SIZE(table) + MAP_MARGIN_SIZE + DEFAULT_MAP_SIZE - 1) / DEFAULT_MAP_SIZE) * DEFAULT_MAP_SIZE); /* 16 */ assert(map->filled_size == BL_ARRAY_SIZE(table)); for (key = 0; key < BL_ARRAY_SIZE(table); key++) { bl_map_get(map, key * 3, pair); assert(strcmp(table[key], pair->value) == 0); } for (key = 0; key < BL_ARRAY_SIZE(table) - 2; key++) { bl_map_erase(result, map, key * 3); } assert(map->map_size == 8); assert(map->filled_size == 2); for (key = 0; key < BL_ARRAY_SIZE(table); key++) { bl_map_get(map, key * 3, pair); if (key >= BL_ARRAY_SIZE(table) - 2) { assert(strcmp(table[key], pair->value) == 0); } else { assert(pair == NULL); } } bl_map_get_pairs_array(map, array, size); for (key = 0; key < size; key++) { assert(strcmp(table[key + BL_ARRAY_SIZE(table) - 2], array[key]->value) == 0); } bl_map_destroy(map); bl_msg_printf("PASS bl_map test.\n"); } #endif mlterm-3.9.3/baselib/src/bl_map.h000066400000000000000000000564221441203364000166270ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_MAP_H__ #define __BL_MAP_H__ #include /* memset */ #include "bl_types.h" /* size_t */ #include "bl_debug.h" #include "bl_mem.h" #define DEFAULT_MAP_SIZE 16 #define MAP_MARGIN_SIZE 2 #define BL_PAIR(name) __##name##_pair_t #define BL_PAIR_TYPEDEF(name, key_type, val_type) \ typedef struct __##name##_pair { \ int is_filled; \ key_type key; \ val_type value; \ \ } * __##name##_pair_t #define BL_MAP(name) __##name##_map_t #define BL_MAP_TYPEDEF(name, key_type, val_type) \ BL_PAIR_TYPEDEF(name, key_type, val_type); \ typedef struct __##name##_map { \ BL_PAIR(name) pairs; \ BL_PAIR(name) * pairs_array; \ u_int map_size; \ u_int filled_size; \ int (*hash_func)(key_type, u_int); \ int (*compare_func)(key_type, key_type); \ \ } * __##name##_map_t #define bl_map_new_with_size(key_type, val_type, map, __hash_func, __compare_func, size) \ { \ if ((map = malloc(sizeof(*(map)))) == NULL || \ ((map)->pairs = calloc(size, sizeof(*(map)->pairs))) == NULL) { \ bl_error_printf("malloc() failed in bl_map_new().\n"); \ abort(); \ } \ \ (map)->pairs_array = NULL; \ (map)->map_size = size; \ (map)->filled_size = 0; \ if ((int (*)(int, u_int))__hash_func == bl_map_hash_int) { \ if (size & (size - 1)) { \ (map)->hash_func = (int (*)(key_type, u_int))bl_map_hash_int; \ } else { \ /* new_size == 2^n */ \ (map)->hash_func = (int (*)(key_type, u_int))bl_map_hash_int_fast; \ } \ } else { \ (map)->hash_func = (int (*)(key_type, u_int))__hash_func; \ } \ (map)->compare_func = (int (*)(key_type, key_type))__compare_func; \ } #define bl_map_new(key_type, val_type, map, __hash_func, __compare_func) \ bl_map_new_with_size(key_type, val_type, map, __hash_func, __compare_func, DEFAULT_MAP_SIZE) /* * the deletion of pair->key/pair->value should be done by users of bl_map. */ #define bl_map_destroy(map) \ { \ free((map)->pairs); \ free((map)->pairs_array); \ free(map); \ } #define bl_map_get(map, __key, __pair_p) \ { \ u_int filled_size; \ \ __pair_p = NULL; \ \ if ((filled_size = (map)->filled_size) > 0) { \ int __hash_key; \ \ __hash_key = (*(map)->hash_func)(__key, (map)->map_size); \ do { \ if ((map)->pairs[__hash_key].is_filled) { \ if ((*(map)->compare_func)(__key, (map)->pairs[__hash_key].key)) { \ __pair_p = &(map)->pairs[__hash_key]; \ \ break; \ } \ \ filled_size--; \ } \ \ __hash_key = bl_map_rehash(__hash_key, (map)->map_size); \ } while (filled_size > 0); \ } \ \ if (0 && __pair_p) { \ bl_msg_printf("Found key in %d times\n", (map)->filled_size - filled_size + 1); \ } \ } #if 0 #define bl_map_dump_size(map_size, new_size) \ bl_debug_printf("reallocating map size from %d to %d.\n", map_size, new_size) #else #define bl_map_dump_size(map_size, new_size) #endif #define bl_map_set(result, map, __key, __value) \ { \ int __hash_key; \ u_int __count; \ \ result = 0; \ \ if ((map)->map_size == (map)->filled_size + MAP_MARGIN_SIZE) { \ /* \ * Expanding map by DEFAULT_MAP_SIZE \ */ \ \ u_int __new_size; \ void* __new; \ \ __new_size = (map)->map_size + DEFAULT_MAP_SIZE; \ \ bl_map_dump_size((map)->map_size, __new_size); \ \ if ((__new = calloc(__new_size, sizeof(*(map)->pairs)))) { \ void* __old; \ \ __old = (map)->pairs; \ \ if ((int (*)(int, u_int))(map)->hash_func == bl_map_hash_int || \ (int (*)(int, u_int))(map)->hash_func == bl_map_hash_int_fast) { \ if (__new_size & (__new_size - 1)) { \ /* XXX int (*)() should be int (*)(key_type, u_int) */ \ (map)->hash_func = (int (*)())bl_map_hash_int; \ } else { \ /* __new_size == 2^n */ \ /* XXX int (*)() should be int (*)(key_type, u_int) */ \ (map)->hash_func = (int (*)())bl_map_hash_int_fast; \ } \ } \ \ /* reconstruct (map)->pairs since map_size is changed. */ \ for (__count = 0; __count < (map)->map_size; __count++) { \ if ((map)->pairs[__count].is_filled) { \ void *dst; \ \ __hash_key = (*(map)->hash_func)((map)->pairs[__count].key, __new_size); \ \ (map)->pairs = __new; \ while ((map)->pairs[__hash_key].is_filled) { \ __hash_key = bl_map_rehash(__hash_key, __new_size); \ } \ \ dst = &(map)->pairs[__hash_key]; \ (map)->pairs = __old; \ memcpy(dst, &(map)->pairs[__count], sizeof(*(map)->pairs)); \ } \ } \ \ free(__old); \ (map)->pairs = __new; \ (map)->map_size = __new_size; \ } \ } \ \ __hash_key = (*(map)->hash_func)(__key, (map)->map_size); \ for (__count = 0; __count < (map)->map_size; __count++) { \ if (!(map)->pairs[__hash_key].is_filled) { \ (map)->pairs[__hash_key].key = __key; \ (map)->pairs[__hash_key].value = __value; \ (map)->pairs[__hash_key].is_filled = 1; \ (map)->filled_size++; \ \ free((map)->pairs_array); \ (map)->pairs_array = NULL; \ \ result = 1; \ \ break; \ } \ \ __hash_key = bl_map_rehash(__hash_key, (map)->map_size); \ } \ } #define __bl_map_erase_simple(result, map, __key) \ int __hash_key; \ u_int __count; \ \ result = 0; \ \ __hash_key = (*(map)->hash_func)(__key, (map)->map_size); \ for (__count = 0; __count < (map)->map_size; __count++) { \ if ((map)->pairs[__hash_key].is_filled && \ (*(map)->compare_func)(__key, (map)->pairs[__hash_key].key)) { \ (map)->pairs[__hash_key].is_filled = 0; \ (map)->filled_size--; \ \ free((map)->pairs_array); \ (map)->pairs_array = NULL; \ \ result = 1; \ \ break; \ } \ \ __hash_key = bl_map_rehash(__hash_key, (map)->map_size); \ } /* * Not shrink map. */ #define bl_map_erase_simple(result, map, __key) \ { __bl_map_erase_simple(result, map, __key); } /* * Shrink map. */ #define bl_map_erase(result, map, __key) \ { \ __bl_map_erase_simple(result, map, __key); \ \ /* \ * __hash_key and __count are declared in __bl_map_erase_simple(). \ */ \ \ if (result == 1 && /* \ * if (map)->filled_size is (DEFAULT_MAP_SIZE * 2) \ * smaller than the map size , \ * the map size is (DEFAULT_MAP_SIZE) shrinked. \ * the difference(DEFAULT_MAP_SIZE) is buffered to \ * reduce calling realloc(). \ */ \ (map)->filled_size + (DEFAULT_MAP_SIZE * 2) < (map)->map_size) { \ /* \ * shrinking map by DEFAULT_MAP_SIZE \ */ \ \ u_int __new_size; \ void* __old; \ void* __new; \ u_int __count; \ \ __new_size = (map)->map_size - DEFAULT_MAP_SIZE; \ \ bl_map_dump_size((map)->map_size, __new_size); \ \ if ((__new = calloc(__new_size, sizeof(*(map)->pairs)))) { \ __old = (map)->pairs; \ \ if ((int (*)(int, u_int))(map)->hash_func == bl_map_hash_int || \ (int (*)(int, u_int))(map)->hash_func == bl_map_hash_int_fast) { \ if (__new_size & (__new_size - 1)) { \ /* XXX int (*)() should be int (*)(key_type, u_int) */ \ (map)->hash_func = (int (*)())bl_map_hash_int; \ } else { \ /* __new_size == 2^n */ \ /* XXX int (*)() should be int (*)(key_type, u_int) */ \ (map)->hash_func = (int (*)())bl_map_hash_int_fast; \ } \ } \ \ /* reconstruct (map)->pairs since map_size is changed. */ \ for (__count = 0; __count < (map)->map_size; __count++) { \ if ((map)->pairs[__count].is_filled) { \ void *dst; \ \ __hash_key = (*(map)->hash_func)((map)->pairs[__count].key, __new_size); \ \ (map)->pairs = __new; \ while ((map)->pairs[__hash_key].is_filled) { \ __hash_key = bl_map_rehash(__hash_key, __new_size); \ } \ \ dst = &(map)->pairs[__hash_key]; \ (map)->pairs = __old; \ memcpy(dst, &(map)->pairs[__count], sizeof(*(map)->pairs)); \ } \ } \ \ free(__old); \ (map)->pairs = __new; \ (map)->map_size = __new_size; \ } \ } \ } #define bl_map_get_pairs_array(map, array, size) \ { \ size = (map)->filled_size; \ \ if ((array = (map)->pairs_array) == NULL) { \ if ((array = calloc(size, sizeof(void*))) == NULL) { \ size = 0; \ } else { \ int __array_count; \ u_int __count; \ \ __array_count = 0; \ for (__count = 0; __count < (map)->map_size; __count++) { \ if ((map)->pairs[__count].is_filled) { \ array[__array_count++] = &(map)->pairs[__count]; \ } \ } \ } \ \ (map)->pairs_array = array; \ } \ } int bl_map_rehash(int hash_key, u_int size); /* * preparing useful hash functions. */ int bl_map_hash_str(char *key, u_int size); int bl_map_hash_int(int key, u_int size); int bl_map_hash_int_fast(int key, u_int size); /* * preparing useful compare functions. */ int bl_map_compare_str(char *key1, char *key2); int bl_map_compare_str_nocase(char *key1, char *key2); int bl_map_compare_int(int key1, int key2); #endif mlterm-3.9.3/baselib/src/bl_mem.c000066400000000000000000000227001441203364000166130ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* * !! Notice !! * don't use other bl_xxx functions(macros may be ok) as much as possible since * they may use * these memory management functions. */ #include "bl_mem.h" #include /* fprintf */ #include /* memset */ #include "bl_slist.h" #if 0 #define __DEBUG #endif #ifndef CONCATABLE_FUNCTION #define __FUNCTION__ "" #endif #ifndef HAVE_ALLOCA #define ALLOCA_PAGE_UNIT_SIZE 4096 #define MAX_STACK_FRAMES 10 typedef struct alloca_page { void *ptr; size_t size; size_t used_size; struct alloca_page *prev_page; } alloca_page_t; /* --- static variables --- */ static size_t total_allocated_size = 0; static alloca_page_t *alloca_page; static int stack_frame_bases[MAX_STACK_FRAMES]; static int current_stack_frame = 0; /* --- global functions --- */ void *bl_alloca(size_t size) { void *ptr; /* arranging bytes boundary */ size = ((size + sizeof(char *) - 1) / sizeof(char *)) * sizeof(char *); if (alloca_page == NULL || alloca_page->used_size + size > alloca_page->size) { alloca_page_t *new_page; if ((new_page = malloc(sizeof(alloca_page_t))) == NULL) { return NULL; } new_page->size = ((size / ALLOCA_PAGE_UNIT_SIZE) + 1) * ALLOCA_PAGE_UNIT_SIZE; new_page->used_size = 0; if ((new_page->ptr = malloc(new_page->size)) == NULL) { free(new_page); return NULL; } #ifdef DEBUG memset(new_page->ptr, 0xff, new_page->size); #endif #ifdef __DEBUG fprintf(stderr, "Create new page(size %d).\n", new_page->size); #endif new_page->prev_page = alloca_page; alloca_page = new_page; } /* operations of void * cannot be done in some operating systems */ ptr = (char *)alloca_page->ptr + alloca_page->used_size; alloca_page->used_size += size; total_allocated_size += size; #ifdef __DEBUG fprintf(stderr, "alloca %p(size %d).\n", ptr, size); #endif return ptr; } int bl_alloca_begin_stack_frame(void) { if (alloca_page == NULL) { /* no page is found. curent_stack_frame == 0. */ return 1; } /* stack_frame_bases[0] is always 0. */ current_stack_frame++; if (current_stack_frame >= MAX_STACK_FRAMES) { #ifdef __DEBUG fprintf(stderr, "Failed to create a new stack frame.\n"); #endif return 0; } stack_frame_bases[current_stack_frame] = total_allocated_size; #ifdef __DEBUG fprintf(stderr, "Create %d stack frame (at %d).\n", current_stack_frame, stack_frame_bases[current_stack_frame]); #endif return 1; } void bl_alloca_end_stack_frame(void) { if (alloca_page == NULL) { /* no page is found */ return; } /* if (current_stack_frame < MAX_STACK_FRAMES) */ { size_t shrink_size; alloca_page_t *page; #ifdef __DEBUG fprintf(stderr, "Delete %d stack frame (at %d size %d).\n", current_stack_frame, stack_frame_bases[current_stack_frame], total_allocated_size - stack_frame_bases[current_stack_frame]); #endif shrink_size = total_allocated_size - stack_frame_bases[current_stack_frame]; page = alloca_page; while (shrink_size > page->used_size) { alloca_page_t *_page; if ((_page = page->prev_page) == NULL) { #ifdef DEBUG fprintf(stderr, "*** ERROR *** page link list is corrupt.\n"); #endif /* XXX so as not to cause segfault */ shrink_size = page->used_size; break; } shrink_size -= page->used_size; #ifdef __DEBUG fprintf(stderr, "Delete page(size %d).\n", page->size); #endif free(page->ptr); free(page); page = _page; } /* Don't free the first frame. */ alloca_page = page; alloca_page->used_size -= shrink_size; total_allocated_size = stack_frame_bases[current_stack_frame]; if (current_stack_frame > 0) { current_stack_frame--; } } } void bl_alloca_garbage_collect(void) { alloca_page_t *page; #ifdef __DEBUG fprintf(stderr, "allocated memory(size %d) for alloca() is discarded.\n", total_allocated_size); #endif page = alloca_page; while (page) { alloca_page_t *_page; _page = page->prev_page; free(page->ptr); free(page); page = _page; } alloca_page = NULL; total_allocated_size = 0; current_stack_frame = 0; } #endif /* HAVE_ALLOCA */ #undef malloc #undef calloc #undef realloc #undef free #undef bl_mem_free_all typedef struct mem_log { void *ptr; size_t size; const char *file; int line; const char *func; struct mem_log *next; } mem_log_t; /* --- static variables --- */ static mem_log_t *mem_logs = NULL; /* --- static functions --- */ static mem_log_t *search_mem_log(void *ptr) { mem_log_t *log; log = mem_logs; while (log) { if (log->ptr == ptr) { return log; } log = bl_slist_next(log); } return NULL; } /* --- global functions --- */ void *bl_mem_malloc(size_t size, const char *file, /* should be allocated memory. */ int line, const char *func /* should be allocated memory. */ ) { mem_log_t *log; if ((log = malloc(sizeof(mem_log_t))) == NULL) { return NULL; } if ((log->ptr = malloc(size)) == NULL) { free(log); return NULL; } memset(log->ptr, 0xff, size); log->size = size; log->file = file; log->line = line; log->func = func; bl_slist_insert_head(mem_logs, log); #ifdef __DEBUG fprintf(stderr, " memory %p(size %d) was successfully allocated at %s(l.%d in %s), " "logged in %p.\n", log->ptr, log->size, log->func, log->line, log->file, log); #endif return log->ptr; } void *bl_mem_calloc(size_t number, size_t size, const char *file, /* should be allocated memory. If NULL, not logged. */ int line, const char *func /* should be allocated memory. */ ) { void *ptr; size_t total_size; total_size = number * size; if (number && size && !total_size) { /* integer overflow */ return NULL; } if (total_size && (total_size / number != size)) { /* integer overflow */ return NULL; } if (file == NULL) { ptr = malloc(total_size); } else { ptr = bl_mem_malloc(total_size, file, line, func); } if (ptr) { memset(ptr, 0, total_size); } return ptr; } void bl_mem_remove(void *ptr, const char *file, /* should be allocated memory. */ int line, const char *func /* should be allocated memory. */ ) { if (ptr) { mem_log_t *log; if ((log = search_mem_log(ptr)) == NULL) { #ifdef DEBUG fprintf(stderr, " %p is freed at %s[l.%d in %s] but not logged.\n", ptr, func, line, file); #endif } else { #ifdef __DEBUG fprintf(stderr, " %p(size %d, alloced at %s[l.%d in %s] and freed at" " %s[l.%d in %s] logged in %p) was successfully freed.\n", ptr, log->size, log->func, log->line, log->file, file, line, func, log); #endif bl_slist_remove(mem_logs, log); memset(ptr, 0xff, log->size); free(log); } } } void bl_mem_free(void *ptr, const char *file, /* should be allocated memory. */ int line, const char *func /* should be allocated memory. */ ) { bl_mem_remove(ptr, file, line, func); free(ptr); } void *bl_mem_realloc(void *ptr, size_t size, const char *file, /* should be allocated memory. */ int line, const char *func /* should be allocated memory. */ ) { void *new_ptr; mem_log_t *log; if (ptr == NULL) { return bl_mem_malloc(size, file, line, func); } if ((log = search_mem_log(ptr)) == NULL) { #ifdef DEBUG fprintf(stderr, " %p is reallocated at %s[l.%d in %s] but not logged.\n", ptr, func, line, file); #endif return realloc(ptr, size); } /* * allocate new memory. */ if ((new_ptr = bl_mem_malloc(size, file, line, func)) == NULL) { return NULL; } if (log->size < size) { memcpy(new_ptr, ptr, log->size); } else { memcpy(new_ptr, ptr, size); } /* * free old memory. */ bl_mem_free(ptr, __FILE__, __LINE__, __FUNCTION__); return new_ptr; } void bl_mem_dump_all(void) { mem_log_t *log; log = mem_logs; while (log) { fprintf(stderr, "%p: ", log); fprintf(stderr, "%p(size %d , alloced at %s[l.%d in %s] is allocated.\n", log->ptr, (int)log->size, log->func, log->line, log->file); log = bl_slist_next(log); } } int bl_mem_free_all(void) { mem_log_t *log; if ((log = mem_logs)) { mem_log_t *prev; do { fprintf(stderr, "%p: ", log); fprintf(stderr, "%p(size %d, alloced at %s[l.%d in %s] is not freed.\n", log->ptr, (int)log->size, log->func, log->line, log->file); #if 1 fprintf(stderr, " [%s]\n", log->ptr); #endif free(log->ptr); log = bl_slist_next((prev = log)); free(prev); } while (log); mem_logs = NULL; return 0; } else { #ifdef __DEBUG fprintf(stderr, "YOUR MEMORY MANAGEMENT IS PERFECT!"); #endif return 1; } } #ifdef __DEBUG int main(int argc, char **argv) { u_int count; for (count = 0; count < 2; count++) { bl_alloca_begin_stack_frame(); memset(bl_alloca(4096), 0xff, 4096); memset(bl_alloca(4096), 0xff, 4096); memset(bl_alloca(4096), 0xff, 4096); bl_alloca_end_stack_frame(); } fprintf(stderr, "===> Dump before garbage collect\n"); bl_mem_dump_all(); bl_alloca_garbage_collect(); fprintf(stderr, "===> Dump after garbage collect\n"); bl_mem_dump_all(); return 0; } #endif mlterm-3.9.3/baselib/src/bl_mem.h000066400000000000000000000051401441203364000166170ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_MEM_H__ #define __BL_MEM_H__ #include #include "bl_types.h" /* size_t */ #include "bl_def.h" #if defined(BL_DEBUG) #define malloc(size) bl_mem_malloc(size, __FILE__, __LINE__, __FUNCTION__) #define calloc(number, size) bl_mem_calloc(number, size, __FILE__, __LINE__, __FUNCTION__) #define realloc(ptr, size) bl_mem_realloc(ptr, size, __FILE__, __LINE__, __FUNCTION__) #define free(ptr) bl_mem_free(ptr, __FILE__, __LINE__, __FUNCTION__) #elif !defined(CALLOC_CHECK_OVERFLOW) /* * In some environment (where CALLOC_CHECK_OVERFLOW is not defined by configure * script), * calloc doesn't check if number*size is over sizeof(size_t). */ #define calloc(number, size) bl_mem_calloc(number, size, NULL, 0, NULL) #endif void *bl_mem_malloc(size_t size, const char *file, int line, const char *func); void *bl_mem_calloc(size_t number, size_t size, const char *file, int line, const char *func); void *bl_mem_realloc(void *ptr, size_t size, const char *file, int line, const char *func); void bl_mem_remove(void *ptr, const char *file, int line, const char *func); void bl_mem_free(void *ptr, const char *file, int line, const char *func); #ifdef BL_DEBUG void bl_mem_dump_all(void); int bl_mem_free_all(void); #else #define bl_mem_free_all() #endif #ifndef HAVE_ALLOCA #undef alloca #ifdef BL_DEBUG #include /* memset */ #define alloca(size) memset(bl_alloca(size), 0xff, size) #else #define alloca(size) bl_alloca(size) #endif void *bl_alloca(size_t size); int bl_alloca_begin_stack_frame(void); void bl_alloca_end_stack_frame(void); void bl_alloca_garbage_collect(void); #else /* HAVE_ALLOCA */ #define bl_alloca_begin_stack_frame() 1 #define bl_alloca_end_stack_frame() 1 #define bl_alloca_garbage_collect() 1 /* If glib/galloca.h has been already included, following hack is disabled. */ #ifndef __G_ALLOCA_H__ /* AIX requires this to be the first thing in the file. */ #ifndef __GNUC__ #ifdef HAVE_ALLOCA_H #include #else /* HAVE_ALLOCA_H */ #ifdef _AIX #pragma alloca #else /* _AIX */ /* predefined by HP cc +Olibcalls */ #ifndef alloca char *alloca(); #endif #endif /* _AIX */ #endif /* HAVE_ALLOCA_H */ #else /* __GNUC__ */ #ifdef BL_DEBUG /* This debug hack can be available in GNUC alone. */ #undef alloca #include /* memset */ #define alloca(size) memset(alloca(size), 0xff, size) #else /* BL_DEBUG */ #ifdef HAVE_ALLOCA_H #include #endif /* HAVE_ALLOCA_H */ #endif /* BL_DEBUG */ #endif /* __GNUC__ */ #endif /* __G_ALLOCA_H__ */ #endif /* HAVE_ALLOCA */ #endif mlterm-3.9.3/baselib/src/bl_net.h000066400000000000000000000011301441203364000166220ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_NET_H__ #define __BL_NET_H__ #ifdef USE_WIN32API #undef _WIN32_WINNT #define _WIN32_WINNT 0x0501 /* for getaddrinfo */ #include #include /* addrinfo */ #else /* USE_WIN32API */ #include "bl_types.h" /* socklen_t */ #include #include #include #include #ifndef AF_LOCAL #define AF_LOCAL AF_UNIX #endif #ifndef PF_LOCAL #ifdef PF_UNIX #define PF_LOCAL PF_UNIX #else #define PF_LOCAL AF_LOCAL #endif #endif #endif /* USE_WIN32API */ #endif mlterm-3.9.3/baselib/src/bl_path.c000066400000000000000000000261661441203364000170030ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_path.h" #include /* NULL */ #include #include /* getenv */ #include /* isdigit */ #if defined(__ANDROID__) #include #elif defined(USE_WIN32API) #include #include /* IsDBCSLeadByte */ #endif #include "bl_debug.h" #if 0 #define __DEBUG #endif /* --- global functions --- */ #if !defined(HAVE_BASENAME) || defined(USE_WIN32API) || defined(BL_DEBUG) char* __bl_basename(char *path) { char *p; if (path == NULL || *path == '\0') { return "."; } p = path + strlen(path) - 1; while (1) { if (p == path) { return p; } else if (*p == '/' #ifdef USE_WIN32API || (*p == '\\' && (p - 1 == path || !IsDBCSLeadByte(*(p - 1)))) #endif ) { *(p--) = '\0'; } else { break; } } while (1) { if (*p == '/' #ifdef USE_WIN32API || (*p == '\\' && (p - 1 == path || !IsDBCSLeadByte(*(p - 1)))) #endif ) { return p + 1; } else { if (p == path) { return p; } } p--; } } #endif #ifndef REMOVE_FUNCS_MLTERM_UNUSE int bl_path_cleanname(char *cleaned_path, size_t size, const char *path) { char *src; char *dst; size_t left; char *p; if (size == 0) { return 0; } if ((src = alloca(strlen(path) + 1)) == NULL) { return 0; } strcpy(src, path); dst = cleaned_path; left = size; if (*src == '/') { *(dst++) = '\0'; left--; src++; } while ((p = strchr(src, '/'))) { *p = '\0'; if (strcmp(src, ".") == 0) { goto end; } else if (strcmp(src, "..") == 0 && left < size) { char *last; if ((last = strrchr(cleaned_path, '/'))) { last++; } else { last = cleaned_path; } if (*last != '\0' && strcmp(last, "..") != 0) { dst -= (strlen(last) + 1); left += (strlen(last) + 1); *dst = '\0'; goto end; } } if (*src) { if (left < strlen(src) + 1) { return 1; } if (left < size) { *(dst - 1) = '/'; } strcpy(dst, src); dst += (strlen(src) + 1); left -= (strlen(src) + 1); } end: src = p + 1; } if (src && *src) { if (left < strlen(src) + 1) { return 1; } if (left < size) { *(dst - 1) = '/'; } strcpy(dst, src); dst += (strlen(src) + 1); left -= (strlen(src) + 1); } return 1; } #endif /* REMOVE_FUNCS_MLTERM_UNUSE */ /* * Parsing "@:::". */ int bl_parse_uri(char **proto, /* proto can be NULL. If seq doesn't have proto, NULL is set. */ char **user, /* user can be NULL. If seq doesn't have user, NULL is set. */ char **host, /* host can be NULL. */ char **port, /* port can be NULL. If seq doesn't have port, NULL is set. */ char **path, /* path can be NULL. If seq doesn't have path, NULL is set. */ char **aux, /* aux can be NULL. If seq doesn't have aux string, NULL is set. */ char *seq /* broken in this function. */ ) { char *p; size_t len; len = strlen(seq); p = NULL; if (len > 6) { if (strncmp(seq, "ssh://", 6) == 0 || strncmp(seq, "ftp://", 6) == 0) { seq = (p = seq) + 6; *(seq - 3) = '\0'; } else if (len > 7) { if (strncmp(seq, "mosh://", 7) == 0) { seq = (p = seq) + 7; *(seq - 3) = '\0'; } else if (len > 9) { if (strncmp(seq, "telnet://", 9) == 0 || strncmp(seq, "rlogin://", 9) == 0) { seq = (p = seq) + 9; *(seq - 3) = '\0'; } } } } if (proto) { *proto = p; } if ((p = strchr(seq, '/'))) { *(p++) = '\0'; if (*p == '\0') { p = NULL; } } if (path) { *path = p; } if ((p = strchr(seq, '@'))) { *p = '\0'; if (user) { *user = seq; } seq = p + 1; } else if (user) { *user = NULL; } if (host) { *host = seq; } if ((p = strchr(seq, ':'))) { *(p++) = '\0'; if (isdigit((int)*p)) { seq = p; while (isdigit((int)(*(++p)))) ; if (*p == '\0') { p = NULL; } else { *(p++) = '\0'; } } else { seq = NULL; } } else { seq = NULL; } if (port) { *port = seq; } if (aux) { *aux = p; } return 1; } char *bl_get_home_dir(void) { #ifdef __ANDROID__ static char *dir; if (!dir) { struct stat st; if (stat("/sdcard", &st) == 0) { dir = "/sdcard"; } else if (stat("/mnt/sdcard", &st) == 0) { dir = "/mnt/sdcard"; } else { dir = "/extsdcard"; } } return dir; #else char *dir; #ifdef USE_WIN32API if ((dir = getenv("HOMEPATH")) && *dir) { return dir; } #endif if ((dir = getenv("HOME")) && *dir) { return dir; } return NULL; #endif } #if defined(__CYGWIN__) #include int bl_conv_to_win32_path(const char *path, char *winpath, size_t len) { int ret; if ((ret = cygwin_conv_path(CCP_POSIX_TO_WIN_A, path, winpath, len)) < 0) { bl_warn_printf("Couldn't convert %s to win32 path.\n", path); } return ret; } int bl_conv_to_posix_path(const char *winpath, char *path, size_t len) { int ret; if ((ret = cygwin_conv_path(CCP_WIN_A_TO_POSIX, winpath, path, len)) < 0) { bl_warn_printf("Couldn't convert %s to posix path.\n", winpath); } return ret; } #elif defined(__MSYS__) #include /* MAX_PATH */ #include int bl_conv_to_win32_path(const char *path, char *winpath, size_t len) { static size_t prefix_len; int ret; if (prefix_len == 0) { char winpath[MAX_PATH]; cygwin_conv_to_win32_path("/", winpath); prefix_len = strlen(winpath); } if (strlen(path) + prefix_len >= len) { bl_warn_printf("Couldn't convert %s to win32 path.\n", path); return -1; } cygwin_conv_to_win32_path(path, winpath); return 0; } int bl_conv_to_posix_path(const char *winpath, char *path, size_t len) { int ret; if (strlen(winpath) >= len) { bl_warn_printf("Couldn't convert %s to posix path.\n", winpath); return -1; } cygwin_conv_to_posix_path(winpath, path); return 0; } #endif #ifdef BL_DEBUG #include #if defined(__CYGWIN__) || defined(__MSYS__) #include static void TEST_bl_path_win32(void) { char path[MAX_PATH]; bl_conv_to_win32_path("/foo/bar", path, sizeof(path)); #if defined(__CYGWIN__) assert(strcasecmp(path, "c:\\cygwin64\\foo\\bar") == 0 || strcasecmp(path, "c:\\cygwin\\foo\\bar") == 0); #else /* if defined(__MSYS__) */ assert(strcasecmp(path, "c:\\msys64\\foo\\bar") == 0); #endif assert(bl_conv_to_win32_path( "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", path, sizeof(path)) < 0); bl_conv_to_posix_path("c:\\cygwin\\foo\\bar", path, sizeof(path)); #if defined(__CYGWIN__) assert(strcasecmp(path, "/cygdrive/c/cygwin/foo/bar") == 0); #else /* if defined(__MSYS__) */ assert(strcasecmp(path, "/c/cygwin/foo/bar") == 0); #endif assert(bl_conv_to_posix_path( "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", path, sizeof(path)) < 0); } #endif static void TEST_bl_path_common(void) { char uri1[] = "ssh://ken@localhost.localdomain:22"; char uri2[] = "ken@localhost.localdomain:22"; char uri3[] = "ken@localhost.localdomain:22:utf8"; char uri4[] = "ken@localhost.localdomain"; char uri5[] = "ssh://localhost.localdomain"; char uri6[] = "telnet://ken@localhost.localdomain:22:eucjp/usr/local/"; char uri7[] = "ssh://ken@localhost.localdomain:22:eucjp/"; char uri8[] = "ssh://localhost:eucjp/usr/local"; char *user; char *proto; char *host; char *port; char *encoding; char *path; bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri1); assert(strcmp(proto, "ssh") == 0); assert(strcmp(user, "ken") == 0); assert(strcmp(host, "localhost.localdomain") == 0); assert(strcmp(port, "22") == 0); assert(path == NULL); assert(encoding == NULL); bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri2); assert(proto == NULL); assert(strcmp(user, "ken") == 0); assert(strcmp(host, "localhost.localdomain") == 0); assert(strcmp(port, "22") == 0); assert(path == NULL); assert(encoding == NULL); bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri3); assert(proto == NULL); assert(strcmp(user, "ken") == 0); assert(strcmp(host, "localhost.localdomain") == 0); assert(strcmp(port, "22") == 0); assert(path == NULL); assert(strcmp(encoding, "utf8") == 0); bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri4); assert(proto == NULL); assert(strcmp(user, "ken") == 0); assert(strcmp(host, "localhost.localdomain") == 0); assert(port == NULL); assert(path == NULL); assert(encoding == NULL); bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri5); assert(strcmp(proto, "ssh") == 0); assert(user == NULL); assert(strcmp(host, "localhost.localdomain") == 0); assert(port == NULL); assert(path == NULL); assert(encoding == NULL); bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri6); assert(strcmp(proto, "telnet") == 0); assert(strcmp(user, "ken") == 0); assert(strcmp(host, "localhost.localdomain") == 0); assert(strcmp(port, "22") == 0); assert(strcmp(path, "usr/local/") == 0); assert(strcmp(encoding, "eucjp") == 0); bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri7); assert(strcmp(proto, "ssh") == 0); assert(strcmp(user, "ken") == 0); assert(strcmp(host, "localhost.localdomain") == 0); assert(strcmp(port, "22") == 0); assert(path == NULL); assert(strcmp(encoding, "eucjp") == 0); bl_parse_uri(&proto, &user, &host, &port, &path, &encoding, uri8); assert(strcmp(proto, "ssh") == 0); assert(user == NULL); assert(strcmp(host, "localhost") == 0); assert(port == NULL); assert(strcmp(path, "usr/local") == 0); assert(strcmp(encoding, "eucjp") == 0); } static void TEST_bl_basename(void) { char path1[] = "/foo/bar/"; char path2[] = "/foo/bar"; char path3[] = "/f o o/ b a r"; #ifdef USE_WIN32API /* Hyou (SJIS) = \x95\x5c (0x5c = \) */ char path4[] = "/foo/\x95\x5c bar"; #endif assert(strcmp(__bl_basename(path1), "bar") == 0); assert(strcmp(__bl_basename(path2), "bar") == 0); assert(strcmp(__bl_basename(path3), " b a r") == 0); #ifdef USE_WIN32API assert(strcmp(__bl_basename(path4), "\x95\x5c bar") == 0); #endif } void TEST_bl_path(void) { #if defined(__CYGWIN__) || defined(__MSYS__) TEST_bl_path_win32(); #endif TEST_bl_path_common(); TEST_bl_basename(); bl_msg_printf("PASS bl_path test.\n"); } #endif /* BL_DEBUG */ mlterm-3.9.3/baselib/src/bl_path.h000066400000000000000000000031621441203364000167770ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_PATH_H__ #define __BL_PATH_H__ #include /* isalpha */ #include "bl_types.h" #include "bl_def.h" /* PathIsRelative() is not used to avoid link shlwapi.lib */ #define IS_RELATIVE_PATH_DOS(path) \ (isalpha((path)[0]) ? ((path)[1] != ':' || (path)[2] != '\\') : ((path)[0] != '\\')) #define IS_RELATIVE_PATH_UNIX(path) (*(path) != '/') #ifdef USE_WIN32API #define IS_RELATIVE_PATH(path) IS_RELATIVE_PATH_DOS(path) #else #define IS_RELATIVE_PATH(path) IS_RELATIVE_PATH_UNIX(path) #endif #if defined(__CYGWIN__) || defined(__MSYS__) #ifndef BINDIR #define BL_LIBEXECDIR(suffix) "/bin" #else #define BL_LIBEXECDIR(suffix) BINDIR #endif #else #ifndef LIBEXECDIR #define BL_LIBEXECDIR(suffix) "/usr/local/libexec/" suffix #else #define BL_LIBEXECDIR(suffix) LIBEXECDIR "/" suffix #endif #endif /* XXX win32 basename() works strangely if cp932 characters are pssed. */ #if defined(HAVE_BASENAME) && !defined(USE_WIN32API) #include #define bl_basename(path) basename(path) #else #define bl_basename(path) __bl_basename(path) char *__bl_basename(char *path); #endif #ifndef REMOVE_FUNCS_MLTERM_UNUSE int bl_path_cleanname(char *cleaned_path, size_t size, const char *path); #endif int bl_parse_uri(char **proto, char **user, char **host, char **port, char **path, char **aux, char *seq); char *bl_get_home_dir(void); #if defined(__CYGWIN__) || defined(__MSYS__) int bl_conv_to_win32_path(const char *path, char *winpath, size_t len); int bl_conv_to_posix_path(const char *winpath, char *path, size_t len); #endif #endif mlterm-3.9.3/baselib/src/bl_privilege.c000066400000000000000000000031311441203364000200200ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_privilege.h" #include /* getuid/getgid */ #include "bl_def.h" /* --- static variables --- */ #if defined(HAVE_SETEUID) && defined(HAVE_GETEUID) static int euid_is_changed; static uid_t saved_euid; static int egid_is_changed; static gid_t saved_egid; #endif /* --- global functions --- */ #if defined(HAVE_SETEUID) && defined(HAVE_GETEUID) int bl_priv_change_euid(uid_t uid) { if (euid_is_changed) { /* pretending to succeed */ return 1; } saved_euid = geteuid(); if (seteuid(uid) == 0) { euid_is_changed = 1; return 1; } else { return 0; } } int bl_priv_restore_euid(void) { if (!euid_is_changed) { /* pretending to succeed */ return 1; } if (seteuid(saved_euid) == 0) { euid_is_changed = 0; return 1; } else { return 0; } } #else int bl_priv_change_euid(uid_t uid) { return 0; } int bl_priv_restore_euid(void) { return 0; } #endif #if defined(HAVE_SETEUID) && defined(HAVE_SETEGID) int bl_priv_change_egid(uid_t gid) { if (egid_is_changed) { /* pretending to succeed */ return 1; } saved_egid = getegid(); if (setegid(gid) == 0) { egid_is_changed = 1; return 1; } else { return 0; } } int bl_priv_restore_egid(void) { if (!egid_is_changed) { /* pretending to succeed */ return 1; } if (setegid(saved_egid) == 0) { egid_is_changed = 0; return 1; } else { return 0; } } #else int bl_priv_change_egid(gid_t gid) { return 0; } int bl_priv_restore_egid(void) { return 0; } #endif mlterm-3.9.3/baselib/src/bl_privilege.h000066400000000000000000000004701441203364000200300ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_PRIVILEGE_H__ #define __BL_PRIVILEGE_H__ #include "bl_types.h" /* uid_t / gid_t */ int bl_priv_change_euid(uid_t uid); int bl_priv_restore_euid(void); int bl_priv_change_egid(gid_t gid); int bl_priv_restore_egid(void); #endif mlterm-3.9.3/baselib/src/bl_pty.h000066400000000000000000000004431441203364000166560ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_PTY_H__ #define __BL_PTY_H__ #include "bl_types.h" /* pid_t */ pid_t bl_pty_fork(int *master, int *slave); int bl_pty_close(int master); void bl_pty_helper_set_flag(int lastlog, int utmp, int wtmp); #endif mlterm-3.9.3/baselib/src/bl_pty_bsd.c000066400000000000000000000123611441203364000175030ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_pty.h" #include /* tcset|tcget */ #include #include #include #include #include #include #include #include #include #include "bl_str.h" /* strdup */ #include "bl_debug.h" #include "bl_file.h" /* bl_file_set_cloexec */ /* Disable special character functions */ #ifdef _POSIX_VDISABLE #define VDISABLE _POSIX_VDISABLE #else #define VDISABLE 255 #endif /* * FreeBSD * /dev/pty[p-sP-S][0-9a-v] master pseudo terminals * /dev/tty[p-sP-S][0-9a-v] slave pseudo terminals * NetBSD * /dev/pty[p-zP-T][0-9a-zA-Z] master pseudo terminals * /dev/tty[p-zP-T][0-9a-zA-Z] slave pseudo terminals */ #if defined(__FreeBSD__) #define PTYCHAR1 "pqrsPQRS" #else #define PTYCHAR1 "pqrstuvwxyzPQRST" #endif #if defined(__FreeBSD__) #define PTYCHAR2 "0123456789abcdefghijklmnopqrstuv" #elif defined(__NetBSD__) #define PTYCHAR2 "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" #else #define PTYCHAR2 "0123456789abcdef" #endif /* --- static functions --- */ static int login_tty(int fd) { setsid(); if (ioctl(fd, TIOCSCTTY, (char *)NULL) == -1) { return 0; } dup2(fd, 0); dup2(fd, 1); dup2(fd, 2); if (fd > STDERR_FILENO) { close(fd); } return 1; } static int open_pty(int *master, int *slave) { char name[] = "/dev/XtyXX"; char *p1; char *p2; gid_t ttygid; struct group *gr; if ((gr = getgrnam("tty")) != NULL) { ttygid = gr->gr_gid; } else { ttygid = (gid_t)-1; } for (p1 = PTYCHAR1; *p1; p1++) { name[8] = *p1; for (p2 = PTYCHAR2; *p2; p2++) { name[5] = 'p'; name[9] = *p2; if ((*master = open(name, O_RDWR, 0)) == -1) { if (errno == ENOENT) { /* try next pty */ continue; } } else { bl_file_set_cloexec(*master); /* * we succeeded to open pty master. * opening pty slave in succession. */ name[5] = 't'; chown(name, getuid(), ttygid); chmod(name, S_IRUSR | S_IWUSR | S_IWGRP); if ((*slave = open(name, O_RDWR, 0)) != -1) { return 1; } close(*master); } } } return 0; } /* --- global functions --- */ pid_t bl_pty_fork(int *master, int *slave) { int mode; pid_t pid; struct termios tio; int fd; if (!open_pty(master, slave)) { return -1; } pid = fork(); if (pid == -1) { /* fork failed */ return -1; } else if (pid == 0) { /* * child process */ close(*master); login_tty(*slave); return 0; } /* * parent process */ /* * delaying. */ if ((mode = fcntl(*master, F_GETFL, 0)) == -1 || ((mode & O_NDELAY) == 0 && fcntl(*master, F_SETFL, mode | O_NDELAY) == -1)) { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Failed to set pty master non-blocking.\n"); #endif } /* * terminal attributes. */ memset(&tio, 0, sizeof(struct termios)); tio.c_iflag = BRKINT | IGNPAR | ICRNL | IXON; tio.c_oflag = OPOST | ONLCR; tio.c_cflag = CS8 | CREAD; tio.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOE | ECHOK; #ifdef ECHOKE tio.c_lflag |= ECHOKE; #endif #ifdef ECHOCTL tio.c_lflag |= ECHOCTL; #endif tio.c_cc[VEOF] = CEOF; tio.c_cc[VEOL] = VDISABLE; tio.c_cc[VERASE] = CERASE; tio.c_cc[VINTR] = CINTR; tio.c_cc[VKILL] = CKILL; tio.c_cc[VQUIT] = CQUIT; tio.c_cc[VSTART] = CSTART; tio.c_cc[VSTOP] = CSTOP; tio.c_cc[VSUSP] = CSUSP; #ifdef VDSUSP tio.c_cc[VDSUSP] = CDSUSP; #endif #ifdef VREPRINT tio.c_cc[VREPRINT] = CRPRNT; #endif #ifdef VRPRNT tio.c_cc[VRPRNT] = CRPRNT; #endif #ifdef VDISCARD tio.c_cc[VDISCARD] = CFLUSH; #endif #ifdef VFLUSHO tio.c_cc[VFLUSHO] = CFLUSH; #endif #ifdef VWERASE tio.c_cc[VWERASE] = CWERASE; #endif #ifdef VLNEXT tio.c_cc[VLNEXT] = CLNEXT; #endif #ifdef VEOL2 tio.c_cc[VEOL2] = VDISABLE; #endif #ifdef VSWTC tio.c_cc[VSWTC] = VDISABLE; #endif #ifdef VSWTCH tio.c_cc[VSWTCH] = VDISABLE; #endif #ifdef VSTATUS tio.c_cc[VSTATUS] = CSTATUS; #endif /* * VMIN == VEOF and VTIME == VEOL on old System V. */ #if VMIN != VEOF tio.c_cc[VMIN] = 1; #endif #if VTIME != VEOL tio.c_cc[VTIME] = 0; #endif /* * inheriting tty(0,1,2) settings ... */ for (fd = 0; fd <= 2; fd++) { struct termios def_tio; if (tcgetattr(fd, &def_tio) == 0) { tio.c_cc[VEOF] = def_tio.c_cc[VEOF]; tio.c_cc[VEOL] = def_tio.c_cc[VEOL]; tio.c_cc[VERASE] = def_tio.c_cc[VERASE]; tio.c_cc[VINTR] = def_tio.c_cc[VINTR]; tio.c_cc[VKILL] = def_tio.c_cc[VKILL]; tio.c_cc[VQUIT] = def_tio.c_cc[VQUIT]; tio.c_cc[VSTART] = def_tio.c_cc[VSTART]; tio.c_cc[VSTOP] = def_tio.c_cc[VSTOP]; tio.c_cc[VSUSP] = def_tio.c_cc[VSUSP]; break; } } #ifdef B38400 cfsetispeed(&tio, B38400); cfsetospeed(&tio, B38400); #else cfsetispeed(&tio, B9600); cfsetospeed(&tio, B9600); #endif if (tcsetattr(*master, TCSANOW, &tio) < 0) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " tcsetattr() failed.\n"); #endif } bl_file_set_cloexec(*slave); return pid; } int bl_pty_close(int master) { return close(master); } void bl_pty_helper_set_flag(int lastlog, int utmp, int wtmp) {} mlterm-3.9.3/baselib/src/bl_pty_helper.c000066400000000000000000000236511441203364000202160ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_pty.h" #include #include #include #include #include #include #include #include /* memcpy */ #include #include "bl_def.h" /* HAVE_SETSID, LINE_MAX */ #include "bl_debug.h" #include "bl_mem.h" /* realloc/free */ #include "bl_path.h" /* BL_LIBEXECDIR */ #ifndef MSG_NOSIGNAL #define MSG_NOSIGNAL 0 #endif #if 0 #define __DEBUG #endif typedef enum { GNOME_PTY_OPEN_PTY_UTMP = 1, GNOME_PTY_OPEN_PTY_UWTMP, GNOME_PTY_OPEN_PTY_WTMP, GNOME_PTY_OPEN_PTY_LASTLOG, GNOME_PTY_OPEN_PTY_LASTLOGUTMP, GNOME_PTY_OPEN_PTY_LASTLOGUWTMP, GNOME_PTY_OPEN_PTY_LASTLOGWTMP, GNOME_PTY_OPEN_NO_DB_UPDATE, GNOME_PTY_RESET_TO_DEFAULTS, GNOME_PTY_CLOSE_PTY, GNOME_PTY_SYNCH } GnomePtyOps; typedef struct { int pty; void *tag; } pty_helper_tag_t; /* --- static variables --- */ static pid_t myself = -1; static pid_t pty_helper_pid = -1; static int pty_helper_tunnel = -1; static pty_helper_tag_t *pty_helper_tags = NULL; static u_int num_pty_helper_tags; static GnomePtyOps pty_helper_open_ops = GNOME_PTY_OPEN_PTY_UTMP; /* --- static functions --- */ static void setup_child(int fd) { char *tty; tty = ttyname(fd); #ifdef __DEBUG bl_debug_printf(BL_DEBUG_TAG " Setting up child pty(name:%s, fd:%d)\n", tty ? tty : "(none)", fd); #endif /* Try to reopen the pty to acquire it as our controlling terminal. */ if (tty != NULL) { int _fd; if ((_fd = open(tty, O_RDWR)) != -1) { if (fd != -1) { close(fd); } fd = _fd; } } if (fd == -1) { exit(EXIT_FAILURE); } /* Start a new session and become process group leader. */ #if defined(HAVE_SETSID) && defined(HAVE_SETPGID) setsid(); setpgid(0, 0); #endif #ifdef TIOCSCTTY ioctl(fd, TIOCSCTTY, fd); #endif #if defined(HAVE_ISASTREAM) && defined(I_PUSH) if (isastream(fd) == 1) { ioctl(fd, I_PUSH, "ptem"); ioctl(fd, I_PUSH, "ldterm"); ioctl(fd, I_PUSH, "ttcompat"); } #endif if (fd != STDIN_FILENO) { dup2(fd, STDIN_FILENO); } if (fd != STDOUT_FILENO) { dup2(fd, STDOUT_FILENO); } if (fd != STDERR_FILENO) { dup2(fd, STDERR_FILENO); } if (fd != STDIN_FILENO && fd != STDOUT_FILENO && fd != STDERR_FILENO) { close(fd); } close(pty_helper_tunnel); } #ifdef HAVE_RECVMSG static void read_ptypair(int tunnel, int *master, int *slave) { int count; int ret; char control[LINE_MAX]; char iobuf[LINE_MAX]; struct cmsghdr *cmsg; struct msghdr msg; struct iovec vec; for (count = 0; count < 2; count++) { vec.iov_base = iobuf; vec.iov_len = sizeof(iobuf); msg.msg_name = NULL; msg.msg_namelen = 0; msg.msg_iov = &vec; msg.msg_iovlen = 1; msg.msg_control = control; msg.msg_controllen = sizeof(control); if ((ret = recvmsg(tunnel, &msg, MSG_NOSIGNAL)) == -1) { return; } for (cmsg = CMSG_FIRSTHDR(&msg); cmsg != NULL; cmsg = CMSG_NXTHDR(&msg, cmsg)) { if (cmsg->cmsg_type == SCM_RIGHTS) { memcpy(&ret, CMSG_DATA(cmsg), sizeof(ret)); if (count == 0) { /* Without this, pty master is blocked in poll. */ fcntl(ret, F_SETFL, O_NONBLOCK); *master = ret; } else /* if( i == 1) */ { fcntl(ret, F_SETFL, O_NONBLOCK); *slave = ret; } } } } } #elif defined(I_RECVFD) static void read_ptypair(int tunnel, int *master, int *slave) { int ret; if (ioctl(tunnel, I_RECVFD, &ret) == -1) { return; } *master = ret; if (ioctl(tunnel, I_RECVFD, &ret) == -1) { return; } *slave = ret; } #endif #ifdef HAVE_SOCKETPAIR static int open_pipe(int *a, int *b) { int p[2]; int ret = -1; #ifdef PF_UNIX #ifdef SOCK_STREAM ret = socketpair(PF_UNIX, SOCK_STREAM, 0, p); #else #ifdef SOCK_DGRAM ret = socketpair(PF_UNIX, SOCK_DGRAM, 0, p); #endif #endif if (ret == 0) { *a = p[0]; *b = p[1]; return 0; } #endif return ret; } #else static int open_pipe(int *a, int *b) { int p[2]; int ret = -1; ret = pipe(p); if (ret == 0) { *a = p[0]; *b = p[1]; } return ret; } #endif /* read ignoring EINTR and EAGAIN. */ static ssize_t n_read(int fd, void *buffer, size_t buf_size) { size_t n; char *p; int ret; n = 0; p = buffer; while (n < buf_size) { ret = read(fd, p + n, buf_size - n); switch (ret) { case 0: return n; case -1: switch (errno) { case EINTR: case EAGAIN: #ifdef ERESTART case ERESTART: #endif break; default: return -1; } default: n += ret; } } return n; } /* write ignoring EINTR and EAGAIN. */ static ssize_t n_write(int fd, const void *buffer, size_t buf_size) { size_t n; const char *p; int ret; n = 0; p = buffer; while (n < buf_size) { ret = write(fd, p + n, buf_size - n); switch (ret) { case 0: return n; case -1: switch (errno) { case EINTR: case EAGAIN: #ifdef ERESTART case ERESTART: #endif break; default: return -1; } default: n += ret; } } return n; } static void stop_pty_helper(void) { if (pty_helper_pid != -1) { free(pty_helper_tags); pty_helper_tags = NULL; num_pty_helper_tags = 0; close(pty_helper_tunnel); pty_helper_tunnel = -1; /* child processes might trigger this function on exit(). */ if (myself == getpid()) { kill(pty_helper_pid, SIGTERM); } pty_helper_pid = -1; } } static int start_pty_helper(void) { int tmp[2]; int tunnel; if (access(BL_LIBEXECDIR("mlterm") "/gnome-pty-helper", X_OK) != 0) { bl_error_printf("Couldn't run %s", BL_LIBEXECDIR("mlterm") "/gnome-pty-helper"); return 0; } /* Create a communication link with the helper. */ tmp[0] = open("/dev/null", O_RDONLY); if (tmp[0] == -1) { return 0; } tmp[1] = open("/dev/null", O_RDONLY); if (tmp[1] == -1) { close(tmp[0]); return 0; } if (open_pipe(&pty_helper_tunnel, &tunnel) != 0) { return 0; } close(tmp[0]); close(tmp[1]); pty_helper_pid = fork(); if (pty_helper_pid == -1) { return 0; } if (pty_helper_pid == 0) { /* Child */ int count; /* No need to close all descriptors because gnome-pty-helper does that * anyway. */ for (count = 0; count < 3; count++) { close(count); } dup2(tunnel, STDIN_FILENO); dup2(tunnel, STDOUT_FILENO); close(tunnel); close(pty_helper_tunnel); execl(BL_LIBEXECDIR("mlterm") "/gnome-pty-helper", "gnome-pty-helper", NULL); exit(EXIT_SUCCESS); } close(tunnel); myself = getpid(); atexit(stop_pty_helper); return 1; } /* --- global functions --- */ pid_t bl_pty_fork(int *master, int *slave) { pid_t pid; int ret; void *tag; if (pty_helper_pid == -1) { if (!start_pty_helper()) { return -1; } } /* Send our request. */ if (n_write(pty_helper_tunnel, &pty_helper_open_ops, sizeof(pty_helper_open_ops)) != sizeof(pty_helper_open_ops)) { return -1; } #ifdef __DEBUG bl_debug_printf(BL_DEBUG_TAG " Sent request to helper.\n"); #endif /* Read back the response. */ if (n_read(pty_helper_tunnel, &ret, sizeof(ret)) != sizeof(ret)) { return -1; } #ifdef __DEBUG bl_debug_printf(BL_DEBUG_TAG " Received response from helper.\n"); #endif if (ret == 0) { return -1; } #ifdef __DEBUG bl_debug_printf(BL_DEBUG_TAG " Helper returns success.\n"); #endif /* Read back a tag. */ if (n_read(pty_helper_tunnel, &tag, sizeof(tag)) != sizeof(tag)) { return -1; } #ifdef __DEBUG bl_debug_printf(BL_DEBUG_TAG " Tag = %p.\n", tag); #endif /* Receive the master and slave ptys. */ read_ptypair(pty_helper_tunnel, master, slave); if ((*master == -1) || (*slave == -1)) { close(*master); close(*slave); return -1; } #ifdef __DEBUG bl_debug_printf(BL_DEBUG_TAG " Master pty %d / Slave pty %d.\n", *master, *slave); #endif pty_helper_tags = realloc(pty_helper_tags, sizeof(pty_helper_tag_t) * (num_pty_helper_tags + 1)); pty_helper_tags[num_pty_helper_tags].pty = *master; pty_helper_tags[num_pty_helper_tags++].tag = tag; pid = fork(); if (pid == -1) { /* Error */ bl_error_printf("Failed to fork.\n"); close(*master); close(*slave); } else if (pid == 0) { /* child */ close(*master); setup_child(*slave); } return pid; } int bl_pty_close(int master) { u_int count; for (count = 0; count < num_pty_helper_tags; count++) { if (pty_helper_tags[count].pty == master) { void *tag; GnomePtyOps ops; tag = pty_helper_tags[count].tag; ops = GNOME_PTY_CLOSE_PTY; if (n_write(pty_helper_tunnel, &ops, sizeof(ops)) != sizeof(ops) || n_write(pty_helper_tunnel, &tag, sizeof(tag)) != sizeof(tag)) { return -1; } ops = GNOME_PTY_SYNCH; if (n_write(pty_helper_tunnel, &ops, sizeof(ops)) != sizeof(ops)) { return -1; } #if 0 /* This can be blocked (CentOS 5, vte 0.14.0) */ n_read(pty_helper_tunnel, &ops, 1); #endif pty_helper_tags[count] = pty_helper_tags[--num_pty_helper_tags]; return 0; } } return close(master); } void bl_pty_helper_set_flag(int lastlog, int utmp, int wtmp) { int idx; GnomePtyOps ops[8] = { GNOME_PTY_OPEN_NO_DB_UPDATE, /* 0 0 0 */ GNOME_PTY_OPEN_PTY_LASTLOG, /* 0 0 1 */ GNOME_PTY_OPEN_PTY_UTMP, /* 0 1 0 */ GNOME_PTY_OPEN_PTY_LASTLOGUTMP, /* 0 1 1 */ GNOME_PTY_OPEN_PTY_WTMP, /* 1 0 0 */ GNOME_PTY_OPEN_PTY_LASTLOGWTMP, /* 1 0 1 */ GNOME_PTY_OPEN_PTY_UWTMP, /* 1 1 0 */ GNOME_PTY_OPEN_PTY_LASTLOGUWTMP, /* 1 1 1 */ }; idx = 0; if (lastlog) { idx += 1; } if (utmp) { idx += 2; } if (wtmp) { idx += 4; } pty_helper_open_ops = ops[idx]; } mlterm-3.9.3/baselib/src/bl_pty_none.c000066400000000000000000000004641441203364000176730ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_pty.h" /* --- global functions --- */ pid_t bl_pty_fork(int *master, int *slave) { /* do nothing. */ return 0; } int bl_pty_close(int master) { return 0; } void bl_pty_helper_set_flag(int lastlog, int utmp, int wtmp) {} mlterm-3.9.3/baselib/src/bl_pty_streams.c000066400000000000000000000167241441203364000204200ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* * _GNU_SOURCE must be defined before including to take effect. * since standard headers, bl_types.h and bl_def.h include features.h * indirectly, * ecplicitly evaluate only the autoconf's result here. */ #include "bl_config.h" #ifdef HAVE_GNU_SOURCE #define _GNU_SOURCE #endif #include "bl_pty.h" #include #include #include #include #include #include #include #include #include #if defined(__ANDROID__) || defined(__HAIKU__) #include #else #include #endif #ifdef HAVE_STROPTS_H #include #endif #ifdef HAVE_SYS_STROPTS_H #include #endif /* for cygwin */ #undef __XSI_VISIBLE #define __XSI_VISIBLE 600 #include #undef __XSI_VISIBLE #include "bl_str.h" /* strdup */ #include "bl_file.h" #include "bl_debug.h" #include "bl_sig_child.h" /* Disable special character functions */ #ifdef _POSIX_VDISABLE #define VDISABLE _POSIX_VDISABLE #else #define VDISABLE 255 #endif /* For Android */ #ifndef CEOF #define CEOF ('d' & 0x1f) #endif #ifndef CERASE #define CERASE 0x7f #endif #ifndef CINTR #define CINTR ('c' & 0x1f) #endif #ifndef CKILL #define CKILL ('u' & 0x1f) #endif #ifndef CQUIT #define CQUIT 0x1c #endif #ifndef CSTART #define CSTART ('q' & 0x1f) #endif #ifndef CSTOP #define CSTOP ('s' & 0x1f) #endif #ifndef CSUSP #define CSUSP ('z' & 0x1f) #endif #ifndef CDSUSP #define CDSUSP ('y' & 0x1f) #endif #ifndef CRPRNT #define CRPRNT ('r' & 0x1f) #endif #ifndef CFLUSH #define CFLUSH ('o' & 0x1f) #endif #ifndef CWERASE #define CWERASE ('w' & 0x1f) #endif #ifndef CLNEXT #define CLNEXT ('v' & 0x1f) #endif /* --- global functions --- */ pid_t bl_pty_fork(int *master, int *slave) { int mode; pid_t pid; char *ttydev; struct termios tio; int fd; #ifdef HAVE_POSIX_OPENPT *master = posix_openpt(O_RDWR | O_NOCTTY); #else *master = open("/dev/ptmx", O_RDWR | O_NOCTTY, 0); #endif if (*master < 0) { bl_error_printf("Couldn't open a master pseudo-terminal device.\n"); return -1; } bl_file_set_cloexec(*master); /* * The behaviour of the grantpt() function is unspecified * if the application has installed a signal handler to catch SIGCHLD signals. * (see http://www.opengroup.org/onlinepubs/007908799/xsh/grantpt.html) */ bl_sig_child_stop(); if (grantpt(*master) < 0) { #if 0 /* XXX this fails but it doesn't do harm in some environments */ bl_sig_child_start(); return -1; #endif } bl_sig_child_start(); if (unlockpt(*master) < 0) { close(*master); return -1; } if ((ttydev = ptsname(*master)) == NULL) { bl_error_printf("Couldn't open a slave pseudo-terminal device.\n"); #ifdef __linux__ bl_msg_printf( "If your operating system is Linux, make sure your kernel was compiled " "with\n" "'CONFIG_UNIX98_PTYS=y' and devpts file system was mounted.\n"); #endif close(*master); return -1; } if ((mode = fcntl(*master, F_GETFL, 0)) == -1 || ((mode & O_NDELAY) == 0 && fcntl(*master, F_SETFL, mode | O_NDELAY) == -1)) { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Failed to set pty master non-blocking.\n"); #endif } if ((*slave = open(ttydev, O_RDWR | O_NOCTTY, 0)) < 0) { close(*master); return -1; } /* * cygwin doesn't have isastream. */ #if defined(HAVE_ISASTREAM) && defined(I_PUSH) if (isastream(*slave) == 1) { ioctl(*slave, I_PUSH, "ptem"); ioctl(*slave, I_PUSH, "ldterm"); ioctl(*slave, I_PUSH, "ttcompat"); } #endif memset(&tio, 0, sizeof(struct termios)); tio.c_iflag = BRKINT | IGNPAR | ICRNL | IXON; tio.c_oflag = OPOST | ONLCR; tio.c_cflag = CS8 | CREAD; tio.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOE | ECHOK; #ifdef ECHOKE tio.c_lflag |= ECHOKE; #endif #ifdef ECHOCTL tio.c_lflag |= ECHOCTL; #endif tio.c_cc[VEOF] = CEOF; tio.c_cc[VEOL] = VDISABLE; tio.c_cc[VERASE] = CERASE; tio.c_cc[VINTR] = CINTR; tio.c_cc[VKILL] = CKILL; tio.c_cc[VQUIT] = CQUIT; tio.c_cc[VSTART] = CSTART; tio.c_cc[VSTOP] = CSTOP; tio.c_cc[VSUSP] = CSUSP; #ifdef VDSUSP tio.c_cc[VDSUSP] = CDSUSP; #endif #ifdef VREPRINT tio.c_cc[VREPRINT] = CRPRNT; #endif #ifdef VRPRNT tio.c_cc[VRPRNT] = CRPRNT; #endif #ifdef VDISCARD tio.c_cc[VDISCARD] = CFLUSH; #endif #ifdef VFLUSHO tio.c_cc[VFLUSHO] = CFLUSH; #endif #ifdef VWERASE tio.c_cc[VWERASE] = CWERASE; #endif #ifdef VLNEXT tio.c_cc[VLNEXT] = CLNEXT; #endif #ifdef VEOL2 tio.c_cc[VEOL2] = VDISABLE; #endif #ifdef VSWTC tio.c_cc[VSWTC] = VDISABLE; #endif #ifdef VSWTCH tio.c_cc[VSWTCH] = VDISABLE; #endif #ifdef VSTATUS tio.c_cc[VSTATUS] = CSTATUS; #endif /* * VMIN == VEOF and VTIME == VEOL on old System V. */ #if VMIN != VEOF tio.c_cc[VMIN] = 1; #endif #if VTIME != VEOL tio.c_cc[VTIME] = 0; #endif /* * inheriting tty(0,1,2) settings ... */ for (fd = 0; fd <= 2; fd++) { struct termios def_tio; if (tcgetattr(fd, &def_tio) == 0) { tio.c_cc[VEOF] = def_tio.c_cc[VEOF]; tio.c_cc[VEOL] = def_tio.c_cc[VEOL]; tio.c_cc[VERASE] = def_tio.c_cc[VERASE]; tio.c_cc[VINTR] = def_tio.c_cc[VINTR]; tio.c_cc[VKILL] = def_tio.c_cc[VKILL]; tio.c_cc[VQUIT] = def_tio.c_cc[VQUIT]; tio.c_cc[VSTART] = def_tio.c_cc[VSTART]; tio.c_cc[VSTOP] = def_tio.c_cc[VSTOP]; tio.c_cc[VSUSP] = def_tio.c_cc[VSUSP]; break; } } pid = fork(); if (pid == -1) { /* fork failed */ close(*master); close(*slave); return -1; } else if (pid == 0) { /* child */ #ifdef __MSYS__ /* * XXX * I don't know why but following hack doesn't effect in MSYS/Windows7. * Set "CYGWIN=tty" environmental variable in msys.bat instead. */ #if 0 /* * XXX * I don't know why but FreeConsole() is called in setsid() * unless following codes(close(0...2)) are placed between * fork() and setsid() (before dup2()) in msys. * If FreeConsole() is called in setsid(), each non-msys program * which is started by shell in mlterm opens command prompt * window... */ for (fd = 0; fd <= 2; fd++) { if (fd != *slave) { close(fd); } } #endif #endif close(*master); #ifdef HAVE_SETSID setsid(); #else /* HAVE_SETSID */ #ifdef TIOCNOTTY fd = open("/dev/tty", O_RDWR | O_NOCTTY); if (fd >= 0) { ioctl(fd, TIOCNOTTY, NULL); close(fd); } #endif /* TIOCNOTTY */ #endif /* HAVE_SETSID */ #ifdef TIOCSCTTY /* BSD (in addition Linux also knows TIOCSCTTY) */ if (ioctl(*slave, TIOCSCTTY, NULL) < 0) { return -1; } #else /* no TIOCSCTTY (SysV) */ fd = open("/dev/tty", O_RDWR | O_NOCTTY); if (fd >= 0) { close(fd); } fd = open(ttydev, O_RDWR); if (fd >= 0) { close(fd); } fd = open("/dev/tty", O_WRONLY); if (fd < 0) { return -1; } close(fd); #endif /* no TIOCSCTTY (SysV) */ dup2(*slave, 0); dup2(*slave, 1); dup2(*slave, 2); if (*slave > STDERR_FILENO) { close(*slave); } #ifdef B38400 cfsetispeed(&tio, B38400); cfsetospeed(&tio, B38400); #else cfsetispeed(&tio, B9600); cfsetospeed(&tio, B9600); #endif if (tcsetattr(STDIN_FILENO, TCSANOW, &tio) < 0) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " tcsetattr() failed.\n"); #endif } return 0; } bl_file_set_cloexec(*slave); return pid; } int bl_pty_close(int master) { return close(master); } void bl_pty_helper_set_flag(int lastlog, int utmp, int wtmp) {} mlterm-3.9.3/baselib/src/bl_sig_child.c000066400000000000000000000043011441203364000177570ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_sig_child.h" #ifndef USE_WIN32API #include /* EINTR */ #include #include #endif #include "bl_debug.h" #include "bl_mem.h" /* realloc/free */ typedef struct sig_child_event_listener { void *self; void (*exited)(void *, pid_t); } sig_child_event_listener_t; /* --- static variables --- */ static sig_child_event_listener_t *listeners; static u_int num_listeners; /* --- static functions --- */ #ifndef USE_WIN32API static void sig_child(int sig) { pid_t pid; #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " SIG CHILD received.\n"); #endif while (1) { if ((pid = waitpid(-1, NULL, WNOHANG)) <= 0) { if (pid == -1 && errno == EINTR) { errno = 0; continue; } break; } bl_trigger_sig_child(pid); } /* reset */ signal(SIGCHLD, sig_child); } #endif /* --- global functions --- */ void bl_sig_child_start(void) { #ifndef USE_WIN32API signal(SIGCHLD, sig_child); #endif } void bl_sig_child_stop(void) { #ifndef USE_WIN32API signal(SIGCHLD, SIG_DFL); #endif } void bl_sig_child_final(void) { #ifndef USE_WIN32API signal(SIGCHLD, SIG_DFL); #endif free(listeners); listeners = NULL; } int bl_add_sig_child_listener(void *self, void (*exited)(void *, pid_t)) { void *p; if ((p = realloc(listeners, sizeof(*listeners) * (num_listeners + 1))) == NULL) { #ifdef DEBUG bl_warn_printf(BL_DEBUG_TAG " realloc failed.\n"); #endif return 0; } listeners = p; listeners[num_listeners].self = self; listeners[num_listeners].exited = exited; num_listeners++; return 1; } int bl_remove_sig_child_listener(void *self, void (*exited)(void *, pid_t)) { u_int count; for (count = 0; count < num_listeners; count++) { if (listeners[count].self == self && listeners[count].exited == exited) { listeners[count] = listeners[--num_listeners]; /* * memory area of listener is not shrunk. */ return 1; } } return 0; } void bl_trigger_sig_child(pid_t pid) { u_int count; for (count = 0; count < num_listeners; count++) { (*listeners[count].exited)(listeners[count].self, pid); } } mlterm-3.9.3/baselib/src/bl_sig_child.h000066400000000000000000000007031441203364000177660ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_SIG_CHILD_H__ #define __BL_SIG_CHILD_H__ #include "bl_types.h" /* pid_t */ void bl_sig_child_start(void); void bl_sig_child_stop(void); void bl_sig_child_final(void); int bl_add_sig_child_listener(void *self, void (*exited)(void *, pid_t)); int bl_remove_sig_child_listener(void *self, void (*exited)(void *, pid_t)); void bl_trigger_sig_child(pid_t pid); #endif mlterm-3.9.3/baselib/src/bl_slist.h000066400000000000000000000021111441203364000171720ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_SLIST_H__ #define __BL_SLIST_H__ #define bl_slist_insert_head(list, new) \ { \ (new)->next = (list); \ (list) = (new); \ } #define bl_slist_remove(list, target) \ { \ if ((list) == (target)) { \ (list) = (list)->next; \ } else if (list) { \ void *orig = (list); \ while ((list)->next) { \ if ((list)->next == (target)) { \ (list)->next = (target)->next; \ break; \ } else { \ (list) = (list)->next; \ } \ } \ (list) = orig; \ } \ } #define bl_slist_next(list) ((list) ? (list)->next : NULL) #define bl_slist_is_empty(list) ((list) == NULL) #endif mlterm-3.9.3/baselib/src/bl_str.c000066400000000000000000000174301441203364000166510ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_str.h" #include /* sprintf */ #include /* va_list */ #include /* isdigit */ #include "bl_debug.h" #include "bl_mem.h" #undef bl_str_sep #undef bl_basename /* --- global functions --- */ #ifndef HAVE_STRSEP char* __bl_str_sep(char **strp, const char *delim) { char *s; const char *spanp; int c; int sc; char *tok; if ((s = *strp) == NULL) { return NULL; } for (tok = s;;) { c = *s++; spanp = delim; do { if ((sc = *spanp++) == c) { if (c == 0) { s = NULL; } else { s[-1] = 0; } *strp = s; return tok; } } while (sc != 0); } } #endif /* * !! Notice !! * It is a caller that is responsible to check buffer overrun. */ int bl_snprintf(char *str, size_t size, const char *format, ...) { va_list arg_list; va_start(arg_list, format); #ifdef HAVE_SNPRINTF return vsnprintf(str, size, format, arg_list); #else /* * XXX * this may cause buffer overrun. */ return vsprintf(str, format, arg_list); #endif } char *__bl_str_dup(const char *str, const char *file /* should be allocated memory. */, int line, const char *func /* should be allocated memory. */) { char *new_str; if ((new_str = bl_mem_malloc(strlen(str) + 1, file, line, func)) == NULL) { return NULL; } strcpy(new_str, str); return new_str; } #ifndef REMOVE_FUNCS_MLTERM_UNUSE /* * XXX * this doesn't concern about ISO2022 sequences or so. * dst/src must be u_char since 0x80 - 0x9f is specially dealed. */ size_t bl_str_tabify(u_char *dst, size_t dst_len, const u_char *src, size_t src_len, size_t tab_len) { size_t pos_in_tab; size_t space_num; int dst_pos; int src_pos; int count; if (tab_len == 0) { #ifdef BL_DEBUG bl_warn_printf(BL_DEBUG_TAG " 0 is illegal tab length.\n"); #endif return 0; } dst_pos = 0; pos_in_tab = 0; space_num = 0; for (src_pos = 0; src_pos < src_len; src_pos++) { if (src[src_pos] == ' ') { if (pos_in_tab == tab_len - 1) { dst[dst_pos++] = '\t'; if (dst_pos >= dst_len) { return dst_pos; } space_num = 0; /* next */ pos_in_tab = 0; } else { space_num++; /* next */ pos_in_tab++; } } else { if (space_num > 0) { for (count = 0; count < space_num; count++) { dst[dst_pos++] = ' '; if (dst_pos >= dst_len) { return dst_pos; } } space_num = 0; } dst[dst_pos++] = src[src_pos]; if (dst_pos >= dst_len) { return dst_pos; } if (src[src_pos] == '\n' || src[src_pos] == '\t') { /* next */ pos_in_tab = 0; } else if ((0x20 <= src[src_pos] && src[src_pos] < 0x7f) || 0xa0 <= src[src_pos]) { /* next */ if (pos_in_tab == tab_len - 1) { pos_in_tab = 0; } else { pos_in_tab++; } } else if (src[src_pos] == 0x1b) { /* XXX ISO2022 seq should be considered. */ } } } if (space_num > 0) { for (count = 0; count < space_num; count++) { dst[dst_pos++] = ' '; if (dst_pos >= dst_len) { return dst_pos; } } } return dst_pos; } #endif char *bl_str_chop_spaces(char *str) { size_t pos; pos = strlen(str); while (pos > 0) { pos--; if (str[pos] != ' ' && str[pos] != '\t') { str[pos + 1] = '\0'; break; } } return str; } int bl_str_n_to_uint(u_int *i, const char *s, size_t n) { u_int _i; int digit; if (n == 0) { return 0; } _i = 0; for (digit = 0; digit < n && s[digit]; digit++) { if (!isdigit(s[digit])) { return 0; } _i *= 10; _i += (s[digit] - 0x30); } *i = _i; return 1; } int bl_str_n_to_int(int *i, const char *s, size_t n) { u_int _i; int is_minus; if (n == 0) { return 0; } if (*s == '-') { if (--n == 0) { return 0; } s++; is_minus = 1; } else { is_minus = 0; } if (!bl_str_n_to_uint(&_i, s, n)) { return 0; } if ((int)_i < 0) { return 0; } if (is_minus) { *i = -((int)_i); } else { *i = (int)_i; } return 1; } int bl_str_to_uint(u_int *i, const char *s) { u_int _i; if (*s == '\0') { return 0; } _i = 0; while (*s) { if (!isdigit(*s)) { return 0; } _i *= 10; _i += (*s - 0x30); s++; } *i = _i; return 1; } int bl_str_to_int(int *i, const char *s) { u_int _i; int is_minus; if (*s == '\0') { return 0; } if (*s == '-') { if (*(++s) == '\0') { return 0; } is_minus = 1; } else { is_minus = 0; } if (!bl_str_to_uint(&_i, s)) { return 0; } if ((int)_i < 0) { return 0; } if (is_minus) { *i = -((int)_i); } else { *i = (int)_i; } return 1; } u_int bl_count_char_in_str(const char *str, char ch) { u_int count; count = 0; while (*str) { if (*str == ch) { count++; } str++; } return count; } /* str1 and str2 can be NULL */ int bl_compare_str(const char *str1, const char *str2) { if (str1 == str2) { return 0; } if (str1 == NULL) { return -1; } else if (str2 == NULL) { return 1; } return strcmp(str1, str2); } char *bl_str_replace(const char *str, const char *orig, /* Don't specify "". */ const char *new) { size_t orig_len; size_t new_len; int diff; const char *p; char *new_str; char *dst; orig_len = strlen(orig); new_len = strlen(new); if ((diff = new_len - orig_len) != 0) { int num; for (num = 0, p = str; (p = strstr(p, orig)); num++, p += orig_len); if (num == 0) { return NULL; } diff *= num; } if (!(p = strstr(str, orig)) || !(dst = new_str = malloc(strlen(str) + diff + 1))) { return NULL; } do { memcpy(dst, str, p - str); dst += (p - str); memcpy(dst, new, new_len); dst += new_len; str = p + orig_len; } while ((p = strstr(str, orig))); strcpy(dst, str); return new_str; } #if 0 char *bl_str_escape_backslash(char *str) { char *escaped_str; char *p; if (!(p = escaped_str = malloc(strlen(str) + bl_count_char_in_str(str, '\\') + 1))) { return str; } while (1) { *(p++) = *str; if (*str == '\0') { g_free(str); return escaped_str; } else if (*str == '\\') { *(p++) = '\\'; } str++; } } #endif char *bl_str_unescape(const char *str) { char *new_str; char *p; if ((new_str = malloc(strlen(str) + 1)) == NULL) { return NULL; } for (p = new_str; *str; str++, p++) { if (*str == '\\') { u_int digit; if (*(++str) == '\0') { break; } else if (sscanf(str, "x%2x", &digit) == 1) { *p = (char)digit; str += 2; } else if (*str == 'n') { *p = '\n'; } else if (*str == 'r') { *p = '\r'; } else if (*str == 't') { *p = '\t'; } else if (*str == 'e' || *str == 'E') { *p = '\033'; } else { *p = *str; } } else if (*str == '^') { if (*(++str) == '\0') { break; } else if ('@' <= *str && *str <= '_') { *p = *str - 'A' + 1; } else if (*str == '?') { *p = '\x7f'; } else { *p = *str; } } else { *p = *str; } } *p = '\0'; return new_str; } #ifdef BL_DEBUG #include void TEST_bl_str(void) { char *str; str = bl_str_replace("abcdefabcdef", "abc", "xxxx"); assert(strcmp(str, "xxxxdefxxxxdef") == 0); free(str); str = bl_str_unescape("abc\\n\\r\\t\\e\\E^A\\x1b"); assert(strcmp(str, "abc\n\r\t\x1b\x1b\x01\x1b") == 0); free(str); bl_msg_printf("PASS bl_str test.\n"); } #endif mlterm-3.9.3/baselib/src/bl_str.h000066400000000000000000000026101441203364000166500ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_STR_H__ #define __BL_STR_H__ #include /* strlen/strsep/strdup */ #include "bl_types.h" /* size_t */ #include "bl_def.h" #include "bl_mem.h" /* alloca */ #ifdef HAVE_STRSEP #define bl_str_sep(strp, delim) strsep(strp, delim) #else #define bl_str_sep(strp, delim) __bl_str_sep(strp, delim) char* __bl_str_sep(char **strp, const char *delim); #endif /* * cpp doesn't necessarily process variable number of arguments. */ int bl_snprintf(char *str, size_t size, const char *format, ...); #ifdef BL_DEBUG #define strdup(str) __bl_str_dup(str, __FILE__, __LINE__, __FUNCTION__) #endif char *__bl_str_dup(const char *str, const char *file, int line, const char *func); #ifndef REMOVE_FUNCS_MLTERM_UNUSE size_t bl_str_tabify(u_char *dst, size_t dst_len, const u_char *src, size_t src_len, size_t tab_len); #endif char *bl_str_chop_spaces(char *str); int bl_str_n_to_uint(u_int *i, const char *s, size_t n); int bl_str_n_to_int(int *i, const char *s, size_t n); int bl_str_to_uint(u_int *i, const char *s); int bl_str_to_int(int *i, const char *s); u_int bl_count_char_in_str(const char *str, char ch); int bl_compare_str(const char *str1, const char *str2); char *bl_str_replace(const char *str, const char *orig_sub, const char *new_sub); char *bl_str_unescape(const char *str); #endif mlterm-3.9.3/baselib/src/bl_time.c000066400000000000000000000146231441203364000170000ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_time.h" #ifndef REMOVE_FUNCS_MLTERM_UNUSE #include /* strncmp()/memset() */ #include #include /* isdigit() */ #include "bl_debug.h" #include "bl_mem.h" /* alloca() */ #if 0 #define __DEBUG #endif /* --- static variables --- */ static char *abbrev_wdays[] = {"Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}; static char *wdays[] = {"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"}; static char *abbrev_months[] = {"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"}; static char *months[] = {"January", "Febrary", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"}; /* --- static functions --- */ /* * XXX * this should be placed in bl_str. */ static int strntoi(const char *str, size_t size) { int i = 0; char *format = NULL; /* * size should be 4 digits , or 0 - 999 */ if (size < 0 || 999 < size) { return 0; } if ((format = alloca(4 + 2)) == NULL) { /* the same spec as atoi() */ return 0; } sprintf(format, "%%%dd", size); sscanf(str, format, &i); return i; } /* --- global functions --- */ /* * this function converts the string date represented by the following format to *time_t. * the format is described by the characters below. * * supported format. * %Y year 1900- * %m month 0-11 * %d mday 1-31 * %H hour 0-23 * %S second 0-61 * * If you want to do the opposition of this function , use strftime(). * * XXX * these format characters are conformed to str{p|f}time() format charcters and *are * extended in some points e.g.) the num of length can be inserted between '%' * and a format character. */ time_t bl_time_string_date_to_time_t(const char *format, const char *date) { struct tm tm_info; char *date_dup = NULL; char *date_p = NULL; const char *format_p = NULL; if ((date_dup = alloca(strlen(date) + 1)) == NULL) { return -1; } strcpy(date_dup, date); format_p = format; date_p = date_dup; /* * we set default value. */ memset(&tm_info, 0, sizeof(struct tm)); tm_info.tm_mday = 1; /* [1-31] */ tm_info.tm_wday = 0; /* ignored by mktime() */ tm_info.tm_yday = 0; /* ignored by mktime() */ tm_info.tm_isdst = -1; /* we dont presume summer time */ #if 0 tm_info.tm_gmtoff = 0; /* offset from UTC in seconds */ tm_info.tm_zone = "UTC"; #endif while (*format_p && *date_p) { if (*format_p == '%') { int size = 0; format_p++; if (!*format_p) { /* strange format. */ return -1; } else if (*format_p == '%') { if (*date_p != '%') { /* strange format. */ return -1; } format_p++; date_p++; continue; } if (isdigit(*format_p)) { size = strntoi(format_p, 1); format_p++; } else { size = 1; } if (*format_p == 'Y') { if (size != 4) { /* we don't support before 1900. */ return -1; } tm_info.tm_year = strntoi(date_p, size) - 1900; date_p += size; } else if (*format_p == 'm') { if (size != 1 && size != 2) { return -1; } tm_info.tm_mon = strntoi(date_p, size) - 1; date_p += size; #ifdef __DEBUG bl_debug_printf("mon %d\n", tm_info.tm_mon); #endif } else if (*format_p == 'd') { if (size != 1 && size != 2) { return -1; } tm_info.tm_mday = strntoi(date_p, size); date_p += size; #ifdef __DEBUG bl_debug_printf("day %d\n", tm_info.tm_mday); #endif } else if (*format_p == 'H') { if (size != 1 && size != 2) { return -1; } tm_info.tm_hour = strntoi(date_p, size); date_p += size; #ifdef __DEBUG bl_debug_printf("hour %d\n", tm_info.tm_hour); #endif } else if (*format_p == 'M') { if (size != 1 && size != 2) { return -1; } tm_info.tm_min = strntoi(date_p, size); date_p += size; #ifdef __DEBUG bl_debug_printf("min %d\n", tm_info.tm_min); #endif } else if (*format_p == 'S') { if (size != 1 && size != 2) { return -1; } tm_info.tm_sec = strntoi(date_p, size); date_p += size; #ifdef __DEBUG bl_debug_printf("sec %d\n", tm_info.tm_sec); #endif } else { return -1; } format_p++; } else { date_p++; format_p++; } } if (*date_p != '\0' || *format_p != '\0') { return -1; } else { /* if fails , mktime returns -1. */ return mktime(&tm_info); } } struct tm *bl_time_string_date_to_tm(struct tm *tm_info, const char *format, const char *date) { time_t time = 0; if ((time = bl_time_string_date_to_time_t(format, date)) == -1) { return NULL; } return memcpy(tm_info, localtime(&time), sizeof(struct tm)); } /* * "Sun","Sunday" -> 0. * * XXX * we don't intend to support TIME locale , which means locale wdays for example *"" * will not be parsed. */ int bl_time_string_wday_to_int(const char *wday) { int count = 0; for (count = 0; count < 7; count++) { if (strcmp(wday, wdays[count]) == 0 || strcmp(wday, abbrev_wdays[count]) == 0) { return count; } } return -1; } /* * 0 -> "Sun" */ char *bl_time_int_wday_to_abbrev_string(int wday) { if (0 <= wday && wday < 6) { return abbrev_wdays[wday]; } else { return NULL; } } /* * 0 -> "Sunday" */ char *bl_time_int_wday_to_string(int wday) { if (0 <= wday && wday < 6) { return wdays[wday]; } else { return NULL; } } /* * "Jan","January" -> 0 */ int bl_time_string_month_to_int(const char *month) { int count = 0; for (count = 0; count < 12; count++) { if (strcmp(month, months[count]) == 0 || strcmp(month, abbrev_months[count]) == 0) { return count; } } return -1; } /* * 0 -> "January" */ char *bl_time_int_month_to_string(int month) { if (0 <= month && month < 6) { return months[month]; } else { return NULL; } } /* * 0 -> "Jan" */ char *bl_time_int_month_to_abbrev_string(int month) { if (0 <= month && month < 6) { return abbrev_months[month]; } else { return NULL; } } #endif /* REMOVE_FUNCS_MLTERM_UNUSE */ mlterm-3.9.3/baselib/src/bl_time.h000066400000000000000000000013711441203364000170010ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_TIME_H__ #define __BL_TIME_H__ #include #include "bl_def.h" /* REMOVE_FUNCS_MLTERM_UNUSE */ #ifndef REMOVE_FUNCS_MLTERM_UNUSE time_t bl_time_string_date_to_time_t(const char *format, const char *date); struct tm *bl_time_string_date_to_tm(struct tm *tm_info, const char *format, const char *date); int bl_time_string_wday_to_int(const char *wday); char *bl_time_int_wday_to_string(int wday); char *bl_time_int_wday_to_abbrev_string(int wday); int bl_time_string_month_to_int(const char *month); char *bl_time_int_month_to_string(int month); char *bl_time_int_month_to_abbrev_string(int month); #endif /* REMOVE_FUNCS_MLTERM_UNUSE */ #endif /* __BL_TIME_H__ */ mlterm-3.9.3/baselib/src/bl_types.h000066400000000000000000000007071441203364000172110ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_TYPES_H__ #define __BL_TYPES_H__ /* various AC_TYPEs are defined in bl_config.h */ #include "bl_config.h" #include #ifdef HAVE_SYS_BITYPES_H #include /* for OpenServer 6.0.0 */ #endif #ifdef HAVE_STDINT_H #include #endif /* only for tests */ #ifdef TEST_LP64 #define size_t bl_size_t typedef long long bl_size_t; #endif #endif mlterm-3.9.3/baselib/src/bl_unistd.c000066400000000000000000000023221441203364000173410ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_unistd.h" #include #include /* select */ #ifdef USE_WIN32API #include #endif /* --- global functions --- */ #ifndef HAVE_USLEEP int __bl_usleep(u_int microseconds) { #ifndef USE_WIN32API struct timeval tval; tval.tv_usec = microseconds % 1000000; tval.tv_sec = microseconds / 1000000; if (select(0, NULL, NULL, NULL, &tval) == 0) { return 0; } else { return -1; } #else Sleep(microseconds / 1000); /* sleep mili-seconds */ return 0; #endif /* USE_WIN32API */ } #endif /* HAVE_USLEEP */ #ifndef HAVE_SETENV #include #include #include /* putenv */ int __bl_setenv(const char *name, const char *value, int overwrite) { char *env; if (!overwrite && getenv(name)) { return 0; } /* XXX Memory leaks. */ if (!(env = malloc(strlen(name) + 1 + strlen(value) + 1))) { return -1; } sprintf(env, "%s=%s", name, value); return putenv(env); } #endif /* HAVE_SETENV */ #ifndef HAVE_GETUID uid_t __bl_getuid(void) { return 0; } #endif /* HAVE_GETUID */ #ifndef HAVE_GETGID gid_t __bl_getgid(void) { return 0; } #endif /* HAVE_GETGID */ mlterm-3.9.3/baselib/src/bl_unistd.h000066400000000000000000000032501441203364000173470ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_UNISTD_H__ #define __BL_UNISTD_H__ /* Wrapper functions of */ #include "bl_def.h" #include "bl_types.h" #ifdef HAVE_USLEEP #include #define bl_usleep(microsec) usleep(microsec) #else #define bl_usleep(microsec) __bl_usleep(microsec) int __bl_usleep(u_int microseconds); #endif #ifdef HAVE_SETENV #include #define bl_setenv(name, value, overwrite) setenv(name, value, overwrite) #else /* HAVE_SETENV */ #ifdef USE_WIN32API /* getenv() doesn't get the value set by bl_setenv(). */ #define bl_setenv(name, value, overwrite) SetEnvironmentVariableA(name, value) #else /* USE_WIN32API */ #define bl_setenv __bl_setenv int __bl_setenv(const char *name, const char *value, int overwrite); #endif /* USE_WIN32API */ #endif /* HAVE_SETENV */ #ifdef HAVE_UNSETENV #include #define bl_unsetenv(name) unsetenv(name) #else /* HAVE_SETENV */ #ifdef USE_WIN32API #define bl_unsetenv(name) SetEnvironmentVariableA(name, NULL) #else /* USE_WIN32API */ #define bl_unsetenv(name) bl_setenv(name, "", 1); #endif /* USE_WIN32API */ #endif /* HAVE_UNSETENV */ #ifdef HAVE_GETUID #include #define bl_getuid getuid #else #define bl_getuid __bl_getuid uid_t __bl_getuid(void); #endif #ifdef HAVE_GETGID #include #define bl_getgid getgid #else #define bl_getgid __bl_getgid gid_t __bl_getgid(void); #endif /* XXX vt_pty_unix.c which uses bl_killpg() has already included it. */ /* #include */ #ifdef HAVE_KILLPG #define bl_killpg(pid, sig) killpg(pid, sig) #else #define bl_killpg(pid, sig) kill(-pid, sig) #endif #endif mlterm-3.9.3/baselib/src/bl_util.c000066400000000000000000000125141441203364000170140ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_util.h" #include #include /* getenv */ #ifdef HAVE_GETPWUID #include #endif #include "bl_unistd.h" /* bl_getuid */ #include "bl_debug.h" /* --- static functions --- */ static int hex_to_int(char c) { if ('0' <= c && c <= '9') { return c - '0'; } else { c &= 0xdf; if ('A' <= c && c <= 'F') { return c - 'A' + 10; } } return -1; } static inline int get_pc(int h, u_int32_t m1, u_int32_t m2) { if (h < 60) { return m1 + (m2 - m1) * h / 60; } else if (h < 180) { return m2; } else if (h < 240) { return m1 + (m2 - m1) * (240 - h) / 60; } else { return m1; } } /* --- global functions --- */ size_t bl_hex_decode(char *decoded, const char *encoded, size_t e_len) { size_t pos; char *p = decoded; for (pos = 0; e_len > pos + 1; pos += 2) { int i1 = hex_to_int(encoded[pos]); int i2 = hex_to_int(encoded[pos + 1]); if (i1 < 0 || i2 < 0) { break; } *(p++) = i1 * 16 + i2; } return (p - decoded); } size_t bl_hex_encode(char *encoded, const char *decoded, size_t d_len) { size_t pos; char *p = encoded; for (pos = 0; d_len > pos; pos ++) { int h1 = (decoded[pos] >> 4) & 0xf; int h2 = decoded[pos] & 0xf; *(p++) = (h1 > 9) ? ('a' + h1 - 10) : ('0' + h1); *(p++) = (h2 > 9) ? ('a' + h2 - 10) : ('0' + h2); } return (p - encoded); } size_t bl_base64_decode(char *decoded, const char *encoded, size_t e_len) { size_t d_pos; size_t e_pos; /* ASCII -> Base64 order */ int8_t conv_tbl[] = {/* 0x2b - */ 62, -1, -1, -1, 63, /* 0x30 - */ 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, -1, -1, -1, -2, -1, -1, /* 0x40 - */ -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, /* 0x50 - */ 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, -1, -1, /* 0x60 - */ -1, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, /* 0x70 - 7a */ 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51}; d_pos = e_pos = 0; while (e_len >= e_pos + 4) { size_t count; int8_t bytes[4]; for (count = 0; count < 4; e_pos++) { if (encoded[e_pos] < 0x2b || 0x7a < encoded[e_pos] || (bytes[count] = conv_tbl[encoded[e_pos] - 0x2b]) == -1) { #ifdef DEBUG if (encoded[e_pos] != '\x0d' && encoded[e_pos] != '\x0a') { bl_debug_printf(BL_DEBUG_TAG " ignoring %c in base64\n", encoded[e_pos]); } #endif if (e_len <= e_pos + 1) { goto end; } } else { count++; } } decoded[d_pos++] = (((bytes[0] << 2) & 0xfc) | ((bytes[1] >> 4) & 0x3)); if (bytes[2] != -2) { decoded[d_pos++] = (((bytes[1] << 4) & 0xf0) | ((bytes[2] >> 2) & 0xf)); } else { break; } if (bytes[3] != -2) { decoded[d_pos++] = (((bytes[2] << 6) & 0xc0) | (bytes[3] & 0x3f)); } else { break; } } end: #ifdef DEBUG decoded[d_pos] = '\0'; if (strlen(encoded) < 1000) { bl_debug_printf(BL_DEBUG_TAG " Base64 Decode %s => %s\n", encoded, decoded); } #endif return d_pos; } void bl_hls_to_rgb(int *r, int *g, int *b, int h /* 0-360 */, int l /* 0-100 */, int s /* 0-100 */) { if (s == 0) { *r = *g = *b = l * 255 / 100; } else { u_int32_t m1; u_int32_t m2; if (l < 50) { m2 = l * (100 + s); } else { m2 = (l + s) * 100 - l * s; } m1 = l * 200 - m2; *r = get_pc(h, m1, m2) * 255 / 10000; if ((h -= 120) < 0) { h += 360; } *g = get_pc(h, m1, m2) * 255 / 10000; if ((h -= 120) < 0) { h += 360; } *b = get_pc(h, m1, m2) * 255 / 10000; } } void bl_rgb_to_hls(int *h, int *l, int *s, int r /* 0-255 */, int g /* 0-255 */, int b /* 0-255 */) { int max; int min; if (r > g) { if (g > b) { /* r > g > b */ max = r; min = b; } else { min = g; if (r > b) { /* r > b >= g */ max = r; } else { /* b >= r > g */ max = b; } } } else if (b > g) { /* b > g >= r */ max = b; min = r; } else { max = g; if (r > b) { /* g >= r > b */ min = b; } else { /* g >= b >= r */ min = r; } } *l = (max + min) * 100 / 255 / 2; if (max == min) { /* r == g == b */ *h = 0; *s = 0; } else { if (max == r) { *h = 60 * (g - b) / (max - min); } else if (max == g) { *h = 60 * (b - r) / (max - min) + 120; } else /* if (max == b) */ { *h = 60 * (r - g) / (max - min) + 240; } if (*h < 0) { *h += 360; } if (max + min < 255) { *s = (max - min) * 100 / (max + min); } else { *s = (max - min) * 100 / (510 - max - min); } } } const char *bl_get_user_name(void) { char *user; #ifdef HAVE_WINDOWS_H if (!(user = getenv("USERNAME"))) #endif { if (!(user = getenv("USER"))) { user = getenv("LOGNAME"); #ifdef HAVE_GETPWUID if (!user) { struct passwd *p; if ((p = getpwuid(bl_getuid()))) { user = p->pw_name; } } #endif } } return user; } mlterm-3.9.3/baselib/src/bl_util.h000066400000000000000000000051741441203364000170250ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_UTIL_H__ #define __BL_UTIL_H__ #if defined(NetBSD) || defined(FreeBSD) #include /* __FreeBSD_version, __NetBSD_Version */ #endif #include "bl_def.h" /* WORDS_BIGENDIAN */ #include "bl_types.h" /* u_int32_t */ #if (defined(__NetBSD_Version__) && (__NetBSD_Version__ >= 300000000)) || \ (defined(__FreeBSD_version) && (__FreeBSD_version >= 501000)) #include #define BE32DEC(p) be32dec(p) #define BE16DEC(p) be16dec(p) #define LE32DEC(p) le32dec(p) #define LE16DEC(p) le16dec(p) #else /* p is unsigned char */ #define BE32DEC(p) (((u_int32_t)(p)[0] << 24) | ((p)[1] << 16) | ((p)[2] << 8) | (p)[3]) #define BE16DEC(p) (((p)[0] << 8) | (p)[1]) #define LE32DEC(p) (((u_int32_t)(p)[3] << 24) | ((p)[2] << 16) | ((p)[1] << 8) | (p)[0]) #define LE16DEC(p) (((p)[1] << 8) | (p)[0]) #endif /* p is "unsigned char *". __NO_STRICT_ALIGNMENT is defined in sys/types.h of * *BSD */ #if defined(__NO_STRICT_ALIGNMENT) || defined(__i386) #define TOINT32(p) (*((u_int32_t *)(p))) #define TOINT16(p) (*((u_int16_t *)(p))) #elif defined(WORDS_BIGENDIAN) #define TOINT32(p) BE32DEC(p) #define TOINT16(p) BE16DEC(p) #else #define TOINT32(p) LE32DEC(p) #define TOINT16(p) LE16DEC(p) #endif #define BL_MAX(n1, n2) ((n1) > (n2) ? (n1) : (n2)) #define BL_MIN(n1, n2) ((n1) > (n2) ? (n2) : (n1)) /* TYPE: MIN(signed) -- MAX(unsigned) (number of bytes needed) * char : -128 -- 256 (4) * int16 : -32768 -- 65536 (6) * int32 : -2147483648 -- 4294967296 (11) * int64 : -9223372036854775808 -- 18446744073709551616 (20) * * Since log10(2^8) = 2.4..., (sizeof(n)*3) is large enough * for all n >= 2. */ #define DIGIT_STR_LEN(n) \ ((sizeof(n) == 1) ? 4 : (sizeof(n) == 2) ? 6 : (sizeof(n) == 4) ? 11 : (sizeof(n) == 8) \ ? 20 \ : (sizeof(n) * 3)) #define BL_INT_TO_STR(i) _BL_INT_TO_STR(i) #define _BL_INT_TO_STR(i) #i #define BL_SWAP(t, a, b) { t tmp; tmp = (a); (a) = (b); (b) = tmp; } #define BL_ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0])) size_t bl_hex_decode(char *decoded, const char *encoded, size_t e_len); size_t bl_hex_encode(char *encoded, const char *decoded, size_t d_len); size_t bl_base64_decode(char *decoded, const char *encoded, size_t e_len); void bl_hls_to_rgb(int *r, int *g, int *b, int h, int l, int s); void bl_rgb_to_hls(int *h, int *l, int *s, int r, int g, int b); const char *bl_get_user_name(void); #endif mlterm-3.9.3/baselib/src/bl_utmp.h000066400000000000000000000004111441203364000170220ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __BL_UTMP_H__ #define __BL_UTMP_H__ typedef struct bl_utmp *bl_utmp_t; bl_utmp_t bl_utmp_new(const char *tty, const char *host, int pty_fd); void bl_utmp_destroy(bl_utmp_t utmp); #endif mlterm-3.9.3/baselib/src/bl_utmp_bsd.c000066400000000000000000000116411441203364000176540ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_utmp.h" #include /* sscanf */ #include /* strncpy */ #include /* open */ #include #include /* write/close/getuid/getgid */ #include /* getpwuid */ #include /* stat */ #include #include #include "bl_types.h" /* off_t */ #include "bl_util.h" /* BL_MIN */ #include "bl_mem.h" /* malloc/free */ #include "bl_privilege.h" /* * These four macros are directly used in this file. * They appeared at least in 4.4BSD-Lite according to NetBSD cvs repository. */ #ifndef UT_LINESIZE #error "UT_LINESIZE is not defined." #endif #ifndef _PATH_UTMP #error "_PATH_UTMP is not defined." #endif #ifndef _PATH_WTMP #error "_PATH_WTMP is not defined." #endif #ifndef _PATH_LASTLOG #error "_PATH_LASTLOG is not defined." #endif struct bl_utmp { char ut_line[UT_LINESIZE]; int ut_pos; }; /* --- static functions --- */ static int write_utmp(struct utmp *ut, int pos) { int fd; if ((fd = open(_PATH_UTMP, O_WRONLY)) == -1 || lseek(fd, (off_t)(pos * sizeof(*ut)), SEEK_SET) == -1) { return 0; } write(fd, ut, sizeof(*ut)); close(fd); return 1; } static int write_wtmp(struct utmp *ut, int pos) { int fd; int locked; int retry; struct flock lck; /* fcntl locking scheme */ struct stat st; int result; if ((fd = open(_PATH_WTMP, O_WRONLY | O_APPEND, 0)) < 0) { return 0; } lck.l_whence = SEEK_END; /* lock from current eof */ lck.l_len = 0; /* end at "largest possible eof" */ lck.l_start = 0; lck.l_type = F_WRLCK; /* write lock */ locked = 0; for (retry = 0; retry < 10; retry++) { /* * lock with F_SETLK. * F_SETLKW would cause a deadlock. */ if (fcntl(fd, F_SETLK, &lck) != -1) { locked = 1; break; } else if (errno != EAGAIN && errno != EACCES) { break; } } if (!locked) { close(fd); return 0; } result = 0; if (fstat(fd, &st) == 0) { if (write(fd, ut, sizeof(*ut)) != sizeof(*ut)) { /* removing bad writes */ ftruncate(fd, st.st_size); } else { result = 1; } } lck.l_type = F_UNLCK; fcntl(fd, F_SETLK, &lck); close(fd); return result; } static int write_lastlog(struct lastlog *ll, uid_t uid) { int fd; int result; result = 0; if ((fd = open(_PATH_LASTLOG, O_RDWR)) != -1) { if (lseek(fd, (off_t)(uid * sizeof(*ll)), SEEK_SET) != -1) { write(fd, ll, sizeof(*ll)); result = 1; } close(fd); } return result; } /* --- global functions --- */ bl_utmp_t bl_utmp_new(const char *tty, const char *host, int pty_fd /* not used */ ) { bl_utmp_t utmp; struct utmp ut; struct lastlog ll; FILE *fp; struct passwd *pwent; char *pw_name; char buf[256]; char buf2[256]; if ((utmp = malloc(sizeof(*utmp))) == NULL) { return NULL; } memset(&ut, 0, sizeof(ut)); memset(&ll, 0, sizeof(ll)); ll.ll_time = ut.ut_time = time(NULL); memcpy(ut.ut_host, host, BL_MIN(sizeof(ut.ut_host), strlen(host))); memcpy(ll.ll_host, host, BL_MIN(sizeof(ll.ll_host), strlen(host))); if ((pwent = getpwuid(getuid())) == NULL || pwent->pw_name == NULL) { pw_name = "?"; } else { pw_name = pwent->pw_name; } strncpy(ut.ut_name, pw_name, BL_MIN(sizeof(ut.ut_name), strlen(pw_name))); if (strncmp(tty, "/dev/", 5) == 0) { /* skip /dev/ prefix */ tty += 5; } if (strncmp(tty, "pty", 3) != 0 && strncmp(tty, "tty", 3) != 0) { goto error; } memcpy(ut.ut_line, tty, BL_MIN(sizeof(ut.ut_line), strlen(tty))); memcpy(ll.ll_line, tty, BL_MIN(sizeof(ll.ll_line), strlen(tty))); memcpy(utmp->ut_line, ut.ut_line, sizeof(ut.ut_line)); if ((fp = fopen("/etc/ttys", "r")) == NULL && (fp = fopen("/etc/ttytab", "r")) == NULL) { goto error; } utmp->ut_pos = 1; while (1) { if (!fgets(buf, sizeof(buf), fp)) { goto error; } if (*buf != '#' && sscanf(buf, "%s", buf2) == 1) { if (strcmp(tty, buf2) == 0) { break; } } utmp->ut_pos++; } fclose(fp); bl_priv_restore_euid(); bl_priv_restore_egid(); if (!write_utmp(&ut, utmp->ut_pos)) { goto error; } write_wtmp(&ut, utmp->ut_pos); write_lastlog(&ll, pwent->pw_uid); bl_priv_change_euid(getuid()); bl_priv_change_egid(getgid()); return utmp; error: bl_priv_change_euid(getuid()); bl_priv_change_egid(getgid()); free(utmp); return NULL; } void bl_utmp_destroy(bl_utmp_t utmp) { struct utmp ut; bl_priv_restore_euid(); bl_priv_restore_egid(); memset(&ut, 0, sizeof(ut)); write_utmp(&ut, utmp->ut_pos); ut.ut_time = time(NULL); memcpy(ut.ut_line, utmp->ut_line, sizeof(utmp->ut_line)); memset(ut.ut_name, 0, sizeof(ut.ut_name)); memset(ut.ut_host, 0, sizeof(ut.ut_host)); write_wtmp(&ut, utmp->ut_pos); bl_priv_change_euid(getuid()); bl_priv_change_egid(getgid()); free(utmp); } mlterm-3.9.3/baselib/src/bl_utmp_login.c000066400000000000000000000050331441203364000202120ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_utmp.h" #include /* NULL */ #include #include #include /* getuid */ #include /* strncmp */ #include /* time */ #if 1 /* *BSD has utmp.h anyway though login/logout aren't defined in it */ #include /* login/logout(glibc2) you have to link libutil. */ #endif #if 0 /* glibc(linux) doesn't have util.h */ #include /* login/logout(*BSD) you have to link libutil. */ #endif #include "bl_util.h" /* BL_MIN */ #include "bl_mem.h" /* malloc/free */ #include "bl_def.h" /* HAVE_SETUTENT */ #include "bl_privilege.h" struct bl_utmp { char ut_line[UT_LINESIZE]; }; /* --- global functions --- */ bl_utmp_t bl_utmp_new(const char *tty, const char *host, int pty_fd) { bl_utmp_t utmp; struct utmp ut; struct passwd *pwent; char *pw_name; if ((utmp = malloc(sizeof(*utmp))) == NULL) { return NULL; } /* unnecessary ? */ #if 0 #ifdef HAVE_SETUTENT setutent(); #endif #endif memset(&ut, 0, sizeof(ut)); if ((pwent = getpwuid(getuid())) == NULL || pwent->pw_name == NULL) { pw_name = "?"; } else { pw_name = pwent->pw_name; } /* * user name field is named ut_name in *BSD and is ut_user in glibc2 , * but glibc2 also defines ut_name as an alias of ut_user for backward * compatibility. */ strncpy(ut.ut_name, pw_name, BL_MIN(sizeof(ut.ut_name) - 2, strlen(pw_name))); ut.ut_name[sizeof(ut.ut_name) - 1] = 0; if (strncmp(tty, "/dev/", 5) == 0) { /* skip /dev/ prefix */ tty += 5; } if (strncmp(tty, "pts", 3) != 0 && strncmp(tty, "pty", 3) != 0 && strncmp(tty, "tty", 3) != 0) { free(utmp); return NULL; } #ifndef HAVE_SETUTENT /* ut.ut_line must be filled before login() on bsd. */ memcpy(ut.ut_line, tty, BL_MIN(sizeof(ut.ut_line), strlen(tty))); #endif ut.ut_time = time(NULL); memcpy(ut.ut_host, host, BL_MIN(sizeof(ut.ut_host), strlen(host))); bl_priv_restore_euid(); /* useless? */ bl_priv_restore_egid(); /* login does not give us error information... */ login(&ut); bl_priv_change_euid(getuid()); bl_priv_change_egid(getgid()); memcpy(utmp->ut_line, ut.ut_line, sizeof(utmp->ut_line)); return utmp; } void bl_utmp_destroy(bl_utmp_t utmp) { bl_priv_restore_euid(); bl_priv_restore_egid(); logout(utmp->ut_line); logwtmp(utmp->ut_line, "", ""); bl_priv_change_euid(getuid()); bl_priv_change_egid(getgid()); /* unnecessary ? */ #if 0 #ifdef HAVE_SETUTENT endutent(); #endif #endif free(utmp); } mlterm-3.9.3/baselib/src/bl_utmp_none.c000066400000000000000000000004271441203364000200430ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_utmp.h" #include /* NULL */ /* --- global functions --- */ bl_utmp_t bl_utmp_new(const char *tty, const char *host, int pty_fd) { return NULL; } void bl_utmp_destroy(bl_utmp_t utmp) {} mlterm-3.9.3/baselib/src/bl_utmp_sysv.c000066400000000000000000000107441441203364000201130ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* Sample implementation - who/w works; finger doesn't (WHY ??) */ #include "bl_utmp.h" #include /* NULL */ #include #include /* strncmp */ #include /* time */ #ifdef USE_UTMPX #include /* getut*, setut*, etc */ #else #include /* getut*, setut*, etc */ #endif #include /* timeval */ #include /* getuid */ #include "bl_util.h" /* BL_MIN */ #include "bl_mem.h" /* malloc/free */ #include "bl_privilege.h" #include "bl_debug.h" #ifdef _PATH_UTMP_UPDATE #include #endif #ifdef USE_UTMPX #define LINE_WIDTH 32 #else #define LINE_WIDTH 12 #endif struct bl_utmp { char ut_line[LINE_WIDTH]; char ut_pos[4]; }; /* --- static functions --- */ static const char *get_pw_name(void) { struct passwd *pwent; if (((pwent = getpwuid(getuid())) == NULL) || (pwent->pw_name == NULL)) { return "?"; } else { return pwent->pw_name; } } /* --- global functions --- */ bl_utmp_t bl_utmp_new(const char *tty, const char *host, int pty_fd) { #ifdef USE_UTMPX struct utmpx ut; #else struct utmp ut; #endif bl_utmp_t utmp; const char *pw_name; char *tty_num; struct timeval timenow; gettimeofday(&timenow, NULL); if ((utmp = calloc(1, sizeof(*utmp))) == NULL) { return NULL; } memset(&ut, 0, sizeof(ut)); if ((strncmp(tty, "/dev/", 5)) == 0) { /* skip /dev/ prefix */ tty += 5; } if ((strncmp(tty, "pts", 3) != 0) && (strncmp(tty, "pty", 3) != 0) && (strncmp(tty, "tty", 3) != 0)) { free(utmp); return NULL; } if ((tty_num = strchr(tty, '/'))) { tty_num++; } else if (strncmp(tty + 1, "typ", 3) == 0) { /* /dev/ttypN or /dev/ptypN */ tty_num = tty + 4; } else if (strncmp(tty, "ttys", 4) == 0) { /* /dev/ttys00N (MacOSX) */ tty_num = tty + 4; tty += 3; /* s00N */ } else { free(utmp); return NULL; } pw_name = get_pw_name(); strncpy(ut.ut_user, pw_name, BL_MIN(sizeof(ut.ut_user), strlen(pw_name))); memcpy(ut.ut_id, tty_num, BL_MIN(sizeof(ut.ut_id), strlen(tty_num))); memcpy(ut.ut_line, tty, BL_MIN(sizeof(ut.ut_line), strlen(tty))); ut.ut_pid = getpid(); ut.ut_type = USER_PROCESS; #ifdef USE_UTMPX ut.ut_tv.tv_sec = timenow.tv_sec; ut.ut_tv.tv_usec = timenow.tv_usec; #else ut.ut_time = time(NULL); #endif #ifdef USE_UTMPX memcpy(ut.ut_host, host, BL_MIN(sizeof(ut.ut_host), strlen(host))); #if !defined(__FreeBSD__) && !defined(__APPLE__) && !defined(__CYGWIN__) && !defined(__MSYS__) ut.ut_session = getsid(0); #endif #endif memcpy(utmp->ut_line, tty, BL_MIN(sizeof(utmp->ut_line), strlen(tty))); memcpy(utmp->ut_pos, tty_num, BL_MIN(sizeof(utmp->ut_pos), strlen(tty_num))); bl_priv_restore_euid(); /* useless? */ bl_priv_restore_egid(); /* reset the input stream to the beginning of the file */ #ifdef USE_UTMPX setutxent(); #else setutent(); #endif /* insert new entry */ #ifdef USE_UTMPX if (!pututxline(&ut)) { #ifdef _PATH_UTMP_UPDATE /* NetBSD calls waitpid() for utmp_update which is executed as root(SUID) * and fails(ECHILD). */ if (errno != ECHILD) #endif { free(utmp); utmp = NULL; } } #else /* pututline doesn't return value in XPG2 and SVID2 */ pututline(&ut); #endif #ifdef DEBUG if (!utmp) { bl_debug_printf(BL_DEBUG_TAG "pututline failed. EUID %d EGID %d => ", geteuid(), getegid()); perror(NULL); } #endif #ifdef USE_UTMPX endutxent(); #else endutent(); #endif bl_priv_change_euid(getuid()); bl_priv_change_egid(getgid()); return utmp; } void bl_utmp_destroy(bl_utmp_t utmp) { #ifdef USE_UTMPX struct utmpx ut; #else struct utmp ut; #endif const char *pw_name; memset(&ut, 0, sizeof(ut)); pw_name = get_pw_name(); strncpy(ut.ut_user, pw_name, BL_MIN(sizeof(ut.ut_user), strlen(pw_name))); memcpy(ut.ut_id, utmp->ut_pos, BL_MIN(sizeof(ut.ut_id), sizeof(utmp->ut_pos))); memcpy(ut.ut_line, utmp->ut_line, BL_MIN(sizeof(ut.ut_line), sizeof(utmp->ut_line))); ut.ut_pid = getpid(); ut.ut_type = DEAD_PROCESS; #ifdef USE_UTMPX ut.ut_tv.tv_sec = 0; ut.ut_tv.tv_usec = 0; #else ut.ut_time = 0; #endif bl_priv_restore_euid(); bl_priv_restore_egid(); /* reset the input stream to the beginning of the file */ #ifdef USE_UTMPX setutxent(); pututxline(&ut); endutxent(); #else setutent(); pututline(&ut); endutent(); #endif bl_priv_change_euid(getuid()); bl_priv_change_egid(getgid()); free(utmp); } mlterm-3.9.3/baselib/src/bl_utmp_utmper.c000066400000000000000000000015441441203364000204210ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "bl_utmp.h" #include /* NULL */ #include #include "bl_mem.h" /* malloc/free */ #include "bl_str.h" /* strdup */ struct bl_utmp { char *tty; int fd; }; /* --- global functions --- */ bl_utmp_t bl_utmp_new(const char *tty, const char *host, int pty_fd) { bl_utmp_t utmp; if ((utmp = malloc(sizeof(*utmp))) == NULL) { return NULL; } if ((utmp->tty = strdup(tty)) == NULL) { free(utmp); return NULL; } utmp->fd = pty_fd; #ifdef UTEMPTER_NEW_API utempter_add_record(pty_fd, host); #else addToUtmp(tty, host, pty_fd); #endif return utmp; } void bl_utmp_destroy(bl_utmp_t utmp) { #ifdef UTEMPTER_NEW_API utempter_remove_record(utmp->fd); #else removeLineFromUtmp(utmp->tty, utmp->fd); #endif free(utmp->tty); free(utmp); } mlterm-3.9.3/cocoa/000077500000000000000000000000001441203364000141075ustar00rootroot00000000000000mlterm-3.9.3/cocoa/build-ios43.sh000077500000000000000000000007011441203364000165020ustar00rootroot00000000000000#!/bin/sh if [ $# -ne 1 ]; then echo "Usage: build-iphonesim.sh [install prefix]" exit 0 fi dir=`dirname $0` export SDKROOT="/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.3.sdk" export CFLAGS="-g -D__arm__=1" $dir/../configure --prefix=$1 --with-gui=quartz --host=arm-apple-darwin --disable-shared --disable-fribidi --disable-ssh2 --disable-otl --without-tools --enable-debug --with-ios-sdk=iphoneos4.3 --with-ios-arch=armv7 mlterm-3.9.3/cocoa/build-iossim43.sh000077500000000000000000000010371441203364000172160ustar00rootroot00000000000000#!/bin/sh if [ $# -ne 1 ]; then echo "Usage: build-iphonesim.sh [install prefix]" exit 0 fi dir=`dirname $0` export SDKROOT="/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk" export CFLAGS="-g -fobjc-abi-version=2 -fobjc-legacy-dispatch -D__IPHONE_OS_VERSION_MIN_REQUIRED=40300" $dir/../configure --prefix=$1 --with-gui=quartz --host=i686-apple-darwin --disable-shared --disable-fribidi --disable-ssh2 --disable-otl --without-tools --enable-debug --with-ios-sdk=iphonesimulator4.3 --with-ios-arch=i686 mlterm-3.9.3/cocoa/build-iossim71.sh000077500000000000000000000006251441203364000172210ustar00rootroot00000000000000#!/bin/sh if [ $# -ne 1 ]; then echo "Usage: build-iphonesim.sh [install prefix]" exit 0 fi dir=`dirname $0` export CFLAGS="-g -fobjc-abi-version=2 -fobjc-legacy-dispatch" $dir/../configure --prefix=$1 --with-gui=quartz --host=x86_64-apple-darwin --disable-shared --disable-fribidi --disable-ssh2 --disable-otl --without-tools --enable-debug --with-ios-sdk=iphonesimulator7.1 --with-ios-arch=x86_64 mlterm-3.9.3/cocoa/install-ios.sh000077500000000000000000000005641441203364000167110ustar00rootroot00000000000000#!/bin/sh if [ $# != 1 ]; then echo "Usage: install-ios.sh [installed prefix]" exit fi if [ ! -d $HOME/mlterm-ios.app ]; then echo "Copy top_srcdir/cocoa/mlterm-ios.app to $HOME/" exit fi prefix="${1}" cd $HOME/mlterm-ios.app mkdir -p etc/mlterm cp -f $prefix/etc/mlterm/* etc/mlterm/ rm mlterm/*aafont rm mlterm/font-fb rm mlterm/[tv]font cp $prefix/bin/mlterm . mlterm-3.9.3/cocoa/install-sdl2.sh000077500000000000000000000032071441203364000167600ustar00rootroot00000000000000#!/bin/sh if [ $# != 1 ]; then echo "Usage: install-sdl2.sh [installed prefix]" exit fi if [ ! -d $HOME/mlterm-sdl2.app ]; then echo "Copy top_srcdir/cocoa/mlterm.app to $HOME/mlterm-sdl2" exit fi prefix="${1}" cd $HOME/mlterm-sdl2.app mkdir -p mlterm cp -f $prefix/etc/mlterm/* mlterm/ rm mlterm/*aafont rm mlterm/font-fb rm mlterm/[tv]font mkdir -p $HOME/mlterm-sdl2.app/Contents/MacOS cd $HOME/mlterm-sdl2.app/Contents/MacOS libs="lib/libpobl.[0-9]*.dylib lib/libmef.[0-9]*.dylib lib/libmlterm_core.dylib lib/libmlterm_coreotl.dylib lib/mlterm/libctl_bidi.so lib/mlterm/libctl_iscii.so lib/mlterm/libind_bengali.so lib/mlterm/libind_hindi.so lib/mlterm/libotl.so lib/mlterm/libim-skk-sdl2.so lib/mlterm/libim-kbd-sdl2.so lib/mlterm/libzmodem.so" mkdir -p lib/mef mkdir -p lib/mlterm for file in $libs lib/mef/lib*.so ; do cp -f $prefix/$file `dirname $file`/ done for file in bin/mlterm-sdl2 libexec/mlterm/mlconfig ; do cp -f $prefix/$file . done for file in $libs mlterm-sdl2 mlconfig ; do if [ -f $file ]; then echo "Update $file" for lib in $libs ; do install_name_tool -change $prefix/$lib @executable_path/$lib $file done fi done if [ -f lib/mlterm/libotl.so ]; then libhb=`otool -L lib/mlterm/libotl.so |sed -n 's/[^/]*\(.*harfbuzz.*dylib\).*/\1/p'` if [ "$libhb" != "" ]; then install_name_tool -change $libhb \ @executable_path/lib/gtk/libharfbuzz.0.dylib lib/mlterm/libotl.so fi libotf=`otool -L lib/mlterm/libotl.so |sed -n 's/[^/]*\(.*otf.*dylib\).*/\1/p'` if [ "$libotf" != "" ]; then install_name_tool -change $libotf \ @executable_path/lib/gtk/libotf.0.dylib lib/mlterm/libotl.so fi fi mv mlterm-sdl2 mlterm mlterm-3.9.3/cocoa/install.sh000077500000000000000000000031421441203364000161140ustar00rootroot00000000000000#!/bin/sh if [ $# != 1 ]; then echo "Usage: install.sh [installed prefix]" exit fi if [ ! -d $HOME/mlterm.app ]; then echo "Copy top_srcdir/cocoa/mlterm.app to $HOME/" exit fi prefix="${1}" cd $HOME/mlterm.app mkdir -p mlterm cp -f $prefix/etc/mlterm/* mlterm/ rm mlterm/*aafont rm mlterm/font-fb rm mlterm/[tv]font mkdir -p $HOME/mlterm.app/Contents/MacOS cd $HOME/mlterm.app/Contents/MacOS libs="lib/libpobl.[0-9]*.dylib lib/libmef.[0-9]*.dylib lib/libmlterm_core.dylib lib/libmlterm_coreotl.dylib lib/mlterm/libctl_bidi.so lib/mlterm/libctl_iscii.so lib/mlterm/libind_bengali.so lib/mlterm/libind_hindi.so lib/mlterm/libotl-quartz.so lib/mlterm/libim-skk.so lib/mlterm/libim-kbd.so lib/mlterm/libzmodem.so" mkdir -p lib/mef mkdir -p lib/mlterm for file in $libs lib/mef/lib*.so ; do cp -f $prefix/$file `dirname $file`/ done for file in bin/mlterm libexec/mlterm/mlconfig ; do cp -f $prefix/$file . done for file in $libs mlterm mlconfig ; do if [ -f $file ]; then echo "Update $file" for lib in $libs ; do install_name_tool -change $prefix/$lib @executable_path/$lib $file done fi done if [ -f lib/mlterm/libotl-quartz.so ]; then libhb=`otool -L lib/mlterm/libotl-quartz.so |sed -n 's/[^/]*\(.*harfbuzz.*dylib\).*/\1/p'` if [ "$libhb" != "" ]; then install_name_tool -change $libhb \ @executable_path/lib/gtk/libharfbuzz.0.dylib lib/mlterm/libotl-quartz.so fi libotf=`otool -L lib/mlterm/libotl-quartz.so |sed -n 's/[^/]*\(.*otf.*dylib\).*/\1/p'` if [ "$libotf" != "" ]; then install_name_tool -change $libotf \ @executable_path/lib/gtk/libotf.0.dylib lib/mlterm/libotl-quartz.so fi fi mlterm-3.9.3/cocoa/lipo.sh000077500000000000000000000003641441203364000154140ustar00rootroot00000000000000#!/bin/sh if [ $# != 3 ]; then echo "Create multi-arch binary" echo "usage: lipo.sh [binary1] [binary2] [output]" exit fi /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo -create $1 $2 -output $3 mlterm-3.9.3/cocoa/mlterm-ios.app/000077500000000000000000000000001441203364000167565ustar00rootroot00000000000000mlterm-3.9.3/cocoa/mlterm-ios.app/Info.plist000077500000000000000000000022401441203364000207270ustar00rootroot00000000000000bplist00 '+789<=\CFBundleName_CFBundleIdentifier_CFBundleInfoDictionaryVersion_UIRequiredDeviceCapabilities_CFBundleVersion_CFBundleExecutable_LSRequiresIPhoneOS^UILaunchImages_ UISupportedInterfaceOrientations_CFBundleDisplayName_UILaunchImages~ipad_CFBundlePackageType_CFBundleSignature^UIDeviceFamily_CFBundleDevelopmentRegion_%UISupportedInterfaceOrientations~ipad_CFBundleShortVersionStringVmlterm_arakiken.mltermS6.0Uarmv7S1.0 # !"_UILaunchImageOrientation_UILaunchImageName_UILaunchImageSize_UILaunchImageMinimumOSVersionXPortrait_LaunchImage-480hZ{320, 480}S4.0$%&_LaunchImage-568hZ{320, 568}S7.0()*_UIInterfaceOrientationPortrait_#UIInterfaceOrientationLandscapeLeft_$UIInterfaceOrientationLandscapeRight,/25-."_LaunchImage-1024h[{768, 1024}01."YLandscape_LaunchImage-768h34&_LaunchImage-2732h\{2048, 2732}064&_LaunchImage-2048hTAPPLT????:;Q1Q2Ren(>)*_(UIInterfaceOrientationPortraitUpsideDown-:Oo(>Ra}';[dw#(1EQZdw?mlterm-3.9.3/cocoa/mlterm-ios.app/Makefile000066400000000000000000000000761441203364000204210ustar00rootroot00000000000000all: plutil -convert binary1 mlterm-Info.plist -o Info.plist mlterm-3.9.3/cocoa/mlterm-ios.app/PkgInfo000066400000000000000000000000101441203364000202250ustar00rootroot00000000000000APPL????mlterm-3.9.3/cocoa/mlterm-ios.app/mlterm-Info.plist000066400000000000000000000064221441203364000222300ustar00rootroot00000000000000 CFBundleDevelopmentRegion en CFBundleDisplayName mlterm CFBundleExecutable mlterm CFBundleIdentifier arakiken.mlterm CFBundleInfoDictionaryVersion 6.0 CFBundleName mlterm CFBundlePackageType APPL CFBundleShortVersionString 1.0 CFBundleSignature ???? CFBundleVersion 1.0 LSRequiresIPhoneOS UIRequiredDeviceCapabilities armv7 UIDeviceFamily 1 2 UISupportedInterfaceOrientations UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UISupportedInterfaceOrientations~ipad UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UILaunchImages UILaunchImageMinimumOSVersion 4.0 UILaunchImageName LaunchImage-480h UILaunchImageOrientation Portrait UILaunchImageSize {320, 480} UILaunchImageMinimumOSVersion 7.0 UILaunchImageName LaunchImage-568h UILaunchImageOrientation Portrait UILaunchImageSize {320, 568} UILaunchImages~ipad UILaunchImageMinimumOSVersion 4.0 UILaunchImageName LaunchImage-1024h UILaunchImageOrientation Portrait UILaunchImageSize {768, 1024} UILaunchImageMinimumOSVersion 4.0 UILaunchImageName LaunchImage-768h UILaunchImageOrientation Landscape UILaunchImageSize {768, 1024} UILaunchImageMinimumOSVersion 7.0 UILaunchImageName LaunchImage-2732h UILaunchImageOrientation Portrait UILaunchImageSize {2048, 2732} UILaunchImageMinimumOSVersion 7.0 UILaunchImageName LaunchImage-2048h UILaunchImageOrientation Landscape UILaunchImageSize {2048, 2732} mlterm-3.9.3/cocoa/mlterm.app/000077500000000000000000000000001441203364000161665ustar00rootroot00000000000000mlterm-3.9.3/cocoa/mlterm.app/Contents/000077500000000000000000000000001441203364000177635ustar00rootroot00000000000000mlterm-3.9.3/cocoa/mlterm.app/Contents/Info.plist000066400000000000000000000015321441203364000217340ustar00rootroot00000000000000 CFBundleDevelopmentRegion English CFBundleExecutable mlterm CFBundleIconFile CFBundleIdentifier mlterm CFBundleInfoDictionaryVersion 6.0 CFBundleName mlterm CFBundlePackageType APPL CFBundleShortVersionString mlterm CFBundleSignature ???? CFBundleVersion 1.0 NSMainNibFile Main NSPrincipalClass NSApplication mlterm-3.9.3/cocoa/mlterm.app/Contents/PkgInfo000066400000000000000000000000101441203364000212320ustar00rootroot00000000000000APPL????mlterm-3.9.3/cocoa/mlterm.app/Contents/Resources/000077500000000000000000000000001441203364000217355ustar00rootroot00000000000000mlterm-3.9.3/cocoa/mlterm.app/Contents/Resources/English.lproj/000077500000000000000000000000001441203364000244535ustar00rootroot00000000000000mlterm-3.9.3/cocoa/mlterm.app/Contents/Resources/English.lproj/InfoPlist.strings000066400000000000000000000002161441203364000277740ustar00rootroot00000000000000/* Localized versions of Info.plist keys */ CFBundleName = "mlterm"; mlterm-3.9.3/cocoa/mlterm.app/Contents/Resources/English.lproj/Main.nib/000077500000000000000000000000001441203364000261065ustar00rootroot00000000000000mlterm-3.9.3/cocoa/mlterm.app/Contents/Resources/English.lproj/Main.nib/designable.nib000066400000000000000000000156421441203364000307050ustar00rootroot00000000000000 1060 10D575 732 1038.29 460.00 com.apple.InterfaceBuilder.CocoaPlugin 732 com.apple.InterfaceBuilder.CocoaPlugin NSApplication FirstResponder NSApplication 15 2 {{0, 400}, {400, 400}} 813170688 mlterm NSWindow View {1.79769e+308, 1.79769e+308} {100, 100} 18 {400, 400} MLTermView {400, 400} {{0, 0}, {1440, 878}} {100, 122} {1.79769e+308, 1.79769e+308} 0 -2 File's Owner -1 First Responder 21 MyWindow 2 -3 Application 166 com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin {{71, 99}, {400, 400}} com.apple.InterfaceBuilder.CocoaPlugin {{71, 99}, {400, 400}} {100, 100} 174 FirstResponder NSObject IBUserSource MLTermView NSView IBUserSource 0 com.apple.InterfaceBuilder.CocoaPlugin.macosx YES 3 mlterm-3.9.3/cocoa/mlterm.app/Contents/Resources/English.lproj/Main.nib/keyedobjects.nib000066400000000000000000000274031441203364000312610ustar00rootroot00000000000000 $archiver NSKeyedArchiver $objects $null $class CF$UID 54 NSAccessibilityConnectors CF$UID 51 NSAccessibilityOidsKeys CF$UID 52 NSAccessibilityOidsValues CF$UID 53 NSClassesKeys CF$UID 42 NSClassesValues CF$UID 43 NSConnections CF$UID 29 NSFontManager CF$UID 0 NSFramework CF$UID 5 NSNamesKeys CF$UID 35 NSNamesValues CF$UID 36 NSNextOid 176 NSObjectsKeys CF$UID 30 NSObjectsValues CF$UID 34 NSOidsKeys CF$UID 44 NSOidsValues CF$UID 45 NSRoot CF$UID 2 NSVisibleWindows CF$UID 6 $class CF$UID 4 NSClassName CF$UID 3 NSApplication $classes NSCustomObject NSObject $classname NSCustomObject IBCocoaFramework $class CF$UID 28 NS.objects CF$UID 7 $class CF$UID 27 NSMaxSize CF$UID 26 NSMinSize CF$UID 25 NSScreenRect CF$UID 24 NSViewClass CF$UID 12 NSWTFlags 813170688 NSWindowBacking 2 NSWindowClass CF$UID 10 NSWindowContentMaxSize CF$UID 13 NSWindowContentMinSize CF$UID 14 NSWindowRect CF$UID 8 NSWindowStyleMask 15 NSWindowTitle CF$UID 9 NSWindowView CF$UID 15 {{0, 400}, {400, 400}} mlterm $class CF$UID 11 NS.string NSWindow $classes NSMutableString NSString NSObject $classname NSMutableString $class CF$UID 11 NS.string View {1.79769e+308, 1.79769e+308} {100, 100} $class CF$UID 23 NSFrameSize CF$UID 22 NSNextResponder CF$UID 0 NSSubviews CF$UID 16 NSvFlags 18 $class CF$UID 21 NS.objects CF$UID 17 $class CF$UID 20 NSClassName CF$UID 19 NSFrameSize CF$UID 18 NSNextResponder CF$UID 15 NSSuperview CF$UID 15 {400, 400} MLTermView $classes NSCustomView NSView NSResponder NSObject $classname NSCustomView $classes NSMutableArray NSArray NSObject $classname NSMutableArray {400, 400} $classes NSView NSResponder NSObject $classname NSView {{0, 0}, {800, 578}} {100, 122} {1.79769e+308, 1.79769e+308} $classes NSWindowTemplate NSObject $classname NSWindowTemplate $classes NSMutableSet NSSet NSObject $classname NSMutableSet $class CF$UID 21 NS.objects $class CF$UID 33 NS.objects CF$UID 15 CF$UID 17 CF$UID 31 CF$UID 7 $class CF$UID 4 NSClassName CF$UID 32 NSApplication $classes NSArray NSObject $classname NSArray $class CF$UID 33 NS.objects CF$UID 7 CF$UID 15 CF$UID 2 CF$UID 2 $class CF$UID 33 NS.objects CF$UID 2 CF$UID 15 CF$UID 17 CF$UID 31 CF$UID 7 $class CF$UID 33 NS.objects CF$UID 37 CF$UID 38 CF$UID 39 CF$UID 40 CF$UID 41 File's Owner Content View Term View Application MyWindow $class CF$UID 33 NS.objects $class CF$UID 33 NS.objects $class CF$UID 33 NS.objects CF$UID 2 CF$UID 15 CF$UID 17 CF$UID 31 CF$UID 7 $class CF$UID 33 NS.objects CF$UID 46 CF$UID 47 CF$UID 48 CF$UID 49 CF$UID 50 175 2 166 -3 21 $class CF$UID 21 NS.objects $class CF$UID 33 NS.objects $class CF$UID 33 NS.objects $classes NSIBObjectData NSObject $classname NSIBObjectData $top IB.objectdata CF$UID 1 $version 100000 mlterm-3.9.3/common/000077500000000000000000000000001441203364000143135ustar00rootroot00000000000000mlterm-3.9.3/common/c_animgif.c000066400000000000000000000121731441203364000163770ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include /* sprintf */ #include /* open */ #include /* close */ #include #include /* DIGIT_STR_LEN */ /* --- static functions --- */ static int hash_path(const char *path) { int hash; hash = 0; while (*path) { hash += *(path++); } return hash & 65535 /* 0xffff */; } static void save_gif(const char *path, u_char *header, size_t header_size, u_char *body, size_t body_size #ifdef USE_WIN32GUI , int colorkey #endif ) { int fd; #ifdef USE_WIN32API if ((fd = open(path, O_WRONLY | O_CREAT | O_BINARY, 0600)) >= 0) #else if ((fd = open(path, O_WRONLY | O_CREAT, 0600)) >= 0) #endif { write(fd, header, header_size); write(fd, body, body_size); #ifdef USE_WIN32GUI if (colorkey >= 0) { u_char append[] = "\x2c\x00\x00\x00\x00\x01\x00\x01\x00\x00\x08\x01\x00\x00"; append[12] = colorkey; write(fd, append, sizeof(append) - 1); } #endif write(fd, "\x3b", 1); close(fd); } } static u_char *skip_gif_header(u_char *p) { /* Header */ p += 10; if (*(p)&0x80) { p += (3 * (2 << ((*p) & 0x7))); } p += 3; return p; } #ifdef GDK_PIXBUF_VERSION /* read gif information from mlterm/anim*.gif file. */ static int read_gif_info(const char *path, int *x_off, int *y_off, int *width, int *height) { int fd; u_char data[1024]; /* enough to get necessary gif information */ ssize_t len; if ((fd = open(path, O_RDONLY)) < 0) { return 0; } len = read(fd, data, sizeof(data)); close(fd); /* Cast to char* is necessary because this function can be compiled by g++. */ if (len >= 6 && strncmp((char*)data, "GIF89a", 6) == 0) { u_char *p; p = skip_gif_header(data); if (p + 12 < data + len && p[0] == 0x21 && p[1] == 0xf9 && p[2] == 0x04 && p[8] == 0x2c) { *x_off = (p[10] << 8) | p[9]; *y_off = (p[12] << 8) | p[11]; *width = (data[7] << 8) | data[6]; *height = (data[9] << 8) | data[8]; return 1; } } return 0; } #endif static int split_animation_gif(const char *path, const char *dir, /* must end with '/'. */ int hash) { int fd; struct stat st; u_char *header; size_t header_size; u_char *body; u_char *p; ssize_t len; int num; char *split_path; const char *format; const char *next_format; #ifdef USE_WIN32GUI int colorkey; #endif #ifdef USE_WIN32API if ((fd = open(path, O_RDONLY | O_BINARY)) < 0) #else if ((fd = open(path, O_RDONLY)) < 0) #endif { return 0; } /* Cast to u_char* is necessary because this function can be compiled by g++. */ if (fstat(fd, &st) != 0 || !(header = (u_char*)malloc(st.st_size))) { close(fd); return 0; } len = read(fd, header, st.st_size); close(fd); /* Header */ /* Cast to char* is necessary because this function can be compiled by g++. */ if (len != st.st_size || strncmp((char*)header, "GIF89a", 6) != 0) { free(header); return 0; } p = skip_gif_header(header); header_size = p - header; /* Application Extension */ if (p[0] == 0x21 && p[1] == 0xff) { p += 19; } /* Other blocks */ body = NULL; num = -1; /* animx%d-%d.gif */ split_path = (char*)alloca(strlen(dir) + 10 + 5 + DIGIT_STR_LEN(int)+1); while (p + 2 < header + st.st_size) { if (*(p++) == 0x21 && *(p++) == 0xf9 && *(p++) == 0x04) { /* skip the first frame. */ if (body) { /* Graphic Control Extension */ sprintf(split_path, format, dir, hash, num); save_gif(split_path, header, header_size, body, p - 3 - body #ifdef USE_WIN32GUI , colorkey #endif ); format = next_format; } else { format = "%sanim%d.gif"; } /* XXX *p & 4 => Regarded as no dispose. */ next_format = (*p & 0x4) ? "%sanimx%d-%d.gif" : "%sanim%d-%d.gif"; body = p - 3; #ifdef USE_WIN32GUI if (p + 13 < header + st.st_size) { int frame_xoff; int frame_yoff; int frame_width; int frame_height; frame_xoff = ((p[7] << 8) | p[6]); frame_yoff = ((p[9] << 8) | p[8]); frame_width = ((p[11] << 8) | p[10]); frame_height = ((p[13] << 8) | p[12]); /* * XXX * GDI+ which clears margin area with an opaque color if the 2nd * or later frame is smaller than the 1st one. * The hack of embedding a transparent color at x=0 y=0 fixes it. */ if (frame_xoff > 0 || frame_yoff > 0 || frame_xoff + frame_width < ((header[7] << 8) | header[6]) || frame_yoff + frame_height < ((header[9] << 8) | header[8])) { colorkey = p[3]; } else { colorkey = -1; } } #endif num++; } } if (body) { sprintf(split_path, format, dir, hash, num); save_gif(split_path, header, header_size, body, header + st.st_size - body - 1 #ifdef USE_WIN32GUI , colorkey #endif ); } free(header); return 1; } mlterm-3.9.3/common/c_config.h.in000066400000000000000000000017561441203364000166510ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __C_CONFIG_H__ #define __C_CONFIG_H__ /* Define to 1 if translation of program messages to the user's native language is requested. */ #undef ENABLE_NLS /* Define if the GNU dcgettext() function is already present or preinstalled. */ #undef HAVE_DCGETTEXT /* Define if the GNU gettext() function is already present or preinstalled. */ #undef HAVE_GETTEXT /* Define if you have the iconv() function. */ #undef HAVE_ICONV /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the version of this package. */ #undef PACKAGE_VERSION /* Version number of package */ #undef VERSION #endif mlterm-3.9.3/common/c_imagelib.c000066400000000000000000000243311441203364000165350ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifdef BUILTIN_IMAGELIB #include /* DIGIT_STR_LEN */ #include /* alloca */ #include /* BL_LIBEXECDIR (for registobmp) */ #include "c_sixel.c" #include "c_regis.c" #include "c_animgif.c" /* --- static functions --- */ #ifdef GDK_PIXBUF_VERSION #include /* bl_get_user_rc_path */ #ifdef USE_FREETYPE_EMOJI #include #include FT_FREETYPE_H #ifdef FT_LOAD_COLOR static FT_Library library; static void pixbuf_destroy_notify_emoji(guchar *pixels, gpointer data) { FT_Done_Face(data); /* free pixels */ #if 0 FT_Done_FreeType(library); library = NULL; #endif } static char *is_otf_emoji(const char *path) { char *p; while ((p = strchr(path, '.'))) { if (((p[1] | 0x20) == 't' || (p[1] | 0x20) == 'o') && (p[2] | 0x20) == 't' && ((p[3] | 0x20) == 'f' || (p[3] | 0x20) == 'c') && p[4] == '/') { p[4] = '\0'; return p + 5; } path = p + 1; } return NULL; } static GdkPixbuf *gdk_pixbuf_new_from_otf(const char *path) { char *p; FT_Face face; u_int code; FT_UInt idx; int x; int y; unsigned char *buffer; GdkPixbuf *pixbuf = NULL; if (!(p = is_otf_emoji(path))) { return NULL; } if (sscanf(p, "%x", &code) != 1 || code == 0) { return NULL; } if (library == NULL && FT_Init_FreeType(&library)) { return NULL; } if (FT_New_Face(library, path, 0, &face)) { goto end1; } if ((idx = FT_Get_Char_Index(face, code)) == 0) { goto end2; } if (face->num_fixed_sizes > 0) { int nearest = 0; #if 0 u_int32_t min_diff = 0xffffffff; u_int32_t diff; int count; for (count = 0; count < face->num_fixed_sizes; count++) { diff = abs(font_width - face->available_sizes[0].width); if (min_diff > diff) { min_diff = diff; nearest = count; } } #endif FT_Select_Size(face, nearest); } FT_Load_Glyph(face, idx, FT_LOAD_DEFAULT|FT_LOAD_COLOR); #if 0 FT_Render_Glyph(face->glyph, FT_RENDER_MODE_LCD); #endif #ifdef DEBUG bl_debug_printf("%s emoji: code %x idx %x w %d(%d bytes) h %d\n", path, code, idx, face->glyph->bitmap.width, face->glyph->bitmap.pitch, face->glyph->bitmap.rows); #endif if (face->glyph->format != FT_GLYPH_FORMAT_BITMAP || face->glyph->bitmap.pixel_mode != FT_PIXEL_MODE_BGRA) { goto end2; } buffer = face->glyph->bitmap.buffer; for (y = 0; y < face->glyph->bitmap.rows; y++) { for (x = 0; x < face->glyph->bitmap.pitch; x += 4) { /* BGRA => RGBA */ unsigned char tmp = buffer[x]; buffer[x] = buffer[x + 2]; buffer[x + 2] = tmp; } buffer += face->glyph->bitmap.pitch; } return gdk_pixbuf_new_from_data(face->glyph->bitmap.buffer, GDK_COLORSPACE_RGB, TRUE, 8, face->glyph->bitmap.width, face->glyph->bitmap.rows, face->glyph->bitmap.pitch, pixbuf_destroy_notify_emoji, face); end2: FT_Done_Face(face); end1: #if 0 FT_Done_FreeType(library); #endif return pixbuf; } #else #define gdk_pixbuf_new_from_otf(path) (NULL) #endif #else #define gdk_pixbuf_new_from_otf(path) (NULL) #endif static void pixbuf_destroy_notify(guchar *pixels, gpointer data) { free(pixels); } static GdkPixbuf *gdk_pixbuf_new_from_sixel(const char *path) { u_char *pixels; u_int width; u_int height; if (!(pixels = load_sixel_from_file(path, &width, &height))) { return NULL; } /* load_sixel_from_file returns 4 bytes per pixel data. */ return gdk_pixbuf_new_from_data(pixels, GDK_COLORSPACE_RGB, TRUE, 8, width, height, width * 4, pixbuf_destroy_notify, NULL); } #define create_cardinals_from_sixel(path, width, height) (NULL) /* create an CARDINAL array for_NET_WM_ICON data */ static u_int32_t *create_cardinals_from_pixbuf(GdkPixbuf *pixbuf) { u_int width; u_int height; u_int32_t *cardinal; int rowstride; u_char *line; u_char *pixel; u_int i, j; width = gdk_pixbuf_get_width(pixbuf); height = gdk_pixbuf_get_height(pixbuf); if (width > ((SSIZE_MAX / sizeof(*cardinal)) - 2) / height || /* integer overflow */ !(cardinal = malloc((width * height + 2) * sizeof(*cardinal)))) { return NULL; } rowstride = gdk_pixbuf_get_rowstride(pixbuf); line = gdk_pixbuf_get_pixels(pixbuf); /* format of the array is {width, height, ARGB[][]} */ cardinal[0] = width; cardinal[1] = height; if (gdk_pixbuf_get_has_alpha(pixbuf)) { for (i = 0; i < height; i++) { pixel = line; line += rowstride; for (j = 0; j < width; j++) { /* RGBA to ARGB */ cardinal[(i * width + j) + 2] = ((((((u_int32_t)(pixel[3]) << 8) + pixel[0]) << 8) + pixel[1]) << 8) + pixel[2]; pixel += 4; } } } else { for (i = 0; i < height; i++) { pixel = line; line += rowstride; for (j = 0; j < width; j++) { /* all pixels are completely opaque (0xFF) */ cardinal[(i * width + j) + 2] = ((((((u_int32_t)(0x0000FF) << 8) + pixel[0]) << 8) + pixel[1]) << 8) + pixel[2]; pixel += 3; } } } return cardinal; } static GdkPixbuf *gdk_pixbuf_new_from(const char *path) { GdkPixbuf *pixbuf; if (!(pixbuf = gdk_pixbuf_new_from_otf(path)) && (strcasecmp(path + strlen(path) - 4, ".six") != 0 || !(pixbuf = gdk_pixbuf_new_from_sixel(path)))) { if (strcasecmp(path + strlen(path) - 4, ".gif") == 0 && !strstr(path, "mlterm/anim")) { /* Animation GIF */ char *dir; if ((dir = bl_get_user_rc_path("mlterm/"))) { int hash; hash = hash_path(path); if (strstr(path, "://")) { char *cmd; if (!(cmd = alloca(25 + strlen(path) + strlen(dir) + 5 + DIGIT_STR_LEN(int)+1))) { goto end; } sprintf(cmd, "curl -L -k -s %s > %sanim%d.gif", path, dir, hash); if (system(cmd) != 0) { goto end; } path = cmd + 14 + strlen(path) + 3; } split_animation_gif(path, dir, hash); end: free(dir); } } #if GDK_PIXBUF_MAJOR >= 2 if (strstr(path, "://")) { #ifdef __G_IO_H__ /* * gdk-pixbuf depends on gio. (__G_IO_H__ is defined if * gdk-pixbuf-core.h includes gio.h) */ GFile *file; GInputStream *in; if ((in = (GInputStream*)g_file_read( (file = g_vfs_get_file_for_uri(g_vfs_get_default(), path)), NULL, NULL))) { pixbuf = gdk_pixbuf_new_from_stream(in, NULL, NULL); g_object_unref(in); } else #endif { char *cmd; pixbuf = NULL; if ((cmd = alloca(11 + strlen(path) + 1))) { FILE* fp; sprintf(cmd, "curl -L -k -s %s", path); if ((fp = popen(cmd, "r"))) { GdkPixbufLoader *loader; guchar buf[65536]; size_t len; loader = gdk_pixbuf_loader_new(); while ((len = fread(buf, 1, sizeof(buf), fp)) > 0) { gdk_pixbuf_loader_write(loader, buf, len, NULL); } gdk_pixbuf_loader_close(loader, NULL); pclose(fp); if ((pixbuf = gdk_pixbuf_loader_get_pixbuf(loader))) { g_object_ref(pixbuf); } g_object_unref(loader); } } } #ifdef __G_IO_H__ g_object_unref(file); #endif } else #endif /* GDK_PIXBUF_MAJOR */ { if (strcasecmp(path + strlen(path) - 4, ".rgs") == 0) { char *new_path; if ((new_path = alloca(strlen(path) + 1)) && convert_regis_to_bmp(strcpy(new_path, path))) { path = new_path; } } #if GDK_PIXBUF_MAJOR >= 2 pixbuf = gdk_pixbuf_new_from_file(path, NULL); #else pixbuf = gdk_pixbuf_new_from_file(path); #endif if (strstr(path, "mlterm/anim")) { int xoff; int yoff; int width; int height; if (read_gif_info(path, &xoff, &yoff, &width, &height)) { if (width > gdk_pixbuf_get_width(pixbuf) || height > gdk_pixbuf_get_height(pixbuf)) { GdkPixbuf *new_pixbuf; new_pixbuf = gdk_pixbuf_new(GDK_COLORSPACE_RGB, TRUE, 8, width, height); gdk_pixbuf_fill(new_pixbuf, 0x00000000); gdk_pixbuf_copy_area(pixbuf, 0, 0, gdk_pixbuf_get_width(pixbuf), gdk_pixbuf_get_height(pixbuf), new_pixbuf, xoff, yoff); g_object_unref(pixbuf); pixbuf = new_pixbuf; } } } } } return pixbuf; } #else /* GDK_PIXBUF_VERSION */ #define gdk_pixbuf_new_from_sixel(path) (NULL) static u_int32_t *create_cardinals_from_sixel(const char *path) { u_int width; u_int height; u_int32_t *cardinal; if (!(cardinal = (u_int32_t*)load_sixel_from_file(path, &width, &height))) { return NULL; } cardinal -= 2; cardinal[0] = width; cardinal[1] = height; return cardinal; } #endif /* GDK_PIXBUF_VERSION */ #endif /* BUILTIN_IMAGELIB */ #ifdef USE_XLIB /* seek the closest color */ static int closest_color_index(XColor *color_list, int len, int red, int green, int blue) { int closest = 0; int i; u_int min = 0xffffff; u_int diff; int diff_r, diff_g, diff_b; for (i = 0; i < len; i++) { /* lazy color-space conversion*/ diff_r = red - (color_list[i].red >> 8); diff_g = green - (color_list[i].green >> 8); diff_b = blue - (color_list[i].blue >> 8); diff = diff_r * diff_r * 9 + diff_g * diff_g * 30 + diff_b * diff_b; if (diff < min) { min = diff; closest = i; /* no one may notice the difference (4[2^3/2]*4*9+4*4*30+4*4) */ if (diff < 640) { break; } } } return closest; } /**Return position of the least significant bit * *\param val value to count * */ static int lsb(u_int val) { int nth = 0; if (val == 0) { return 0; } while ((val & 1) == 0) { val = val >> 1; nth++; } return nth; } /**Return position of the most significant bit * *\param val value to count * */ static int msb(u_int val) { int nth; if (val == 0) { return 0; } nth = lsb(val) + 1; while (val & (1 << nth)) { nth++; } return nth; } #endif /* USE_XLIB */ mlterm-3.9.3/common/c_intl.h000066400000000000000000000003231441203364000157320ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __C_INTL_H__ #define __C_INTL_H__ #include "c_config.h" #define _(arg) gettext(arg) #define N_(arg) arg #include "gettext.h" #endif mlterm-3.9.3/common/c_regis.c000066400000000000000000000042651441203364000161010ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* --- static functions --- */ #if defined(USE_WIN32API) static int convert_regis_to_bmp(char *path) { size_t len = strlen(path); char cmd[17 + len * 2]; STARTUPINFO si; PROCESS_INFORMATION pi; path[len - 4] = '\0'; sprintf(cmd, "registobmp.exe %s.rgs %s.bmp", path, path); ZeroMemory(&si, sizeof(STARTUPINFO)); si.cb = sizeof(STARTUPINFO); si.dwFlags = STARTF_FORCEOFFFEEDBACK; if (CreateProcess(NULL, cmd, NULL, NULL, FALSE, CREATE_NO_WINDOW, NULL, NULL, &si, &pi)) { DWORD code; WaitForSingleObject(pi.hProcess, INFINITE); GetExitCodeProcess(pi.hProcess, &code); CloseHandle(pi.hProcess); CloseHandle(pi.hThread); if (code == 0) { strcat(path, ".bmp"); return 1; } } return 0; } #else #include /* execve */ #include #include /* bl_basename */ static int convert_regis_to_bmp(char *path) { pid_t pid; int status; if ((pid = fork()) == -1) { return 0; } if (pid == 0) { char *new_path; size_t len; #if defined(__CYGWIN__) || defined(__MSYS__) /* To make registobmp work even if it (or SDL) doesn't depend on cygwin. */ char *file; file = bl_basename(path); if (file && path < file) { *(file - 1) = '\0'; chdir(path); path = file; } #endif len = strlen(path); /* Cast to char* is necessary because this function can be compiled by g++. */ if ((new_path = (char*)malloc(len + 1))) { char *argv[4]; strncpy(new_path, path, len - 4); strcpy(new_path + len - 4, ".bmp"); argv[0] = BL_LIBEXECDIR("mlterm") "/registobmp"; argv[1] = path; argv[2] = new_path; argv[3] = NULL; execve(argv[0], argv, NULL); } exit(1); } waitpid(pid, &status, 0); /* * WEXITSTATUS uses __in and __out for union members, but * sal.h included from windows.h defines __in and __out macros on msys. * It causes compiling error in WEXITSTATUS. */ #ifdef __MSYS__ #undef __in #undef __out #endif if (WEXITSTATUS(status) == 0) { strcpy(path + strlen(path) - 4, ".bmp"); return 1; } return 0; } #endif mlterm-3.9.3/common/c_sixel.c000066400000000000000000000652341441203364000161170ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include /* memcpy */ #include /* fstat */ #include /* BL_MIN */ #include /* alloca */ /* * The size of the base palettes. * SIXEL_PALETTE_SIZE should be less than 1024. * (See the block of if ((color = params[0]) >= SIXEL_PALETTE_SIZE)) */ #ifndef SIXEL_PALETTE_SIZE #define SIXEL_PALETTE_SIZE 256 #endif /* * Support sixel graphics extension which "sayaka --ormode on" outputs. * (See https://github.com/isaki68k/sayaka/, * https://github.com/isaki68k/sayaka/blob/master/vala/sixel.native.c#L113) */ #if 1 #define SIXEL_ORMODE #endif #ifdef SIXEL_1BPP #define correct_height correct_height_1bpp #define load_sixel_from_data load_sixel_from_data_1bpp #define SIXEL_RGB100(r, g, b) ((9 * (r) * (r) + 30 * (g) * (g) + (b) * (b) > \ 9 * 50 * 50 + 30 * 50 * 50 + 50 * 50) ? 1 : 0) #define SIXEL_RGB255(r, g, b) ((9 * (r) * (r) + 30 * (g) * (g) + (b) * (b) > \ 9 * 127 * 127 + 30 * 127 * 127 + 127 * 127) ? 1 : 0) #define CARD_HEAD_SIZE 0 #define pixel_t u_int8_t #elif defined(SIXEL_SHAREPALETTE) /* Both sixel and system uses same palette (works on fb alone) */ #define correct_height correct_height_sharepalette #define load_sixel_from_data load_sixel_from_data_sharepalette #define CARD_HEAD_SIZE 0 #ifdef USE_GRF #define pixel_t u_int16_t #else #define pixel_t u_int8_t #endif #else #define SIXEL_RGB100(r, g, b) ((((r)*255 / 100) << 16) | (((g)*255 / 100) << 8) | ((b)*255 / 100)) #ifndef CARD_HEAD_SIZE #ifdef GDK_PIXBUF_VERSION #define CARD_HEAD_SIZE 0 #else #define CARD_HEAD_SIZE 8 #endif #endif /* CARD_HEAD_SIZE */ #define pixel_t u_int32_t #endif /* SIXEL_1BPP */ #define PIXEL_SIZE sizeof(pixel_t) /* --- static variables --- */ #if !defined(SIXEL_1BPP) && !defined(SIXEL_SHAREPALETTE) static pixel_t *custom_palette; #endif /* --- static functions --- */ #ifndef __GET_PARAMS__ #define __GET_PARAMS__ static u_int get_params(int *params, u_int max_params, const char **p) { u_int count; const char *start; memset(params, 0, sizeof(int) * max_params); for (start = *p, count = 0; count < max_params; count++) { while (1) { if ('0' <= **p && **p <= '9') { params[count] = params[count] * 10 + (**p - '0'); } else if (**p == ';') { (*p)++; break; } else { if (start == *p) { return 0; } else { (*p)--; return count + 1; } } (*p)++; } } (*p)--; return count; } #endif /* __GET_PARAMS__ */ #ifndef __READ_SIXEL_FILE__ #define __READ_SIXEL_FILE__ static char *read_sixel_file(const char *path) { FILE* fp; struct stat st; char * data; size_t len; if (!(fp = fopen(path, "r"))) { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " failed to open %s\n.", path); #endif return NULL; } fstat(fileno(fp), &st); /* * - malloc() should be used here because alloca() could return insufficient * memory. * - Cast to char* is necessary because this function can be compiled by g++. */ if (!(data = (char*)malloc(st.st_size + 1))) { fclose(fp); return NULL; } len = fread(data, 1, st.st_size, fp); fclose(fp); data[len] = '\0'; return data; } #endif #ifndef __REALLOC_PIXELS_INTERN__ #define __REALLOC_PIXELS_INTERN__ static int realloc_pixels_intern(u_char **pixels, size_t new_stride, int new_height, size_t cur_stride, int cur_height, int n_copy_rows) { u_char *p; u_char *src; u_char *dst; int y; if (new_stride < cur_stride) { if (new_height > cur_height) { /* Not supported */ #ifdef DEBUG bl_error_printf(BL_DEBUG_TAG " Sixel width bytes is shrunk (%d->%d) but height is lengthen (%d->%d)\n", cur_stride, new_stride, cur_height, new_height); #endif return 0; } else /* if (new_height < cur_height) */ { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Sixel data: %d bytes %d rows -> shrink %d bytes %d rows (No alloc)\n", cur_stride, cur_height, new_stride, new_height); #endif dst = src = *pixels; for (y = 1; y < n_copy_rows; y++) { memmove((dst += new_stride), (src += cur_stride), new_stride); } return 1; } } /* 'new_stride == cur_stride && new_height == cur_height' is checked before calling this. */ else if (new_stride == cur_stride && new_height < cur_height) { /* do nothing */ return 1; } if (new_stride > (SSIZE_MAX - CARD_HEAD_SIZE) / new_height) { /* integer overflow */ return 0; } if (new_stride == cur_stride /* && new_height > cur_height */) { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Sixel data: %d bytes %d rows -> realloc %d bytes %d rows\n", cur_stride, cur_height, new_stride, new_height); #endif /* Cast to u_char* is necessary because this function can be compiled by g++. */ if ((p = (u_char*)realloc(*pixels - CARD_HEAD_SIZE, CARD_HEAD_SIZE + new_stride * new_height))) { p += CARD_HEAD_SIZE; } else { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " realloc failed.\n."); #endif return 0; } memset(p + cur_stride * cur_height, 0, new_stride * (new_height - cur_height)); } else if (new_stride * new_height <= cur_stride * cur_height) { /* cur_stride < new_stride, but cur_height > new_height */ #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Sixel data: %d bytes %d rows -> %d bytes %d rows (No alloc)\n", cur_stride, cur_height, new_stride, new_height); #endif src = (*pixels) + n_copy_rows * cur_stride; dst = (*pixels) + n_copy_rows * new_stride; y = 1; while (1) { memset((dst -= new_stride) + cur_stride, 0, new_stride - cur_stride); if (y++ >= n_copy_rows) { break; } memmove(dst, (src -= cur_stride), cur_stride); } return 1; } else { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Sixel data: %d bytes %d rows -> calloc %d bytes %d rows\n", cur_stride, cur_height, new_stride, new_height); #endif /* Cast to u_char* is necessary because this function can be compiled by g++. */ if ((p = (u_char*)calloc(CARD_HEAD_SIZE + new_stride * new_height, 1))) { p += CARD_HEAD_SIZE; } else { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " calloc failed.\n."); #endif return 0; } for (y = 0; y < n_copy_rows; y++) { memcpy(p + (y * new_stride), (*pixels) + (y * cur_stride), cur_stride); } if (*pixels) { free((*pixels) - CARD_HEAD_SIZE); } } *pixels = p; return 1; } #endif /* realloc_pixels() might not be inlined because it is called twice. */ #define realloc_pixels(pixels, new_width, new_height, cur_width, cur_height, n_copy_rows) \ ((new_width) == (cur_width) && (new_height) == (cur_height) ? \ 1 : realloc_pixels_intern(pixels, new_width * PIXEL_SIZE, new_height, \ cur_width * PIXEL_SIZE, cur_height, n_copy_rows)) /* * Correct the height which is always multiple of 6, but this doesn't * necessarily work. */ static void correct_height(pixel_t *pixels, int width, int *height /* multiple of 6 */) { int x; int y; pixels += (width * (*height - 1)); for (y = 0; y < 5; y++) { for (x = 0; x < width; x++) { if (pixels[x]) { return; } } (*height)--; pixels -= width; } } /* * load_sixel_from_file() returns at least 1024*1024 pixels memory even if * the actual image size is less than it. * It is the caller that should shrink (realloc) it. */ static u_char *load_sixel_from_data(const char *file_data, u_int *width_ret, u_int *height_ret) { const char *p = file_data; u_char *pixels; int params[6]; u_int n; /* number of params */ int init_width; int pix_x; int pix_y; int stride; int cur_width; int cur_height; int width; int height; int rep; int color; int asp_x; #ifdef SIXEL_ORMODE int ormode = 0; #endif #ifdef SIXEL_SHAREPALETTE u_int8_t color_indexes[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 255 }; #else /* VT340 Default Color Map */ static pixel_t default_palette[] = { SIXEL_RGB100(0, 0, 0), /* BLACK */ SIXEL_RGB100(20, 20, 80), /* BLUE */ SIXEL_RGB100(80, 13, 13), /* RED */ SIXEL_RGB100(20, 80, 20), /* GREEN */ SIXEL_RGB100(80, 20, 80), /* MAGENTA */ SIXEL_RGB100(20, 80, 80), /* CYAN */ SIXEL_RGB100(80, 80, 20), /* YELLOW */ SIXEL_RGB100(53, 53, 53), /* GRAY 50% */ SIXEL_RGB100(26, 26, 26), /* GRAY 25% */ SIXEL_RGB100(33, 33, 60), /* BLUE* */ SIXEL_RGB100(60, 26, 26), /* RED* */ SIXEL_RGB100(33, 60, 33), /* GREEN* */ SIXEL_RGB100(60, 33, 60), /* MAGENTA* */ SIXEL_RGB100(33, 60, 60), /* CYAN* */ SIXEL_RGB100(60, 60, 33), /* YELLOW* */ SIXEL_RGB100(80, 80, 80) /* GRAY 75% */ }; pixel_t *palette; pixel_t *base_palette; pixel_t *ext_palette = NULL; #endif pixels = NULL; init_width = 0; cur_width = cur_height = width = height = 0; #ifndef SIXEL_SHAREPALETTE #ifndef SIXEL_1BPP if (custom_palette) { base_palette = palette = custom_palette; if (palette[SIXEL_PALETTE_SIZE] == 0) /* No active palette */ { memcpy(palette, default_palette, sizeof(default_palette)); memset(palette + 16, 0, sizeof(pixel_t) * SIXEL_PALETTE_SIZE - sizeof(default_palette)); } } else #endif { base_palette = palette = (pixel_t*)alloca(sizeof(pixel_t) * SIXEL_PALETTE_SIZE); memcpy(palette, default_palette, sizeof(default_palette)); memset(palette + 16, 0, sizeof(pixel_t) * SIXEL_PALETTE_SIZE - sizeof(default_palette)); } #endif restart: while (1) { if (*p == '\0') { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format\n."); #endif goto end; } else if (*p == '\x90') { break; } else if (*p == '\x1b') { if (*(++p) == 'P') { break; } } else { p++; } } if (*(++p) != ';') { /* P1 */ switch (*p) { case 'q': /* The default value. (2:1 is documented though) */ asp_x = 1; #if 0 asp_y = 1; #endif goto body; #if 0 case '0': case '1': case '5': case '6': asp_x = 1; asp_y = 2; break; case '2': asp_x = 1; asp_y = 5; break; case '3': case '4': asp_x = 1; asp_y = 3; break; case '7': case '8': case '9': asp_x = 1; asp_y = 1; break; default: #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format.\n."); #endif goto end; #else case '\0': #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format.\n."); #endif goto end; default: asp_x = 1; /* XXX */ #endif } if (p[1] == ';') { p++; } } else { /* P1 is omitted. */ asp_x = 1; /* V:H=2:1 */ #if 0 asp_y = 2; #endif } if (*(++p) != ';') { /* P2 */ switch (*p) { case 'q': goto body; #ifdef SIXEL_ORMODE case '5': ormode = 1; break; #endif #if 0 case '0': case '2': ... break; default: #else case '\0': #endif #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format.\n."); #endif goto end; } if (p[1] == ';') { p++; } } #if 0 else { /* P2 is omitted. */ } #endif /* Ignoring P3 */ while (*(++p) != 'q') { if (*p == '\0') { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format.\n."); #endif goto end; } } body: #ifdef SIXEL_SHAREPALETTE { char *p2; /* 'p + 2' is to skip '#' of "#0;9;%d;%d;%d" appended just after "DCS ... q" in vt_parser.c */ if (!(p2 = memchr(p + 2, '#', 50)) || (p2[2] != ';' && p2[3] != ';' && p2[4] != ';')) { /* If color definition is not found, load_sixel_from_data_sharepalette() exits. */ goto error; } } #endif rep = asp_x; /* always >= 1 */ pix_x = pix_y = 0; stride = width * PIXEL_SIZE; color = 0; while (*(++p) != '\0') { if (*p >= '?' && *p <= '\x7E') { u_int new_width; u_int new_height; int a; int b; int y; u_char *line; if (height < pix_y + 6) { new_height = height + 516 /* 6*86 */; } else { new_height = height; } if (width < pix_x + rep) { u_int expand = BL_MAX(rep, 512); u_int h; new_width = width + expand; stride += (expand * PIXEL_SIZE); h = width * height / new_width; /* * h=17, pix_y=6 * h=17/6*6=12 == pix_y + 6 */ if (h >= pix_y + 11) { h = h / 6 * 6; new_height = h; } } else { new_width = width; } if (!realloc_pixels(&pixels, new_width, new_height, width, height, pix_y + 6)) { break; } width = new_width; height = new_height; b = *p - '?'; a = 0x01; line = pixels + pix_y * stride + pix_x * PIXEL_SIZE; #ifdef SIXEL_ORMODE if (ormode) { for (y = 0; y < 6; y++) { if ((b & a) != 0) { int x = 0; do { ((pixel_t*)line)[x++] |= color; } while (x < rep); /* rep >= 1 */ } a <<= 1; line += stride; } } else #endif { #ifdef SIXEL_SHAREPALETTE for (y = 0; y < 6; y++) { if ((b & a) != 0) { #ifdef USE_GRF int x = 0; do { ((u_int16_t*)line)[x++] = color_indexes[color]; } while (x < rep); /* rep >= 1 */ #else memset(line, color_indexes[color], rep); #endif } a <<= 1; line += stride; } #else for (y = 0; y < 6; y++) { if ((b & a) != 0) { int x = 0; do { #ifdef SIXEL_1BPP /* 0x80 is opaque mark */ ((pixel_t*)line)[x++] = 0x80 | palette[color]; #else ((pixel_t*)line)[x++] = palette[color]; #endif } while (x < rep); /* rep >= 1 */ } a <<= 1; line += stride; } #endif /* SIXEL_SHAREPALETTE */ } pix_x += rep; if (cur_width < pix_x) { cur_width = pix_x; } if (cur_height < pix_y + 6) { cur_height = pix_y + 6; } rep = asp_x; /* always >= 1 */ } else if (*p == '!') { /* ! Pn Ch */ if (*(++p) == '\0') { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format.\n."); #endif break; } if (get_params(params, 1, &p) > 0) { if ((rep = params[0]) < 1) { rep = 1; } rep *= asp_x; } } else if (*p == '$' || *p == '-') { pix_x = 0; rep = asp_x; /* always >= 1 */ if (*p == '-') { if (!init_width && width > cur_width && cur_width > 0) { int y; #ifdef DEBUG bl_debug_printf("Sixel width is shrunk (%d -> %d)\n", width, cur_width); #endif for (y = 1; y < cur_height; y++) { memmove(pixels + y * cur_width * PIXEL_SIZE, pixels + y * width * PIXEL_SIZE, cur_width * PIXEL_SIZE); } memset(pixels + y * cur_width * PIXEL_SIZE, 0, (cur_height * (width - cur_width) * PIXEL_SIZE)); width = cur_width; stride = width * PIXEL_SIZE; init_width = 1; } pix_y += 6; } } else if (*p == '#') /* # Pc ; Pu; Px; Py; Pz */ { if (*(++p) == '\0') { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format.\n."); #endif break; } n = get_params(params, BL_ARRAY_SIZE(params), &p); if (n > 0) { if ((color = params[0]) >= SIXEL_PALETTE_SIZE) { #ifdef SIXEL_SHAREPALETTE color = SIXEL_PALETTE_SIZE - 1; #else if (color >= 1024) { color = 0; goto use_base_palette; } else { color -= SIXEL_PALETTE_SIZE; if (!ext_palette) { if (!(ext_palette = (pixel_t*)alloca(sizeof(pixel_t) * (1024 - SIXEL_PALETTE_SIZE)))) { color = 0; goto use_base_palette; } memset(ext_palette, 0, 1024 - SIXEL_PALETTE_SIZE); } palette = ext_palette; } #endif } else { if (color < 0) { color = 0; } #ifndef SIXEL_SHAREPALETTE use_base_palette: palette = base_palette; #endif } } if (n > 4) { int rgba[4]; /* The arguments of bl_hls_to_rgb() are 'int*' */ rgba[3] = 255; if (params[1] == 1) { /* HLS */ bl_hls_to_rgb(&rgba[0], &rgba[1], &rgba[2], BL_MIN(params[2], 360), BL_MIN(params[3], 100), BL_MIN(params[4], 100)); if (n > 5 && params[5] < 100) { rgba[3] = params[5] * 255 / 100; } } else if (params[1] == 2 #ifndef SIXEL_SHAREPALETTE || params[1] == 9 /* see vt_parser.c */ #endif ) { /* RGB */ rgba[0] = params[2] >= 100 ? 255 : params[2] * 255 / 100; rgba[1] = params[3] >= 100 ? 255 : params[3] * 255 / 100; rgba[2] = params[4] >= 100 ? 255 : params[4] * 255 / 100; if (n > 5 && params[5] < 100) { rgba[3] = params[5] * 255 / 100; } } else if (params[1] == 3) { /* R8G8B8 */ rgba[0] = params[2] >= 255 ? 255 : params[2]; rgba[1] = params[3] >= 255 ? 255 : params[3]; rgba[2] = params[4] >= 255 ? 255 : params[4]; if (n > 5 && params[5] < 255) { rgba[3] = params[5]; } } else { continue; } #if defined(SIXEL_1BPP) palette[color] = SIXEL_RGB255(rgba[0], rgba[1], rgba[2]); #elif defined(SIXEL_SHAREPALETTE) { u_int8_t r, g, b; /* fb/ui_display.h which defines ui_cmap_get_pixel_rgb() is included from ui_imagelib.c */ if (!ui_cmap_get_pixel_rgb(&r, &g, &b, color) || abs(r - rgba[0]) >= 0x10 || abs(g - rgba[1]) >= 0x10 || abs(b - rgba[2]) >= 0x10) { u_long closest; /* * fb/ui_display.h which defines ui_cmap_get_closest_color() is included * from ui_imagelib.c */ if (ui_cmap_get_closest_color(&closest, rgba[0], rgba[1], rgba[2])) { color_indexes[color] = closest; } else { goto error; } } } #else #if defined(GDK_PIXBUF_VERSION) || defined(USE_QUARTZ) /* RGBA */ ((u_char*)(palette + color))[0] = rgba[0]; ((u_char*)(palette + color))[1] = rgba[1]; ((u_char*)(palette + color))[2] = rgba[2]; ((u_char*)(palette + color))[3] = rgba[3]; #else /* ARGB */ palette[color] = (rgba[3] << 24) | (rgba[0] << 16) | (rgba[1] << 8) | rgba[2]; #endif if (palette == custom_palette && palette[SIXEL_PALETTE_SIZE] <= color) { /* * Set max active palette number for NetBSD/OpenBSD. * (See load_file() in fb/ui_imagelib.c) */ palette[SIXEL_PALETTE_SIZE] = color + 1; } #endif #ifdef __DEBUG bl_debug_printf(BL_DEBUG_TAG " Set rgb %x for color %d.\n", palette[color], color); #endif } } else if (*p == '"') /* " Pan ; Pad ; Ph ; Pv */ { u_int new_width = 0; u_int new_height = 0; int need_resize = 0; if (*(++p) == '\0') { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Illegal format.\n."); #endif break; } if ((n = get_params(params, 4, &p)) == 1) { params[1] = 1; n = 2; } switch (n) { case 4: new_height = (params[3] + 5) / 6 * 6; case 3: new_width = params[2]; #if 0 case 2: /* V:H=params[0]:params[1] */ #if 0 asp_x = params[1]; asp_y = params[0]; #else rep /= asp_x; if ((asp_x = params[1] / params[0]) == 0) { asp_x = 1; /* XXX */ } rep *= asp_x; #endif #endif } if (width < new_width) { /* w200 h100 -> w400 h0 case is ignored. */ if (new_height > 0) { need_resize = 1; if (height > new_height) { new_height = height; } } } if (height < new_height) { /* w200 h100 -> w0 h200 case is ignored. */ if (new_width > 0) { need_resize = 1; if (width > new_width) { new_width = width; } } } if (need_resize && realloc_pixels(&pixels, new_width, new_height, width, height, pix_y + 6)) { width = new_width; stride = new_width * PIXEL_SIZE; height = new_height; } } else if (*p == '\x1b') { if (*(++p) == '\\') { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " EOF.\n."); #endif /* See is_separated_sixel() in vt_parser.c */ if (*(p + 1) != '\0') { goto restart; } break; } else if (*p == '\0') { break; } } else if (*p == '\x9c') { #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " EOF.\n."); #endif /* See is_separated_sixel() in vt_parser.c */ if (*(p + 1) != '\0') { goto restart; } break; } } end: #if !defined(SIXEL_1BPP) && !defined(SIXEL_SHAREPALETTE) custom_palette = NULL; #endif if (cur_width > 0 && realloc_pixels(&pixels, cur_width, cur_height, width, height, cur_height)) { correct_height((pixel_t*)pixels, cur_width, &cur_height); #ifdef DEBUG bl_debug_printf("Shrink size w %d h %d -> w %d h %d\n", width, height, cur_width, cur_height); #endif #ifdef SIXEL_ORMODE if (ormode) { int x, y; pixel_t *p = (pixel_t*)pixels; for (y = 0; y < cur_height; y++) { for (x = 0; x < cur_width; x++) { #if defined(SIXEL_SHAREPALETTE) *p = color_indexes[*p]; #elif defined(SIXEL_1BPP) /* 0x80 is opaque mark */ *p = 0x80 | palette[*p]; #else *p = palette[*p]; #endif p++; } } } #endif *width_ret = cur_width; *height_ret = cur_height; return pixels; } #ifdef DEBUG bl_debug_printf(BL_DEBUG_TAG " Nothing is drawn.\n"); #endif #ifdef SIXEL_SHAREPALETTE error: #endif if (pixels) { free(pixels - CARD_HEAD_SIZE); } return NULL; } #if !defined(SIXEL_1BPP) && !defined(SIXEL_SHAREPALETTE) static u_char *load_sixel_from_file(const char *path, u_int *width_ret, u_int *height_ret) { char *file_data; u_char *pixels; if ((file_data = read_sixel_file(path))) { pixels = load_sixel_from_data(file_data, width_ret, height_ret); free(file_data); return pixels; } else { return NULL; } } pixel_t *ui_set_custom_sixel_palette(pixel_t *palette /* NULL -> Create new palette */ ) { if (!palette) { palette = (pixel_t*)calloc(sizeof(pixel_t), SIXEL_PALETTE_SIZE + 1); } return (custom_palette = palette); } #endif #if defined(BL_DEBUG) && !defined(TEST_SIXEL) #include #define TEST_SIXEL /* Don't define TEST_sixel_realloc_pixels twice */ #define PIXEL_DATA(b1, b2, b4) \ (sizeof(pixel_t) == 1 ? (b1) : (sizeof(pixel_t) == 2 ? (b2) : /* sizeof(pixel_t) == 4 */ (b4))) void TEST_sixel_realloc_pixels(void) { pixel_t *pixels = NULL; int x; int y; /* 0 0 -> 100 100 */ realloc_pixels(&pixels, 100, 100, 0, 0, 0); memset(pixels, 0x1, 100 * 100 * sizeof(pixel_t)); /* 100 100 -> 80 125 (Not supported) */ assert(realloc_pixels(&pixels, 80, 125, 100, 100, 0) == 0); /* 100 100 -> 50 100 */ realloc_pixels(&pixels, 50, 100, 100, 100, 100); for (y = 0; y < 100; y++) { for (x = 0; x < 50; x++) { assert(pixels[y * 50 + x] == PIXEL_DATA(0x1, 0x0101, 0x01010101)); } } /* 50 100 -> 50 200 */ realloc_pixels(&pixels, 50, 200, 50, 100, 100); memset(pixels + 50 * 100, 0x2, 50 * 100 * sizeof(pixel_t)); for (y = 0; y < 100; y++) { for (x = 0; x < 50; x++) { assert(pixels[y * 50 + x] == PIXEL_DATA(0x1, 0x0101, 0x01010101)); } } for (;y < 200; y++) { for (x = 0; x < 50; x++) { assert(pixels[y * 50 + x] == PIXEL_DATA(0x2, 0x0202, 0x02020202)); } } /* 50 200 -> 80 120 */ realloc_pixels(&pixels, 80, 120, 50, 200, 120); for (y = 0; y < 100; y++) { for (x = 0; x < 50; x++) { assert(pixels[y * 80 + x] == PIXEL_DATA(0x1, 0x0101, 0x01010101)); } for (; x < 80; x++) { assert(pixels[y * 80 + x] == 0x0); } } for (;y < 120; y++) { for (x = 0; x < 50; x++) { assert(pixels[y * 80 + x] == PIXEL_DATA(0x2, 0x0202, 0x02020202)); } for (; x < 80; x++) { assert(pixels[y * 80 + x] == 0x0); } } /* 80 120 -> 200 180 */ realloc_pixels(&pixels, 200, 180, 80, 120, 150); for (y = 0; y < 100; y++) { for (x = 0; x < 50; x++) { assert(pixels[y * 200 + x] == PIXEL_DATA(0x1, 0x0101, 0x01010101)); } for (; x < 200; x++) { assert(pixels[y * 200 + x] == 0x0); } } for (;y < 120; y++) { for (x = 0; x < 50; x++) { assert(pixels[y * 200 + x] == PIXEL_DATA(0x2, 0x0202, 0x02020202)); } for (; x < 200; x++) { assert(pixels[y * 200 + x] == 0x0); } } for (; y < 180; y++) { for (; x < 200; x++) { assert(pixels[y * 200 + x] == 0x0); } } free(pixels); bl_msg_printf("PASS realloc_pixels test\n"); } #endif #undef realloc_pixels #undef correct_height #undef load_sixel_from_data #undef SIXEL_RGB100 #undef SIXEL_RGB255 #undef CARD_HEAD_SIZE #undef pixel_t #undef PIXEL_SIZE mlterm-3.9.3/common/gettext.h000066400000000000000000000057101441203364000161530ustar00rootroot00000000000000/* Convenience header for conditional use of GNU . Copyright (C) 1995-1998, 2000-2002 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #ifndef _LIBGETTEXT_H #define _LIBGETTEXT_H 1 /* NLS can be disabled through the configure --disable-nls option. */ #if ENABLE_NLS /* Get declarations of GNU message catalog functions. */ #include #else /* Solaris /usr/include/locale.h includes /usr/include/libintl.h, which chokes if dcgettext is defined as a macro. So include it now, to make later inclusions of a NOP. We don't include as well because people using "gettext.h" will not include , and also including would fail on SunOS 4, whereas is OK. */ #if defined(__sun) #include #endif /* Disabled NLS. The casts to 'const char *' serve the purpose of producing warnings for invalid uses of the value returned from these functions. On pre-ANSI systems without 'const', the config.h file is supposed to contain "#define const". */ #define gettext(Msgid) ((const char *)(Msgid)) #define dgettext(Domainname, Msgid) ((const char *)(Msgid)) #define dcgettext(Domainname, Msgid, Category) ((const char *)(Msgid)) #define ngettext(Msgid1, Msgid2, N) ((N) == 1 ? (const char *)(Msgid1) : (const char *)(Msgid2)) #define dngettext(Domainname, Msgid1, Msgid2, N) \ ((N) == 1 ? (const char *)(Msgid1) : (const char *)(Msgid2)) #define dcngettext(Domainname, Msgid1, Msgid2, N, Category) \ ((N) == 1 ? (const char *)(Msgid1) : (const char *)(Msgid2)) #define textdomain(Domainname) ((const char *)(Domainname)) #define bindtextdomain(Domainname, Dirname) ((const char *)(Dirname)) #define bind_textdomain_codeset(Domainname, Codeset) ((const char *)(Codeset)) #endif /* A pseudo function call that serves as a marker for the automated extraction of messages, but does not call gettext(). The run-time translation is done at a different place in the code. The argument, String, should be a literal string. Concatenated strings and other string expressions won't work. The macro's expansion is not parenthesized, so that it is suitable as initializer for static 'char[]' or 'const char[]' variables. */ #define gettext_noop(String) String #endif /* _LIBGETTEXT_H */ mlterm-3.9.3/configure000077500000000000000000031672101441203364000147440ustar00rootroot00000000000000#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.69. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. # # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # Use a proper internal environment variable to ensure we don't fall # into an infinite loop, continuously re-executing ourselves. if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then _as_can_reexec=no; export _as_can_reexec; # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 as_fn_exit 255 fi # We don't want this to propagate to other subprocesses. { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi " as_required="as_fn_return () { (exit \$1); } as_fn_success () { as_fn_return 0; } as_fn_failure () { as_fn_return 1; } as_fn_ret_success () { return 0; } as_fn_ret_failure () { return 1; } exitcode=0 as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || exit 1 test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 test \$(( 1 + 1 )) = 2 || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. as_shell=$as_dir/$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : CONFIG_SHELL=$as_shell as_have_required=yes if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : break 2 fi fi done;; esac as_found=false done $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : CONFIG_SHELL=$SHELL as_have_required=yes fi; } IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : export CONFIG_SHELL # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 exit 255 fi if test x$as_have_required = xno; then : $as_echo "$0: This script requires a shell more modern than all" $as_echo "$0: the shells that I found on your system." if test x${ZSH_VERSION+set} = xset ; then $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, $0: including any error possibly output before this $0: message. Then install a modern shell, or manually run $0: the script under such a shell if you do have one." fi exit 1 fi fi fi SHELL=${CONFIG_SHELL-/bin/sh} export SHELL # Unset more variables known to interfere with behavior of common tools. CLICOLOR_FORCE= GREP_OPTIONS= unset CLICOLOR_FORCE GREP_OPTIONS ## --------------------- ## ## M4sh Shell Functions. ## ## --------------------- ## # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits as_lineno_1=$LINENO as_lineno_1a=$LINENO as_lineno_2=$LINENO as_lineno_2a=$LINENO eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # If we had to re-execute with $CONFIG_SHELL, we're ensured to have # already done that, so ensure we don't try to do so again and fall # in an infinite loop. This has already happened in practice. _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" SHELL=${CONFIG_SHELL-/bin/sh} test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= # Identity of this package. PACKAGE_NAME= PACKAGE_TARNAME= PACKAGE_VERSION= PACKAGE_STRING= PACKAGE_BUGREPORT= PACKAGE_URL= # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" enable_option_checking=no ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS UTMP_CFLAGS UTMP_LIBS UTMP_NAME PTY_NAME DL_CFLAGS DL_LIBS DL_LOADER XPG4_LIBS ALLOCA pobl_top_builddir_suffix pobl_top_srcdir_suffix EF_CHAR_LO MAKE_DIRS TABLE_CFLAGS mef_top_builddir_suffix mef_top_srcdir_suffix MAKE_DIRS2 PTHREAD_LIB TRANSFER_LIBS TRANSFER_CFLAGS SPLIT_CFLAGS DAEMON_CFLAGS BRLAPI_CFLAGS BRLAPI_LIBS CTL_LIBS_FOR_PROG CTL_LIBS IND_CFLAGS IND_LIBS subdirs CHANGE_DATE MAIN_OBJ_SUFFIX INTL_LIBS VT52_CFLAGS DL_SELF NO_UNDEFINED_FLAG DL_LIBS_SB SB_CFLAGS DL_LIBS_IM IM_CFLAGS SKK_LIBS WNN_LIBS WNN_CFLAGS CANNA_LIBS CANNA_CFLAGS SCIM_LIBS SCIM_CFLAGS FCITXUTILS_LIBS FCITXUTILS_CFLAGS FCITX_LIBS FCITX_CFLAGS IBUS_LIBS IBUS_CFLAGS M17NLIB_LIBS M17NLIB_CFLAGS m17n_config IIIMCF_LIBS IIIMCF_CFLAGS UIM_LIBS UIM_CFLAGS DND_CFLAGS SDLTTF_LIBS SDLTTF_CFLAGS SDL_LIBS SDL_CFLAGS EMOJI_LIBS EMOJI_CFLAGS MLIMGLOADER_LIB PERL GTK_LIBS_FOR_MLCONFIG GTK_CFLAGS_FOR_MLCONFIG MKINSTALLDIRS POSUB POFILES PO_IN_DATADIR_FALSE PO_IN_DATADIR_TRUE INTLLIBS INSTOBJEXT GMOFILES DATADIRNAME CATOBJEXT CATALOGS XGETTEXT GMSGFMT MSGFMT_OPTS MSGFMT INTL_MACOSX_LIBS USE_NLS AM_BACKSLASH AM_DEFAULT_VERBOSITY AM_DEFAULT_V AM_V CSCOPE ETAGS CTAGS am__fastdepCXX_FALSE am__fastdepCXX_TRUE CXXDEPMODE am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE am__include DEPDIR am__untar am__tar AMTAR am__leading_dot SET_MAKE mkdir_p MKDIR_P INSTALL_STRIP_PROGRAM install_sh MAKEINFO AUTOHEADER AUTOMAKE AUTOCONF ACLOCAL VERSION PACKAGE CYGPATH_W am__isrc TOOLS_CFLAGS VTE_ABI VTE_LIBS VTE_CFLAGS MOSH_OCB_OBJ MOSH_DIR VT_PTY_OBJ SSH2_LIBS_FOR_PROG PROTOBUF_LIBS PROTOBUF_CFLAGS SSH2_LIBS SSH2_CFLAGS PROG NODL_OBJ TYPE_LIBS_FOR_VTE TYPE_LIBS_FOR_PROG TYPE_LIBS TYPE_CFLAGS OT_LAYOUT_OBJ OT_LAYOUT_CFLAGS OT_LAYOUT_LIBS_FOR_PROG OT_LAYOUT_LIBS libotf_config HB_LIBS HB_CFLAGS CAIRO_LIBS CAIRO_CFLAGS xft_config XFT_LIBS XFT_CFLAGS FONTCONFIG_LIBS FONTCONFIG_CFLAGS TYPE_LOADER_OBJ CTL_LIBS_FOR_VTE CTL_CFLAGS fribidi_config FRIBIDI_LIBS FRIBIDI_CFLAGS CTL_LOADER_OBJ LMLTERM_CORE TRUECOLOR_TAG TRUECOLOR_CFLAGS REGEX_LIBS REGEX_CFLAGS GUI_CFLAGS GUI SDL2GUI sdl2_config SDL2_LIBS SDL2_CFLAGS WAYLAND_LIBS WAYLAND_CFLAGS SIXEL_LIBS SIXEL_CFLAGS VT_NORM_CFLAGS VT_NORM_OBJ COCOA_LIBS COCOAOBJ XUTF8_CFLAGS IMAGE_CFLAGS MATH_CFLAGS MATH_LIBS IMAGELIB_LIBS IMAGELIB_CFLAGS FT_LIBS FT_CFLAGS imlib2_config imlib_config have_gdk_pixbuf1 GIO_LIBS GIO_CFLAGS GDK_PIXBUF_LIBS GDK_PIXBUF_CFLAGS GTK_LIBS GTK_CFLAGS GTK4_LIBS GTK4_CFLAGS PKG_CONFIG_LIBDIR PKG_CONFIG_PATH DEXPORT SUBSYSTEM WIN32TAG CYGPATHW MLTERM_FB X_CFLAGS_AUX X_EXTRA_LIBS X_LIBS X_PRE_LIBS X_CFLAGS XMKMF SOCK_LIBS CXXCPP CPP LT_SYS_LIBRARY_PATH OTOOL64 OTOOL LIPO NMEDIT DSYMUTIL MANIFEST_TOOL AWK RANLIB STRIP ac_ct_AR AR FILECMD LN_S NM ac_ct_DUMPBIN DUMPBIN LD FGREP EGREP GREP SED LIBTOOL OBJDUMP DLLTOOL AS DEB_CFLAGS INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM ac_ct_CXX CXXFLAGS CXX OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CC XCRUN PKG_CONFIG POBL_CFLAGS LPOBL MEF_CFLAGS LMEF CFLAGS host_os host_vendor host_cpu host build_os build_vendor build_cpu build target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL am__quote' ac_subst_files='' ac_user_opts=' enable_option_checking with_ios_sdk with_ios_arch enable_debug with_libtool enable_shared enable_static with_pic enable_fast_install with_aix_soname with_gnu_ld with_sysroot enable_libtool_lock with_x with_gui with_gtk with_imagelib enable_image enable_compact_truecolor enable_dl_ctl enable_fribidi with_pthread enable_dl_type enable_anti_alias enable_fontconfig with_type_engines enable_otl enable_ssh2 with_mosh with_tools enable_use_tools enable_dependency_tracking enable_silent_rules with_libltdl enable_dnd enable_kbd enable_uim enable_iiimf enable_m17nlib enable_ibus enable_fcitx enable_scim enable_canna enable_wnn enable_skk with_scrollbars enable_vt52 enable_optimize_redrawing enable_ind enable_brlapi enable_daemon enable_split enable_zmodem with_map_table with_prop_table with_iconv enable_dl_table enable_largefile enable_pty_helper with_utmp enable_utmp_suid ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CXX CXXFLAGS CCC LT_SYS_LIBRARY_PATH CPP CXXCPP XMKMF PKG_CONFIG PKG_CONFIG_PATH PKG_CONFIG_LIBDIR GTK4_CFLAGS GTK4_LIBS GTK_CFLAGS GTK_LIBS GDK_PIXBUF_CFLAGS GDK_PIXBUF_LIBS GIO_CFLAGS GIO_LIBS FT_CFLAGS FT_LIBS WAYLAND_CFLAGS WAYLAND_LIBS SDL2_CFLAGS SDL2_LIBS FRIBIDI_CFLAGS FRIBIDI_LIBS FONTCONFIG_CFLAGS FONTCONFIG_LIBS XFT_CFLAGS XFT_LIBS CAIRO_CFLAGS CAIRO_LIBS HB_CFLAGS HB_LIBS SSH2_CFLAGS SSH2_LIBS PROTOBUF_CFLAGS PROTOBUF_LIBS VTE_CFLAGS VTE_LIBS SDL_CFLAGS SDL_LIBS SDLTTF_CFLAGS SDLTTF_LIBS UIM_CFLAGS UIM_LIBS IIIMCF_CFLAGS IIIMCF_LIBS M17NLIB_CFLAGS M17NLIB_LIBS IBUS_CFLAGS IBUS_LIBS FCITX_CFLAGS FCITX_LIBS FCITXUTILS_CFLAGS FCITXUTILS_LIBS SCIM_CFLAGS SCIM_LIBS' ac_subdirs_all='${SUBDIRS}' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *=) ac_optarg= ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) as_fn_error $? "unrecognized option: \`$ac_option' Try \`$0 --help' for more information" ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures this package to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF X features: --x-includes=DIR X include files are in DIR --x-libraries=DIR X library files are in DIR Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-debug debug [default=disabled] --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) --disable-image show image [default=enabled] --disable-compact-truecolor true color support by reusing 240 palettes [default=enabled] --disable-dl-ctl dynamic loading ctl library [default=enable] --disable-fribidi bidi [default=enabled] --disable-dl-type dynamic loading type engine library [default=enable] --disable-anti-alias same as --with-type-engines=xcore on xlib [default=enabled] do not use truetype fonts on framebuffer [default=enabled] --disable-fontconfig use fontconfig with freetype on framebuffer or wayland [default=enabled] --disable-otl Open Type layout with the use of harfbuzz or libotf [default=enabled] --disable-ssh2 libssh2 [default=enabled] --disable-use-tools do not build and use external tools [default=enabled] --enable-dependency-tracking do not reject slow dependency extractors --disable-dependency-tracking speeds up one-time build --enable-silent-rules less verbose build output (undo: "make V=1") --disable-silent-rules verbose build output (undo: "make V=0") --disable-dnd dnd [default=enabled] --disable-kbd input method for Arabic and Indic [default=enabled] --disable-uim uim [default=enabled] --disable-iiimf IIIMF (Experimental) [default=enabled] --disable-m17nlib m17n library [default=enabled] --disable-ibus IBUS [default=enabled] --disable-fcitx FCITX [default=enabled] --disable-scim SCIM [default=enabled] --disable-canna CANNA [default=enabled] --disable-wnn WNN [default=enabled] --disable-skk SKK [default=enabled] --enable-vt52 enable VT52 emulation [default=disabled] --enable-optimize-redrawing optimize redrawing a line [default=disabled] --disable-ind libind [default=enabled] --enable-brlapi libbrlapi [default=disabled] --disable-daemon daemon mode [default=enabled] --disable-split split screen [default=enabled] --disable-zmodem zmodem [default=enabled] --disable-dl-table dynamic loading table [default=enable] --disable-largefile omit support for large files --enable-pty-helper use pty helper [default=disabled] --enable-utmp-suid install mlterm with SUID or SGID for utmp [default=disabled] Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-ios-sdk[=ARG] iOS SDK (e.g. iphoneos4.3 iphonesimulator4.3) --with-ios-arch[=ARG] iOS architectures (e.g. arm7v x86_64,i686) --with-libtool[=ARG] libtool path [default=without] --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use both] --with-aix-soname=aix|svr4|both shared library versioning (aka "SONAME") variant to provide on AIX, [default=aix]. --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-sysroot[=DIR] Search for dependent libraries within DIR (or the compiler's sysroot if not specified). --with-x use the X Window System --with-gui[=ARG] gui library (xlib|win32|fb|quartz|console|wayland|sdl2|beos) --with-gtk[=ARG] gtk+ version (2.0|3.0|4.0) [default=3.0] --with-imagelib[=ARG] image library (gdk-pixbuf) [default=no] --without-pthread do not use pthread [default=with] --with-type-engines[=ARG] type engines (xcore, xft, cairo) [default=xcore,xft,cairo] --with-mosh[=ARG] The directory where mosh is built --with-tools[=ARG] external tools [default=mlclient,mlconfig,mlcc,mlterm-menu,mlimgloader,registobmp,mlfc] --with-libltdl[=PREFIX] load modules with libltdl [default=without] --with-scrollbars[=ARG] scrollbar plugins (sample, extra, pixmap_engine) [default=sample,extra,pixmap_engine] --without-map-table mapping table [default=with] --without-prop-table property table [default=with] --with-iconv use iconv for charset conversion [default=without] --with-utmp[=ARG] utmp (utempter,sysv,login,bsd,none) Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory CXX C++ compiler command CXXFLAGS C++ compiler flags LT_SYS_LIBRARY_PATH User-defined run-time library search path. CPP C preprocessor CXXCPP C++ preprocessor XMKMF Path to xmkmf, Makefile generator for X Window System PKG_CONFIG path to pkg-config utility PKG_CONFIG_PATH directories to add to pkg-config's search path PKG_CONFIG_LIBDIR path overriding pkg-config's built-in search path GTK4_CFLAGS C compiler flags for GTK4, overriding pkg-config GTK4_LIBS linker flags for GTK4, overriding pkg-config GTK_CFLAGS C compiler flags for GTK, overriding pkg-config GTK_LIBS linker flags for GTK, overriding pkg-config GDK_PIXBUF_CFLAGS C compiler flags for GDK_PIXBUF, overriding pkg-config GDK_PIXBUF_LIBS linker flags for GDK_PIXBUF, overriding pkg-config GIO_CFLAGS C compiler flags for GIO, overriding pkg-config GIO_LIBS linker flags for GIO, overriding pkg-config FT_CFLAGS C compiler flags for FT, overriding pkg-config FT_LIBS linker flags for FT, overriding pkg-config WAYLAND_CFLAGS C compiler flags for WAYLAND, overriding pkg-config WAYLAND_LIBS linker flags for WAYLAND, overriding pkg-config SDL2_CFLAGS C compiler flags for SDL2, overriding pkg-config SDL2_LIBS linker flags for SDL2, overriding pkg-config FRIBIDI_CFLAGS C compiler flags for FRIBIDI, overriding pkg-config FRIBIDI_LIBS linker flags for FRIBIDI, overriding pkg-config FONTCONFIG_CFLAGS C compiler flags for FONTCONFIG, overriding pkg-config FONTCONFIG_LIBS linker flags for FONTCONFIG, overriding pkg-config XFT_CFLAGS C compiler flags for XFT, overriding pkg-config XFT_LIBS linker flags for XFT, overriding pkg-config CAIRO_CFLAGS C compiler flags for CAIRO, overriding pkg-config CAIRO_LIBS linker flags for CAIRO, overriding pkg-config HB_CFLAGS C compiler flags for HB, overriding pkg-config HB_LIBS linker flags for HB, overriding pkg-config SSH2_CFLAGS C compiler flags for SSH2, overriding pkg-config SSH2_LIBS linker flags for SSH2, overriding pkg-config PROTOBUF_CFLAGS C compiler flags for PROTOBUF, overriding pkg-config PROTOBUF_LIBS linker flags for PROTOBUF, overriding pkg-config VTE_CFLAGS C compiler flags for VTE, overriding pkg-config VTE_LIBS linker flags for VTE, overriding pkg-config SDL_CFLAGS C compiler flags for SDL, overriding pkg-config SDL_LIBS linker flags for SDL, overriding pkg-config SDLTTF_CFLAGS C compiler flags for SDLTTF, overriding pkg-config SDLTTF_LIBS linker flags for SDLTTF, overriding pkg-config UIM_CFLAGS C compiler flags for UIM, overriding pkg-config UIM_LIBS linker flags for UIM, overriding pkg-config IIIMCF_CFLAGS C compiler flags for IIIMCF, overriding pkg-config IIIMCF_LIBS linker flags for IIIMCF, overriding pkg-config M17NLIB_CFLAGS C compiler flags for M17NLIB, overriding pkg-config M17NLIB_LIBS linker flags for M17NLIB, overriding pkg-config IBUS_CFLAGS C compiler flags for IBUS, overriding pkg-config IBUS_LIBS linker flags for IBUS, overriding pkg-config FCITX_CFLAGS C compiler flags for FCITX, overriding pkg-config FCITX_LIBS linker flags for FCITX, overriding pkg-config FCITXUTILS_CFLAGS C compiler flags for FCITXUTILS, overriding pkg-config FCITXUTILS_LIBS linker flags for FCITXUTILS, overriding pkg-config SCIM_CFLAGS C compiler flags for SCIM, overriding pkg-config SCIM_LIBS linker flags for SCIM, overriding pkg-config Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to the package provider. _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF configure generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi ## ------------------------ ## ## Autoconf initialization. ## ## ------------------------ ## # ac_fn_c_try_compile LINENO # -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile # ac_fn_cxx_try_compile LINENO # ---------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_cxx_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_cxx_try_compile # ac_fn_c_try_link LINENO # ----------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists and can be compiled using the include files in # INCLUDES, setting the cache variable VAR accordingly. ac_fn_c_check_header_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile # ac_fn_c_try_cpp LINENO # ---------------------- # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp # ac_fn_c_try_run LINENO # ---------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes # that executables *can* be run. ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then : ac_retval=0 else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Define $2 to an innocuous variant, in case declares $2. For example, HP-UX 11i declares gettimeofday. */ #define $2 innocuous_$2 /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $2 (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $2 /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $2 (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$2 || defined __stub___$2 choke me #endif int main () { return $2 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func # ac_fn_cxx_try_cpp LINENO # ------------------------ # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_cxx_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_cxx_try_cpp # ac_fn_cxx_try_link LINENO # ------------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_cxx_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_cxx_try_link # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists, giving a warning if it cannot be compiled using # the include files in INCLUDES and setting the cache variable VAR # accordingly. ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } else # Is the header compilable? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 $as_echo_n "checking $2 usability... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_header_compiler=yes else ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 $as_echo "$ac_header_compiler" >&6; } # Is the header present? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 $as_echo_n "checking $2 presence... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$2> _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : ac_header_preproc=yes else ac_header_preproc=no fi rm -f conftest.err conftest.i conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( yes:no: ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; no:yes:* ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel # ac_fn_c_check_type LINENO TYPE VAR INCLUDES # ------------------------------------------- # Tests whether TYPE exists after having included INCLUDES, setting cache # variable VAR accordingly. ac_fn_c_check_type () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=no" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { if (sizeof ($2)) return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { if (sizeof (($2))) return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else eval "$3=yes" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_type cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by $as_me, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. $as_echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi as_fn_append ac_configure_args " '$ac_arg'" ;; esac done done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo $as_echo "## ---------------- ## ## Cache variables. ## ## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo $as_echo "## ----------------- ## ## Output variables. ## ## ----------------- ##" echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then $as_echo "## ------------------- ## ## File substitutions. ## ## ------------------- ##" echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then $as_echo "## ----------- ## ## confdefs.h. ## ## ----------- ##" echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h $as_echo "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_URL "$PACKAGE_URL" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then # We do not want a PATH search for config.site. case $CONFIG_SITE in #(( -*) ac_site_file1=./$CONFIG_SITE;; */*) ac_site_file1=$CONFIG_SITE;; *) ac_site_file1=./$CONFIG_SITE;; esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" \ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "failed to load site script $ac_site_file See \`config.log' for more details" "$LINENO" 5; } fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) as_fn_append ac_configure_args " '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## ## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_config_headers="$ac_config_headers common/c_config.h" ac_aux_dir= for ac_dir in script "$srcdir"/script; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then as_fn_error $? "cannot find install-sh, install.sh, or shtool in script \"$srcdir\"/script" "$LINENO" 5 fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } if ${ac_cv_build+:} false; then : $as_echo_n "(cached) " >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 $as_echo "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } if ${ac_cv_host+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac # for CFLAGS="..." ./configure ... if test -d ${top_srcdir-$srcdir}/encodefilter -a -d ${top_srcdir-$srcdir}/baselib ; then CONFIG_SUBDIR_LIBS="internal" if test "$CONFIG_SUBDIR_LIBS" = "external"; then SUBDIRS="baselib encodefilter" fi MEF_CFLAGS='-I${top_builddir}/encodefilter/include' POBL_CFLAGS='-I${top_builddir}/baselib/include' LMEF='${top_builddir}/encodefilter/src/libmef.la' LPOBL='${top_builddir}/baselib/src/libpobl.la' elif test -d ${top_srcdir-$srcdir}/../../encodefilter -a -d ${top_srcdir-$srcdir}/../../baselib ; then # --with-gui=xlib,fb => cd fb ; --with-gui=fb MEF_CFLAGS='-I${top_builddir}/../../encodefilter/include' POBL_CFLAGS='-I${top_builddir}/../../baselib/include' LMEF='${top_builddir}/../../encodefilter/src/libmef.la' LPOBL='${top_builddir}/../../baselib/src/libpobl.la' else LMEF="-lmef" LPOBL="-lpobl" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$PKG_CONFIG"; then ac_cv_prog_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_PKG_CONFIG="${ac_tool_prefix}pkg-config" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi PKG_CONFIG=$ac_cv_prog_PKG_CONFIG if test -n "$PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_PKG_CONFIG"; then ac_ct_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_PKG_CONFIG"; then ac_cv_prog_ac_ct_PKG_CONFIG="$ac_ct_PKG_CONFIG" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_PKG_CONFIG="pkg-config" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_PKG_CONFIG=$ac_cv_prog_ac_ct_PKG_CONFIG if test -n "$ac_ct_PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PKG_CONFIG" >&5 $as_echo "$ac_ct_PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_PKG_CONFIG" = x; then PKG_CONFIG="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac PKG_CONFIG=$ac_ct_PKG_CONFIG fi else PKG_CONFIG="$ac_cv_prog_PKG_CONFIG" fi # Check whether --with-ios-sdk was given. if test "${with_ios_sdk+set}" = set; then : withval=$with_ios_sdk; ios_sdk=$with_ios_sdk fi if test "$ios_sdk" != ""; then # Extract the first word of "xcrun", so it can be a program name with args. set dummy xcrun; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_XCRUN+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$XCRUN"; then ac_cv_prog_XCRUN="$XCRUN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_XCRUN="xcrun" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi XCRUN=$ac_cv_prog_XCRUN if test -n "$XCRUN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCRUN" >&5 $as_echo "$XCRUN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$XCRUN" != ""; then if test "$SDKROOT" = ""; then SDKROOT=`$XCRUN --sdk $ios_sdk --show-sdk-path` fi if test "$CC" = ""; then # Do 'export' for baselib/configure and encodefilter/configure. export CC="`$XCRUN --sdk $ios_sdk -f cc` -isysroot $SDKROOT" simver=`echo $ios_sdk|sed -n 's/^iphonesimulator\([0-9.]*\)$/\1/p'` if test "$simver" != ""; then case "$simver" in [0-4].*) # -D__IPHONE_OS_VERSION_MIN_REQUIRED=40300 or something like that # should be defined as the value of CFLAGS environmental variable # before ./configure. ;; *) CC="$CC -mios-simulator-version-min=$simver" ;; esac fi fi # Check whether --with-ios-arch was given. if test "${with_ios_arch+set}" = set; then : withval=$with_ios_arch; ios_arch=$with_ios_arch fi if test "$ios_arch" != ""; then ios_arch=`echo ${ios_arch} | sed 's/,/ /g'` for arch in $ios_arch; do CC="$CC -arch $arch" done fi if test "$CPP" = ""; then export CPP="$CC -E" fi if test "$RANLIB" = ""; then export RANLIB=`$XCRUN --sdk $ios_sdk -f ranlib` fi if test "$LIBTOOL" = ""; then export LIBTOOL=`$XCRUN --sdk $ios_sdk -f libtool` fi if test "$AR" = ""; then export AR=`$XCRUN --sdk $ios_sdk -f ar` fi fi XCRUN= fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { { ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi if test -z "$ac_file"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of executables: cannot compile and link See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details" "$LINENO" 5; } fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of object files: cannot compile See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Expand $ac_aux_dir to an absolute path. am_aux_dir=`cd "$ac_aux_dir" && pwd` ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 $as_echo_n "checking whether $CC understands -c and -o together... " >&6; } if ${am_cv_prog_cc_c_o+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF # Make sure it works both with $CC and with simple cc. # Following AC_PROG_CC_C_O, we do the test twice because some # compilers refuse to overwrite an existing .o file with -o, # though they will create one. am_cv_prog_cc_c_o=yes for am_i in 1 2; do if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } \ && test -f conftest2.$ac_objext; then : OK else am_cv_prog_cc_c_o=no break fi done rm -f core conftest* unset am_i fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 $as_echo "$am_cv_prog_cc_c_o" >&6; } if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. # But if we don't then we get into trouble of one sort or another. # A longer-term fix would be to have automake use am__CC in this case, # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" CC="$am_aux_dir/compile $CC" fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # mlimgloader (gdiplus.cpp) and SCIM ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test -z "$CXX"; then if test -n "$CCC"; then CXX=$CCC else if test -n "$ac_tool_prefix"; then for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CXX"; then ac_cv_prog_CXX="$CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CXX=$ac_cv_prog_CXX if test -n "$CXX"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 $as_echo "$CXX" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CXX" && break done fi if test -z "$CXX"; then ac_ct_CXX=$CXX for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CXX"; then ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CXX="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CXX=$ac_cv_prog_ac_ct_CXX if test -n "$ac_ct_CXX"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 $as_echo "$ac_ct_CXX" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CXX" && break done if test "x$ac_ct_CXX" = x; then CXX="g++" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CXX=$ac_ct_CXX fi fi fi fi # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } if ${ac_cv_cxx_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_cxx_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GXX=yes else GXX= fi ac_test_CXXFLAGS=${CXXFLAGS+set} ac_save_CXXFLAGS=$CXXFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 $as_echo_n "checking whether $CXX accepts -g... " >&6; } if ${ac_cv_prog_cxx_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_cxx_werror_flag=$ac_cxx_werror_flag ac_cxx_werror_flag=yes ac_cv_prog_cxx_g=no CXXFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_cv_prog_cxx_g=yes else CXXFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : else ac_cxx_werror_flag=$ac_save_cxx_werror_flag CXXFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_cv_prog_cxx_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cxx_werror_flag=$ac_save_cxx_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 $as_echo "$ac_cv_prog_cxx_g" >&6; } if test "$ac_test_CXXFLAGS" = set; then CXXFLAGS=$ac_save_CXXFLAGS elif test $ac_cv_prog_cxx_g = yes; then if test "$GXX" = yes; then CXXFLAGS="-g -O2" else CXXFLAGS="-g" fi else if test "$GXX" = yes; then CXXFLAGS="-O2" else CXXFLAGS= fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in #(( ./ | .// | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 $as_echo_n "checking for inline... " >&6; } if ${ac_cv_c_inline+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; static $ac_kw foo_t static_foo () {return 0; } $ac_kw foo_t foo () {return 0; } #endif _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_inline=$ac_kw fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_inline" != no && break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 $as_echo "$ac_cv_c_inline" >&6; } case $ac_cv_c_inline in inline | yes) ;; *) case $ac_cv_c_inline in no) ac_val=;; *) ac_val=$ac_cv_c_inline;; esac cat >>confdefs.h <<_ACEOF #ifndef __cplusplus #define inline $ac_val #endif _ACEOF ;; esac # Check whether --enable-debug was given. if test "${enable_debug+set}" = set; then : enableval=$enable_debug; debug=$enable_debug fi if test "$debug" = "yes" ; then DEB_CFLAGS="-DDEBUG -DBL_DEBUG" fi enable_win32_dll=yes case $host in *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. set dummy ${ac_tool_prefix}as; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AS+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AS"; then ac_cv_prog_AS="$AS" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AS="${ac_tool_prefix}as" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AS=$ac_cv_prog_AS if test -n "$AS"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 $as_echo "$AS" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_AS"; then ac_ct_AS=$AS # Extract the first word of "as", so it can be a program name with args. set dummy as; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_AS+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_AS"; then ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AS="as" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AS=$ac_cv_prog_ac_ct_AS if test -n "$ac_ct_AS"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5 $as_echo "$ac_ct_AS" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_AS" = x; then AS="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac AS=$ac_ct_AS fi else AS="$ac_cv_prog_AS" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. set dummy ${ac_tool_prefix}dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DLLTOOL"; then ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DLLTOOL=$ac_cv_prog_DLLTOOL if test -n "$DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 $as_echo "$DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DLLTOOL"; then ac_ct_DLLTOOL=$DLLTOOL # Extract the first word of "dlltool", so it can be a program name with args. set dummy dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DLLTOOL"; then ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DLLTOOL="dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL if test -n "$ac_ct_DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 $as_echo "$ac_ct_DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DLLTOOL" = x; then DLLTOOL="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DLLTOOL=$ac_ct_DLLTOOL fi else DLLTOOL="$ac_cv_prog_DLLTOOL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. set dummy ${ac_tool_prefix}objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 $as_echo "$OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OBJDUMP"; then ac_ct_OBJDUMP=$OBJDUMP # Extract the first word of "objdump", so it can be a program name with args. set dummy objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OBJDUMP"; then ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OBJDUMP="objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP if test -n "$ac_ct_OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 $as_echo "$ac_ct_OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then OBJDUMP="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OBJDUMP=$ac_ct_OBJDUMP fi else OBJDUMP="$ac_cv_prog_OBJDUMP" fi ;; esac test -z "$AS" && AS=as test -z "$DLLTOOL" && DLLTOOL=dlltool test -z "$OBJDUMP" && OBJDUMP=objdump enable_dlopen=yes # Check whether --with-libtool was given. if test "${with_libtool+set}" = set; then : withval=$with_libtool; libtool=$with_libtool fi if test "${libtool}" != "" ; then LIBTOOL=${libtool} else case `pwd` in *\ * | *\ *) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; esac macro_version='2.4.7' macro_revision='2.4.7' ltmain=$ac_aux_dir/ltmain.sh # Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\(["`$\\]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\(["`\\]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 $as_echo_n "checking how to print strings... " >&6; } # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "" } case $ECHO in printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 $as_echo "printf" >&6; } ;; print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 $as_echo "print -r" >&6; } ;; *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 $as_echo "cat" >&6; } ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 $as_echo_n "checking for a sed that does not truncate output... " >&6; } if ${ac_cv_path_SED+:} false; then : $as_echo_n "(cached) " >&6 else ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for ac_i in 1 2 3 4 5 6 7; do ac_script="$ac_script$as_nl$ac_script" done echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed { ac_script=; unset ac_script;} if test -z "$SED"; then ac_path_SED_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_SED" || continue # Check for GNU ac_path_SED and select it if it is found. # Check for GNU $ac_path_SED case `"$ac_path_SED" --version 2>&1` in *GNU*) ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo '' >> "conftest.nl" "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_SED_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_SED="$ac_path_SED" ac_path_SED_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_SED_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_SED"; then as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 fi else ac_cv_path_SED=$SED fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 $as_echo "$ac_cv_path_SED" >&6; } SED="$ac_cv_path_SED" rm -f conftest.sed test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 $as_echo "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else if test -z "$EGREP"; then ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 $as_echo_n "checking for fgrep... " >&6; } if ${ac_cv_path_FGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 then ac_cv_path_FGREP="$GREP -F" else if test -z "$FGREP"; then ac_path_FGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in fgrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_FGREP" || continue # Check for GNU ac_path_FGREP and select it if it is found. # Check for GNU $ac_path_FGREP case `"$ac_path_FGREP" --version 2>&1` in *GNU*) ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'FGREP' >> "conftest.nl" "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_FGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_FGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_FGREP"; then as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_FGREP=$FGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 $as_echo "$ac_cv_path_FGREP" >&6; } FGREP="$ac_cv_path_FGREP" test -z "$GREP" && GREP=grep # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then : withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 $as_echo_n "checking for ld used by $CC... " >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 $as_echo_n "checking for GNU ld... " >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi if ${lt_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 $as_echo "$LD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } if ${lt_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 $as_echo "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } if ${lt_cv_path_NM+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 $as_echo "$lt_cv_path_NM" >&6; } if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else if test -n "$ac_tool_prefix"; then for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DUMPBIN+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DUMPBIN"; then ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DUMPBIN=$ac_cv_prog_DUMPBIN if test -n "$DUMPBIN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 $as_echo "$DUMPBIN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$DUMPBIN" && break done fi if test -z "$DUMPBIN"; then ac_ct_DUMPBIN=$DUMPBIN for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DUMPBIN"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN if test -n "$ac_ct_DUMPBIN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 $as_echo "$ac_ct_DUMPBIN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_DUMPBIN" && break done if test "x$ac_ct_DUMPBIN" = x; then DUMPBIN=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DUMPBIN=$ac_ct_DUMPBIN fi fi case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 $as_echo_n "checking the name lister ($NM) interface... " >&6; } if ${lt_cv_nm_interface+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: output\"" >&5) cat conftest.out >&5 if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 $as_echo "$lt_cv_nm_interface" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 $as_echo_n "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 $as_echo "no, using $LN_S" >&6; } fi # find the maximum length of command line arguments { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 $as_echo_n "checking the maximum length of command line arguments... " >&6; } if ${lt_cv_sys_max_cmd_len+:} false; then : $as_echo_n "(cached) " >&6 else i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | msys* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[ ]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac fi if test -n "$lt_cv_sys_max_cmd_len"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 $as_echo "$lt_cv_sys_max_cmd_len" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 $as_echo "none" >&6; } fi max_cmd_len=$lt_cv_sys_max_cmd_len : ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 $as_echo_n "checking how to convert $build file names to $host format... " >&6; } if ${lt_cv_to_host_file_cmd+:} false; then : $as_echo_n "(cached) " >&6 else case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac fi to_host_file_cmd=$lt_cv_to_host_file_cmd { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 $as_echo "$lt_cv_to_host_file_cmd" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } if ${lt_cv_to_tool_file_cmd+:} false; then : $as_echo_n "(cached) " >&6 else #assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac fi to_tool_file_cmd=$lt_cv_to_tool_file_cmd { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 $as_echo "$lt_cv_to_tool_file_cmd" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 $as_echo_n "checking for $LD option to reload object files... " >&6; } if ${lt_cv_ld_reload_flag+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_reload_flag='-r' fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 $as_echo "$lt_cv_ld_reload_flag" >&6; } reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; *) reload_flag=" $reload_flag" ;; esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) if test yes != "$GCC"; then reload_cmds=false fi ;; darwin*) if test yes = "$GCC"; then reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi ;; esac if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}file", so it can be a program name with args. set dummy ${ac_tool_prefix}file; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_FILECMD+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$FILECMD"; then ac_cv_prog_FILECMD="$FILECMD" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_FILECMD="${ac_tool_prefix}file" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi FILECMD=$ac_cv_prog_FILECMD if test -n "$FILECMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILECMD" >&5 $as_echo "$FILECMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_FILECMD"; then ac_ct_FILECMD=$FILECMD # Extract the first word of "file", so it can be a program name with args. set dummy file; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_FILECMD+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_FILECMD"; then ac_cv_prog_ac_ct_FILECMD="$ac_ct_FILECMD" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_FILECMD="file" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_FILECMD=$ac_cv_prog_ac_ct_FILECMD if test -n "$ac_ct_FILECMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_FILECMD" >&5 $as_echo "$ac_ct_FILECMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_FILECMD" = x; then FILECMD=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac FILECMD=$ac_ct_FILECMD fi else FILECMD="$ac_cv_prog_FILECMD" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. set dummy ${ac_tool_prefix}objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 $as_echo "$OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OBJDUMP"; then ac_ct_OBJDUMP=$OBJDUMP # Extract the first word of "objdump", so it can be a program name with args. set dummy objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OBJDUMP"; then ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OBJDUMP="objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP if test -n "$ac_ct_OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 $as_echo "$ac_ct_OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then OBJDUMP="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OBJDUMP=$ac_ct_OBJDUMP fi else OBJDUMP="$ac_cv_prog_OBJDUMP" fi test -z "$OBJDUMP" && OBJDUMP=objdump { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 $as_echo_n "checking how to recognize dependent libraries... " >&6; } if ${lt_cv_deplibs_check_method+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[4-9]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[45]*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin* | msys*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[3-9]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 $as_echo "$lt_cv_deplibs_check_method" >&6; } file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. set dummy ${ac_tool_prefix}dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DLLTOOL"; then ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DLLTOOL=$ac_cv_prog_DLLTOOL if test -n "$DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 $as_echo "$DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DLLTOOL"; then ac_ct_DLLTOOL=$DLLTOOL # Extract the first word of "dlltool", so it can be a program name with args. set dummy dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DLLTOOL"; then ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DLLTOOL="dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL if test -n "$ac_ct_DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 $as_echo "$ac_ct_DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DLLTOOL" = x; then DLLTOOL="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DLLTOOL=$ac_ct_DLLTOOL fi else DLLTOOL="$ac_cv_prog_DLLTOOL" fi test -z "$DLLTOOL" && DLLTOOL=dlltool { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 $as_echo_n "checking how to associate runtime and link libraries... " >&6; } if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO if test -n "$ac_tool_prefix"; then for ac_prog in ar do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AR"; then ac_cv_prog_AR="$AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AR="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AR=$ac_cv_prog_AR if test -n "$AR"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 $as_echo "$AR" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AR" && break done fi if test -z "$AR"; then ac_ct_AR=$AR for ac_prog in ar do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 $as_echo "$ac_ct_AR" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_AR" && break done if test "x$ac_ct_AR" = x; then AR="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac AR=$ac_ct_AR fi fi : ${AR=ar} # Use ARFLAGS variable as AR's operation code to sync the variable naming with # Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have # higher priority because thats what people were doing historically (setting # ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS # variable obsoleted/removed. test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} lt_ar_flags=$AR_FLAGS # Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override # by AR_FLAGS because that was never working and AR_FLAGS is about to die. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 $as_echo_n "checking for archiver @FILE support... " >&6; } if ${lt_cv_ar_at_file+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ar_at_file=no cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 $as_echo "$lt_cv_ar_at_file" >&6; } if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi test -z "$STRIP" && STRIP=: if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. set dummy ${ac_tool_prefix}ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$RANLIB"; then ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 $as_echo "$RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_RANLIB"; then ac_ct_RANLIB=$RANLIB # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_RANLIB"; then ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 $as_echo "$ac_ct_RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_RANLIB" = x; then RANLIB=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac RANLIB=$ac_ct_RANLIB fi else RANLIB="$ac_cv_prog_RANLIB" fi test -z "$RANLIB" && RANLIB=: # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Check for command to grab the raw symbol name followed by C symbol from nm. { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } if ${lt_cv_sys_global_symbol_pipe+:} false; then : $as_echo_n "(cached) " >&6 else # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[BCDEGRST]' # Regexp to match symbols that can be accessed directly from C. sympat='\([_A-Za-z][_A-Za-z0-9]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[BCDT]' ;; cygwin* | msys* | mingw* | pw32* | cegcc*) symcode='[ABCDGISTW]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[ABCDEGRST]' fi ;; irix* | nonstopux*) symcode='[BCDEGRST]' ;; osf*) symcode='[BCDEGQRST]' ;; solaris*) symcode='[BDRT]' ;; sco3.2v5*) symcode='[DT]' ;; sysv4.2uw2*) symcode='[DT]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[ABDT]' ;; sysv4) symcode='[DFNSTU]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[ABCDGIRSTW]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK '"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx" else lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then # Now try to grab the symbols. nlist=conftest.nm if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT_DLSYM_CONST #else # define LT_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done fi if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 $as_echo "failed" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 $as_echo "ok" >&6; } fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then nm_file_list_spec='@' fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 $as_echo_n "checking for sysroot... " >&6; } # Check whether --with-sysroot was given. if test "${with_sysroot+set}" = set; then : withval=$with_sysroot; else with_sysroot=no fi lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 $as_echo "$with_sysroot" >&6; } as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 $as_echo "${lt_sysroot:-no}" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 $as_echo_n "checking for a working dd... " >&6; } if ${ac_cv_path_lt_DD+:} false; then : $as_echo_n "(cached) " >&6 else printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} if test -z "$lt_DD"; then ac_path_lt_DD_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in dd; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_lt_DD" || continue if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi $ac_path_lt_DD_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_lt_DD"; then : fi else ac_cv_path_lt_DD=$lt_DD fi rm -f conftest.i conftest2.i conftest.out fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 $as_echo "$ac_cv_path_lt_DD" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 $as_echo_n "checking how to truncate binary pipes... " >&6; } if ${lt_cv_truncate_bin+:} false; then : $as_echo_n "(cached) " >&6 else printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 $as_echo "$lt_cv_truncate_bin" >&6; } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then : enableval=$enable_libtool_lock; fi test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then if test yes = "$lt_cv_prog_gnu_ld"; then case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then emul=elf case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 $as_echo_n "checking whether the C compiler needs -belf... " >&6; } if ${lt_cv_cc_needs_belf+:} false; then : $as_echo_n "(cached) " >&6 else ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_cc_needs_belf=yes else lt_cv_cc_needs_belf=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 $as_echo "$lt_cv_cc_needs_belf" >&6; } if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. set dummy ${ac_tool_prefix}mt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$MANIFEST_TOOL"; then ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL if test -n "$MANIFEST_TOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 $as_echo "$MANIFEST_TOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_MANIFEST_TOOL"; then ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL # Extract the first word of "mt", so it can be a program name with args. set dummy mt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_MANIFEST_TOOL"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL if test -n "$ac_ct_MANIFEST_TOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_MANIFEST_TOOL" = x; then MANIFEST_TOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL fi else MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" fi test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } if ${lt_cv_path_mainfest_tool+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&5 if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 $as_echo "$lt_cv_path_mainfest_tool" >&6; } if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi case $host_os in rhapsody* | darwin*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DSYMUTIL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DSYMUTIL"; then ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DSYMUTIL=$ac_cv_prog_DSYMUTIL if test -n "$DSYMUTIL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 $as_echo "$DSYMUTIL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DSYMUTIL"; then ac_ct_DSYMUTIL=$DSYMUTIL # Extract the first word of "dsymutil", so it can be a program name with args. set dummy dsymutil; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DSYMUTIL"; then ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL if test -n "$ac_ct_DSYMUTIL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 $as_echo "$ac_ct_DSYMUTIL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DSYMUTIL" = x; then DSYMUTIL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DSYMUTIL=$ac_ct_DSYMUTIL fi else DSYMUTIL="$ac_cv_prog_DSYMUTIL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. set dummy ${ac_tool_prefix}nmedit; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_NMEDIT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$NMEDIT"; then ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi NMEDIT=$ac_cv_prog_NMEDIT if test -n "$NMEDIT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 $as_echo "$NMEDIT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_NMEDIT"; then ac_ct_NMEDIT=$NMEDIT # Extract the first word of "nmedit", so it can be a program name with args. set dummy nmedit; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_NMEDIT"; then ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_NMEDIT="nmedit" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT if test -n "$ac_ct_NMEDIT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 $as_echo "$ac_ct_NMEDIT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_NMEDIT" = x; then NMEDIT=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac NMEDIT=$ac_ct_NMEDIT fi else NMEDIT="$ac_cv_prog_NMEDIT" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. set dummy ${ac_tool_prefix}lipo; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$LIPO"; then ac_cv_prog_LIPO="$LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_LIPO="${ac_tool_prefix}lipo" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi LIPO=$ac_cv_prog_LIPO if test -n "$LIPO"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 $as_echo "$LIPO" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_LIPO"; then ac_ct_LIPO=$LIPO # Extract the first word of "lipo", so it can be a program name with args. set dummy lipo; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_LIPO"; then ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_LIPO="lipo" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO if test -n "$ac_ct_LIPO"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 $as_echo "$ac_ct_LIPO" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_LIPO" = x; then LIPO=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac LIPO=$ac_ct_LIPO fi else LIPO="$ac_cv_prog_LIPO" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. set dummy ${ac_tool_prefix}otool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL"; then ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL="${ac_tool_prefix}otool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL=$ac_cv_prog_OTOOL if test -n "$OTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 $as_echo "$OTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL"; then ac_ct_OTOOL=$OTOOL # Extract the first word of "otool", so it can be a program name with args. set dummy otool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL"; then ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL="otool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL if test -n "$ac_ct_OTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 $as_echo "$ac_ct_OTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OTOOL" = x; then OTOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL=$ac_ct_OTOOL fi else OTOOL="$ac_cv_prog_OTOOL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. set dummy ${ac_tool_prefix}otool64; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL64"; then ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL64=$ac_cv_prog_OTOOL64 if test -n "$OTOOL64"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 $as_echo "$OTOOL64" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL64"; then ac_ct_OTOOL64=$OTOOL64 # Extract the first word of "otool64", so it can be a program name with args. set dummy otool64; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL64"; then ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL64="otool64" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 if test -n "$ac_ct_OTOOL64"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 $as_echo "$ac_ct_OTOOL64" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OTOOL64" = x; then OTOOL64=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL64=$ac_ct_OTOOL64 fi else OTOOL64="$ac_cv_prog_OTOOL64" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 $as_echo_n "checking for -single_module linker flag... " >&6; } if ${lt_cv_apple_cc_single_mod+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&5 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&5 # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&5 fi rm -rf libconftest.dylib* rm -f conftest.* fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 $as_echo "$lt_cv_apple_cc_single_mod" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } if ${lt_cv_ld_exported_symbols_list+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_ld_exported_symbols_list=yes else lt_cv_ld_exported_symbols_list=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 $as_echo_n "checking for -force_load linker flag... " >&6; } if ${lt_cv_ld_force_load+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 echo "$AR $AR_FLAGS libconftest.a conftest.o" >&5 $AR $AR_FLAGS libconftest.a conftest.o 2>&5 echo "$RANLIB libconftest.a" >&5 $RANLIB libconftest.a 2>&5 cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&5 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&5 fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 $as_echo "$lt_cv_ld_force_load" >&6; } case $host_os in rhapsody* | darwin1.[012]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) case $MACOSX_DEPLOYMENT_TARGET,$host in 10.[012],*|,*powerpc*-darwin[5-8]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; *) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 $as_echo_n "checking how to run the C preprocessor... " >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default " if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in dlfcn.h do : ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default " if test "x$ac_cv_header_dlfcn_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_DLFCN_H 1 _ACEOF fi done func_stripname_cnf () { case $2 in .*) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%\\\\$2\$%%"`;; *) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%$2\$%%"`;; esac } # func_stripname_cnf # Set options # Check whether --enable-shared was given. if test "${enable_shared+set}" = set; then : enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac else enable_shared=yes fi # Check whether --enable-static was given. if test "${enable_static+set}" = set; then : enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac else enable_static=yes fi # Check whether --with-pic was given. if test "${with_pic+set}" = set; then : withval=$with_pic; lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac else pic_mode=default fi # Check whether --enable-fast-install was given. if test "${enable_fast_install+set}" = set; then : enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac else enable_fast_install=yes fi shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[5-9]*,yes) { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; } # Check whether --with-aix-soname was given. if test "${with_aix_soname+set}" = set; then : withval=$with_aix_soname; case $withval in aix|svr4|both) ;; *) as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 ;; esac lt_cv_with_aix_soname=$with_aix_soname else if ${lt_cv_with_aix_soname+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_with_aix_soname=aix fi with_aix_soname=$lt_cv_with_aix_soname fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 $as_echo "$with_aix_soname" >&6; } if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' test -z "$LN_S" && LN_S="ln -s" if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 $as_echo_n "checking for objdir... " >&6; } if ${lt_cv_objdir+:} false; then : $as_echo_n "(cached) " >&6 else rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 $as_echo "$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir cat >>confdefs.h <<_ACEOF #define LT_OBJDIR "$lt_cv_objdir/" _ACEOF case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC and # ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o func_cc_basename $compiler cc_basename=$func_cc_basename_result # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/${ac_tool_prefix}file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 $as_echo_n "checking for file... " >&6; } if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi else MAGIC_CMD=: fi fi fi ;; esac # Use C for the default configuration in the libtool script lt_save_CC=$CC ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o objext=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* if test -n "$compiler"; then lt_prog_compiler_no_builtin_flag= if test yes = "$GCC"; then case $cc_basename in nvcc*) lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; *) lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl= lt_prog_compiler_pic= lt_prog_compiler_static= if test yes = "$GCC"; then lt_prog_compiler_wl='-Wl,' lt_prog_compiler_static='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' fi lt_prog_compiler_pic='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support lt_prog_compiler_pic='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. lt_prog_compiler_static= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) lt_prog_compiler_pic='-fPIC' ;; esac ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic=-Kconform_pic fi ;; *) lt_prog_compiler_pic='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 lt_prog_compiler_wl='-Xlinker ' if test -n "$lt_prog_compiler_pic"; then lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' else lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; esac ;; mingw* | cygwin* | msys* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; # Lahey Fortran 8.1. lf95*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='--shared' lt_prog_compiler_static='--static' ;; nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; ccc*) lt_prog_compiler_wl='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-qpic' lt_prog_compiler_static='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='' ;; *Sun\ F* | *Sun*Fortran*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Wl,' ;; *Intel*\ [CF]*Compiler*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; *Portland\ Group*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; esac ;; esac ;; newsos6) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static='-non_shared' ;; rdos*) lt_prog_compiler_static='-non_shared' ;; solaris*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) lt_prog_compiler_wl='-Qoption ld ';; *) lt_prog_compiler_wl='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl='-Qoption ld ' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic='-Kconform_pic' lt_prog_compiler_static='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; unicos*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_can_build_shared=no ;; uts4*) lt_prog_compiler_pic='-pic' lt_prog_compiler_static='-Bstatic' ;; *) lt_prog_compiler_can_build_shared=no ;; esac fi case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic= ;; *) lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 $as_echo_n "checking for $compiler option to produce PIC... " >&6; } if ${lt_cv_prog_compiler_pic+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic=$lt_prog_compiler_pic fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 $as_echo "$lt_cv_prog_compiler_pic" >&6; } lt_prog_compiler_pic=$lt_cv_prog_compiler_pic # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } if ${lt_cv_prog_compiler_pic_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; } if test yes = "$lt_cv_prog_compiler_pic_works"; then case $lt_prog_compiler_pic in "" | " "*) ;; *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; esac else lt_prog_compiler_pic= lt_prog_compiler_can_build_shared=no fi fi # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } if ${lt_cv_prog_compiler_static_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_static_works=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works=yes fi else lt_cv_prog_compiler_static_works=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 $as_echo "$lt_cv_prog_compiler_static_works" >&6; } if test yes = "$lt_cv_prog_compiler_static_works"; then : else lt_prog_compiler_static= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } hard_links=nottested if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 $as_echo_n "checking if we can lock with hard links... " >&6; } hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 $as_echo "$hard_links" >&6; } if test no = "$hard_links"; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } runpath_var= allow_undefined_flag= always_export_symbols=no archive_cmds= archive_expsym_cmds= compiler_needs_object=no enable_shared_with_static_runtimes=no export_dynamic_flag_spec= export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' hardcode_automatic=no hardcode_direct=no hardcode_direct_absolute=no hardcode_libdir_flag_spec= hardcode_libdir_separator= hardcode_minus_L=no hardcode_shlibpath_var=unsupported inherit_rpath=no link_all_deplibs=unknown module_cmds= module_expsym_cmds= old_archive_from_new_cmds= old_archive_from_expsyms_cmds= thread_safe_flag_spec= whole_archive_flag_spec= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= case $host_os in cygwin* | msys* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; esac ld_shlibs=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; *\ \(GNU\ Binutils\)\ [3-9]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' export_dynamic_flag_spec='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else whole_archive_flag_spec= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then allow_undefined_flag=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else ld_shlibs=no fi ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' export_dynamic_flag_spec='$wl--export-all-symbols' allow_undefined_flag=unsupported always_export_symbols=no enable_shared_with_static_runtimes=yes export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs=no fi ;; haiku*) archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' link_all_deplibs=yes ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes file_list_spec='@' ;; interix[3-9]*) hardcode_direct=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 whole_archive_flag_spec= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes ;; esac case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) export_dynamic_flag_spec='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else ld_shlibs=no fi ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac if test no = "$ld_shlibs"; then runpath_var= hardcode_libdir_flag_spec= export_dynamic_flag_spec= whole_archive_flag_spec= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag=unsupported always_export_symbols=yes archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct=unsupported fi ;; aix[4-9]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds='' hardcode_direct=yes hardcode_direct_absolute=yes hardcode_libdir_separator=':' link_all_deplibs=yes file_list_spec='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. hardcode_direct=no hardcode_direct_absolute=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L=yes hardcode_libdir_flag_spec='-L$libdir' hardcode_libdir_separator= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi export_dynamic_flag_spec='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag='-berok' # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath_+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib' allow_undefined_flag="-z nodefs" archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath_+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag=' $wl-bernotok' allow_undefined_flag=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec='$convenience' fi archive_cmds_need_lc=yes archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; bsdi[45]*) export_dynamic_flag_spec=-rdynamic ;; cygwin* | msys* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl* | icl*) # Native MSVC or ICC hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported always_export_symbols=yes file_list_spec='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, )='true' enable_shared_with_static_runtimes=yes exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib old_postinstall_cmds='chmod 644 $oldlib' postlink_cmds='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC and ICC wrapper hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_from_new_cmds='true' # FIXME: Should let the user specify the lib program. old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' enable_shared_with_static_runtimes=yes ;; esac ;; darwin* | rhapsody*) archive_cmds_need_lc=no hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported if test yes = "$lt_cv_ld_force_load"; then whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' else whole_archive_flag_spec='' fi link_all_deplibs=yes allow_undefined_flag=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" archive_expsym_cmds="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" module_expsym_cmds="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" else ld_shlibs=no fi ;; dgux*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly* | midnightbsd*) archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; hpux9*) if test yes = "$GCC"; then archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes export_dynamic_flag_spec='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 $as_echo_n "checking if $CC understands -b... " >&6; } if ${lt_cv_prog_compiler__b+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler__b=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -b" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler__b=yes fi else lt_cv_prog_compiler__b=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 $as_echo "$lt_cv_prog_compiler__b" >&6; } if test yes = "$lt_cv_prog_compiler__b"; then archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi ;; esac fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: case $host_cpu in hppa*64*|ia64*) hardcode_direct=no hardcode_shlibpath_var=no ;; *) hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } if ${lt_cv_irix_exported_symbol+:} false; then : $as_echo_n "(cached) " >&6 else save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int foo (void) { return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_irix_exported_symbol=yes else lt_cv_irix_exported_symbol=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 $as_echo "$lt_cv_irix_exported_symbol" >&6; } if test yes = "$lt_cv_irix_exported_symbol"; then archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi else archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: inherit_rpath=yes link_all_deplibs=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler ld_shlibs=yes archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; newsos6) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: hardcode_shlibpath_var=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then hardcode_direct=yes hardcode_shlibpath_var=no hardcode_direct_absolute=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' else archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='$wl-rpath,$libdir' fi else ld_shlibs=no fi ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes file_list_spec='@' ;; osf3*) if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' fi archive_cmds_need_lc='no' hardcode_libdir_separator=: ;; solaris*) no_undefined_flag=' -z defs' if test yes = "$GCC"; then wlarc='$wl' archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi hardcode_libdir_flag_spec='-R$libdir' hardcode_shlibpath_var=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else whole_archive_flag_spec='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec='-L$libdir' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; sysv4) case $host_vendor in sni) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds='$CC -r -o $output$reload_objs' hardcode_direct=no ;; motorola) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var=no ;; sysv4.3*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no export_dynamic_flag_spec='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag='$wl-z,text' archive_cmds_need_lc=no hardcode_shlibpath_var=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag='$wl-z,text' allow_undefined_flag='$wl-z,nodefs' archive_cmds_need_lc=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-R,$libdir' hardcode_libdir_separator=':' link_all_deplibs=yes export_dynamic_flag_spec='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) export_dynamic_flag_spec='$wl-Blargedynsym' ;; esac fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 $as_echo "$ld_shlibs" >&6; } test no = "$ld_shlibs" && can_build_shared=no with_gnu_ld=$with_gnu_ld # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc" in x|xyes) # Assume -lc should be added archive_cmds_need_lc=yes if test yes,yes = "$GCC,$enable_shared"; then case $archive_cmds in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } if ${lt_cv_archive_cmds_need_lc+:} false; then : $as_echo_n "(cached) " >&6 else $RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl pic_flag=$lt_prog_compiler_pic compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag allow_undefined_flag= if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then lt_cv_archive_cmds_need_lc=no else lt_cv_archive_cmds_need_lc=yes fi allow_undefined_flag=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; } archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc ;; esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 $as_echo_n "checking dynamic linker characteristics... " >&6; } if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[lt_foo]++; } if (lt_freq[lt_foo] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([A-Za-z]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[4-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a(lib.so.V)' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | msys* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" ;; mingw* | cegcc* | msys*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl* | *,icl*) # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin* | msys*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[23].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[3-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. hardcode_libdir_flag_spec='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH if ${lt_cv_shlibpath_overrides_runpath+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : lt_cv_shlibpath_overrides_runpath=yes fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS libdir=$save_libdir fi shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 $as_echo "$dynamic_linker" >&6; } test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 $as_echo_n "checking how to hardcode library paths into programs... " >&6; } hardcode_action= if test -n "$hardcode_libdir_flag_spec" || test -n "$runpath_var" || test yes = "$hardcode_automatic"; then # We can hardcode non-existent directories. if test no != "$hardcode_direct" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" && test no != "$hardcode_minus_L"; then # Linking always hardcodes the temporary library directory. hardcode_action=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action=unsupported fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 $as_echo "$hardcode_action" >&6; } if test relink = "$hardcode_action" || test yes = "$inherit_rpath"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin* | msys*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 $as_echo_n "checking for dlopen in -ldl... " >&6; } if ${ac_cv_lib_dl_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dl_dlopen=yes else ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" if test "x$ac_cv_func_shl_load" = xyes; then : lt_cv_dlopen=shl_load else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 $as_echo_n "checking for shl_load in -ldld... " >&6; } if ${ac_cv_lib_dld_shl_load+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shl_load (); int main () { return shl_load (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dld_shl_load=yes else ac_cv_lib_dld_shl_load=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 $as_echo "$ac_cv_lib_dld_shl_load" >&6; } if test "x$ac_cv_lib_dld_shl_load" = xyes; then : lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld else ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" if test "x$ac_cv_func_dlopen" = xyes; then : lt_cv_dlopen=dlopen else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 $as_echo_n "checking for dlopen in -ldl... " >&6; } if ${ac_cv_lib_dl_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dl_dlopen=yes else ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 $as_echo_n "checking for dlopen in -lsvld... " >&6; } if ${ac_cv_lib_svld_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsvld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_svld_dlopen=yes else ac_cv_lib_svld_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 $as_echo "$ac_cv_lib_svld_dlopen" >&6; } if test "x$ac_cv_lib_svld_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 $as_echo_n "checking for dld_link in -ldld... " >&6; } if ${ac_cv_lib_dld_dld_link+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dld_link (); int main () { return dld_link (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dld_dld_link=yes else ac_cv_lib_dld_dld_link=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 $as_echo "$ac_cv_lib_dld_dld_link" >&6; } if test "x$ac_cv_lib_dld_dld_link" = xyes; then : lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld fi fi fi fi fi fi ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 $as_echo_n "checking whether a program can dlopen itself... " >&6; } if ${lt_cv_dlopen_self+:} false; then : $as_echo_n "(cached) " >&6 else if test yes = "$cross_compiling"; then : lt_cv_dlopen_self=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 $as_echo "$lt_cv_dlopen_self" >&6; } if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } if ${lt_cv_dlopen_self_static+:} false; then : $as_echo_n "(cached) " >&6 else if test yes = "$cross_compiling"; then : lt_cv_dlopen_self_static=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 $as_echo "$lt_cv_dlopen_self_static" >&6; } fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi striplib= old_striplib= { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 $as_echo_n "checking whether stripping libraries is possible... " >&6; } if test -z "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } else if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else case $host_os in darwin*) # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } ;; freebsd*) if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then old_striplib="$STRIP --strip-debug" striplib="$STRIP --strip-unneeded" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi ;; *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } ;; esac fi fi # Report what library types will actually be built { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 $as_echo_n "checking if libtool supports shared libraries... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 $as_echo "$can_build_shared" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 $as_echo_n "checking whether to build shared libraries... " >&6; } test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 $as_echo "$enable_shared" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 $as_echo_n "checking whether to build static libraries... " >&6; } # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 $as_echo "$enable_static" >&6; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC=$lt_save_CC if test -n "$CXX" && ( test no != "$CXX" && ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || (test g++ != "$CXX"))); then ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } if test -z "$CXXCPP"; then if ${ac_cv_prog_CXXCPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CXXCPP needs to be expanded for CXXCPP in "$CXX -E" "/lib/cpp" do ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CXXCPP=$CXXCPP fi CXXCPP=$ac_cv_prog_CXXCPP else ac_cv_prog_CXXCPP=$CXXCPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 $as_echo "$CXXCPP" >&6; } ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu else _lt_caught_CXX_error=yes fi ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu archive_cmds_need_lc_CXX=no allow_undefined_flag_CXX= always_export_symbols_CXX=no archive_expsym_cmds_CXX= compiler_needs_object_CXX=no export_dynamic_flag_spec_CXX= hardcode_direct_CXX=no hardcode_direct_absolute_CXX=no hardcode_libdir_flag_spec_CXX= hardcode_libdir_separator_CXX= hardcode_minus_L_CXX=no hardcode_shlibpath_var_CXX=unsupported hardcode_automatic_CXX=no inherit_rpath_CXX=no module_cmds_CXX= module_expsym_cmds_CXX= link_all_deplibs_CXX=unknown old_archive_cmds_CXX=$old_archive_cmds reload_flag_CXX=$reload_flag reload_cmds_CXX=$reload_cmds no_undefined_flag_CXX= whole_archive_flag_spec_CXX= enable_shared_with_static_runtimes_CXX=no # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o objext_CXX=$objext # No sense in running all these tests if we already determined that # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} CFLAGS=$CXXFLAGS compiler=$CC compiler_CXX=$CC func_cc_basename $compiler cc_basename=$func_cc_basename_result if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately if test yes = "$GXX"; then lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' else lt_prog_compiler_no_builtin_flag_CXX= fi if test yes = "$GXX"; then # Set up default GNU C++ configuration # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then : withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 $as_echo_n "checking for ld used by $CC... " >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 $as_echo_n "checking for GNU ld... " >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi if ${lt_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 $as_echo "$LD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } if ${lt_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 $as_echo "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test yes = "$with_gnu_ld"; then archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else whole_archive_flag_spec_CXX= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } ld_shlibs_CXX=yes case $host_os in aix3*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aix[4-9]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_CXX='' hardcode_direct_CXX=yes hardcode_direct_absolute_CXX=yes hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes file_list_spec_CXX='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. hardcode_direct_CXX=no hardcode_direct_absolute_CXX=no ;; esac if test yes = "$GXX"; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_CXX=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_CXX=yes hardcode_libdir_flag_spec_CXX='-L$libdir' hardcode_libdir_separator_CXX= fi esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag=$shared_flag' $wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi export_dynamic_flag_spec_CXX='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. always_export_symbols_CXX=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. # The "-G" linker flag allows undefined symbols. no_undefined_flag_CXX='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath__CXX+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath__CXX fi hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then hardcode_libdir_flag_spec_CXX='$wl-R $libdir:/usr/lib:/lib' allow_undefined_flag_CXX="-z nodefs" archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath__CXX+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath__CXX fi hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_CXX=' $wl-bernotok' allow_undefined_flag_CXX=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_CXX='$convenience' fi archive_cmds_need_lc_CXX=yes archive_expsym_cmds_CXX='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$RM -r $output_objdir/$realname.d' fi fi ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_CXX=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else ld_shlibs_CXX=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; cygwin* | msys* | mingw* | pw32* | cegcc*) case $GXX,$cc_basename in ,cl* | no,cl* | ,icl* | no,icl*) # Native MSVC or ICC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec_CXX=' ' allow_undefined_flag_CXX=unsupported always_export_symbols_CXX=yes file_list_spec_CXX='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' enable_shared_with_static_runtimes_CXX=yes # Don't use ranlib old_postinstall_cmds_CXX='chmod 644 $oldlib' postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ func_to_tool_file "$lt_outputfile"~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_CXX='-L$libdir' export_dynamic_flag_spec_CXX='$wl--export-all-symbols' allow_undefined_flag_CXX=unsupported always_export_symbols_CXX=no enable_shared_with_static_runtimes_CXX=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_CXX=no fi ;; esac ;; darwin* | rhapsody*) archive_cmds_need_lc_CXX=no hardcode_direct_CXX=no hardcode_automatic_CXX=yes hardcode_shlibpath_var_CXX=unsupported if test yes = "$lt_cv_ld_force_load"; then whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' else whole_archive_flag_spec_CXX='' fi link_all_deplibs_CXX=yes allow_undefined_flag_CXX=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" archive_expsym_cmds_CXX="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" module_expsym_cmds_CXX="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" if test yes != "$lt_cv_apple_cc_single_mod"; then archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" archive_expsym_cmds_CXX="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi else ld_shlibs_CXX=no fi ;; os2*) hardcode_libdir_flag_spec_CXX='-L$libdir' hardcode_minus_L_CXX=yes allow_undefined_flag_CXX=unsupported shrext_cmds=.dll archive_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds_CXX='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes_CXX=yes file_list_spec_CXX='@' ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; freebsd2.*) # C++ shared libraries reported to be fairly broken before # switch to ELF ld_shlibs_CXX=no ;; freebsd-elf*) archive_cmds_need_lc_CXX=no ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions ld_shlibs_CXX=yes ;; haiku*) archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' link_all_deplibs_CXX=yes ;; hpux9*) hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' hardcode_libdir_separator_CXX=: export_dynamic_flag_spec_CXX='$wl-E' hardcode_direct_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; hpux10*|hpux11*) if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' hardcode_libdir_separator_CXX=: case $host_cpu in hppa*64*|ia64*) ;; *) export_dynamic_flag_spec_CXX='$wl-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no ;; *) hardcode_direct_CXX=yes hardcode_direct_absolute_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; interix[3-9]*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' export_dynamic_flag_spec_CXX='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_CXX='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi link_all_deplibs_CXX=yes ;; esac hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' hardcode_libdir_separator_CXX=: inherit_rpath_CXX=yes ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc* | ecpc* ) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac archive_cmds_need_lc_CXX=no hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [1-5].* | *pgcpp\ [1-5].*) prelink_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' old_archive_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ $RANLIB $oldlib' archive_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac hardcode_libdir_flag_spec_CXX='$wl--rpath $wl$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' whole_archive_flag_spec_CXX='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_CXX='-rpath $libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' hardcode_libdir_flag_spec_CXX='-R$libdir' whole_archive_flag_spec_CXX='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object_CXX=yes # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; m88k*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; *nto* | *qnx*) ld_shlibs_CXX=yes ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no hardcode_direct_absolute_CXX=yes archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' export_dynamic_flag_spec_CXX='$wl-E' whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else ld_shlibs_CXX=no fi ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' hardcode_libdir_separator_CXX=: # Archives containing C++ object files must be created using # the KAI C++ compiler. case $host in osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; esac ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; cxx*) case $host in osf3*) allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' ;; *) allow_undefined_flag_CXX=' -expect_unresolved \*' archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ $RM $lib.exp' hardcode_libdir_flag_spec_CXX='-rpath $libdir' ;; esac hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes,no = "$GXX,$with_gnu_ld"; then allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' case $host in osf3*) archive_cmds_CXX='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ archive_cmds_need_lc_CXX=yes no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_shlibpath_var_CXX=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' ;; esac link_all_deplibs_CXX=yes output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test yes,no = "$GXX,$with_gnu_ld"; then no_undefined_flag_CXX=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. archive_cmds_CXX='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' fi hardcode_libdir_flag_spec_CXX='$wl-R $wl$libdir' case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) whole_archive_flag_spec_CXX='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_CXX='$wl-z,text' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag_CXX='$wl-z,text' allow_undefined_flag_CXX='$wl-z,nodefs' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='$wl-R,$libdir' hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes export_dynamic_flag_spec_CXX='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ '"$old_archive_cmds_CXX" reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ '"$reload_cmds_CXX" ;; *) archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 $as_echo "$ld_shlibs_CXX" >&6; } test no = "$ld_shlibs_CXX" && can_build_shared=no GCC_CXX=$GXX LD_CXX=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... # Dependencies to place before and after the object being linked: predep_objects_CXX= postdep_objects_CXX= predeps_CXX= postdeps_CXX= compiler_lib_search_path_CXX= cat > conftest.$ac_ext <<_LT_EOF class Foo { public: Foo (void) { a = 0; } private: int a; }; _LT_EOF _lt_libdeps_save_CFLAGS=$CFLAGS case "$CC $CFLAGS " in #( *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; esac if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test x-L = "$p" || test x-R = "$p"; then prev=$p continue fi # Expand the sysroot to ease extracting the directories later. if test -z "$prev"; then case $p in -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; esac fi case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac if test no = "$pre_test_object_deps_done"; then case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$compiler_lib_search_path_CXX"; then compiler_lib_search_path_CXX=$prev$p else compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} $prev$p" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$postdeps_CXX"; then postdeps_CXX=$prev$p else postdeps_CXX="${postdeps_CXX} $prev$p" fi fi prev= ;; *.lto.$objext) ;; # Ignore GCC LTO objects *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test no = "$pre_test_object_deps_done"; then if test -z "$predep_objects_CXX"; then predep_objects_CXX=$p else predep_objects_CXX="$predep_objects_CXX $p" fi else if test -z "$postdep_objects_CXX"; then postdep_objects_CXX=$p else postdep_objects_CXX="$postdep_objects_CXX $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling CXX test program" fi $RM -f confest.$objext CFLAGS=$_lt_libdeps_save_CFLAGS # PORTME: override above test on systems where it is broken case $host_os in interix[3-9]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. predep_objects_CXX= postdep_objects_CXX= postdeps_CXX= ;; esac case " $postdeps_CXX " in *" -lc "*) archive_cmds_need_lc_CXX=no ;; esac compiler_lib_search_dirs_CXX= if test -n "${compiler_lib_search_path_CXX}"; then compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi lt_prog_compiler_wl_CXX= lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX= # C++ specific cases for pic, static, wl, etc. if test yes = "$GXX"; then lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' fi lt_prog_compiler_pic_CXX='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support lt_prog_compiler_pic_CXX='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | msys* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic_CXX='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static_CXX='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_CXX='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all lt_prog_compiler_pic_CXX= ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. lt_prog_compiler_static_CXX= ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_CXX=-Kconform_pic fi ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic_CXX='-fPIC -shared' ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac else case $host_os in aix[4-9]*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' else lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; mingw* | cygwin* | msys* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic_CXX='-DDLL_EXPORT' ;; dgux*) case $cc_basename in ec++*) lt_prog_compiler_pic_CXX='-KPIC' ;; ghcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; freebsd* | dragonfly* | midnightbsd*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='$wl-a ${wl}archive' if test ia64 != "$host_cpu"; then lt_prog_compiler_pic_CXX='+Z' fi ;; aCC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_CXX='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler lt_prog_compiler_wl_CXX='--backend -Wl,' lt_prog_compiler_pic_CXX='-fPIC' ;; ecpc* ) # old Intel C++ for x86_64, which still supported -KPIC. lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-static' ;; icpc* ) # Intel C++, used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-fPIC' lt_prog_compiler_static_CXX='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-fpic' lt_prog_compiler_static_CXX='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) # IBM XL 8.0, 9.0 on PPC and BlueGene lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-qpic' lt_prog_compiler_static_CXX='-qstaticlink' ;; *) case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) lt_prog_compiler_pic_CXX='-W c,exportall' ;; *) ;; esac ;; netbsd*) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic_CXX='-fPIC -shared' ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) lt_prog_compiler_wl_CXX='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 lt_prog_compiler_pic_CXX='-pic' ;; cxx*) # Digital/Compaq C++ lt_prog_compiler_wl_CXX='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x lt_prog_compiler_pic_CXX='-pic' lt_prog_compiler_static_CXX='-Bstatic' ;; lcc*) # Lucid lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 lt_prog_compiler_pic_CXX='-KPIC' ;; *) ;; esac ;; vxworks*) ;; *) lt_prog_compiler_can_build_shared_CXX=no ;; esac fi case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_CXX= ;; *) lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 $as_echo_n "checking for $compiler option to produce PIC... " >&6; } if ${lt_cv_prog_compiler_pic_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 $as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_CXX"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_works_CXX=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_CXX=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 $as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } if test yes = "$lt_cv_prog_compiler_pic_works_CXX"; then case $lt_prog_compiler_pic_CXX in "" | " "*) ;; *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; esac else lt_prog_compiler_pic_CXX= lt_prog_compiler_can_build_shared_CXX=no fi fi # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_static_works_CXX=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_CXX=yes fi else lt_cv_prog_compiler_static_works_CXX=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 $as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } if test yes = "$lt_cv_prog_compiler_static_works_CXX"; then : else lt_prog_compiler_static_CXX= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o_CXX=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_CXX=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o_CXX=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_CXX=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } hard_links=nottested if test no = "$lt_cv_prog_compiler_c_o_CXX" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 $as_echo_n "checking if we can lock with hard links... " >&6; } hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 $as_echo "$hard_links" >&6; } if test no = "$hard_links"; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' case $host_os in aix[4-9]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_CXX='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) export_symbols_cmds_CXX=$ltdll_cmds ;; cygwin* | msys* | mingw* | cegcc*) case $cc_basename in cl* | icl*) exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' ;; esac ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 $as_echo "$ld_shlibs_CXX" >&6; } test no = "$ld_shlibs_CXX" && can_build_shared=no with_gnu_ld_CXX=$with_gnu_ld # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_CXX" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_CXX=yes if test yes,yes = "$GCC,$enable_shared"; then case $archive_cmds_CXX in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : $as_echo_n "(cached) " >&6 else $RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_CXX pic_flag=$lt_prog_compiler_pic_CXX compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_CXX allow_undefined_flag_CXX= if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then lt_cv_archive_cmds_need_lc_CXX=no else lt_cv_archive_cmds_need_lc_CXX=yes fi allow_undefined_flag_CXX=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 $as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX ;; esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 $as_echo_n "checking dynamic linker characteristics... " >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[4-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a(lib.so.V)' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | msys* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; mingw* | cegcc* | msys*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl* | *,icl*) # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin* | msys*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[23].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[3-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. hardcode_libdir_flag_spec_CXX='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH if ${lt_cv_shlibpath_overrides_runpath+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_link "$LINENO"; then : if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : lt_cv_shlibpath_overrides_runpath=yes fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS libdir=$save_libdir fi shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 $as_echo "$dynamic_linker" >&6; } test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 $as_echo_n "checking how to hardcode library paths into programs... " >&6; } hardcode_action_CXX= if test -n "$hardcode_libdir_flag_spec_CXX" || test -n "$runpath_var_CXX" || test yes = "$hardcode_automatic_CXX"; then # We can hardcode non-existent directories. if test no != "$hardcode_direct_CXX" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" && test no != "$hardcode_minus_L_CXX"; then # Linking always hardcodes the temporary library directory. hardcode_action_CXX=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_CXX=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_CXX=unsupported fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 $as_echo "$hardcode_action_CXX" >&6; } if test relink = "$hardcode_action_CXX" || test yes = "$inherit_rpath_CXX"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi fi # test -n "$compiler" CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld fi # test yes != "$_lt_caught_CXX_error" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_config_commands="$ac_config_commands libtool" # Only expand once: LIBTOOL='${top_builddir}/libtool' fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 $as_echo_n "checking for connect in -lsocket... " >&6; } if ${ac_cv_lib_socket_connect+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsocket $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char connect (); int main () { return connect (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_socket_connect=yes else ac_cv_lib_socket_connect=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 $as_echo "$ac_cv_lib_socket_connect" >&6; } if test "x$ac_cv_lib_socket_connect" = xyes; then : SOCK_LIBS=-lsocket fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 $as_echo_n "checking for X... " >&6; } # Check whether --with-x was given. if test "${with_x+set}" = set; then : withval=$with_x; fi # $have_x is `yes', `no', `disabled', or empty when we do not yet know. if test "x$with_x" = xno; then # The user explicitly disabled X. have_x=disabled else case $x_includes,$x_libraries in #( *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : $as_echo_n "(cached) " >&6 else # One or both of the vars are not set, and there is no cached value. ac_x_includes=no ac_x_libraries=no rm -f -r conftest.dir if mkdir conftest.dir; then cd conftest.dir cat >Imakefile <<'_ACEOF' incroot: @echo incroot='${INCROOT}' usrlibdir: @echo usrlibdir='${USRLIBDIR}' libdir: @echo libdir='${LIBDIR}' _ACEOF if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. for ac_var in incroot usrlibdir libdir; do eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" done # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. for ac_extension in a so sl dylib la dll; do if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && test -f "$ac_im_libdir/libX11.$ac_extension"; then ac_im_usrlibdir=$ac_im_libdir; break fi done # Screen out bogus values from the imake configuration. They are # bogus both because they are the default anyway, and because # using them would break gcc on systems where it needs fixed includes. case $ac_im_incroot in /usr/include) ac_x_includes= ;; *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; esac case $ac_im_usrlibdir in /usr/lib | /usr/lib64 | /lib | /lib64) ;; *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; esac fi cd .. rm -f -r conftest.dir fi # Standard set of common directories for X headers. # Check X11 before X11Rn because it is often a symlink to the current release. ac_x_header_dirs=' /usr/X11/include /usr/X11R7/include /usr/X11R6/include /usr/X11R5/include /usr/X11R4/include /usr/include/X11 /usr/include/X11R7 /usr/include/X11R6 /usr/include/X11R5 /usr/include/X11R4 /usr/local/X11/include /usr/local/X11R7/include /usr/local/X11R6/include /usr/local/X11R5/include /usr/local/X11R4/include /usr/local/include/X11 /usr/local/include/X11R7 /usr/local/include/X11R6 /usr/local/include/X11R5 /usr/local/include/X11R4 /usr/X386/include /usr/x386/include /usr/XFree86/include/X11 /usr/include /usr/local/include /usr/unsupported/include /usr/athena/include /usr/local/x11r5/include /usr/lpp/Xamples/include /usr/openwin/include /usr/openwin/share/include' if test "$ac_x_includes" = no; then # Guess where to find include files, by looking for Xlib.h. # First, try using that file with no special directory specified. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # We can compile using X headers with no special include directory. ac_x_includes= else for ac_dir in $ac_x_header_dirs; do if test -r "$ac_dir/X11/Xlib.h"; then ac_x_includes=$ac_dir break fi done fi rm -f conftest.err conftest.i conftest.$ac_ext fi # $ac_x_includes = no if test "$ac_x_libraries" = no; then # Check for the libraries. # See if we find them without any special options. # Don't add to $LIBS permanently. ac_save_LIBS=$LIBS LIBS="-lX11 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { XrmInitialize () ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : LIBS=$ac_save_LIBS # We can link X programs with no special library path. ac_x_libraries= else LIBS=$ac_save_LIBS for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` do # Don't even attempt the hair of trying to link an X program! for ac_extension in a so sl dylib la dll; do if test -r "$ac_dir/libX11.$ac_extension"; then ac_x_libraries=$ac_dir break 2 fi done done fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi # $ac_x_libraries = no case $ac_x_includes,$ac_x_libraries in #( no,* | *,no | *\'*) # Didn't find X, or a directory has "'" in its name. ac_cv_have_x="have_x=no";; #( *) # Record where we found X for the cache. ac_cv_have_x="have_x=yes\ ac_x_includes='$ac_x_includes'\ ac_x_libraries='$ac_x_libraries'" esac fi ;; #( *) have_x=yes;; esac eval "$ac_cv_have_x" fi # $with_x != no if test "$have_x" != yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 $as_echo "$have_x" >&6; } no_x=yes else # If each of the values was on the command line, it overrides each guess. test "x$x_includes" = xNONE && x_includes=$ac_x_includes test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries # Update the cache value to reflect the command line values. ac_cv_have_x="have_x=yes\ ac_x_includes='$x_includes'\ ac_x_libraries='$x_libraries'" { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } fi if test "$no_x" = yes; then # Not all programs may use this symbol, but it does not hurt to define it. $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= else if test -n "$x_includes"; then X_CFLAGS="$X_CFLAGS -I$x_includes" fi # It would also be nice to do this for all -L options, not just this one. if test -n "$x_libraries"; then X_LIBS="$X_LIBS -L$x_libraries" # For Solaris; some versions of Sun CC require a space after -R and # others require no space. Words are not sufficient . . . . { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 $as_echo_n "checking whether -R must be followed by a space... " >&6; } ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" ac_xsave_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } X_LIBS="$X_LIBS -R$x_libraries" else LIBS="$ac_xsave_LIBS -R $x_libraries" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } X_LIBS="$X_LIBS -R $x_libraries" else { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 $as_echo "neither works" >&6; } fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext ac_c_werror_flag=$ac_xsave_c_werror_flag LIBS=$ac_xsave_LIBS fi # Check for system-dependent libraries X programs must link with. # Do this before checking for the system-independent R6 libraries # (-lICE), since we may need -lsocket or whatever for X linking. if test "$ISC" = yes; then X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" else # Martyn Johnson says this is needed for Ultrix, if the X # libraries were built with DECnet support. And Karl Berry says # the Alpha needs dnet_stub (dnet does not exist). ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char XOpenDisplay (); int main () { return XOpenDisplay (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldnet $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dnet_ntoa (); int main () { return dnet_ntoa (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dnet_dnet_ntoa=yes else ac_cv_lib_dnet_dnet_ntoa=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" fi if test $ac_cv_lib_dnet_dnet_ntoa = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldnet_stub $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dnet_ntoa (); int main () { return dnet_ntoa (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dnet_stub_dnet_ntoa=yes else ac_cv_lib_dnet_stub_dnet_ntoa=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" fi fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS="$ac_xsave_LIBS" # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, # to get the SysV transport functions. # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) # needs -lnsl. # The nsl library prevents programs from opening the X display # on Irix 5.2, according to T.E. Dickey. # The functions gethostbyname, getservbyname, and inet_addr are # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" if test "x$ac_cv_func_gethostbyname" = xyes; then : fi if test $ac_cv_func_gethostbyname = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } if ${ac_cv_lib_nsl_gethostbyname+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lnsl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char gethostbyname (); int main () { return gethostbyname (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_nsl_gethostbyname=yes else ac_cv_lib_nsl_gethostbyname=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" fi if test $ac_cv_lib_nsl_gethostbyname = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } if ${ac_cv_lib_bsd_gethostbyname+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lbsd $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char gethostbyname (); int main () { return gethostbyname (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_bsd_gethostbyname=yes else ac_cv_lib_bsd_gethostbyname=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" fi fi fi # lieder@skyler.mavd.honeywell.com says without -lsocket, # socket/setsockopt and other routines are undefined under SCO ODT # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary # on later versions), says Simon Leinen: it contains gethostby* # variants that don't use the name server (or something). -lsocket # must be given before -lnsl if both are needed. We assume that # if connect needs -lnsl, so does gethostbyname. ac_fn_c_check_func "$LINENO" "connect" "ac_cv_func_connect" if test "x$ac_cv_func_connect" = xyes; then : fi if test $ac_cv_func_connect = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 $as_echo_n "checking for connect in -lsocket... " >&6; } if ${ac_cv_lib_socket_connect+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsocket $X_EXTRA_LIBS $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char connect (); int main () { return connect (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_socket_connect=yes else ac_cv_lib_socket_connect=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 $as_echo "$ac_cv_lib_socket_connect" >&6; } if test "x$ac_cv_lib_socket_connect" = xyes; then : X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" fi fi # Guillermo Gomez says -lposix is necessary on A/UX. ac_fn_c_check_func "$LINENO" "remove" "ac_cv_func_remove" if test "x$ac_cv_func_remove" = xyes; then : fi if test $ac_cv_func_remove = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 $as_echo_n "checking for remove in -lposix... " >&6; } if ${ac_cv_lib_posix_remove+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lposix $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char remove (); int main () { return remove (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_posix_remove=yes else ac_cv_lib_posix_remove=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 $as_echo "$ac_cv_lib_posix_remove" >&6; } if test "x$ac_cv_lib_posix_remove" = xyes; then : X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" fi fi # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. ac_fn_c_check_func "$LINENO" "shmat" "ac_cv_func_shmat" if test "x$ac_cv_func_shmat" = xyes; then : fi if test $ac_cv_func_shmat = no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 $as_echo_n "checking for shmat in -lipc... " >&6; } if ${ac_cv_lib_ipc_shmat+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lipc $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shmat (); int main () { return shmat (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ipc_shmat=yes else ac_cv_lib_ipc_shmat=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } if test "x$ac_cv_lib_ipc_shmat" = xyes; then : X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" fi fi fi # Check for libraries that X11R6 Xt/Xaw programs need. ac_save_LDFLAGS=$LDFLAGS test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to # check for ICE first), but we must link in the order -lSM -lICE or # we get undefined symbols. So assume we have SM if we have ICE. # These have to be linked with before -lX11, unlike the other # libraries we check for below, so use a different variable. # John Interrante, Karl Berry { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lICE $X_EXTRA_LIBS $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char IceConnectionNumber (); int main () { return IceConnectionNumber (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ICE_IceConnectionNumber=yes else ac_cv_lib_ICE_IceConnectionNumber=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" fi LDFLAGS=$ac_save_LDFLAGS fi if test "$have_x" = "yes"; then X_CFLAGS_AUX="-DHAVE_XLIB" X_LIBS="$X_LIBS -lX11" fi MLTERM_FB="mlterm-fb" # Check whether --with-gui was given. if test "${with_gui+set}" = set; then : withval=$with_gui; gui=$with_gui fi if test `echo $gui | grep ,`; then gui_list=`echo $gui | sed 's/,/ /g'` is_first=t mkdir -p ${top_srcdir-$srcdir}/gui for g in $gui_list; do if test $is_first; then gui=$g is_first= else SUBDIRS="${SUBDIRS} gui/$g" MAKE_DIRS2="${MAKE_DIRS2} gui/$g" if test -d ${top_srcdir-$srcdir}/gui/$g ; then echo "" echo "** WARNING **" echo "${top_srcdir-$srcdir}/gui/$g exists, so copy no files for $g." echo "If there are files which should be copied, copy them manually." echo "" else mkdir -p ${top_srcdir-$srcdir}/gui/$g # clone source tree to build both mlterm, mlterm-wl, mlterm-fb, mlterm-con and mlterm-sdl2. for file in ChangeLog Makefile.in common configure etc gtk inputmethod java \ main man vtemu script scrollbar uitoolkit doc libvterm; do cp -R ${top_srcdir-$srcdir}/$file ${top_srcdir-$srcdir}/gui/$g/ done mkdir -p ${top_srcdir-$srcdir}/gui/$g/contrib cp -R ${top_srcdir-$srcdir}/contrib/scrollbar ${top_srcdir-$srcdir}/gui/$g/contrib/ fi fi done elif test "$gui" = "subdir"; then gui=`basename $PWD` if test "$gui" = "wscons"; then MLTERM_FB="mlterm-wscons" elif test "$gui" = "x68kgrf"; then MLTERM_FB="mlterm-x68kgrf" elif test "$gui" = "scpc98"; then MLTERM_FB="mlterm-scpc98" fi fi if test "$gui" = "wscons"; then gui="fb" fbtype="wscons" elif test "$gui" = "x68kgrf"; then gui="fb" fbtype="x68kgrf" elif test "$gui" = "scpc98"; then gui="fb" fbtype="pc98" fi if test "$gui" = "fb" ; then MAKE_DIRS2="doc/kbd ${MAKE_DIRS2}" OUTPUT_FILES="doc/kbd/Makefile ${OUTPUT_FILES}" fi ml_cv_is_posix="yes" case "${host_os}" in mingw*) CYGPATHW=echo WIN32TAG=_win32 if test ! -f "/lib/libmsys-1.0.dll.a" ; then case "${lt_cv_path_LD}" in *-msys*) ;; *) ml_cv_is_posix="no" ;; esac fi if test "$gui" != "sdl2" -a "$gui" != "win32" ; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi ;; msys*) # msys2 # Extract the first word of "cygpath", so it can be a program name with args. set dummy cygpath; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CYGPATHW+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CYGPATHW"; then ac_cv_prog_CYGPATHW="$CYGPATHW" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CYGPATHW="cygpath -w" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_prog_CYGPATHW" && ac_cv_prog_CYGPATHW="echo" fi fi CYGPATHW=$ac_cv_prog_CYGPATHW if test -n "$CYGPATHW"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATHW" >&5 $as_echo "$CYGPATHW" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi WIN32TAG=_win32 # $have_x is defined in AC_PATH_XTRA. if test "$have_x" = "yes" ; then if test "$gui" = "" ; then gui="xlib" elif test "$gui" != "xlib" -a "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi else if test "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi fi ;; cygwin*) # Extract the first word of "cygpath", so it can be a program name with args. set dummy cygpath; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CYGPATHW+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CYGPATHW"; then ac_cv_prog_CYGPATHW="$CYGPATHW" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CYGPATHW="cygpath -w" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_prog_CYGPATHW" && ac_cv_prog_CYGPATHW="echo" fi fi CYGPATHW=$ac_cv_prog_CYGPATHW if test -n "$CYGPATHW"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATHW" >&5 $as_echo "$CYGPATHW" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi WIN32TAG=_win32 case "${CC} ${CFLAGS}" in *mno-cygwin* | *-mingw*) ml_cv_is_posix="no" ;; *) ;; esac # $have_x is defined in AC_PATH_XTRA. if test "$have_x" = "yes" ; then if test "$gui" = "" ; then gui="xlib" elif test "$gui" != "xlib" -a "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi else if test "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi fi ;; *) CYGPATHW=echo if test "$gui" != "xlib" -a "$gui" != "fb" -a "$gui" != "console" -a "$gui" != "quartz" -a "$gui" != "wayland" -a "$gui" != "sdl2" -a "$gui" != "beos"; then if test "$gui" != "" ; then echo "$gui is not supported in ${host_os}. xlib is used instead." fi gui="xlib" fi # $have_x is defined in AC_PATH_XTRA. if test "$gui" = "xlib" -a "$have_x" != "yes" ; then echo "" echo "** ERROR **" echo "Could not find xlib." echo "" exit 1 fi ;; esac # for java/Makefile.in if test "$ml_cv_is_posix" = "yes" -o "$debug" = "yes" ; then SUBSYSTEM="-Wl,--subsystem,console" fi if test "$with_gnu_ld" = "yes" ; then DEXPORT="-Wl,--version-script=\$(VPATH)/dexport.map" elif test "`$LD --version 2>&1 | $GREP Solaris`" != "" ; then # This option is for SunOS 5.x (Solaris) or later. DEXPORT="-Wl,-M -Wl,\$(VPATH)/dexport-sun.map -Wl,-z -Wl,nodefs" fi # Check whether --with-gtk was given. if test "${with_gtk+set}" = set; then : withval=$with_gtk; gtk_version=$with_gtk fi if test "$gtk_version" = "no" ; then have_gtk=no else if test "$gtk_version" = "4.0" ; then if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_path_PKG_CONFIG"; then ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $ac_pt_PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 $as_echo "$ac_pt_PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_pt_PKG_CONFIG" = x; then PKG_CONFIG="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac PKG_CONFIG=$ac_pt_PKG_CONFIG fi else PKG_CONFIG="$ac_cv_path_PKG_CONFIG" fi fi if test -n "$PKG_CONFIG"; then _pkg_min_version=0.9.0 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } PKG_CONFIG="" fi fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK4" >&5 $as_echo_n "checking for GTK4... " >&6; } if test -n "$GTK4_CFLAGS"; then pkg_cv_GTK4_CFLAGS="$GTK4_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk4\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk4") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK4_CFLAGS=`$PKG_CONFIG --cflags "gtk4" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$GTK4_LIBS"; then pkg_cv_GTK4_LIBS="$GTK4_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk4\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk4") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK4_LIBS=`$PKG_CONFIG --libs "gtk4" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GTK4_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gtk4" 2>&1` else GTK4_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gtk4" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$GTK4_PKG_ERRORS" >&5 have_gtk4=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_gtk4=no else GTK4_CFLAGS=$pkg_cv_GTK4_CFLAGS GTK4_LIBS=$pkg_cv_GTK4_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_gtk4=yes fi # mlconfig supports gtk4, but mlterm-menu and libvte do not support it gtk_version=3.0 elif test "$gtk_version" = "" ; then gtk_version=3.0 fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK" >&5 $as_echo_n "checking for GTK... " >&6; } if test -n "$GTK_CFLAGS"; then pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-\$gtk_version\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk+-$gtk_version") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags "gtk+-$gtk_version" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$GTK_LIBS"; then pkg_cv_GTK_LIBS="$GTK_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-\$gtk_version\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk+-$gtk_version") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs "gtk+-$gtk_version" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gtk+-$gtk_version" 2>&1` else GTK_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gtk+-$gtk_version" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$GTK_PKG_ERRORS" >&5 have_gtk=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_gtk=no else GTK_CFLAGS=$pkg_cv_GTK_CFLAGS GTK_LIBS=$pkg_cv_GTK_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_gtk=yes fi if test "$have_gtk" != "yes"; then if test "$gtk_version" = "3.0"; then gtk_version=2.0 else gtk_version=3.0 fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK" >&5 $as_echo_n "checking for GTK... " >&6; } if test -n "$GTK_CFLAGS"; then pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-\$gtk_version\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk+-$gtk_version") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags "gtk+-$gtk_version" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$GTK_LIBS"; then pkg_cv_GTK_LIBS="$GTK_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-\$gtk_version\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk+-$gtk_version") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs "gtk+-$gtk_version" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gtk+-$gtk_version" 2>&1` else GTK_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gtk+-$gtk_version" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$GTK_PKG_ERRORS" >&5 have_gtk=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_gtk=no else GTK_CFLAGS=$pkg_cv_GTK_CFLAGS GTK_LIBS=$pkg_cv_GTK_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_gtk=yes fi fi fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GDK_PIXBUF" >&5 $as_echo_n "checking for GDK_PIXBUF... " >&6; } if test -n "$GDK_PIXBUF_CFLAGS"; then pkg_cv_GDK_PIXBUF_CFLAGS="$GDK_PIXBUF_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gdk-pixbuf-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "gdk-pixbuf-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GDK_PIXBUF_CFLAGS=`$PKG_CONFIG --cflags "gdk-pixbuf-2.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$GDK_PIXBUF_LIBS"; then pkg_cv_GDK_PIXBUF_LIBS="$GDK_PIXBUF_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gdk-pixbuf-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "gdk-pixbuf-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GDK_PIXBUF_LIBS=`$PKG_CONFIG --libs "gdk-pixbuf-2.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GDK_PIXBUF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gdk-pixbuf-2.0" 2>&1` else GDK_PIXBUF_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gdk-pixbuf-2.0" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$GDK_PIXBUF_PKG_ERRORS" >&5 have_gdk_pixbuf2=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_gdk_pixbuf2=no else GDK_PIXBUF_CFLAGS=$pkg_cv_GDK_PIXBUF_CFLAGS GDK_PIXBUF_LIBS=$pkg_cv_GDK_PIXBUF_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_gdk_pixbuf2=yes fi # try to link libgio-2.0 explicitly. (SF topic #6234829) if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gdk-pixbuf-2.0 >= 2.14\""; } >&5 ($PKG_CONFIG --exists --print-errors "gdk-pixbuf-2.0 >= 2.14") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GIO" >&5 $as_echo_n "checking for GIO... " >&6; } if test -n "$GIO_CFLAGS"; then pkg_cv_GIO_CFLAGS="$GIO_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gio-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "gio-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GIO_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$GIO_LIBS"; then pkg_cv_GIO_LIBS="$GIO_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gio-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "gio-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GIO_LIBS=`$PKG_CONFIG --libs "gio-2.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GIO_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gio-2.0" 2>&1` else GIO_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gio-2.0" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$GIO_PKG_ERRORS" >&5 as_fn_error $? "Package requirements (gio-2.0) were not met: $GIO_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. Alternatively, you may set the environment variables GIO_CFLAGS and GIO_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. Alternatively, you may set the environment variables GIO_CFLAGS and GIO_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details. To get pkg-config, see . See \`config.log' for more details" "$LINENO" 5; } else GIO_CFLAGS=$pkg_cv_GIO_CFLAGS GIO_LIBS=$pkg_cv_GIO_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi fi GDK_PIXBUF_CFLAGS="$GDK_PIXBUF_CFLAGS $GIO_CFLAGS" GDK_PIXBUF_LIBS="$GDK_PIXBUF_LIBS $GIO_LIBS" # Extract the first word of "gdk-pixbuf-config", so it can be a program name with args. set dummy gdk-pixbuf-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_have_gdk_pixbuf1+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$have_gdk_pixbuf1"; then ac_cv_prog_have_gdk_pixbuf1="$have_gdk_pixbuf1" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_have_gdk_pixbuf1="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi have_gdk_pixbuf1=$ac_cv_prog_have_gdk_pixbuf1 if test -n "$have_gdk_pixbuf1"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gdk_pixbuf1" >&5 $as_echo "$have_gdk_pixbuf1" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$gui" = "xlib" ; then # Check whether --with-imagelib was given. if test "${with_imagelib+set}" = set; then : withval=$with_imagelib; imagelib=$with_imagelib fi else # Don't link an external image library on win32gdi or framebuffer. with_imagelib="" fi case ${imagelib} in imlib) # Extract the first word of "imlib-config", so it can be a program name with args. set dummy imlib-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_imlib_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$imlib_config"; then ac_cv_prog_imlib_config="$imlib_config" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_imlib_config="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_prog_imlib_config" && ac_cv_prog_imlib_config="no" fi fi imlib_config=$ac_cv_prog_imlib_config if test -n "$imlib_config"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $imlib_config" >&5 $as_echo "$imlib_config" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$imlib_config" = "xno" ; then echo "" echo "** ERROR **" echo "Could not find imlib-config." echo "" exit 1 fi echo "" echo "** WARNING **" echo " imlib is no longer supported." echo "" IMAGELIB_CFLAGS="`imlib-config --cflags` -DBUILTIN_IMAGELIB" IMAGELIB_LIBS="`imlib-config --libs`" ;; imlib2) # Extract the first word of "imlib2-config", so it can be a program name with args. set dummy imlib2-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_imlib2_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$imlib2_config"; then ac_cv_prog_imlib2_config="$imlib2_config" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_imlib2_config="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_prog_imlib2_config" && ac_cv_prog_imlib2_config="no" fi fi imlib2_config=$ac_cv_prog_imlib2_config if test -n "$imlib2_config"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $imlib2_config" >&5 $as_echo "$imlib2_config" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$imlib2_config" = "xno" ; then echo "" echo "** ERROR **" echo "Could not find imlib2-config." echo "" exit 1 fi echo "" echo "** WARNING **" echo " imlib2 is no longer supported." echo "" IMAGELIB_CFLAGS="`imlib2-config --cflags` -DBUILTIN_IMAGELIB" IMAGELIB_LIBS="`imlib2-config --libs`" ;; gdk-pixbuf) if test "$have_gdk_pixbuf2" = "yes" ; then gdk_pixbuf_version=2 elif test "$have_gdk_pixbuf1" = "yes" ; then gdk_pixbuf_version=1 else echo "" echo "** ERROR **" echo "Could not find gdk-pixbuf" echo "" exit 1 fi ;; gdk-pixbuf2) if test "$have_gdk_pixbuf2" = "yes" ; then gdk_pixbuf_version=2 else echo "" echo "** ERROR **" echo "Could not find gdk-pixbuf2" echo "" exit 1 fi ;; gdk-pixbuf1) if test "$have_gdk_pixbuf1" = "yes" ; then gdk_pixbuf_version=1 else echo "" echo "** ERROR **" echo "Could not find gdk-pixbuf1" echo "" exit 1 fi ;; *) if test "${imagelib}" != "" ; then echo "" echo "** ERROR **" echo "${imagelib} library is NOT supported." echo "" exit 1 fi ;; esac pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FT" >&5 $as_echo_n "checking for FT... " >&6; } if test -n "$FT_CFLAGS"; then pkg_cv_FT_CFLAGS="$FT_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FT_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$FT_LIBS"; then pkg_cv_FT_LIBS="$FT_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FT_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then FT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "freetype2" 2>&1` else FT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "freetype2" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$FT_PKG_ERRORS" >&5 have_ft=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_ft=no else FT_CFLAGS=$pkg_cv_FT_CFLAGS FT_LIBS=$pkg_cv_FT_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_ft=yes fi if test "$have_ft" = "no" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FT" >&5 $as_echo_n "checking for FT... " >&6; } if test -n "$FT_CFLAGS"; then pkg_cv_FT_CFLAGS="$FT_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype\""; } >&5 ($PKG_CONFIG --exists --print-errors "freetype") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FT_CFLAGS=`$PKG_CONFIG --cflags "freetype" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$FT_LIBS"; then pkg_cv_FT_LIBS="$FT_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype\""; } >&5 ($PKG_CONFIG --exists --print-errors "freetype") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FT_LIBS=`$PKG_CONFIG --libs "freetype" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then FT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "freetype" 2>&1` else FT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "freetype" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$FT_PKG_ERRORS" >&5 have_ft=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_ft=no else FT_CFLAGS=$pkg_cv_FT_CFLAGS FT_LIBS=$pkg_cv_FT_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_ft=yes fi fi # -DUSE_FREETYPE can be added to FT_CFLAGS later. FT_CFLAGS_ORIGINAL=$FT_CFLAGS if test "$gdk_pixbuf_version" != "" ; then if test "$gdk_pixbuf_version" = "1" ; then # Override GDK_PIXBUF_XXX variables. GDK_PIXBUF_CFLAGS="`gdk-pixbuf-config --cflags`" GDK_PIXBUF_LIBS="`gdk-pixbuf-config --libs`" echo "" echo "** WARNING **" echo " gdk-pixbuf1 is no longer supported." echo "" fi IMAGELIB_CFLAGS="${GDK_PIXBUF_CFLAGS} -DBUILTIN_IMAGELIB" IMAGELIB_LIBS="${GDK_PIXBUF_LIBS}" if test "$have_ft" = "yes"; then IMAGELIB_CFLAGS="$IMAGELIB_CFLAGS -DUSE_FREETYPE_EMOJI $FT_CFLAGS_ORIGINAL" IMAGELIB_LIBS="$IMAGELIB_LIBS $FT_LIBS" fi elif test "$have_gdk_pixbuf2" != "yes" -a "$have_gdk_pixbuf1" = "yes" ; then GDK_PIXBUF_CFLAGS="`gdk-pixbuf-config --cflags`" GDK_PIXBUF_LIBS="`gdk-pixbuf-config --libs`" fi # Used by mlimgloader. # XXX For pow in libm.so which is used in ui_imagelib.c # /lib/* ... e.g.) /lib/i386-linux-gnu in ubuntu. for ml_cv_lib_path in /lib /usr/lib /lib/* `echo $LIBRARY_PATH | tr ":" " "` ; do libm_files=`ls $ml_cv_lib_path/libm\\.so* $ml_cv_lib_path/libm\\.sl* 2> /dev/null` for libm_file in $libm_files ; do if test -n "`$NM -D $libm_file | $GREP pow`" ; then ml_cv_libm_dir=`dirname $libm_file` break fi done if test "$ml_cv_libm_dir" != ""; then break fi done if test -z "$IMAGELIB_LIBS" ; then if test -n "$ml_cv_libm_dir" ; then MATH_CFLAGS="-DDLOPEN_LIBM -DLIBMDIR=\\\"$ml_cv_libm_dir\\\"" else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pow in -lm" >&5 $as_echo_n "checking for pow in -lm... " >&6; } if ${ac_cv_lib_m_pow+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pow (); int main () { return pow (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_m_pow=yes else ac_cv_lib_m_pow=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_pow" >&5 $as_echo "$ac_cv_lib_m_pow" >&6; } if test "x$ac_cv_lib_m_pow" = xyes; then : MATH_LIBS=-lm fi fi else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pow in -lm" >&5 $as_echo_n "checking for pow in -lm... " >&6; } if ${ac_cv_lib_m_pow+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pow (); int main () { return pow (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_m_pow=yes else ac_cv_lib_m_pow=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_pow" >&5 $as_echo "$ac_cv_lib_m_pow" >&6; } if test "x$ac_cv_lib_m_pow" = xyes; then : MATH_LIBS=-lm fi fi # Check whether --enable-image was given. if test "${enable_image+set}" = set; then : enableval=$enable_image; image=$enable_image else image="yes" fi if test "$image" != "yes" ; then # If sixel.h is not found on gui=console, set IMAGE_CFLAGS="-DNO_IMAGE" forcibly below. IMAGE_CFLAGS="-DNO_IMAGE" fi if test "$gui" = "win32" ; then GUI="win32" GUI_CFLAGS="-DUSE_WIN32GUI" X_CFLAGS="" elif test "$gui" = "xlib" ; then GUI="xlib" # Li18nux Xlib-I18N defines X_HAVE_UTF8_STRING but has no Xutf8LookupString. ldflags="$LDFLAGS" cflags="$CFLAGS" LDFLAGS="$LDFLAGS $X_PRE_LIBS $X_LIBS $X_EXTRA_LIBS" CFLAGS="$X_CFLAGS $CFLAGS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xutf8LookupString in -lX11" >&5 $as_echo_n "checking for Xutf8LookupString in -lX11... " >&6; } if ${ac_cv_lib_X11_Xutf8LookupString+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lX11 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char Xutf8LookupString (); int main () { return Xutf8LookupString (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_X11_Xutf8LookupString=yes else ac_cv_lib_X11_Xutf8LookupString=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_X11_Xutf8LookupString" >&5 $as_echo "$ac_cv_lib_X11_Xutf8LookupString" >&6; } if test "x$ac_cv_lib_X11_Xutf8LookupString" = xyes; then : XUTF8_CFLAGS="-DHAVE_XUTF8_LOOKUP_STRING" fi LDFLAGS="$ldflags" CFLAGS="$cflags" elif test "$gui" = "quartz" ; then GUI="quartz" GUI_CFLAGS="-DUSE_QUARTZ" if test "$ios_sdk" != ""; then GUI_CFLAGS="$GUI_CFLAGS -DCOCOA_TOUCH" COCOAOBJ=cocoatouch.o COCOA_LIBS="-framework Foundation -framework UIKit -framework CoreGraphics" else COCOAOBJ=cocoa.o COCOA_LIBS="-framework Foundation -framework Cocoa" fi X_CFLAGS="" VT_NORM_OBJ="vt_normalize.o" VT_NORM_CFLAGS="-DUSE_NORMALIZE" elif test "$gui" = "console" ; then GUI="console" GUI_CFLAGS="-DUSE_CONSOLE" ac_fn_c_check_header_mongrel "$LINENO" "sixel.h" "ac_cv_header_sixel_h" "$ac_includes_default" if test "x$ac_cv_header_sixel_h" = xyes; then : SIXEL_CFLAGS="-DUSE_LIBSIXEL" fi if test "$SIXEL_CFLAGS" = "-DUSE_LIBSIXEL" ; then SIXEL_LIBS="-lsixel" else IMAGE_CFLAGS="-DNO_IMAGE" IMAGELIB_CFLAGS="" IMAGELIB_LIBS="" fi elif test "$gui" = "beos" ; then GUI="beos" GUI_CFLAGS="-DUSE_BEOS" elif test "$gui" = "wayland" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WAYLAND" >&5 $as_echo_n "checking for WAYLAND... " >&6; } if test -n "$WAYLAND_CFLAGS"; then pkg_cv_WAYLAND_CFLAGS="$WAYLAND_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"wayland-client wayland-cursor xkbcommon\""; } >&5 ($PKG_CONFIG --exists --print-errors "wayland-client wayland-cursor xkbcommon") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_WAYLAND_CFLAGS=`$PKG_CONFIG --cflags "wayland-client wayland-cursor xkbcommon" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$WAYLAND_LIBS"; then pkg_cv_WAYLAND_LIBS="$WAYLAND_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"wayland-client wayland-cursor xkbcommon\""; } >&5 ($PKG_CONFIG --exists --print-errors "wayland-client wayland-cursor xkbcommon") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_WAYLAND_LIBS=`$PKG_CONFIG --libs "wayland-client wayland-cursor xkbcommon" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then WAYLAND_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "wayland-client wayland-cursor xkbcommon" 2>&1` else WAYLAND_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "wayland-client wayland-cursor xkbcommon" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$WAYLAND_PKG_ERRORS" >&5 as_fn_error $? "Package requirements (wayland-client wayland-cursor xkbcommon) were not met: $WAYLAND_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. Alternatively, you may set the environment variables WAYLAND_CFLAGS and WAYLAND_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. Alternatively, you may set the environment variables WAYLAND_CFLAGS and WAYLAND_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details. To get pkg-config, see . See \`config.log' for more details" "$LINENO" 5; } else WAYLAND_CFLAGS=$pkg_cv_WAYLAND_CFLAGS WAYLAND_LIBS=$pkg_cv_WAYLAND_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi GUI="wayland" GUI_CFLAGS="-DUSE_WAYLAND" elif test "$gui" = "sdl2" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SDL2" >&5 $as_echo_n "checking for SDL2... " >&6; } if test -n "$SDL2_CFLAGS"; then pkg_cv_SDL2_CFLAGS="$SDL2_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sdl2\""; } >&5 ($PKG_CONFIG --exists --print-errors "sdl2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDL2_CFLAGS=`$PKG_CONFIG --cflags "sdl2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$SDL2_LIBS"; then pkg_cv_SDL2_LIBS="$SDL2_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sdl2\""; } >&5 ($PKG_CONFIG --exists --print-errors "sdl2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDL2_LIBS=`$PKG_CONFIG --libs "sdl2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then SDL2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "sdl2" 2>&1` else SDL2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "sdl2" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$SDL2_PKG_ERRORS" >&5 have_sdl2=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_sdl2=no else SDL2_CFLAGS=$pkg_cv_SDL2_CFLAGS SDL2_LIBS=$pkg_cv_SDL2_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_sdl2=yes fi if test "$have_sdl2" != "yes" ; then # Extract the first word of "sdl2-config", so it can be a program name with args. set dummy sdl2-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_sdl2_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$sdl2_config"; then ac_cv_prog_sdl2_config="$sdl2_config" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_sdl2_config="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi sdl2_config=$ac_cv_prog_sdl2_config if test -n "$sdl2_config"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sdl2_config" >&5 $as_echo "$sdl2_config" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$sdl2_config" = "yes"; then SDL2_CFLAGS="`sdl2-config --cflags`" SDL2_LIBS="`sdl2-config --libs`" else echo "sdl2 is not available." exit 1 fi fi if test "$ml_cv_is_posix" != "yes"; then SDL2GUI="win32" fi GUI="sdl2" GUI_CFLAGS="-DUSE_SDL2" else GUI="fb" if test "$fbtype" = ""; then if test "`sysctl machdep.ispc98`" = "machdep.ispc98: 1"; then fbtype="pc98" else # for NetBSD/x68k # is also checked not to enable USE_GRF on NetBSD/macppc. ac_fn_c_check_header_mongrel "$LINENO" "machine/grfioctl.h" "ac_cv_header_machine_grfioctl_h" "$ac_includes_default" if test "x$ac_cv_header_machine_grfioctl_h" = xyes; then : ac_fn_c_check_header_mongrel "$LINENO" "machine/vuid_event.h" "ac_cv_header_machine_vuid_event_h" "$ac_includes_default" if test "x$ac_cv_header_machine_vuid_event_h" = xyes; then : fbtype="x68kgrf" GUI_CFLAGS="-DHAVE_GRFIOCTL_H" fi fi fi fi if test "$fbtype" = "x68kgrf"; then GUI_CFLAGS="${GUI_CFLAGS} -DUSE_GRF" elif test "$fbtype" = "pc98"; then GUI_CFLAGS="${GUI_CFLAGS} -DPC98" fi GUI_CFLAGS="${GUI_CFLAGS} -DUSE_FRAMEBUFFER" fi ac_fn_c_check_header_mongrel "$LINENO" "regex.h" "ac_cv_header_regex_h" "$ac_includes_default" if test "x$ac_cv_header_regex_h" = xyes; then : REGEX_CFLAGS="-DHAVE_REGEX" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for regcomp in -lregex" >&5 $as_echo_n "checking for regcomp in -lregex... " >&6; } if ${ac_cv_lib_regex_regcomp+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lregex $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char regcomp (); int main () { return regcomp (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_regex_regcomp=yes else ac_cv_lib_regex_regcomp=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_regex_regcomp" >&5 $as_echo "$ac_cv_lib_regex_regcomp" >&6; } if test "x$ac_cv_lib_regex_regcomp" = xyes; then : REGEX_LIBS=-lregex fi fi # Check whether --enable-compact-truecolor was given. if test "${enable_compact_truecolor+set}" = set; then : enableval=$enable_compact_truecolor; compact_truecolor=$enable_compact_truecolor else compact_truecolor="yes" fi if test "$compact_truecolor" = "yes" ; then TRUECOLOR_CFLAGS="-DUSE_COMPACT_TRUECOLOR" else TRUECOLOR_TAG="x" fi # Check whether --enable-dl-ctl was given. if test "${enable_dl_ctl+set}" = set; then : enableval=$enable_dl_ctl; dl_ctl=$enable_dl_ctl else dl_ctl="yes" fi if test "$enable_shared" = "no" ; then dl_ctl="no" fi if test "$dl_ctl" = "yes" ; then LMLTERM_CORE=libmlterm${TRUECOLOR_TAG}_core.la CTL_LOADER_OBJ=vt_ctl_loader.o else LMLTERM_CORE=libmlterm${TRUECOLOR_TAG}_core.a CTL_CFLAGS="-DNO_DYNAMIC_LOAD_CTL" CTL_LIBS_FOR_VTE="../vtemu/libctl/*.lo" fi # Check whether --enable-fribidi was given. if test "${enable_fribidi+set}" = set; then : enableval=$enable_fribidi; fribidi=$enable_fribidi else fribidi="yes" fi if test "$fribidi" = "yes" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FRIBIDI" >&5 $as_echo_n "checking for FRIBIDI... " >&6; } if test -n "$FRIBIDI_CFLAGS"; then pkg_cv_FRIBIDI_CFLAGS="$FRIBIDI_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fribidi\""; } >&5 ($PKG_CONFIG --exists --print-errors "fribidi") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FRIBIDI_CFLAGS=`$PKG_CONFIG --cflags "fribidi" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$FRIBIDI_LIBS"; then pkg_cv_FRIBIDI_LIBS="$FRIBIDI_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fribidi\""; } >&5 ($PKG_CONFIG --exists --print-errors "fribidi") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FRIBIDI_LIBS=`$PKG_CONFIG --libs "fribidi" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then FRIBIDI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "fribidi" 2>&1` else FRIBIDI_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "fribidi" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$FRIBIDI_PKG_ERRORS" >&5 have_fribidi=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_fribidi=no else FRIBIDI_CFLAGS=$pkg_cv_FRIBIDI_CFLAGS FRIBIDI_LIBS=$pkg_cv_FRIBIDI_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_fribidi=yes fi if test "$have_fribidi" != "yes" ; then # Extract the first word of "fribidi-config", so it can be a program name with args. set dummy fribidi-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_fribidi_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$fribidi_config"; then ac_cv_prog_fribidi_config="$fribidi_config" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_fribidi_config="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_prog_fribidi_config" && ac_cv_prog_fribidi_config="fribidi="no"" fi fi fribidi_config=$ac_cv_prog_fribidi_config if test -n "$fribidi_config"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fribidi_config" >&5 $as_echo "$fribidi_config" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$fribidi_config" = "yes" ; then FRIBIDI_CFLAGS="`fribidi-config --cflags`" FRIBIDI_LIBS="`fribidi-config --libs`" have_fribidi="yes" fi fi else have_fribidi="no" fi if test "$have_fribidi" = "yes" ; then if test "$dl_ctl" = "yes" ; then CTL_LIBS="libctl${TRUECOLOR_TAG}_bidi.la ${CTL_LIBS}" else CTL_CFLAGS="-DUSE_FRIBIDI ${CTL_CFLAGS}" CTL_LIBS="libctl${TRUECOLOR_TAG}_bidi.a ${CTL_LIBS}" CTL_LIBS_FOR_PROG="../vtemu/libctl/libctl${TRUECOLOR_TAG}_bidi.a ${FRIBIDI_LIBS} ${CTL_LIBS_FOR_PROG}" CTL_LIBS_FOR_VTE="${FRIBIDI_LIBS} ${CTL_LIBS_FOR_VTE}" fi fi # Check whether --with-pthread was given. if test "${with_pthread+set}" = set; then : withval=$with_pthread; fi # Check whether --enable-dl-type was given. if test "${enable_dl_type+set}" = set; then : enableval=$enable_dl_type; dl_type=$enable_dl_type else dl_type="yes" fi if test "$enable_shared" = "no" ; then dl_type="no" fi if test "$dl_type" = "yes" ; then TYPE_LOADER_OBJ=ui_type_loader.o if test "$gui" != "xlib" ; then TYPE_CFLAGS="-DNO_DYNAMIC_LOAD_TYPE" fi else TYPE_CFLAGS="-DNO_DYNAMIC_LOAD_TYPE" TYPE_LIBS_FOR_VTE="../uitoolkit/libtype/*.lo" fi if test "$gui" != "win32" -a "$gui" != "quartz"; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FONTCONFIG" >&5 $as_echo_n "checking for FONTCONFIG... " >&6; } if test -n "$FONTCONFIG_CFLAGS"; then pkg_cv_FONTCONFIG_CFLAGS="$FONTCONFIG_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fontconfig\""; } >&5 ($PKG_CONFIG --exists --print-errors "fontconfig") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$FONTCONFIG_LIBS"; then pkg_cv_FONTCONFIG_LIBS="$FONTCONFIG_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fontconfig\""; } >&5 ($PKG_CONFIG --exists --print-errors "fontconfig") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "fontconfig" 2>&1` else FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "fontconfig" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$FONTCONFIG_PKG_ERRORS" >&5 have_fc=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_fc=no else FONTCONFIG_CFLAGS=$pkg_cv_FONTCONFIG_CFLAGS FONTCONFIG_LIBS=$pkg_cv_FONTCONFIG_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_fc=yes fi if test "$have_fc" = "yes"; then FONTCONFIG_CFLAGS="$FONTCONFIG_CFLAGS -DUSE_FONTCONFIG" fi fi # Check whether --enable-anti_alias was given. if test "${enable_anti_alias+set}" = set; then : enableval=$enable_anti_alias; anti_alias=$enable_anti_alias else anti_alias="auto" fi if test "$anti_alias" != "no"; then if test "$gui" = "fb" -o "$gui" = "wayland" -o "$gui" = "sdl2"; then if test "$have_ft" = "yes" ; then FT_CFLAGS="$FT_CFLAGS -DUSE_FREETYPE " # Check whether --enable-fontconfig was given. if test "${enable_fontconfig+set}" = set; then : enableval=$enable_fontconfig; fontconfig=$enable_fontconfig else fontconfig="yes" fi if test "$fontconfig" != "no" -a "$have_fc" = "yes"; then FT_CFLAGS="$FT_CFLAGS $FONTCONFIG_CFLAGS" FT_LIBS="$FT_LIBS $FONTCONFIG_LIBS" else fontconfig="no" fi fi fi fi # Check whether --with-type_engines was given. if test "${with_type_engines+set}" = set; then : withval=$with_type_engines; type_engines=$with_type_engines fi if test "$gui" != "xlib" ; then type_engines="xcore" elif test "$type_engines" = "" ; then if test "$anti_alias" = "no" ; then type_engines="xcore" else type_engines="xcore,xft,cairo" fi fi type_engines=`echo ${type_engines} | sed 's/,/ /g'` for type_engine in ${type_engines} ; do case ${type_engine} in xft) pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XFT" >&5 $as_echo_n "checking for XFT... " >&6; } if test -n "$XFT_CFLAGS"; then pkg_cv_XFT_CFLAGS="$XFT_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xft\""; } >&5 ($PKG_CONFIG --exists --print-errors "xft") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_XFT_CFLAGS=`$PKG_CONFIG --cflags "xft" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$XFT_LIBS"; then pkg_cv_XFT_LIBS="$XFT_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xft\""; } >&5 ($PKG_CONFIG --exists --print-errors "xft") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_XFT_LIBS=`$PKG_CONFIG --libs "xft" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then XFT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "xft" 2>&1` else XFT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "xft" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$XFT_PKG_ERRORS" >&5 have_xft=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_xft=no else XFT_CFLAGS=$pkg_cv_XFT_CFLAGS XFT_LIBS=$pkg_cv_XFT_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_xft=yes fi if test "$have_xft" != "yes" ; then # Extract the first word of "xft-config", so it can be a program name with args. set dummy xft-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_xft_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$xft_config"; then ac_cv_prog_xft_config="$xft_config" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_xft_config="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi xft_config=$ac_cv_prog_xft_config if test -n "$xft_config"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xft_config" >&5 $as_echo "$xft_config" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$xft_config" = "yes" ; then XFT_CFLAGS="`xft-config --cflags`" XFT_LIBS="`xft-config --libs`" have_xft=yes else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftDrawCreate in -lXft" >&5 $as_echo_n "checking for XftDrawCreate in -lXft... " >&6; } if ${ac_cv_lib_Xft_XftDrawCreate+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lXft $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char XftDrawCreate (); int main () { return XftDrawCreate (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_Xft_XftDrawCreate=yes else ac_cv_lib_Xft_XftDrawCreate=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftDrawCreate" >&5 $as_echo "$ac_cv_lib_Xft_XftDrawCreate" >&6; } if test "x$ac_cv_lib_Xft_XftDrawCreate" = xyes; then : have_xft=yes # -lfontconfig is necessary because ui_font.c refers FcXXX # functions directly. XFT_LIBS="-lXft -lfontconfig" fi fi elif test "$gui" = "xlib" -a "$enable_shared" = "no" ; then # In case --disable-shared is specified on some platforms # (e.g. ubuntu 14.04) where dependency_libs="" in libXft.la. XFT_LIBS="$XFT_LIBS -lfontconfig -lfreetype" fi if test "$have_xft" = "yes" ; then if test "$dl_type" = "yes" ; then TYPE_LIBS="libtype_xft.la ${TYPE_LIBS}" else NODL_OBJ="ui_window_xft.o ${NODL_OBJ}" TYPE_LIBS_FOR_VTE="${XFT_LIBS} ${TYPE_LIBS_FOR_VTE}" fi TYPE_CFLAGS="-DUSE_TYPE_XFT ${TYPE_CFLAGS}" type_engines_result="$type_engines_result xft" fi ;; cairo) pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAIRO" >&5 $as_echo_n "checking for CAIRO... " >&6; } if test -n "$CAIRO_CFLAGS"; then pkg_cv_CAIRO_CFLAGS="$CAIRO_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"cairo\""; } >&5 ($PKG_CONFIG --exists --print-errors "cairo") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CAIRO_CFLAGS=`$PKG_CONFIG --cflags "cairo" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$CAIRO_LIBS"; then pkg_cv_CAIRO_LIBS="$CAIRO_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"cairo\""; } >&5 ($PKG_CONFIG --exists --print-errors "cairo") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CAIRO_LIBS=`$PKG_CONFIG --libs "cairo" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then CAIRO_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "cairo" 2>&1` else CAIRO_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "cairo" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$CAIRO_PKG_ERRORS" >&5 have_cairo=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_cairo=no else CAIRO_CFLAGS=$pkg_cv_CAIRO_CFLAGS CAIRO_LIBS=$pkg_cv_CAIRO_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_cairo=yes fi if test "$have_cairo" != "yes" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cairo_create in -lcairo" >&5 $as_echo_n "checking for cairo_create in -lcairo... " >&6; } if ${ac_cv_lib_cairo_cairo_create+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lcairo $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char cairo_create (); int main () { return cairo_create (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_cairo_cairo_create=yes else ac_cv_lib_cairo_cairo_create=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cairo_cairo_create" >&5 $as_echo "$ac_cv_lib_cairo_cairo_create" >&6; } if test "x$ac_cv_lib_cairo_cairo_create" = xyes; then : have_cairo=yes # -lfontconfig is necessary because ui_font.c refers FcXXX # functions directly. CAIRO_LIBS="-lcairo -lfontconfig" fi elif test "$gui" = "xlib" -a "$enable_shared" = "no" ; then # In case --disable-shared is specified on some platforms # (e.g. ubuntu 14.04) where dependency_libs="" in libcairo.la. CAIRO_LIBS="$CAIRO_LIBS -lfontconfig -lfreetype" fi if test "$have_cairo" = "yes" ; then if test "$dl_type" = "yes" ; then TYPE_LIBS="libtype_cairo.la ${TYPE_LIBS}" if test "$with_pthread" != "no" ; then # NetBSD doesn't allow shared libraries to link # libpthread without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi else NODL_OBJ="ui_window_cairo.o ${NODL_OBJ}" TYPE_LIBS_FOR_VTE="${CAIRO_LIBS} ${TYPE_LIBS_FOR_VTE}" fi TYPE_CFLAGS="-DUSE_TYPE_CAIRO ${TYPE_CFLAGS}" type_engines_result="$type_engines_result cairo" fi ;; xcore) TYPE_CFLAGS="-DUSE_TYPE_XCORE ${TYPE_CFLAGS}" type_engines_result="$type_engines_result xcore" ;; *) echo "${type_engine} is unknown type engine." ;; esac done # Check whether --enable-otl was given. if test "${enable_otl+set}" = set; then : enableval=$enable_otl; otl=$enable_otl else otl="yes" fi if test "$otl" != "yes" ; then echo "Open Type layout is disabled" elif test "$gui" = "xlib" -a "$dl_type" = "no" -a "$type_engines_result" = " xcore"; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "fb" -a "$have_ft" != "yes" ; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "wayland" -a "$have_ft" != "yes" ; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "sdl2" -a "$have_ft" != "yes" ; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "console" ; then echo "libotf/libharfbuzz is not available." else pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HB" >&5 $as_echo_n "checking for HB... " >&6; } if test -n "$HB_CFLAGS"; then pkg_cv_HB_CFLAGS="$HB_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"harfbuzz\""; } >&5 ($PKG_CONFIG --exists --print-errors "harfbuzz") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_HB_CFLAGS=`$PKG_CONFIG --cflags "harfbuzz" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$HB_LIBS"; then pkg_cv_HB_LIBS="$HB_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"harfbuzz\""; } >&5 ($PKG_CONFIG --exists --print-errors "harfbuzz") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_HB_LIBS=`$PKG_CONFIG --libs "harfbuzz" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then HB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "harfbuzz" 2>&1` else HB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "harfbuzz" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$HB_PKG_ERRORS" >&5 have_hb=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_hb=no else HB_CFLAGS=$pkg_cv_HB_CFLAGS HB_LIBS=$pkg_cv_HB_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_hb=yes fi if test "$have_hb" = "yes" ; then if test "$gui" = "quartz" ; then CFLAGS_orig=$CFLAGS CPPFLAGS_orig=$CPPFLAGS CFLAGS="$CFLAGS $HB_CFLAGS" CPPFLAGS="$CPPFLAGS $HB_CFLAGS" ac_fn_c_check_header_mongrel "$LINENO" "hb-coretext.h" "ac_cv_header_hb_coretext_h" "$ac_includes_default" if test "x$ac_cv_header_hb_coretext_h" = xyes; then : have_hb_coretext_h=yes else have_hb_coretext_h=no fi CFLAGS=$CFLAGS_orig CPPFLAGS=$CPPFLAGS_orig if test "$have_hb_coretext_h" != "yes" ; then echo "" echo "** ERROR **" echo "harfbuzz/hb-coretext.h is not found." echo "Install harfbuzz with --with-coretext=yes in advance." echo "" have_hb=no fi elif test "$have_ft" = "yes" ; then CFLAGS_orig=$CFLAGS CPPFLAGS_orig=$CPPFLAGS CFLAGS="$CFLAGS $HB_CFLAGS $FT_CFLAGS_ORIGINAL" CPPFLAGS="$CPPFLAGS $HB_CFLAGS $FT_CFLAGS_ORIGINAL" ac_fn_c_check_header_mongrel "$LINENO" "hb-ft.h" "ac_cv_header_hb_ft_h" "$ac_includes_default" if test "x$ac_cv_header_hb_ft_h" = xyes; then : have_hb_ft_h=yes else have_hb_ft_h=no fi CFLAGS=$CFLAGS_orig CPPFLAGS=$CPPFLAGS_orig if test "$have_hb_ft_h" != "yes" ; then echo "" echo "** ERROR **" echo "harfbuzz/hb-ft.h is not found." echo "Install harfbuzz with --with-freetype=yes in advance." echo "" have_hb=no fi fi fi if test "$have_hb" = "yes"; then OT_LAYOUT_CFLAGS="$HB_CFLAGS -DUSE_HARFBUZZ -DUSE_OT_LAYOUT" OT_LAYOUT_LIBS="$HB_LIBS" OT_LAYOUT_OBJ=hb.o if test "$gui" = "win32"; then OT_LAYOUT_LIBS="$OT_LAYOUT_LIBS -lfreetype" elif test "$gui" != "quartz" -a "$have_ft" = "yes"; then OT_LAYOUT_CFLAGS="$OT_LAYOUT_CFLAGS $FT_CFLAGS_ORIGINAL" fi elif test "$gui" = "win32" ; then OT_LAYOUT_CFLAGS="-DUSE_OT_LAYOUT -DUSE_UNISCRIBE" OT_LAYOUT_OBJ=uniscribe.o OT_LAYOUT_LIBS="-lusp10" else # Extract the first word of "libotf-config", so it can be a program name with args. set dummy libotf-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_libotf_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$libotf_config"; then ac_cv_prog_libotf_config="$libotf_config" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_libotf_config="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi libotf_config=$ac_cv_prog_libotf_config if test -n "$libotf_config"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libotf_config" >&5 $as_echo "$libotf_config" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$libotf_config" = "yes" ; then OT_LAYOUT_CFLAGS="`libotf-config --cflags` -DUSE_OT_LAYOUT" OT_LAYOUT_LIBS="`libotf-config --libs`" OT_LAYOUT_OBJ=otf.o fi fi if test "$OT_LAYOUT_OBJ" != "" -a "$enable_shared" = "no" ; then OT_LAYOUT_CFLAGS="$OT_LAYOUT_CFLAGS -DNO_DYNAMIC_LOAD_OTL" OT_LAYOUT_LIBS_FOR_PROG="$OT_LAYOUT_LIBS" fi if test "$OT_LAYOUT_OBJ" != "" -a "$LMLTERM_CORE" = "libmlterm${TRUECOLOR_TAG}_core.la" ; then LMLTERM_CORE="libmlterm${TRUECOLOR_TAG}_coreotl.la" fi fi if test "$OT_LAYOUT_OBJ" != "" ; then MAKE_DIRS2="uitoolkit/libotl ${MAKE_DIRS2}" OUTPUT_FILES="uitoolkit/libotl/Makefile ${OUTPUT_FILES}" fi if test "${NODL_OBJ}" != "" ; then TYPE_LIBS=libtype.a TYPE_LIBS_FOR_PROG="../uitoolkit/libtype/libtype.a ${CAIRO_LIBS} ${XFT_LIBS} ${OT_LAYOUT_LIBS}" fi if test "${TYPE_CFLAGS}" = "" ; then echo "No type engine is specified." exit 1 fi # Check whether --enable-ssh2 was given. if test "${enable_ssh2+set}" = set; then : enableval=$enable_ssh2; ssh2=$enable_ssh2 else ssh2="yes" fi if test "$ssh2" = "yes" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSH2" >&5 $as_echo_n "checking for SSH2... " >&6; } if test -n "$SSH2_CFLAGS"; then pkg_cv_SSH2_CFLAGS="$SSH2_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libssh2\""; } >&5 ($PKG_CONFIG --exists --print-errors "libssh2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SSH2_CFLAGS=`$PKG_CONFIG --cflags "libssh2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$SSH2_LIBS"; then pkg_cv_SSH2_LIBS="$SSH2_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libssh2\""; } >&5 ($PKG_CONFIG --exists --print-errors "libssh2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SSH2_LIBS=`$PKG_CONFIG --libs "libssh2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then SSH2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libssh2" 2>&1` else SSH2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libssh2" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$SSH2_PKG_ERRORS" >&5 ssh2="no" elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } ssh2="no" else SSH2_CFLAGS=$pkg_cv_SSH2_CFLAGS SSH2_LIBS=$pkg_cv_SSH2_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SSH2_CFLAGS="$SSH2_CFLAGS -DUSE_LIBSSH2" if test "x$allow_undefined_flag" = "xunsupported" ; then # vt_pty_ssh.c uses CRYPTO_xxx functions. SSH2_LIBS="-lcrypto $SSH2_LIBS" fi fi fi if test "$enable_shared" != "no" ; then # Check whether --with-mosh was given. if test "${with_mosh+set}" = set; then : withval=$with_mosh; fi if test -d "$with_mosh"; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PROTOBUF" >&5 $as_echo_n "checking for PROTOBUF... " >&6; } if test -n "$PROTOBUF_CFLAGS"; then pkg_cv_PROTOBUF_CFLAGS="$PROTOBUF_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"protobuf\""; } >&5 ($PKG_CONFIG --exists --print-errors "protobuf") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_PROTOBUF_CFLAGS=`$PKG_CONFIG --cflags "protobuf" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$PROTOBUF_LIBS"; then pkg_cv_PROTOBUF_LIBS="$PROTOBUF_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"protobuf\""; } >&5 ($PKG_CONFIG --exists --print-errors "protobuf") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_PROTOBUF_LIBS=`$PKG_CONFIG --libs "protobuf" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then PROTOBUF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "protobuf" 2>&1` else PROTOBUF_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "protobuf" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$PROTOBUF_PKG_ERRORS" >&5 with_mosh="" elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } with_mosh="" else PROTOBUF_CFLAGS=$pkg_cv_PROTOBUF_CFLAGS PROTOBUF_LIBS=$pkg_cv_PROTOBUF_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } MOSH_DIR=$with_mosh fi if test "$MOSH_DIR" != ""; then if test -f $MOSH_DIR/src/crypto/ocb.cc; then # mosh-1.3.2 or before. MOSH_OCB_OBJ="ocb.o" # XXX (See terminaldisplayinit.cc) PROTOBUF_CFLAGS="$PROTOBUF_CFLAGS -DMOSH_VERSION=10302" else # mosh-1.4.0 or later. MOSH_OCB_OBJ="ocb_internal.o" fi fi fi fi if test "$ml_cv_is_posix" = "no" ; then if test "$ssh2" = "yes" ; then VT_PTY_OBJ="vt_pty_ssh.o vt_pty_mosh.o" if test -d "$with_mosh"; then MAKE_DIRS2="${MAKE_DIRS2} vtemu/libptyssh vtemu/libptymosh" OUTPUT_FILES="${OUTPUT_FILES} vtemu/libptyssh/Makefile vtemu/libptymosh/Makefile" SSH2_LIBS_FOR_PROG="-lwsock32" # XXX Hack for wcwidth() PROTOBUF_LIBS="$PROTOBUF_LIBS \${top_builddir}/encodefilter/src/libmef.la" else # Not dlopen SSH2_CFLAGS="$SSH2_CFLAGS -DNO_DYNAMIC_LOAD_SSH" SSH2_LIBS_FOR_PROG="$SSH2_LIBS -lwsock32 -lws2_32" SSH2_LIBS= fi else VT_PTY_OBJ="vt_pty_pipewin32.o" fi else VT_PTY_OBJ="vt_pty_unix.o" if test "$ssh2" = "yes" ; then if test "$with_pthread" != "no" ; then ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default" if test "x$ac_cv_header_pthread_h" = xyes; then : SSH2_CFLAGS="$SSH2_CFLAGS -DHAVE_PTHREAD" SSH2_LIBS="$SSH2_LIBS -lpthread" fi # NetBSD doesn't allow shared libraries to link libpthread # without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi VT_PTY_OBJ="vt_pty_ssh.o vt_pty_mosh.o ${VT_PTY_OBJ}" if test "$enable_shared" = "no" ; then SSH2_CFLAGS="$SSH2_CFLAGS -DNO_DYNAMIC_LOAD_SSH" SSH2_LIBS_FOR_PROG="$SSH2_LIBS" SSH2_LIBS= else # dlopen libptyssh MAKE_DIRS2="vtemu/libptyssh ${MAKE_DIRS2}" OUTPUT_FILES="vtemu/libptyssh/Makefile ${OUTPUT_FILES}" if test -d "$with_mosh"; then MAKE_DIRS2="${MAKE_DIRS2} vtemu/libptymosh" OUTPUT_FILES="${OUTPUT_FILES} vtemu/libptymosh/Makefile" fi fi fi fi if test "${have_gtk}" = "yes" ; then if test "${gtk_version}" = "3.0" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for VTE" >&5 $as_echo_n "checking for VTE... " >&6; } if test -n "$VTE_CFLAGS"; then pkg_cv_VTE_CFLAGS="$VTE_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"vte-2.91\""; } >&5 ($PKG_CONFIG --exists --print-errors "vte-2.91") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_VTE_CFLAGS=`$PKG_CONFIG --cflags "vte-2.91" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$VTE_LIBS"; then pkg_cv_VTE_LIBS="$VTE_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"vte-2.91\""; } >&5 ($PKG_CONFIG --exists --print-errors "vte-2.91") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_VTE_LIBS=`$PKG_CONFIG --libs "vte-2.91" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then VTE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "vte-2.91" 2>&1` else VTE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "vte-2.91" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$VTE_PKG_ERRORS" >&5 have_vte=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_vte=no else VTE_CFLAGS=$pkg_cv_VTE_CFLAGS VTE_LIBS=$pkg_cv_VTE_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_vte=yes fi if test "$have_vte" = "yes" ; then VTE_ABI=2.91 else pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for VTE" >&5 $as_echo_n "checking for VTE... " >&6; } if test -n "$VTE_CFLAGS"; then pkg_cv_VTE_CFLAGS="$VTE_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"vte-2.90\""; } >&5 ($PKG_CONFIG --exists --print-errors "vte-2.90") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_VTE_CFLAGS=`$PKG_CONFIG --cflags "vte-2.90" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$VTE_LIBS"; then pkg_cv_VTE_LIBS="$VTE_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"vte-2.90\""; } >&5 ($PKG_CONFIG --exists --print-errors "vte-2.90") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_VTE_LIBS=`$PKG_CONFIG --libs "vte-2.90" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then VTE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "vte-2.90" 2>&1` else VTE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "vte-2.90" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$VTE_PKG_ERRORS" >&5 have_vte=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_vte=no else VTE_CFLAGS=$pkg_cv_VTE_CFLAGS VTE_LIBS=$pkg_cv_VTE_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_vte=yes fi if test "$have_vte" = "yes"; then VTE_ABI=2.90 fi fi else pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for VTE" >&5 $as_echo_n "checking for VTE... " >&6; } if test -n "$VTE_CFLAGS"; then pkg_cv_VTE_CFLAGS="$VTE_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"vte\""; } >&5 ($PKG_CONFIG --exists --print-errors "vte") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_VTE_CFLAGS=`$PKG_CONFIG --cflags "vte" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$VTE_LIBS"; then pkg_cv_VTE_LIBS="$VTE_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"vte\""; } >&5 ($PKG_CONFIG --exists --print-errors "vte") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_VTE_LIBS=`$PKG_CONFIG --libs "vte" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then VTE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "vte" 2>&1` else VTE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "vte" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$VTE_PKG_ERRORS" >&5 have_vte=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_vte=no else VTE_CFLAGS=$pkg_cv_VTE_CFLAGS VTE_LIBS=$pkg_cv_VTE_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_vte=yes fi fi if test "$have_vte" = "yes" ; then OUTPUT_FILES="gtk/Makefile ${OUTPUT_FILES}" fi else have_vte=no fi tools="mlclient,mlconfig,mlcc,mlterm-menu,mlimgloader,registobmp,mlfc" # Check whether --with-tools was given. if test "${with_tools+set}" = set; then : withval=$with_tools; # if given --without-tools if test "${with_tools}" = "no" ; then tools="" else if test "${with_tools}" != "yes" ; then tools=${with_tools} fi if test -z "$IMAGELIB_CFLAGS" -a "`echo ${tools}|$GREP mlimgloader`" = "" ; then # If --with-imagelib option is not specified, mlimgloader is always built. tools=${tools},mlimgloader fi fi fi tools=`echo ${tools} | sed 's/,/ /g'` # Check whether --enable-use-tools was given. if test "${enable_use_tools+set}" = set; then : enableval=$enable_use_tools; fi if test "$enable_use_tools" = "no" ; then TOOLS_CFLAGS="-DNO_TOOLS" tools= fi am__api_version='1.16' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[\\\"\#\$\&\'\`$am_lf]*) as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; esac # Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( am_has_slept=no for am_try in 1 2; do echo "timestamp, slept: $am_has_slept" > conftest.file set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t "$srcdir/configure" conftest.file` fi if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". as_fn_error $? "ls -t appears to fail. Make sure there is not a broken alias in your environment" "$LINENO" 5 fi if test "$2" = conftest.file || test $am_try -eq 2; then break fi # Just in case. sleep 1 am_has_slept=yes done test "$2" = conftest.file ) then # Ok. : else as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= if grep 'slept: no' conftest.file >/dev/null 2>&1; then ( sleep 1 ) & am_sleep_pid=$! fi rm -f conftest.file test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. # By default was `s,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` if test x"${MISSING+set}" != xset; then MISSING="\${SHELL} '$am_aux_dir/missing'" fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then am_missing_run="$MISSING " else am_missing_run= { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} fi if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; *) install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi # Installed binaries are usually stripped using 'strip' when the user # run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the 'STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } if test -z "$MKDIR_P"; then if ${ac_cv_path_mkdir+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ 'mkdir (fileutils) '4.1*) ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext break 3;; esac done done done IFS=$as_save_IFS fi test -d ./--version && rmdir ./--version if test "${ac_cv_path_mkdir+set}" = set; then MKDIR_P="$ac_cv_path_mkdir -p" else # As a last resort, use the slow shell script. Don't cache a # value for MKDIR_P within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. MKDIR_P="$ac_install_sh -d" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 $as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; } cat > confinc.mk << 'END' am__doit: @echo this is the am__doit target >confinc.out .PHONY: am__doit END am__include="#" am__quote= # BSD make does it like this. echo '.include "confinc.mk" # ignored' > confmf.BSD # Other make implementations (GNU, Solaris 10, AIX) do it like this. echo 'include confinc.mk # ignored' > confmf.GNU _am_result=no for s in GNU BSD; do { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } case $?:`cat confinc.out 2>/dev/null` in #( '0:this is the am__doit target') : case $s in #( BSD) : am__include='.include' am__quote='"' ;; #( *) : am__include='include' am__quote='' ;; esac ;; #( *) : ;; esac if test "$am__include" != "#"; then _am_result="yes ($s style)" break fi done rm -f confinc.* confmf.* { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 $as_echo "${_am_result}" >&6; } # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' am__nodep='_no' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi # Check whether --enable-silent-rules was given. if test "${enable_silent_rules+set}" = set; then : enableval=$enable_silent_rules; fi case $enable_silent_rules in # ((( yes) AM_DEFAULT_VERBOSITY=0;; no) AM_DEFAULT_VERBOSITY=1;; *) AM_DEFAULT_VERBOSITY=1;; esac am_make=${MAKE-make} { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 $as_echo_n "checking whether $am_make supports nested variables... " >&6; } if ${am_cv_make_support_nested_variables+:} false; then : $as_echo_n "(cached) " >&6 else if $as_echo 'TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 am__doit: @$(TRUE) .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 $as_echo "$am_cv_make_support_nested_variables" >&6; } if test $am_cv_make_support_nested_variables = yes; then AM_V='$(V)' AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' else AM_V=$AM_DEFAULT_VERBOSITY AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY fi AM_BACKSLASH='\' if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE=mlterm VERSION=3.9.3 cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: # # mkdir_p='$(MKDIR_P)' # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. # Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AMTAR='$${TAR-tar}' # We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar pax cpio none' am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi am__universal=false case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi depcc="$CXX" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if ${am_cv_CXX_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CXX_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi am__universal=false case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CXX_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CXX_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 $as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then am__fastdepCXX_TRUE= am__fastdepCXX_FALSE='#' else am__fastdepCXX_TRUE='#' am__fastdepCXX_FALSE= fi # Variables for tags utilities; see am/tags.am if test -z "$CTAGS"; then CTAGS=ctags fi if test -z "$ETAGS"; then ETAGS=etags fi if test -z "$CSCOPE"; then CSCOPE=cscope fi # POSIX will say in a future version that running "rm -f" with no argument # is OK; and we want to be able to make that assumption in our Makefile # recipes. So use an aggressive probe to check that the usage we want is # actually supported "in the wild" to an acceptable degree. # See automake bug#10828. # To make any issue more visible, cause the running configure to be aborted # by default if the 'rm' program in use doesn't match our expectations; the # user can still override this though. if true; then : OK; else cat >&2 <<'END' Oops! Your 'rm' program seems unable to run without file operands specified on the command line, even when the '-f' option is present. This is contrary to the behaviour of most rm programs out there, and not conforming with the upcoming POSIX standard: Please tell bug-automake@gnu.org about your system, including the value of your $PATH and any error possibly output before this message. This can help us improve future automake versions. END if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then echo 'Configuration will proceed anyway, since you have set the' >&2 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 echo >&2 else cat >&2 <<'END' Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM to "yes", and re-run configure. END as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 fi fi for tool in ${tools} ; do case ${tool} in mlconfig) if test "$gui" != "fb" -a "$gui" != "console" ; then if test "${have_gtk}" = "yes" -o "${have_gtk4}" = "yes" ; then for ac_header in locale.h do : ac_fn_c_check_header_mongrel "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default" if test "x$ac_cv_header_locale_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LOCALE_H 1 _ACEOF fi done if test $ac_cv_header_locale_h = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5 $as_echo_n "checking for LC_MESSAGES... " >&6; } if ${am_cv_val_LC_MESSAGES+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return LC_MESSAGES ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : am_cv_val_LC_MESSAGES=yes else am_cv_val_LC_MESSAGES=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5 $as_echo "$am_cv_val_LC_MESSAGES" >&6; } if test $am_cv_val_LC_MESSAGES = yes; then $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h fi fi USE_NLS=yes gt_cv_have_gettext=no CATOBJEXT=NONE XGETTEXT=: INTLLIBS= { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; } if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then : $as_echo_n "(cached) " >&6 else gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { CFPreferencesCopyAppValue(NULL, NULL) ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : gt_cv_func_CFPreferencesCopyAppValue=yes else gt_cv_func_CFPreferencesCopyAppValue=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS="$gt_save_LIBS" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5 $as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; } if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5 $as_echo_n "checking for CFLocaleCopyCurrent... " >&6; } if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then : $as_echo_n "(cached) " >&6 else gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { CFLocaleCopyCurrent(); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : gt_cv_func_CFLocaleCopyCurrent=yes else gt_cv_func_CFLocaleCopyCurrent=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS="$gt_save_LIBS" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5 $as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; } if test $gt_cv_func_CFLocaleCopyCurrent = yes; then $as_echo "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h fi INTL_MACOSX_LIBS= if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation" fi ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default" if test "x$ac_cv_header_libintl_h" = xyes; then : gt_cv_func_dgettext_libintl="no" libintl_extra_libs="" # # First check in libc # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ngettext in libc" >&5 $as_echo_n "checking for ngettext in libc... " >&6; } if ${gt_cv_func_ngettext_libc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return !ngettext ("","", 1) ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : gt_cv_func_ngettext_libc=yes else gt_cv_func_ngettext_libc=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_ngettext_libc" >&5 $as_echo "$gt_cv_func_ngettext_libc" >&6; } if test "$gt_cv_func_ngettext_libc" = "yes" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dgettext in libc" >&5 $as_echo_n "checking for dgettext in libc... " >&6; } if ${gt_cv_func_dgettext_libc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return !dgettext ("","") ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : gt_cv_func_dgettext_libc=yes else gt_cv_func_dgettext_libc=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_dgettext_libc" >&5 $as_echo "$gt_cv_func_dgettext_libc" >&6; } fi if test "$gt_cv_func_ngettext_libc" = "yes" ; then for ac_func in bind_textdomain_codeset do : ac_fn_c_check_func "$LINENO" "bind_textdomain_codeset" "ac_cv_func_bind_textdomain_codeset" if test "x$ac_cv_func_bind_textdomain_codeset" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_BIND_TEXTDOMAIN_CODESET 1 _ACEOF fi done fi # # If we don't have everything we want, check in libintl # if test "$gt_cv_func_dgettext_libc" != "yes" \ || test "$gt_cv_func_ngettext_libc" != "yes" \ || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bindtextdomain in -lintl" >&5 $as_echo_n "checking for bindtextdomain in -lintl... " >&6; } if ${ac_cv_lib_intl_bindtextdomain+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char bindtextdomain (); int main () { return bindtextdomain (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_bindtextdomain=yes else ac_cv_lib_intl_bindtextdomain=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_bindtextdomain" >&5 $as_echo "$ac_cv_lib_intl_bindtextdomain" >&6; } if test "x$ac_cv_lib_intl_bindtextdomain" = xyes; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ngettext in -lintl" >&5 $as_echo_n "checking for ngettext in -lintl... " >&6; } if ${ac_cv_lib_intl_ngettext+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char ngettext (); int main () { return ngettext (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_ngettext=yes else ac_cv_lib_intl_ngettext=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_ngettext" >&5 $as_echo "$ac_cv_lib_intl_ngettext" >&6; } if test "x$ac_cv_lib_intl_ngettext" = xyes; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dgettext in -lintl" >&5 $as_echo_n "checking for dgettext in -lintl... " >&6; } if ${ac_cv_lib_intl_dgettext+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dgettext (); int main () { return dgettext (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_dgettext=yes else ac_cv_lib_intl_dgettext=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_dgettext" >&5 $as_echo "$ac_cv_lib_intl_dgettext" >&6; } if test "x$ac_cv_lib_intl_dgettext" = xyes; then : gt_cv_func_dgettext_libintl=yes fi fi fi if test "$gt_cv_func_dgettext_libintl" != "yes" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -liconv is needed to use gettext" >&5 $as_echo_n "checking if -liconv is needed to use gettext... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5 $as_echo "" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ngettext in -lintl" >&5 $as_echo_n "checking for ngettext in -lintl... " >&6; } if ${ac_cv_lib_intl_ngettext+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl -liconv $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char ngettext (); int main () { return ngettext (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_ngettext=yes else ac_cv_lib_intl_ngettext=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_ngettext" >&5 $as_echo "$ac_cv_lib_intl_ngettext" >&6; } if test "x$ac_cv_lib_intl_ngettext" = xyes; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dcgettext in -lintl" >&5 $as_echo_n "checking for dcgettext in -lintl... " >&6; } if ${ac_cv_lib_intl_dcgettext+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl -liconv $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dcgettext (); int main () { return dcgettext (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_dcgettext=yes else ac_cv_lib_intl_dcgettext=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_dcgettext" >&5 $as_echo "$ac_cv_lib_intl_dcgettext" >&6; } if test "x$ac_cv_lib_intl_dcgettext" = xyes; then : gt_cv_func_dgettext_libintl=yes libintl_extra_libs=-liconv else : fi else : fi fi # # If we found libintl, then check in it for bind_textdomain_codeset(); # we'll prefer libc if neither have bind_textdomain_codeset(), # and both have dgettext and ngettext # if test "$gt_cv_func_dgettext_libintl" = "yes" ; then glib_save_LIBS="$LIBS" LIBS="$LIBS -lintl $libintl_extra_libs" unset ac_cv_func_bind_textdomain_codeset for ac_func in bind_textdomain_codeset do : ac_fn_c_check_func "$LINENO" "bind_textdomain_codeset" "ac_cv_func_bind_textdomain_codeset" if test "x$ac_cv_func_bind_textdomain_codeset" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_BIND_TEXTDOMAIN_CODESET 1 _ACEOF fi done LIBS="$glib_save_LIBS" if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then gt_cv_func_dgettext_libc=no else if test "$gt_cv_func_dgettext_libc" = "yes" \ && test "$gt_cv_func_ngettext_libc" = "yes"; then gt_cv_func_dgettext_libintl=no fi fi fi fi if test "$gt_cv_func_dgettext_libc" = "yes" \ || test "$gt_cv_func_dgettext_libintl" = "yes"; then gt_cv_have_gettext=yes fi if test "$gt_cv_func_dgettext_libintl" = "yes"; then INTLLIBS="-lintl $libintl_extra_libs $INTL_MACOSX_LIBS" fi if test "$gt_cv_have_gettext" = "yes"; then $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h # Extract the first word of "msgfmt", so it can be a program name with args. set dummy msgfmt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_MSGFMT+:} false; then : $as_echo_n "(cached) " >&6 else case "$MSGFMT" in /*) ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. ;; *) IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then ac_cv_path_MSGFMT="$ac_dir/$ac_word" break fi fi done IFS="$ac_save_ifs" test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" ;; esac fi MSGFMT="$ac_cv_path_MSGFMT" if test "$MSGFMT" != "no"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5 $as_echo "$MSGFMT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$MSGFMT" != "no"; then glib_save_LIBS="$LIBS" LIBS="$LIBS $INTLLIBS" for ac_func in dcgettext do : ac_fn_c_check_func "$LINENO" "dcgettext" "ac_cv_func_dcgettext" if test "x$ac_cv_func_dcgettext" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_DCGETTEXT 1 _ACEOF fi done MSGFMT_OPTS= { $as_echo "$as_me:${as_lineno-$LINENO}: checking if msgfmt accepts -c" >&5 $as_echo_n "checking if msgfmt accepts -c... " >&6; } cat >conftest.foo <<_ACEOF msgid "" msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Project-Id-Version: test 1.0\n" "PO-Revision-Date: 2007-02-15 12:01+0100\n" "Last-Translator: test \n" "Language-Team: C \n" "MIME-Version: 1.0\n" "Content-Transfer-Encoding: 8bit\n" _ACEOF if { { $as_echo "$as_me:${as_lineno-$LINENO}: \$MSGFMT -c -o /dev/null conftest.foo"; } >&5 ($MSGFMT -c -o /dev/null conftest.foo) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then MSGFMT_OPTS=-c; { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } echo "$as_me: failed input was:" >&5 sed 's/^/| /' conftest.foo >&5 fi # Extract the first word of "gmsgfmt", so it can be a program name with args. set dummy gmsgfmt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_GMSGFMT+:} false; then : $as_echo_n "(cached) " >&6 else case $GMSGFMT in [\\/]* | ?:[\\/]*) ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ;; esac fi GMSGFMT=$ac_cv_path_GMSGFMT if test -n "$GMSGFMT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5 $as_echo "$GMSGFMT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi # Extract the first word of "xgettext", so it can be a program name with args. set dummy xgettext; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_XGETTEXT+:} false; then : $as_echo_n "(cached) " >&6 else case "$XGETTEXT" in /*) ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ;; *) IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then ac_cv_path_XGETTEXT="$ac_dir/$ac_word" break fi fi done IFS="$ac_save_ifs" test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ;; esac fi XGETTEXT="$ac_cv_path_XGETTEXT" if test "$XGETTEXT" != ":"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5 $as_echo "$XGETTEXT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { extern int _nl_msg_cat_cntr; return _nl_msg_cat_cntr ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : CATOBJEXT=.gmo DATADIRNAME=share else case $host in *-*-solaris*) ac_fn_c_check_func "$LINENO" "bind_textdomain_codeset" "ac_cv_func_bind_textdomain_codeset" if test "x$ac_cv_func_bind_textdomain_codeset" = xyes; then : CATOBJEXT=.gmo DATADIRNAME=share else CATOBJEXT=.mo DATADIRNAME=lib fi ;; *-*-openbsd*) CATOBJEXT=.mo DATADIRNAME=share ;; *) CATOBJEXT=.mo DATADIRNAME=lib ;; esac fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS="$glib_save_LIBS" INSTOBJEXT=.mo else gt_cv_have_gettext=no fi fi fi if test "$gt_cv_have_gettext" = "yes" ; then $as_echo "#define ENABLE_NLS 1" >>confdefs.h fi if test "$XGETTEXT" != ":"; then if $XGETTEXT --omit-header /dev/null 2> /dev/null; then : ; else { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5 $as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; } XGETTEXT=":" fi fi # We need to process the po/ directory. POSUB=po ac_config_commands="$ac_config_commands default-1" for lang in $ALL_LINGUAS; do GMOFILES="$GMOFILES $lang.gmo" POFILES="$POFILES $lang.po" done if test "$gt_cv_have_gettext" = "yes"; then if test "x$ALL_LINGUAS" = "x"; then LINGUAS= else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5 $as_echo_n "checking for catalogs to be installed... " >&6; } NEW_LINGUAS= for presentlang in $ALL_LINGUAS; do useit=no if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then desiredlanguages="$LINGUAS" else desiredlanguages="$ALL_LINGUAS" fi for desiredlang in $desiredlanguages; do # Use the presentlang catalog if desiredlang is # a. equal to presentlang, or # b. a variant of presentlang (because in this case, # presentlang can be used as a fallback for messages # which are not translated in the desiredlang catalog). case "$desiredlang" in "$presentlang"*) useit=yes;; esac done if test $useit = yes; then NEW_LINGUAS="$NEW_LINGUAS $presentlang" fi done LINGUAS=$NEW_LINGUAS { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5 $as_echo "$LINGUAS" >&6; } fi if test -n "$LINGUAS"; then for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done fi fi MKINSTALLDIRS= if test -n "$ac_aux_dir"; then MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" fi if test -z "$MKINSTALLDIRS"; then MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" fi test -d tool/mlconfig/po || mkdir tool/mlconfig/po if test "x$srcdir" != "x."; then if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then posrcprefix="$srcdir/" else posrcprefix="../../../$srcdir/" fi else posrcprefix="../../../" fi rm -f tool/mlconfig/po/POTFILES sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ < $srcdir/tool/mlconfig/po/POTFILES.in > tool/mlconfig/po/POTFILES MAKE_DIRS2="tool/mlconfig ${MAKE_DIRS2}" OUTPUT_FILES="tool/mlconfig/Makefile ${OUTPUT_FILES}" if test "${MSGFMT}" != "no"; then OUTPUT_FILES="tool/mlconfig/po/Makefile.in ${OUTPUT_FILES}" fi tools_result="$tools_result $tool" if test "$have_gtk4" = "yes" ; then GTK_CFLAGS_FOR_MLCONFIG=$GTK4_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK4_LIBS else GTK_CFLAGS_FOR_MLCONFIG=$GTK_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK_LIBS fi else echo "" echo "** WARNING **" echo " couldn't compile mlconfig since headers/libraries of GTK+ are missing." echo "" fi fi ;; mlterm-menu) if test "${have_gtk}" = "yes" -a "$gui" != "fb" -a "$gui" != "console" ; then MAKE_DIRS2="contrib/tool/mlterm-menu ${MAKE_DIRS2}" OUTPUT_FILES="contrib/tool/mlterm-menu/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" else echo "" echo "** WARNING **" echo " couldn't compile mlterm-menu since headers/libraries of GTK+-2 are missing." echo "" fi ;; mlclient) if test "$ml_cv_is_posix" = "yes" -a "$gui" != "console" ; then MAKE_DIRS2="tool/mlclient ${MAKE_DIRS2}" OUTPUT_FILES="tool/mlclient/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; w3mmlconfig) # Extract the first word of "perl", so it can be a program name with args. set dummy perl; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_PERL+:} false; then : $as_echo_n "(cached) " >&6 else case $PERL in [\\/]* | ?:[\\/]*) ac_cv_path_PERL="$PERL" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_path_PERL" && ac_cv_path_PERL="$PATH" ;; esac fi PERL=$ac_cv_path_PERL if test -n "$PERL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 $as_echo "$PERL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$PERL" = x ; then echo "" echo "** WARNING **" echo " couldn't find perl in PATH environment variable." echo "" PERL="/usr/local/bin/perl" # should be "/usr/bin/env perl"? fi MAKE_DIRS2="tool/w3mmlconfig ${MAKE_DIRS2}" OUTPUT_FILES="tool/w3mmlconfig/Makefile tool/w3mmlconfig/mlconfig.cgi tool/w3mmlconfig/w3mmlconfig ${OUTPUT_FILES}" tools_result="$tools_result $tool" ;; mlcc) if test "$ml_cv_is_posix" = "yes" ; then MAKE_DIRS2="contrib/tool/mlcc ${MAKE_DIRS2}" OUTPUT_FILES="contrib/tool/mlcc/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; mlmenu) if test "$gui" = "xlib" ; then MAKE_DIRS2="tool/mlmenu ${MAKE_DIRS2}" OUTPUT_FILES="tool/mlmenu/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; mlterm-zoom) if test "$gui" = "xlib" ; then MAKE_DIRS2="contrib/tool/mlterm-zoom ${MAKE_DIRS2}" OUTPUT_FILES="contrib/tool/mlterm-zoom/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; mlimgloader) if test "$gui" != "quartz" ; then OUTPUT_FILES="tool/mlimgloader/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/mlimgloader ${MAKE_DIRS2}" tools_result="$tools_result $tool" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : have_gdiplus=yes else have_gdiplus=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test "$have_gdiplus" = "yes" ; then MLIMGLOADER_LIB=gdiplus elif test "$have_gdk_pixbuf2" = "yes" -o "$have_gdk_pixbuf1" = "yes" ; then MLIMGLOADER_LIB=gdk-pixbuf else MLIMGLOADER_LIB=none fi if test "$have_ft" = "yes"; then EMOJI_CFLAGS="-DUSE_FREETYPE_EMOJI $FT_CFLAGS_ORIGINAL" EMOJI_LIBS="$FT_LIBS" fi fi ;; registobmp) if test "$have_sdl2" = "yes"; then SDL_CFLAGS=$SDL2_CFLAGS SDL_LIBS=$SDL2_LIBS else pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SDL" >&5 $as_echo_n "checking for SDL... " >&6; } if test -n "$SDL_CFLAGS"; then pkg_cv_SDL_CFLAGS="$SDL_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sdl2\""; } >&5 ($PKG_CONFIG --exists --print-errors "sdl2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDL_CFLAGS=`$PKG_CONFIG --cflags "sdl2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$SDL_LIBS"; then pkg_cv_SDL_LIBS="$SDL_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sdl2\""; } >&5 ($PKG_CONFIG --exists --print-errors "sdl2") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDL_LIBS=`$PKG_CONFIG --libs "sdl2" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then SDL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "sdl2" 2>&1` else SDL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "sdl2" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$SDL_PKG_ERRORS" >&5 have_sdl2=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_sdl2=no else SDL_CFLAGS=$pkg_cv_SDL_CFLAGS SDL_LIBS=$pkg_cv_SDL_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_sdl2=yes fi if test "$have_sdl2" != "yes" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SDL" >&5 $as_echo_n "checking for SDL... " >&6; } if test -n "$SDL_CFLAGS"; then pkg_cv_SDL_CFLAGS="$SDL_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sdl\""; } >&5 ($PKG_CONFIG --exists --print-errors "sdl") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDL_CFLAGS=`$PKG_CONFIG --cflags "sdl" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$SDL_LIBS"; then pkg_cv_SDL_LIBS="$SDL_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sdl\""; } >&5 ($PKG_CONFIG --exists --print-errors "sdl") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDL_LIBS=`$PKG_CONFIG --libs "sdl" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then SDL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "sdl" 2>&1` else SDL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "sdl" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$SDL_PKG_ERRORS" >&5 have_sdl=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_sdl=no else SDL_CFLAGS=$pkg_cv_SDL_CFLAGS SDL_LIBS=$pkg_cv_SDL_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_sdl=yes fi fi fi if test "$have_sdl2" = "yes"; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SDLTTF" >&5 $as_echo_n "checking for SDLTTF... " >&6; } if test -n "$SDLTTF_CFLAGS"; then pkg_cv_SDLTTF_CFLAGS="$SDLTTF_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"SDL2_ttf\""; } >&5 ($PKG_CONFIG --exists --print-errors "SDL2_ttf") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDLTTF_CFLAGS=`$PKG_CONFIG --cflags "SDL2_ttf" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$SDLTTF_LIBS"; then pkg_cv_SDLTTF_LIBS="$SDLTTF_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"SDL2_ttf\""; } >&5 ($PKG_CONFIG --exists --print-errors "SDL2_ttf") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDLTTF_LIBS=`$PKG_CONFIG --libs "SDL2_ttf" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then SDLTTF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "SDL2_ttf" 2>&1` else SDLTTF_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "SDL2_ttf" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$SDLTTF_PKG_ERRORS" >&5 have_sdlttf=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_sdlttf=no else SDLTTF_CFLAGS=$pkg_cv_SDLTTF_CFLAGS SDLTTF_LIBS=$pkg_cv_SDLTTF_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_sdlttf=yes fi elif test "$have_sdl" = "yes"; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SDLTTF" >&5 $as_echo_n "checking for SDLTTF... " >&6; } if test -n "$SDLTTF_CFLAGS"; then pkg_cv_SDLTTF_CFLAGS="$SDLTTF_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"SDL_ttf\""; } >&5 ($PKG_CONFIG --exists --print-errors "SDL_ttf") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDLTTF_CFLAGS=`$PKG_CONFIG --cflags "SDL_ttf" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$SDLTTF_LIBS"; then pkg_cv_SDLTTF_LIBS="$SDLTTF_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"SDL_ttf\""; } >&5 ($PKG_CONFIG --exists --print-errors "SDL_ttf") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SDLTTF_LIBS=`$PKG_CONFIG --libs "SDL_ttf" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then SDLTTF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "SDL_ttf" 2>&1` else SDLTTF_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "SDL_ttf" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$SDLTTF_PKG_ERRORS" >&5 have_sdlttf=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_sdlttf=no else SDLTTF_CFLAGS=$pkg_cv_SDLTTF_CFLAGS SDLTTF_LIBS=$pkg_cv_SDLTTF_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_sdlttf=yes fi else continue fi if test "$have_sdlttf" = "yes"; then SDLTTF_CFLAGS="$SDLTTF_CFLAGS -DUSE_SDLTTF" fi SDL_CFLAGS="$SDL_CFLAGS $SDLTTF_CFLAGS" SDL_LIBS="$SDL_LIBS $SDLTTF_LIBS" OUTPUT_FILES="tool/registobmp/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/registobmp ${MAKE_DIRS2}" tools_result="$tools_result $tool" ;; mlfc) if test "$gui" != "win32" -a "$gui" != "quartz" ; then if test "$have_fc" = "yes" ; then OUTPUT_FILES="tool/mlfc/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/mlfc ${MAKE_DIRS2}" tools_result="$tools_result $tool" fi fi ;; *) echo "${tool} is unknown tool." ;; esac done if test "$gui" = "win32"; then OUTPUT_FILES="tool/servman/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/servman ${MAKE_DIRS2}" tools_result="$tools_result servman" fi # # --- libltdl --- # # Check whether --with-libltdl was given. if test "${with_libltdl+set}" = set; then : withval=$with_libltdl; else with_libltdl=no fi # We don't check here wheter libltdl is installed. (See pobl/src/configure.in) # # --- Xdnd --- # # Check whether --enable-dnd was given. if test "${enable_dnd+set}" = set; then : enableval=$enable_dnd; dnd=$enable_dnd else dnd="yes" fi if test "$dnd" = "no" ; then DND_CFLAGS="-DDISABLE_XDND" fi DL_LIBS_IM="" # # --- kbd --- # # Check whether --enable-kbd was given. if test "${enable_kbd+set}" = set; then : enableval=$enable_kbd; kbd=$enable_kbd fi if test "$enable_shared" = "no" ; then kbd="no" fi if test "$kbd" != "no" ; then MAKE_DIRS2="inputmethod/kbd ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/kbd/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/kbd/libim-kbd.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result kbd" fi # # --- uim --- # # Check whether --enable-uim was given. if test "${enable_uim+set}" = set; then : enableval=$enable_uim; uim=$enable_uim fi if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then uim="no" fi if test "x$uim" != xno ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UIM" >&5 $as_echo_n "checking for UIM... " >&6; } if test -n "$UIM_CFLAGS"; then pkg_cv_UIM_CFLAGS="$UIM_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"uim >= 1.0.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "uim >= 1.0.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_UIM_CFLAGS=`$PKG_CONFIG --cflags "uim >= 1.0.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$UIM_LIBS"; then pkg_cv_UIM_LIBS="$UIM_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"uim >= 1.0.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "uim >= 1.0.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_UIM_LIBS=`$PKG_CONFIG --libs "uim >= 1.0.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then UIM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "uim >= 1.0.0" 2>&1` else UIM_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "uim >= 1.0.0" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$UIM_PKG_ERRORS" >&5 have_uim=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_uim=no else UIM_CFLAGS=$pkg_cv_UIM_CFLAGS UIM_LIBS=$pkg_cv_UIM_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_uim=yes fi if test "x$have_uim" = xyes ; then MAKE_DIRS2="inputmethod/uim ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/uim/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/uim/libim-uim.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result uim" fi fi # # --- IIIMF --- # # Check whether --enable-iiimf was given. if test "${enable_iiimf+set}" = set; then : enableval=$enable_iiimf; iiimf=$enable_iiimf fi if test "x$iiimf" != xno ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IIIMCF" >&5 $as_echo_n "checking for IIIMCF... " >&6; } if test -n "$IIIMCF_CFLAGS"; then pkg_cv_IIIMCF_CFLAGS="$IIIMCF_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"iiimf-lib-client\""; } >&5 ($PKG_CONFIG --exists --print-errors "iiimf-lib-client") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_IIIMCF_CFLAGS=`$PKG_CONFIG --cflags "iiimf-lib-client" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$IIIMCF_LIBS"; then pkg_cv_IIIMCF_LIBS="$IIIMCF_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"iiimf-lib-client\""; } >&5 ($PKG_CONFIG --exists --print-errors "iiimf-lib-client") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_IIIMCF_LIBS=`$PKG_CONFIG --libs "iiimf-lib-client" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then IIIMCF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "iiimf-lib-client" 2>&1` else IIIMCF_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "iiimf-lib-client" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$IIIMCF_PKG_ERRORS" >&5 have_iiimcf=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } have_iiimcf=no else IIIMCF_CFLAGS=$pkg_cv_IIIMCF_CFLAGS IIIMCF_LIBS=$pkg_cv_IIIMCF_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } have_iiimcf=yes fi if test "x$have_iiimcf" = xyes ; then found_iiimcf=yes elif test -d /usr/lib/im/lib ; then LIBS="$LIBS -L/usr/lib/im/lib" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iiimcf_create_context in -liiimcf" >&5 $as_echo_n "checking for iiimcf_create_context in -liiimcf... " >&6; } if ${ac_cv_lib_iiimcf_iiimcf_create_context+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-liiimcf $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char iiimcf_create_context (); int main () { return iiimcf_create_context (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_iiimcf_iiimcf_create_context=yes else ac_cv_lib_iiimcf_iiimcf_create_context=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iiimcf_iiimcf_create_context" >&5 $as_echo "$ac_cv_lib_iiimcf_iiimcf_create_context" >&6; } if test "x$ac_cv_lib_iiimcf_iiimcf_create_context" = xyes; then : found_iiimcf=yes IIIMCF_CFLAGS="-I/usr/lib/im/include" IIIMCF_LIBS="-L/usr/lib/im/lib -liiimcf" fi else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iiimcf_create_context in -liiimcf" >&5 $as_echo_n "checking for iiimcf_create_context in -liiimcf... " >&6; } if ${ac_cv_lib_iiimcf_iiimcf_create_context+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-liiimcf $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char iiimcf_create_context (); int main () { return iiimcf_create_context (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_iiimcf_iiimcf_create_context=yes else ac_cv_lib_iiimcf_iiimcf_create_context=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iiimcf_iiimcf_create_context" >&5 $as_echo "$ac_cv_lib_iiimcf_iiimcf_create_context" >&6; } if test "x$ac_cv_lib_iiimcf_iiimcf_create_context" = xyes; then : found_iiimcf=yes IIIMCF_CFLAGS="-I/usr/include/iiim" IIIMCF_LIBS="-liiimcf" fi fi if test "x$found_iiimcf" = xyes ; then IM_CFLAGS="$IM_CFLAGS -DUSE_IIIMF" MAKE_DIRS2="inputmethod/iiimf ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/iiimf/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then echo "" echo "** ERROR **" echo " IIIMF plugin couldn't be used with libltdl." echo "" exit 1 else input_methods_result="$input_methods_result IIIMF" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iiimcf_create_hotkey_notify_event in -liiimcf" >&5 $as_echo_n "checking for iiimcf_create_hotkey_notify_event in -liiimcf... " >&6; } if ${ac_cv_lib_iiimcf_iiimcf_create_hotkey_notify_event+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-liiimcf $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char iiimcf_create_hotkey_notify_event (); int main () { return iiimcf_create_hotkey_notify_event (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_iiimcf_iiimcf_create_hotkey_notify_event=yes else ac_cv_lib_iiimcf_iiimcf_create_hotkey_notify_event=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iiimcf_iiimcf_create_hotkey_notify_event" >&5 $as_echo "$ac_cv_lib_iiimcf_iiimcf_create_hotkey_notify_event" >&6; } if test "x$ac_cv_lib_iiimcf_iiimcf_create_hotkey_notify_event" = xyes; then : IIIMCF_CFLAGS="$IIIMCF_CFLAGS -DHAVE_HOTKEY_NOTFY_EVENT" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iiimcf_create_aux_getvalues_event in -liiimcf" >&5 $as_echo_n "checking for iiimcf_create_aux_getvalues_event in -liiimcf... " >&6; } if ${ac_cv_lib_iiimcf_iiimcf_create_aux_getvalues_event+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-liiimcf $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char iiimcf_create_aux_getvalues_event (); int main () { return iiimcf_create_aux_getvalues_event (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_iiimcf_iiimcf_create_aux_getvalues_event=yes else ac_cv_lib_iiimcf_iiimcf_create_aux_getvalues_event=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iiimcf_iiimcf_create_aux_getvalues_event" >&5 $as_echo "$ac_cv_lib_iiimcf_iiimcf_create_aux_getvalues_event" >&6; } if test "x$ac_cv_lib_iiimcf_iiimcf_create_aux_getvalues_event" = xyes; then : IIIMCF_CFLAGS="$IIIMCF_CFLAGS -DHAVE_AUX_GETVALUES_EVENT" fi fi fi # # --- m17n library --- # # Check whether --enable-m17nlib was given. if test "${enable_m17nlib+set}" = set; then : enableval=$enable_m17nlib; m17nlib=$enable_m17nlib fi if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then m17nlib="no" fi if test "x$m17nlib" != xno ; then # Extract the first word of "m17n-config", so it can be a program name with args. set dummy m17n-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_m17n_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$m17n_config"; then ac_cv_prog_m17n_config="$m17n_config" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_m17n_config="yes" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_prog_m17n_config" && ac_cv_prog_m17n_config="no" fi fi m17n_config=$ac_cv_prog_m17n_config if test -n "$m17n_config"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $m17n_config" >&5 $as_echo "$m17n_config" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "$m17n_config" = "yes"; then M17NLIB_LIBS=`m17n-config --libs` M18NLIB_CFLAGS=`m17n-config --cflags` m17nlib=yes else pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for M17NLIB" >&5 $as_echo_n "checking for M17NLIB... " >&6; } if test -n "$M17NLIB_CFLAGS"; then pkg_cv_M17NLIB_CFLAGS="$M17NLIB_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"m17n-shell\""; } >&5 ($PKG_CONFIG --exists --print-errors "m17n-shell") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_M17NLIB_CFLAGS=`$PKG_CONFIG --cflags "m17n-shell" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$M17NLIB_LIBS"; then pkg_cv_M17NLIB_LIBS="$M17NLIB_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"m17n-shell\""; } >&5 ($PKG_CONFIG --exists --print-errors "m17n-shell") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_M17NLIB_LIBS=`$PKG_CONFIG --libs "m17n-shell" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then M17NLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "m17n-shell" 2>&1` else M17NLIB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "m17n-shell" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$M17NLIB_PKG_ERRORS" >&5 m17nlib=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } m17nlib=no else M17NLIB_CFLAGS=$pkg_cv_M17NLIB_CFLAGS M17NLIB_LIBS=$pkg_cv_M17NLIB_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } m17nlib=yes fi fi if test "$m17nlib" = "yes"; then m17n_saved_libs="$LIBS" LIBS="$LIBS $M17NLIB_LIBS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for minput_open_im in -lm17n" >&5 $as_echo_n "checking for minput_open_im in -lm17n... " >&6; } if ${ac_cv_lib_m17n_minput_open_im+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm17n $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char minput_open_im (); int main () { return minput_open_im (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_m17n_minput_open_im=yes else ac_cv_lib_m17n_minput_open_im=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m17n_minput_open_im" >&5 $as_echo "$ac_cv_lib_m17n_minput_open_im" >&6; } if test "x$ac_cv_lib_m17n_minput_open_im" = xyes; then : MAKE_DIRS2="inputmethod/m17nlib ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/m17nlib/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/m17nlib/libim-m17nlib.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result m17nlib" fi LIBS="$m17n_saved_libs" fi fi # # --- IBUS --- # # Check whether --enable-ibus was given. if test "${enable_ibus+set}" = set; then : enableval=$enable_ibus; ibus=$enable_ibus fi if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then ibus="no" fi if test "x$ibus" != "xno" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IBUS" >&5 $as_echo_n "checking for IBUS... " >&6; } if test -n "$IBUS_CFLAGS"; then pkg_cv_IBUS_CFLAGS="$IBUS_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ibus-1.0 >= 1.3.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "ibus-1.0 >= 1.3.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_IBUS_CFLAGS=`$PKG_CONFIG --cflags "ibus-1.0 >= 1.3.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$IBUS_LIBS"; then pkg_cv_IBUS_LIBS="$IBUS_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ibus-1.0 >= 1.3.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "ibus-1.0 >= 1.3.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_IBUS_LIBS=`$PKG_CONFIG --libs "ibus-1.0 >= 1.3.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then IBUS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "ibus-1.0 >= 1.3.0" 2>&1` else IBUS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "ibus-1.0 >= 1.3.0" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$IBUS_PKG_ERRORS" >&5 has_ibus=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } has_ibus=no else IBUS_CFLAGS=$pkg_cv_IBUS_CFLAGS IBUS_LIBS=$pkg_cv_IBUS_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } has_ibus=yes fi if test "x$has_ibus" = xyes ; then MAKE_DIRS2="inputmethod/ibus ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/ibus/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/ibus/libim-ibus.la ${DL_LIBS_IM}" fi if test "$with_pthread" != "no" ; then # NetBSD doesn't allow shared libraries to link libpthread # without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi input_methods_result="$input_methods_result iBus" fi fi # # --- FCITX --- # # Check whether --enable-fcitx was given. if test "${enable_fcitx+set}" = set; then : enableval=$enable_fcitx; fcitx=$enable_fcitx fi if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then fcitx="no" fi if test "x$fcitx" != "xno" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FCITX" >&5 $as_echo_n "checking for FCITX... " >&6; } if test -n "$FCITX_CFLAGS"; then pkg_cv_FCITX_CFLAGS="$FCITX_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Fcitx5GClient\""; } >&5 ($PKG_CONFIG --exists --print-errors "Fcitx5GClient") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FCITX_CFLAGS=`$PKG_CONFIG --cflags "Fcitx5GClient" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$FCITX_LIBS"; then pkg_cv_FCITX_LIBS="$FCITX_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Fcitx5GClient\""; } >&5 ($PKG_CONFIG --exists --print-errors "Fcitx5GClient") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FCITX_LIBS=`$PKG_CONFIG --libs "Fcitx5GClient" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then FCITX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "Fcitx5GClient" 2>&1` else FCITX_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "Fcitx5GClient" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$FCITX_PKG_ERRORS" >&5 has_fcitx=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } has_fcitx=no else FCITX_CFLAGS=$pkg_cv_FCITX_CFLAGS FCITX_LIBS=$pkg_cv_FCITX_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } has_fcitx=yes fi if test "x$has_fcitx" = xyes ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FCITXUTILS" >&5 $as_echo_n "checking for FCITXUTILS... " >&6; } if test -n "$FCITXUTILS_CFLAGS"; then pkg_cv_FCITXUTILS_CFLAGS="$FCITXUTILS_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Fcitx5Utils\""; } >&5 ($PKG_CONFIG --exists --print-errors "Fcitx5Utils") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FCITXUTILS_CFLAGS=`$PKG_CONFIG --cflags "Fcitx5Utils" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$FCITXUTILS_LIBS"; then pkg_cv_FCITXUTILS_LIBS="$FCITXUTILS_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"Fcitx5Utils\""; } >&5 ($PKG_CONFIG --exists --print-errors "Fcitx5Utils") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FCITXUTILS_LIBS=`$PKG_CONFIG --libs "Fcitx5Utils" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then FCITXUTILS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "Fcitx5Utils" 2>&1` else FCITXUTILS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "Fcitx5Utils" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$FCITXUTILS_PKG_ERRORS" >&5 has_fcitx=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } has_fcitx=no else FCITXUTILS_CFLAGS=$pkg_cv_FCITXUTILS_CFLAGS FCITXUTILS_LIBS=$pkg_cv_FCITXUTILS_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } has_fcitx=yes fi fi fcitx_result="fcitx" if test "x$has_fcitx" = xno ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FCITX" >&5 $as_echo_n "checking for FCITX... " >&6; } if test -n "$FCITX_CFLAGS"; then pkg_cv_FCITX_CFLAGS="$FCITX_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fcitx-gclient\""; } >&5 ($PKG_CONFIG --exists --print-errors "fcitx-gclient") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FCITX_CFLAGS=`$PKG_CONFIG --cflags "fcitx-gclient" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$FCITX_LIBS"; then pkg_cv_FCITX_LIBS="$FCITX_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fcitx-gclient\""; } >&5 ($PKG_CONFIG --exists --print-errors "fcitx-gclient") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_FCITX_LIBS=`$PKG_CONFIG --libs "fcitx-gclient" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then FCITX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "fcitx-gclient" 2>&1` else FCITX_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "fcitx-gclient" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$FCITX_PKG_ERRORS" >&5 has_fcitx=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } has_fcitx=no else FCITX_CFLAGS=$pkg_cv_FCITX_CFLAGS FCITX_LIBS=$pkg_cv_FCITX_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } has_fcitx=yes fi else FCITX_CFLAGS="$FCITX_CFLAGS $FCITXUTILS_CFLAGS -DUSE_FCITX5" # 'pkg-config Fcitx5GClient --libs' doesn't output -lFcitx5GClient # (fcitx5-gtk-5.0.6 on archlinux) # fcitx5-gtk-5.0.7 fixed it. if test "`echo $FCITX_LIBS|grep lFcitx5GClient`" = ""; then FCITX_LIBS="$FCITX_LIBS -lFcitx5GClient" fi fcitx_result="fcitx5" fi if test "x$has_fcitx" = xyes ; then MAKE_DIRS2="inputmethod/fcitx ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/fcitx/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/fcitx/libim-fcitx.la ${DL_LIBS_IM}" fi if test "$with_pthread" != "no" ; then # NetBSD doesn't allow shared libraries to link libpthread # without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi input_methods_result="$input_methods_result $fcitx_result" fi fi # # --- SCIM --- # # Check whether --enable-scim was given. if test "${enable_scim+set}" = set; then : enableval=$enable_scim; scim=$enable_scim fi if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then scim="no" fi if test "x$scim" != "xno" -a "$gui" != "fb" -a "$gui" != "console" ; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SCIM" >&5 $as_echo_n "checking for SCIM... " >&6; } if test -n "$SCIM_CFLAGS"; then pkg_cv_SCIM_CFLAGS="$SCIM_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"scim >= 1.4.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "scim >= 1.4.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SCIM_CFLAGS=`$PKG_CONFIG --cflags "scim >= 1.4.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$SCIM_LIBS"; then pkg_cv_SCIM_LIBS="$SCIM_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"scim >= 1.4.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "scim >= 1.4.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_SCIM_LIBS=`$PKG_CONFIG --libs "scim >= 1.4.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then SCIM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "scim >= 1.4.0" 2>&1` else SCIM_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "scim >= 1.4.0" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$SCIM_PKG_ERRORS" >&5 has_scim=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } has_scim=no else SCIM_CFLAGS=$pkg_cv_SCIM_CFLAGS SCIM_LIBS=$pkg_cv_SCIM_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } has_scim=yes fi if test "x$has_scim" = xyes ; then MAKE_DIRS2="inputmethod/scim ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/scim/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/scim/libim-scim.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result SCIM" fi fi # # --- CANNA --- # # Check whether --enable-canna was given. if test "${enable_canna+set}" = set; then : enableval=$enable_canna; canna=$enable_canna fi if test "$enable_shared" = "no" -o "$ml_cv_is_posix" = "no" ; then canna="no" fi if test "x$canna" != "xno" ; then ac_fn_c_check_header_mongrel "$LINENO" "canna/jrkanji.h" "ac_cv_header_canna_jrkanji_h" "$ac_includes_default" if test "x$ac_cv_header_canna_jrkanji_h" = xyes; then : has_canna=yes else has_canna=no fi if test "x$has_canna" = xyes ; then CANNA_LIBS="-lcanna" MAKE_DIRS2="inputmethod/canna ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/canna/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/canna/libim-canna.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result canna" fi fi # # --- WNN --- # # Check whether --enable-wnn was given. if test "${enable_wnn+set}" = set; then : enableval=$enable_wnn; wnn=$enable_wnn fi if test "$enable_shared" = "no" -o "$ml_cv_is_posix" = "no" ; then wnn="no" fi if test "x$wnn" != "xno" ; then ac_fn_c_check_header_mongrel "$LINENO" "wnn/jllib.h" "ac_cv_header_wnn_jllib_h" "$ac_includes_default" if test "x$ac_cv_header_wnn_jllib_h" = xyes; then : has_wnn=yes else has_wnn=no fi if test "x$has_wnn" = xyes ; then WNN_LIBS="-ljd" if test -d /usr/pkg/share/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/pkg/share\\\"" elif test -d /usr/local/share/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/local/share\\\"" elif test -d /usr/local/lib/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/local/lib\\\"" elif test -d /usr/share/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/share\\\"" else WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/lib\\\"" fi MAKE_DIRS2="inputmethod/wnn ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/wnn/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/wnn/libim-wnn.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result wnn" fi fi # # --- SKK --- # # Check whether --enable-skk was given. if test "${enable_skk+set}" = set; then : enableval=$enable_skk; skk=$enable_skk fi if test "$enable_shared" != "no" -a "$skk" != "no"; then MAKE_DIRS2="inputmethod/skk ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/skk/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/skk/libim-skk.la ${DL_LIBS_IM}" fi if test "$ml_cv_is_posix" = "no" ; then SKK_LIBS="-lwsock32 -lws2_32" fi input_methods_result="$input_methods_result skk" fi if test "x$input_methods_result" != x ; then IM_CFLAGS="-DUSE_IM_PLUGIN" fi # # --- scrollbar plugins --- # DL_LIBS_SB="" SB_CFLAGS="" scrollbars="sample,extra,pixmap_engine" # Check whether --with-scrollbars was given. if test "${with_scrollbars+set}" = set; then : withval=$with_scrollbars; # If given --without-scrollbars or --with-scrollbars with no args. if test "${with_scrollbars}" = "no" ; then scrollbars="" elif test "${with_scrollbars}" != "yes" ; then scrollbars=${with_scrollbars} fi fi if test "$enable_shared" != "no" ; then scrollbars=`echo ${scrollbars} | sed 's/,/ /g'` else scrollbars= fi for scrollbar in ${scrollbars} ; do case ${scrollbar} in sample) if test "$gui" = "xlib" -o "$gui" = "win32"; then MAKE_DIRS2="scrollbar/sample ${MAKE_DIRS2}" OUTPUT_FILES="scrollbar/sample/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then DL_LIBS_SB="-dlopen \$(top_builddir)/scrollbar/sample/libsample.la ${DL_LIBS_SB}" fi scrollbars_result="$scrollbars_result $scrollbar" fi ;; extra) if test "$gui" = "xlib" ; then MAKE_DIRS2="contrib/scrollbar/extra ${MAKE_DIRS2}" OUTPUT_FILES="contrib/scrollbar/extra/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then for name in athena next motif mozmodern ; do DL_LIBS_SB="-dlopen \$(top_builddir)/contrib/scrollbar/extra/lib$name.la ${DL_LIBS_SB}" done fi scrollbars_result="$scrollbars_result $scrollbar" fi ;; pixmap_engine) if test "x$allow_undefined_flag" = "xunsupported" ; then echo "" echo "** ERROR **" echo "pixmap_engine has undefined symbols. $host_os does NOT allow it." echo "" elif test "$gui" = "xlib" -a "$image" != "no"; then if test "$have_gdk_pixbuf1" = "yes" -o "$have_gdk_pixbuf2" = "yes" ; then MAKE_DIRS2="contrib/scrollbar/pixmap_engine ${MAKE_DIRS2}" OUTPUT_FILES="contrib/scrollbar/pixmap_engine/Makefile contrib/scrollbar/pixmap_engine/sample3/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then DL_LIBS_SB="-dlopen \$(top_builddir)/contrib/scrollbar/pixmap_engine/libpixmap_engine.la ${DL_LIBS_SB}" fi SB_CFLAGS="-DSUPPORT_PIXMAP_ENGINE" scrollbars_result="$scrollbars_result $scrollbar" else echo "" echo "** ERROR **" echo "To use pixmap_engine for scrollbar, you need gdk-pixbuf library." echo "" fi fi ;; *) echo "${scrollbar} is unknown scrollbar." ;; esac done # for scrollbar in ${scrollbars} # # --- module related stuffs --- # # undefined symbol { $as_echo "$as_me:${as_lineno-$LINENO}: checking for undefined symbol" >&5 $as_echo_n "checking for undefined symbol... " >&6; } if test "x$allow_undefined_flag" = "xunsupported" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: not supported" >&5 $as_echo "not supported" >&6; } NO_UNDEFINED_FLAG="-no-undefined" else { $as_echo "$as_me:${as_lineno-$LINENO}: result: supported" >&5 $as_echo "supported" >&6; } NO_UNDEFINED_FLAG="" fi if test "x$with_libltdl" != "xno" ; then DL_SELF="-dlopen self" fi # Check whether --enable-vt52 was given. if test "${enable_vt52+set}" = set; then : enableval=$enable_vt52; vt52=$enable_vt52 else vt52="no" fi if test "$vt52" = "yes" ; then VT52_CFLAGS="-DUSE_VT52" fi # Check whether --enable-optimize_redrawing was given. if test "${enable_optimize_redrawing+set}" = set; then : enableval=$enable_optimize_redrawing; optimize_redrawing=$enable_optimize_redrawing else optimize_redrawing="no" fi if test "$optimize_redrawing" = "yes" ; then CFLAGS="$CFLAGS -DOPTIMIZE_REDRAWING" fi # XXX(maybe not portable) if test "${USE_NLS}" = "yes" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettext in -lintl" >&5 $as_echo_n "checking for gettext in -lintl... " >&6; } if ${ac_cv_lib_intl_gettext+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char gettext (); int main () { return gettext (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_gettext=yes else ac_cv_lib_intl_gettext=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_gettext" >&5 $as_echo "$ac_cv_lib_intl_gettext" >&6; } if test "x$ac_cv_lib_intl_gettext" = xyes; then : INTL_LIBS="-lintl" fi fi # Because pic object files are fat, non-pic ones are linked unless --disable-static # option is specified. if test "$enable_static" = "no" ; then MAIN_OBJ_SUFFIX=":.o=.lo" fi CHANGE_DATE=`head -n 1 ${top_srcdir-$srcdir}/ChangeLog | sed -n 's/^\([0-9]*-[0-9]*-[0-9]*\).*$/\1/p'` OUTPUT_FILES="main/version.h ${OUTPUT_FILES}" if test "${SUBDIRS}" != "" ; then # for baselib and encodefilter ac_configure_args="${ac_configure_args} --without-funcs-mlterm-unuse" # for gui ac_configure_args=`echo ${ac_configure_args} | sed 's/--with-gui=[A-Za-z0-9,]*/--with-gui=subdir/g'` if test "$dl_ctl" != "no"; then ac_configure_args="${ac_configure_args} --disable-ind --disable-fribidi" fi ac_configure_args="${ac_configure_args} --without-tools" subdirs="$subdirs ${SUBDIRS}" fi MAKE_DIRS2="vtemu vtemu/libctl uitoolkit/libtype uitoolkit main man etc ${MAKE_DIRS2}" OUTPUT_FILES="Makefile vtemu/Makefile vtemu/libctl/Makefile uitoolkit/libtype/Makefile uitoolkit/Makefile main/Makefile man/Makefile etc/Makefile java/Makefile libvterm/Makefile ${OUTPUT_FILES}" # Check whether --enable-ind was given. if test "${enable_ind+set}" = set; then : enableval=$enable_ind; ind=$enable_ind else ind="yes" fi if test "$gui" = "quartz" -o "$gui" = "console"; then IND_CFLAGS="-DNOT_CONVERT_TO_ISCII" ind="no" fi if test "$ind" = "yes" ; then IND_CFLAGS='-I${top_builddir}/libind' IND_LIBS='${top_builddir}/libind/libind.a' MAKE_DIRS2="libind ${MAKE_DIRS2}" OUTPUT_FILES="libind/Makefile ${OUTPUT_FILES}" if test "$dl_ctl" = "yes" ; then CTL_LIBS="libctl${TRUECOLOR_TAG}_iscii.la ${CTL_LIBS}" else CTL_CFLAGS="-DUSE_IND ${CTL_CFLAGS}" CTL_LIBS="libctl${TRUECOLOR_TAG}_iscii.a ${CTL_LIBS}" CTL_LIBS_FOR_PROG="../vtemu/libctl/libctl${TRUECOLOR_TAG}_iscii.a ${CTL_LIBS_FOR_PROG}" fi fi # Check whether --enable-brlapi was given. if test "${enable_brlapi+set}" = set; then : enableval=$enable_brlapi; brlapi=$enable_brlapi else brlapi="no" fi if test "$brlapi" = "yes" ; then BRLAPI_CFLAGS='-DUSE_BRLAPI' BRLAPI_LIBS='-lbrlapi' if test "$host_os" != "haiku"; then INSTALL_OPT="-m 4755 -o root" fi fi # Check whether --enable-daemon was given. if test "${enable_daemon+set}" = set; then : enableval=$enable_daemon; daemon=$enable_daemon else daemon="yes" fi if test "$daemon" = "no" ; then DAEMON_CFLAGS="-DNO_DAEMON" fi # Check whether --enable-split was given. if test "${enable_split+set}" = set; then : enableval=$enable_split; split=$enable_split else split="yes" fi if test "$split" = "no" ; then SPLIT_CFLAGS="-DNO_SPLIT" fi # Check whether --enable-zmodem was given. if test "${enable_zmodem+set}" = set; then : enableval=$enable_zmodem; zmodem=$enable_zmodem else zmodem="yes" fi if test "$zmodem" = "no" ; then TRANSFER_CFLAGS="-DNO_ZMODEM" else TRANSFER_LIBS="libzmodem.la" fi if test "${MAKE_DIRS2}" != "" ; then mkdir -p ${MAKE_DIRS2} fi if test "$CONFIG_SUBDIR_LIBS" = "internal"; then # # ====> check for encodefilter <=== # mef_top_srcdir_suffix="/encodefilter" mef_top_builddir_suffix="/.." # Check whether --with-map-table was given. if test "${with_map_table+set}" = set; then : withval=$with_map_table; map_table=$with_map_table else map_table="yes" fi if test "$map_table" = "no" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DREMOVE_MAPPING_TABLE" fi # Check whether --with-prop-table was given. if test "${with_prop_table+set}" = set; then : withval=$with_prop_table; prop_table=$with_prop_table else prop_table="yes" fi if test "$prop_table" = "no" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DREMOVE_PROPERTY_TABLE" fi # Check whether --with-iconv was given. if test "${with_iconv+set}" = set; then : withval=$with_iconv; iconv=$with_iconv else iconv="no" fi if test "$iconv" = "yes" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DUSE_ICONV" fi # Check whether --enable-dl-table was given. if test "${enable_dl_table+set}" = set; then : enableval=$enable_dl_table; dl_table=$enable_dl_table else if test "$iconv" = "yes"; then dl_table="no" else dl_table="yes" fi fi if test "$enable_shared" = "no" ; then dl_table="no" fi if test "$dl_table" = "no" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DNO_DYNAMIC_LOAD_TABLE" MAKE_DIRS="src" OUTPUT_FILES="${OUTPUT_FILES} encodefilter/Makefile encodefilter/src/Makefile" else MAKE_DIRS="src module" OUTPUT_FILES="${OUTPUT_FILES} encodefilter/Makefile encodefilter/src/Makefile encodefilter/module/Makefile" fi if test "${MAKE_DIRS}" != "" ; then mkdir -p ${MAKE_DIRS} fi # # --- check for undefined symbol --- # if test "x$allow_undefined_flag" = "xunsupported" ; then # link ef_char.lo to module/*.dll to resolve addresses in creating dll. EF_CHAR_LO="../src/ef_char.lo" else EF_CHAR_LO="" fi # # ====> check for baselib <=== # pobl_top_srcdir_suffix="/baselib" pobl_top_builddir_suffix="/.." ac_config_headers="$ac_config_headers baselib/src/bl_config.h" #detect glibc cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { #ifdef __GLIBC__ #else #error int boil\[-1\]; #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : $as_echo "#define HAVE_GNU_SOURCE 1" >>confdefs.h fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext # # --- Checks for header files --- # # NOTE: if --with-libtool is specified, stdc header isn't detected. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi for ac_header in langinfo.h dlfcn.h dl.h stropts.h sys/stropts.h stdint.h windows.h errno.h stdint.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done # # --- Checks for library functions --- # for ac_func in strsep fgetln basename isastream seteuid setegid geteuid getegid setsid snprintf usleep setenv unsetenv flock getuid getgid getpwuid recvmsg setpgid socketpair killpg gettimeofday do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" if test "x$ac_cv_type_size_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define size_t unsigned int _ACEOF fi # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 $as_echo_n "checking for working alloca.h... " >&6; } if ${ac_cv_working_alloca_h+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { char *p = (char *) alloca (2 * sizeof (int)); if (p) return 0; ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_working_alloca_h=yes else ac_cv_working_alloca_h=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 $as_echo "$ac_cv_working_alloca_h" >&6; } if test $ac_cv_working_alloca_h = yes; then $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 $as_echo_n "checking for alloca... " >&6; } if ${ac_cv_func_alloca_works+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __GNUC__ # define alloca __builtin_alloca #else # ifdef _MSC_VER # include # define alloca _alloca # elif defined(__NetBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(__OpenBSD__) # include # else # ifdef HAVE_ALLOCA_H # include # else # ifdef _AIX #pragma alloca # else # ifndef alloca /* predefined by HP cc +Olibcalls */ void *alloca (size_t); # endif # endif # endif # endif #endif int main () { char *p = (char *) alloca (1); if (p) return 0; ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_func_alloca_works=yes else ac_cv_func_alloca_works=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 $as_echo "$ac_cv_func_alloca_works" >&6; } if test $ac_cv_func_alloca_works = yes; then $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h else # The SVR3 libPW and SVR4 libucb both contain incompatible functions # that cause trouble. Some versions do not even contain alloca or # contain a buggy version. If you still want to use their alloca, # use ar to extract alloca.o from them instead of compiling alloca.c. ALLOCA=\${LIBOBJDIR}alloca.$ac_objext $as_echo "#define C_ALLOCA 1" >>confdefs.h { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } if ${ac_cv_os_cray+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined CRAY && ! defined CRAY2 webecray #else wenotbecray #endif _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "webecray" >/dev/null 2>&1; then : ac_cv_os_cray=yes else ac_cv_os_cray=no fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 $as_echo "$ac_cv_os_cray" >&6; } if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define CRAY_STACKSEG_END $ac_func _ACEOF break fi done fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 $as_echo_n "checking stack direction for C alloca... " >&6; } if ${ac_cv_c_stack_direction+:} false; then : $as_echo_n "(cached) " >&6 else if test "$cross_compiling" = yes; then : ac_cv_c_stack_direction=0 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int find_stack_direction (int *addr, int depth) { int dir, dummy = 0; if (! addr) addr = &dummy; *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; dir = depth ? find_stack_direction (addr, depth - 1) : 0; return dir + dummy; } int main (int argc, char **argv) { return find_stack_direction (0, argc + !argv + 20) < 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_c_stack_direction=1 else ac_cv_c_stack_direction=-1 fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 $as_echo "$ac_cv_c_stack_direction" >&6; } cat >>confdefs.h <<_ACEOF #define STACK_DIRECTION $ac_cv_c_stack_direction _ACEOF fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 $as_echo_n "checking for an ANSI C-conforming const... " >&6; } if ${ac_cv_c_const+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __cplusplus /* Ultrix mips cc rejects this sort of thing. */ typedef int charset[2]; const charset cs = { 0, 0 }; /* SunOS 4.1.1 cc rejects this. */ char const *const *pcpcc; char **ppc; /* NEC SVR4.0.2 mips cc rejects this. */ struct point {int x, y;}; static struct point const zero = {0,0}; /* AIX XL C 1.02.0.0 rejects this. It does not let you subtract one const X* pointer from another in an arm of an if-expression whose if-part is not a constant expression */ const char *g = "string"; pcpcc = &g + (g ? g-g : 0); /* HPUX 7.0 cc rejects these. */ ++pcpcc; ppc = (char**) pcpcc; pcpcc = (char const *const *) ppc; { /* SCO 3.2v4 cc rejects this sort of thing. */ char tx; char *t = &tx; char const *s = 0 ? (char *) 0 : (char const *) 0; *t++ = 0; if (s) return 0; } { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ int x[] = {25, 17}; const int *foo = &x[0]; ++foo; } { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ typedef const int *iptr; iptr p = 0; ++p; } { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ struct s { int j; const int *ap[3]; } bx; struct s *b = &bx; b->j = 5; } { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ const int foo = 10; if (!foo) return 0; } return !cs[0] && !zero.x; #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_const=yes else ac_cv_c_const=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 $as_echo "$ac_cv_c_const" >&6; } if test $ac_cv_c_const = no; then $as_echo "#define const /**/" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } if ${ac_cv_c_bigendian+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_bigendian=unknown # See if we're dealing with a universal compiler. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __APPLE_CC__ not a universal capable compiler #endif typedef int dummy; _ACEOF if ac_fn_c_try_compile "$LINENO"; then : # Check for potential -arch flags. It is not universal unless # there are at least two -arch flags with different values. ac_arch= ac_prev= for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do if test -n "$ac_prev"; then case $ac_word in i?86 | x86_64 | ppc | ppc64) if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then ac_arch=$ac_word else ac_cv_c_bigendian=universal break fi ;; esac ac_prev= elif test "x$ac_word" = "x-arch"; then ac_prev=arch fi done fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_c_bigendian = unknown; then # See if sys/param.h defines the BYTE_ORDER macro. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ && LITTLE_ENDIAN) bogus endian macros #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : # It does; now see whether it defined to BIG_ENDIAN or not. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { #if BYTE_ORDER != BIG_ENDIAN not big endian #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_bigendian=yes else ac_cv_c_bigendian=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi if test $ac_cv_c_bigendian = unknown; then # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) bogus endian macros #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : # It does; now see whether it defined to _BIG_ENDIAN or not. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { #ifndef _BIG_ENDIAN not big endian #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_bigendian=yes else ac_cv_c_bigendian=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi if test $ac_cv_c_bigendian = unknown; then # Compile a test program. if test "$cross_compiling" = yes; then : # Try to guess by grepping values from an object file. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; int use_ascii (int i) { return ascii_mm[i] + ascii_ii[i]; } short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; int use_ebcdic (int i) { return ebcdic_mm[i] + ebcdic_ii[i]; } extern int foo; int main () { return use_ascii (foo) == use_ebcdic (foo); ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then ac_cv_c_bigendian=yes fi if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then if test "$ac_cv_c_bigendian" = unknown; then ac_cv_c_bigendian=no else # finding both strings is unlikely to happen, but who knows? ac_cv_c_bigendian=unknown fi fi fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int main () { /* Are we little or big endian? From Harbison&Steele. */ union { long int l; char c[sizeof (long int)]; } u; u.l = 1; return u.c[sizeof (long int) - 1] == 1; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_c_bigendian=no else ac_cv_c_bigendian=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 $as_echo "$ac_cv_c_bigendian" >&6; } case $ac_cv_c_bigendian in #( yes) $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h ;; #( no) ;; #( universal) $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h ;; #( *) as_fn_error $? "unknown endianness presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; esac # Check whether --enable-largefile was given. if test "${enable_largefile+set}" = set; then : enableval=$enable_largefile; fi if test "$enable_largefile" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 $as_echo_n "checking for special C compiler options needed for large files... " >&6; } if ${ac_cv_sys_largefile_CC+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_sys_largefile_CC=no if test "$GCC" != yes; then ac_save_CC=$CC while :; do # IRIX 6.2 and later do not support large files by default, # so use the C compiler's -n32 option if that helps. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : break fi rm -f core conftest.err conftest.$ac_objext CC="$CC -n32" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_largefile_CC=' -n32'; break fi rm -f core conftest.err conftest.$ac_objext break done CC=$ac_save_CC rm -f conftest.$ac_ext fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 $as_echo "$ac_cv_sys_largefile_CC" >&6; } if test "$ac_cv_sys_largefile_CC" != no; then CC=$CC$ac_cv_sys_largefile_CC fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } if ${ac_cv_sys_file_offset_bits+:} false; then : $as_echo_n "(cached) " >&6 else while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_file_offset_bits=no; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _FILE_OFFSET_BITS 64 #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_file_offset_bits=64; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_sys_file_offset_bits=unknown break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 $as_echo "$ac_cv_sys_file_offset_bits" >&6; } case $ac_cv_sys_file_offset_bits in #( no | unknown) ;; *) cat >>confdefs.h <<_ACEOF #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits _ACEOF ;; esac rm -rf conftest* if test $ac_cv_sys_file_offset_bits = unknown; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } if ${ac_cv_sys_large_files+:} false; then : $as_echo_n "(cached) " >&6 else while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_large_files=no; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _LARGE_FILES 1 #include /* Check that off_t can represent 2**63 - 1 correctly. We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_large_files=1; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_sys_large_files=unknown break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 $as_echo "$ac_cv_sys_large_files" >&6; } case $ac_cv_sys_large_files in #( no | unknown) ;; *) cat >>confdefs.h <<_ACEOF #define _LARGE_FILES $ac_cv_sys_large_files _ACEOF ;; esac rm -rf conftest* fi fi # for OpenServer 6.0.0 ac_fn_c_check_header_mongrel "$LINENO" "sys/bitypes.h" "ac_cv_header_sys_bitypes_h" "$ac_includes_default" if test "x$ac_cv_header_sys_bitypes_h" = xyes; then : ac_includes_default="\ $ac_includes_default #include " HAVE_SYS_BITYPES_H=1 $as_echo "#define HAVE_SYS_BITYPES_H 1" >>confdefs.h fi ac_fn_c_check_type "$LINENO" "u_char" "ac_cv_type_u_char" "$ac_includes_default" if test "x$ac_cv_type_u_char" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_char unsigned char _ACEOF fi ac_fn_c_check_type "$LINENO" "u_short" "ac_cv_type_u_short" "$ac_includes_default" if test "x$ac_cv_type_u_short" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_short unsigned short _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int" "ac_cv_type_u_int" "$ac_includes_default" if test "x$ac_cv_type_u_int" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int unsigned int _ACEOF fi ac_fn_c_check_type "$LINENO" "u_long" "ac_cv_type_u_long" "$ac_includes_default" if test "x$ac_cv_type_u_long" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_long unsigned long _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int8_t" "ac_cv_type_u_int8_t" "$ac_includes_default" if test "x$ac_cv_type_u_int8_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int8_t unsigned char _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int16_t" "ac_cv_type_u_int16_t" "$ac_includes_default" if test "x$ac_cv_type_u_int16_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int16_t unsigned short _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" "$ac_includes_default" if test "x$ac_cv_type_u_int32_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int32_t unsigned int _ACEOF fi ac_fn_c_check_type "$LINENO" "u_int64_t" "ac_cv_type_u_int64_t" "$ac_includes_default" if test "x$ac_cv_type_u_int64_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define u_int64_t unsigned long _ACEOF fi ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" if test "x$ac_cv_type_int8_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int8_t char _ACEOF fi ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" if test "x$ac_cv_type_int16_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int16_t short _ACEOF fi ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" if test "x$ac_cv_type_int32_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int32_t int _ACEOF fi ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default" if test "x$ac_cv_type_int64_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define int64_t long _ACEOF fi ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" if test "x$ac_cv_type_ssize_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define ssize_t int _ACEOF fi ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" if test "x$ac_cv_type_mode_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define mode_t int _ACEOF fi ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" if test "x$ac_cv_type_pid_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define pid_t int _ACEOF fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 $as_echo_n "checking for uid_t in sys/types.h... " >&6; } if ${ac_cv_type_uid_t+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "uid_t" >/dev/null 2>&1; then : ac_cv_type_uid_t=yes else ac_cv_type_uid_t=no fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 $as_echo "$ac_cv_type_uid_t" >&6; } if test $ac_cv_type_uid_t = no; then $as_echo "#define uid_t int" >>confdefs.h $as_echo "#define gid_t int" >>confdefs.h fi ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" if test "x$ac_cv_type_off_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define off_t long int _ACEOF fi ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" if test "x$ac_cv_type_size_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define size_t unsigned int _ACEOF fi # # --- Platform dependent stuff --- # bl_cv_cygwin=no bl_cv_mingw=no bl_cv_win32=no case "${host_os}" in cygwin*) bl_cv_cygwin=yes case "${CC} ${CFLAGS}" in *mno-cygwin* | *-mingw*) bl_cv_win32=yes $as_echo "#define USE_WIN32API /**/" >>confdefs.h ;; *) ;; esac ;; mingw*) bl_cv_mingw=yes if test ! -f "/lib/libmsys-1.0.dll.a" ; then case "${lt_cv_path_LD}" in *-msys*) ;; *) bl_cv_win32=yes $as_echo "#define USE_WIN32API /**/" >>confdefs.h ;; esac fi ;; *) ;; esac # # --- socklen_t --- # # NOTE: #define _BSDTYPES_DEFINED is necessary because AC_TRY_COMPILE defines # u_char, u_short and so on before #include . # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5 $as_echo_n "checking for socklen_t... " >&6; } if ${bl_cv_socklen_ident+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include int main () { socklen_t len ; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : bl_cv_socklen_ident=yes else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _BSDTYPES_DEFINED #include int main () { socklen_t len ; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : bl_cv_socklen_ident=yes else bl_cv_socklen_ident=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bl_cv_socklen_ident" >&5 $as_echo "$bl_cv_socklen_ident" >&6; } if test "${bl_cv_socklen_ident}" = "no" ; then $as_echo "#define socklen_t unsigned int" >>confdefs.h fi # # --- Check if concatenation of string literals with __FUNCTION__ is supported. --- # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __FUNCTION__" >&5 $as_echo_n "checking for __FUNCTION__... " >&6; } if ${bl_cv_func_ident+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { char * p = "[" __FUNCTION__ "]" ; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : bl_cv_func_ident=yes else bl_cv_func_ident=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bl_cv_func_ident" >&5 $as_echo "$bl_cv_func_ident" >&6; } if test "${bl_cv_func_ident}" = "yes" ; then $as_echo "#define CONCATABLE_FUNCTION /**/" >>confdefs.h fi # # --- Check for libxpg4 (for FreeBSD) --- # for ac_func in setlocale do : ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale" if test "x$ac_cv_func_setlocale" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SETLOCALE 1 _ACEOF fi done if test "x$ac_cv_func_setlocale" = xno ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setlocale in -lxpg4" >&5 $as_echo_n "checking for setlocale in -lxpg4... " >&6; } if ${ac_cv_lib_xpg4_setlocale+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lxpg4 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char setlocale (); int main () { return setlocale (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_xpg4_setlocale=yes else ac_cv_lib_xpg4_setlocale=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xpg4_setlocale" >&5 $as_echo "$ac_cv_lib_xpg4_setlocale" >&6; } if test "x$ac_cv_lib_xpg4_setlocale" = xyes; then : XPG4_LIBS=-lxpg4 fi fi # # --- Checks for dynamic linking loader --- # DL_LOADER=none DL_LIBS= DL_CFLAGS= # lt_dlopenext in libltdl # Check whether --with-libltdl was given. if test "${with_libltdl+set}" = set; then : withval=$with_libltdl; else with_libltdl=no fi if test "x$with_libltdl" != "xno" ; then if test "x$with_libltdl" != "xyes"; then DL_CFLAGS="-I$with_libltdl/include" bl_libltdl_libdir="-L$with_libltdl/lib" fi bl_ldflags_save="$LDFLAGS" LDFLAGS="$LDFLAGS $bl_libltdl_libdir" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lt_dlopenext in -lltdl" >&5 $as_echo_n "checking for lt_dlopenext in -lltdl... " >&6; } if ${ac_cv_lib_ltdl_lt_dlopenext+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lltdl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char lt_dlopenext (); int main () { return lt_dlopenext (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ltdl_lt_dlopenext=yes else ac_cv_lib_ltdl_lt_dlopenext=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ltdl_lt_dlopenext" >&5 $as_echo "$ac_cv_lib_ltdl_lt_dlopenext" >&6; } if test "x$ac_cv_lib_ltdl_lt_dlopenext" = xyes; then : DL_LOADER=ltdl DL_LIBS="$bl_libltdl_libdir -lltdl" else echo "" echo "Could not find libltdl" echo "" exit 1 fi LDFLAGS="$bl_ldflags_save" fi # lt_cv_dlopen is set by AC_LIBTOOL_DLOPEN if test "$DL_LOADER" = none ; then case "${lt_cv_dlopen}" in # LoadLibrary (Windows) LoadLibrary) DL_LOADER=win32 ;; # shl_load (HP-UX) shl_load) DL_LOADER=dld ;; # dlopen (UNIX98) dlopen) DL_LOADER=dl ;; # What is dld_link? Does anybody know? dld_link) DL_LOADER=none ;; *) DL_LOADER=none ;; esac DL_LIBS="${DL_LIBS} ${lt_cv_dlopen_libs}" if test "$DL_LOADER" = none ; then # NSLinkModule (darwin) ac_fn_c_check_func "$LINENO" "NSLinkModule" "ac_cv_func_NSLinkModule" if test "x$ac_cv_func_NSLinkModule" = xyes; then : DL_LOADER=dyld DL_LIBS= fi fi # cygwin hack # (AC_LIBTOOL_DLOPEN tell lt_cv_dlopen == dlopen but use bl_dlcfn_win32.c.) # On msys2, use dlopen because bl_dlfcn_win32 doesn't work correctly. if test "$bl_cv_cygwin" = "yes"; then DL_LOADER=win32 fi fi if test "$DL_LOADER" = none ; then $as_echo "#define DLFCN_NONE /**/" >>confdefs.h fi # # --- pty check --- # { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pty/tty type" >&5 $as_echo_n "checking for pty/tty type... " >&6; } if test "$bl_cv_win32" = "yes" ; then bl_cv_pty=none elif test "$bl_cv_mingw" = "yes" ; then bl_cv_pty=streams elif test "$host" = "$build" ; then ac_fn_c_check_func "$LINENO" "posix_openpt" "ac_cv_func_posix_openpt" if test "x$ac_cv_func_posix_openpt" = xyes; then : if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run test program while cross compiling See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return posix_openpt(O_RDWR | O_NOCTTY) == -1; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : $as_echo "#define HAVE_POSIX_OPENPT /**/" >>confdefs.h bl_cv_pty=streams else bl_cv_pty=bsd fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi else bl_cv_pty=bsd fi if test "$bl_cv_pty" = "bsd" ; then if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run test program while cross compiling See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { return open( "/dev/ptmx", O_RDWR | O_NOCTTY, 0) == -1; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : bl_cv_pty=streams fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi else # cross compiling ac_fn_c_check_func "$LINENO" "posix_openpt" "ac_cv_func_posix_openpt" if test "x$ac_cv_func_posix_openpt" = xyes; then : $as_echo "#define HAVE_POSIX_OPENPT /**/" >>confdefs.h bl_cv_pty=streams else bl_cv_pty=bsd fi fi # Check whether --enable-pty_helper was given. if test "${enable_pty_helper+set}" = set; then : enableval=$enable_pty_helper; pty_helper=$enable_pty_helper fi if test "$pty_helper" = yes ; then if test "$bl_cv_pty" = streams ; then bl_cv_pty=helper else echo "" echo "** WARNING **" echo " pty helper is not supported in bsd-style pty system." echo "" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bl_cv_pty" >&5 $as_echo "$bl_cv_pty" >&6; } PTY_NAME="${bl_cv_pty}" # # --- checks for utmp --- # # Check whether --with-utmp was given. if test "${with_utmp+set}" = set; then : withval=$with_utmp; utmp_type=$with_utmp fi UTMP_NAME= UTMP_LIBS= if test "$bl_cv_pty" = helper -o "$bl_cv_mingw" = yes -o "$bl_cv_cygwin" = yes -o "$host_os" = "msys" -o "$host_os" = "haiku"; then UTMP_NAME=none UTMP_LIBS= fi # libutempter if test "$utmp_type" = "" -o "$utmp_type" = "utempter"; then if test -z "$UTMP_NAME"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for utempter_add_record in -lutempter" >&5 $as_echo_n "checking for utempter_add_record in -lutempter... " >&6; } if ${ac_cv_lib_utempter_utempter_add_record+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lutempter $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char utempter_add_record (); int main () { return utempter_add_record (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_utempter_utempter_add_record=yes else ac_cv_lib_utempter_utempter_add_record=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_utempter_utempter_add_record" >&5 $as_echo "$ac_cv_lib_utempter_utempter_add_record" >&6; } if test "x$ac_cv_lib_utempter_utempter_add_record" = xyes; then : UTMP_NAME=utmper UTMP_LIBS="-lutempter" UTMP_CFLAGS="-DUTEMPTER_NEW_API" fi fi if test -z "$UTMP_NAME"; then # FreeBSD { $as_echo "$as_me:${as_lineno-$LINENO}: checking for utempter_add_record in -lulog" >&5 $as_echo_n "checking for utempter_add_record in -lulog... " >&6; } if ${ac_cv_lib_ulog_utempter_add_record+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lulog $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char utempter_add_record (); int main () { return utempter_add_record (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ulog_utempter_add_record=yes else ac_cv_lib_ulog_utempter_add_record=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ulog_utempter_add_record" >&5 $as_echo "$ac_cv_lib_ulog_utempter_add_record" >&6; } if test "x$ac_cv_lib_ulog_utempter_add_record" = xyes; then : UTMP_NAME=utmper UTMP_LIBS="-lulog" UTMP_CFLAGS="-DUTEMPTER_NEW_API" fi fi if test -z "$UTMP_NAME" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addToUtmp in -lutempter" >&5 $as_echo_n "checking for addToUtmp in -lutempter... " >&6; } if ${ac_cv_lib_utempter_addToUtmp+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lutempter $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char addToUtmp (); int main () { return addToUtmp (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_utempter_addToUtmp=yes else ac_cv_lib_utempter_addToUtmp=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_utempter_addToUtmp" >&5 $as_echo "$ac_cv_lib_utempter_addToUtmp" >&6; } if test "x$ac_cv_lib_utempter_addToUtmp" = xyes; then : UTMP_NAME=utmper UTMP_LIBS="-lutempter -lutil" fi fi fi # setutxent() (SysV) if test "$utmp_type" = "" -o "$utmp_type" = "sysv"; then if test -z "$UTMP_NAME"; then ac_fn_c_check_func "$LINENO" "setutxent" "ac_cv_func_setutxent" if test "x$ac_cv_func_setutxent" = xyes; then : UTMP_NAME=sysv UTMP_LIBS= UTMP_CFLAGS=-DUSE_UTMPX fi fi # setutent() (SysV) if test -z "$UTMP_NAME"; then ac_fn_c_check_func "$LINENO" "setutent" "ac_cv_func_setutent" if test "x$ac_cv_func_setutent" = xyes; then : UTMP_NAME=sysv UTMP_LIBS= fi fi fi # libutil if test "$utmp_type" = "" -o "$utmp_type" = "login"; then if test -z "$UTMP_NAME" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for logout in -lutil" >&5 $as_echo_n "checking for logout in -lutil... " >&6; } if ${ac_cv_lib_util_logout+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lutil $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char logout (); int main () { return logout (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_util_logout=yes else ac_cv_lib_util_logout=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_logout" >&5 $as_echo "$ac_cv_lib_util_logout" >&6; } if test "x$ac_cv_lib_util_logout" = xyes; then : UTMP_NAME=login UTMP_LIBS=-lutil fi fi fi # other (BSD) if test "$utmp_type" = "" -o "$utmp_type" = "bsd"; then if test -z "$UTMP_NAME" ; then UTMP_NAME=bsd UTMP_LIBS= fi fi if test -z "$UTMP_NAME" ; then UTMP_NAME=none UTMP_LIBS= fi if test "$UTMP_NAME" != "none"; then # for vtemu/vt_pty_unix.c UTMP_CFLAGS="$UTMP_CFLAGS -DUSE_UTMP" fi $as_echo "#define REMOVE_FUNCS_MLTERM_UNUSE /**/" >>confdefs.h # # --- check for malloc --- # if test "$host" = "$build"; then if test "$cross_compiling" = yes; then : { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run test program while cross compiling See \`config.log' for more details" "$LINENO" 5; } else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main() { return calloc(8, ((1 << (sizeof(size_t) * 8 - 1)) + 1)) ? 1 : 0 ; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : $as_echo "#define CALLOC_CHECK_OVERFLOW 1" >>confdefs.h fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi OUTPUT_FILES="${OUTPUT_FILES} baselib/Makefile baselib/src/Makefile" else # CONFIG_SUBDIR_LIBS # ./configure at subdirs finished. if test -d baselib; then utmp_none_obj=`grep bl_utmp_none.o baselib/src/Makefile` elif test -d ../../baselib; then utmp_none_obj=`grep bl_utmp_none.o ../../baselib/src/Makefile` fi if test "$utmp_none_obj" = ""; then UTMP_CFLAGS="-DUSE_UTMP" else # for following "$UTMP_NAME" != "none" UTMP_NAME="none" fi fi # CONFIG_SUBDIR_LIBS ac_config_files="$ac_config_files ${OUTPUT_FILES}" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then if test "x$cache_file" != "x/dev/null"; then { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} if test ! -f "$cache_file" || test -h "$cache_file"; then cat confcache >"$cache_file" else case $cache_file in #( */* | ?:*) mv -f confcache "$cache_file"$$ && mv -f "$cache_file"$$ "$cache_file" ;; #( *) mv -f confcache "$cache_file" ;; esac fi fi else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= U= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`$as_echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs { $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 $as_echo_n "checking that generated files are newer than configure... " >&6; } if test -n "$am_sleep_pid"; then # Hide warnings about reused PIDs. wait $am_sleep_pid 2>/dev/null fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 $as_echo "done" >&6; } if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then as_fn_error $? "conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -n "$EXEEXT"; then am__EXEEXT_TRUE= am__EXEEXT_FALSE='#' else am__EXEEXT_TRUE='#' am__EXEEXT_FALSE= fi : "${CONFIG_STATUS=./config.status}" ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 ## ----------------------------------- ## ## Main body of $CONFIG_STATUS script. ## ## ----------------------------------- ## _ASEOF test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by $as_me, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac case $ac_config_headers in *" "*) set x $ac_config_headers; shift; ac_config_headers=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to the package provider." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ config.status configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" Copyright (C) 2012 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' MKDIR_P='$MKDIR_P' AWK='$AWK' test -n "\$AWK" || AWK=awk _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 do case $1 in --*=?*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; --*=) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg= ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) $as_echo "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) $as_echo "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; '') as_fn_error $? "missing file argument" ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_HEADERS " '$ac_optarg'" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header as_fn_error $? "ambiguous option: \`$1' Try \`$0 --help' for more information.";; --help | --hel | -h ) $as_echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) as_fn_error $? "unrecognized option: \`$1' Try \`$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX $as_echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`' DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`' SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' FILECMD='`$ECHO "$FILECMD" | $SED "$delay_single_quote_subst"`' deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' lt_ar_flags='`$ECHO "$lt_ar_flags" | $SED "$delay_single_quote_subst"`' AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`' nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`' objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`' configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`' hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$1 _LTECHO_EOF' } # Quote evaled strings. for var in AS \ DLLTOOL \ OBJDUMP \ SHELL \ ECHO \ PATH_SEPARATOR \ SED \ GREP \ EGREP \ FGREP \ LD \ NM \ LN_S \ lt_SP2NL \ lt_NL2SP \ reload_flag \ FILECMD \ deplibs_check_method \ file_magic_cmd \ file_magic_glob \ want_nocaseglob \ sharedlib_from_linklib_cmd \ AR \ archiver_list_spec \ STRIP \ RANLIB \ CC \ CFLAGS \ compiler \ lt_cv_sys_global_symbol_pipe \ lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_import \ lt_cv_sys_global_symbol_to_c_name_address \ lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ lt_cv_nm_interface \ nm_file_list_spec \ lt_cv_truncate_bin \ lt_prog_compiler_no_builtin_flag \ lt_prog_compiler_pic \ lt_prog_compiler_wl \ lt_prog_compiler_static \ lt_cv_prog_compiler_c_o \ need_locks \ MANIFEST_TOOL \ DSYMUTIL \ NMEDIT \ LIPO \ OTOOL \ OTOOL64 \ shrext_cmds \ export_dynamic_flag_spec \ whole_archive_flag_spec \ compiler_needs_object \ with_gnu_ld \ allow_undefined_flag \ no_undefined_flag \ hardcode_libdir_flag_spec \ hardcode_libdir_separator \ exclude_expsyms \ include_expsyms \ file_list_spec \ variables_saved_for_relink \ libname_spec \ library_names_spec \ soname_spec \ install_override_mode \ finish_eval \ old_striplib \ striplib \ compiler_lib_search_dirs \ predep_objects \ postdep_objects \ predeps \ postdeps \ compiler_lib_search_path \ LD_CXX \ reload_flag_CXX \ compiler_CXX \ lt_prog_compiler_no_builtin_flag_CXX \ lt_prog_compiler_pic_CXX \ lt_prog_compiler_wl_CXX \ lt_prog_compiler_static_CXX \ lt_cv_prog_compiler_c_o_CXX \ export_dynamic_flag_spec_CXX \ whole_archive_flag_spec_CXX \ compiler_needs_object_CXX \ with_gnu_ld_CXX \ allow_undefined_flag_CXX \ no_undefined_flag_CXX \ hardcode_libdir_flag_spec_CXX \ hardcode_libdir_separator_CXX \ exclude_expsyms_CXX \ include_expsyms_CXX \ file_list_spec_CXX \ compiler_lib_search_dirs_CXX \ predep_objects_CXX \ postdep_objects_CXX \ predeps_CXX \ postdeps_CXX \ compiler_lib_search_path_CXX; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in reload_cmds \ old_postinstall_cmds \ old_postuninstall_cmds \ old_archive_cmds \ extract_expsyms_cmds \ old_archive_from_new_cmds \ old_archive_from_expsyms_cmds \ archive_cmds \ archive_expsym_cmds \ module_cmds \ module_expsym_cmds \ export_symbols_cmds \ prelink_cmds \ postlink_cmds \ postinstall_cmds \ postuninstall_cmds \ finish_cmds \ sys_lib_search_path_spec \ configure_time_dlsearch_path \ configure_time_lt_sys_library_path \ reload_cmds_CXX \ old_archive_cmds_CXX \ old_archive_from_new_cmds_CXX \ old_archive_from_expsyms_cmds_CXX \ archive_cmds_CXX \ archive_expsym_cmds_CXX \ module_cmds_CXX \ module_expsym_cmds_CXX \ export_symbols_cmds_CXX \ prelink_cmds_CXX \ postlink_cmds_CXX; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done ac_aux_dir='$ac_aux_dir' # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile' AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "common/c_config.h") CONFIG_HEADERS="$CONFIG_HEADERS common/c_config.h" ;; "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;; "baselib/src/bl_config.h") CONFIG_HEADERS="$CONFIG_HEADERS baselib/src/bl_config.h" ;; "${OUTPUT_FILES}") CONFIG_FILES="$CONFIG_FILES ${OUTPUT_FILES}" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= ac_tmp= trap 'exit_status=$? : "${ac_tmp:=$tmp}" { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status ' 0 trap 'as_fn_exit 1' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. # This happens for instance with `./config.status config.h'. if test -n "$CONFIG_FILES"; then ac_cr=`echo X | tr X '\015'` # On cygwin, bash can eat \r inside `` if the user requested igncr. # But we know of no other shell where ac_cr would be empty at this # point, so we can use a bashism as a fallback. if test "x$ac_cr" = x; then eval ac_cr=\$\'\\r\' fi ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then ac_cs_awk_cr='\\r' else ac_cs_awk_cr=$ac_cr fi echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF { echo "cat >conf$$subs.awk <<_ACEOF" && echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && echo "_ACEOF" } >conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h s/^/S["/; s/!.*/"]=/ p g s/^[^!]*!// :repl t repl s/'"$ac_delim"'$// t delim :nl h s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p n b repl :more1 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t nl :delim h s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p b :more2 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t delim ' >$CONFIG_STATUS || ac_write_fail=1 rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" } { line = $ 0 nfields = split(line, field, "@") substed = 0 len = length(field[1]) for (i = 2; i < nfields; i++) { key = field[i] keylen = length(key) if (S_is_set[key]) { value = S[key] line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) len += length(value) + length(field[++i]) substed = 1 } else len += 1 + keylen } print line } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF # VPATH may cause trouble with some makes, so we remove sole $(srcdir), # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ h s/// s/^/:/ s/[ ]*$/:/ s/:\$(srcdir):/:/g s/:\${srcdir}:/:/g s/:@srcdir@:/:/g s/^:*// s/:*$// x s/\(=[ ]*\).*/\1/ G s/\n// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" # Set up the scripts for CONFIG_HEADERS section. # No need to generate them if there are no CONFIG_HEADERS. # This happens for instance with `./config.status Makefile'. if test -n "$CONFIG_HEADERS"; then cat >"$ac_tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF # Transform confdefs.h into an awk script `defines.awk', embedded as # here-document in config.status, that substitutes the proper values into # config.h.in to produce config.h. # Create a delimiter string that does not exist in confdefs.h, to ease # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do ac_tt=`sed -n "/$ac_delim/p" confdefs.h` if test -z "$ac_tt"; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done # For the awk script, D is an array of macro values keyed by name, # likewise P contains macro parameters if any. Preserve backslash # newline sequences. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* sed -n ' s/.\{148\}/&'"$ac_delim"'/g t rset :rset s/^[ ]*#[ ]*define[ ][ ]*/ / t def d :def s/\\$// t bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3"/p s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p d :bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3\\\\\\n"\\/p t cont s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p t cont d :cont n s/.\{148\}/&'"$ac_delim"'/g t clear :clear s/\\$// t bsnlc s/["\\]/\\&/g; s/^/"/; s/$/"/p d :bsnlc s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p b cont ' >$CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 for (key in D) D_is_set[key] = 1 FS = "" } /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { line = \$ 0 split(line, arg, " ") if (arg[1] == "#") { defundef = arg[2] mac1 = arg[3] } else { defundef = substr(arg[1], 2) mac1 = arg[2] } split(mac1, mac2, "(") #) macro = mac2[1] prefix = substr(line, 1, index(line, defundef) - 1) if (D_is_set[macro]) { # Preserve the white space surrounding the "#". print prefix "define", macro P[macro] D[macro] next } else { # Replace #undef with comments. This is necessary, for example, # in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. if (defundef == "undef") { print "/*", prefix defundef, macro, "*/" next } } } { print } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 fi # test -n "$CONFIG_HEADERS" eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" shift for ac_tag do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$ac_tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`$as_echo "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$ac_tmp/stdin" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac ac_MKDIR_P=$MKDIR_P case $MKDIR_P in [\\/$]* | ?:[\\/]* ) ;; */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= ac_sed_dataroot=' /datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@top_build_prefix@&$ac_top_build_prefix&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t s&@MKDIR_P@&$ac_MKDIR_P&;t t $ac_datarootdir_hack " eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ "$ac_tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&2;} rm -f "$ac_tmp/stdin" case $ac_file in -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; esac \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; :H) # # CONFIG_HEADER # if test x"$ac_file" != x-; then { $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" } >"$ac_tmp/config.h" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" mv "$ac_tmp/config.h" "$ac_file" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ || as_fn_error $? "could not create -" "$LINENO" 5 fi # Compute "$ac_file"'s index in $config_headers. _am_arg="$ac_file" _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $_am_arg | $_am_arg:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$_am_arg" : 'X\(//\)[^/]' \| \ X"$_am_arg" : 'X\(//\)$' \| \ X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$_am_arg" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "libtool":C) # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # The names of the tagged configurations supported by this script. available_tags='CXX ' # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG # Assembler program. AS=$lt_AS # DLL creation program. DLLTOOL=$lt_DLLTOOL # Object dumper program. OBJDUMP=$lt_OBJDUMP # Which release of libtool.m4 was used? macro_version=$macro_version macro_revision=$macro_revision # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # What type of objects to build. pic_mode=$pic_mode # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # Shared archive member basename,for filename based shared library versioning on AIX. shared_archive_member_spec=$shared_archive_member_spec # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # An echo program that protects backslashes. ECHO=$lt_ECHO # The PATH separator for the build system. PATH_SEPARATOR=$lt_PATH_SEPARATOR # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # A sed program that does not truncate output. SED=$lt_SED # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="\$SED -e 1s/^X//" # A grep program that handles long lines. GREP=$lt_GREP # An ERE matcher. EGREP=$lt_EGREP # A literal string matcher. FGREP=$lt_FGREP # A BSD- or MS-compatible name lister. NM=$lt_NM # Whether we need soft or hard links. LN_S=$lt_LN_S # What is the maximum length of a command? max_cmd_len=$max_cmd_len # Object file suffix (normally "o"). objext=$ac_objext # Executable file suffix (normally ""). exeext=$exeext # whether the shell understands "unset". lt_unset=$lt_unset # turn spaces into newlines. SP2NL=$lt_lt_SP2NL # turn newlines into spaces. NL2SP=$lt_lt_NL2SP # convert \$build file names to \$host format. to_host_file_cmd=$lt_cv_to_host_file_cmd # convert \$build files to toolchain format. to_tool_file_cmd=$lt_cv_to_tool_file_cmd # A file(cmd) program that detects file types. FILECMD=$lt_FILECMD # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method = "file_magic". file_magic_cmd=$lt_file_magic_cmd # How to find potential files when deplibs_check_method = "file_magic". file_magic_glob=$lt_file_magic_glob # Find potential files using nocaseglob when deplibs_check_method = "file_magic". want_nocaseglob=$lt_want_nocaseglob # Command to associate shared and link libraries. sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd # The archiver. AR=$lt_AR # Flags to create an archive (by configure). lt_ar_flags=$lt_ar_flags # Flags to create an archive. AR_FLAGS=\${ARFLAGS-"\$lt_ar_flags"} # How to feed a file listing to the archiver. archiver_list_spec=$lt_archiver_list_spec # A symbol stripping program. STRIP=$lt_STRIP # Commands used to install an old-style archive. RANLIB=$lt_RANLIB old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Whether to use a lock for old archive extraction. lock_old_archive_extraction=$lock_old_archive_extraction # A C compiler. LTCC=$lt_CC # LTCC compiler flags. LTCFLAGS=$lt_CFLAGS # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration. global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm into a list of symbols to manually relocate. global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import # Transform the output of nm in a C name address pair. global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # Transform the output of nm in a C name address pair when lib prefix is needed. global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix # The name lister interface. nm_interface=$lt_lt_cv_nm_interface # Specify filename containing input files for \$NM. nm_file_list_spec=$lt_nm_file_list_spec # The root where to search for dependent libraries,and where our libraries should be installed. lt_sysroot=$lt_sysroot # Command to truncate a binary pipe. lt_truncate_bin=$lt_lt_cv_truncate_bin # The name of the directory that contains temporary libtool files. objdir=$objdir # Used to examine libraries when file_magic_cmd begins with "file". MAGIC_CMD=$MAGIC_CMD # Must we lock files when doing compilation? need_locks=$lt_need_locks # Manifest tool. MANIFEST_TOOL=$lt_MANIFEST_TOOL # Tool to manipulate archived DWARF debug symbol files on Mac OS X. DSYMUTIL=$lt_DSYMUTIL # Tool to change global to local symbols on Mac OS X. NMEDIT=$lt_NMEDIT # Tool to manipulate fat objects and archives on Mac OS X. LIPO=$lt_LIPO # ldd/readelf like tool for Mach-O binaries on Mac OS X. OTOOL=$lt_OTOOL # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. OTOOL64=$lt_OTOOL64 # Old archive suffix (normally "a"). libext=$libext # Shared library suffix (normally ".so"). shrext_cmds=$lt_shrext_cmds # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Variables whose values should be saved in libtool wrapper scripts and # restored at link time. variables_saved_for_relink=$lt_variables_saved_for_relink # Do we need the "lib" prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Library versioning type. version_type=$version_type # Shared library runtime path variable. runpath_var=$runpath_var # Shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Permission mode override for installation of shared libraries. install_override_mode=$lt_install_override_mode # Command to use after installation of a shared archive. postinstall_cmds=$lt_postinstall_cmds # Command to use after uninstallation of a shared archive. postuninstall_cmds=$lt_postuninstall_cmds # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # As "finish_cmds", except a single script fragment to be evaled but # not shown. finish_eval=$lt_finish_eval # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Compile-time system search path for libraries. sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Detected run-time system search path for libraries. sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path # Explicit LT_SYS_LIBRARY_PATH set during ./configure time. configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # The linker used to build libraries. LD=$lt_LD # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds # A language specific compiler. CC=$lt_compiler # Is the compiler the GNU compiler? with_gcc=$GCC # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc # Whether or not to disallow shared libs when runtime libs are static. allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec # Whether the compiler copes with passing no objects directly. compiler_needs_object=$lt_compiler_needs_object # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds # Commands used to build a shared archive. archive_cmds=$lt_archive_cmds archive_expsym_cmds=$lt_archive_expsym_cmds # Commands used to build a loadable module if different from building # a shared archive. module_cmds=$lt_module_cmds module_expsym_cmds=$lt_module_expsym_cmds # Whether we are building with GNU ld or not. with_gnu_ld=$lt_with_gnu_ld # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag # Flag that enforces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec # Whether we need a single "-rpath" flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary. hardcode_direct=$hardcode_direct # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary and the resulting library dependency is # "absolute",i.e impossible to change by setting \$shlibpath_var if the # library is relocated. hardcode_direct_absolute=$hardcode_direct_absolute # Set to "yes" if using the -LDIR flag during linking hardcodes DIR # into the resulting binary. hardcode_minus_L=$hardcode_minus_L # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR # into the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var # Set to "yes" if building a shared library automatically hardcodes DIR # into the library and all subsequent libraries and executables linked # against it. hardcode_automatic=$hardcode_automatic # Set to yes if linker adds runtime paths of dependent libraries # to runtime path list. inherit_rpath=$inherit_rpath # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs # Set to "yes" if exported symbols are required. always_export_symbols=$always_export_symbols # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms # Symbols that must always be exported. include_expsyms=$lt_include_expsyms # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds # Commands necessary for finishing linking programs. postlink_cmds=$lt_postlink_cmds # Specify filename containing input files. file_list_spec=$lt_file_list_spec # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action # The directories searched by this compiler when creating a shared library. compiler_lib_search_dirs=$lt_compiler_lib_search_dirs # Dependencies to place before and after the objects being linked to # create a shared library. predep_objects=$lt_predep_objects postdep_objects=$lt_postdep_objects predeps=$lt_predeps postdeps=$lt_postdeps # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac ltmain=$ac_aux_dir/ltmain.sh # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" cat <<_LT_EOF >> "$ofile" # ### BEGIN LIBTOOL TAG CONFIG: CXX # The linker used to build libraries. LD=$lt_LD_CXX # How to create reloadable object files. reload_flag=$lt_reload_flag_CXX reload_cmds=$lt_reload_cmds_CXX # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds_CXX # A language specific compiler. CC=$lt_compiler_CXX # Is the compiler the GNU compiler? with_gcc=$GCC_CXX # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_CXX # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_CXX # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_CXX # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_CXX # Whether or not to disallow shared libs when runtime libs are static. allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX # Whether the compiler copes with passing no objects directly. compiler_needs_object=$lt_compiler_needs_object_CXX # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX # Commands used to build a shared archive. archive_cmds=$lt_archive_cmds_CXX archive_expsym_cmds=$lt_archive_expsym_cmds_CXX # Commands used to build a loadable module if different from building # a shared archive. module_cmds=$lt_module_cmds_CXX module_expsym_cmds=$lt_module_expsym_cmds_CXX # Whether we are building with GNU ld or not. with_gnu_ld=$lt_with_gnu_ld_CXX # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_CXX # Flag that enforces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_CXX # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX # Whether we need a single "-rpath" flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary. hardcode_direct=$hardcode_direct_CXX # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary and the resulting library dependency is # "absolute",i.e impossible to change by setting \$shlibpath_var if the # library is relocated. hardcode_direct_absolute=$hardcode_direct_absolute_CXX # Set to "yes" if using the -LDIR flag during linking hardcodes DIR # into the resulting binary. hardcode_minus_L=$hardcode_minus_L_CXX # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR # into the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX # Set to "yes" if building a shared library automatically hardcodes DIR # into the library and all subsequent libraries and executables linked # against it. hardcode_automatic=$hardcode_automatic_CXX # Set to yes if linker adds runtime paths of dependent libraries # to runtime path list. inherit_rpath=$inherit_rpath_CXX # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_CXX # Set to "yes" if exported symbols are required. always_export_symbols=$always_export_symbols_CXX # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_CXX # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_CXX # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_CXX # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds_CXX # Commands necessary for finishing linking programs. postlink_cmds=$lt_postlink_cmds_CXX # Specify filename containing input files. file_list_spec=$lt_file_list_spec_CXX # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_CXX # The directories searched by this compiler when creating a shared library. compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX # Dependencies to place before and after the objects being linked to # create a shared library. predep_objects=$lt_predep_objects_CXX postdep_objects=$lt_postdep_objects_CXX predeps=$lt_predeps_CXX postdeps=$lt_postdeps_CXX # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_CXX # ### END LIBTOOL TAG CONFIG: CXX _LT_EOF ;; "depfiles":C) test x"$AMDEP_TRUE" != x"" || { # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. # TODO: see whether this extra hack can be removed once we start # requiring Autoconf 2.70 or later. case $CONFIG_FILES in #( *\'*) : eval set x "$CONFIG_FILES" ;; #( *) : set x $CONFIG_FILES ;; #( *) : ;; esac shift # Used to flag and report bootstrapping failures. am_rc=0 for am_mf do # Strip MF so we end up with the name of the file. am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile which includes # dependency-tracking related rules and includes. # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ || continue am_dirpart=`$as_dirname -- "$am_mf" || $as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$am_mf" : 'X\(//\)[^/]' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$am_mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` am_filepart=`$as_basename -- "$am_mf" || $as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$am_mf" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` { echo "$as_me:$LINENO: cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles" >&5 (cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } || am_rc=$? done if test $am_rc -ne 0; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "Something went wrong bootstrapping makefile fragments for automatic dependency tracking. If GNU make was not used, consider re-running the configure script with MAKE=\"gmake\" (or whatever is necessary). You can also try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking). See \`config.log' for more details" "$LINENO" 5; } fi { am_dirpart=; unset am_dirpart;} { am_filepart=; unset am_filepart;} { am_mf=; unset am_mf;} { am_rc=; unset am_rc;} rm -f conftest-deps.mk } ;; "default-1":C) case "$CONFIG_FILES" in *po/Makefile.in*) sed -e "/POTFILES =/r tool/mlconfig/po/POTFILES" tool/mlconfig/po/Makefile.in > tool/mlconfig/po/Makefile esac ;; esac done # for ac_tag as_fn_exit 0 _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || as_fn_exit 1 fi # # CONFIG_SUBDIRS section. # if test "$no_recursion" != yes; then # Remove --cache-file, --srcdir, and --disable-option-checking arguments # so they do not pile up. ac_sub_configure_args= ac_prev= eval "set x $ac_configure_args" shift for ac_arg do if test -n "$ac_prev"; then ac_prev= continue fi case $ac_arg in -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \ | --c=*) ;; --config-cache | -C) ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) ;; --disable-option-checking) ;; *) case $ac_arg in *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append ac_sub_configure_args " '$ac_arg'" ;; esac done # Always prepend --prefix to ensure using the same prefix # in subdir configurations. ac_arg="--prefix=$prefix" case $ac_arg in *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args" # Pass --silent if test "$silent" = yes; then ac_sub_configure_args="--silent $ac_sub_configure_args" fi # Always prepend --disable-option-checking to silence warnings, since # different subdirs can have different --enable and --with options. ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args" ac_popdir=`pwd` for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue # Do not complain, so a configure script can configure whichever # parts of a large source tree are present. test -d "$srcdir/$ac_dir" || continue ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)" $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5 $as_echo "$ac_msg" >&6 as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" # Check for guested configure; otherwise get Cygnus style configure. if test -f "$ac_srcdir/configure.gnu"; then ac_sub_configure=$ac_srcdir/configure.gnu elif test -f "$ac_srcdir/configure"; then ac_sub_configure=$ac_srcdir/configure elif test -f "$ac_srcdir/configure.in"; then # This should be Cygnus configure. ac_sub_configure=$ac_aux_dir/configure else { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;} ac_sub_configure= fi # The recursion is here. if test -n "$ac_sub_configure"; then # Make the cache file name correct relative to the subdirectory. case $cache_file in [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;; *) # Relative name. ac_sub_cache_file=$ac_top_build_prefix$cache_file ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;} # The eval makes quoting arguments work. eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \ --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" || as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5 fi cd "$ac_popdir" done fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi # Check whether --enable-utmp-suid was given. if test "${enable_utmp_suid+set}" = set; then : enableval=$enable_utmp_suid; utmp_suid=$enable_utmp_suid fi if test "$INSTALL_OPT" = ""; then # SUID is not set to mlterm on MacOSX/Quartz. if test "$utmp_suid" = "yes" -a "$UTMP_NAME" != "none" -a "$gui" != "quartz"; then has_utmp=`grep utmp /etc/group 2>/dev/null` if test "$has_utmp" ; then INSTALL_OPT="-m 2755 -g utmp" else INSTALL_OPT="-m 4755 -o root" fi else INSTALL_OPT="-m 755" fi if test "$gui" = "fb" ; then INSTALL_OPT="-m 4755 -o root" fi fi cat main/Makefile | sed "s/@INSTALL_OPT@/$INSTALL_OPT/" | sed "s/@UTMP_CFLAGS@/$UTMP_CFLAGS/" > main/Makefile.new mv main/Makefile.new main/Makefile cat vtemu/Makefile | sed "s/@UTMP_CFLAGS@/$UTMP_CFLAGS/" > vtemu/Makefile.new mv vtemu/Makefile.new vtemu/Makefile # Remove 'as_fn_exit 0' sed '$d' ${CONFIG_STATUS} > ${CONFIG_STATUS}.new mv ${CONFIG_STATUS}.new ${CONFIG_STATUS} chmod 755 ${CONFIG_STATUS} cat >>$CONFIG_STATUS < main/Makefile.new mv main/Makefile.new main/Makefile cat vtemu/Makefile | sed "s/@UTMP_CFLAGS@/$UTMP_CFLAGS/" > vtemu/Makefile.new mv vtemu/Makefile.new vtemu/Makefile as_fn_exit 0 EOF # configuration result echo echo echo "Mlterm was configured as follows" echo echo "Installation path prefix : $prefix" echo "Build shared libraries : $enable_shared" echo "Build static libraries : $enable_static" if test "$fbtype" = ""; then echo "GUI toolkit : $gui" else echo "GUI toolkit : $gui ($fbtype)" fi echo "BiDi rendering (Fribidi) : $have_fribidi" echo "Indic rendering : $ind" if test "$OT_LAYOUT_OBJ" = "hb.o"; then echo "OpenType Layout : yes (harfbuzz)" elif test "$OT_LAYOUT_OBJ" = "otf.o"; then echo "OpenType Layout : yes (libotf)" elif test "$OT_LAYOUT_OBJ" = "uniscribe.o"; then echo "OpenType Layout : yes (uniscribe)" else echo "OpenType Layout : no" fi echo "External tools :$tools_result" echo "Image processing : $image" echo "Built-in image library : $with_imagelib" echo "utmp support : $utmp" if test "$gui" = "fb" -o "$gui" = "wayland" -o "$gui" = "sdl2"; then if test "$have_ft" = "yes"; then if test "$fontconfig" = "yes"; then echo "Supported font formats : pcf ttf(+fontconfig)" else echo "Supported font formats : pcf ttf" fi else echo "Supported font formats : pcf" fi elif test "$gui" = "xlib"; then echo "Type engines :$type_engines_result" fi echo "DnD : $dnd" if test "$gui" = "xlib"; then echo "Input Methods : XIM$input_methods_result" else echo "Input Methods :$input_methods_result" fi echo "Scrollbars : simple${scrollbars_result}" echo "libssh2 : $ssh2" echo "mosh directory : $MOSH_DIR" if test "$have_gtk" = "yes"; then if test "$have_gtk4" = "yes"; then echo "GTK+ : yes ($gtk_version, 4.0)" else echo "GTK+ : yes ($gtk_version)" fi else if test "$have_gtk4" = "yes"; then echo "GTK+ : yes (4.0)" else echo "GTK+ : no" fi fi if test "$VTE_ABI" = ""; then vte_version="" else vte_version=" (${VTE_ABI})" fi echo "libvte : $have_vte$vte_version" echo "brlapi : $brlapi" echo "VT52 : $vt52" echo "Permission of mlterm binary : $INSTALL_OPT" echo "Compact true color : $compact_truecolor" echo # This should be called at the end of configure. # If --with-gui=quartz,console is specified, copy uitoolkit/* to gui/console/uitoolkit # before removing following files. if test "$gui" = "quartz" ; then # ui_event_source.c, ui_sb_view_factory.c, ui_scrollbar.c and ui_simple_sb_view.c # exist in uitoolkit/ and uitoolkit/quartz/. # Those in uitoolkit/ must be removed to build those in uitoolkit/quartz/. (cd uitoolkit/quartz/ && \ for file in `ls *.c` ; do if test -f ../$file ; then mv ../$file ../xlib/ ; fi ; done) fi mlterm-3.9.3/configure.in000066400000000000000000002002541441203364000153370ustar00rootroot00000000000000# -*- mode:sh; sh-basic-offset:2; tab-width:2; indent-tabs-mode:t -*- AC_INIT() AC_CONFIG_HEADER(common/c_config.h) AC_CONFIG_AUX_DIR(script) AC_CANONICAL_HOST AC_CANONICAL_BUILD # for CFLAGS="..." ./configure ... AC_SUBST(CFLAGS) if test -d ${top_srcdir-$srcdir}/encodefilter -a -d ${top_srcdir-$srcdir}/baselib ; then CONFIG_SUBDIR_LIBS="internal" if test "$CONFIG_SUBDIR_LIBS" = "external"; then SUBDIRS="baselib encodefilter" fi MEF_CFLAGS='-I${top_builddir}/encodefilter/include' POBL_CFLAGS='-I${top_builddir}/baselib/include' LMEF='${top_builddir}/encodefilter/src/libmef.la' LPOBL='${top_builddir}/baselib/src/libpobl.la' elif test -d ${top_srcdir-$srcdir}/../../encodefilter -a -d ${top_srcdir-$srcdir}/../../baselib ; then # --with-gui=xlib,fb => cd fb ; --with-gui=fb MEF_CFLAGS='-I${top_builddir}/../../encodefilter/include' POBL_CFLAGS='-I${top_builddir}/../../baselib/include' LMEF='${top_builddir}/../../encodefilter/src/libmef.la' LPOBL='${top_builddir}/../../baselib/src/libpobl.la' else LMEF="-lmef" LPOBL="-lpobl" fi AC_SUBST(LMEF) AC_SUBST(MEF_CFLAGS) AC_SUBST(LPOBL) AC_SUBST(POBL_CFLAGS) AC_CHECK_TOOL(PKG_CONFIG, pkg-config) AC_ARG_WITH(ios-sdk, [ --with-ios-sdk@<:@=ARG@:>@ iOS SDK (e.g. iphoneos4.3 iphonesimulator4.3) ], ios_sdk=$with_ios_sdk) if test "$ios_sdk" != ""; then AC_CHECK_PROG(XCRUN, xcrun, xcrun) if test "$XCRUN" != ""; then if test "$SDKROOT" = ""; then SDKROOT=`$XCRUN --sdk $ios_sdk --show-sdk-path` fi if test "$CC" = ""; then # Do 'export' for baselib/configure and encodefilter/configure. export CC="`$XCRUN --sdk $ios_sdk -f cc` -isysroot $SDKROOT" simver=`echo $ios_sdk|sed -n 's/^iphonesimulator\(@<:@0-9.@:>@*\)$/\1/p'` if test "$simver" != ""; then case "$simver" in @<:@0-4@:>@.*) # -D__IPHONE_OS_VERSION_MIN_REQUIRED=40300 or something like that # should be defined as the value of CFLAGS environmental variable # before ./configure. ;; *) CC="$CC -mios-simulator-version-min=$simver" ;; esac fi fi AC_ARG_WITH(ios-arch, [ --with-ios-arch@<:@=ARG@:>@ iOS architectures (e.g. arm7v x86_64,i686) ], ios_arch=$with_ios_arch) if test "$ios_arch" != ""; then ios_arch=`echo ${ios_arch} | sed 's/,/ /g'` for arch in $ios_arch; do CC="$CC -arch $arch" done fi if test "$CPP" = ""; then export CPP="$CC -E" fi if test "$RANLIB" = ""; then export RANLIB=`$XCRUN --sdk $ios_sdk -f ranlib` fi if test "$LIBTOOL" = ""; then export LIBTOOL=`$XCRUN --sdk $ios_sdk -f libtool` fi if test "$AR" = ""; then export AR=`$XCRUN --sdk $ios_sdk -f ar` fi fi XCRUN= fi AC_PROG_CC # mlimgloader (gdiplus.cpp) and SCIM AC_PROG_CXX AC_PROG_INSTALL AC_C_INLINE AC_ARG_ENABLE(debug, [ --enable-debug debug @<:@default=disabled@:>@], debug=$enable_debug) if test "$debug" = "yes" ; then DEB_CFLAGS="-DDEBUG -DBL_DEBUG" fi AC_SUBST(DEB_CFLAGS) AC_LIBTOOL_WIN32_DLL AC_LIBTOOL_DLOPEN AC_ARG_WITH(libtool, [ --with-libtool@<:@=ARG@:>@ libtool path @<:@default=without@:>@], libtool=$with_libtool) if test "${libtool}" != "" ; then LIBTOOL=${libtool} else AM_PROG_LIBTOOL LIBTOOL='${top_builddir}/libtool' fi AC_SUBST(LIBTOOL) AC_CHECK_LIB(socket,connect,SOCK_LIBS=-lsocket) AC_SUBST(SOCK_LIBS) AC_PATH_XTRA if test "$have_x" = "yes"; then X_CFLAGS_AUX="-DHAVE_XLIB" X_LIBS="$X_LIBS -lX11" AC_SUBST(X_CFLAGS_AUX) fi MLTERM_FB="mlterm-fb" AC_ARG_WITH(gui, [ --with-gui@<:@=ARG@:>@ gui library (xlib|win32|fb|quartz|console|wayland|sdl2|beos)], gui=$with_gui) if test `echo $gui | grep ,`; then gui_list=`echo $gui | sed 's/,/ /g'` is_first=t mkdir -p ${top_srcdir-$srcdir}/gui for g in $gui_list; do if test $is_first; then gui=$g is_first= else SUBDIRS="${SUBDIRS} gui/$g" MAKE_DIRS2="${MAKE_DIRS2} gui/$g" if test -d ${top_srcdir-$srcdir}/gui/$g ; then echo "" echo "** WARNING **" echo "${top_srcdir-$srcdir}/gui/$g exists, so copy no files for $g." echo "If there are files which should be copied, copy them manually." echo "" else mkdir -p ${top_srcdir-$srcdir}/gui/$g # clone source tree to build both mlterm, mlterm-wl, mlterm-fb, mlterm-con and mlterm-sdl2. for file in ChangeLog Makefile.in common configure etc gtk inputmethod java \ main man vtemu script scrollbar uitoolkit doc libvterm; do cp -R ${top_srcdir-$srcdir}/$file ${top_srcdir-$srcdir}/gui/$g/ done mkdir -p ${top_srcdir-$srcdir}/gui/$g/contrib cp -R ${top_srcdir-$srcdir}/contrib/scrollbar ${top_srcdir-$srcdir}/gui/$g/contrib/ fi fi done elif test "$gui" = "subdir"; then gui=`basename $PWD` if test "$gui" = "wscons"; then MLTERM_FB="mlterm-wscons" elif test "$gui" = "x68kgrf"; then MLTERM_FB="mlterm-x68kgrf" elif test "$gui" = "scpc98"; then MLTERM_FB="mlterm-scpc98" fi fi AC_SUBST(MLTERM_FB) if test "$gui" = "wscons"; then gui="fb" fbtype="wscons" elif test "$gui" = "x68kgrf"; then gui="fb" fbtype="x68kgrf" elif test "$gui" = "scpc98"; then gui="fb" fbtype="pc98" fi if test "$gui" = "fb" ; then MAKE_DIRS2="doc/kbd ${MAKE_DIRS2}" OUTPUT_FILES="doc/kbd/Makefile ${OUTPUT_FILES}" fi ml_cv_is_posix="yes" case "${host_os}" in mingw*) CYGPATHW=echo WIN32TAG=_win32 if test ! -f "/lib/libmsys-1.0.dll.a" ; then case "${lt_cv_path_LD}" in *-msys*) ;; *) ml_cv_is_posix="no" ;; esac fi if test "$gui" != "sdl2" -a "$gui" != "win32" ; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi ;; msys*) # msys2 AC_CHECK_PROG(CYGPATHW,cygpath,cygpath -w,echo) WIN32TAG=_win32 # $have_x is defined in AC_PATH_XTRA. if test "$have_x" = "yes" ; then if test "$gui" = "" ; then gui="xlib" elif test "$gui" != "xlib" -a "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi else if test "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi fi ;; cygwin*) AC_CHECK_PROG(CYGPATHW,cygpath,cygpath -w,echo) WIN32TAG=_win32 case "${CC} ${CFLAGS}" in *mno-cygwin* | *-mingw*) ml_cv_is_posix="no" ;; *) ;; esac # $have_x is defined in AC_PATH_XTRA. if test "$have_x" = "yes" ; then if test "$gui" = "" ; then gui="xlib" elif test "$gui" != "xlib" -a "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi else if test "$gui" != "win32" -a "$gui" != "console" -a "$gui" != "sdl2"; then echo "$gui is not supported in ${host_os}. Use win32." gui="win32" fi fi ;; *) CYGPATHW=echo if test "$gui" != "xlib" -a "$gui" != "fb" -a "$gui" != "console" -a "$gui" != "quartz" -a "$gui" != "wayland" -a "$gui" != "sdl2" -a "$gui" != "beos"; then if test "$gui" != "" ; then echo "$gui is not supported in ${host_os}. xlib is used instead." fi gui="xlib" fi # $have_x is defined in AC_PATH_XTRA. if test "$gui" = "xlib" -a "$have_x" != "yes" ; then echo "" echo "** ERROR **" echo "Could not find xlib." echo "" exit 1 fi ;; esac # for java/Makefile.in AC_SUBST(WIN32TAG) AC_SUBST(CYGPATHW) if test "$ml_cv_is_posix" = "yes" -o "$debug" = "yes" ; then SUBSYSTEM="-Wl,--subsystem,console" fi AC_SUBST(SUBSYSTEM) if test "$with_gnu_ld" = "yes" ; then DEXPORT="-Wl,--version-script=\$(VPATH)/dexport.map" elif test "`$LD --version 2>&1 | $GREP Solaris`" != "" ; then # This option is for SunOS 5.x (Solaris) or later. DEXPORT="-Wl,-M -Wl,\$(VPATH)/dexport-sun.map -Wl,-z -Wl,nodefs" fi AC_SUBST(DEXPORT) AC_ARG_WITH(gtk, [ --with-gtk@<:@=ARG@:>@ gtk+ version (2.0|3.0|4.0) @<:@default=3.0@:>@], gtk_version=$with_gtk) if test "$gtk_version" = "no" ; then have_gtk=no else if test "$gtk_version" = "4.0" ; then PKG_CHECK_MODULES(GTK4, gtk4, have_gtk4=yes, have_gtk4=no) # mlconfig supports gtk4, but mlterm-menu and libvte do not support it gtk_version=3.0 elif test "$gtk_version" = "" ; then gtk_version=3.0 fi PKG_CHECK_MODULES(GTK, gtk+-$gtk_version, have_gtk=yes, have_gtk=no) if test "$have_gtk" != "yes"; then if test "$gtk_version" = "3.0"; then gtk_version=2.0 else gtk_version=3.0 fi PKG_CHECK_MODULES(GTK, gtk+-$gtk_version, have_gtk=yes, have_gtk=no) fi fi AC_SUBST(GTK_CFLAGS) AC_SUBST(GTK_LIBS) PKG_CHECK_MODULES(GDK_PIXBUF, gdk-pixbuf-2.0, have_gdk_pixbuf2=yes, have_gdk_pixbuf2=no) # try to link libgio-2.0 explicitly. (SF topic #6234829) PKG_CHECK_EXISTS(gdk-pixbuf-2.0 >= 2.14, [ PKG_CHECK_MODULES(GIO, gio-2.0) ]) GDK_PIXBUF_CFLAGS="$GDK_PIXBUF_CFLAGS $GIO_CFLAGS" GDK_PIXBUF_LIBS="$GDK_PIXBUF_LIBS $GIO_LIBS" AC_CHECK_PROG(have_gdk_pixbuf1,gdk-pixbuf-config,yes) if test "$gui" = "xlib" ; then AC_ARG_WITH(imagelib, [ --with-imagelib@<:@=ARG@:>@ image library (gdk-pixbuf) @<:@default=no@:>@], imagelib=$with_imagelib) else # Don't link an external image library on win32gdi or framebuffer. with_imagelib="" fi case ${imagelib} in imlib) AC_CHECK_PROG(imlib_config,imlib-config,yes,no) if test "x$imlib_config" = "xno" ; then echo "" echo "** ERROR **" echo "Could not find imlib-config." echo "" exit 1 fi echo "" echo "** WARNING **" echo " imlib is no longer supported." echo "" IMAGELIB_CFLAGS="`imlib-config --cflags` -DBUILTIN_IMAGELIB" IMAGELIB_LIBS="`imlib-config --libs`" ;; imlib2) AC_CHECK_PROG(imlib2_config,imlib2-config,yes,no) if test "x$imlib2_config" = "xno" ; then echo "" echo "** ERROR **" echo "Could not find imlib2-config." echo "" exit 1 fi echo "" echo "** WARNING **" echo " imlib2 is no longer supported." echo "" IMAGELIB_CFLAGS="`imlib2-config --cflags` -DBUILTIN_IMAGELIB" IMAGELIB_LIBS="`imlib2-config --libs`" ;; gdk-pixbuf) if test "$have_gdk_pixbuf2" = "yes" ; then gdk_pixbuf_version=2 elif test "$have_gdk_pixbuf1" = "yes" ; then gdk_pixbuf_version=1 else echo "" echo "** ERROR **" echo "Could not find gdk-pixbuf" echo "" exit 1 fi ;; gdk-pixbuf2) if test "$have_gdk_pixbuf2" = "yes" ; then gdk_pixbuf_version=2 else echo "" echo "** ERROR **" echo "Could not find gdk-pixbuf2" echo "" exit 1 fi ;; gdk-pixbuf1) if test "$have_gdk_pixbuf1" = "yes" ; then gdk_pixbuf_version=1 else echo "" echo "** ERROR **" echo "Could not find gdk-pixbuf1" echo "" exit 1 fi ;; *) if test "${imagelib}" != "" ; then echo "" echo "** ERROR **" echo "${imagelib} library is NOT supported." echo "" exit 1 fi ;; esac PKG_CHECK_MODULES(FT, freetype2, have_ft=yes, have_ft=no) if test "$have_ft" = "no" ; then PKG_CHECK_MODULES(FT, freetype, have_ft=yes, have_ft=no) fi # -DUSE_FREETYPE can be added to FT_CFLAGS later. FT_CFLAGS_ORIGINAL=$FT_CFLAGS if test "$gdk_pixbuf_version" != "" ; then if test "$gdk_pixbuf_version" = "1" ; then # Override GDK_PIXBUF_XXX variables. GDK_PIXBUF_CFLAGS="`gdk-pixbuf-config --cflags`" GDK_PIXBUF_LIBS="`gdk-pixbuf-config --libs`" echo "" echo "** WARNING **" echo " gdk-pixbuf1 is no longer supported." echo "" fi IMAGELIB_CFLAGS="${GDK_PIXBUF_CFLAGS} -DBUILTIN_IMAGELIB" IMAGELIB_LIBS="${GDK_PIXBUF_LIBS}" if test "$have_ft" = "yes"; then IMAGELIB_CFLAGS="$IMAGELIB_CFLAGS -DUSE_FREETYPE_EMOJI $FT_CFLAGS_ORIGINAL" IMAGELIB_LIBS="$IMAGELIB_LIBS $FT_LIBS" fi elif test "$have_gdk_pixbuf2" != "yes" -a "$have_gdk_pixbuf1" = "yes" ; then GDK_PIXBUF_CFLAGS="`gdk-pixbuf-config --cflags`" GDK_PIXBUF_LIBS="`gdk-pixbuf-config --libs`" fi # Used by mlimgloader. AC_SUBST(GDK_PIXBUF_CFLAGS) AC_SUBST(GDK_PIXBUF_LIBS) AC_SUBST(IMAGELIB_CFLAGS) AC_SUBST(IMAGELIB_LIBS) # XXX For pow in libm.so which is used in ui_imagelib.c # /lib/* ... e.g.) /lib/i386-linux-gnu in ubuntu. for ml_cv_lib_path in /lib /usr/lib /lib/* `echo $LIBRARY_PATH | tr ":" " "` ; do libm_files=`ls $ml_cv_lib_path/libm\\.so* $ml_cv_lib_path/libm\\.sl* 2> /dev/null` for libm_file in $libm_files ; do if test -n "`$NM -D $libm_file | $GREP pow`" ; then ml_cv_libm_dir=`dirname $libm_file` break fi done if test "$ml_cv_libm_dir" != ""; then break fi done if test -z "$IMAGELIB_LIBS" ; then if test -n "$ml_cv_libm_dir" ; then MATH_CFLAGS="-DDLOPEN_LIBM -DLIBMDIR=\\\"$ml_cv_libm_dir\\\"" else AC_CHECK_LIB(m, pow, MATH_LIBS=-lm) fi else AC_CHECK_LIB(m, pow, MATH_LIBS=-lm) fi AC_SUBST(MATH_LIBS) AC_SUBST(MATH_CFLAGS) AC_ARG_ENABLE(image, [ --disable-image show image @<:@default=enabled@:>@], image=$enable_image, image="yes") if test "$image" != "yes" ; then # If sixel.h is not found on gui=console, set IMAGE_CFLAGS="-DNO_IMAGE" forcibly below. IMAGE_CFLAGS="-DNO_IMAGE" fi AC_SUBST(IMAGE_CFLAGS) if test "$gui" = "win32" ; then GUI="win32" GUI_CFLAGS="-DUSE_WIN32GUI" X_CFLAGS="" elif test "$gui" = "xlib" ; then GUI="xlib" # Li18nux Xlib-I18N defines X_HAVE_UTF8_STRING but has no Xutf8LookupString. ldflags="$LDFLAGS" cflags="$CFLAGS" LDFLAGS="$LDFLAGS $X_PRE_LIBS $X_LIBS $X_EXTRA_LIBS" CFLAGS="$X_CFLAGS $CFLAGS" AC_CHECK_LIB(X11,Xutf8LookupString,XUTF8_CFLAGS="-DHAVE_XUTF8_LOOKUP_STRING") LDFLAGS="$ldflags" CFLAGS="$cflags" AC_SUBST(XUTF8_CFLAGS) elif test "$gui" = "quartz" ; then GUI="quartz" GUI_CFLAGS="-DUSE_QUARTZ" if test "$ios_sdk" != ""; then GUI_CFLAGS="$GUI_CFLAGS -DCOCOA_TOUCH" COCOAOBJ=cocoatouch.o COCOA_LIBS="-framework Foundation -framework UIKit -framework CoreGraphics" else COCOAOBJ=cocoa.o COCOA_LIBS="-framework Foundation -framework Cocoa" fi AC_SUBST(COCOAOBJ) AC_SUBST(COCOA_LIBS) X_CFLAGS="" VT_NORM_OBJ="vt_normalize.o" VT_NORM_CFLAGS="-DUSE_NORMALIZE" AC_SUBST(VT_NORM_OBJ) AC_SUBST(VT_NORM_CFLAGS) elif test "$gui" = "console" ; then GUI="console" GUI_CFLAGS="-DUSE_CONSOLE" AC_CHECK_HEADER(sixel.h, SIXEL_CFLAGS="-DUSE_LIBSIXEL") if test "$SIXEL_CFLAGS" = "-DUSE_LIBSIXEL" ; then SIXEL_LIBS="-lsixel" else IMAGE_CFLAGS="-DNO_IMAGE" IMAGELIB_CFLAGS="" IMAGELIB_LIBS="" fi AC_SUBST(SIXEL_CFLAGS) AC_SUBST(SIXEL_LIBS) elif test "$gui" = "beos" ; then GUI="beos" GUI_CFLAGS="-DUSE_BEOS" elif test "$gui" = "wayland" ; then PKG_CHECK_MODULES(WAYLAND, [wayland-client wayland-cursor xkbcommon]) GUI="wayland" GUI_CFLAGS="-DUSE_WAYLAND" AC_SUBST(WAYLAND_CFLAGS) AC_SUBST(WAYLAND_LIBS) elif test "$gui" = "sdl2" ; then PKG_CHECK_MODULES(SDL2, sdl2, have_sdl2=yes, have_sdl2=no) if test "$have_sdl2" != "yes" ; then AC_CHECK_PROG(sdl2_config, sdl2-config, yes) if test "$sdl2_config" = "yes"; then SDL2_CFLAGS="`sdl2-config --cflags`" SDL2_LIBS="`sdl2-config --libs`" else echo "sdl2 is not available." exit 1 fi fi if test "$ml_cv_is_posix" != "yes"; then SDL2GUI="win32" AC_SUBST(SDL2GUI) fi GUI="sdl2" GUI_CFLAGS="-DUSE_SDL2" AC_SUBST(SDL2_CFLAGS) AC_SUBST(SDL2_LIBS) else GUI="fb" if test "$fbtype" = ""; then if test "`sysctl machdep.ispc98`" = "machdep.ispc98: 1"; then fbtype="pc98" else # for NetBSD/x68k # is also checked not to enable USE_GRF on NetBSD/macppc. AC_CHECK_HEADER(machine/grfioctl.h, AC_CHECK_HEADER(machine/vuid_event.h, [ fbtype="x68kgrf" GUI_CFLAGS="-DHAVE_GRFIOCTL_H" ])) fi fi if test "$fbtype" = "x68kgrf"; then GUI_CFLAGS="${GUI_CFLAGS} -DUSE_GRF" elif test "$fbtype" = "pc98"; then GUI_CFLAGS="${GUI_CFLAGS} -DPC98" fi GUI_CFLAGS="${GUI_CFLAGS} -DUSE_FRAMEBUFFER" fi AC_SUBST(GUI) AC_SUBST(GUI_CFLAGS) AC_CHECK_HEADER(regex.h, [ REGEX_CFLAGS="-DHAVE_REGEX" AC_CHECK_LIB(regex,regcomp,REGEX_LIBS=-lregex) ]) AC_SUBST(REGEX_CFLAGS) AC_SUBST(REGEX_LIBS) AC_ARG_ENABLE(compact-truecolor, [ --disable-compact-truecolor true color support by reusing 240 palettes @<:@default=enabled@:>@], compact_truecolor=$enable_compact_truecolor, compact_truecolor="yes") if test "$compact_truecolor" = "yes" ; then TRUECOLOR_CFLAGS="-DUSE_COMPACT_TRUECOLOR" else TRUECOLOR_TAG="x" fi AC_SUBST(TRUECOLOR_CFLAGS) AC_SUBST(TRUECOLOR_TAG) AC_ARG_ENABLE(dl-ctl, [ --disable-dl-ctl dynamic loading ctl library @<:@default=enable@:>@], dl_ctl=$enable_dl_ctl, dl_ctl="yes") if test "$enable_shared" = "no" ; then dl_ctl="no" fi if test "$dl_ctl" = "yes" ; then LMLTERM_CORE=libmlterm${TRUECOLOR_TAG}_core.la CTL_LOADER_OBJ=vt_ctl_loader.o else LMLTERM_CORE=libmlterm${TRUECOLOR_TAG}_core.a CTL_CFLAGS="-DNO_DYNAMIC_LOAD_CTL" CTL_LIBS_FOR_VTE="../vtemu/libctl/*.lo" fi AC_SUBST(LMLTERM_CORE) AC_SUBST(CTL_LOADER_OBJ) AC_ARG_ENABLE(fribidi, [ --disable-fribidi bidi @<:@default=enabled@:>@], fribidi=$enable_fribidi, fribidi="yes") if test "$fribidi" = "yes" ; then PKG_CHECK_MODULES(FRIBIDI, fribidi, have_fribidi=yes, have_fribidi=no) if test "$have_fribidi" != "yes" ; then AC_CHECK_PROG(fribidi_config,fribidi-config,yes,fribidi="no") if test "$fribidi_config" = "yes" ; then FRIBIDI_CFLAGS="`fribidi-config --cflags`" FRIBIDI_LIBS="`fribidi-config --libs`" have_fribidi="yes" fi fi else have_fribidi="no" fi if test "$have_fribidi" = "yes" ; then if test "$dl_ctl" = "yes" ; then CTL_LIBS="libctl${TRUECOLOR_TAG}_bidi.la ${CTL_LIBS}" else CTL_CFLAGS="-DUSE_FRIBIDI ${CTL_CFLAGS}" CTL_LIBS="libctl${TRUECOLOR_TAG}_bidi.a ${CTL_LIBS}" CTL_LIBS_FOR_PROG="../vtemu/libctl/libctl${TRUECOLOR_TAG}_bidi.a ${FRIBIDI_LIBS} ${CTL_LIBS_FOR_PROG}" CTL_LIBS_FOR_VTE="${FRIBIDI_LIBS} ${CTL_LIBS_FOR_VTE}" fi fi AC_SUBST(FRIBIDI_CFLAGS) AC_SUBST(FRIBIDI_LIBS) AC_SUBST(CTL_CFLAGS) AC_SUBST(CTL_LIBS_FOR_VTE) AC_ARG_WITH(pthread, [ --without-pthread do not use pthread @<:@default=with@:>@]) AC_ARG_ENABLE(dl-type, [ --disable-dl-type dynamic loading type engine library @<:@default=enable@:>@], dl_type=$enable_dl_type, dl_type="yes") if test "$enable_shared" = "no" ; then dl_type="no" fi if test "$dl_type" = "yes" ; then TYPE_LOADER_OBJ=ui_type_loader.o if test "$gui" != "xlib" ; then TYPE_CFLAGS="-DNO_DYNAMIC_LOAD_TYPE" fi else TYPE_CFLAGS="-DNO_DYNAMIC_LOAD_TYPE" TYPE_LIBS_FOR_VTE="../uitoolkit/libtype/*.lo" fi AC_SUBST(TYPE_LOADER_OBJ) if test "$gui" != "win32" -a "$gui" != "quartz"; then PKG_CHECK_MODULES(FONTCONFIG, fontconfig, have_fc=yes, have_fc=no) if test "$have_fc" = "yes"; then FONTCONFIG_CFLAGS="$FONTCONFIG_CFLAGS -DUSE_FONTCONFIG" AC_SUBST(FONTCONFIG_CFLAGS) AC_SUBST(FONTCONFIG_LIBS) fi fi AC_ARG_ENABLE(anti_alias, [ --disable-anti-alias same as --with-type-engines=xcore on xlib @<:@default=enabled@:>@ do not use truetype fonts on framebuffer @<:@default=enabled@:>@ ], anti_alias=$enable_anti_alias, anti_alias="auto") if test "$anti_alias" != "no"; then if test "$gui" = "fb" -o "$gui" = "wayland" -o "$gui" = "sdl2"; then if test "$have_ft" = "yes" ; then FT_CFLAGS="$FT_CFLAGS -DUSE_FREETYPE " AC_ARG_ENABLE(fontconfig, [ --disable-fontconfig use fontconfig with freetype on framebuffer or wayland @<:@default=enabled@:>@ ], fontconfig=$enable_fontconfig, fontconfig="yes") if test "$fontconfig" != "no" -a "$have_fc" = "yes"; then FT_CFLAGS="$FT_CFLAGS $FONTCONFIG_CFLAGS" FT_LIBS="$FT_LIBS $FONTCONFIG_LIBS" else fontconfig="no" fi AC_SUBST(FT_CFLAGS) AC_SUBST(FT_LIBS) fi fi fi AC_ARG_WITH(type_engines, [ --with-type-engines@<:@=ARG@:>@ type engines (xcore, xft, cairo) @<:@default=xcore,xft,cairo@:>@], type_engines=$with_type_engines) if test "$gui" != "xlib" ; then type_engines="xcore" elif test "$type_engines" = "" ; then if test "$anti_alias" = "no" ; then type_engines="xcore" else type_engines="xcore,xft,cairo" fi fi type_engines=`echo ${type_engines} | sed 's/,/ /g'` for type_engine in ${type_engines} ; do case ${type_engine} in xft) PKG_CHECK_MODULES(XFT, xft, have_xft=yes, have_xft=no) if test "$have_xft" != "yes" ; then AC_CHECK_PROG(xft_config,xft-config,yes) if test "$xft_config" = "yes" ; then XFT_CFLAGS="`xft-config --cflags`" XFT_LIBS="`xft-config --libs`" have_xft=yes else AC_CHECK_LIB(Xft,XftDrawCreate, [ have_xft=yes # -lfontconfig is necessary because ui_font.c refers FcXXX # functions directly. XFT_LIBS="-lXft -lfontconfig" ]) fi elif test "$gui" = "xlib" -a "$enable_shared" = "no" ; then # In case --disable-shared is specified on some platforms # (e.g. ubuntu 14.04) where dependency_libs="" in libXft.la. XFT_LIBS="$XFT_LIBS -lfontconfig -lfreetype" fi if test "$have_xft" = "yes" ; then if test "$dl_type" = "yes" ; then TYPE_LIBS="libtype_xft.la ${TYPE_LIBS}" else NODL_OBJ="ui_window_xft.o ${NODL_OBJ}" TYPE_LIBS_FOR_VTE="${XFT_LIBS} ${TYPE_LIBS_FOR_VTE}" fi TYPE_CFLAGS="-DUSE_TYPE_XFT ${TYPE_CFLAGS}" type_engines_result="$type_engines_result xft" fi ;; cairo) PKG_CHECK_MODULES(CAIRO, cairo, have_cairo=yes, have_cairo=no) if test "$have_cairo" != "yes" ; then AC_CHECK_LIB(cairo,cairo_create, [ have_cairo=yes # -lfontconfig is necessary because ui_font.c refers FcXXX # functions directly. CAIRO_LIBS="-lcairo -lfontconfig" ]) elif test "$gui" = "xlib" -a "$enable_shared" = "no" ; then # In case --disable-shared is specified on some platforms # (e.g. ubuntu 14.04) where dependency_libs="" in libcairo.la. CAIRO_LIBS="$CAIRO_LIBS -lfontconfig -lfreetype" fi if test "$have_cairo" = "yes" ; then if test "$dl_type" = "yes" ; then TYPE_LIBS="libtype_cairo.la ${TYPE_LIBS}" if test "$with_pthread" != "no" ; then # NetBSD doesn't allow shared libraries to link # libpthread without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi else NODL_OBJ="ui_window_cairo.o ${NODL_OBJ}" TYPE_LIBS_FOR_VTE="${CAIRO_LIBS} ${TYPE_LIBS_FOR_VTE}" fi TYPE_CFLAGS="-DUSE_TYPE_CAIRO ${TYPE_CFLAGS}" type_engines_result="$type_engines_result cairo" fi ;; xcore) TYPE_CFLAGS="-DUSE_TYPE_XCORE ${TYPE_CFLAGS}" type_engines_result="$type_engines_result xcore" ;; *) echo "${type_engine} is unknown type engine." ;; esac done AC_ARG_ENABLE(otl, [ --disable-otl Open Type layout with the use of harfbuzz or libotf @<:@default=enabled@:>@], otl=$enable_otl, otl="yes") if test "$otl" != "yes" ; then echo "Open Type layout is disabled" elif test "$gui" = "xlib" -a "$dl_type" = "no" -a "$type_engines_result" = " xcore"; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "fb" -a "$have_ft" != "yes" ; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "wayland" -a "$have_ft" != "yes" ; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "sdl2" -a "$have_ft" != "yes" ; then echo "libotf/libharfbuzz is not available." elif test "$gui" = "console" ; then echo "libotf/libharfbuzz is not available." else PKG_CHECK_MODULES(HB, harfbuzz, have_hb=yes, have_hb=no) if test "$have_hb" = "yes" ; then if test "$gui" = "quartz" ; then CFLAGS_orig=$CFLAGS CPPFLAGS_orig=$CPPFLAGS CFLAGS="$CFLAGS $HB_CFLAGS" CPPFLAGS="$CPPFLAGS $HB_CFLAGS" AC_CHECK_HEADER(hb-coretext.h, have_hb_coretext_h=yes, have_hb_coretext_h=no) CFLAGS=$CFLAGS_orig CPPFLAGS=$CPPFLAGS_orig if test "$have_hb_coretext_h" != "yes" ; then echo "" echo "** ERROR **" echo "harfbuzz/hb-coretext.h is not found." echo "Install harfbuzz with --with-coretext=yes in advance." echo "" have_hb=no fi elif test "$have_ft" = "yes" ; then CFLAGS_orig=$CFLAGS CPPFLAGS_orig=$CPPFLAGS CFLAGS="$CFLAGS $HB_CFLAGS $FT_CFLAGS_ORIGINAL" CPPFLAGS="$CPPFLAGS $HB_CFLAGS $FT_CFLAGS_ORIGINAL" AC_CHECK_HEADER(hb-ft.h, have_hb_ft_h=yes, have_hb_ft_h=no) CFLAGS=$CFLAGS_orig CPPFLAGS=$CPPFLAGS_orig if test "$have_hb_ft_h" != "yes" ; then echo "" echo "** ERROR **" echo "harfbuzz/hb-ft.h is not found." echo "Install harfbuzz with --with-freetype=yes in advance." echo "" have_hb=no fi fi fi if test "$have_hb" = "yes"; then OT_LAYOUT_CFLAGS="$HB_CFLAGS -DUSE_HARFBUZZ -DUSE_OT_LAYOUT" OT_LAYOUT_LIBS="$HB_LIBS" OT_LAYOUT_OBJ=hb.o if test "$gui" = "win32"; then OT_LAYOUT_LIBS="$OT_LAYOUT_LIBS -lfreetype" elif test "$gui" != "quartz" -a "$have_ft" = "yes"; then OT_LAYOUT_CFLAGS="$OT_LAYOUT_CFLAGS $FT_CFLAGS_ORIGINAL" fi elif test "$gui" = "win32" ; then OT_LAYOUT_CFLAGS="-DUSE_OT_LAYOUT -DUSE_UNISCRIBE" OT_LAYOUT_OBJ=uniscribe.o OT_LAYOUT_LIBS="-lusp10" else AC_CHECK_PROG(libotf_config,libotf-config,yes) if test "$libotf_config" = "yes" ; then OT_LAYOUT_CFLAGS="`libotf-config --cflags` -DUSE_OT_LAYOUT" OT_LAYOUT_LIBS="`libotf-config --libs`" OT_LAYOUT_OBJ=otf.o fi fi if test "$OT_LAYOUT_OBJ" != "" -a "$enable_shared" = "no" ; then OT_LAYOUT_CFLAGS="$OT_LAYOUT_CFLAGS -DNO_DYNAMIC_LOAD_OTL" OT_LAYOUT_LIBS_FOR_PROG="$OT_LAYOUT_LIBS" fi if test "$OT_LAYOUT_OBJ" != "" -a "$LMLTERM_CORE" = "libmlterm${TRUECOLOR_TAG}_core.la" ; then LMLTERM_CORE="libmlterm${TRUECOLOR_TAG}_coreotl.la" fi fi AC_SUBST(OT_LAYOUT_LIBS) AC_SUBST(OT_LAYOUT_LIBS_FOR_PROG) AC_SUBST(OT_LAYOUT_CFLAGS) AC_SUBST(OT_LAYOUT_OBJ) if test "$OT_LAYOUT_OBJ" != "" ; then MAKE_DIRS2="uitoolkit/libotl ${MAKE_DIRS2}" OUTPUT_FILES="uitoolkit/libotl/Makefile ${OUTPUT_FILES}" fi if test "${NODL_OBJ}" != "" ; then TYPE_LIBS=libtype.a TYPE_LIBS_FOR_PROG="../uitoolkit/libtype/libtype.a ${CAIRO_LIBS} ${XFT_LIBS} ${OT_LAYOUT_LIBS}" fi if test "${TYPE_CFLAGS}" = "" ; then echo "No type engine is specified." exit 1 fi AC_SUBST(XFT_CFLAGS) AC_SUBST(XFT_LIBS) AC_SUBST(CAIRO_LIBS) AC_SUBST(CAIRO_LIBS) AC_SUBST(TYPE_CFLAGS) AC_SUBST(TYPE_LIBS) AC_SUBST(TYPE_LIBS_FOR_PROG) AC_SUBST(TYPE_LIBS_FOR_VTE) AC_SUBST(NODL_OBJ) AC_SUBST(PROG) AC_ARG_ENABLE(ssh2, [ --disable-ssh2 libssh2 @<:@default=enabled@:>@], ssh2=$enable_ssh2, ssh2="yes") if test "$ssh2" = "yes" ; then PKG_CHECK_MODULES(SSH2, libssh2, [ SSH2_CFLAGS="$SSH2_CFLAGS -DUSE_LIBSSH2" if test "x$allow_undefined_flag" = "xunsupported" ; then # vt_pty_ssh.c uses CRYPTO_xxx functions. SSH2_LIBS="-lcrypto $SSH2_LIBS" fi ], ssh2="no") fi if test "$enable_shared" != "no" ; then AC_ARG_WITH(mosh, [ --with-mosh@<:@=ARG@:>@ The directory where mosh is built]) if test -d "$with_mosh"; then PKG_CHECK_MODULES(PROTOBUF, protobuf, MOSH_DIR=$with_mosh, with_mosh="") if test "$MOSH_DIR" != ""; then if test -f $MOSH_DIR/src/crypto/ocb.cc; then # mosh-1.3.2 or before. MOSH_OCB_OBJ="ocb.o" # XXX (See terminaldisplayinit.cc) PROTOBUF_CFLAGS="$PROTOBUF_CFLAGS -DMOSH_VERSION=10302" else # mosh-1.4.0 or later. MOSH_OCB_OBJ="ocb_internal.o" fi fi fi fi if test "$ml_cv_is_posix" = "no" ; then if test "$ssh2" = "yes" ; then VT_PTY_OBJ="vt_pty_ssh.o vt_pty_mosh.o" if test -d "$with_mosh"; then MAKE_DIRS2="${MAKE_DIRS2} vtemu/libptyssh vtemu/libptymosh" OUTPUT_FILES="${OUTPUT_FILES} vtemu/libptyssh/Makefile vtemu/libptymosh/Makefile" SSH2_LIBS_FOR_PROG="-lwsock32" # XXX Hack for wcwidth() PROTOBUF_LIBS="$PROTOBUF_LIBS \${top_builddir}/encodefilter/src/libmef.la" else # Not dlopen SSH2_CFLAGS="$SSH2_CFLAGS -DNO_DYNAMIC_LOAD_SSH" SSH2_LIBS_FOR_PROG="$SSH2_LIBS -lwsock32 -lws2_32" SSH2_LIBS= fi else VT_PTY_OBJ="vt_pty_pipewin32.o" fi else VT_PTY_OBJ="vt_pty_unix.o" if test "$ssh2" = "yes" ; then if test "$with_pthread" != "no" ; then AC_CHECK_HEADER(pthread.h, [ SSH2_CFLAGS="$SSH2_CFLAGS -DHAVE_PTHREAD" SSH2_LIBS="$SSH2_LIBS -lpthread" ]) # NetBSD doesn't allow shared libraries to link libpthread # without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi VT_PTY_OBJ="vt_pty_ssh.o vt_pty_mosh.o ${VT_PTY_OBJ}" if test "$enable_shared" = "no" ; then SSH2_CFLAGS="$SSH2_CFLAGS -DNO_DYNAMIC_LOAD_SSH" SSH2_LIBS_FOR_PROG="$SSH2_LIBS" SSH2_LIBS= else # dlopen libptyssh MAKE_DIRS2="vtemu/libptyssh ${MAKE_DIRS2}" OUTPUT_FILES="vtemu/libptyssh/Makefile ${OUTPUT_FILES}" if test -d "$with_mosh"; then MAKE_DIRS2="${MAKE_DIRS2} vtemu/libptymosh" OUTPUT_FILES="${OUTPUT_FILES} vtemu/libptymosh/Makefile" fi fi fi fi AC_SUBST(SSH2_LIBS) AC_SUBST(SSH2_LIBS_FOR_PROG) AC_SUBST(SSH2_CFLAGS) AC_SUBST(VT_PTY_OBJ) AC_SUBST(MOSH_DIR) AC_SUBST(MOSH_OCB_OBJ) AC_SUBST(PROTOBUF_CFLAGS) AC_SUBST(PROTOBUF_LIBS) if test "${have_gtk}" = "yes" ; then if test "${gtk_version}" = "3.0" ; then PKG_CHECK_MODULES(VTE, vte-2.91, have_vte=yes, have_vte=no) if test "$have_vte" = "yes" ; then VTE_ABI=2.91 else PKG_CHECK_MODULES(VTE, vte-2.90, have_vte=yes, have_vte=no) if test "$have_vte" = "yes"; then VTE_ABI=2.90 fi fi else PKG_CHECK_MODULES(VTE, vte, have_vte=yes, have_vte=no) fi if test "$have_vte" = "yes" ; then OUTPUT_FILES="gtk/Makefile ${OUTPUT_FILES}" AC_SUBST(VTE_ABI) fi else have_vte=no fi tools="mlclient,mlconfig,mlcc,mlterm-menu,mlimgloader,registobmp,mlfc" AC_ARG_WITH(tools, [ --with-tools@<:@=ARG@:>@ external tools @<:@default=mlclient,mlconfig,mlcc,mlterm-menu,mlimgloader,registobmp,mlfc@:>@], [ # if given --without-tools if test "${with_tools}" = "no" ; then tools="" else if test "${with_tools}" != "yes" ; then tools=${with_tools} fi if test -z "$IMAGELIB_CFLAGS" -a "`echo ${tools}|$GREP mlimgloader`" = "" ; then # If --with-imagelib option is not specified, mlimgloader is always built. tools=${tools},mlimgloader fi fi ]) tools=`echo ${tools} | sed 's/,/ /g'` AC_ARG_ENABLE(use-tools, [ --disable-use-tools do not build and use external tools @<:@default=enabled@:>@]) if test "$enable_use_tools" = "no" ; then TOOLS_CFLAGS="-DNO_TOOLS" tools= fi AC_SUBST(TOOLS_CFLAGS) AM_INIT_AUTOMAKE(mlterm,3.9.3) for tool in ${tools} ; do case ${tool} in mlconfig) if test "$gui" != "fb" -a "$gui" != "console" ; then if test "${have_gtk}" = "yes" -o "${have_gtk4}" = "yes" ; then AM_GLIB_GNU_GETTEXT MAKE_DIRS2="tool/mlconfig ${MAKE_DIRS2}" OUTPUT_FILES="tool/mlconfig/Makefile ${OUTPUT_FILES}" if test "${MSGFMT}" != "no"; then OUTPUT_FILES="tool/mlconfig/po/Makefile.in ${OUTPUT_FILES}" fi tools_result="$tools_result $tool" if test "$have_gtk4" = "yes" ; then GTK_CFLAGS_FOR_MLCONFIG=$GTK4_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK4_LIBS else GTK_CFLAGS_FOR_MLCONFIG=$GTK_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK_LIBS fi AC_SUBST(GTK_CFLAGS_FOR_MLCONFIG) AC_SUBST(GTK_LIBS_FOR_MLCONFIG) else echo "" echo "** WARNING **" echo " couldn't compile mlconfig since headers/libraries of GTK+ are missing." echo "" fi fi ;; mlterm-menu) if test "${have_gtk}" = "yes" -a "$gui" != "fb" -a "$gui" != "console" ; then MAKE_DIRS2="contrib/tool/mlterm-menu ${MAKE_DIRS2}" OUTPUT_FILES="contrib/tool/mlterm-menu/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" else echo "" echo "** WARNING **" echo " couldn't compile mlterm-menu since headers/libraries of GTK+-2 are missing." echo "" fi ;; mlclient) if test "$ml_cv_is_posix" = "yes" -a "$gui" != "console" ; then MAKE_DIRS2="tool/mlclient ${MAKE_DIRS2}" OUTPUT_FILES="tool/mlclient/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; w3mmlconfig) AC_PATH_PROG(PERL,perl,$PATH) if test "x$PERL" = x ; then echo "" echo "** WARNING **" echo " couldn't find perl in PATH environment variable." echo "" PERL="/usr/local/bin/perl" # should be "/usr/bin/env perl"? fi MAKE_DIRS2="tool/w3mmlconfig ${MAKE_DIRS2}" OUTPUT_FILES="tool/w3mmlconfig/Makefile tool/w3mmlconfig/mlconfig.cgi tool/w3mmlconfig/w3mmlconfig ${OUTPUT_FILES}" tools_result="$tools_result $tool" ;; mlcc) if test "$ml_cv_is_posix" = "yes" ; then MAKE_DIRS2="contrib/tool/mlcc ${MAKE_DIRS2}" OUTPUT_FILES="contrib/tool/mlcc/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; mlmenu) if test "$gui" = "xlib" ; then MAKE_DIRS2="tool/mlmenu ${MAKE_DIRS2}" OUTPUT_FILES="tool/mlmenu/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; mlterm-zoom) if test "$gui" = "xlib" ; then MAKE_DIRS2="contrib/tool/mlterm-zoom ${MAKE_DIRS2}" OUTPUT_FILES="contrib/tool/mlterm-zoom/Makefile ${OUTPUT_FILES}" tools_result="$tools_result $tool" fi ;; mlimgloader) if test "$gui" != "quartz" ; then OUTPUT_FILES="tool/mlimgloader/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/mlimgloader ${MAKE_DIRS2}" tools_result="$tools_result $tool" AC_TRY_COMPILE([ #include #include ],, have_gdiplus=yes,have_gdiplus=no) if test "$have_gdiplus" = "yes" ; then MLIMGLOADER_LIB=gdiplus elif test "$have_gdk_pixbuf2" = "yes" -o "$have_gdk_pixbuf1" = "yes" ; then MLIMGLOADER_LIB=gdk-pixbuf else MLIMGLOADER_LIB=none fi AC_SUBST(MLIMGLOADER_LIB) if test "$have_ft" = "yes"; then EMOJI_CFLAGS="-DUSE_FREETYPE_EMOJI $FT_CFLAGS_ORIGINAL" EMOJI_LIBS="$FT_LIBS" AC_SUBST(EMOJI_CFLAGS) AC_SUBST(EMOJI_LIBS) fi fi ;; registobmp) if test "$have_sdl2" = "yes"; then SDL_CFLAGS=$SDL2_CFLAGS SDL_LIBS=$SDL2_LIBS else PKG_CHECK_MODULES(SDL, sdl2, have_sdl2=yes, have_sdl2=no) if test "$have_sdl2" != "yes" ; then PKG_CHECK_MODULES(SDL, sdl, have_sdl=yes, have_sdl=no) fi fi if test "$have_sdl2" = "yes"; then PKG_CHECK_MODULES(SDLTTF, SDL2_ttf, have_sdlttf=yes, have_sdlttf=no) elif test "$have_sdl" = "yes"; then PKG_CHECK_MODULES(SDLTTF, SDL_ttf, have_sdlttf=yes, have_sdlttf=no) else continue fi if test "$have_sdlttf" = "yes"; then SDLTTF_CFLAGS="$SDLTTF_CFLAGS -DUSE_SDLTTF" fi SDL_CFLAGS="$SDL_CFLAGS $SDLTTF_CFLAGS" SDL_LIBS="$SDL_LIBS $SDLTTF_LIBS" AC_SUBST(SDL_CFLAGS) AC_SUBST(SDL_LIBS) OUTPUT_FILES="tool/registobmp/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/registobmp ${MAKE_DIRS2}" tools_result="$tools_result $tool" ;; mlfc) if test "$gui" != "win32" -a "$gui" != "quartz" ; then if test "$have_fc" = "yes" ; then OUTPUT_FILES="tool/mlfc/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/mlfc ${MAKE_DIRS2}" tools_result="$tools_result $tool" fi fi ;; *) echo "${tool} is unknown tool." ;; esac done if test "$gui" = "win32"; then OUTPUT_FILES="tool/servman/Makefile ${OUTPUT_FILES}" MAKE_DIRS2="tool/servman ${MAKE_DIRS2}" tools_result="$tools_result servman" fi # # --- libltdl --- # AC_ARG_WITH(libltdl, [ --with-libltdl@<:@=PREFIX@:>@ load modules with libltdl @<:@default=without@:>@],, [with_libltdl=no]) # We don't check here wheter libltdl is installed. (See pobl/src/configure.in) # # --- Xdnd --- # AC_ARG_ENABLE(dnd, [ --disable-dnd dnd @<:@default=enabled@:>@], dnd=$enable_dnd, dnd="yes") if test "$dnd" = "no" ; then DND_CFLAGS="-DDISABLE_XDND" fi AC_SUBST(DND_CFLAGS) DL_LIBS_IM="" # # --- kbd --- # AC_ARG_ENABLE(kbd, [ --disable-kbd input method for Arabic and Indic @<:@default=enabled@:>@], kbd=$enable_kbd) if test "$enable_shared" = "no" ; then kbd="no" fi if test "$kbd" != "no" ; then MAKE_DIRS2="inputmethod/kbd ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/kbd/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/kbd/libim-kbd.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result kbd" fi # # --- uim --- # AC_ARG_ENABLE(uim, [ --disable-uim uim @<:@default=enabled@:>@], uim=$enable_uim) if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then uim="no" fi if test "x$uim" != xno ; then PKG_CHECK_MODULES(UIM, uim >= 1.0.0, have_uim=yes, have_uim=no) if test "x$have_uim" = xyes ; then MAKE_DIRS2="inputmethod/uim ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/uim/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/uim/libim-uim.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result uim" fi fi AC_SUBST(UIM_CFLAGS) AC_SUBST(UIM_LIBS) # # --- IIIMF --- # AC_ARG_ENABLE(iiimf, [ --disable-iiimf IIIMF (Experimental) @<:@default=enabled@:>@], iiimf=$enable_iiimf) if test "x$iiimf" != xno ; then PKG_CHECK_MODULES(IIIMCF, iiimf-lib-client, have_iiimcf=yes, have_iiimcf=no) if test "x$have_iiimcf" = xyes ; then found_iiimcf=yes elif test -d /usr/lib/im/lib ; then LIBS="$LIBS -L/usr/lib/im/lib" AC_CHECK_LIB(iiimcf, iiimcf_create_context, [ found_iiimcf=yes IIIMCF_CFLAGS="-I/usr/lib/im/include" IIIMCF_LIBS="-L/usr/lib/im/lib -liiimcf" ]) else AC_CHECK_LIB(iiimcf, iiimcf_create_context, [ found_iiimcf=yes IIIMCF_CFLAGS="-I/usr/include/iiim" IIIMCF_LIBS="-liiimcf" ]) fi if test "x$found_iiimcf" = xyes ; then IM_CFLAGS="$IM_CFLAGS -DUSE_IIIMF" MAKE_DIRS2="inputmethod/iiimf ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/iiimf/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then echo "" echo "** ERROR **" echo " IIIMF plugin couldn't be used with libltdl." echo "" exit 1 else input_methods_result="$input_methods_result IIIMF" fi AC_CHECK_LIB(iiimcf, iiimcf_create_hotkey_notify_event, [ IIIMCF_CFLAGS="$IIIMCF_CFLAGS -DHAVE_HOTKEY_NOTFY_EVENT" ]) AC_CHECK_LIB(iiimcf, iiimcf_create_aux_getvalues_event, [ IIIMCF_CFLAGS="$IIIMCF_CFLAGS -DHAVE_AUX_GETVALUES_EVENT" ]) fi fi AC_SUBST(IIIMCF_CFLAGS) AC_SUBST(IIIMCF_LIBS) # # --- m17n library --- # AC_ARG_ENABLE(m17nlib, [ --disable-m17nlib m17n library @<:@default=enabled@:>@], m17nlib=$enable_m17nlib) if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then m17nlib="no" fi if test "x$m17nlib" != xno ; then AC_CHECK_PROG(m17n_config, m17n-config, yes, no) if test "$m17n_config" = "yes"; then M17NLIB_LIBS=`m17n-config --libs` M18NLIB_CFLAGS=`m17n-config --cflags` m17nlib=yes else PKG_CHECK_MODULES(M17NLIB, m17n-shell, m17nlib=yes, m17nlib=no) fi if test "$m17nlib" = "yes"; then m17n_saved_libs="$LIBS" LIBS="$LIBS $M17NLIB_LIBS" AC_CHECK_LIB(m17n, minput_open_im, [ MAKE_DIRS2="inputmethod/m17nlib ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/m17nlib/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/m17nlib/libim-m17nlib.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result m17nlib" ]) LIBS="$m17n_saved_libs" fi fi AC_SUBST(M17NLIB_CFLAGS) AC_SUBST(M17NLIB_LIBS) # # --- IBUS --- # AC_ARG_ENABLE(ibus, [ --disable-ibus IBUS @<:@default=enabled@:>@], ibus=$enable_ibus) if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then ibus="no" fi if test "x$ibus" != "xno" ; then PKG_CHECK_MODULES(IBUS, ibus-1.0 >= 1.3.0, has_ibus=yes, has_ibus=no) if test "x$has_ibus" = xyes ; then MAKE_DIRS2="inputmethod/ibus ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/ibus/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/ibus/libim-ibus.la ${DL_LIBS_IM}" fi if test "$with_pthread" != "no" ; then # NetBSD doesn't allow shared libraries to link libpthread # without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi input_methods_result="$input_methods_result iBus" fi fi AC_SUBST(IBUS_CFLAGS) AC_SUBST(IBUS_LIBS) # # --- FCITX --- # AC_ARG_ENABLE(fcitx, [ --disable-fcitx FCITX @<:@default=enabled@:>@], fcitx=$enable_fcitx) if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then fcitx="no" fi if test "x$fcitx" != "xno" ; then PKG_CHECK_MODULES(FCITX, Fcitx5GClient, has_fcitx=yes, has_fcitx=no) if test "x$has_fcitx" = xyes ; then PKG_CHECK_MODULES(FCITXUTILS, Fcitx5Utils, has_fcitx=yes, has_fcitx=no) fi fcitx_result="fcitx" if test "x$has_fcitx" = xno ; then PKG_CHECK_MODULES(FCITX, fcitx-gclient, has_fcitx=yes, has_fcitx=no) else FCITX_CFLAGS="$FCITX_CFLAGS $FCITXUTILS_CFLAGS -DUSE_FCITX5" # 'pkg-config Fcitx5GClient --libs' doesn't output -lFcitx5GClient # (fcitx5-gtk-5.0.6 on archlinux) # fcitx5-gtk-5.0.7 fixed it. if test "`echo $FCITX_LIBS|grep lFcitx5GClient`" = ""; then FCITX_LIBS="$FCITX_LIBS -lFcitx5GClient" fi fcitx_result="fcitx5" fi if test "x$has_fcitx" = xyes ; then MAKE_DIRS2="inputmethod/fcitx ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/fcitx/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/fcitx/libim-fcitx.la ${DL_LIBS_IM}" fi if test "$with_pthread" != "no" ; then # NetBSD doesn't allow shared libraries to link libpthread # without linking it to executables. case "${host_os}" in netbsd*) PTHREAD_LIB="-lpthread" ;; esac fi input_methods_result="$input_methods_result $fcitx_result" fi fi AC_SUBST(FCITX_CFLAGS) AC_SUBST(FCITX_LIBS) # # --- SCIM --- # AC_ARG_ENABLE(scim, [ --disable-scim SCIM @<:@default=enabled@:>@], scim=$enable_scim) if test "$enable_shared" = "no" -o "$gui" = "quartz" ; then scim="no" fi if test "x$scim" != "xno" -a "$gui" != "fb" -a "$gui" != "console" ; then PKG_CHECK_MODULES(SCIM, scim >= 1.4.0, has_scim=yes , has_scim=no) if test "x$has_scim" = xyes ; then MAKE_DIRS2="inputmethod/scim ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/scim/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/scim/libim-scim.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result SCIM" fi fi AC_SUBST(SCIM_CFLAGS) AC_SUBST(SCIM_LIBS) # # --- CANNA --- # AC_ARG_ENABLE(canna, [ --disable-canna CANNA @<:@default=enabled@:>@], canna=$enable_canna) if test "$enable_shared" = "no" -o "$ml_cv_is_posix" = "no" ; then canna="no" fi if test "x$canna" != "xno" ; then AC_CHECK_HEADER(canna/jrkanji.h, has_canna=yes, has_canna=no) if test "x$has_canna" = xyes ; then CANNA_LIBS="-lcanna" MAKE_DIRS2="inputmethod/canna ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/canna/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/canna/libim-canna.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result canna" fi fi AC_SUBST(CANNA_CFLAGS) AC_SUBST(CANNA_LIBS) # # --- WNN --- # AC_ARG_ENABLE(wnn, [ --disable-wnn WNN @<:@default=enabled@:>@], wnn=$enable_wnn) if test "$enable_shared" = "no" -o "$ml_cv_is_posix" = "no" ; then wnn="no" fi if test "x$wnn" != "xno" ; then AC_CHECK_HEADER(wnn/jllib.h, has_wnn=yes, has_wnn=no) if test "x$has_wnn" = xyes ; then WNN_LIBS="-ljd" if test -d /usr/pkg/share/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/pkg/share\\\"" elif test -d /usr/local/share/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/local/share\\\"" elif test -d /usr/local/lib/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/local/lib\\\"" elif test -d /usr/share/wnn ; then WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/share\\\"" else WNN_CFLAGS="-DWNNLIBDIR=\\\"/usr/lib\\\"" fi MAKE_DIRS2="inputmethod/wnn ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/wnn/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/wnn/libim-wnn.la ${DL_LIBS_IM}" fi input_methods_result="$input_methods_result wnn" fi fi AC_SUBST(WNN_CFLAGS) AC_SUBST(WNN_LIBS) # # --- SKK --- # AC_ARG_ENABLE(skk, [ --disable-skk SKK @<:@default=enabled@:>@], skk=$enable_skk) if test "$enable_shared" != "no" -a "$skk" != "no"; then MAKE_DIRS2="inputmethod/skk ${MAKE_DIRS2}" OUTPUT_FILES="inputmethod/skk/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != xno ; then DL_LIBS_IM="-dlopen \$(top_builddir)/inputmethod/skk/libim-skk.la ${DL_LIBS_IM}" fi if test "$ml_cv_is_posix" = "no" ; then SKK_LIBS="-lwsock32 -lws2_32" fi input_methods_result="$input_methods_result skk" fi AC_SUBST(SKK_LIBS) if test "x$input_methods_result" != x ; then IM_CFLAGS="-DUSE_IM_PLUGIN" fi AC_SUBST(IM_CFLAGS) AC_SUBST(DL_LIBS_IM) # # --- scrollbar plugins --- # DL_LIBS_SB="" SB_CFLAGS="" scrollbars="sample,extra,pixmap_engine" AC_ARG_WITH(scrollbars, [ --with-scrollbars@<:@=ARG@:>@ scrollbar plugins (sample, extra, pixmap_engine) @<:@default=sample,extra,pixmap_engine@:>@], [ # If given --without-scrollbars or --with-scrollbars with no args. if test "${with_scrollbars}" = "no" ; then scrollbars="" elif test "${with_scrollbars}" != "yes" ; then scrollbars=${with_scrollbars} fi ]) if test "$enable_shared" != "no" ; then scrollbars=`echo ${scrollbars} | sed 's/,/ /g'` else scrollbars= fi for scrollbar in ${scrollbars} ; do case ${scrollbar} in sample) if test "$gui" = "xlib" -o "$gui" = "win32"; then MAKE_DIRS2="scrollbar/sample ${MAKE_DIRS2}" OUTPUT_FILES="scrollbar/sample/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then DL_LIBS_SB="-dlopen \$(top_builddir)/scrollbar/sample/libsample.la ${DL_LIBS_SB}" fi scrollbars_result="$scrollbars_result $scrollbar" fi ;; extra) if test "$gui" = "xlib" ; then MAKE_DIRS2="contrib/scrollbar/extra ${MAKE_DIRS2}" OUTPUT_FILES="contrib/scrollbar/extra/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then for name in athena next motif mozmodern ; do DL_LIBS_SB="-dlopen \$(top_builddir)/contrib/scrollbar/extra/lib$name.la ${DL_LIBS_SB}" done fi scrollbars_result="$scrollbars_result $scrollbar" fi ;; pixmap_engine) if test "x$allow_undefined_flag" = "xunsupported" ; then echo "" echo "** ERROR **" echo "pixmap_engine has undefined symbols. $host_os does NOT allow it." echo "" elif test "$gui" = "xlib" -a "$image" != "no"; then if test "$have_gdk_pixbuf1" = "yes" -o "$have_gdk_pixbuf2" = "yes" ; then MAKE_DIRS2="contrib/scrollbar/pixmap_engine ${MAKE_DIRS2}" OUTPUT_FILES="contrib/scrollbar/pixmap_engine/Makefile contrib/scrollbar/pixmap_engine/sample3/Makefile ${OUTPUT_FILES}" if test "x$with_libltdl" != "xno" ; then DL_LIBS_SB="-dlopen \$(top_builddir)/contrib/scrollbar/pixmap_engine/libpixmap_engine.la ${DL_LIBS_SB}" fi SB_CFLAGS="-DSUPPORT_PIXMAP_ENGINE" scrollbars_result="$scrollbars_result $scrollbar" else echo "" echo "** ERROR **" echo "To use pixmap_engine for scrollbar, you need gdk-pixbuf library." echo "" fi fi ;; *) echo "${scrollbar} is unknown scrollbar." ;; esac done # for scrollbar in ${scrollbars} AC_SUBST(SB_CFLAGS) AC_SUBST(DL_LIBS_SB) # # --- module related stuffs --- # # undefined symbol AC_MSG_CHECKING([for undefined symbol]) if test "x$allow_undefined_flag" = "xunsupported" ; then AC_MSG_RESULT([not supported]) NO_UNDEFINED_FLAG="-no-undefined" else AC_MSG_RESULT(supported) NO_UNDEFINED_FLAG="" fi AC_SUBST(NO_UNDEFINED_FLAG) if test "x$with_libltdl" != "xno" ; then DL_SELF="-dlopen self" fi AC_SUBST(DL_SELF) AC_ARG_ENABLE(vt52, [ --enable-vt52 enable VT52 emulation @<:@default=disabled@:>@], vt52=$enable_vt52, vt52="no") if test "$vt52" = "yes" ; then VT52_CFLAGS="-DUSE_VT52" fi AC_SUBST(VT52_CFLAGS) AC_ARG_ENABLE(optimize_redrawing, [ --enable-optimize-redrawing optimize redrawing a line @<:@default=disabled@:>@], optimize_redrawing=$enable_optimize_redrawing, optimize_redrawing="no") if test "$optimize_redrawing" = "yes" ; then CFLAGS="$CFLAGS -DOPTIMIZE_REDRAWING" fi # XXX(maybe not portable) if test "${USE_NLS}" = "yes" ; then AC_CHECK_LIB(intl,gettext, [ INTL_LIBS="-lintl" ]) fi AC_SUBST(INTL_LIBS) # Because pic object files are fat, non-pic ones are linked unless --disable-static # option is specified. if test "$enable_static" = "no" ; then MAIN_OBJ_SUFFIX=":.o=.lo" fi AC_SUBST(MAIN_OBJ_SUFFIX) CHANGE_DATE=`head -n 1 ${top_srcdir-$srcdir}/ChangeLog | sed -n 's/^\(@<:@0-9@:>@*-@<:@0-9@:>@*-@<:@0-9@:>@*\).*$/\1/p'` AC_SUBST(CHANGE_DATE) OUTPUT_FILES="main/version.h ${OUTPUT_FILES}" if test "${SUBDIRS}" != "" ; then # for baselib and encodefilter ac_configure_args="${ac_configure_args} --without-funcs-mlterm-unuse" # for gui ac_configure_args=`echo ${ac_configure_args} | sed 's/--with-gui=@<:@A-Za-z0-9,@:>@*/--with-gui=subdir/g'` if test "$dl_ctl" != "no"; then ac_configure_args="${ac_configure_args} --disable-ind --disable-fribidi" fi ac_configure_args="${ac_configure_args} --without-tools" AC_CONFIG_SUBDIRS(${SUBDIRS}) fi MAKE_DIRS2="vtemu vtemu/libctl uitoolkit/libtype uitoolkit main man etc ${MAKE_DIRS2}" OUTPUT_FILES="Makefile vtemu/Makefile vtemu/libctl/Makefile uitoolkit/libtype/Makefile uitoolkit/Makefile main/Makefile man/Makefile etc/Makefile java/Makefile libvterm/Makefile ${OUTPUT_FILES}" AC_ARG_ENABLE(ind, [ --disable-ind libind @<:@default=enabled@:>@], ind=$enable_ind, ind="yes") if test "$gui" = "quartz" -o "$gui" = "console"; then IND_CFLAGS="-DNOT_CONVERT_TO_ISCII" ind="no" fi if test "$ind" = "yes" ; then IND_CFLAGS='-I${top_builddir}/libind' IND_LIBS='${top_builddir}/libind/libind.a' MAKE_DIRS2="libind ${MAKE_DIRS2}" OUTPUT_FILES="libind/Makefile ${OUTPUT_FILES}" if test "$dl_ctl" = "yes" ; then CTL_LIBS="libctl${TRUECOLOR_TAG}_iscii.la ${CTL_LIBS}" else CTL_CFLAGS="-DUSE_IND ${CTL_CFLAGS}" CTL_LIBS="libctl${TRUECOLOR_TAG}_iscii.a ${CTL_LIBS}" CTL_LIBS_FOR_PROG="../vtemu/libctl/libctl${TRUECOLOR_TAG}_iscii.a ${CTL_LIBS_FOR_PROG}" fi fi AC_SUBST(IND_LIBS) AC_SUBST(IND_CFLAGS) AC_SUBST(CTL_LIBS) AC_SUBST(CTL_LIBS_FOR_PROG) AC_ARG_ENABLE(brlapi, [ --enable-brlapi libbrlapi @<:@default=disabled@:>@], brlapi=$enable_brlapi, brlapi="no") if test "$brlapi" = "yes" ; then BRLAPI_CFLAGS='-DUSE_BRLAPI' BRLAPI_LIBS='-lbrlapi' if test "$host_os" != "haiku"; then INSTALL_OPT="-m 4755 -o root" fi fi AC_SUBST(BRLAPI_LIBS) AC_SUBST(BRLAPI_CFLAGS) AC_ARG_ENABLE(daemon, [ --disable-daemon daemon mode @<:@default=enabled@:>@], daemon=$enable_daemon, daemon="yes") if test "$daemon" = "no" ; then DAEMON_CFLAGS="-DNO_DAEMON" fi AC_SUBST(DAEMON_CFLAGS) AC_ARG_ENABLE(split, [ --disable-split split screen @<:@default=enabled@:>@], split=$enable_split, split="yes") if test "$split" = "no" ; then SPLIT_CFLAGS="-DNO_SPLIT" fi AC_SUBST(SPLIT_CFLAGS) AC_ARG_ENABLE(zmodem, [ --disable-zmodem zmodem @<:@default=enabled@:>@], zmodem=$enable_zmodem, zmodem="yes") if test "$zmodem" = "no" ; then TRANSFER_CFLAGS="-DNO_ZMODEM" else TRANSFER_LIBS="libzmodem.la" fi AC_SUBST(TRANSFER_CFLAGS) AC_SUBST(TRANSFER_LIBS) AC_SUBST(PTHREAD_LIB) AC_SUBST(MAKE_DIRS2) if test "${MAKE_DIRS2}" != "" ; then mkdir -p ${MAKE_DIRS2} fi if test "$CONFIG_SUBDIR_LIBS" = "internal"; then # # ====> check for encodefilter <=== # mef_top_srcdir_suffix="/encodefilter" mef_top_builddir_suffix="/.." AC_SUBST(mef_top_srcdir_suffix) AC_SUBST(mef_top_builddir_suffix) AC_ARG_WITH(map-table, [ --without-map-table mapping table @<:@default=with@:>@], map_table=$with_map_table,map_table="yes") if test "$map_table" = "no" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DREMOVE_MAPPING_TABLE" fi AC_ARG_WITH(prop-table, [ --without-prop-table property table @<:@default=with@:>@], prop_table=$with_prop_table,prop_table="yes") if test "$prop_table" = "no" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DREMOVE_PROPERTY_TABLE" fi AC_ARG_WITH(iconv, [ --with-iconv use iconv for charset conversion @<:@default=without@:>@], iconv=$with_iconv,iconv="no") if test "$iconv" = "yes" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DUSE_ICONV" fi AC_ARG_ENABLE(dl-table, [ --disable-dl-table dynamic loading table @<:@default=enable@:>@], dl_table=$enable_dl_table, [ if test "$iconv" = "yes"; then dl_table="no" else dl_table="yes" fi ]) if test "$enable_shared" = "no" ; then dl_table="no" fi if test "$dl_table" = "no" ; then TABLE_CFLAGS="${TABLE_CFLAGS} -DNO_DYNAMIC_LOAD_TABLE" MAKE_DIRS="src" OUTPUT_FILES="${OUTPUT_FILES} encodefilter/Makefile encodefilter/src/Makefile" else MAKE_DIRS="src module" OUTPUT_FILES="${OUTPUT_FILES} encodefilter/Makefile encodefilter/src/Makefile encodefilter/module/Makefile" fi AC_SUBST(TABLE_CFLAGS) AC_SUBST(MAKE_DIRS) if test "${MAKE_DIRS}" != "" ; then mkdir -p ${MAKE_DIRS} fi # # --- check for undefined symbol --- # if test "x$allow_undefined_flag" = "xunsupported" ; then # link ef_char.lo to module/*.dll to resolve addresses in creating dll. EF_CHAR_LO="../src/ef_char.lo" else EF_CHAR_LO="" fi AC_SUBST(EF_CHAR_LO) # # ====> check for baselib <=== # pobl_top_srcdir_suffix="/baselib" pobl_top_builddir_suffix="/.." AC_SUBST(pobl_top_srcdir_suffix) AC_SUBST(pobl_top_builddir_suffix) AC_CONFIG_HEADER(baselib/src/bl_config.h) #detect glibc AC_TRY_COMPILE([#include ], [ #ifdef __GLIBC__ #else #error int boil\[-1\]; #endif ], AC_DEFINE(HAVE_GNU_SOURCE)) # # --- Checks for header files --- # # NOTE: if --with-libtool is specified, stdc header isn't detected. AC_HEADER_STDC AC_CHECK_HEADERS(langinfo.h dlfcn.h dl.h stropts.h sys/stropts.h stdint.h windows.h errno.h stdint.h) # # --- Checks for library functions --- # AC_CHECK_FUNCS(strsep fgetln basename isastream seteuid setegid geteuid getegid setsid snprintf usleep setenv unsetenv flock getuid getgid getpwuid recvmsg setpgid socketpair killpg gettimeofday) AC_FUNC_ALLOCA AC_C_CONST AC_C_BIGENDIAN AC_SYS_LARGEFILE # for OpenServer 6.0.0 AC_CHECK_HEADER(sys/bitypes.h, [ ac_includes_default="\ $ac_includes_default #include " HAVE_SYS_BITYPES_H=1 AC_DEFINE(HAVE_SYS_BITYPES_H) ]) AC_CHECK_TYPE(u_char,unsigned char) AC_CHECK_TYPE(u_short,unsigned short) AC_CHECK_TYPE(u_int,unsigned int) AC_CHECK_TYPE(u_long,unsigned long) AC_CHECK_TYPE(u_int8_t,unsigned char) AC_CHECK_TYPE(u_int16_t,unsigned short) AC_CHECK_TYPE(u_int32_t,unsigned int) AC_CHECK_TYPE(u_int64_t,unsigned long) AC_CHECK_TYPE(int8_t,char) AC_CHECK_TYPE(int16_t,short) AC_CHECK_TYPE(int32_t,int) AC_CHECK_TYPE(int64_t,long) AC_CHECK_TYPE(ssize_t,int) AC_TYPE_MODE_T AC_TYPE_PID_T AC_TYPE_UID_T AC_TYPE_OFF_T AC_TYPE_SIZE_T # # --- Platform dependent stuff --- # bl_cv_cygwin=no bl_cv_mingw=no bl_cv_win32=no case "${host_os}" in cygwin*) bl_cv_cygwin=yes case "${CC} ${CFLAGS}" in *mno-cygwin* | *-mingw*) bl_cv_win32=yes AC_DEFINE(USE_WIN32API,,"USE_WIN32API") ;; *) ;; esac ;; mingw*) bl_cv_mingw=yes if test ! -f "/lib/libmsys-1.0.dll.a" ; then case "${lt_cv_path_LD}" in *-msys*) ;; *) bl_cv_win32=yes AC_DEFINE(USE_WIN32API,,"USE_WIN32API") ;; esac fi ;; *) ;; esac # # --- socklen_t --- # # NOTE: #define _BSDTYPES_DEFINED is necessary because AC_TRY_COMPILE defines # u_char, u_short and so on before #include . # AC_CACHE_CHECK(for socklen_t, bl_cv_socklen_ident, [AC_TRY_COMPILE( [ #include #include #include ], [ socklen_t len ; ], bl_cv_socklen_ident=yes, [AC_TRY_COMPILE( [ #define _BSDTYPES_DEFINED #include ], [ socklen_t len ; ], bl_cv_socklen_ident=yes, bl_cv_socklen_ident=no)])]) if test "${bl_cv_socklen_ident}" = "no" ; then AC_DEFINE(socklen_t, unsigned int, "socklen_t") fi # # --- Check if concatenation of string literals with __FUNCTION__ is supported. --- # AC_CACHE_CHECK(for __FUNCTION__, bl_cv_func_ident,[ AC_TRY_COMPILE(, [ char * p = "[" __FUNCTION__ "]" ; ] , bl_cv_func_ident=yes,bl_cv_func_ident=no)]) if test "${bl_cv_func_ident}" = "yes" ; then AC_DEFINE(CONCATABLE_FUNCTION,,"CONCATABLE_FUNCTION") fi # # --- Check for libxpg4 (for FreeBSD) --- # AC_CHECK_FUNCS(setlocale) if test "x$ac_cv_func_setlocale" = xno ; then AC_CHECK_LIB(xpg4, setlocale, XPG4_LIBS=-lxpg4) AC_SUBST(XPG4_LIBS) fi # # --- Checks for dynamic linking loader --- # DL_LOADER=none DL_LIBS= DL_CFLAGS= # lt_dlopenext in libltdl AC_ARG_WITH(libltdl, [ --with-libltdl@<:@=PREFIX@:>@ load modules with libltdl @<:@default=without@:>@],, [with_libltdl=no]) if test "x$with_libltdl" != "xno" ; then if test "x$with_libltdl" != "xyes"; then DL_CFLAGS="-I$with_libltdl/include" bl_libltdl_libdir="-L$with_libltdl/lib" fi bl_ldflags_save="$LDFLAGS" LDFLAGS="$LDFLAGS $bl_libltdl_libdir" AC_CHECK_LIB(ltdl, lt_dlopenext, [ DL_LOADER=ltdl DL_LIBS="$bl_libltdl_libdir -lltdl" ],[ echo "" echo "Could not find libltdl" echo "" exit 1]) LDFLAGS="$bl_ldflags_save" fi # lt_cv_dlopen is set by AC_LIBTOOL_DLOPEN if test "$DL_LOADER" = none ; then case "${lt_cv_dlopen}" in # LoadLibrary (Windows) LoadLibrary) DL_LOADER=win32 ;; # shl_load (HP-UX) shl_load) DL_LOADER=dld ;; # dlopen (UNIX98) dlopen) DL_LOADER=dl ;; # What is dld_link? Does anybody know? dld_link) DL_LOADER=none ;; *) DL_LOADER=none ;; esac DL_LIBS="${DL_LIBS} ${lt_cv_dlopen_libs}" if test "$DL_LOADER" = none ; then # NSLinkModule (darwin) AC_CHECK_FUNC(NSLinkModule, [ DL_LOADER=dyld DL_LIBS= ], []) fi # cygwin hack # (AC_LIBTOOL_DLOPEN tell lt_cv_dlopen == dlopen but use bl_dlcfn_win32.c.) # On msys2, use dlopen because bl_dlfcn_win32 doesn't work correctly. if test "$bl_cv_cygwin" = "yes"; then DL_LOADER=win32 fi fi AC_SUBST(DL_LOADER) AC_SUBST(DL_LIBS) AC_SUBST(DL_CFLAGS) if test "$DL_LOADER" = none ; then AC_DEFINE(DLFCN_NONE,,"DLFCN_NONE") fi # # --- pty check --- # AC_MSG_CHECKING(for pty/tty type) if test "$bl_cv_win32" = "yes" ; then bl_cv_pty=none elif test "$bl_cv_mingw" = "yes" ; then bl_cv_pty=streams elif test "$host" = "$build" ; then AC_CHECK_FUNC(posix_openpt, [AC_RUN_IFELSE([AC_LANG_PROGRAM([#include ], [return posix_openpt(O_RDWR | O_NOCTTY) == -1;])], [ AC_DEFINE(HAVE_POSIX_OPENPT,,"HAVE_POSIX_OPENPT") bl_cv_pty=streams ], [bl_cv_pty=bsd])], [bl_cv_pty=bsd]) if test "$bl_cv_pty" = "bsd" ; then AC_RUN_IFELSE( [AC_LANG_PROGRAM([#include ], [return open( "/dev/ptmx", O_RDWR | O_NOCTTY, 0) == -1;])], [bl_cv_pty=streams]) fi else # cross compiling AC_CHECK_FUNC(posix_openpt, [ AC_DEFINE(HAVE_POSIX_OPENPT,,"HAVE_POSIX_OPENPT") bl_cv_pty=streams ], [bl_cv_pty=bsd]) fi AC_ARG_ENABLE(pty_helper, [ --enable-pty-helper use pty helper @<:@default=disabled@:>@], pty_helper=$enable_pty_helper) if test "$pty_helper" = yes ; then if test "$bl_cv_pty" = streams ; then bl_cv_pty=helper else echo "" echo "** WARNING **" echo " pty helper is not supported in bsd-style pty system." echo "" fi fi AC_MSG_RESULT($bl_cv_pty) PTY_NAME="${bl_cv_pty}" AC_SUBST(PTY_NAME) # # --- checks for utmp --- # AC_ARG_WITH(utmp, [ --with-utmp@<:@=ARG@:>@ utmp (utempter,sysv,login,bsd,none)], utmp_type=$with_utmp) UTMP_NAME= UTMP_LIBS= if test "$bl_cv_pty" = helper -o "$bl_cv_mingw" = yes -o "$bl_cv_cygwin" = yes -o "$host_os" = "msys" -o "$host_os" = "haiku"; then UTMP_NAME=none UTMP_LIBS= fi # libutempter if test "$utmp_type" = "" -o "$utmp_type" = "utempter"; then if test -z "$UTMP_NAME"; then AC_CHECK_LIB(utempter, utempter_add_record, [ UTMP_NAME=utmper UTMP_LIBS="-lutempter" UTMP_CFLAGS="-DUTEMPTER_NEW_API" ], []) fi if test -z "$UTMP_NAME"; then # FreeBSD AC_CHECK_LIB(ulog, utempter_add_record, [ UTMP_NAME=utmper UTMP_LIBS="-lulog" UTMP_CFLAGS="-DUTEMPTER_NEW_API" ], []) fi if test -z "$UTMP_NAME" ; then AC_CHECK_LIB(utempter, addToUtmp, [ UTMP_NAME=utmper UTMP_LIBS="-lutempter -lutil" ]) fi fi # setutxent() (SysV) if test "$utmp_type" = "" -o "$utmp_type" = "sysv"; then if test -z "$UTMP_NAME"; then AC_CHECK_FUNC(setutxent, [ UTMP_NAME=sysv UTMP_LIBS= UTMP_CFLAGS=-DUSE_UTMPX ], []) fi # setutent() (SysV) if test -z "$UTMP_NAME"; then AC_CHECK_FUNC(setutent, [ UTMP_NAME=sysv UTMP_LIBS= ], []) fi fi # libutil if test "$utmp_type" = "" -o "$utmp_type" = "login"; then if test -z "$UTMP_NAME" ; then AC_CHECK_LIB(util, logout, [ UTMP_NAME=login UTMP_LIBS=-lutil ], []) fi fi # other (BSD) if test "$utmp_type" = "" -o "$utmp_type" = "bsd"; then if test -z "$UTMP_NAME" ; then UTMP_NAME=bsd UTMP_LIBS= fi fi if test -z "$UTMP_NAME" ; then UTMP_NAME=none UTMP_LIBS= fi if test "$UTMP_NAME" != "none"; then # for vtemu/vt_pty_unix.c UTMP_CFLAGS="$UTMP_CFLAGS -DUSE_UTMP" fi AC_SUBST(UTMP_NAME) AC_SUBST(UTMP_LIBS) AC_SUBST(UTMP_CFLAGS) AC_DEFINE(REMOVE_FUNCS_MLTERM_UNUSE,,"REMOVE_FUNCS_MLTERM_UNUSE") # # --- check for malloc --- # if test "$host" = "$build"; then AC_TRY_RUN( [ #include int main() { return calloc(8, ((1 << (sizeof(size_t) * 8 - 1)) + 1)) ? 1 : 0 ; } ], AC_DEFINE(CALLOC_CHECK_OVERFLOW)) fi OUTPUT_FILES="${OUTPUT_FILES} baselib/Makefile baselib/src/Makefile" else # CONFIG_SUBDIR_LIBS # ./configure at subdirs finished. if test -d baselib; then utmp_none_obj=`grep bl_utmp_none.o baselib/src/Makefile` elif test -d ../../baselib; then utmp_none_obj=`grep bl_utmp_none.o ../../baselib/src/Makefile` fi if test "$utmp_none_obj" = ""; then UTMP_CFLAGS="-DUSE_UTMP" else # for following "$UTMP_NAME" != "none" UTMP_NAME="none" fi fi # CONFIG_SUBDIR_LIBS AC_OUTPUT(${OUTPUT_FILES}) AC_ARG_ENABLE(utmp-suid, [ --enable-utmp-suid install mlterm with SUID or SGID for utmp @<:@default=disabled@:>@], utmp_suid=$enable_utmp_suid) if test "$INSTALL_OPT" = ""; then # SUID is not set to mlterm on MacOSX/Quartz. if test "$utmp_suid" = "yes" -a "$UTMP_NAME" != "none" -a "$gui" != "quartz"; then has_utmp=`grep utmp /etc/group 2>/dev/null` if test "$has_utmp" ; then INSTALL_OPT="-m 2755 -g utmp" else INSTALL_OPT="-m 4755 -o root" fi else INSTALL_OPT="-m 755" fi if test "$gui" = "fb" ; then INSTALL_OPT="-m 4755 -o root" fi fi cat main/Makefile | sed "s/@INSTALL_OPT@/$INSTALL_OPT/" | sed "s/@UTMP_CFLAGS@/$UTMP_CFLAGS/" > main/Makefile.new mv main/Makefile.new main/Makefile cat vtemu/Makefile | sed "s/@UTMP_CFLAGS@/$UTMP_CFLAGS/" > vtemu/Makefile.new mv vtemu/Makefile.new vtemu/Makefile # Remove 'as_fn_exit 0' sed '$d' ${CONFIG_STATUS} > ${CONFIG_STATUS}.new mv ${CONFIG_STATUS}.new ${CONFIG_STATUS} chmod 755 ${CONFIG_STATUS} cat >>$CONFIG_STATUS < main/Makefile.new mv main/Makefile.new main/Makefile cat vtemu/Makefile | sed "s/@UTMP_CFLAGS@/$UTMP_CFLAGS/" > vtemu/Makefile.new mv vtemu/Makefile.new vtemu/Makefile as_fn_exit 0 EOF # configuration result echo echo echo "Mlterm was configured as follows" echo echo "Installation path prefix : $prefix" dnl echo "Character mapping table : " dnl echo "Character property table : " echo "Build shared libraries : $enable_shared" echo "Build static libraries : $enable_static" dnl echo "Optimization for redrawing a line : $optimize_redrawing" if test "$fbtype" = ""; then echo "GUI toolkit : $gui" else echo "GUI toolkit : $gui ($fbtype)" fi echo "BiDi rendering (Fribidi) : $have_fribidi" echo "Indic rendering : $ind" if test "$OT_LAYOUT_OBJ" = "hb.o"; then echo "OpenType Layout : yes (harfbuzz)" elif test "$OT_LAYOUT_OBJ" = "otf.o"; then echo "OpenType Layout : yes (libotf)" elif test "$OT_LAYOUT_OBJ" = "uniscribe.o"; then echo "OpenType Layout : yes (uniscribe)" else echo "OpenType Layout : no" fi echo "External tools :$tools_result" echo "Image processing : $image" echo "Built-in image library : $with_imagelib" echo "utmp support : $utmp" if test "$gui" = "fb" -o "$gui" = "wayland" -o "$gui" = "sdl2"; then if test "$have_ft" = "yes"; then if test "$fontconfig" = "yes"; then echo "Supported font formats : pcf ttf(+fontconfig)" else echo "Supported font formats : pcf ttf" fi else echo "Supported font formats : pcf" fi elif test "$gui" = "xlib"; then echo "Type engines :$type_engines_result" fi echo "DnD : $dnd" if test "$gui" = "xlib"; then echo "Input Methods : XIM$input_methods_result" else echo "Input Methods :$input_methods_result" fi echo "Scrollbars : simple${scrollbars_result}" echo "libssh2 : $ssh2" echo "mosh directory : $MOSH_DIR" if test "$have_gtk" = "yes"; then if test "$have_gtk4" = "yes"; then echo "GTK+ : yes ($gtk_version, 4.0)" else echo "GTK+ : yes ($gtk_version)" fi else if test "$have_gtk4" = "yes"; then echo "GTK+ : yes (4.0)" else echo "GTK+ : no" fi fi if test "$VTE_ABI" = ""; then vte_version="" else vte_version=" (${VTE_ABI})" fi echo "libvte : $have_vte$vte_version" echo "brlapi : $brlapi" echo "VT52 : $vt52" echo "Permission of mlterm binary : $INSTALL_OPT" echo "Compact true color : $compact_truecolor" echo # This should be called at the end of configure. # If --with-gui=quartz,console is specified, copy uitoolkit/* to gui/console/uitoolkit # before removing following files. if test "$gui" = "quartz" ; then # ui_event_source.c, ui_sb_view_factory.c, ui_scrollbar.c and ui_simple_sb_view.c # exist in uitoolkit/ and uitoolkit/quartz/. # Those in uitoolkit/ must be removed to build those in uitoolkit/quartz/. (cd uitoolkit/quartz/ && \ for file in `ls *.c` ; do if test -f ../$file ; then mv ../$file ../xlib/ ; fi ; done) fi mlterm-3.9.3/contrib/000077500000000000000000000000001441203364000144635ustar00rootroot00000000000000mlterm-3.9.3/contrib/icon/000077500000000000000000000000001441203364000154135ustar00rootroot00000000000000mlterm-3.9.3/contrib/icon/README000066400000000000000000000030151441203364000162720ustar00rootroot00000000000000mlterm icon collection ====================== - mlterm-icon-fvwm.png I made this icon from scratch for FVWM window manager. GPL applies it. - mlterm-icon-gnome.png, mlterm-icon-gnome2.png These icons, designed for GNOME / GNOME 2.0, are based on GPLed icons. (gnome-globe.png, gnome-term.png, gnome-terminal.png) - mlterm-icon-wmaker.png This icon is based on linuxterm.tiff in the Window Maker source distribution. The WindowMaker/Icons/README file said... "The icons listed in the end of this file and their correspondent xpm versions were made by Marco van Hylckama Vlieg. They may be distributed freely and/or modified as long as the original Author is mentioned! marco@windowmaker.org" - mlterm-icon-kde.png This is designed for KDE and based on GPLed icons. (hi48-app-konsole.png, hi32-app-konqueror.png) - mlterm-icon-twm.png This icon was changed to monochromatic color for twm window manager from the icon which was made by Tomohiro KUBOTA san. (mlterm_48x48.xpm) - mlterm-icon-24colors-1.png, mlterm-icon-24colors-2.png These icons use less than 24 colors. I hope these make you happy with low depth color. Licensed under modified BSD-style license. - mlterm-icon.svg, mlterm-icon-trans.svg These icons were contributed from Tobias Kieslich . Licensed under GPL. - mlterm-icon-win32.icon This icon is converted from mlterm-icon-24colors-2.png. comments, suggestions are welcome. -- Seiichi SATO mlterm-3.9.3/contrib/icon/mlterm-icon-24colors-1.png000066400000000000000000000007051441203364000221540ustar00rootroot00000000000000PNG  IHDR Tg0PLTELLLfff333tRNS@fbKGDH pHYs  ~tIME  b/(IDATxU!o1 dze.i}mr<6a+/L\m1auȘ%q$KmAeƔ*[XM@0l3)`dg`g>aԫ"o @3npr//EVx{Oӂ{:CQ5hɫ q Q /?T~36i{uth]Zg`=|IENDB`mlterm-3.9.3/contrib/icon/mlterm-icon-24colors-2.png000066400000000000000000000007421441203364000221560ustar00rootroot00000000000000PNG  IHDR D6PLTEfffLLL333=tRNS@fbKGDH pHYs  ~tIME  ,g%IDATx۶ D[k0iӞ%qx'v${>7(P09?@^D_ X=.3{URpdi#)k|x|V LSX@_X£ o_ dKkzoOTtt&uT`}$zzkvvr!';ԆtX%;j XTqhk]$U_+c V]J'wF?uR8\|Dr~㾛:NNʕIENDB`mlterm-3.9.3/contrib/icon/mlterm-icon-fvwm.png000066400000000000000000000046711441203364000213340ustar00rootroot00000000000000PNG  IHDR00WbKGD: pHYs  #utIME#t FIDATxYl\Ww,xI8cKJ[ZVYH $$*<T !P+A+񆐐 Vb\TW4TBNpU=$vbkǞx{,^fswh O7zY>TɛƯm"X|4̊涊EG.G ?(>͏pŻ8c3lj;.}=]D%VB8-hرtetEOspAƋW7!3_ڒC+D"FxtHRx!\!z qNł%$\ySSSNӓY [* @kͦMhmmeϞ=tuuD:T?vW*sQB]]]KYHJɁ :zWrN\F&H$ ʕ_~r3^R 388X_|y(ƕ7q9b"DWr"@nKAb+rQfIffZDb;そlNcS ](7Gs‡ ;9.߁j](HkGX~,lo3UPXɚzوc\ԅZ@ Lm0q Dfz%$A\4ث̆KtX#ܞ:XAeR\ 0 ~a6ua#qSQn۱S$PHDL0UVՎκF(brZk'oaqH*1MVbMLkI 憛C{"m ~a?E(Q̅7am4i[m<pho4Әl[lf}8dC f ]uZQP}],UrsuÀ`}02m ˲Q# a`B[\d*ë95f }'?ӍMUteT̉[qu56I%*i(CԨaz5he~Օ~ΎX?c$vڝO> d( KYF!z4qbiPH)Mn'.Bn!Re# %5g/R_Kyȕ{pE$iVn%f8 )9 PJgԇ'-@듷/*KH Lb0Oi B:Y +$B[JPaj`:T1 ;D3)'^Tڇ0R"+" !D b&b}hp,쭇6 BY;qd ǑR!B+•)Z齺 Kr`)9YJ4. =0VZ|DS]*]#\87\7h`<[mӲ㿰8tTˍ79w+ t $TPy، +2N 257Wq>HS3صj#8RžŮI湕quE~?JJ *?jk_|tk7qgUQ AܱRgfC8=,eZbl۶i{mHc>h ʟ7ZI%"Ԝ`|u,])[RW^40pH/#^D<+[& x4mCu= w0C'KX$@ 7ߔMRyvt6Le`]er\Z[4 ^mCF?V&eFaeg/`oMxNSŞWy# !ZƝx`]oG=շ7X,IENDB`mlterm-3.9.3/contrib/icon/mlterm-icon-gnome.png000066400000000000000000000071721441203364000214610ustar00rootroot00000000000000PNG  IHDR00WbKGD pHYs  ~tIME(,*IDATxݙk%G~?}7Isf4ki<3;ٱYfٵCم@`<=yJH !ubvoX3ҌFstNV]t2e޴ Si3d=`[sDfaLsZNs 'sLO ~dZ%2Yjrf_'<^kJ4S Ndj5-%$1M\…&@{S3̼/]zEPq ]!ãC??O0!hbЩM¯]@E QmP.X !2pslaI?xOM57ty׸u2Jw.1)[&HJ.>VW*Q)JxCDvQʕpIbt' 嘰w?$_GFY 姶@k۷z*Aql2`0IIx(韧"^iA`3@X''-\fY`U677qfI&++4M'ZXUoQh8kxcaai{/GD >~L\& iH8sLzoO88s]{}Fy7t'[ya<{I^X;, Y C͵MZ-Zpe{.f{wlƆ [_4 fff08c| `41b4EQTlr6I$8v=tN"VWW# ZsYx?1 ИЅcRBfhj%p]CfiiiRzV, ^=\ D&"#*bvM''9vvQ&c#gLU)%(DgIxN6v;vgygM8?|g:Q1D>"B`@)2`+Hp'Aen Ɏ';f|֌Nm^Y"?B5#Q5[.hTiINRR*'")Ӏ2މF=hJrqxcyix|muDE9?d"++bFP~/Z }*6 -3t= ;,ʉH1儐B 1%`ؖy{^Ao2t,Aźt)~YE/|_]๹O6+<#n 6q"RHЉ`T$HzUJt8j%XAf{or'?aeH"Pl4jVD˲r!0łEYܺlX(\0E&d'&WW7xygo6.c\ZH^Rlrqk+<$5G8Re4?ryX"A[Uw Mpfs;KܼG;Gq>G>OsA2eQH,20>PS-FO? `0D:@E0  @ H?1oݾK&У7(|<%qgz1.* 1tBM q>{! $T2-9}/#0B wсf +Mvӌ8h FFK2D = d +O\,z.QTT7R>Er9K(c{Ǝ4kO]>*\x C@^FG7l[9!ɀИ8G|"МV:!~|>O>_?1SOp re쇴]CEk$#v_s(BL]7wc HRT8:JTiޏ^y}P(Ҩ- Z p}henGŋX6D/s'˧vl>QBBAhp. #qr+& +qbVl E\)amYHa2X9;–BagIJ m#N~3UqĈM8>w'}8BgN$x ` ,g.YF4K)e[eJbs雕Rs1'*F(|E` V YۈtG6g4Ȇ)l1X$`(Q8pm) )ш$DH\!:O7O?{; ܏@Ȇ Hl%Or>~>FRdYVT.՛K-T/[uX+bi :mKSgs.pW&Q֒k <͔3UyPJRRD EDql#RZ ,Ff5hoEQj(1C۫K"}:""csuM!x߼:g!CZ˅ /|>(0j3յ]u@tD"{%A( !H1 #1FIX@8g'qc3kSz*jO`9AEzl@ d(؞eY0x$&Fک Pz @5 NG?@ϸҌFDl@Ę!L-q>4;EsuNBL.cʩ췀xW?b5[ 8x*T>5%O}{bu `ieNΒY`!HHdnY(:{ʲ$@/'t_Q"680Pd.8M!6wj@#ҒL ;c YqTuE]sS6?DbeXi]8! TVVV!:B ( eeFGwn<ϙCV=SK|80c 3'dlυ{ DQJTaҸKd'҅kZڸ7$@1FXkSUVmx悷J 'kk(h Utli%ƈw>]SvQK:ȶ@x',YB[!/%HJ=xj$6c 2Xk[8M w=2#T1S$8zтVRmϋ(Sdjkm>b%6yGթgEQ0QZH+Z 4h- "( ,D\:T|ﶶLSZ]@]Xchs$ƴZ*2n٥( :eQ9EQ$:e0qDcurdYY!&=gʫph_%n()6C+&,o=' Lb:tpX]YYZ܈[_ȥWYq\cT(xb.6]k\'_q)3F#ʲL<( ,'˲T*q2&wwk#k8zUŵeA@) %ə -.-R'|7>?z_xd8)?L#QmJcŅ$'~/-*qbmD/{?z'8e:Z+PjM "tE$B1eG鶩e~K<t ʢD{qE8&g?}w߱sԠG|ȓOq>paswc@dP#Rgyޱ8wKrVzW 4:/}z9}K1[AwU47o ^KGcTwZTKGXQ0mRvVк@dcQq&xl:zx7уWonϢd?R3mC~47y虱W+;z~W_}o<_ԇî3}6Z]b~q% D5"5,wG=xUPѳH9k>{t1\iS9{Q nqDYOeb3>khF@(DbWD[8`qS 4S/,TQ!޲ ׯ]߸Glo^@Ãfl4-4OUBUa7_G+J7Ud.xz;ިzNsf THbu_AS1;\EW͐7/v D-ݸɥ q. DTDo3Zk7TD;NBDp2ڸ]AzLfJ`X>%GKT7Vl*%A$q41`w{׿xFD.DNLW;;-VIw;MwJʊ?p|H]颒 R?ps}qY  "r)F 2ar@%{ӀwȁnbUk}P)u,|{rpx`Uw =  6h\?"eYQv@v [Fb d:~'LRiPjK"(1vEȚ=(T)vMmL'jvo'@dJ5Á̋HWLA9@M@F"fԿ#;ƝJٳ4K#dh =+ݮw[~06L3[ wDMkIENDB`mlterm-3.9.3/contrib/icon/mlterm-icon-kde.png000066400000000000000000000034431441203364000211140ustar00rootroot00000000000000PNG  IHDR szzbKGD pHYs  ~tIME1/=IDATx]l{m߱3Kti41NIbj(PJRPhD!jD*J_ZA>8RViB B5ZR\6Şݹ;Ӈc鑎jusZ|I"!-538GtƎ;ʕkf!̎RDQ @#xE52OL Hŋ!=9wv;}w;wDk֚0 )  *mE5)hjjBk޽{mflFJIcc쮒$eq͢!ꧠT*144Ğ={( 7iYDↅHDP_s2<< eˈc J_oqUKBP066ƶ[Ѧvr F$o[ĖG~!-3|7Xֵ..ɚ୭+_1(>:Dn_j|Ϊt7LU8,d͛7ϿAۤP(`YVMpI]ŖgBJ@@ʣ(}m"G6- %T*9@4w FbXWL&e%S:D[A!Ӆ(G.l &=FA[D"F"?8Xֶ6>]p]MM5OTB&jxJ%Jtm! 'w{OhFSs}_ 4u"Sd W ha[&eע?9O?:pU`Zr`IQ 9yڅq+߸%>y )ͥ{asݸDj%r^? 8N5 ,.WV/'{9֊Lĥϣɺ|eQ*R MH$x?_ d_{AH"Wn3 6aLT?9r⛱>]6r@Q7@W\ЄQe/0!X+W7Kݒh R<#a>ĝ6T7F"QZTBWƞv?1$ /؎uџCEAlX \HK?3>:a|-/OX se v+ *R@~"˥D}⨲x?[c;^$?7x Created with Inkscape http://www.inkscape.org/ image/svg+xml ML-Term Icon 2004-07-15 Tobias Kieslich mlterm-3.9.3/contrib/icon/mlterm-icon-twm.png000066400000000000000000000004651441203364000211610ustar00rootroot00000000000000PNG  IHDR00*l PLTE~OtRNS@fbKGDH pHYs  d_tIME   wIDATx;0 ,GHxghNŜA§#GT%?Cu#i=:h @2Jڑ3 bcbH Z`~#܅p,xK56 \1 mʍ΀/6Lx>U\ǭ׍#oY%<:+fN0IENDB`mlterm-3.9.3/contrib/icon/mlterm-icon-win32.ico000066400000000000000000000042761441203364000213060ustar00rootroot00000000000000 ( @fffLLL333ܐ }ȌHԌH I!}}}}DNE ,"" "8=IܐBIܐBIܐ                                                          @`mlterm-3.9.3/contrib/icon/mlterm-icon-wmaker.png000066400000000000000000000101521441203364000216320ustar00rootroot00000000000000PNG  IHDR00WbKGD pHYs  ~tIME 1 IDATxil\u޷"DI(ǒHr+N$lM,-"EcE&Hi$h@-!S@a/e9HDII$5Ùlo޻K?!%CYA zs/7 +I0oP(5~K/= Qv* -LZkvN jNrNo?'׊*Ig Q)qET<Dyl&gC=ɝcLۀB<}!9,i5Xk1Ơ$A$$`kYYi< v@?/|pCSw~x]wرcG pp֦`: 팵X8RPJaC:H͕*f85TUB_Y< N9{FСCg~^Zgs!rBqG!8 "85DfZ}fJJ^VJO!JIR&Biut^bEb xզnG45J" "rJJuLXT*S))4VLI8Z8,`|Oxşᡔ$F$i6kTE+e% bs\̀t9օcC5D;!(կ~= Dg,&ikֺ.s >=#BI%B; ҎL˺}$=|cpaM UlfRU0},N\⥣\)WN)("`u֚f||G!zEqmzʈ!,&r9Ntfu$D:ބS )R(ߚRH%qn`|_gw!3UTo.Fy\59~yUE-jA}{GΰP-tKF*RYIvٹNʮ,Gjиbq3U^mr1xE5(!M/dt_Pm .-D*ެ Ɖ W6_}L +xő )hcy>o:+8L& AExd2ܵcVڰ:;ua8 صy+d=zq[7G5c39-[f|=QWϝ#]+6@ R RJC,[Z-t)B<vsLދS _Z}!;og|rJogRS0sfۛ~ +'|0ıhc %vdhxjӋ9v"^JL\WR.suՅ /LOSd 8j-T-&&G!y?͐fDWZgu8N}$Mm74K{3叞fvaO]$FҊhbN1ؓttē OJ $͒̈́(O1222ī_C {2H;1t/*,yA<Δ|W/pEzYz,MD+$fSB#%fu[ /--u@Zu a-'zOء$ZFyi( ' u[f{MDkW> R>AL5Z3N,+d}fkmF{"g37Na,~|m'kbuKW15e aL&qAgHBŭ>`n!hcb95ϝ=ɢ㽇82_fTB)n58q4"XgQ,RJS)p塤ٳX !p[ѼdrZ$"?T?y^{G68m+^s`9?SoH ]= x(%V &tYgO\dd &|aMP*೏ C1@6޶^19:1r;!@(^F力+k!sg8v l@X\c '~H[8GC5.\`lh3(2AI ϿS=}W^X$tD)*%=ݾqO!%|'?|_8MSo+o\$s^/lk8j i4l]4R:ocPH#@z!X7ƥ7zқ%_X֘4ӎ'Yp. tb!qΑ$mfSY6msʕk bq9VwDUrsi;vSGAt$_\wjNt :N`Љ'.SzqQ qLtȂ0tNCݵԭ _:ԅĒ#}{333/>e)a;H_o!|QJy } PCJ!*!Tr#SO[;śì+p(ZfKk;bzG_җgFӊZ$IڭL=.QWHcIZ%+:Q&nGJŲ)t(022\ܹBgwߜ| |:1222 Created with Inkscape http://www.inkscape.org/ image/svg+xml ML-Term Icon 2004-07-14 Tobias Kieslich mlterm-3.9.3/contrib/scrollbar/000077500000000000000000000000001441203364000164465ustar00rootroot00000000000000mlterm-3.9.3/contrib/scrollbar/extra/000077500000000000000000000000001441203364000175715ustar00rootroot00000000000000mlterm-3.9.3/contrib/scrollbar/extra/ChangeLog000066400000000000000000000024771441203364000213550ustar00rootroot000000000000002003-02-02 Seiichi SATO * next.c, mozmodern.c, athena.c, motif.c: replaced the old plugin-interface (vt_*_sb_view_new()) with the new interface (x_*_sb_view_new()) which has been supported since version 2.4.0 2002-09-15 Seiichi SATO * next.c: minor cleanup 2002-09-07 Seiichi SATO * next.c: fixed memory leak in create_bg(). 2002-05-05 Seiichi SATO * mozmodern.c: added a cache for pixel values. 2002-05-01 Seiichi SATO * exsb_common.c: fixed minor bug in get_closest_xcolor_pseudo() * athena.c, motif.c: removed unused variables 2002-05-01 Seiichi SATO * exsb_common.c: renamed nearest_color to closest_color 2002-04-30 Seiichi SATO * ChangeLog: This file, initial import. * LICENCE: Initial import. * fixed some bugs related to destroy pixmaps and/or graphic contexts. * added initialization for graphic contexts * exsb_common.c: Initial import, common functions to manipulate color 2002-04-26 Seiichi SATO * next.c: bugfix in flag initialization in vt_*_sb_view_new() 2002-04-25 Seiichi SATO * Makefile.in, athena.c, motif.c, motif_data.h, mozmodern.c, mozmodern_data.h, next.c, next_data.h : Initial import mlterm-3.9.3/contrib/scrollbar/extra/LICENCE000066400000000000000000000026341441203364000205630ustar00rootroot00000000000000Copyright (C) 2002 Seiichi SATO Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. The name of any author may not be used to endorse or promote products derived from this software without their specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. mlterm-3.9.3/contrib/scrollbar/extra/Makefile.in000066400000000000000000000040411441203364000216350ustar00rootroot00000000000000top_builddir = ../../.. top_srcdir = @top_srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ libdir = @libdir@ LIBDIR = $(DESTDIR)$(libdir)/mlterm VPATH = ${top_srcdir}/contrib/scrollbar/extra ATHENA_OBJ = athena.o MOTIF_OBJ = motif.o MOZMODERN_OBJ = mozmodern.o NEXT_OBJ = next.o CFLAGS = $(CFLAGS_LOCAL) -I$(top_srcdir)/uitoolkit @CFLAGS@ @CPPFLAGS@ @X_CFLAGS@ CC = @CC@ INSTALL = @INSTALL@ LIBTOOL = @LIBTOOL@ LIBTOOL_CC = $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) LIBTOOL_LINK = $(LIBTOOL) --mode=link $(CC) @LDFLAGS@ LIBTOOL_INSTALL = $(LIBTOOL) --mode=install $(INSTALL) .SUFFIXES: .o .c all: libathena.la libmotif.la libmozmodern.la libnext.la libathena.la: $(ATHENA_OBJ) $(LIBTOOL_LINK) -o libathena.la $(ATHENA_OBJ:.o=.lo) \ -rpath $(libdir)/mlterm \ -module -avoid-version @NO_UNDEFINED_FLAG@ \ @X_LIBS@ @X_EXTRA_LIBS@ # @X_LIBS@ @X_PRE_LIBS@ @X_EXTRA_LIBS@ libmotif.la: $(MOTIF_OBJ) $(LIBTOOL_LINK) -o libmotif.la $(MOTIF_OBJ:.o=.lo) \ -rpath $(libdir)/mlterm \ -module -avoid-version @NO_UNDEFINED_FLAG@ \ @X_LIBS@ @X_EXTRA_LIBS@ # @X_LIBS@ @X_PRE_LIBS@ @X_EXTRA_LIBS@ libmozmodern.la: $(MOZMODERN_OBJ) $(LIBTOOL_LINK) -o libmozmodern.la $(MOZMODERN_OBJ:.o=.lo) \ -rpath $(libdir)/mlterm \ -module -avoid-version @NO_UNDEFINED_FLAG@ \ @X_LIBS@ @X_EXTRA_LIBS@ # @X_LIBS@ @X_PRE_LIBS@ @X_EXTRA_LIBS@ libnext.la: $(NEXT_OBJ) $(LIBTOOL_LINK) -o libnext.la $(NEXT_OBJ:.o=.lo) \ -rpath $(libdir)/mlterm \ -module -avoid-version @NO_UNDEFINED_FLAG@ \ @X_LIBS@ @X_EXTRA_LIBS@ # @X_LIBS@ @X_PRE_LIBS@ @X_EXTRA_LIBS@ .c.o: $(LIBTOOL_CC) -c $< $(LIBDIR): mkdir -p $(LIBDIR) install: $(LIBDIR) $(LIBTOOL_INSTALL) libathena.la libmotif.la libmozmodern.la libnext.la $(LIBDIR) uninstall: rm -f $(LIBDIR)/*athena.* $(LIBDIR)/*motif.* $(LIBDIR)/*mozmodern.* $(LIBDIR)/*next.* clean: rm -rf $(ATHENA_OBJ) $(ATHENA_OBJ:.o=.lo) \ $(MOTIF_OBJ) $(MOTIF_OBJ:.o=.lo) \ $(MOZMODERN_OBJ) $(MOZMODERN_OBJ:.o=.lo) \ $(NEXT_OBJ) $(NEXT_OBJ:.o=.lo) \ libathena.la libmotif.la libmozmodern.la libnext.la *.core .libs distclean: clean rm -f Makefile mlterm-3.9.3/contrib/scrollbar/extra/athena.c000066400000000000000000000061131441203364000211760ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include #include #include #define WIDTH 14 typedef struct athena_sb_view { ui_sb_view_t view; int is_transparent; } athena_sb_view_t; /* --- static functions --- */ static void get_geometry_hints(ui_sb_view_t *view, unsigned int *width, unsigned int *top_margin, unsigned int *bottom_margin, int *up_button_y, unsigned int *up_button_height, int *down_button_y, unsigned int *down_button_height) { *width = WIDTH; *top_margin = 1; *bottom_margin = 1; *up_button_y = 0; *up_button_height = 0; *down_button_y = 0; *down_button_height = 0; } static void get_default_color(ui_sb_view_t *view, char **fg_color, char **bg_color) { *fg_color = "black"; *bg_color = "white"; } static void realized(ui_sb_view_t *view, Display *display, int screen, Window window, GC gc, unsigned int height) { view->display = display; view->screen = screen; view->window = window; view->gc = gc; view->height = height; } static void resized(ui_sb_view_t *view, Window window, unsigned int height) { view->window = window; view->height = height; } static void destroy(ui_sb_view_t *view) { free(view); } static void draw_scrollbar(ui_sb_view_t *view, int bar_top_y, unsigned int bar_height) { XPoint *points; unsigned short x; unsigned short y; int i = 0; int j; /* clear */ XClearArea(view->display, view->window, 0, 0, WIDTH, view->height - 1, 0); if ((points = malloc((WIDTH * view->height) * sizeof(XPoint))) == NULL) { return; } /* bar */ j = 1; for (y = bar_top_y; y < bar_top_y + bar_height; y++) { for (x = j; x < WIDTH - 1; x += 2) { points[i].x = x; points[i].y = y; i++; } j++; if (j == 3) { j = 1; } } XDrawPoints(view->display, view->window, view->gc, points, i, CoordModeOrigin); free(points); } /* --- global functions --- */ ui_sb_view_t *ui_athena_sb_view_new(void) { athena_sb_view_t *athena_sb; if ((athena_sb = calloc(1, sizeof(athena_sb_view_t))) == NULL) { return NULL; } athena_sb->view.version = 1; athena_sb->view.get_geometry_hints = get_geometry_hints; athena_sb->view.get_default_color = get_default_color; athena_sb->view.realized = realized; athena_sb->view.resized = resized; athena_sb->view.destroy = destroy; athena_sb->view.draw_scrollbar = draw_scrollbar; return (ui_sb_view_t *)athena_sb; } ui_sb_view_t *ui_athena_transparent_sb_view_new(void) { athena_sb_view_t *athena_sb; if ((athena_sb = calloc(1, sizeof(athena_sb_view_t))) == NULL) { return NULL; } athena_sb->view.version = 1; athena_sb->view.get_geometry_hints = get_geometry_hints; athena_sb->view.get_default_color = get_default_color; athena_sb->view.realized = realized; athena_sb->view.resized = resized; athena_sb->view.destroy = destroy; athena_sb->view.draw_scrollbar = draw_scrollbar; athena_sb->is_transparent = 1; return (ui_sb_view_t *)athena_sb; } mlterm-3.9.3/contrib/scrollbar/extra/exsb_common.h000066400000000000000000000042161441203364000222560ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __EXSB_COMMON_H__ #define __EXSB_COMMON_H__ #include #include #include /* --- static functions --- */ static void get_closest_xcolor_pseudo(Display *display, int screen, Colormap cmap, XColor *color, XColor *closest_color) { XColor *all_colors; int i; int closest_index = 0; unsigned long min = 0xffffffff; unsigned long diff; unsigned long diff_r = 0, diff_g = 0, diff_b = 0; int ncells = DisplayCells(display, screen); all_colors = malloc(ncells * sizeof(XColor)); /* get all colors from default colormap */ for (i = 0; i < ncells; i++) { all_colors[i].pixel = i; } XQueryColors(display, cmap, all_colors, ncells); /* find closest color */ for (i = 0; i < ncells; i++) { diff_r = (color->red - all_colors[i].red) >> 8; diff_g = (color->green - all_colors[i].green) >> 8; diff_b = (color->blue - all_colors[i].blue) >> 8; diff = diff_r * diff_r + diff_g * diff_g + diff_b * diff_b; if (diff < min) /* closest ? */ { min = diff; closest_index = i; } } closest_color->red = all_colors[closest_index].red; closest_color->green = all_colors[closest_index].green; closest_color->blue = all_colors[closest_index].blue; closest_color->flags = DoRed | DoGreen | DoBlue; free(all_colors); if (XAllocColor(display, cmap, closest_color) == 0) { closest_color->pixel = BlackPixel(display, screen); } } /* --- global functions -- */ static unsigned long exsb_get_pixel(Display *display, int screen, Colormap cmap, Visual *visual, char *color_name) { XColor color; XColor closest_color; if (XParseColor(display, cmap, color_name, &color) == 0) { return BlackPixel(display, screen); } if (XAllocColor(display, cmap, &color) == 0) { if (visual->class == PseudoColor || visual->class == GrayScale) { get_closest_xcolor_pseudo(display, screen, cmap, &color, &closest_color); return closest_color.pixel; } return BlackPixel(display, screen); } return color.pixel; } #endif mlterm-3.9.3/contrib/scrollbar/extra/motif.c000066400000000000000000000304351441203364000210600ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include #include #include #include "motif_data.h" #define WIDTH 15 #define V_MARGIN 14 #define BUTTON_SIZE 11 typedef struct motif_sb_view { ui_sb_view_t view; GC gc; Colormap cmap; unsigned long fg_lighter_color; unsigned long fg_darker_color; unsigned long bg_lighter_color; unsigned long bg_darker_color; int is_transparent; } motif_sb_view_t; /* --- static functions --- */ static void get_geometry_hints(ui_sb_view_t *view, unsigned int *width, unsigned int *top_margin, unsigned int *bottom_margin, int *up_button_y, unsigned int *up_button_height, int *down_button_y, unsigned int *down_button_height) { *width = WIDTH; *top_margin = V_MARGIN; *bottom_margin = V_MARGIN; *up_button_y = 0; *up_button_height = V_MARGIN; *down_button_y = -V_MARGIN; *down_button_height = V_MARGIN; } static void get_default_color(ui_sb_view_t *view, char **fg_color, char **bg_color) { *fg_color = "gray"; *bg_color = "lightgray"; } static void realized(ui_sb_view_t *view, Display *display, int screen, Window window, GC gc, unsigned int height) { motif_sb_view_t *motif_sb; XWindowAttributes attr; XGCValues gc_value; motif_sb = (motif_sb_view_t*)view; view->display = display; view->screen = screen; view->window = window; view->gc = gc; view->height = height; gc_value.foreground = BlackPixel(view->display, view->screen); gc_value.background = WhitePixel(view->display, view->screen); gc_value.graphics_exposures = 0; motif_sb->gc = XCreateGC(view->display, view->window, GCForeground | GCBackground | GCGraphicsExposures, &gc_value); XGetWindowAttributes(view->display, view->window, &attr); motif_sb->cmap = attr.colormap; } static void resized(ui_sb_view_t *view, Window window, unsigned int height) { view->window = window; view->height = height; } static void destroy(ui_sb_view_t *view) { motif_sb_view_t *motif_sb; motif_sb = (motif_sb_view_t*)view; if (motif_sb) { XFreeGC(view->display, motif_sb->gc); free(motif_sb); } } static unsigned short adjust_rgb(unsigned short v, float fac) { if (v == 0 && fac > 0) { v = 0x7070; } if (v * fac > 0xffff) { return 0xffff; } else { return (unsigned short)(v * fac); } } static void color_changed(ui_sb_view_t *view, int is_fg) { motif_sb_view_t *motif_sb; XColor color; XColor color_lighter; XColor color_darker; XGCValues gc_value_ret; motif_sb = (motif_sb_view_t*)view; if (motif_sb->is_transparent) { motif_sb->fg_lighter_color = motif_sb->bg_lighter_color = WhitePixel(view->display, view->screen); motif_sb->fg_darker_color = motif_sb->bg_darker_color = BlackPixel(view->display, view->screen); return; } /* query current fg/bg color pixel */ XGetGCValues(view->display, view->gc, GCForeground | GCBackground, &gc_value_ret); color_darker.flags = color_lighter.flags = DoRed | DoGreen | DoBlue; /* fg highlight color / shade color */ color.pixel = gc_value_ret.foreground; XQueryColor(view->display, motif_sb->cmap, &color); color_lighter.red = adjust_rgb(color.red, 1.5); color_lighter.green = adjust_rgb(color.green, 1.5); color_lighter.blue = adjust_rgb(color.blue, 1.5); color_darker.red = adjust_rgb(color.red, 0.5); color_darker.green = adjust_rgb(color.green, 0.5); color_darker.blue = adjust_rgb(color.blue, 0.5); if (XAllocColor(view->display, motif_sb->cmap, &color_lighter)) { motif_sb->fg_lighter_color = color_lighter.pixel; } else { motif_sb->fg_lighter_color = WhitePixel(view->display, view->screen); } if (XAllocColor(view->display, motif_sb->cmap, &color_darker)) { motif_sb->fg_darker_color = color_darker.pixel; } else { motif_sb->fg_darker_color = BlackPixel(view->display, view->screen); } /* bg highlight color / shade color */ color.pixel = gc_value_ret.background; XQueryColor(view->display, motif_sb->cmap, &color); color_lighter.red = adjust_rgb(color.red, 1.5); color_lighter.green = adjust_rgb(color.green, 1.5); color_lighter.blue = adjust_rgb(color.blue, 1.5); color_darker.red = adjust_rgb(color.red, 0.5); color_darker.green = adjust_rgb(color.green, 0.5); color_darker.blue = adjust_rgb(color.blue, 0.5); if (XAllocColor(view->display, motif_sb->cmap, &color_lighter)) { motif_sb->bg_lighter_color = color_lighter.pixel; } else { motif_sb->bg_lighter_color = WhitePixel(view->display, view->screen); } if (XAllocColor(view->display, motif_sb->cmap, &color_darker)) { motif_sb->bg_darker_color = color_darker.pixel; } else { motif_sb->bg_darker_color = BlackPixel(view->display, view->screen); } } static void draw_button(ui_sb_view_t *view, char **data, unsigned int offset_y) { motif_sb_view_t *motif_sb; char cur = '\0'; int x; int y; GC gc = NULL; XPoint xpoint[BUTTON_SIZE * BUTTON_SIZE]; int i = 0; motif_sb = (motif_sb_view_t*)view; for (y = 0; y < BUTTON_SIZE; y++) { for (x = 0; x < BUTTON_SIZE; x++) { if (cur != data[y][x]) { if (i) { /* before setting gc, draw stocked points */ XDrawPoints(view->display, view->window, gc, xpoint, i, CoordModeOrigin); i = 0; } /* changing gc */ if (data[y][x] == '.') { XSetForeground(view->display, motif_sb->gc, motif_sb->fg_lighter_color); gc = motif_sb->gc; } else if (data[y][x] == '#') { XSetForeground(view->display, motif_sb->gc, motif_sb->fg_darker_color); gc = motif_sb->gc; } else if (data[y][x] == ':') { if (motif_sb->is_transparent) { continue; } gc = view->gc; } else if (data[y][x] == ' ') { continue; } cur = data[y][x]; } /* stocking point */ xpoint[i].x = x + 2; xpoint[i].y = y + offset_y; i++; } } if (i) { XDrawPoints(view->display, view->window, gc, xpoint, i, CoordModeOrigin); } } static void draw_up_button(ui_sb_view_t *view, int is_pressed) { motif_sb_view_t *motif_sb; char **src; XSegment line[4]; motif_sb = (motif_sb_view_t*)view; if (is_pressed) { src = arrow_up_pressed_src; } else { src = arrow_up_src; } XClearArea(view->display, view->window, 0, 0, V_MARGIN, V_MARGIN, 0); draw_button(view, src, 2); XSetForeground(view->display, motif_sb->gc, motif_sb->bg_darker_color); line[0].x1 = 0; line[0].y1 = 0; line[0].x2 = 14; line[0].y2 = 0; line[1].x1 = 0; line[1].y1 = 1; line[1].x2 = 13; line[1].y2 = 1; line[2].x1 = 0; line[2].y1 = 2; line[2].x2 = 0; line[2].y2 = 13; line[3].x1 = 1; line[3].y1 = 2; line[3].x2 = 1; line[3].y2 = 13; XDrawSegments(view->display, view->window, motif_sb->gc, line, 4); XSetForeground(view->display, motif_sb->gc, motif_sb->bg_lighter_color); line[0].x1 = 13; line[0].y1 = 2; line[0].x2 = 13; line[0].y2 = 13; line[1].x1 = 14; line[1].y1 = 1; line[1].x2 = 14; line[1].y2 = 13; XDrawSegments(view->display, view->window, motif_sb->gc, line, 2); } static void draw_down_button(ui_sb_view_t *view, int is_pressed) { motif_sb_view_t *motif_sb; char **src; XSegment line[4]; motif_sb = (motif_sb_view_t*)view; if (is_pressed) { src = arrow_down_pressed_src; } else { src = arrow_down_src; } XClearArea(view->display, view->window, 0, view->height - V_MARGIN, V_MARGIN, V_MARGIN, 0); draw_button(view, src, view->height - BUTTON_SIZE - 2); XSetForeground(view->display, motif_sb->gc, motif_sb->bg_darker_color); line[0].x1 = 0; line[0].y1 = view->height - V_MARGIN; line[0].x2 = 0; line[0].y2 = view->height - 1; line[1].x1 = 1; line[1].y1 = view->height - V_MARGIN; line[1].x2 = 1; line[1].y2 = view->height - 2; XDrawSegments(view->display, view->window, motif_sb->gc, line, 2); XSetForeground(view->display, motif_sb->gc, motif_sb->bg_lighter_color); line[0].x1 = 13; line[0].y1 = view->height - V_MARGIN; line[0].x2 = 13; line[0].y2 = view->height - 1; line[1].x1 = 14; line[1].y1 = view->height - V_MARGIN; line[1].x2 = 14; line[1].y2 = view->height - 1; line[2].x1 = 2; line[2].y1 = view->height - 2; line[2].x2 = 12; line[2].y2 = view->height - 2; line[3].x1 = 1; line[3].y1 = view->height - 1; line[3].x2 = 12; line[3].y2 = view->height - 1; XDrawSegments(view->display, view->window, motif_sb->gc, line, 4); } static void draw_scrollbar(ui_sb_view_t *view, int bar_top_y, unsigned int bar_height) { motif_sb_view_t *motif_sb; XSegment line[4]; motif_sb = (motif_sb_view_t*)view; /* clear */ XClearArea(view->display, view->window, 2, V_MARGIN, WIDTH - 4, view->height - V_MARGIN * 2, 0); /* bar */ if (!motif_sb->is_transparent) { XFillRectangle(view->display, view->window, view->gc, 2, bar_top_y, WIDTH - 4, bar_height); } /* bar's highlight */ XSetForeground(view->display, motif_sb->gc, motif_sb->fg_lighter_color); line[0].x1 = 2; line[0].y1 = bar_top_y; line[0].x2 = WIDTH - 3; line[0].y2 = bar_top_y; line[1].x1 = 2; line[1].y1 = bar_top_y + 1; line[1].x2 = WIDTH - 4; line[1].y2 = bar_top_y + 1; line[2].x1 = 2; line[2].y1 = bar_top_y + 2; line[2].x2 = 2; line[2].y2 = bar_top_y + bar_height - 1; line[3].x1 = 3; line[3].y1 = bar_top_y + 1; line[3].x2 = 3; line[3].y2 = bar_top_y + bar_height - 2; XDrawSegments(view->display, view->window, motif_sb->gc, line, 4); /* bar's shade */ XSetForeground(view->display, motif_sb->gc, motif_sb->fg_darker_color); line[0].x1 = WIDTH - 3; line[0].y1 = bar_top_y + 1; line[0].x2 = WIDTH - 3; line[0].y2 = bar_top_y + bar_height - 1; line[1].x1 = WIDTH - 4; line[1].y1 = bar_top_y + 2; line[1].x2 = WIDTH - 4; line[1].y2 = bar_top_y + bar_height - 1; line[2].x1 = 4; line[2].y1 = bar_top_y + bar_height - 2; line[2].x2 = WIDTH - 5; line[2].y2 = bar_top_y + bar_height - 2; line[3].x1 = 3; line[3].y1 = bar_top_y + bar_height - 1; line[3].x2 = WIDTH - 5; line[3].y2 = bar_top_y + bar_height - 1; XDrawSegments(view->display, view->window, motif_sb->gc, line, 4); /* scrollview's shade */ XSetForeground(view->display, motif_sb->gc, motif_sb->bg_darker_color); line[0].x1 = 0; line[0].y1 = V_MARGIN; line[0].x2 = 0; line[0].y2 = view->height - V_MARGIN; line[1].x1 = 1; line[1].y1 = V_MARGIN; line[1].x2 = 1; line[1].y2 = view->height - V_MARGIN; XDrawSegments(view->display, view->window, motif_sb->gc, line, 2); /* scrollview's highlight */ XSetForeground(view->display, motif_sb->gc, motif_sb->bg_lighter_color); line[0].x1 = WIDTH - 2; line[0].y1 = V_MARGIN; line[0].x2 = WIDTH - 2; line[0].y2 = view->height - V_MARGIN; line[1].x1 = WIDTH - 1; line[1].y1 = V_MARGIN; line[1].x2 = WIDTH - 1; line[1].y2 = view->height - V_MARGIN; XDrawSegments(view->display, view->window, motif_sb->gc, line, 2); } /* --- global functions --- */ ui_sb_view_t *ui_motif_sb_view_new(void) { motif_sb_view_t *motif_sb; if ((motif_sb = calloc(1, sizeof(motif_sb_view_t))) == NULL) { return NULL; } motif_sb->view.version = 1; motif_sb->view.get_geometry_hints = get_geometry_hints; motif_sb->view.get_default_color = get_default_color; motif_sb->view.realized = realized; motif_sb->view.resized = resized; motif_sb->view.destroy = destroy; motif_sb->view.color_changed = color_changed; motif_sb->view.draw_scrollbar = draw_scrollbar; motif_sb->view.draw_up_button = draw_up_button; motif_sb->view.draw_down_button = draw_down_button; return (ui_sb_view_t*)motif_sb; } ui_sb_view_t *ui_motif_transparent_sb_view_new(void) { motif_sb_view_t *motif_sb; if ((motif_sb = calloc(1, sizeof(motif_sb_view_t))) == NULL) { return NULL; } motif_sb->view.version = 1; motif_sb->view.get_geometry_hints = get_geometry_hints; motif_sb->view.get_default_color = get_default_color; motif_sb->view.realized = realized; motif_sb->view.resized = resized; motif_sb->view.destroy = destroy; motif_sb->view.color_changed = color_changed; motif_sb->view.draw_scrollbar = draw_scrollbar; motif_sb->view.draw_up_button = draw_up_button; motif_sb->view.draw_down_button = draw_down_button; motif_sb->is_transparent = 1; return (ui_sb_view_t*)motif_sb; } mlterm-3.9.3/contrib/scrollbar/extra/motif_data.h000066400000000000000000000021111441203364000220440ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __VT_MOTIF_DATA_H__ #define __VT_MOTIF_DATA_H__ /* * '.' highlight * ':' fg * '#' shade * ' ' bg */ static char *arrow_up_src[] = { " . ", " ..# ", " ..# ", " ..:## ", " ..:## ", " ..:::## ", " ..:::## ", " ..:::::## ", " ..:::::## ", "..#########", ".##########" }; static char *arrow_down_src[] = { "...........", ".........##", " ..:::::## ", " ..:::::## ", " ..:::## ", " ..:::## ", " ..:## ", " ..:## ", " .## ", " .## ", " # " }; static char *arrow_up_pressed_src[] = { " # ", " ##. ", " ##. ", " ##:.. ", " ##:.. ", " ##:::.. ", " ##:::.. ", " ##:::::.. ", " ##:::::.. ", "##.........", "#.........." }; static char *arrow_down_pressed_src[] = { "###########", "#########..", " ##:::::.. ", " ##:::::.. ", " ##:::.. ", " ##:::.. ", " ##:.. ", " ##:.. ", " #.. ", " #.. ", " . " }; #endif mlterm-3.9.3/contrib/scrollbar/extra/mozmodern.c000066400000000000000000000314251441203364000217540ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include #include #include #include "exsb_common.h" #include "mozmodern_data.h" #define WIDTH 15 #define MARGIN 15 #define NR_COLOR 18 typedef struct mozmod_sb_view { ui_sb_view_t view; GC gc; unsigned int depth; Pixmap background; Pixmap arrow_up; Pixmap arrow_up_pressed; Pixmap arrow_down; Pixmap arrow_down_pressed; unsigned long pixels[NR_COLOR]; /* cache */ } mozmod_sb_view_t; static char *color_name[] = { "rgb:00/00/00", /* 0 '#' */ "rgb:e4/eb/f2", /* 1 ' ' */ "rgb:c3/ca/d2", /* 2 '.' */ "rgb:b1/bb/c5", /* 3 ':' */ "rgb:a4/af/bb", /* 4 '$' */ "rgb:8f/9d/ad", /* 5 '+' */ "rgb:ad/b6/c0", /* 6 '^' */ "rgb:9c/a8/b4", /* 7 '@' */ "rgb:93/9f/ad", /* 8 ',' */ "rgb:70/80/92", /* 9 '-' */ "rgb:92/9e/ac", /* 10 '~' */ "rgb:87/95/a4", /* 11 ';" */ "rgb:98/9e/a6", /* 12 */ "rgb:79/81/8c", /* 13 */ "rgb:6d/80/94", /* 14 */ "rgb:d7/df/e6", /* 15 */ "rgb:8d/95/9f", /* 16 */ "rgb:a0/a8/ae" /* 17 */ }; /* --- static functions --- */ static unsigned long get_pixel_by_symbol(ui_sb_view_t *view, char symbol) { mozmod_sb_view_t *mozmod_sb; int index; mozmod_sb = (mozmod_sb_view_t *)view; switch (symbol) { case '#': index = 0; break; case ' ': index = 1; break; case '.': index = 2; break; case ':': index = 3; break; case '$': index = 4; break; case '+': index = 5; break; case '^': index = 6; break; case '@': index = 7; break; case ',': index = 8; break; case '-': index = 9; break; case '~': index = 10; break; case ';': index = 11; break; default: index = 0; break; } return mozmod_sb->pixels[index]; } static Pixmap get_pixmap(ui_sb_view_t *view, GC gc, char **data, unsigned int width, unsigned int height) { Pixmap pix; char cur; int x; int y; pix = XCreatePixmap(view->display, view->window, width, height, ((mozmod_sb_view_t *)view)->depth); cur = '\0'; for (y = 0; y < height; y++) { for (x = 0; x < width; x++) { if (cur != data[y][x]) { XSetForeground(view->display, gc, get_pixel_by_symbol(view, data[y][x])); cur = data[y][x]; } XDrawPoint(view->display, pix, gc, x, y); } } return pix; } static void get_geometry_hints(ui_sb_view_t *view, unsigned int *width, unsigned int *top_margin, unsigned int *bottom_margin, int *up_button_y, unsigned int *up_button_height, int *down_button_y, unsigned int *down_button_height) { *width = WIDTH; *top_margin = MARGIN; *bottom_margin = MARGIN; *up_button_y = 0; *up_button_height = MARGIN; *down_button_y = -MARGIN; *down_button_height = MARGIN; } static void get_default_color(ui_sb_view_t *view, char **fg_color, char **bg_color) { *fg_color = "gray"; *bg_color = "lightgray"; } static Pixmap vt_create_sb_bg_pixmap(ui_sb_view_t *view, int width, int height) { Pixmap pix; mozmod_sb_view_t *mozmod_sb; mozmod_sb = (mozmod_sb_view_t *)view; pix = XCreatePixmap(view->display, view->window, width, height, mozmod_sb->depth); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[12]); XFillRectangle(view->display, pix, mozmod_sb->gc, 1, 0, width - 2, height); XSetForeground(view->display, mozmod_sb->gc, BlackPixel(view->display, view->screen)); XDrawLine(view->display, pix, mozmod_sb->gc, 0, 0, 0, height - 1); XDrawLine(view->display, pix, mozmod_sb->gc, width - 1, 0, width - 1, height - 1); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[13]); XDrawLine(view->display, pix, mozmod_sb->gc, 1, 0, 1, height - 1); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[16]); XDrawLine(view->display, pix, mozmod_sb->gc, 2, 0, 2, height - 1); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[17]); XDrawLine(view->display, pix, mozmod_sb->gc, width - 2, 0, width - 2, height - 1); return pix; } static void realized(ui_sb_view_t *view, Display *display, int screen, Window window, GC gc, unsigned int height) { mozmod_sb_view_t *mozmod_sb; XWindowAttributes attr; XGCValues gc_value; int i; mozmod_sb = (mozmod_sb_view_t *)view; view->display = display; view->screen = screen; view->window = window; view->gc = gc; view->height = height; XGetWindowAttributes(view->display, view->window, &attr); mozmod_sb->depth = attr.depth; for (i = 0; i < NR_COLOR; i++) { mozmod_sb->pixels[i] = exsb_get_pixel(view->display, view->screen, attr.colormap, attr.visual, color_name[i]); } gc_value.foreground = BlackPixel(view->display, view->screen); gc_value.background = WhitePixel(view->display, view->screen); gc_value.graphics_exposures = 0; mozmod_sb->gc = XCreateGC(view->display, view->window, GCForeground | GCBackground | GCGraphicsExposures, &gc_value); mozmod_sb->background = vt_create_sb_bg_pixmap(view, WIDTH, view->height - MARGIN * 2); mozmod_sb->arrow_up = get_pixmap(view, mozmod_sb->gc, arrow_up_src, WIDTH, MARGIN); mozmod_sb->arrow_down = get_pixmap(view, mozmod_sb->gc, arrow_down_src, WIDTH, MARGIN); mozmod_sb->arrow_up_pressed = get_pixmap(view, mozmod_sb->gc, arrow_up_pressed_src, WIDTH, MARGIN); mozmod_sb->arrow_down_pressed = get_pixmap(view, mozmod_sb->gc, arrow_down_pressed_src, WIDTH, MARGIN); XCopyArea(view->display, mozmod_sb->background, view->window, view->gc, 0, 0, WIDTH, view->height, 0, 0); } static void resized(ui_sb_view_t *view, Window window, unsigned int height) { mozmod_sb_view_t *mozmod_sb; mozmod_sb = (mozmod_sb_view_t *)view; view->window = window; view->height = height; /* * create new background pixmap to fit well with resized scroll view */ XFreePixmap(view->display, mozmod_sb->background); mozmod_sb->background = vt_create_sb_bg_pixmap(view, WIDTH, view->height - MARGIN * 2); } static void destroy(ui_sb_view_t *view) { mozmod_sb_view_t *mozmod_sb; mozmod_sb = (mozmod_sb_view_t *)view; if (mozmod_sb) { XFreePixmap(view->display, mozmod_sb->background); XFreePixmap(view->display, mozmod_sb->arrow_up); XFreePixmap(view->display, mozmod_sb->arrow_up_pressed); XFreePixmap(view->display, mozmod_sb->arrow_down); XFreePixmap(view->display, mozmod_sb->arrow_down_pressed); XFreeGC(view->display, mozmod_sb->gc); free(mozmod_sb); } } static void draw_up_button(ui_sb_view_t *view, int is_pressed) { mozmod_sb_view_t *mozmod_sb; Pixmap arrow; mozmod_sb = (mozmod_sb_view_t *)view; if (is_pressed) { arrow = mozmod_sb->arrow_up_pressed; } else { arrow = mozmod_sb->arrow_up; } XCopyArea(view->display, arrow, view->window, view->gc, 0, 0, WIDTH, MARGIN, 0, 0); } static void draw_down_button(ui_sb_view_t *view, int is_pressed) { mozmod_sb_view_t *mozmod_sb; Pixmap arrow; mozmod_sb = (mozmod_sb_view_t *)view; if (is_pressed) { arrow = mozmod_sb->arrow_down_pressed; } else { arrow = mozmod_sb->arrow_down; } XCopyArea(view->display, arrow, view->window, view->gc, 0, 0, WIDTH, MARGIN, 0, view->height - MARGIN); } static void draw_scrollbar_common(ui_sb_view_t *view, int bar_top_y, unsigned int bar_height, int is_transparent) { mozmod_sb_view_t *mozmod_sb; int y; XSegment line[3]; mozmod_sb = (mozmod_sb_view_t *)view; /* drawing background */ /* FIXME: shoule use XSetWindowBackgroundPixmap() */ if (is_transparent) { XClearArea(view->display, view->window, 0, MARGIN, WIDTH, view->height - MARGIN * 2, 0); } else { XCopyArea(view->display, mozmod_sb->background, view->window, view->gc, 0, 0, WIDTH, bar_top_y - MARGIN, 0, MARGIN); XCopyArea(view->display, mozmod_sb->background, view->window, view->gc, 0, 0, WIDTH, view->height - bar_top_y - bar_height - MARGIN, 0, bar_top_y + bar_height); } /* drawing bar */ if (bar_height < 6) /* can't draw shade, since too small */ { XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[3]); XFillRectangle(view->display, view->window, mozmod_sb->gc, 0, bar_top_y, WIDTH, bar_height); XSetForeground(view->display, mozmod_sb->gc, BlackPixel(view->display, view->screen)); XDrawRectangle(view->display, view->window, mozmod_sb->gc, 0, bar_top_y, WIDTH - 1, bar_height); return; } XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[3]); XFillRectangle(view->display, view->window, mozmod_sb->gc, 1, bar_top_y + 1, WIDTH - 2, bar_height - 2); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[5]); line[0].x1 = WIDTH - 2; line[0].y1 = bar_top_y + 1; line[0].x2 = WIDTH - 2; line[0].y2 = bar_top_y + bar_height - 2; line[1].x1 = 2; line[1].y1 = bar_top_y + bar_height - 2; line[1].x2 = WIDTH - 3; line[1].y2 = bar_top_y + bar_height - 2; XDrawSegments(view->display, view->window, mozmod_sb->gc, line, 2); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[4]); line[0].x1 = WIDTH - 3; line[0].y1 = bar_top_y + 2; line[0].x2 = WIDTH - 3; line[0].y2 = bar_top_y + bar_height - 3; line[1].x1 = 3; line[1].y1 = bar_top_y + bar_height - 3; line[1].x2 = WIDTH - 4; line[1].y2 = bar_top_y + bar_height - 3; XDrawSegments(view->display, view->window, mozmod_sb->gc, line, 2); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[1]); line[0].x1 = 1; line[0].y1 = bar_top_y + 1; line[0].x2 = 1; line[0].y2 = bar_top_y + bar_height - 2; line[1].x1 = 2; line[1].y1 = bar_top_y + 1; line[1].x2 = WIDTH - 3; line[1].y2 = bar_top_y + 1; XDrawSegments(view->display, view->window, mozmod_sb->gc, line, 2); XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[2]); line[0].x1 = 2; line[0].y1 = bar_top_y + 2; line[0].x2 = 2; line[0].y2 = bar_top_y + bar_height - 3; line[1].x1 = 3; line[1].y1 = bar_top_y + 2; line[1].x2 = WIDTH - 4; line[1].y2 = bar_top_y + 2; XDrawSegments(view->display, view->window, mozmod_sb->gc, line, 2); XSetForeground(view->display, mozmod_sb->gc, BlackPixel(view->display, view->screen)); XDrawRectangle(view->display, view->window, mozmod_sb->gc, 0, bar_top_y, WIDTH - 1, bar_height - 1); /* draw relief */ if (bar_height > 17) { int bar_mid_y = bar_top_y + bar_height / 2; int i = 0; for (y = bar_mid_y - 4; y < bar_mid_y + 5; y += 4) { line[i].x1 = 4; line[i].y1 = y; line[i].x2 = WIDTH - 5; line[i].y2 = y; i++; } XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[14]); XDrawSegments(view->display, view->window, mozmod_sb->gc, line, i); i = 0; for (y = bar_mid_y - 3; y < bar_mid_y + 6; y += 4) { line[i].x1 = 4; line[i].y1 = y; line[i].x2 = WIDTH - 5; line[i].y2 = y; i++; } XSetForeground(view->display, mozmod_sb->gc, mozmod_sb->pixels[15]); XDrawSegments(view->display, view->window, mozmod_sb->gc, line, i); } } static void draw_scrollbar(ui_sb_view_t *view, int bar_top_y, unsigned int bar_height) { draw_scrollbar_common(view, bar_top_y, bar_height, 0); } static void draw_transparent_scrollbar(ui_sb_view_t *view, int bar_top_y, unsigned int bar_height) { draw_scrollbar_common(view, bar_top_y, bar_height, 1); } /* --- global functions --- */ ui_sb_view_t *ui_mozmodern_sb_view_new(void) { mozmod_sb_view_t *mozmod_sb; if ((mozmod_sb = calloc(1, sizeof(mozmod_sb_view_t))) == NULL) { return NULL; } mozmod_sb->view.version = 1; mozmod_sb->view.get_geometry_hints = get_geometry_hints; mozmod_sb->view.get_default_color = get_default_color; mozmod_sb->view.realized = realized; mozmod_sb->view.resized = resized; mozmod_sb->view.destroy = destroy; mozmod_sb->view.draw_scrollbar = draw_scrollbar; mozmod_sb->view.draw_up_button = draw_up_button; mozmod_sb->view.draw_down_button = draw_down_button; return (ui_sb_view_t *)mozmod_sb; } ui_sb_view_t *ui_mozmodern_transparent_sb_view_new(void) { mozmod_sb_view_t *mozmod_sb; if ((mozmod_sb = calloc(1, sizeof(mozmod_sb_view_t))) == NULL) { return NULL; } mozmod_sb->view.version = 1; mozmod_sb->view.get_geometry_hints = get_geometry_hints; mozmod_sb->view.get_default_color = get_default_color; mozmod_sb->view.realized = realized; mozmod_sb->view.resized = resized; mozmod_sb->view.destroy = destroy; mozmod_sb->view.draw_scrollbar = draw_transparent_scrollbar; mozmod_sb->view.draw_up_button = draw_up_button; mozmod_sb->view.draw_down_button = draw_down_button; return (ui_sb_view_t *)mozmod_sb; } mlterm-3.9.3/contrib/scrollbar/extra/mozmodern_data.h000066400000000000000000000033701441203364000227500ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __VT_MOZMODERN_DATA_H__ #define __VT_MOZMODERN_DATA_H__ /* * '#' black * released button * ' ' #e4ebf2 * '.' #c3cad2 * ':' #b1bbc5 * '$' #a4afbb * '+' #8f9dad * pressed button * '^' #adb6c0 * '@' #9ca8b4 * ',' #939fad * '-' #708092 * '~' #929eac * ';" #8795a4 */ static char *arrow_up_src[] = { "###############", "# +#", "# ..........$+#", "# .:::::::::$+#", "# .:::::::::$+#", "# .::::#::::$+#", "# .:::###:::$+#", "# .::#####::$+#", "# .:#######:$+#", "# .#########$+#", "# .:::::::::$+#", "# .:::::::::$+#", "# .$$$$$$$$$$+#", "# ++++++++++++#", "###############" }; static char *arrow_down_src[] = { "###############", "# +#", "# ..........$+#", "# .:::::::::$+#", "# .:::::::::$+#", "# .#########$+#", "# .:#######:$+#", "# .::#####::$+#", "# .:::###:::$+#", "# .::::#::::$+#", "# .:::::::::$+#", "# .:::::::::$+#", "# .$$$$$$$$$$+#", "# ++++++++++++#", "###############" }; static char *arrow_up_pressed_src[] = { "###############", "#-------------#", "#^,,,,,,,,,,,-#", "#^@@@@@@@@@@@-#", "#^@@@@@@@@@@@-#", "#^@@@@@#@@@@@-#", "#^@@@@###@@@@-#", "#^@@@#####@@@-#", "#^@@#######@@-#", "#^@#########@-#", "#^@@@@@@@@@@@-#", "#^@@@@@@@@@@@-#", "#^~~~~~~~~~~~-#", "#^;;;;;;;;;;;-#", "###############" }; static char *arrow_down_pressed_src[] = { "###############", "#-------------#", "#^,,,,,,,,,,,-#", "#^@@@@@@@@@@@-#", "#^@@@@@@@@@@@-#", "#^@#########@-#", "#^@@#######@@-#", "#^@@@#####@@@-#", "#^@@@@###@@@@-#", "#^@@@@@#@@@@@-#", "#^@@@@@@@@@@@-#", "#^@@@@@@@@@@@-#", "#^~~~~~~~~~~~-#", "#^;;;;;;;;;;;-#", "###############" }; #endif mlterm-3.9.3/contrib/scrollbar/extra/next.c000066400000000000000000000345231441203364000207220ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include #include #include #include "exsb_common.h" #include "next_data.h" #define WIDTH 18 #define BOTTOM_MARGIN 35 #define BUTTON_SIZE 16 #define UP_BUTTON_Y(view_height) ((view_height)-BUTTON_SIZE * 2 - 2) #define DOWN_BUTTON_Y(view_height) ((view_height)-BUTTON_SIZE - 1) #define BAR_RELIEF_SIZE 6 #define BAR_RELIEF_X 5 typedef struct next_sb_view { ui_sb_view_t view; GC gc; unsigned int depth; Pixmap background; Pixmap bar_relief; Pixmap arrow_up; Pixmap arrow_up_pressed; Pixmap arrow_down; Pixmap arrow_down_pressed; unsigned long gray_light; unsigned long gray_dark; int has_scrollbuf; int is_transparent; } next_sb_view_t; /* --- static functions --- */ static Pixmap get_icon_pixmap(ui_sb_view_t *view, GC gc, char **data, unsigned int width, unsigned int height) { Pixmap pix; next_sb_view_t *next_sb; char cur = '\0'; short x; short y; XPoint *xpoint; int i = 0; next_sb = (next_sb_view_t *)view; pix = XCreatePixmap(view->display, view->window, width, height, next_sb->depth); if ((xpoint = malloc((width * height) * sizeof(XPoint))) == NULL) { return pix; } for (y = 0; y < height; y++) { for (x = 0; x < width; x++) { if (cur != data[y][x]) { if (i) { /* before setting gc, draw stocked points */ XDrawPoints(view->display, pix, gc, xpoint, i, CoordModeOrigin); i = 0; } /* changing gc */ if (data[y][x] == ' ') { XSetForeground(view->display, gc, WhitePixel(view->display, view->screen)); } else if (data[y][x] == '#') { XSetForeground(view->display, gc, BlackPixel(view->display, view->screen)); } else if (data[y][x] == '+') { XSetForeground(view->display, gc, next_sb->gray_dark); } else if (data[y][x] == '-') { XSetForeground(view->display, gc, next_sb->gray_light); } cur = data[y][x]; } /* stocking point */ xpoint[i].x = x; xpoint[i].y = y; i++; } } if (i) { XDrawPoints(view->display, pix, gc, xpoint, i, CoordModeOrigin); } free(xpoint); return pix; } static void get_geometry_hints(ui_sb_view_t *view, unsigned int *width, unsigned int *top_margin, unsigned int *bottom_margin, int *up_button_y, unsigned int *up_button_height, int *down_button_y, unsigned int *down_button_height) { *width = WIDTH; *top_margin = 0; *bottom_margin = BOTTOM_MARGIN; *up_button_y = -(BUTTON_SIZE + 1) * 2; *up_button_height = BUTTON_SIZE; *down_button_y = -(BUTTON_SIZE + 1); *down_button_height = BUTTON_SIZE; } static void get_default_color(ui_sb_view_t *view, char **fg_color, char **bg_color) { *fg_color = "gray"; *bg_color = "lightgray"; } static Pixmap create_bg(ui_sb_view_t *view, int width, int height) { Pixmap pix; next_sb_view_t *next_sb; short x; short y; XPoint *xpoint; int i = 0; next_sb = (next_sb_view_t *)view; pix = XCreatePixmap(view->display, view->window, width, height, ((next_sb_view_t *)view)->depth); XSetForeground(view->display, next_sb->gc, next_sb->gray_light); XFillRectangle(view->display, pix, next_sb->gc, 0, 0, width, height); if ((xpoint = malloc((width * height / 2) * sizeof(XPoint))) == NULL) { return pix; } XSetForeground(view->display, next_sb->gc, next_sb->gray_dark); for (y = 0; y < height; y += 2) { for (x = 1; x < width - 1; x += 2) { xpoint[i].x = x; xpoint[i].y = y; i++; } } for (y = 1; y < height; y += 2) { for (x = 2; x < width - 1; x += 2) { xpoint[i].x = x; xpoint[i].y = y; i++; } } XDrawPoints(view->display, pix, next_sb->gc, xpoint, i, CoordModeOrigin); free(xpoint); return pix; } static void realized(ui_sb_view_t *view, Display *display, int screen, Window window, GC gc, unsigned int height) { next_sb_view_t *next_sb; XWindowAttributes attr; XGCValues gc_value; next_sb = (next_sb_view_t *)view; view->display = display; view->screen = screen; view->window = window; view->gc = gc; view->height = height; gc_value.foreground = BlackPixel(view->display, view->screen); gc_value.background = WhitePixel(view->display, view->screen); gc_value.graphics_exposures = 0; next_sb->gc = XCreateGC(view->display, view->window, GCForeground | GCBackground | GCGraphicsExposures, &gc_value); XGetWindowAttributes(view->display, view->window, &attr); next_sb->depth = attr.depth; next_sb->gray_light = exsb_get_pixel(view->display, view->screen, attr.colormap, attr.visual, "rgb:ae/aa/ae"); next_sb->gray_dark = exsb_get_pixel(view->display, view->screen, attr.colormap, attr.visual, "rgb:51/55/51"); next_sb->background = create_bg(view, WIDTH, view->height); next_sb->bar_relief = get_icon_pixmap(view, next_sb->gc, bar_relief_src, BAR_RELIEF_SIZE, BAR_RELIEF_SIZE); next_sb->arrow_up = get_icon_pixmap(view, next_sb->gc, arrow_up_src, BUTTON_SIZE, BUTTON_SIZE); next_sb->arrow_down = get_icon_pixmap(view, next_sb->gc, arrow_down_src, BUTTON_SIZE, BUTTON_SIZE); next_sb->arrow_up_pressed = get_icon_pixmap(view, next_sb->gc, arrow_up_pressed_src, BUTTON_SIZE, BUTTON_SIZE); next_sb->arrow_down_pressed = get_icon_pixmap(view, next_sb->gc, arrow_down_pressed_src, BUTTON_SIZE, BUTTON_SIZE); XCopyArea(view->display, next_sb->background, view->window, view->gc, 0, 0, WIDTH, view->height, 0, 0); } static void resized(ui_sb_view_t *view, Window window, unsigned int height) { next_sb_view_t *next_sb; next_sb = (next_sb_view_t *)view; view->window = window; view->height = height; /* create new background pixmap to fit well with resized scroll view */ XFreePixmap(view->display, next_sb->background); next_sb->background = create_bg(view, WIDTH, view->height); } static void destroy(ui_sb_view_t *view) { next_sb_view_t *next_sb; next_sb = (next_sb_view_t *)view; if (next_sb) { XFreePixmap(view->display, next_sb->background); XFreePixmap(view->display, next_sb->bar_relief); XFreePixmap(view->display, next_sb->arrow_up); XFreePixmap(view->display, next_sb->arrow_up_pressed); XFreePixmap(view->display, next_sb->arrow_down); XFreePixmap(view->display, next_sb->arrow_down_pressed); XFreeGC(view->display, next_sb->gc); free(next_sb); } } static void draw_up_button(ui_sb_view_t *view, int is_pressed) { next_sb_view_t *next_sb; Pixmap arrow; char **src; int x; int y; next_sb = (next_sb_view_t *)view; /* clear */ if (next_sb->is_transparent) { XClearArea(view->display, view->window, 1, UP_BUTTON_Y(view->height), BUTTON_SIZE, BUTTON_SIZE, 0); } else { XCopyArea(view->display, next_sb->background, view->window, view->gc, 0, UP_BUTTON_Y(view->height) - 1, WIDTH, BUTTON_SIZE + 2, 0, UP_BUTTON_Y(view->height) - 1); } /* if no scrollback buffer, not draw */ if (!next_sb->has_scrollbuf) { return; } if (is_pressed) { arrow = next_sb->arrow_up_pressed; src = arrow_up_pressed_src; } else { arrow = next_sb->arrow_up; src = arrow_up_src; } /* drowing upper arrow button */ if (next_sb->is_transparent) { for (y = 0; y < BUTTON_SIZE; y++) { for (x = 0; x < BUTTON_SIZE; x++) { if (src[y][x] == '-') { XCopyArea(view->display, view->window, arrow, view->gc, x + 1, y + UP_BUTTON_Y(view->height), 1, 1, x, y); } } } } XCopyArea(view->display, arrow, view->window, view->gc, 0, 0, BUTTON_SIZE, BUTTON_SIZE, 1, UP_BUTTON_Y(view->height)); } static void draw_down_button(ui_sb_view_t *view, int is_pressed) { next_sb_view_t *next_sb; Pixmap arrow; char **src; int x; int y; next_sb = (next_sb_view_t *)view; /* clear */ if (next_sb->is_transparent) { XClearArea(view->display, view->window, 1, DOWN_BUTTON_Y(view->height), BUTTON_SIZE, BUTTON_SIZE, 0); } else { XCopyArea(view->display, next_sb->background, view->window, view->gc, 0, DOWN_BUTTON_Y(view->height), WIDTH, BUTTON_SIZE + 1, 0, DOWN_BUTTON_Y(view->height)); } /* if no scrollback buffer, not draw */ if (!next_sb->has_scrollbuf) { return; } if (is_pressed) { arrow = next_sb->arrow_down_pressed; src = arrow_down_pressed_src; } else { arrow = next_sb->arrow_down; src = arrow_down_src; } /* drowing down arrow button */ if (next_sb->is_transparent) { for (y = 0; y < BUTTON_SIZE; y++) { for (x = 0; x < BUTTON_SIZE; x++) { if (src[y][x] == '-') { XCopyArea(view->display, view->window, arrow, view->gc, x + 1, y + DOWN_BUTTON_Y(view->height), 1, 1, x, y); } } } } XCopyArea(view->display, arrow, view->window, view->gc, 0, 0, BUTTON_SIZE, BUTTON_SIZE, 1, DOWN_BUTTON_Y(view->height)); } static void draw_scrollbar(ui_sb_view_t *view, int bar_top_y, unsigned int bar_height) { next_sb_view_t *next_sb; XSegment line[2]; next_sb = (next_sb_view_t *)view; if (bar_top_y == 0 && bar_height == view->height - BOTTOM_MARGIN) { /* drawing scroll view background to clear */ /* FIXME: should use XSetWindowBackgroundPixmap() */ if (!next_sb->is_transparent) { XCopyArea(view->display, next_sb->background, view->window, view->gc, 0, 0, WIDTH, view->height - BOTTOM_MARGIN, 0, 0); } else { XClearArea(view->display, view->window, 1, 0, WIDTH - 2, view->height - BOTTOM_MARGIN, 0); } return; /* if no scrollback buffer, not draw bar */ } /* rise up/down button */ if (next_sb->has_scrollbuf == 0) { next_sb->has_scrollbuf = 1; draw_up_button(view, 0); draw_down_button(view, 0); } /* clear */ if (next_sb->is_transparent) { XClearArea(view->display, view->window, 1, 0, WIDTH - 2, view->height - BOTTOM_MARGIN, 0); } else { /* FIXME: should use XSetWindowBackgroundPixmap() */ XCopyArea(view->display, next_sb->background, view->window, view->gc, 0, 0, WIDTH, bar_top_y, 0, 0); XCopyArea(view->display, next_sb->background, view->window, view->gc, 0, bar_top_y, WIDTH, view->height - bar_top_y - bar_height - BOTTOM_MARGIN, 0, bar_top_y + bar_height); XSetForeground(view->display, next_sb->gc, next_sb->gray_light); line[0].x1 = 0; line[0].y1 = bar_top_y; line[0].x2 = 0; line[0].y2 = bar_top_y + view->height - 1; line[1].x1 = WIDTH - 1; line[1].y1 = bar_top_y; line[1].x2 = WIDTH - 1; line[1].y2 = bar_top_y + bar_height - 1; XDrawSegments(view->display, view->window, next_sb->gc, line, 2); } /* drawing bar */ if (!next_sb->is_transparent) { XSetForeground(view->display, next_sb->gc, next_sb->gray_light); XFillRectangle(view->display, view->window, next_sb->gc, 1, bar_top_y, WIDTH - 2, bar_height); } /* drawing relief */ if (bar_height >= BAR_RELIEF_SIZE) { XCopyArea(view->display, next_sb->bar_relief, view->window, next_sb->gc, 1, 0, BAR_RELIEF_SIZE - 2, 1, BAR_RELIEF_X + 1, bar_top_y + (bar_height - BAR_RELIEF_SIZE) / 2); XCopyArea(view->display, next_sb->bar_relief, view->window, next_sb->gc, 0, 1, BAR_RELIEF_SIZE, BAR_RELIEF_SIZE - 2, BAR_RELIEF_X, bar_top_y + (bar_height - BAR_RELIEF_SIZE) / 2 + 1); XCopyArea(view->display, next_sb->bar_relief, view->window, next_sb->gc, 1, 5, BAR_RELIEF_SIZE - 2, 1, BAR_RELIEF_X + 1, bar_top_y + (bar_height - BAR_RELIEF_SIZE) / 2 + 5); #if 0 XCopyArea(view->display, next_sb->bar_relief, view->window, next_sb->gc, 0, 0, BAR_RELIEF_SIZE, BAR_RELIEF_SIZE, BAR_RELIEF_X, bar_top_y + (bar_height - BAR_RELIEF_SIZE) / 2); #endif } /* bar's highlight */ XSetForeground(view->display, next_sb->gc, WhitePixel(view->display, view->screen)); line[0].x1 = 1; line[0].y1 = bar_top_y; line[0].x2 = 1; line[0].y2 = bar_top_y + bar_height - 1; line[1].x1 = 2; line[1].y1 = bar_top_y; line[1].x2 = WIDTH - 3; line[1].y2 = bar_top_y; XDrawSegments(view->display, view->window, next_sb->gc, line, 2); /* bar's shade (black) */ XSetForeground(view->display, next_sb->gc, BlackPixel(view->display, view->screen)); line[0].x1 = WIDTH - 2; line[0].y1 = bar_top_y; line[0].x2 = WIDTH - 2; line[0].y2 = bar_top_y + bar_height - 1; line[1].x1 = 1; line[1].y1 = bar_top_y + bar_height - 1; line[1].x2 = WIDTH - 3; line[1].y2 = bar_top_y + bar_height - 1; XDrawSegments(view->display, view->window, next_sb->gc, line, 2); /* bar's shade (nextish dark gray) */ XSetForeground(view->display, next_sb->gc, next_sb->gray_dark); line[0].x1 = WIDTH - 3; line[0].y1 = bar_top_y + 1; line[0].x2 = WIDTH - 3; line[0].y2 = bar_top_y + bar_height - 2; line[1].x1 = 2; line[1].y1 = bar_top_y + bar_height - 2; line[1].x2 = WIDTH - 4; line[1].y2 = bar_top_y + bar_height - 2; XDrawSegments(view->display, view->window, next_sb->gc, line, 2); } /* --- global functions --- */ ui_sb_view_t *ui_next_sb_view_new(void) { next_sb_view_t *next_sb; if ((next_sb = calloc(1, sizeof(next_sb_view_t))) == NULL) { return NULL; } next_sb->view.version = 1; next_sb->view.get_geometry_hints = get_geometry_hints; next_sb->view.get_default_color = get_default_color; next_sb->view.realized = realized; next_sb->view.resized = resized; next_sb->view.destroy = destroy; next_sb->view.draw_scrollbar = draw_scrollbar; next_sb->view.draw_up_button = draw_up_button; next_sb->view.draw_down_button = draw_down_button; return (ui_sb_view_t *)next_sb; } ui_sb_view_t *ui_next_transparent_sb_view_new(void) { next_sb_view_t *next_sb; if ((next_sb = calloc(1, sizeof(next_sb_view_t))) == NULL) { return NULL; } next_sb->view.version = 1; next_sb->view.get_geometry_hints = get_geometry_hints; next_sb->view.get_default_color = get_default_color; next_sb->view.realized = realized; next_sb->view.resized = resized; next_sb->view.destroy = destroy; next_sb->view.draw_scrollbar = draw_scrollbar; next_sb->view.draw_up_button = draw_up_button; next_sb->view.draw_down_button = draw_down_button; next_sb->is_transparent = 1; return (ui_sb_view_t *)next_sb; } mlterm-3.9.3/contrib/scrollbar/extra/next_data.h000066400000000000000000000034371441203364000217200ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef __VT_NEXTISH_SB_DATA_H__ #define __VT_NEXTISH_SB_DATA_H__ static char *bar_relief_src[] = { "-+###-", "+#++++", "#++---", "#+-- ", "#+- ", "-+- -" }; static char *arrow_up_src[] = { " #", " -------------+#", " -------------+#", " ------+------+#", " ------#------+#", " -----+#+-----+#", " -----###-----+#", " ----+###+----+#", " ----#####----+#", " ---+#####+---+#", " ---#######---+#", " --+#######+--+#", " -------------+#", " -------------+#", " ++++++++++++++#", "################", }; static char *arrow_down_src[] = { " #", " -------------+#", " -------------+#", " --+#######+--+#", " ---#######---+#", " ---+#####+---+#", " ----#####----+#", " ----+###+----+#", " -----###-----+#", " -----+#+-----+#", " ------#------+#", " ------+------+#", " -------------+#", " -------------+#", " ++++++++++++++#", "################", }; static char *arrow_up_pressed_src[] = { " #", " +#", " +#", " + +#", " + +#", " +++ +#", " +++ +#", " +++++ +#", " +++++ +#", " +++++++ +#", " +++++++ +#", " +++++++++ +#", " +#", " +#", " ++++++++++++++#", "################", }; static char *arrow_down_pressed_src[] = { " #", " +#", " +#", " +++++++++ +#", " +++++++ +#", " +++++++ +#", " +++++ +#", " +++++ +#", " +++ +#", " +++ +#", " + +#", " + +#", " +#", " +#", " ++++++++++++++#", "################", }; #endif mlterm-3.9.3/contrib/scrollbar/pixmap_engine/000077500000000000000000000000001441203364000212715ustar00rootroot00000000000000mlterm-3.9.3/contrib/scrollbar/pixmap_engine/HOWTO.html000066400000000000000000000075771441203364000230770ustar00rootroot00000000000000 How to create a pixmap scrollbar</ title>< meta http - equiv = "Content-type" content = "text/html; charset=ISO-8859-1"><style type = "text/css">.fig { text - align : center; } table { border - width : 1px; border - style : solid; width: 100 % ; } th { border - width : 1px; border - style : solid; text - align : left; } tr { border - width : 1px; border - style : solid; } td { border - width : 1px; border - style : solid; } .footer { border - width : 1px 0 0 0; border - style : solid; text - align : right; } </style> </head> <h1>How to create a pixmap scrollbar for mlterm</h1> <h2>1. Introduction</h2> This document provides a simple guide for creating pixmap scrollbar for mlterm using a pixmap_engine plugin. The pixmap_engine has been a part of mlterm since version 2.8.0. <h2>2. Image file</h2> <p> To create the pixmap scrollbar, you will need making images which construct a scrollbar as the below figure. The images must be formatted as PNG, and you must not change the file name. You need not make all images. For example, in case of the below figure, there are not bg_top.png and bg_bottom.png. </p> <div class="fig"> <img src="./HOWTO.images/fig1.png"> </div> <h2>3. Location and 'rc' file</h2> <p> The pixmap scrollbar location is $PREFIX/share/mlterm/scrollbars/[scrollbar_name]/ or $HOME/.mlterm/scrollbars/[scrollbar_name]/. The first thing you will need to do is to put the file called 'rc' into the [scrollbar_name] directory. The 'rc' file is a simple text file. It has some parameters which configure how the pixmap scrollbar is shown. In the 'rc' file, lines starting with '#' are ignored and the first line must be the following line: </p> <pre> engine = pixmap_engine </pre> <h2>4. Parameter</h2> <p> For minimum configuration, you need the following parameters: </p> <table> <tr> <th> key </th> <th> type </th> <th> default </th> <th> description </th> </tr> <tr> <td> witdh </td> <td> decimal number </td> <td> 0 </td> <td> width of scrollbar (pixel) </td> </tr> <tr> <td> button_up_height </td> <td> decimal number </td> <td> 0 </td> <td> height of button_up.png (pixel) </td> </tr> <tr> <td> button_down_height </td> <td> decimal number </td> <td> 0 </td> <td> height of button_down.png (pixel) </td> </tr> <tr> <td> top_margin </td> <td> decimal number </td> <td> 0 </td> <td> top margin for movable area of scrollbar (pixel) </td> </tr> <tr> <td> bottom_margin </td> <td> decimal number </td> <td> 0 </td> <td> bottom margin for movable area of scrollbar (pixel) </td> </tr> </table> <div class="fig"> <img src="./HOWTO.images/fig2.png"> <img src="./HOWTO.images/fig3.png"> </div> <p> Also, for more flexible design, optional parameters are available. </p> <table> <tr> <th> key </th> <th> type </th> <th> default </th> <th> description </th> </tr> <tr> <td> button_layout </td> <td> string </td> <td> "none" </td> <td> layout of button ("none", "northgravity", "southgravity") </td> </tr> <tr> <td> bg_tile </td> <td> string </td> <td> "true" </td> <td> bg_body.png is tiled or scaled ("true", "false") </td> </tr> <tr> <td> slider_tile </td> <td> string </td> <td> "false" </td> <td> slider_body.png is tiled or scaled ("true", "false") </td> </tr> <tr> <td> bg_enable_trans </td> <td> string </td> <td> "false" </td> <td> use transparent background ("true", "false") </td> </tr> </table> <div class="fig"> <img src="./HOWTO.images/fig4.png"> </div> <div class="footer"> revision: $Id$ </div> </body> </html> ���������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/HOWTO.images/������������������������������������������0000775�0000000�0000000�00000000000�14412033640�0023435�5����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/HOWTO.images/fig1.png����������������������������������0000664�0000000�0000000�00000113177�14412033640�0025003�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��X��&����,c:��� pHYs��a��a?i���tIME 7,:�� �IDATxyTS$y š'`A,RzP "ⵈ1Qh:uDqy<P(\@&e*ˢbEW(ZVQ+'L?I!`<r=|yib1  x&@APAAAPAAAPAAA6jhdA"Pep%."b2U^ `( B  EF7_(B#z B  EϞ=SvhgAAAPAAAPAAAPAAAPAd 񈻻;qp9G R%)2sV^qB  cE!G "  ! Jjjj/q>ebbB" �2%|~ff%K )ŋe"RRRutt,X'jmYSSoiiIhѢEMOn$W]]]III... eʔ)?&7FO~ yɓ' Ǵix<^yyy@@@jjSmΝ텅UUUDv@z//7oZYY1 VWWw'N&''S(jQTTIӛN>d2KJJde\XXd2=<<NJKK7Bl'OV\y[[[???}}p\.[TT ! `06lp!==="D$effyxxTTThhh($TUUw^S;::VXq޽-[H\/_Hgr۷o[[[? Yt͛d"&d2Mtȑm۶c"77KwFQPmm+WȐL&Cݺuȑ#+:11*!!_C //O?N/ �<zRMD|ͭ[RSS0< LJJNIIa0v322r1>(2Btv?BZ@B/s,((>UlvS %**J$J/_GLtճ/mݺ&R(< r7ni8B %QQ8*Nf̘!Bqrr_ߛsU$TWW;990|�{tafff/_nK?&RH4ݻ}Ν;HB ܶ v<DDȘP(2kW$ɓ}>dr?٣DBQHjK&"Hhry(Ba_yvwws92"³g W'@l,,ZfH3#TIFڪmlldO_.9�---&Lӧ+ֶR x+++/wj0(Ԗ~L$*++fayڵk|>J>{%|:#Daqw bc!!>@Sst5e׮]2}Ė!-�pBoyf0OHkymKttL.%%L&7L&Y<&>o>|@QD(,.OOGXW^IBD"Qrr]lmmCCC@ooo XM F?tjgg!-AAA%%%aaaVVVCdEr̙oJ(555""b!!!3g8͚5+"""##CZby<g}܌FU;wE8y**`<ػ<<!'v*oQ.`0Ν;9ydbofoo_\\ED4iRBBBPPի?gϞ}wWZfccc-[fll\___\\`0<&+aÆB:NEEEҫ�jkk\~vsuu500xaqqX,>^SAJ?Á f͚5oߎ---mhhvppؾ}t3gŕZ_|1-,,^p?K##yt}I]&&&QGGgΜ9,K&nٹٯ_633�42d`Epp L@dسgϔ]F@Hr8O -(([hl߾=++MYW=B}Oà |0]N>֛^zǎl6ʕ+ҧ^x"IP"믿BCӝ9a„={ե̀B bL` 'NXPPwXu}!2D7n/\狢G @DFd2yĦ ! Zq8ABd|1Á~KABD5A@  !2$A!DƵp B#B4:ABd\;8 Ȩ#@+i8PiL! !2%P2y3D\BA!Dƍ#8$" 8Y[qu "Zq8ABd|Á"T@\> Ёc, T@ɇyG\A!DƢA!DY( (ȸvGfVٳ"cHqu (ȸ@D_@HABDG B8N%APǵp  W"kGAPǩp |cM++!1m;A({aX�Up%)C2sV^q B"|}}"Rp  vq8P>cƍh A!DFp HD&P8/h@%O<YMMM__ř@:N?#|ҧLLLH$RAA�@f$9\d!BxRD"QJJ΂ bB핳-?kjj--- -Z/W܈Ϟ=cX4---Mr;55uzzzjjj~aHHHmmmጉ2e Jutt,--K_ŋP(KKˀ�1o /}WWWRR.B2eJppǏaԎ\G8 ">ғ'O2 ---iӦx򀀀SN+Ν; @mmށ^^^7o޴b04ٳ'N LNNyS__ߢ"OOO:ti&YRR<djkk{xxL:㕖D |e˖͚5y[fϞ秫{޽Ç8{t:S� VyәLsss322r^'O\Ν;~~~<r\.h袣C|႘xqluqG2�~rσ OrI>A֭� -[zJ. ҨTCggt~?Df`{{-JD6"Ν;{$777{$מ�p1m߿(,W܈SNw^>}Z:ϟ@AAbaaG X\]] �=%}BIII MMM^^^nݺ!4<ZSS3//Ox>>>JeQ ;|989#ʬ\2##COO?d2>tЭ[9;$ >Ӹ:$֒YYYGU{(44ouVjjr;t{X a„ }G}�MMMfff?=s@"r??%%_~vLMM ,X0䦐'%%UWW0 ;Ȉq1BUG`qe}kx^^9}BDEED]=bh4'';w(}h֭&&&H/^,8::544vx%"aYYݻ�`ҥ<:%\?ZjjrSs\ƍeQ{E!DPOBN| � ƍ0inh3f<EP~Wy/Vzuud�p]@CC1^|9Tc1J:;;c&-@MMO?D"�=zi'NV~NɟUUiCk y.ݻw-;w(}Nqj;:k롳�"PqP B)"s'QB {|XfU)BbP[7DRhEsB٭Z"fϞ �&Mvڕ+Wrss5kJbqߚ~Yi enBdH%pܮ 54@M +} uu�X?~Ҳ9Hڪmlld5_.9�---&Lӧ+ֶR t,*++/a0(Ԗ~L$*++6k,XWߛ7o:;;$k.B9%2=W|B&׮]T*YSw4]$ N oÁB!<?Wɓ11w/DD@x8C~>�Pmf6Zڷk.'&&0 h z+͛7V4hllLOOO8pD"]vțh[e7)))ϟ?g2 >6mt �޾};gGGGPqFo4cƌE=z�9%�bZZZ:$SvޭlSȄd677˜ۇгPjrI@I?@�l(6͜ `n`a&&>*E X,VJJ '}VGٵkmhh(cǎO>2e  F?QNRl"loo/JJJnjee5MV-gΜ ׿#1QzzzDDٳeNf6lؐ!d޿ٳ</77ۛ~D3:%ĵɉR۶m G#""{b|QI---<o˖-(:cO"{|>twS>ccȞP`fд Iߦ<[Yr ƹs<=='OL,j틋h&MJHH ^z~ٳܹs(ZKKVbٱ˖-366/..nnnf0T5W-gÆ t:0QYY444*}0^^^ ŋkjjΞ=+ =J HHHX~=055-**ziNNN�444JJJ#""LLL=zt̙SNXB wZwTII qGŹ<|X,?Ef) !> KÁ8|Q}:|ck65kn߾ZР}v???3gΌ+))imm511Yj?/b[XX\z577?~˗FFF lBmYvMLLLyyyccΜ9s"##Y,V_&a^t)777;;;++͛7 cǎ3gΔYTTk.~Oɟ?ُ?Fі/_g9ְwTvv6фׯ_y{{GEE~'Fu)i3_5k4/'o:f7nOר2$'̓͛GikdB*uG"ވ ۓ'Μ9sEr8Oh؄lBCV},777gY,Vzzz@@�z1JG'Oo'~IN޻hZIG\DիWرf_rӶ_x5څB8쌮 CTzDiEɡNNN0aBKKKii={LMMQKccxLÁҲ 8Cz0R"^p! @*ĉ qP~%P2wJ } @�!#?????_5sCKUUUEEō7Z[[.\8狢Ҩp`޾{d8|::z5!2<|b1� c2&!2A!TpB/XYÇ  ! Tp|S!CO@[ܻ  8C;8$S#>ކ B88$Á#95  dW8@ܜAp3@ܫL9HFA!.DApli?ÁB!<  ?""yܜzpdspƍ0a<x�Ÿ9Ȁ"@7{D#Q{;�=~"S# ߶�tv K (4#�opp>ABB~Rd\+ c2�AA!DAqʨm۩GAAAAFcg<# G  ( B  (  ! "  ! " ȸa- 2-((tAA $#! 1 (ÆR!"~kAjkk'OxL@;fWWWRR.B2eJppǏD"S D*(( RH%KR( /חHUSSoiiIT~ѢE}U~ɉ"(%%A]]]GGgyyy28J2<BQQNqI1m4W^^z)sssI'O\Ν;~~~<r\.Hzܹ*::ZT}}͛7 F;{')tB&1uTWZZ*2Q(oQQ'Nojj:}4,))&Cn%m�?DQRuƖ-[^z%  iiiT*looD<GWW�֭['ҥCmmmTjFFtmmmD;w'%%Q(vy޽+kOOO�8vtJIX wl L'ʕ+322;'d2aaaG cǎ1 FFF\.wٲe{/%11*%%OwA^^^}}}\\\ppiӤ+ޣ򡡡]]]۶m'ʚ8qѣG7oL"cV~Td- rss\.rƍcR({&yyyl6[fQQQ"PoݺDRyE.3{DhNNNwܑ BUBݿ~/ZȱF͘1C) 믿넸{Qz0LsNNN=F%̟?<RΒ+v {433{jo%AƂ8V_gBa"=<OeDrVD"me E:0X A!DDnmkk}uwC׮]2#_tikCee%�HpT^ TVV $0X A!T%iQx9Gصk%!11E2�� �IDATd6779rwL>o߾ׄ`4662$iڵ2ϟ3Kd BAFNڲ2+IH$JNN޵kmhh(6k֬ ix}YssjggN,YYYI'9sLHH۷o+1{쐐IxDD̙3{(r9+! \PNUN!e0Ν<y2~/..zաURRj*6j``bX|y*:hii?("66vٲe =p8 6teeewvv.**Аlhhprl+!(22BGX>=^f۷cccKKKo秮.իٹٯ_633�6HEr8Ǐ|h޼yt:tkĔ766̙3'22b24AVB׋DU qپ}{VV̳,+=== `x3*kf%A7oL>]MMʕ+ҧ^x1wGw+WM!JxG!r]*t''}yzzN0tϞ=uuuiii믿!VBBd wd҂!x\]]/\(>qĂ?AJ"FFUYRS6#qo Y`P2毊D7n/\gBd@&ϟOKhA=BU ! "  ! "  !  ՞5gq( ! " Ȑ2XpڏOǷs^oAd3OX#A/Bhm~9ıH§ )]]PV@A!T `QGzh6>xX"E"ZB1$&4)&  d"#X>>uj-jhH)/PHP{]izzb� -jj:@Dg 0ihi @&ffF*P2 #,D"[.??o�py+#|n}˧F Ib1[]]Mdթ@@]]PTB!.H@&ôi ( VVrID554P2AP1/FYBڛ7 B<PC� E?�D"x D"耧O=)QMCCy%MAhD)q71zH&P46\�Lj JADA!Q(06~wlaѿ)[2%-dJ;(زmm9s0M6|�222\۷;::&M9eʔ_4駟^~mff駟.ZwDdO?ybŊ;v1c$NPPPZZڭ[{$p8,رc7odo)--}왶#Qy"P(LMMMMM{.Jutt f0$IFPLKoH!ɓ CKKcڴi<< 55ԩS撘O<Yr;wlmm<xr\nQQRy󦕕huuugϞ=qD```rr2E744Z͛ӧOg2!ҵŇ655򅅅L&S[[cԩ<Tf 9,**MMMOf2%%%d2YyFP1$jR(J&NaÆC!"(333,,ãBCC�:::֯_/qeZ[[zu+Vw^FFƖ-[$E|3CCØ"ݽ*%%%00P"3l6{ӦMΝpbccuuu%7n܈L&dKWȑ#۶m<˗o߾mmmMg0gҥSFPvXGdJfLgrʌ >:2f|~XXؑ#G ))رc C:]lŋTtbb"!l ₃M�)))KBBBpptdSS¥K^tIe˖�IÇTjHH{+ޣ򡡡]]]۶m �feeM8ѣ!TiDVIfz&q`cm3߭K@fWǏI2Inmm�{{#0(~᫚3) 'M4q7nSKKˣG$ߢERh{{"돒+Vر�̙ٳ'Oe+WHnaa1}J"ӧON~܁U[XXL:ȓ񌌌z\p;wZz]G/bL�_}0wەF|�Bqrr*--w4�U]]]N5?WUUXB 䧶M~'GGG¡ ':STgg~A:аwL33˗/K2FPq/0оK&@mʈD"X{3B|W4LgHH$X&= JHH tvttΟ??LI]Y2cR(hCnaAFN2eQajׯ_vϧJOV遷!/ֶR Hfkk[QQݭ.oWǘlll.\rN8ŋW^ TVV)j!02f"*#&8:ܹ͟^^_}fCX�T]vt[ZZ$7Lfss#GzS^ 1==]{wvZ"b:tHD޽wxpp7o\Ç'M-O壣e)))ϟ?g2ZCFPdļL1yܺeee,իWHk.[[P"0,,l֬Y>fjgg!-AAA%%%aaaVVV=mmmׯ{Wc͚5&&&~嗭[v"""fΜ#̙3!!!o߾|jjjDDٳ;7ʰ026_@6~9}Mq\.8wɓ}qqֻ{[KKdժUl6;..Çb...2E.[ظ`<xPFIIwDDDBBɣGΜ9uԩ+VƖ-[bcclvz644p86l(,,D߿\TT$PNaaAf͚۷oƖ988l߾ϯ0իWsss}μttt�F)\s/_͛7/88Nbff?ggg緵h˗ٳ;wwX%֮]kccS^^ب3gΜH5?z�ZG8n[RֱcԩS#sBp8۷gee<bӥW"BCCSRR~W[[FVǶdԳz;v+WXZZJzEtt6 ޽{lWWWyTP,"2t''}yzzN0tϞ=uuuiii�_.!<zh{{<&T ! # 'NXPPCT>}h0B-֐qKUU}V==={{ ٌ N$sYB'L?>'F@  ( B  ( 2ȨD8bA¡.@Av" ( B  ( 2wȨd}AA=@"I`T}AQ@mTf$C*E!T{C*G =un�145 (M^Naص X `EEDQ 2/!8ynބN4 Tj23"Gx~ucc:`$2LLBAS ;/cDB呗}w$9ҥ�| GOR3`pvQI?)H#BDb(dQ>k|FQ:P(`fffRğ!?OGE_("QQp:�?_~ _~ C~>\ϟP6S[[?yd555}}ŋgffJ+))EWWBL2%88�@"|}}W4\d!BxtTPP@ԇ@fBC</((BGG&..jUU՚5k(_W^pɘeMM%aE�Y$888,X //Ob!Lz\-'O=7G7FxI1m4W^^z)sssI'O\Ν;~~~<r\.h�z//7oZYY1 VWWw'N&''S(�عsg{{{aaaUUUtt4V[[wBJXdISSիwǎo޺uҥKuuuL+W={400L&S[[cԩ<T9,**MMMOf2%%%d2Yy UA<S>?wr!ׯ9֭y&&bSS0qJUqcX #Fudݺu�e˖W^I…BaZZJupp$ۭ555D"$2uY5EREܹw2KQ(["D{�==?X.�`ǎX߿(wޕ|'�;vLQCxxQXQDcc1xw[xb!OK)!)) �:Dozs&E r�)))2OdÇB%;wG'ŋÅBI ÇKGŋ , eBT#Trp0۶7$&p6.Ic.((>%~r\KKˍ7ʺ({U^yyyl6[fQQQ"P{D={6�899ivɓ[`֭&&& ,_G4tI2.cf :;?{x<عf c4mƌ}''RݻwܤǢ;wjwwwJ؄8ݽ{W [==Ѵ%�Juvv {433|_&p s9 \Ͽ۶Fz>*Gu rE(JN=~}ݭdr?!L$)Zdۻ}_]l�;2cR(hC~q"9s`rܶf"UWW|i^~]rڵk|>J|%Ek'Ѷ@MM;�rAIAeeyeBF#T Etqy$11mmK$?*Ů]dS--- ƻn2#Gۧ Fccczz,c8@"֮]hJV!ez)))ϟ?g2f˄"_H_U.++cX E"Qrr]lmmCCCYfEDDdddHy<g}< Ythh]xx8A=(($,,Jҕm_DDD̜9G3gBBB޾}+mԈٳg(Z2.2`ר*d#7"~EQr\q9OOɓ'k7{{b---"VIIɪUlv\\Çb]\\dv Iϟ']lq}}}qqqss3 (틆gÆ t:@YY444Ш!L !>Egۚٳ`ڴq0O׬Ys҆mmm۷KǴzjvvvnnnvvׯ̼ttt�F)d!Ep8Ǐ򥑑Ѽy󂃃tlgڵ666111卍:::s̉dX2G.o^&d_$bZ6q?7o½{̝ NNZgYYYnnn2ϲX�< +/ ! )ý{p,TWI@Of7oL>]MMʕ+ҧ^x1wGw6.Vktt"g!?^xH 7qCӝ9a„={եׯP/B ҋqۚQ 'NXPPCwGeBF 5ړ5?P[mk~ED7n/\'"eB#Dqۚ L?~L !2EhiGয়3fwA!D=Kq> (8VDܶAB4xWDܶABQ"KqAPqmkz("n[  !2.A5"HOEtwӶ5=""BqEmkA!DܶAM br3BT$&Br2�?_~ _~ C~>\ϟP68{D""zү"5"mBXXX̘1oA!DƓ"5R<x\H$"qpApNEtr__ؽ48p�!?BB <t|n߆1hH3e*XZZWLp|>?33s 2 Vfݩ ,SSSCBBzD&JyŢhiiim D*((��%K )ŋj]MME233AuP(9Y$888,X //OGȻ\\\tuu)ʔ)S?~ >G8ءuKg/jٶF&nz8p`_}}} tzee<644Z͛ӧOg2ӧnݚ={{rrr233>"y嵵˖-5k{sªhS^^^7o޴b04ٳ'N LNNٹ/,,d2SNxN277& %-**MMMOf2%%%N'OV\y[[[???}}p\.[TT+ Օޙ]]֭eexUAl[b2UN?g?~BY[['%%7Nww@ɻfoڴI:rGG~iOOOIxSS͛CCC}||$o޼>}< ܹs'UUUݻW+Vܻw/##c˖-7˗AAAiii111Y1L&'9m6 ~jP˗/߾}ښ`08ҥK7o,mKa vJTP_ubcz"Y_|$&Bl,hﶭ /Cw 0F MMMfffc4s@y/iaa #'&&VUUq\i &|w}66�� �IDATQxxxWW$СCr`?&$$Kw}qqquuuIV\.1� ɡ|ͭ[RSS/Q�]]ݬ,MMͣGJSRR t\% (F;'Gv㸂m(=矿SDbIbWo�oŋv�K.' xܼG>5H{Gؽ{wccKk5噛ާ(JTTH$*,,߿ň[n511D/_G4tI˵ܸq&HȘg v_Ԥ-25LMB>@Dj6UDm͍PP��NO0c� X,<ю=f͚DDD3,�UUU+VPSx:;;K~ԸNՀvww̟?�޽+C}R?C?)аwL33˗/K~޽{ͭysŧp,"o"P'ԀJϘ!>]Z^MM$dHCt 7կI]vʕov͚5M(E"Q;;UVْ!#L&%DtD"X,hOnH.3&B&}wuwwÇB8ؘ")N@~Ç۵N"JX5eʢjji@V E=wQQkk.yֶ[pU>/9k,XWWޛ7o:;;]@ZYY �>\[[[uuMή\&׮]T*YdpѾq^||ի7m"|I&75BMMϥՑit˗lMz@XY9P(@hh! �~;oSIرc{4cƌE={VY,VDDġCI=wٴi֭[V^#۷o̙oQe0۷oOOO=)8@"֮]+RRR?W__ dرȑ#yS|>߾}bܩYVc(Ν� �>rs-j^__Y$(V1|!P@`a8|ۍ"x\oooooo3#ʓ6444'''22Jn۶Mammml6f6lؐ!0d޿ٳ2=NRl"ikoo/JJJnjee%̙3!!!׿tttuވDgϖԈf`$,,,'''""BKKKz+۲eKss3>g(ee ,Pm3"=.Z{A Fhmo=W[(*�Z[e;]Duo$$$_`=}4)=())HHHpss311yљ3gN:b Iduuˋ`Xx~MMٳgBѣG݇uZZZϟ_j͎]lq}}}qqqss3cٰaCaa!N<y2+++sQQ*ȟ\&Msuu500xaqqX,>^SpoL~JK  @� ϟCM u42 MmmH88F155YTTk.~z9mmm4m{=fjjzҥ쬬7oXXX0;v̜9SI zjnn.9~˗/͛L{a]&&&QGGgΜ9,C&dgg{wTTwh45lظ8#]?<¸q=Jhk{[x:̜ꈌadp8۷orssybDɄ]]2ԑp{b#2Լw^Wz;v+WXZZJzEtt6nB Z�,,d#>66BClu?OAuDz nNNNwrrڷo ZZZJKKSWWfjj7 !2r{bs… =8qbAAN{21B%c豷:vwC].@ ***nܸڪgoopB/!2̡u ""(XQG\ԁ B(ע8*u/#B:E/K>3e*l;;"B NqQ ckI$Һu%;cUf"(#.@Aޫ ߴURXXXvAPH.e#$OB >Щ#̝ Ú5aaB|<> 鐚 �N32!(l//} %N"z_A(EVD111SLR}Ŕ>xb biiDݩ ,SSSCBBzD&JyŢhiii 5jjj/c5_d!BxlifPPD}vD"eeeoؚKKK-]y"H$JIIqppPWWY`A^^!Ү$]]] 2eʔǏ�Dzu3m@T?8{|:^YY OچUVe2ӧnݚ={{rrr233>㣵˗/]l٬Yoɓ' Ǵix<^yyy@@@jjS%1뽼n޼iee`0h4Z]]ٳgO8LrlfPPPZZZjjjrrtbÇMMMWB&1uTWZZ*yzzӧO3̒liɓ'+Ws玭\.-**§AWG|r/$99>(uzzzRR{vvvWUUJ޿l6{ӦMґ;::~ӧO{zzJ›6ojll,m7oOP[ Ɔ :'w333<<<***OvttX޽{[l/_$0&&Ff:::Ν;J‰Ѣ455<d2ҕ?rȶmۤ+Op۷o[[[? Yt͛m^WW~zI3[[[(2 uThjxx7֖pfΜY^^nbb"O”_~%!!!88X:Դpҥ.]&&&VUUt&LΝ%y:tHQ+WfddHߒd6Ž9.LJJtriӦ)-[{csJ[!SCX!E'P J)eyj{D$%LVkCV><vWkMѮU$N3?nL)_׸χuu݁/ܵkLWƧl|XXXsssDDDrrիQ t BӇF={<rWd`` fϞY=0OG;z$䑦f''FBȬY&LȌBT]UUu۶m2ɤ ECC#&&V:Qz/[la'$$ޣ5255 w>ׯŹ=ŋ%''C޽xb tV22272g 9εk!"bɒ%rws Ao@x1--lٲeWҮq8UU6?+**~F'Jъ zzzPq`2Y^^p<Kul}&ZtK~ND{jjjS;Nibbcׯ_I&g:j_p)))YYY/X`kgH$b ӳmmmό*%Ig3ӣTTT胆 Hz׺T311199999)99yʔ)'N|g0d_E'wJ&)=D"i斖|�U1::!**J d%%%---E"Zqqqkk+OkkkDYuӧO_xa``&{X^^>~x/ңlviii[[r^ii)!.uk7 !Ǐ>}H$?|Ç_[zJKK{@,--/\*0 jO$''/Y.7;vƌoVd^>___sN!TG={fooogg/v]__O?3rkkkSRRm`0|||zЧOD]v{{{+7n[NMJJ>Uxuuu8566!�@p1dFSdް0脄 kllr'N?t徺ݽ299Yn[|A{baaa[YYY&55U:8?RPP>f̘&eFFF~iժU dƍx+W>{Lz㓓#""lmm_iGǼa…uuu,ҫ(0qPPPbb566˻{nff"+(((HLLtuu522}Ǜ=BO_{yyqܭ[:99VTT8q=--mܹo"<ycĈT_~e„ <uꔧgppp\\ٳZ]]_WWr{nҳijj}6c;B?77͍J<F ,((v3>>YOO֭[ԩSj@@6ޅkllGGG=yd"OMLL쌌FCC9slذ=-ccs Oqܵkv,̂ ^WXXXSSblll"##dfff@(:t'O ussy[I;wn\\K3~۷>}VKK>::wkQA'Ox{{_^KK;ǐkCVf~3j߹W;e�\XXXRR?f_;qLQ(FFFSRRJ�wkѣ gggER̟?ڵϟÍ7X,t `+Ҟ?H>pbcc=<< V___XXaÆ N2oѽrvv>sLPPЊ+><''Gs@�&YUUխYh{ʨ7`<zHGGg„ ӧON?~XA_��D_@w޽7YǩүmA?J7x�� :Y�����J)kDް��P"��@�� pj5��!��aBg � jD:[�ނQ��@��(S5Q�P"��@��(lWvjK'AF�P"��@�Ut%"5Sr&��J���B��W&M����D;)ń7"CA � zLB>hkC9$**DW?s*a2蛀�gH^ik#b`@L2jQS3nj!,QWG^� '{7aDBHK "&r.il$7oֿe{;HZZDW&y |}}srr$n/b0/~�@ !̚%g\{;il$ͤFH[ **ނ��%>dC !̬gݻ<TBfffcǎq�@*q^RaNK^طhǎ;vx+**h@0?y)p˷S#*?{X[[gs̑;aB~xڵk[ZZ<( Ǧ#FZKMMͺuN8uWkk̙3L>Zl{{{rrrrrBCC\.8{fffVV?S͘1CnܸWTTTSSby<ҥKUU|ч?/,,wŲ2wwSSSE"իWΝ=rȷy]| y)py)pr/mGQY77RE歩|ѣy<~eeevv@ HMMݻ?m@@͛73338k׮+WJO<gΜ7n̞=ںg=}t,pss{cx<^AAAFFtcƌrUUU'N8|+ȑ#\.WSSs޼yFjhh8}tPPPrrѣGMMM\b͛744v6pwwk׮쀀�]]_U$D<\0RXRXr޼ܻw~70̀�KK˔={v/^̝;,))iŊU.88xҥ755ǎxe†h"zӧOFݳ:rȎ;|||J^jiiI3!! Yf-[T7o%Ǐ߿___ҋr;wѡ7o^II\w'x<KHH}߾}W8ZUUG£GBCCpAx2ño_%ݿ <`TgܸqO622RdƤ~)11Q877w֬YΝ޽,??MzaÆ}W&MZf}߹sgS͛˖-7n\ZZLaBB!mmÇ)BmjRR˥ʪ 5j==55Uz]***[fM"3{XXXsssDDDrrի {)//?x ˕^H$={ٳgqiArñ ew_bԠϏSQQQLLLdd,p 2U/۶msttN&)111-:w3U=۝ϟ/.`:444p8׮]dee1ׯ_⒛vZz-[:ޢ# WZuV@ H$Xd]شiSgw:AʔoޘyI{0--m[lIHHXhQDD\\\:{A]]gEEEkk˽4tv0EH$k׮?|w?Ν{ʔ)ׯKPgJL&),,b]MMo.\~յm'M+AK[1o Ο?% (:b'+++OO.?wٿ@ r'X&)***]CbDw/]`0d6F]H$흭?q![c 1::!**J d%%%---%?Zqqq]XkkkDi&z/ pGV^p7nή a٥mmmrӴ"]kll,//[�miixQVZZjee]pBkko[@МO$''/Y.=;vƌ8ϦT�� �IDAToVd^>___sNW!K.t={foooggE!FAVVVǎB\nmmmJJ2m (ݻw<ƍA߿ <n߾}G⛏aQ7;[hhhTɌjȼaaajjjWo566_rEztT___~UVV8qBnɲ[+5rȼ<'''//,[ KOO_fZ`` }? VZ5fY|~RR.5jf)#""늊 ӺrZ(└[[[#u-<<<333""BSSsnhh A�/%&&q\cc㼼wfff*2FAAwDDDbb۷?|QzbuuˋnݺIWWĉiiis}1baʔ))))K. 8tP:i<uꔧgppp\\ٳZ]]_WWr;3'\ɓ'=<<FA_&LIOYSSs مBnn5{QQQeeC^^^m;ۅj㝝nݺ/HN:6@Aз輼'O?^$)8ɷ~hhh8gΜ 6tell|9@Nr׮];nܸ^ߵ%Kgƍۼys533+..BСC?600<yrhh[U,XpոB5Ȁ�E>>>Ǐ߾}ӧkkk|~=v222N~zihh迯b0j[i5_[[K}8/Eߍ.tk�G3 鮮r `�YS'P6_vmpp-,,G=|pƍ, !`xm&PvffÉ6lX}}}aa oll |(kcv3g/e999�:::\tѣG:::&L>}:E�( )SP —^}?&BB:[v :cVf~~ܫ}ye/v��{��@`0C(�D�� ���U0hF�P"��@��tU0 �@CW�{P5 ��B���!������A�}ח`tb0dSt�B���!@?cff6vX�!ڱcGEE[^X,Ƒ@`L۷9RMMή)kmm=pɴ q%$''O6MGGGUU>XrZݻ ߭~ƍ˗1BUUUWWmmm|̙L&lѢEgϞȈ`Bحһbff5~xjS,X```d2EGG]8}v***/_naaA3ft<b8))F]]]KKkڴiYYYyA477ٳQ[[d9244~#oNC20 y<@𲿳+W˵=ɳm۶>7''ͭFUxzz^|y<O__2;;[ L|]6 @[[͛صkʕ+'3g΍7fϞmmm.9rjjjΛ7oԨQ O JNN>z韽UWW{yy]|y̘1\.аĉ^b޽{L&!dݺuϟ?-++۸q#5/8[͜9vګWZj֬Y!=g}vĉoVOO#X,ּyBGü<77;vdddYs玻klv@@*D"Q^^~Bo޽~7|d2,--SRR_x1wܲ+VЗκKJO;vÃe˖ :tѢEO=[rwܩCw8>o޼ jc\\\n޼H?~~}}۷SAH6m$_T7DiӦO?ѣOcoݫW޲eK\\\Gx#o߾իWKw}wUKKK \.W(Κ5kٲe'*++ϏީGzyyQ�AJK !<011J*ƍ;}4fĮ%%%O cciӦIO{2H$aÆ}W~5k;wn BSSS ܹܷo$&&._\VSOO/++kԩUUU]{m6: Ɔ ɓx_xx#G9)))2G ,,?'NHHS>dȐ4z={˓\ND'!vR_Oȷߒ#G!_ ~NNNEEE111fRpFPhjj*Sm6GGG:NhѢs9;;[Ճ}ٲeܶ}!!!`͚5,SSS2׻][kbL"3muu5KQ@EԩS=>Vںu@ Xz5=pΜ92r8k׮CD"Œ%KԦMf̘>J�wIn.ٲYC֭mOKKp8[l>|x@@EkeeeGUUߩ?+**~F'JQGR4 244up8?R^pdnɄ׻=XldXe988GqJǏ~t_ڤIGދTT3gD,&Ƒ82c4T[.\8|JJJVV@ /,X%Im?d2VVV]LokkKA-bX"t6c{{;=JEEEK$A,v�<S2L$I{{{gklBkٳ1ra0qr"6 B^f`0 B6]RRҢ./K0 r/^^466?^ŋ(6]ZZ&8[ZZJA}^9mmmVVV] Z[[:=wo Fho'{7Y[Gd.i%T ׉%K;vƌoVH;wʽHYtK>m3{{{;;.J [۽{w}}=˥rkkkSRRbm`0|||>ZllܸQn4))Wy猤⒀ %+^Lr#0.Mbb…ܜtrjhhǎKfT@E NHHΰF???'N?tݽ299Yk|tsXwި(6Fo՚5kRSS!!!cƌh7nǏ\ٳgG 999""VM] HMM>q .ÅA(,+#/lR^N$?oZ[, LAAA~~~\.8//ݻ̫QPPjddtǏ777=zŅX]]믿r[nurrխ8qD{{{ZZܹs|wD"=y򤇇Lj#˄ 555455O:7{CVWWq\/nvc>B?77͍:EEEyyyҍߩj㝝nݺ/HN:(0(H78vTV,^LwɓNjD"???g711o322 ̙aÆϝ;'222ӟ>}jffr׮]۱d3 ,zj\\\aaaMM Ų )n PxСǏL<944ͭW*g۷o?}tmm}tt4^w*##:wO<111^~!WųXCVfWz!~Gڡ"㤸\H82y2"l612pU0Q=R(FFFSRRp P"nq|+=ő#߉Ξ5U|]688ң>|qF0"P9DB,-ƍdҤQ :pm޼Ahkkgffq8XaÆnذj8PBdE+)! 8;#̙3AAA2><''Gt@�,ҵ.ZPhᎎeee%%%.]z葎΄ OE0#p06�#***SL%0(As�@t2!/Fs�@`� @4��!(4��!(o޻G|=C��IGs�@ ׽&��ANg7ԩ� [Dh� @�BP. ��A~��J� 7/��P_4����A��B��B@4��@*4��@*o9��P9��Py#�@*#&��A� ^� T" E�@*o_4��rAh��B@� T: ��A~��J� ��B@4��@*4��@*u9��P9��Py#!��J!�� D"鯛GC%_���B>G}ԇ+WرڅB"M'C�� h}]ńR\L�@*'O!dJr*^� |7|Zݻ S2gn� F]B!Ӧ--��rybB+�G ��qПϥ>def/v_�J���P"0jkkzjk�!������A�� ��@�� �����B��ot=y&?Eyi���%B���!��UtmgC u��(�� ��Ҁ68�� +vB'66dPbfF#.1hc$�`6y!DG#ΎXZFLLȐ!w8�B:Ԉ> דfr:b`@L2ja7� ^BHX9{Ԑ̙DG_%Ϟlh43#$jjF��@%nG}9)+#/C< 55Hn3%|@ԈDDDuR|><�XG ψB M&N$gϒcΝݝpd<FIs3%/^ZRSC**?G!Ąhh}}D#��2p8ښp8D$"Ǐ Af /)zR]MH[k"c}}2b��A8p4?C&N$d:2y2ɤI&CBILLɟsuϞ<F=*Q%X��¿VL&17'K[ۗ57c?7t/^:B*Ș1DK �hHהRitpY4:MTm*!F��@86XZ&997_Gcm-y<{FnK4��Ȉ˖uZS[ш��~27R__fZDc{@4�ulbQVF&N$ 8A.Ja 4j�!A_!B($99ʕ8|"#F(2�zHTM˾zaF#Zn__ߜIInu`,^8;;_@*GPon5x8[nL8pҥ7�޽{5]šѨx 4j�!t훭Y 4jFm up.GLy3 ]7Ąّ)SȂdJE6m";v]dnD 2?XA֬!'?Il,IJ"Gbr"rܿw{=C:b7wƍ˗1BUUUWWmmm2w~u =Ȉ`BHz3g3L33E={VZbqRRִiӲzvߑZɴ qFw~~~MMM n�511iiiy]~EE-,,8cƌN+jnn޳g69rdhhoFG___\2Q"V4|O.vlQup.9o޼QF544>}:(((99ѣZںu?[VVqFj 8R]]u1cp\CCê'N>|xŊ{ePyxx=xرc< ##CE7xzz^|y<O__2;;[ LFfggW\.Wz[nEGGKlhh8r'|滖X,ּyN+s玻klv@@*D"Q^^ AzoJ:*.sNjX,>p@xxyJJJ444T餬lӦMң:ljjrqqyfjjj`` ]L|qHHo.ի?\P(5kֲe/^̝;,))iŊտ.88xҥ+3gδHKKBXyEo ^5O}V^$*&WWת,???z=z $PjJo~:*vןuwwOMMTQQ nmm ߷oߚ5k޽J˗Kʪ 5j=*!!BӇx&%%OÍsssg͚uܹl$ FIMv…wR(jD"IMMuttޗ75wwznhϞ=)Dٳgw% ,HY-QQjiyʫ۲eܛ!!!0++488Xy`_%77wڵ9sLihhp]zBʕ+\qTUmس\l٧~N�>|XOOt^v---MziokUVmݺU H"+DK,כ6m1c AH@hܛrl7 !_;ghh8vNp )P^^>w\f'HM2ru411_oYYˋ1QF͜93==}***$77{XXXUUUMMM^paZ'QMMo_ٽI&!J6P|qQыbD((;^eMTf&Fr7dv+%bnd`` ;{̙3/\Ǔ&M /###>}z!???mm^ٵO"Y"+H$?/҂kۄ2҄q#ik#֑5kF>F!^ŋǏOSWWR__qJXrYYM쒒ήŭ=Hooo]]݃B>=gΜ{oԩ&|O>GyG��IDAT'ʪ˴pq&}]4'8ܴ|)[�%x{zY 6M9sL|rVrkkkSRRɶm`0|||z}|~}}Ν;&GLL̛l$r_~ecccnn!C!>>>/^sNjj*ō7-8&%%ݿuw<n߾}G⇃ 8p'XN'6ݻIi).Ő^WTTzX,޻woTT :׿Ԕ.j0++5k֤JCBB njfcc 񍍍~~~W\yÍ ljj;w| B>⠠j2_+""bܸq2?rgϞI䈈[[[u-<<:"""55U:b.\XWW_ۄ{$PlW"<ycĈT[_~e„ d扉!!!ݻW_ :tܹ'O555O:7{CVWWq;v.khhx{{GDD$&&ݾ}Guqqy8q"NKKԜ;w.}�'O|55h555 nnnI,**tppVKPz wvvӻuV~~D"9uꔣ~>BұdX?HZ^ ,zj\\\aaaMM Ų P+V7.>>ѣGFFF}?̬X C=~`ɡnnn=.6ɷ~hhh8gΜ 6tݍd0˗/puuҢϟ?Ȩwwg۷o?}tmm}tt4XOMFF@ x䉉멝244`H ))y7[Uqw`}ז'DD]U׫>|@($ j}GP*w,OII )@|}!ӯ[&�B׮]|y}ƍY,:ZCB}l_m޼A洵3338Nllǰa 7lPUU~ccc(!(7[Ϝ9b ÇYh}>ZcYYYIIɥK=z3a„ӧyQ!47@2eKU@kJŋD C��R M&NˍCekb� T8q&��Be7-3� s ��A)fÍC��2뛍��A @l��B@l��4IQ/uX|蛭ޢ ako'&B!y� ,웭7�A׮qM,��AJѣQS �BP>5o6��!(V4kJ++7� AY㰤elUU!O��޶vR_gl!QB=ˀb7� 7� R'EYٻM W^� ^LHBC\AC�@2kJ_͆� e,6LoŽ{z8�BPaEjJ�ACf�!(M,6oFl� +5Tl!��uNF,- 7�A}@C�o)v8dMȧܿON2Erwu ? &A��6w\ɓ'd�@G,nThhoOdo~-yb07/_>bUUU]]]''IO>QFFF #''xE@z̜9S__d-Zٳr"lllյMճwSurrc2AAA7nb7O__I r&&&---kX|uNg̘9w744ܿ?=%99yڴi:::|ʕ+eX,޾}ȑ# {pP(~ 設d2Gos!8웾.t1WoՑ9rjjjΛ7oԨQ O JNN>zinݺϟ斕mܸb:TWW{yy]|y̘1\.аĉ^b޽{-|yxx=xرc< ##[OO˗/=WVVfgg T쯾JϞs֭h GO{w!<b͛7ohh(,,Ι3ƍg϶ܽ{ ־yfffvڵrJjm۶|G999nnn666]R|=Mo~(<wqwwv_E"H$듫hk$9Y2yɒ{%.Id$ = oxϵw Zx1!DCC#00?߿_MMŋws6*ፍ֭'OxxxB<ljjLfRRR{{;=^^^T1bȶ6 YfIܜ/Hߵk!ڗ^5._\ٳdv<͛7eNcǤ|}ꏰjه~&H !aaauzP(r ?nii9dȐ,CCCâEުAB?$xQ':Ubb">],wI[� ?XL۳g!dΝ}۷o'$%%mԩ***nݒ=;;[fʇ2dڴi;vB;jmm>}[aqmzSg@Xlmm9v|׮]u<)gŇ~{QL=}?H}biC);뤭mƌ}GOHl,%mm=qx0Wl"_HH{'Xfeewd2ׯ_/sssed444p8׮]S|BT ϛ1۶mF.[L">|XOOoԩ^vm彾k]UVɜS'''cggqv sQ3466Bf͚5azR|:Mr(9"bɒ%r6m2Lq8m&~Jd{7)-X;V(&p~gE_l#SL*wNJᨪoݍ5j̙3b1udrss\˗RSS.\9USSspp9:::Xh5 !$--lٲei(ŗ߭+BSpu;;N4/~xX.f#!K“TQgӣ_'e߹**](=Tn*VS F{w7200={v̙.\?I&嗑O>=t萟u?ww`,PfJ&iee*lmm !.\8|JJJVV@ /,X(ŗ߭B)2vƖ!(eʼi&BASSˠ9xj766?^Oŋ(]]]BH}}ad{nfKKK_ZZJ/7fKJJZZZ)[[[{޺9sÇ̙3dv422/xL9mmmVVV]nmm-H:{/ ptttttvppҮQ/[/\.\hmmUSS8u@ơ;!?(%ݻw-l6!̙3S=[5˭MIIm O2ϯ߹scLL̛l$r_~ecccnn!C!>>>/^sNjj*:4ƍ喖߿wҥ.] ٳgvvvK,Fcǎ1c۷ !]R|=M}q(xuuu8566AJӦ !V?[,ݻ7**f _TaJCCmiaaaVVVk֬Z&ß?RPP>f̘^尰0脄ollrnd```SS޹s?RO?8((O?~ʕ+={&}N#""lmm>~B 8qC#ݽ299Y]]A ;v.QoEg_~wO!$""bܸqx( HMM  E( (TM)!/UV:ҷгH$r'O1b_~0aB~~&5ybbbHH?{}WC;wn϶SSSԩSqqqg:thuuu~~~]]˥quFFFo>~xssѣG]\\d#'Nf455Sinn>y -B?77͍:EEEyyy]̫_SlݺIWWĉiii%&&q\cc㼼wfffv=Jw4Bjjj:8&/mAA}wvvӻu ԩSj=w`Qah,؅#H$***SNݷo_sssYzxxPp.]z޽#P}h3 CCC77Ǐ4VCF:Hh Գ .vgLS07R߄ *5z%K̘1#--U}G::: c၁믋-200PUUE""_~wO֡;%%%e3&&&K,!^w(? 0W ݻzV">ePH R&Tflݡ 鮮r Tk^ۢ<cה׮]|y Q>ܸq#ݕ"6o<Xb�pbcc=<< V___XXaÆ#ĵ'Ϝ9b Çɡ:]G##xkbqIIɥK=z3a„ӧ(�@2e>_7��(u������A��| #��(�� ��Q|>�D�� ��>5 kG_�{0�!{�j�����B���!������A�� ��@�� �����B���!������A�� ��? 'k�"����IENDB`�������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/HOWTO.images/fig2.png����������������������������������0000664�0000000�0000000�00000017640�14412033640�0025002�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR�������Ng��� pHYs��a��a?i���tIME  %v��?IDATx{Pg]$vt&MpiqDGȸx3|ˎ:J\[LQfBEL#Ӥ **r=g, !>v]DV�p�,� X��,� X��,� X��,� X��,� X��,� X�V"H:?D" ]] ��]_{5K`6m*++3o<KKN/mCCKNӦMJQQQ/_֝Z"dgg /%999d2Ԗ^4bw6%"""++k(Nξvիu'VUU۷722j[nꫡW\JKKS(V\YWWRJJJ֭[j!AAAw]`A^^^ff\uoNlnn6l W^՝uVAJKKjܹsuwY*777k߽{7 @s5w\VNxvbMM IIIj�B:SJǏߴϜ9s AT*nd c㏛7o^hСCU*G/9;;kP*^kX {jZ999SNN,,,,..ԻRiggxb=` 6trcf̘j[qq1` #FLNN\V** @Ţrl B&͞=[BJJJ\]] _4i^m <D[[j^7�A_O<f H${633s޼y2rV;%z?.Jy�?٣d2oo^zI;*ꫯjkk O>РނFx`�333Q[SSR|}}MLLA>{ \.wssko aaa[li{WSSӚ5kxՓ?fL O?-((ccc]\\V^yfy<@?eiĉr<))TVݰa&OhhhÍ-[m۶ӧ[[[_Ǐsss~mx3!H4O>p@`AfΜimmlmm;Rꫯfee7|]XXͳSNe�a�@�`�@�` k,� X��,� X��,� X��,� X��,� X��,� X��,� ��>}ߝl7 ]x?V zD݇yӬt^(�CB�x �|HUQQ۫]q�,� ��,� �/$$Dߝ{ou/ev<} 97O/O?;3n8aM8rÇO6-11Iw.aemm-HAމڇ766&&&zzzZZZJR{{9s<yRZZZZ]\\ᑞ7eYYYddo{:1..P&yxx!!!cРA#G\x˗r_?~cwwwL&J_yEoҥ<$Ԏp߾}(;#Forss캴+WթTui&q̀QFheeU^^sNT~~~>>>w=x`hhh~~~JJʀNR;ߪ=CpΝ eff7.\0~pL?&&&nݺu-뾾r<<<_~8p@7Gs =}&jn);ɱ[g~[۵wܹsA066xvzss] ]\\=z;sxމuuurPPhhf^reٕj'>|O={tu;sEFF:D;vJ뵱xzyy Ș<xPw wܙ1c z7$==]VUU͙3G& 0wܮnO  ___B1hР  ޲e˅ [KJJm;ʰHOO:uj\\\yyC6oR&%''$%%!ڽ{wC… ]쬻J899ՑXfK.}qۅرҥK(gddL8{ۃ>L% Kiiit;;wIҵk׶T*ޭ洲ruu-..~uWUtwATN0ǧÍ׬YSQQqԩfdd888z'|ҽ++J?SgF[K\]][]Қ2e ---ikk{ Cdhh8iҤ"]ֻ /Ο?/iǜ9s4]Nii ڻֽ zѽ\hMf] {Lb YnT*R4/"۩]h?~677m^`uo|47tҘ1cϞ=\JVs޸q{k充MMMzBAzS]ڗQSSSaaSoرcj ={fx̙FCCöE!aj*ھ}{ee(ڸpĉEEE[(w{aD}YnӨ;w.Xܹsz?&L{&z=o466_<ߎ;AΝ;WZ%ccc5?#5DQ` ұX''Kj>֠^WWp%K5w_/^?=D ˖-?~|'Ο??33S7orJBBQ.Ydر˖-S(={{x3$lvLיQ޳iFF(>|SW^7nܡCLMM5 6l۶m .ttt9sȑ#o߾!C̘1X#G7n[o 2͛w(6m](T*!:vؕ+W&MtccB##o& @?|ڴieeeyyyIIIm|!򲰰vڡCj#GA/nܸѣn233sqqY|yxxx111Gϯ/>n޾ --MTfff޿'O^hO H%88x̘1׿ۊW {G :ԩSiii)))ɵ(XbyHSRR4}𡭭m``ڵk(/ Oo/ks櫧ΰ+nS\7h>S_6XT._<99yz ۽{wTTO.gX=6|y{g32s+VDGGw֭333 uB'|&xVmE&_Ʀѣqyy]`OxV÷3l:qDTTTLL_~9;;[)y,<f>}ܹsՃ 7no  0ec)s�� �>]t~ �gX�@�j �gXhWzZ t`=Փ0QPy ==Wq^z�,� 7kajhsp� �^!aH�gX��,� X��,� ��,� ��,� ��,� ��,� ��,� ��,� ��,� ��,� ��!�@�` X�@�` X�@�` X�@�` X�@�` X�@�` X�@�` X�@�` X�@�` X�@�,� X�@�,� X�@�,� X�@�,� X�@�,� X�@�,� X�@�,� X�@�,� X�@�,� X�@�,� X��,� X��,� X��,� X��,� X��,� X��,� X��,� X��,� X��,� X��,� ��,� ��,� ��,� ��,� ��,� ��,� ��,� ��,� ��,� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��`��`��`��`��`��`��`��`��`��`�@�`�@�`�@�`�@�`�@�`�@�`�@�`�@�`�@�`�@�` X�@�` X�@�` X�зpښ1Eگc Sw~_،t^(�CB� X�G3)�ΰ�,�xZyY�a�@�`�@�`�@2O/O !!!-V$IHHH|A~ev�ΰ�<{{^{Ё~_$ufħGlڴiӦMΰ˗/GFF>|ڴiMMMtp}A.kkkD-N>111R*ϙ3ɓzbdd4p@ښN6B*:88DEE]|;yYZZwrDQmhh]srr244d---mlhhHHH4hȑ#/^ }?~cwwwL&J_yEo+=B8۷OESSwygĈUUU~mTTTBBBnn]rʺ:JURRn:D335n޼PTT4j(Qrrrbbbv)J[}8pݻ OII0 ?nݺ_TTꫯZZZ^r%+++--MP~Qu}ڵիWNڷooddԳ&BPPP~~o@@;wrss,X7n]pa2NMMMLLܺuŋ[}}}ryxx/qnlޗM0QsN>G':Xknmms8""ͻv244tqqy,)z'rCCCBҢ^SSyʕnggWZZC???AwvvJw l;wnW77]WssaAz[ ٗ5͢lll.^^^^ $%%:];wf̘'$==]TUU͙3G&oOǯ>!P( [lp—_~{޾}{IIɶm"##u�SN+//}͛_ddί7>>ܼyEt8R<<<R4<<㚑ƙ3gnܸ!JyP(uGvM{YwSJqrrrdQfK.}qۅرҥK(gddL8{5,tg}z… _z饴[uzz]tttۻRڵk[ZZtAn5kqqq׫T*y 6l|jaNNԩSsrr ###{|44H2榻(R9a766^fMEEũSޛ= |I` Ǐܞp^bee;R~{kt钫kTZSL t'ZZZ_oIIK&M^WF1399YsEYVT�Qg B&͞=wM{wQ/Ο?/iǜ9s4]Nii ڻֽ׸hALss. +]4`@4{[z7U*v)jZ[fzՍ =y򤧧3g~Yf-Yd޽˗/̜7orOZNjj?~ރC= ҥKcƌ;{.sssA*++mllZͩF rINaa E\~醆3)nod``={<==srrd2fT|x;vZ;ѣGzόϜ9hhh^sx uZJ+++rAN8ѶVEEE[(wc|Æ $88w9,,r˖-mjjjZf͓l({QT&&& ={ B.:=M ,8wO!矯 I޻wO1ׯ'XEǎ {8qΝV山cc>H-*Q; t,66iҥO h-\0??ɒ%F]uqqYz͛u7f޼y?ndDDD}}~xYfi& 駟DEE=FFGGO8qΛ7o^r%!!A%KƎl2Bٳg߻w&bHdddxa??ÇWUU=zիƍ;t萩faÆm۶m…3g9r۷?dȐ3f>|655=r䈿ttƍz!CܼyСCE~#8???00pٲe۶m>}_?~877~8q\.OJJ255վA6lذɓ''&&>oѼ!O6ܼ,//9))[{9 qqq^^^׮];tZ>r䈻"c>=AAA/^ܸqѣGoݺeff|V?`cbbF_]]mmm_|^}AAAZZR̼'Oh"; ﲲRRRjjj?c'''HDlٲӧ8P;=88`̙}:tSRRRkkkEQ\bѣYKII<Çk׮쯕 ,I) ;_t?RjӤT*/_<}t޽;**3,/Wg`:6s+VDGGw֭333  3,ΰ:Qd_~i];v옏lll*++=ڵK/p<?=Guĉ/rvvS @_^RRrsUWW4hܸqoƋ L2E۔/� X�b o �� CB'Hp�KO$n�(s �8�� ��� ��� ��� ��`�42_����IENDB`������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/HOWTO.images/fig3.png����������������������������������0000664�0000000�0000000�00000015113�14412033640�0024774�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR�������п��� pHYs��a��a?i���tIME $u��IDATxyTw_(&ubcբxE[() eԡ1xbhXmF\X:"!--2rG;עsUˆQdHd2,eQNx<}$^/�tƂU��D *�Q ��D *�QnOD/$>]S/.^`1bĈeEEƟVm 0�涯2,�F�fX557v皚B`T @T��D$}|&�Dh}̘1D/Ȟ@:ٱcDž M"dff !$b)55500Y*/^^pBdd+܃꿦&::nرJЎFY`T*9rݻ׶&%%M>Q*zxxDDDfXX*++]]]-466&&&K{.&&~hVt{0`ݴi222_%4ϨuuuYYYfƍwݸqcܹѣe2kEEE^^_||ݻwKRr9s~FEE۷/77wذaX``͛7͛pرu֝;wnʕ3f̰'ON8d|O?zّ#Gr+WdgglٳgϜ9s)ׯ_ )..7nܲe\VjuNNNWҞ|C4 IєQFoT Fٴiqz}}zŔ7|Ʃjmfڔ\.zf޽V3gNQQ1DRVVf^ߴi|uQc0vڵjժ-[l߾0^+++۹sgllYSSP(-ZvYƸ!냂***222x ssNLLܹs;7|s9///ÿ2LR͘1#""쩲k.FsH)##_TLHHHrr1'B +V|GgϞݷo_:uVc$I\\J�fgg$&&(ʷ~-533sĉm`XVVgLf]\\jK/i9B߿O>a_i1l0B.TaNe:}˖-aXr[zzz:0uV 5}}}cYX\~8ER :tʕT#Q@@jsҥ>v[h[ѵ[\\LTz~<&VVVjo븴1S++_~[0 lmm[M7Biiɓ--ۯLJKK'MNɓ;sۉC jD; ha+Gl 2=~e~D?mN[ZZ:jݻÇ{yJ{:0nܸ3gtt̙3Baݻeee|oo /PTT'N//SNuqFz+1LVUU.^uVDpB7nl]sϞ=?ry v͝ ˫@TȊ+y睔B.:::???66vѦ9|[oӪl߾}k֬8q[o7=_jL먻w?bccǏf͚,Z_ÔMAA믿P(o>sAݸqȑ#2lǎR,Y<|𚚚/ҥK/rNNNN< [[ۂիWAAAnnn׮];|pCCCBB:}T*g͚t#G???+++w<r.-wwo6==]R}Zeʔ)111m\.\8vm۶=z_\~}xxxGǣzӧT*ZwޠAfϞ]&sOKKKOOOKK!Cϟa;;;!FYJ/kb,:UdD}gqXXXffSsJZvڽ7<<<999**Qw]9͛n:BqIOOOӻn߾qF[[ۮ\BTzR=<Oɏ}}}7o:x[nUTT$%%=3DR͚5QQQ˗/7ᑙxbsވD>>){R~~~ᄏs玃Ä OnǾ gaa1uVnS�Q @T�f=O;A`TF^{v>{52 їzeKf` *K `T@T~)zsUl!0�D *�Q@T��D *�Q@T��D *귯;gf� @T� >"}u� @T�3,�}SQwQ *�� @T�M֭K] @TzAzhh`ucZRiVZ?uUb]P`M]݋߾-ZZX *mZB8ܩx(W\@Z@TmӨQB:u۶曪7X *[~?#BYMNp{`^MV/9୭EDă{zB 0ߨ==cRnaJe\.EJ?x ֹ !H ̷�֎:-6]񏭒-B8`y2�f9\<֍B �sJ<ssFL4*.nԴi6ZS7ڿ4 oo6nTus;<b| B*=++al�iTZj< ,JO1. W[7s_iH.0�D�뽺K<NjT_`T >&v.U�P=]`T @TX�Q @T�� *�Q @T��xvUVUvqANBhiow!� @T� 0%Kt!.G QekWY`T @ne >+NL ܞMF�D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D *� @T��D0_]؉cnt]#8~HU�Ifq INEތR(z%Kl 0.i: jʪJU�� *�Q @T�� *�Q @T�\Yׂn.WVu)�F�`]T|puU�Pj]c ?_IF�`Wwgԉ=&|Q *�X7_3~*�QiɩR]nYR"0,dS?~յkں"-|ruZFbc 0_OD~ؽ[txz%`FQi~K%MM}dRuiSӳ%%bn!X1 !x: 0amwrζKJ:wwÝ\or""}| /*Bk/4H459ϖ?` ӵ`<GE!6?|ڵ:OOZoewpBX4<[R"rO`QBH:O11?z5 jk-._˧MGBq騻@Tdm}S?B֊ (`{߿aLr1oﻩkP*Rw}q>U�P=:c)Օod @T� ^EF� *�Q7uU�o 0.0�D@`]`T @TX�Q @T�� *�Q @T��xvUVU�}P-YF�DwF+e5iBO~ }?u}c_3?@<JSsSow-F�D *� @T�7W.ltƨQeQ *aaa/%~K)Tb`T1c ̋NCvq…jTFK<1*//>|c@@@jjjsss9RSSRŋ+y$IffB/NV꼦&::nرJUF`T:r߻w#äӧ;::JRr 3]VeeexxkRRD???{{{TsЪ:nϞ=>>> 6mZFF1}ϲe2͜9sFQSSsѨ}687Νߏ=Z&VTT}˗/߽{T*BuuuYYYfƍڶحfo޼9o<cǎ[ܹs+W1c\.wvv>y~w ''nGi~ ={ȑ#r˕+W?]ٳgΜ9~xÔׯ7nٲeW\Qj:''+i yCry~~~ZZQy$2lɒ% b 55566vΜ9EEEB׿/^LIIy7gZ6:::))y۶m!.\h6mdެD")++3@zM>\//G_vZjՖ-[oޭ^{;w_555 bѢEmU[[hE}}}PPPEEEFFoa\w܉;wnoΝ;e7>>^&T3fDDD<*]2 III1DaaaP(Ξ=w^+Cܹ322twrrW*]zݺu*H<<<߿T*Mccc}v'&&(ʷ~-533sĉm`HLL,++۳gL&3]...j^Ɯ!omm'[lC6lBh;T*ݰaN{ԩS[fxv~zwU*СCW\Nbij50WV{zz.]ݵn m+VS\]]}}}#quu耣T*-))1[VVj˫AqG|9A/--<ye%)S:]ViiI:ک<yrwvvn;qȐ!ZI߭7OyFN;:bW^=8كfdv---5]jÇ=a5>`f=ܽ{ sc7nܙ3g=,8sgz~ /566{':mԩS_u>AsWy vu-Lf<PVUUvN^uVDpfX۷ܼyN[C)'xW[_~exx4N{{oܸq+V0L\b;3bѣGwwlXjL먻w?bccǏf͚ӒfѢEZdBCC^SSSXXx &9r0MAA믿P(o>sAݸqȑ#2lǎ=Xz/5/lmm BCCW^]v  tmֆR5kիW9 JX`so^XX?]vٲe 0oMOOWT~Vuqq2eJLLLppp/fӧT*ZwޠAfϞv!C̟?Æ vvvBWWzv.H5~~_~kѩ" )R֮]v ONNbTAo]WNy[NP<y۷ooֶܸ+G7o <x[ ***y^ҬY?|r/Ǿ<Y4MQQw}w &L>}<,,,N~?E*� X5>5wn?fǰ`~5s?_΅-/=o��Q @T� ��D *�Q@T�<>ŕ]h~����IENDB`�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/HOWTO.images/fig4.png����������������������������������0000664�0000000�0000000�00000012105�14412033640�0024773�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR�������z^��� pHYs��a��a?i���tIMEfd]��IDATxkp�QR[�ADʔkPC`ҢT:;vz2:miLm$ڙSOSVHm;A)6DSHB;C`p]}Nw~wbb�Q�1 F(�b@Q�1 �b@ F(�Q�1 F(@Q�1 F�b@v7F":\hb4JL0aڴidy19(~7|i"[΋hw۶m={>#F544b緷o߾}ɒ%Gə0aBEE~n.z衇ƌD{Bu֙3gwO:xѢE999'Oްao_7x7XB[[C=T^^>rȜ'~ _x뭷nݺaÆ577w{M:uΜ9X,7>ݮ#믿;vD"u<u~mmm555eee_~yUUU|wClٲeyyys}e{΋ :/bijժ 7ܐr͛7_;vlaէON~͛B:ujUUUuu7<jԨeݿlٲ^zi˖-sό3BO]w]nng>͛7zcƌ !TTTtyoviiiaƌ7nܼyU ߆VZu7wޙ={v#HUUUb Æ {gKػwoKbm߾=*]?O!. ?%\r�IbcΜ9wq]wu><//'?Iµ^iӦɓ'*s^1F/ĝG]bENyĉ3fg?L{iӦ.-..Qgرz2.]BK~%%%CmhhH~G(((H=\'OΜ93''L>W\9bĈ%\uU_~y5-[=N= .,,,<zh{ !|_ /vȑءC-[BxҺ&L0k֬x ۷//}ϫu^ y}G<tв=[l !l۶-u!\s͐!Cߟ'x*qώ;<СC{.aXxq lݺ5p.kI^BCCC駟N~Z|_yu恵 !vyZ^^޻;1]>Smmm5k[[[ӷrss.]]y{΋</GI}lщΚ5K/M2~߄'/(**JsΜ9]vYo.]ٳǏvڕֱc~L~ΝwDz8R9~QϟdsrrV^PiYliiܹss=-쪫[ZZ<ԇU}:/H'GNsܸq~[`ANNNKCw uZZZlll;w!o  466.\077%\uU_~>=G}ᇯý߶Ç[kٶmӧdiYokEΠ"{]]݂ L8qڵoƹ>yџEn999!C=&ON~p7<}y _{ݶm[78zƍv_9ydMMW_=L]3sO}S=9so'M+ٳGyW\y,6w^y;ی3^}Վnj!^s[RR+>?pW˧NO}_rĉW\YWWo~3??G?ԩS?O;>}zyyΝ;n_9CFсXF;vqYhѢE뮏}c_1zV<r <F{oF6~Hs\ի?o}[Yx nq#G<裻vz뭷/=lÆ ǎ۹sI&}͢MӮw'x"Ǐϛ7oܹ=LI稦f͚5O6m*ǯyR34~eOZ9/N>gC'N_nV[[Ǐvm-{xv477ӟ...NUz?~$ɟ/WL^BBy-_|Ĉ^Vu̘1_|q{^,O}ԩS>|Ν;w/^DyBկ~$kҤI%%%}Xwy'??ɇeYYY3y1�h,׿ yʔ)UUUw}ڵk/.o`ڴi7n馛 ?2W^yexÆ w}իGSO.X&~2^-|ViӦB@+FˮÇ?9swQ]]}:4//+xΣÇ?>??ڵ6m:uj8H vM7UWW[hXEXmGD.˗??w@mmmyyyqƭYB;?pNJ[/xG ˱c׿\V'^nXf]ꮽH$2qu۷?񏊊Yfܹo~Ŋ_3[nijj'�!va{GƍϞѐr5oFE;vlʔ){˒jnn^pa4=p@veI&-Z(/yoŅ}Z`Ammm4<|;,Xx 3B]]݉':'_bK/tW^Ȗ8SL9_BW/޽{[ZZ n=-Lzk*3m47\G]`Szv�b@E#CJ]`SԦQ�1 h4/mr`6i�1 F(@Q�1 0=XtIwvF(REER 4 F,-=<G 4 F(]�Q�1 gD%MIT$0Q�>9>�(�b@Q�1 �b`й.o6vF(RE*TvF(R_V?dzzF�(i447P(Cdaylz�.i4%#Q8:.R�b@ F(@Fp[E4 PpvF(R7]>L�Q�>+ڽ.F(R]^L�b@v`�b@ F(@&ptl?1,oi um6i@(YrM F(RE맗LWo1 d 񝭷v}R Fz蛆Q|:~c嶆i@(BF~ _@s^|~eQ�1 RQ�1 <Q�1 i�1 }Qi@(@HtyF(Rd]4 Fz@7 Fz@7Q�z]F(Rd_g�J=0Q�1 g/rc@$ZQ�(RE+T:M�Q�|mr`˛F�J=p0Q�1 F�b@Q�(�b�1 F(�Q�1 F(�b@Q�1 �b@ F(�b�1 F(@Q�1 pȵ .O?tm L�b@,vkF4Y0Q�ty0Q�tyL�Q�]^4 FPL]a�(dD=M!>Q�1 ROV1Q�zty0Q�ty0Q�}QQ�1 ROEyF(�J=.i@ԣ˃i@(f?4 Fze(@W6To(>h6Q�1 &YrM`0kIْ%5Qty@�J`(0Q�>s}F(R]ty4 Fz]0 Fz]0Q�>ty_F(R9|Q`�JQ�1 i�1 i@i@(Y7_`�b@ F ]n ğF�J=pE+TF�J=pD4Elg(�b@ F(0!%Ko~~a�J=E]^7Q�.s{(Pꁬڽi@(@Jt]4 Fz 9>(�b@ F(`h`�J=hYrM`�J=h`�J=47^IM�b@4F~ WԦQ�1 F�b@Q�({2ȒK7v?\Mm�J=sӦ6Q�z2P*`WԦQ�1 CVTNӦ6Q�zr*6i@ԓ4 F�b@Q�(PM&{.1Q�>T(\"XV�0Q�1 F�b@Q�(�b�1 F(@Q�1 F(�b@Q�1 �b`?YY(P����IENDB`�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/LICENCE������������������������������������������������0000664�0000000�0000000�00000002634�14412033640�0022263�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Copyright (C) 2003 Seiichi SATO <ssato@sh.rim.or.jp> Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. The name of any author may not be used to endorse or promote products derived from this software without their specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ����������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/Makefile.in��������������������������������������������0000664�0000000�0000000�00000002524�14412033640�0023341�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������top_builddir = ../../.. top_srcdir = @top_srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ datadir = @datadir@ libdir = @libdir@ LIBDIR = $(DESTDIR)$(libdir)/mlterm DATADIR = $(DESTDIR)$(datadir)/mlterm VPATH = ${top_srcdir}/contrib/scrollbar/pixmap_engine SAMPLES = sample3 PIXMAP_ENGINE_OBJ = pixmap_engine.o CFLAGS = $(CFLAGS_LOCAL) -I$(top_srcdir)/uitoolkit @CFLAGS@ @CPPFLAGS@ @X_CFLAGS@ CC = @CC@ INSTALL = @INSTALL@ LIBTOOL = @LIBTOOL@ LIBTOOL_CC = $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) LIBTOOL_LINK = $(LIBTOOL) --mode=link $(CC) @LDFLAGS@ LIBTOOL_INSTALL = $(LIBTOOL) --mode=install $(INSTALL) .SUFFIXES: .o .c all: libpixmap_engine.la libpixmap_engine.la: $(PIXMAP_ENGINE_OBJ) $(LIBTOOL_LINK) -o libpixmap_engine.la $(PIXMAP_ENGINE_OBJ:.o=.lo) \ -rpath $(libdir)/mlterm -module -avoid-version \ @X_LIBS@ @X_EXTRA_LIBS@ # @X_LIBS@ @X_PRE_LIBS@ @X_EXTRA_LIBS@ .c.o: $(LIBTOOL_CC) -c $< $(LIBDIR): mkdir -p $(LIBDIR) install: $(LIBDIR) $(LIBTOOL_INSTALL) libpixmap_engine.la $(LIBDIR) for dir in $(SAMPLES) ; do (cd $${dir} ; $(MAKE) $@) || exit $? ; done uninstall: rm -f $(LIBDIR)/*pixmap_engine.* for dir in $(SAMPLES) ; do (cd $${dir} ; $(MAKE) $@) || exit $? ; done clean: rm -rf $(PIXMAP_ENGINE_OBJ) $(PIXMAP_ENGINE_OBJ:.o=.lo) \ libpixmap_engine.la *.core .libs *~ distclean: clean rm -f Makefile sample3/Makefile ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/pixmap_engine.c����������������������������������������0000664�0000000�0000000�00000052133�14412033640�0024264�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #if 0 #define __DEBUG 1 #endif #include <stdio.h> #include <stdlib.h> #include <string.h> #include <X11/extensions/shape.h> #include <ui_sb_view.h> #define MAX_IMAGE_SIZE 0xffff #define free_pixmap(d, p) \ do { \ if (p) { \ XFreePixmap(d, p); \ } \ p = None; \ } while (0) #define STR2NUM_WITH_RANGE_CHECK(str, variables) \ do { \ int v; \ sscanf((str), "%d", &v); \ if (v > 1 && v < MAX_IMAGE_SIZE) { \ (variables) = v; \ } else { \ (variables) = 0; \ } \ } while (0) typedef enum button_layout { BTN_NONE, BTN_NORMAL, BTN_NORTHGRAVITY, BTN_SOUTHGRAVITY, } button_layout_t; typedef struct shared_image { Display *display; ui_sb_view_conf_t *conf; /* Don't access directly from ps */ unsigned int btn_up_h; unsigned int btn_dw_h; /* background */ unsigned int bg_top_h; unsigned int bg_bottom_h; Pixmap bg_top; Pixmap bg_bottom; /* up/down buttons */ Pixmap btn_up; Pixmap btn_dw; Pixmap btn_up_pressed; Pixmap btn_dw_pressed; Pixmap btn_up_mask; Pixmap btn_dw_mask; Pixmap btn_up_pressed_mask; Pixmap btn_dw_pressed_mask; /* slider */ unsigned int slider_width; unsigned int slider_top_h; unsigned int slider_bottom_h; unsigned int slider_knob_h; Pixmap slider_top; Pixmap slider_bottom; Pixmap slider_knob; Pixmap slider_top_mask; Pixmap slider_bottom_mask; Pixmap slider_knob_mask; unsigned int use_count; } shared_image_t; typedef struct pixmap_sb_view { ui_sb_view_t view; ui_sb_view_conf_t *conf; GC gc; unsigned int depth; int is_transparent; /* rc settings */ unsigned int width; unsigned int top_margin; unsigned int bottom_margin; unsigned int btn_up_h; unsigned int btn_dw_h; unsigned int pre_slider_h; int bg_enable_trans; int bg_tile; button_layout_t btn_layout; int slider_tile; shared_image_t *si; /* background */ unsigned int bg_body_h; Pixmap bg_body; Pixmap bg_cache; /* slider */ unsigned int slider_body_h; Pixmap slider_body; Pixmap slider_body_mask; Pixmap slider_tiled_cache; Pixmap slider_tiled_cache_mask; } pixmap_sb_view_t; /* Minimum structure of ui_display_t */ typedef struct ui_display { Display *display; } ui_display_t; /* Minimum structure of ui_window_t */ typedef struct ui_window { ui_display_t *disp; } ui_window_t; /* --- static variables --- */ static shared_image_t **shared_images; static unsigned int num_shared_images; /* --- static functions --- */ static void load_image(ui_display_t *disp, ui_sb_view_conf_t *conf, const char *file, Pixmap *pixmap, /* not NULL */ Pixmap *mask, /* can be NULL */ unsigned int *width, /* not NULL or 0 */ unsigned int *height /* not NULL */ ) { char *path; int len; len = strlen(conf->dir) + strlen(file) + 5; path = malloc(sizeof(char) * (len + 1)); sprintf(path, "%s/%s.png", conf->dir, file); if (!(*conf->load_image)(disp, path, NULL, pixmap, mask, width, height, 0)) { #ifdef __DEBUG printf("ui_imagelib_load_file() failed\n"); ; #endif } #ifdef __DEBUG printf(" path: %s, width: %d, height: %d\n", path, *width, *height); #endif free(path); return; } static shared_image_t *acquire_shared_image(ui_display_t *disp, ui_sb_view_conf_t *conf, unsigned int *width, /* not NULL or 0 */ unsigned int *btn_up_h, /* not NULL */ unsigned int *btn_dw_h /* not NULL */ ) { unsigned int count; shared_image_t *si; void *p; for (count = 0; count < num_shared_images; count++) { if (shared_images[count]->display == disp->display && shared_images[count]->conf == conf) { if (*btn_up_h == 0) { *btn_up_h = shared_images[count]->btn_up_h; } if (*btn_dw_h == 0) { *btn_dw_h = shared_images[count]->btn_dw_h; } shared_images[count]->use_count++; return shared_images[count]; } } if ((si = calloc(1, sizeof(shared_image_t))) == NULL) { return NULL; } if ((p = realloc(shared_images, sizeof(shared_image_t *) * (num_shared_images + 1))) == NULL) { free(si); return NULL; } shared_images = p; shared_images[num_shared_images++] = si; si->display = disp->display; si->conf = conf; /* * load background images (separated three parts: top, body and bottom.) */ load_image(disp, si->conf, "bg_top", &si->bg_top, NULL, width, &si->bg_top_h); load_image(disp, si->conf, "bg_bottom", &si->bg_bottom, NULL, width, &si->bg_bottom_h); /* up/down buttons */ load_image(disp, si->conf, "button_up", &si->btn_up, &si->btn_up_mask, width, btn_up_h); load_image(disp, si->conf, "button_down", &si->btn_dw, &si->btn_dw_mask, width, btn_dw_h); load_image(disp, si->conf, "button_up_pressed", &si->btn_up_pressed, &si->btn_up_pressed_mask, width, btn_up_h); load_image(disp, si->conf, "button_down_pressed", &si->btn_dw_pressed, &si->btn_dw_pressed_mask, width, btn_dw_h); /* * load slider images (separated three parts: top, body and bottom.) */ load_image(disp, si->conf, "slider_top", &si->slider_top, &si->slider_top_mask, &si->slider_width, &si->slider_top_h); load_image(disp, si->conf, "slider_bottom", &si->slider_bottom, &si->slider_bottom_mask, &si->slider_width, &si->slider_bottom_h); load_image(disp, si->conf, "slider_knob", &si->slider_knob, &si->slider_knob_mask, &si->slider_width, &si->slider_knob_h); si->btn_up_h = *btn_up_h; si->btn_dw_h = *btn_dw_h; si->use_count = 1; #ifdef __DEBUG fprintf(stderr, "Loading new pixmap scrollbar %s\n", si->conf->sb_name); #endif return si; } static void release_shared_image(shared_image_t *si) { unsigned int count; if (--si->use_count > 0) { return; } for (count = 0; count < num_shared_images; count++) { if (shared_images[count] == si) { shared_images[count] = shared_images[--num_shared_images]; if (num_shared_images == 0) { free(shared_images); shared_images = NULL; } break; } } free_pixmap(si->display, si->bg_top); free_pixmap(si->display, si->bg_bottom); free_pixmap(si->display, si->btn_up); free_pixmap(si->display, si->btn_dw); free_pixmap(si->display, si->btn_up_pressed); free_pixmap(si->display, si->btn_dw_pressed); free_pixmap(si->display, si->btn_up_mask); free_pixmap(si->display, si->btn_dw_mask); free_pixmap(si->display, si->btn_up_pressed_mask); free_pixmap(si->display, si->btn_dw_pressed_mask); free_pixmap(si->display, si->slider_top); free_pixmap(si->display, si->slider_bottom); free_pixmap(si->display, si->slider_knob); free_pixmap(si->display, si->slider_top_mask); free_pixmap(si->display, si->slider_bottom_mask); free_pixmap(si->display, si->slider_knob_mask); #ifdef __DEBUG fprintf(stderr, "Freeing pixmap scrollbar %s\n", si->conf->sb_name); #endif free(si); } static void create_bg_cache(pixmap_sb_view_t *ps) { Display *d; Window win; GC gc; int bg_h; d = ps->view.display; win = ps->view.window; gc = ps->gc; bg_h = ps->view.height; free_pixmap(d, ps->bg_cache); if (bg_h <= 0) { /* ps->view.height is larger than 65536 */ return; } if (!ps->si->bg_top && !ps->bg_body && !ps->si->bg_bottom) { return; } ps->bg_cache = XCreatePixmap(d, win, ps->width, bg_h, ps->depth); if (ps->bg_body_h && ps->bg_body) { int cached_body_h; cached_body_h = bg_h - ps->si->bg_top_h - ps->si->bg_bottom_h; if (cached_body_h <= 0) { /* height of background is too small, do nothing */ } else if (ps->bg_tile) { XSetTile(d, gc, ps->bg_body); XSetTSOrigin(d, gc, 0, 0); XSetFillStyle(d, gc, FillTiled); XFillRectangle(d, ps->bg_cache, gc, 0, ps->si->bg_top_h, ps->width, cached_body_h); } else /* ! ps->bg_tile (scale) */ { free_pixmap(d, ps->bg_body); load_image(ps->view.win->disp, ps->conf, "bg_body", &ps->bg_body, NULL, &ps->width, &cached_body_h); XCopyArea(d, ps->bg_body, ps->bg_cache, gc, 0, 0, ps->width, cached_body_h, 0, ps->si->bg_top_h); } } else { XFillRectangle(d, ps->bg_cache, gc, 0, 0, ps->width, bg_h); } if (ps->si->bg_top_h && ps->si->bg_top) { XCopyArea(d, ps->si->bg_top, ps->bg_cache, gc, 0, 0, ps->width, ps->si->bg_top_h, 0, 0); } if (ps->si->bg_bottom_h && ps->si->bg_bottom) { XCopyArea(d, ps->si->bg_bottom, ps->bg_cache, gc, 0, 0, ps->width, ps->si->bg_bottom_h, 0, bg_h - ps->si->bg_bottom_h); } } static void resize_slider(pixmap_sb_view_t *ps, int body_height) { Display *d; Window win; GC gc; d = ps->view.display; win = ps->view.window; gc = ps->gc; if (body_height <= 0 || !ps->si->slider_width) { return; } free_pixmap(d, ps->slider_tiled_cache); ps->slider_tiled_cache = XCreatePixmap(d, win, ps->si->slider_width, body_height, ps->depth); if (ps->slider_body_h && ps->slider_body) { if (ps->slider_tile) { /* tile */ XSetTile(d, gc, ps->slider_body); XSetTSOrigin(d, gc, 0, 0); XSetFillStyle(d, gc, FillTiled); XFillRectangle(d, ps->slider_tiled_cache, gc, 0, 0, ps->si->slider_width, body_height); } else { /* scale */ free_pixmap(d, ps->slider_body); free_pixmap(d, ps->slider_body_mask); load_image(ps->view.win->disp, ps->conf, "slider_body", &ps->slider_body, &ps->slider_body_mask, &ps->si->slider_width, &body_height); } } } static void get_geometry_hints(ui_sb_view_t *view, unsigned int *width, unsigned int *top_margin, unsigned int *bottom_margin, int *up_button_y, unsigned int *up_button_height, int *down_button_y, unsigned int *down_button_height) { pixmap_sb_view_t *ps; ps = (pixmap_sb_view_t *)view; *width = ps->width; *top_margin = ps->top_margin; *bottom_margin = ps->bottom_margin; *up_button_height = ps->btn_up_h; *down_button_height = ps->btn_dw_h; switch (ps->btn_layout) { case BTN_NONE: *up_button_y = 0; *down_button_y = 0; break; case BTN_NORMAL: *up_button_y = 0; *down_button_y = -ps->btn_dw_h; break; case BTN_NORTHGRAVITY: *up_button_y = 0; *down_button_y = ps->btn_up_h; break; case BTN_SOUTHGRAVITY: *up_button_y = -(ps->btn_up_h + ps->btn_dw_h); *down_button_y = -ps->btn_dw_h; break; } #ifdef __DEBUG printf( "[geometry] width: %d, top_margin: %d, bottom_margin: %d, up_button_y: " "%d, up_button_height: %d, down_button_y: %d, down_button_height: %d\n", *width, *top_margin, *bottom_margin, *up_button_y, *up_button_height, *down_button_y, *down_button_height); #endif } static void get_default_color(ui_sb_view_t *view, char **fg_color, char **bg_color) { /* dummy */ *fg_color = "black"; *bg_color = "gray"; } static void realized(ui_sb_view_t *view, Display *display, int screen, Window window, GC gc, unsigned int height) { pixmap_sb_view_t *ps; XGCValues gc_value; XWindowAttributes attr; ps = (pixmap_sb_view_t *)view; view->display = display; view->screen = screen; view->window = window; view->gc = gc; view->height = height; gc_value.foreground = BlackPixel(display, screen); gc_value.background = WhitePixel(display, screen); gc_value.graphics_exposures = 0; ps->gc = XCreateGC(display, window, GCForeground | GCBackground | GCGraphicsExposures, &gc_value); XGetWindowAttributes(view->display, view->window, &attr); ps->depth = attr.depth; ps->si = acquire_shared_image(view->win->disp, ps->conf, &ps->width, &ps->btn_up_h, &ps->btn_dw_h); /* * load background images (separated three parts: top, body and bottom.) */ load_image(view->win->disp, ps->conf, "bg_body", &ps->bg_body, NULL, &ps->width, &ps->bg_body_h); create_bg_cache(ps); /* * load slider images (separated three parts: top, body and bottom.) */ load_image(view->win->disp, ps->conf, "slider_body", &ps->slider_body, &ps->slider_body_mask, &ps->si->slider_width, &ps->slider_body_h); /* * verify the size */ if (ps->width < ps->si->slider_width) { ps->si->slider_width = ps->width; } } static void resized(ui_sb_view_t *view, Window window, unsigned int height) { pixmap_sb_view_t *ps; ps = (pixmap_sb_view_t *)view; view->window = window; view->height = height; if (ps->is_transparent && ps->bg_enable_trans) { return; } create_bg_cache(ps); } static void destroy(ui_sb_view_t *view) { pixmap_sb_view_t *ps; ps = (pixmap_sb_view_t *)view; if (!ps) { return; } release_shared_image(ps->si); free_pixmap(view->display, ps->bg_body); free_pixmap(view->display, ps->bg_cache); free_pixmap(view->display, ps->slider_body); free_pixmap(view->display, ps->slider_body_mask); free_pixmap(view->display, ps->slider_tiled_cache); free_pixmap(view->display, ps->slider_tiled_cache_mask); XFreeGC(view->display, ps->gc); ps->conf->use_count--; free(ps); } static void draw_button(pixmap_sb_view_t *ps, int up, int pressed) { Display *d; Window w; GC gc; unsigned int up_y = 0; unsigned int dw_y = 0; unsigned int y; unsigned int h; Pixmap src; Pixmap mask; d = ps->view.display; w = ps->view.window; gc = ps->gc; switch (ps->btn_layout) { case BTN_NONE: return; case BTN_NORMAL: up_y = 0; dw_y = ps->view.height - ps->btn_dw_h; break; case BTN_NORTHGRAVITY: up_y = 0; dw_y = ps->btn_up_h; break; case BTN_SOUTHGRAVITY: up_y = ps->view.height - (ps->btn_up_h + ps->btn_dw_h); dw_y = ps->view.height - ps->btn_dw_h; break; } if (up) { if (!ps->si->btn_up_pressed) { pressed = 0; } src = pressed ? ps->si->btn_up_pressed : ps->si->btn_up; mask = pressed ? ps->si->btn_up_pressed_mask : ps->si->btn_up_mask; y = up_y; h = ps->btn_up_h; } else { if (!ps->si->btn_dw_pressed) { pressed = 0; } src = pressed ? ps->si->btn_dw_pressed : ps->si->btn_dw; mask = pressed ? ps->si->btn_dw_pressed_mask : ps->si->btn_dw_mask; y = dw_y; h = ps->btn_dw_h; } /* background */ if (!(ps->is_transparent && ps->bg_enable_trans) && ps->bg_cache) { XCopyArea(d, ps->bg_cache, w, gc, 0, y, ps->width, h, 0, y); } else { XClearArea(d, w, 0, y, ps->width, h, 0); } if (!src) { return; } if (mask) { XSetClipMask(d, gc, mask); XSetClipOrigin(d, gc, 0, y); } XCopyArea(d, src, w, gc, 0, 0, ps->width, h, 0, y); XSetClipMask(d, gc, None); } static void draw_up_button(ui_sb_view_t *view, int pressed) { draw_button((pixmap_sb_view_t *)view, 1, pressed); } static void draw_down_button(ui_sb_view_t *view, int pressed) { draw_button((pixmap_sb_view_t *)view, 0, pressed); } static void draw_scrollbar(ui_sb_view_t *view, int slider_top_y, unsigned int slider_height) { pixmap_sb_view_t *ps; Display *d; Window win; unsigned int bg_h = 0; unsigned int bg_y = 0; unsigned int offset_x; int slr_body_h; GC gc; ps = (pixmap_sb_view_t *)view; d = view->display; win = view->window; gc = ps->gc; bg_h = ps->view.height - ps->btn_up_h - ps->btn_dw_h; offset_x = (ps->width - ps->si->slider_width) / 2; /* * background */ switch (ps->btn_layout) { case BTN_NONE: bg_y = 0; break; case BTN_NORMAL: bg_y = ps->btn_up_h; break; case BTN_NORTHGRAVITY: bg_y = ps->btn_up_h + ps->btn_dw_h; break; case BTN_SOUTHGRAVITY: bg_y = 0; break; } if (!(ps->is_transparent && ps->bg_enable_trans) && ps->bg_cache) { XCopyArea(d, ps->bg_cache, win, gc, 0, bg_y, ps->width, bg_h, 0, bg_y); } else { #if 0 XClearArea(d, win, offset_x, bg_y, ps->slider_width, bg_h, 0); #else XClearArea(d, win, 0, bg_y, ps->width, bg_h, 0); #endif } /* * slider */ if (ps->si->slider_top) { XSetClipMask(d, gc, ps->si->slider_top_mask); XSetClipOrigin(d, gc, offset_x, slider_top_y); XCopyArea(d, ps->si->slider_top, win, gc, 0, 0, ps->si->slider_width, ps->si->slider_top_h < slider_height ? ps->si->slider_top_h : slider_height, offset_x, slider_top_y); XSetClipMask(d, gc, None); } if (ps->si->slider_bottom) { unsigned int y; y = slider_top_y + slider_height - ps->si->slider_bottom_h; XSetClipMask(d, gc, ps->si->slider_bottom_mask); XSetClipOrigin(d, gc, offset_x, y); XCopyArea(d, ps->si->slider_bottom, win, gc, 0, 0, ps->si->slider_width, ps->si->slider_bottom_h < slider_height ? ps->si->slider_bottom_h : slider_height, offset_x, y); XSetClipMask(d, gc, None); } slr_body_h = slider_height - ps->si->slider_top_h - ps->si->slider_bottom_h; if ((ps->slider_tile && slider_height > ps->pre_slider_h) || (!ps->slider_tile && ps->pre_slider_h != slider_height)) { resize_slider(ps, slr_body_h); } ps->pre_slider_h = slider_height; if (slr_body_h <= 0) { return; } if (ps->slider_body) { if (ps->slider_tile) { XCopyArea(d, ps->slider_tiled_cache, win, gc, 0, 0, ps->si->slider_width, slr_body_h, offset_x, slider_top_y + ps->si->slider_top_h); } else /* ! ps->slider_tile (scale) */ { XSetClipMask(d, gc, ps->slider_body_mask); XSetClipOrigin(d, gc, offset_x, slider_top_y + ps->si->slider_top_h); XCopyArea(d, ps->slider_body, win, gc, 0, 0, ps->si->slider_width, slr_body_h, offset_x, slider_top_y + ps->si->slider_top_h); XSetClipMask(d, gc, None); } } if (ps->si->slider_knob && slr_body_h > ps->si->slider_knob_h) { int knob_y; knob_y = slider_top_y + (slider_height - ps->si->slider_knob_h) / 2; XSetClipMask(d, gc, ps->si->slider_knob_mask); XSetClipOrigin(d, gc, offset_x, knob_y); XCopyArea(d, ps->si->slider_knob, win, gc, 0, 0, ps->si->slider_width, ps->si->slider_knob_h, offset_x, knob_y); XSetClipMask(d, gc, None); } } static int parse(pixmap_sb_view_t *ps, ui_sb_view_conf_t *conf) { int count; ui_sb_view_rc_t *p; for (p = conf->rc, count = 0; count < conf->rc_num; p++, count++) { if (strcmp(p->key, "width") == 0) { STR2NUM_WITH_RANGE_CHECK(p->value, ps->width); } else if (strcmp(p->key, "button_up_height") == 0) { STR2NUM_WITH_RANGE_CHECK(p->value, ps->btn_up_h); } else if (strcmp(p->key, "button_down_height") == 0) { STR2NUM_WITH_RANGE_CHECK(p->value, ps->btn_dw_h); } else if (strcmp(p->key, "top_margin") == 0) { STR2NUM_WITH_RANGE_CHECK(p->value, ps->top_margin); } else if (strcmp(p->key, "bottom_margin") == 0) { STR2NUM_WITH_RANGE_CHECK(p->value, ps->bottom_margin); } else if (strcmp(p->key, "bg_tile") == 0) { if (strcmp(p->value, "false") == 0) { ps->bg_tile = 0; } } else if (strcmp(p->key, "bg_enable_trans") == 0) { if (strcmp(p->value, "true") == 0) { ps->bg_enable_trans = 1; } } else if (strcmp(p->key, "button_layout") == 0) { if (strcmp(p->value, "none") == 0) { ps->btn_layout = BTN_NONE; } if (strcmp(p->value, "northgravity") == 0) { ps->btn_layout = BTN_NORTHGRAVITY; } if (strcmp(p->value, "southgravity") == 0) { ps->btn_layout = BTN_SOUTHGRAVITY; } } else if (strcmp(p->key, "slider_tile") == 0) { if (strcmp(p->value, "false") == 0) { ps->slider_tile = 0; } } #ifdef __DEBUG else { printf("unknown key: %s\n", p->key); } #endif } return 1; } /* --- global functions --- */ ui_sb_view_t *ui_pixmap_engine_sb_engine_new(ui_sb_view_conf_t *conf, int is_transparent) { pixmap_sb_view_t *ps; if (!conf) { return NULL; } if ((ps = calloc(1, sizeof(pixmap_sb_view_t))) == NULL) { return NULL; } ps->view.version = 1; ps->bg_tile = 1; ps->btn_layout = BTN_NORMAL; ps->slider_tile = 1; ps->conf = conf; if (!(parse(ps, conf))) { free(ps); return NULL; } /* verify the values */ if (ps->width == 0) { free(ps); return NULL; } if (ps->btn_layout == BTN_NONE && (ps->btn_up_h || ps->btn_dw_h)) { ps->btn_up_h = 0; ps->btn_dw_h = 0; } /* event handlers */ ps->view.get_geometry_hints = get_geometry_hints; ps->view.get_default_color = get_default_color; ps->view.realized = realized; ps->view.resized = resized; ps->view.destroy = destroy; ps->view.draw_scrollbar = draw_scrollbar; ps->view.draw_up_button = draw_up_button; ps->view.draw_down_button = draw_down_button; ps->is_transparent = is_transparent; /* use_count decrement. when it is 0, this plugin will be unloaded. */ conf->use_count++; return (ui_sb_view_t *)ps; } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/�����������������������������������������������0000775�0000000�0000000�00000000000�14412033640�0022635�5����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/Makefile.in������������������������������������0000664�0000000�0000000�00000001177�14412033640�0024710�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������top_builddir = .. top_srcdir = @top_srcdir@ prefix = @prefix@ datadir = @datadir@ DATADIR = $(DESTDIR)$(datadir)/mlterm/scrollbars/sample3 FILES = bg_body.png bg_bottom.png bg_top.png button_down.png button_down_pressed.png button_up.png button_up_pressed.png rc slider_body.png slider_bottom.png slider_knob.png slider_top.png INSTALL=@INSTALL@ all .DEFAULT: @echo "no such a target" $(DATADIR): mkdir -p $(DATADIR) install: $(DATADIR) for file in $(FILES) ; do $(INSTALL) -m 644 $(top_srcdir)/contrib/scrollbar/pixmap_engine/sample3/$${file} $(DATADIR)/$${file} ; done uninstall: rm -rf $(DATADIR) distclean: rm -f Makefile �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/bg_body.png������������������������������������0000664�0000000�0000000�00000000251�14412033640�0024746�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ������x���bKGD������C��� pHYs�� �� ,���tIME&���6IDATx1� @,=Y%�/Xɛo2e&l"rR5|N4����IENDB`�������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/bg_bottom.png����������������������������������0000664�0000000�0000000�00000000311�14412033640�0025312�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ������j���bKGD������C��� pHYs�� �� ���tIME(3٣���VIDATxʱ `N!٫5R̕wsc9'བྷ$ff@Jiˠ�zG"Wk !RY5C U����IENDB`�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/bg_top.png�������������������������������������0000664�0000000�0000000�00000000306�14412033640�0024614�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ������j���bKGD������C��� pHYs�� �� ���tIME&���SIDATx틱 0 1b�?Rʢr:;Ot\y޻of"b@��Hf&IfCG_ERjz2 m[����IENDB`��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/button_down.png��������������������������������0000664�0000000�0000000�00000000677�14412033640�0025717�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ��� ���Kpl_���bKGD������C��� pHYs�� �� d_���tIME ^��LIDATxn@Ell`H#Hjet G$+(hb{͠ر[`vo}QZIQRJIk(,כG܆|'X i(˒0z$I<=?!A0,˼8~�y>qN!躎ʯ7&I=!si6bA)R c OeۜN'y_nR !),^ =7lꚲ,t]GUU\.M`0h ~]dZs, 1Gʒ0 7XgY8#֪b4/Vr|yRiFHَ㏛WK����IENDB`�����������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/button_down_pressed.png������������������������0000664�0000000�0000000�00000000700�14412033640�0027427�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ��� ���Kpl_���bKGD������C��� pHYs�� �� ~���tIME$TX��MIDATx10�D_ 0 (Pq\){ nDC8ɎE۝j,Mc8|z]>!AZ1x7eپtJ$L&n7ʲz<!1f.$I%RJ�!s;Z9@ZFQ`0m[8&csH)B|>7^5 c #Zw!ڮB5EQ0SUUG)վ~0|6Mr|>P k-JÏYWUPJ!:꺦*R_6b[kC=B6fY[RE/&����IENDB`����������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/button_up.png����������������������������������0000664�0000000�0000000�00000000675�14412033640�0025372�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ��� ���Kpl_���bKGD������C��� pHYs�� �� d_���tIME n4��JIDATxAjPEO`L|4҉;ЁK'.ŹkpԏRRw?sNi$1 <%Xf?x<Nvm, (v. p{1 Ð�Rڣyټ�qh봂� �5RJR__H)�~7jUh4t:a8IͲ8p֚^|FkMG)ueB(<q]p],)f~v$ 4QJQ%,#d8ZJ˥0E}Ӡ8fۡV(zj҉ ����IENDB`�������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/button_up_pressed.png��������������������������0000664�0000000�0000000�00000000713�14412033640�0027110�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ��� ���Kpl_���bKGD������C��� pHYs�� �� ~���tIME 90��XIDATx͊@h*S%HH@W.f?r"$j7= 1TM+=jrw9} OUU+mAQ:l6{UU/RJZu])I h~0X,xGeyrpmTUrvx<f>c!c(( <_4�v@)d2}|<ze1uRt `!ʢ(N]DQėUnZkn'Iz:v C1G3EQ0 {/B,!n3@nk6ee\Wo1'3 #����IENDB`�����������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/rc���������������������������������������������0000664�0000000�0000000�00000002011�14412033640�0023156�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# sample3 - sample scrollbar for mlterm, requires "pixmap_engine" plugin. # # Copylight (c) 2003 Seiichi SATO <ssato@sh.rim.or.jp> # license: Modified BSD-style license engine = pixmap_engine ############ # geometry # ############ # width of scrollbar width = 12 # upper limit of slider's movable range. top_margin = 13 # lower limit of slider's movable range. bottom_margin = 13 ############## # background # ############## # how to draw bg_body.png. # "true" is tiled image, "false" is scaled image. # default is true. bg_tile = true # pseudo-transparent window. default is false. bg_enable_trans = true ################## # up/down botton # ################## # layout of button. # normal, none, northgravity or southgravity (default is normal) button_layout = normal # height of up button button_up_height = 11 # height of down button button_down_height = 11 ########## # slider # ########## # how to draw slider_body.png. # "true" is tiled image, "false" is scaled image # default is true. slider_tile = true �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/slider_body.png��������������������������������0000664�0000000�0000000�00000000234�14412033640�0025641�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ������=u���bKGD�9�9�9!7��� pHYs�� �� ���tIME }���)IDATxctww/ ?~>0|􉁉H@B�N[e����IENDB`��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/slider_bottom.png������������������������������0000664�0000000�0000000�00000000443�14412033640�0026212�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ������|d}h���bKGD�9�9�9!7��� pHYs�� �� @A���tIME'3@p���IDATx=ʱmP谀x�:dy%<6dWހGw]() à]u]O<X^afPUB* "z}/DT;mCJ fFJi8Ofv9~]#b'mq1+7U}9,/"7M9MFo tb����IENDB`�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/slider_knob.png��������������������������������0000664�0000000�0000000�00000000256�14412033640�0025641�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ��� ���2Ͻ���bKGD���#j��� pHYs�� �� ~���tIME8ze���;IDATx1 �0"R}NνH0[Un].[SL <L˜����IENDB`��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/scrollbar/pixmap_engine/sample3/slider_top.png���������������������������������0000664�0000000�0000000�00000000413�14412033640�0025505�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������PNG  ��� IHDR��� ������|d}h���bKGD�9�9�9!7��� pHYs�� �� @A���tIME`���IDATxA0@џ"Ws2Y.~/KD1~e9?~OU'3CDZm>_f6R9DV�"bRY͌3 wk<cf*"BJ /:ExX����IENDB`�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/��������������������������������������������������������������������������0000775�0000000�0000000�00000000000�14412033640�0015440�5����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/dnd/����������������������������������������������������������������������0000775�0000000�0000000�00000000000�14412033640�0016205�5����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/dnd/Makefile��������������������������������������������������������������0000664�0000000�0000000�00000000112�14412033640�0017637�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������all: gcc `pkg-config --cflags --libs gtk+-2.0 ` -o sample_dnd ./sample.c ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/dnd/sample.c��������������������������������������������������������������0000664�0000000�0000000�00000004216�14412033640�0017635�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* should be compiled as gcc `pkg-config --cflags --libs gtk+-2.0 ` ./mlconf_dnd.c */ #include <gtk/gtk.h> /* --- static variables --- */ #define MLTERM_CONFIG_MIMETYPE "text/x-mlterm.config" GtkTargetEntry targets[] = {{MLTERM_CONFIG_MIMETYPE, 0, 0}}; /* --- static functions --- */ static void drag_data_get(GtkWidget *widget, GdkDragContext *context, GtkSelectionData *selection_data, guint info, guint time, gpointer data) { char buffer[sizeof("use_transbg=xxxxx") + 1]; sprintf(buffer, "use_transbg=%s", gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget)) ? "true" : "false"); gtk_selection_data_set(selection_data, gdk_atom_intern(MLTERM_CONFIG_MIMETYPE, FALSE), 8, buffer, sizeof(buffer)); } static void toggled(GtkToggleButton *toggle, gpointer data) { gtk_button_set_label(GTK_BUTTON(toggle), gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(toggle)) ? " set \ntransparency" : "unset\ntransparency"); } static gint end_application(GtkWidget *widget, gpointer data) { gtk_main_quit(); return FALSE; } /* --- global functions --- */ int main(int argc, char **argv) { GtkWidget *window; GtkWidget *toggle; gtk_init(&argc, &argv); window = gtk_window_new(GTK_WINDOW_TOPLEVEL); gtk_signal_connect(GTK_OBJECT(window), "delete_event", GTK_SIGNAL_FUNC(end_application), NULL); toggle = gtk_toggle_button_new_with_label("unset\ntransparency"); gtk_drag_source_set(toggle, GDK_MODIFIER_MASK, targets, 1, GDK_ACTION_COPY); gtk_signal_connect(GTK_OBJECT(toggle), "drag_data_get", GTK_SIGNAL_FUNC(drag_data_get), NULL); gtk_signal_connect(GTK_OBJECT(toggle), "toggled", GTK_SIGNAL_FUNC(toggled), NULL); gtk_container_add(GTK_CONTAINER(window), toggle); gtk_window_set_title(GTK_WINDOW(window), ("mlterm configuration")); gtk_container_set_border_width(GTK_CONTAINER(window), 0); gtk_drag_source_set_icon_stock(toggle, GTK_STOCK_EXECUTE); gtk_widget_show(toggle); gtk_widget_show(window); gtk_main(); } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/���������������������������������������������������������������������0000775�0000000�0000000�00000000000�14412033640�0016356�5����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/ChangeLog������������������������������������������������������������0000664�0000000�0000000�00000004124�14412033640�0020131�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������(Recent changelogs are integrated to ../../../ChangeLog) 2010-02-28 Araki Ken <arakiken@users.sf.net> * data_entry_string.c: If data->initial is NULL, mlterm_set_param is called with "" instead of data->initial in entry_string_reset(). (This bug caused segmentation fault in exiting mlcc in OpenSolaris 2009.06.) 2010-02-02 Araki Ken <arakiken@users.sf.net> * Font and color configuration protocol is supported in non-interactive mode. ex) mlcc font ISO8859_1 *--%d-*-iso8859-1 mlcc font ISO8859_1,12 2005-11-18 MINAMI Hirokazu <minami@mistfall.net> *minor cleanups for 2.9.3 2004-11-21 MINAMI Hirokazu <minami@mistfall.net> * added a dummy manpage (mlcc.1). 2004-11-21 MINAMI Hirokazu <minami@mistfall.net> * added non-interactive mode. ex) mlcc fg_color blue 2004-10-04 Seiichi SATO <ssato@sh.rim.or.jp> * new input method option. 2003-06-29 MINAMI Hirokazu <minami@mistfall.net> * re-introduced mlcc - adopted new configuration scheme. 2002-09-04 MINAMI Hirokazu <minami@chem.s.u-tokyo.ac.jp> * lots of minor fix/enhancements. 2.6.0 ready. 2002-07-08 MINAMI Hirokazu <minami@chem.s.u-tokyo.ac.jp> * gamma/contrast are now supported. 2002-06-24 MINAMI Hirokazu <minami@chem.s.u-tokyo.ac.jp> * code cleanup & bugfix (wall paper support was broken). 2002-06-14 MINAMI Hirokazu <minami@chem.s.u-tokyo.ac.jp> * rewrite input handling to lower CPU load. 2002-06-13 MINAMI Hirokazu <minami@chem.s.u-tokyo.ac.jp> * modified comm.c for compatibility (now VMIN=0, VTIME=0. Does this works under NetBSD?) * added contrib/tool/LICENE, contrib/tool/Changelog 2002-06-12 20:41 h_minami * main.c: removed SA_SIGINFO which is not compatible with sa_handler. 2002-06-12 20:36 h_minami * Makefile.in, comm.c, comm.h, config.h.in, configure, configure.in, data.c, data.h, data_entry_bool.c, data_entry_bool.h, data_entry_color.c, data_entry_color.h, data_entry_numeric.c, data_entry_numeric.h, data_entry_radio.c, data_entry_radio.h, data_entry_string.c, data_entry_string.h, install-sh, main.c: mlcc (console based config tool) is added. ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/LICENCE��������������������������������������������������������������0000664�0000000�0000000�00000002660�14412033640�0017347�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Copyright (c) MINAMI Hirokazu (minami@mistfall.net) All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. The name of any author may not be used to endorse or promote products derived from this software without their specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ��������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/Makefile.in����������������������������������������������������������0000664�0000000�0000000�00000002047�14412033640�0020426�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������top_builddir = ../../.. top_srcdir = @top_srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ mandir = @mandir@ BINDIR = $(DESTDIR)$(bindir) MANDIR = $(DESTDIR)$(mandir) MAN1DIR = $(MANDIR)/man1 VPATH = $(top_srcdir)/contrib/tool/mlcc CC = @CC@ PROG = mlcc CFLAGS = @CFLAGS@ @CPPFLAGS@ INSTALL = @INSTALL@ OBJECTS = data.o main.o comm.o \ data_entry_string.o data_entry_bool.o data_entry_numeric.o \ data_entry_color.o data_entry_radio.o all: $(PROG) $(PROG): $(OBJECTS) $(CC) -o $(PROG) $(OBJECTS) @LDFLAGS@ .SUFFIXES: .c.o comm.o: comm.h data.o: comm.h data.h main.o: comm.h data.h .c.o: $(CC) $(CFLAGS) -c $< clean: rm -f $(OBJECTS) $(PROG) core core.* $(PROG).core $(BINDIR): mkdir -p $(BINDIR) $(MAN1DIR): mkdir -p $(MAN1DIR) install: $(BINDIR) $(MAN1DIR) $(INSTALL) -m 755 $(PROG) $(BINDIR) $(INSTALL) -m 644 $(top_srcdir)/contrib/tool/mlcc/mlcc.1 $(MAN1DIR) uninstall: rm -f $(BINDIR)/$(PROG) rm -f $(MAN1DIR)/mlcc.1 mostlyclean: rm -f $(OBJECTS) core core.* $(PROG).core distclean: clean rm -f Makefile �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/Makefile.static������������������������������������������������������0000664�0000000�0000000�00000000734�14412033640�0021310�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������VPATH = . CC = gcc PROG = mlcc CFLAGS = -O2 -Wall -g OBJECTS = data.o main.o comm.o \ data_entry_string.o data_entry_bool.o data_entry_numeric.o \ data_entry_color.o data_entry_radio.o all: $(PROG) $(PROG): $(OBJECTS) $(CC) -o $(PROG) $(OBJECTS) .SUFFIXES: .c.o comm.o: comm.h data.o: comm.h data.h main.o: comm.h data.h .c.o: $(CC) $(CFLAGS) -c $< clean: rm -f $(OBJECTS) $(PROG) core core.* $(PROG).core mostlyclean: rm -f $(OBJECTS) core core.* $(PROG).core ������������������������������������mlterm-3.9.3/contrib/tool/mlcc/comm.c���������������������������������������������������������������0000664�0000000�0000000�00000026426�14412033640�0017467�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include <stdio.h> #include <unistd.h> #include <sys/select.h> /* select */ #include <sys/stat.h> #include <string.h> /* memset, strchr */ #include <stdlib.h> /* atoi */ #include <termios.h> /* tcgetattr/tcsetattr */ #include "comm.h" static char internal_buffer[512]; static char mlterm_pass[65]; #define COLORID_DEFAULT 9 static int choosed_color = 2; static int pointed_color = 1; static const char *color_name_table[] = {"black", "red", "green", "yellow", "blue", "magenta", "cyan", "white", NULL}; static const char color_name_error[] = "(error)"; static struct termios oldtio; /* * communication functions */ static void csi(const char *str) { write(STDOUT_FILENO, "\033", 1); write(STDOUT_FILENO, str, strlen(str)); } static void reload_passwd(void) { FILE *file; char local_buffer[256]; size_t len; struct stat st; if (mlterm_pass[0]) return; if (!getenv("MLTERM")) return; /* is on remote host. */ if (!getenv("HOME")) return; snprintf(local_buffer, sizeof(local_buffer), "%s%s", getenv("HOME"), "/.config/mlterm"); if (stat(local_buffer, &st) == 0 && sizeof(local_buffer) - strlen(local_buffer) >= 11) strcat(local_buffer, "/challenge"); else snprintf(local_buffer, sizeof(local_buffer), "%s%s", getenv("HOME"), "/.mlterm/challenge"); file = fopen(local_buffer, "r"); if (!file) { csi("]5379;gen_proto_challange\007"); sleep(1); file = fopen(local_buffer, "r"); } if (!file) { mlterm_pass[0] = 0; return; } len = fread(mlterm_pass, 1, sizeof(mlterm_pass) - 2, file); mlterm_pass[len] = ';'; mlterm_pass[len + 1] = '\0'; /*fprintf( stderr, "%d\n",fread(mlterm_pass, 1, 63, file) );*/ /*fprintf( stderr, "%s\n", mlterm_pass);*/ fclose(file); } static char *read_param(void) { char *result; fgets(internal_buffer, sizeof(internal_buffer) - 1, stdin); result = strchr(internal_buffer, '\n'); if (!result) { return NULL; } *result = 0; /* terminate */ result = strchr(internal_buffer, '='); if (result) { /*XXX check key and error!!*/ if (*(result + 1)) return result + 1; else return NULL; } return NULL; } static ssize_t read_stdin_timeout(void *buf, size_t nbytes) { fd_set fds; struct timeval tval; tval.tv_usec = 10000; /* 0.01 sec */ tval.tv_sec = 0; FD_SET(STDIN_FILENO, &fds); if (select(STDIN_FILENO + 1, &fds, NULL, NULL, &tval) < 0 || !FD_ISSET(STDIN_FILENO, &fds)) return -1; return read(STDIN_FILENO, buf, nbytes); } int read_one(void) { char buf[4] = {0}; read(STDIN_FILENO, buf, 4); if (buf[0] == 0x08 || buf[0] == 0x7f) return KEY_BS; if (buf[0] != 0x1b) /* XXX should check non-printable */ return buf[0]; if (buf[1] == 0) read_stdin_timeout(buf + 1, 3); if (buf[1] == 0) return KEY_ESC; /* single esc */ if (buf[1] == 0x4f) { /*cursor key?*/ if (buf[2] == 0) read_stdin_timeout(buf + 2, 2); switch (buf[2]) { case 0x41: return KEY_UP; case 0x42: return KEY_DOWN; case 0x43: return KEY_RIGHT; case 0x44: return KEY_LEFT; default: return -1; } } if (buf[1] == 0x5b) { /*cursor key?*/ if (buf[2] == 0) read_stdin_timeout(buf + 2, 2); if (buf[2] == 0x33) { if (buf[3] == 0) read_stdin_timeout(buf + 2, 2); if (buf[3] == 0x7e) return KEY_DEL; } } return -1; /* couldn't processed */ } void flush_stdout(void) { fsync(STDOUT_FILENO); } void dec_char(void) { csi("(0"); } void normal_char(void) { csi("(B"); } void set_cursor_pos(window_t *window, int x, int y) { static char local_buffer[12]; /* [xxxx;yyyyH should enough._buffer may be already used */ snprintf(local_buffer, sizeof(local_buffer), "[%d;%dH", window->top + y, window->left + x); csi(local_buffer); } void set_fg_color(int colorid) { char cmd[] = "[30m"; if (colorid < 0) colorid = COLORID_DEFAULT; if (colorid > COLORID_DEFAULT) colorid = COLORID_DEFAULT; cmd[2] += colorid; csi(cmd); } void set_fg_color_default(void) { csi("[39m"); } void set_bg_color(int colorid) { char cmd[] = "[40m"; if (colorid < 0) colorid = COLORID_DEFAULT; if (colorid > COLORID_DEFAULT) colorid = COLORID_DEFAULT; cmd[2] += colorid; csi(cmd); } void set_altscr(void) { csi("7"); csi("[?47h"); } void unset_altscr(void) { csi("[?47l"); csi("8"); } void set_keypad(void) { csi("[?1h"); csi("="); } void unset_keypad(void) { csi("[?1l"); csi(">"); } void cursor_show(void) { csi("[?25h"); } void cursor_hide(void) { csi("[?25l"); } int term_size(int *w, int *h) { char *p; if (!(p = mlterm_get_param("cols"))) return -1; else *w = atoi(p); if (!(p = mlterm_get_param("rows"))) return -1; else *h = atoi(p); return 0; } char *mlterm_get_color_param(const char *key) { reload_passwd(); snprintf(internal_buffer, sizeof(internal_buffer) - 1, "]5380;%scolor:%s\007", mlterm_pass, key); /*fprintf(stderr, internal_buffer);*/ csi(internal_buffer); return read_param(); } char *mlterm_get_font_param(const char *file, const char *key) { reload_passwd(); snprintf(internal_buffer, sizeof(internal_buffer) - 1, "]5380;%s%s:%s\007", mlterm_pass, file, key); /*fprintf(stderr, internal_buffer);*/ csi(internal_buffer); return read_param(); } char *mlterm_get_param(const char *key) { reload_passwd(); snprintf(internal_buffer, sizeof(internal_buffer) - 1, "]5380;%s%s\007", mlterm_pass, key); /*fprintf(stderr, internal_buffer);*/ csi(internal_buffer); return read_param(); } void mlterm_set_color_param(const char *key, char *value) { snprintf(internal_buffer, sizeof(internal_buffer), "]5379;color:%s=%s\007", key, value); /*fprintf(stderr, internal_buffer);*/ csi(internal_buffer); } void mlterm_set_font_param(const char *file, const char *key, char *value) { snprintf(internal_buffer, sizeof(internal_buffer), "]5379;%s:%s=%s\007", file, key, value); /*fprintf(stderr, internal_buffer);*/ csi(internal_buffer); } void mlterm_set_value(const char *key, int value) { snprintf(internal_buffer, sizeof(internal_buffer), "]5379;%s=%d\007", key, value); csi(internal_buffer); } void mlterm_set_param(const char *key, char *value) { snprintf(internal_buffer, sizeof(internal_buffer), "]5379;%s=%s\007", key, value); csi(internal_buffer); } void mlterm_exec(const char *cmd) { snprintf(internal_buffer, sizeof(internal_buffer), "]5379;%s\007", cmd); csi(internal_buffer); } void display_colorcube(window_t *window, int x, int y, int colorid) { if ((colorid >= 0) && (colorid < COLORID_DEFAULT)) { dec_char(); set_fg_color(colorid); window_addstr(window, x, y, (char *)"a"); /* XXX better char? */ set_fg_color(COLORID_DEFAULT); /* return to default*/ normal_char(); } else window_addstr(window, x, y, (char *)" "); } void display_str(window_t *window, int x, int y, const char *src, decor_t flag) { int len; len = strlen(src); if (len > sizeof(internal_buffer) - 3) len = sizeof(internal_buffer) - 3; memmove(internal_buffer + 1, src, len + 1); switch (flag) { case DC_CHOOSED: internal_buffer[0] = '<'; internal_buffer[len + 1] = '>'; set_fg_color(choosed_color); break; case DC_POINTED: internal_buffer[0] = '<'; internal_buffer[len + 1] = '>'; set_fg_color(pointed_color); break; default: case DC_NORMAL: internal_buffer[0] = ' '; internal_buffer[len + 1] = ' '; break; } internal_buffer[len + 2] = 0; window_addstr(window, x, y, internal_buffer); switch (flag) { case DC_CHOOSED: case DC_POINTED: set_fg_color_default(); break; default: break; } } void display_numeric(window_t *window, int x, int y, int value, const char *unit, decor_t flag) { char *pos; snprintf(internal_buffer, sizeof(internal_buffer) - 1, " %4d:(%s)", value, unit); pos = strchr(internal_buffer, ':'); switch (flag) { case DC_CHOOSED: internal_buffer[0] = '<'; pos[0] = '>'; set_fg_color(choosed_color); break; case DC_POINTED: internal_buffer[0] = '<'; pos[0] = '>'; set_fg_color(pointed_color); break; case DC_NORMAL: internal_buffer[0] = ' '; pos[0] = ' '; break; } window_addstr(window, x, y, internal_buffer); switch (flag) { case DC_CHOOSED: /* pass through */ case DC_POINTED: set_fg_color_default(); break; case DC_NORMAL: break; } } int colorid_from_name(char *name) { int i; for (i = 0; color_name_table[i]; i++) if (strcmp(name, color_name_table[i]) == 0) return i; return -1; } const char *colorname_from_id(int colorid) { if ((colorid >= 0) && (colorid < COLORID_DEFAULT)) return (color_name_table[colorid]); return color_name_error; } /* * window handling functions */ window_t *window_new(int left, int top, int right, int bottom, int framed, window_t *parent) { window_t *window; window = (window_t *)malloc(sizeof(window_t)); window->framed = framed; window->parent = parent; if (parent) { window->top = top + parent->top; window->bottom = bottom + parent->top; window->left = left + parent->left; window->right = right + parent->left; } else { window->top = top; window->bottom = bottom; window->left = left; window->right = right; } return window; } void window_free(window_t *window) { free(window); } void window_addstr(window_t *window, int x, int y, const char *str) { if (window->framed) { set_cursor_pos(window, x + 1, y + 1); } else { set_cursor_pos(window, x, y); } write(STDOUT_FILENO, str, strlen(str)); } int window_width(window_t *window) { return window->right - window->left + 1; } void window_clear(window_t *window) { int y, width; width = window_width(window); if (width > sizeof(internal_buffer) - 1) width = sizeof(internal_buffer) - 1; memset(internal_buffer, ' ', width - 1); internal_buffer[width] = 0; if (window->framed) { dec_char(); internal_buffer[0] = 'x'; /* vertical line*/ internal_buffer[width - 1] = 'x'; } else internal_buffer[width - 1] = ' '; for (y = 1; y < window->bottom - window->top; y++) { set_cursor_pos(window, 0, y); write(STDOUT_FILENO, internal_buffer, strlen(internal_buffer)); } if (window->framed) { memset(internal_buffer, 'q', width - 1); /* horiz. line*/ internal_buffer[0] = 'l'; /* upper left*/ internal_buffer[width - 1] = 'k'; /* upper right*/ } set_cursor_pos(window, 0, 0); write(STDOUT_FILENO, internal_buffer, strlen(internal_buffer)); if (window->framed) { internal_buffer[0] = 'm'; /* lower left*/ internal_buffer[width - 1] = 'j'; /* lower right*/ } set_cursor_pos(window, 0, window->bottom - window->top); write(STDOUT_FILENO, internal_buffer, strlen(internal_buffer)); if (window->framed) normal_char(); flush_stdout(); } int termios_init(void) { struct termios newtio; tcgetattr(0, &oldtio); newtio = oldtio; newtio.c_lflag &= ~ICANON; newtio.c_lflag &= ~ECHO; newtio.c_cc[VMIN] = 1; newtio.c_cc[VTIME] = 0; /* have to break with some intervals to distinguish ESC/Right*/ tcsetattr(0, TCSAFLUSH, &newtio); return 0; } int termios_final(void) { tcsetattr(0, TCSAFLUSH, &oldtio); return 0; } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/comm.h���������������������������������������������������������������0000664�0000000�0000000�00000004204�14412033640�0017462�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef _COMM_H_ #define _COMM_H_ typedef struct Window { int top; int bottom; int left; int right; int framed; struct Window *parent; } window_t; typedef enum decor { DC_NORMAL, DC_CHOOSED, DC_POINTED } decor_t; enum { KEY_UP = 256, /* char max +1 */ KEY_DOWN, KEY_RIGHT, KEY_LEFT, KEY_ESC, KEY_DEL, KEY_BS }; /* * control terminal */ void set_cursor_pos(window_t *window, int x, int y); int read_one(void); void flush_stdout(void); /* alternate screen */ void set_altscr(void); void unset_altscr(void); void set_keypad(void); void unset_keypad(void); void set_fg_color(int colorid); void set_fg_color_default(void); void set_bg_color(int colorid); void cursor_show(void); void cursor_hide(void); void dec_char(void); void normal_char(void); int term_size(int *w, int *h); char *mlterm_get_color_param(const char *key); char *mlterm_get_font_param(const char *file, const char *key); char *mlterm_get_param(const char *key); void mlterm_set_color_param(const char *key, char *value); void mlterm_set_font_param(const char *file, const char *key, char *value); void mlterm_set_param(const char *key, char *value); void mlterm_set_value(const char *key, int value); void mlterm_exec(const char *cmd); /* * text window management */ window_t *window_new(int left, int top, int right, int bottom, int framed, window_t *parent); void window_addstr(window_t *window, int x, int y, const char *str); void window_clear(window_t *window); void window_free(window_t *window); int window_width(window_t *window); /* * termios (for unbuffered I/O) */ int termios_init(void); int termios_final(void); /* * convenience functions */ void display_colorcube(window_t *window, int x, int y, int colorid); void display_str(window_t *window, int x, int y, const char *src, decor_t flag); void display_numeric(window_t *window, int x, int y, int value, const char *unit, decor_t flag); int colorid_from_name(char *name); const char *colorname_from_id(int colorid); int string_edit(window_t *window, char *src, char **result); int color_select(window_t *edit, int initial); #endif ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data.c���������������������������������������������������������������0000664�0000000�0000000�00000006432�14412033640�0017440�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include "comm.h" #include "data.h" #include "data_entry_string.h" #include "data_entry_bool.h" #include "data_entry_color.h" #include "data_entry_radio.h" #include "data_entry_numeric.h" /* * entry handler */ int entry_free(entry_t *entry) { switch (entry->type) { case ENT_STRING: entry_string_free_data(entry); break; case ENT_COLOR: entry_color_free_data(entry); break; case ENT_RADIO: entry_radio_free_data(entry); break; case ENT_BOOL: entry_bool_free_data(entry); break; case ENT_NUMERIC: entry_numeric_free_data(entry); break; case ENT_NONE: /* something stupid happning... */ return -1; } return 0; } int entry_display(window_t *window, entry_t *entry, int x, int y, int state) { switch (entry->type) { case ENT_STRING: entry_string_display(window, entry, x, y, state); break; case ENT_BOOL: entry_bool_display(window, entry, x, y, state); break; case ENT_COLOR: entry_color_display(window, entry, x, y, state); break; case ENT_NUMERIC: entry_numeric_display(window, entry, x, y, state); break; case ENT_RADIO: entry_radio_display(window, entry, x, y, state); break; case ENT_NONE: /* something stupid happning... */ return -1; } return 0; } int entry_apply(entry_t *entry) { switch (entry->type) { case ENT_STRING: entry_string_apply(entry); break; case ENT_BOOL: entry_bool_apply(entry); break; case ENT_COLOR: entry_color_apply(entry); break; case ENT_NUMERIC: entry_numeric_apply(entry); break; case ENT_RADIO: entry_radio_apply(entry); break; case ENT_NONE: /* something stupid happning... */ break; } return 0; } int entry_edit(window_t *window, entry_t *entry, int x, int y) { switch (entry->type) { case ENT_STRING: return entry_string_edit(window, entry, x, y); case ENT_BOOL: return entry_bool_edit(window, entry, x, y); case ENT_COLOR: return entry_color_edit(window, entry, x, y); case ENT_NUMERIC: return entry_numeric_edit(window, entry, x, y); case ENT_RADIO: return entry_radio_edit(window, entry, x, y); case ENT_NONE: /* something stupid happning... */ break; } return 0; } window_t *entry_window_new(window_t *section) { window_t *parent = section->parent; return window_new(0, parent->top + section->bottom + 1, window_width(parent) - 1, parent->bottom + 1, 1, parent); } int entry_reset(entry_t *entry) { switch (entry->type) { case ENT_STRING: entry_string_reset(entry); break; case ENT_BOOL: entry_bool_reset(entry); break; case ENT_COLOR: entry_color_reset(entry); break; case ENT_NUMERIC: entry_numeric_reset(entry); break; case ENT_RADIO: entry_radio_reset(entry); break; case ENT_NONE: /* something stupid happning... */ break; } return 0; } /* * section handler */ void section_free(section_t *section) { section->size--; for (; section->size >= 0; (section->size)--) { entry_free(&(section->entry[section->size])); } } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data.h���������������������������������������������������������������0000664�0000000�0000000�00000001644�14412033640�0017445�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #ifndef _DATA_H_ #define _DATA_H_ /* Check init_data() in main.c */ #define MAX_ENTRY 9 /* * typedefs */ typedef enum { ENT_NONE, ENT_STRING, ENT_NUMERIC, ENT_COLOR, ENT_BOOL, ENT_RADIO } entry_type_t; typedef struct { const char *name; const char *key; int modified; entry_type_t type; void *data; } entry_t; typedef struct { const char *name; int size; int selected; int modified; int maxwidth; entry_t entry[MAX_ENTRY]; } section_t; typedef enum { DS_CANCEL, DS_SELECT, DS_EDIT } display_state_t; int entry_free(entry_t *entry); int entry_edit(window_t *window, entry_t *entry, int x, int y); int entry_apply(entry_t *entry); int entry_display(window_t *window, entry_t *entry, int x, int y, int state); int entry_reset(entry_t *entry); window_t *entry_window_new(window_t *section); void section_free(section_t *section); #endif ��������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_bool.c����������������������������������������������������0000664�0000000�0000000�00000004001�14412033640�0021662�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include <stdlib.h> /* free/malloc */ #include <string.h> #include "comm.h" #include "data.h" #include "data_entry_bool.h" static int is_true(const char *str) { if (!str) return 0; if ((str[0] != 't') && (str[0] != 'T')) return 0; /* mlterm returns "true" or "false". first char is enough*/ return 1; } void entry_bool_reset(const entry_t *entry) { entry_bool_t *data = entry->data; mlterm_set_param(entry->key, ((data->initial) ? "true" : "false")); } void entry_bool_apply(const entry_t *entry) { entry_bool_t *data = entry->data; mlterm_set_param(entry->key, ((data->current) ? "true" : "false")); } entry_bool_t *entry_bool_new(const char *key) { entry_bool_t *entry; entry = malloc(sizeof(entry_bool_t)); entry->initial = is_true(mlterm_get_param(key)); entry->current = entry->initial; ; return entry; } int entry_bool_add(section_t *section, const char *name, const char *key) { if (section->maxwidth < strlen(name)) section->maxwidth = strlen(name); section->entry[section->size].name = name; section->entry[section->size].key = key; section->entry[section->size].type = ENT_BOOL; section->entry[section->size].data = entry_bool_new(key); section->size++; return 0; } void entry_bool_free_data(entry_t *entry) { free(entry->data); return; } void entry_bool_display(window_t *window, const entry_t *entry, int x, int y, int state) { entry_bool_t *data; data = entry->data; display_str(window, x, y, ((data->current) ? "True" : "False"), DC_NORMAL); } int entry_bool_edit(window_t *window, entry_t *entry, int x, int y) { int buffer; entry_bool_t *data; data = entry->data; buffer = read_one(); switch (buffer) { case KEY_ESC: case 10: return -1; case KEY_RIGHT: case KEY_LEFT: case KEY_UP: case KEY_DOWN: data->current = 1 - data->current; entry->modified = 1; return 1; /* redraw */ break; default: /* ignore */ return 0; } } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_bool.h����������������������������������������������������0000664�0000000�0000000�00000001041�14412033640�0021670�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ typedef struct { int initial; int current; } entry_bool_t; entry_bool_t *entry_bool_new(const char *key); int entry_bool_add(section_t *section, const char *name, const char *key); void entry_bool_free_data(entry_t *entry); void entry_bool_apply(const entry_t *entry); void entry_bool_reset(const entry_t *entry); void entry_bool_display(window_t *window, const entry_t *entry, int x, int y, int state); int entry_bool_edit(window_t *window, entry_t *entry, int x, int y); �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_color.c���������������������������������������������������0000664�0000000�0000000�00000005713�14412033640�0022060�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include <string.h> /* strncasecmp/strcasecmp/strdup/strchr/strrchr/memmove*/ #include <stdlib.h> /* free/malloc */ #include "comm.h" #include "data.h" #include "data_entry_color.h" int entry_color_edit(window_t *window, entry_t *entry, int x, int y) { entry_color_t *data; int result; window_t *edit; data = entry->data; edit = window_new(x + 2, y, x + 12, y + 9, 1, window); /*XXX*/ result = color_select(edit, colorid_from_name(data->current)); if (result != colorid_from_name(data->current)) { free(data->current); data->current = strdup(colorname_from_id(result)); entry->modified = 1; } return -1; /* finished */ } void entry_color_reset(entry_t *entry) { entry_color_t *data = entry->data; mlterm_set_param(entry->key, data->initial); } void entry_color_apply(entry_t *entry) { entry_color_t *data = entry->data; mlterm_set_param(entry->key, data->current); free(data->current); data->current = strdup(mlterm_get_param(entry->key)); } entry_color_t *entry_color_new(const char *key) { entry_color_t *entry; entry = malloc(sizeof(entry_color_t)); entry->initial = mlterm_get_param(key); if (entry->initial) entry->initial = strdup(entry->initial); else entry->initial = strdup(""); entry->current = strdup(entry->initial); return entry; } int entry_color_add(section_t *section, const char *name, const char *key) { if (section->maxwidth < strlen(name)) section->maxwidth = strlen(name); section->entry[section->size].name = name; section->entry[section->size].key = key; section->entry[section->size].type = ENT_COLOR; section->entry[section->size].data = entry_color_new(key); section->size++; return 0; } void entry_color_free_data(entry_t *entry) { entry_color_t *data; data = entry->data; free(data->initial); free(data->current); free(data); return; } void entry_color_display(window_t *window, entry_t *entry, int x, int y, int state) { entry_color_t *data; data = entry->data; display_colorcube(window, x + 1, y, colorid_from_name(data->current)); display_str(window, x + 2, y, data->current, DC_NORMAL); } int color_select(window_t *edit, int initial) { int ind, i, flag = 1; int buffer; window_clear(edit); ind = initial; while (1) { if (flag) { window_clear(edit); for (i = 0; i < 8; i++) { if (i == ind) window_addstr(edit, 0, i, ">"); set_fg_color(i); window_addstr(edit, 1, i, colorname_from_id(i)); set_fg_color_default(); } flush_stdout(); flag = 0; } buffer = read_one(); switch (buffer) { case KEY_ESC: return initial; case KEY_UP: case KEY_LEFT: ind--; if (ind < 0) ind = 8; flag = 1; break; case KEY_DOWN: case KEY_RIGHT: ind++; if (ind > 8) ind = 0; flag = 1; break; case 10: /* ret */ return ind; } } } �����������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_color.h���������������������������������������������������0000664�0000000�0000000�00000001034�14412033640�0022055�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ typedef struct { char *initial; char *current; } entry_color_t; entry_color_t *entry_color_new(const char *key); int entry_color_add(section_t *section, const char *name, const char *key); void entry_color_free_data(entry_t *entry); void entry_color_apply(entry_t *entry); void entry_color_reset(entry_t *entry); void entry_color_display(window_t *window, entry_t *entry, int x, int y, int state); int entry_color_edit(window_t *window, entry_t *entry, int x, int y); ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_numeric.c�������������������������������������������������0000664�0000000�0000000�00000005627�14412033640�0022410�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include <string.h> /* strncasecmp/strcasecmp/strdup/strchr/strrchr/memmove*/ #include <stdlib.h> /* free/malloc */ #include "comm.h" #include "data.h" #include "data_entry_numeric.h" void entry_numeric_reset(entry_t *entry) { /* * XXX * Initial value of "alpha" might be 0 which is the default value of * ui_picture_modifier_t::alpha but mlterm_set_value("alpha", "0") * unexpectedly changes alpha of true transparency on x composite * extension or win32. */ if (strcmp(entry->key, "alpha") != 0) { entry_numeric_t *data = entry->data; mlterm_set_value(entry->key, data->initial); } } void entry_numeric_apply(entry_t *entry) { entry_numeric_t *data = entry->data; mlterm_set_value(entry->key, data->current); } entry_numeric_t *entry_numeric_new(const char *key, int max, int min, const char *unit) { entry_numeric_t *entry; char *tmp; tmp = mlterm_get_param(key); entry = malloc(sizeof(entry_numeric_t)); if (tmp) entry->initial = atoi(tmp); else entry->initial = 0; entry->current = entry->initial; entry->unit = unit; entry->max = max; entry->min = min; return entry; } int entry_numeric_add(section_t *section, const char *name, const char *key, int min, int max, const char *unit) { if (section->maxwidth < strlen(name)) section->maxwidth = strlen(name); section->entry[section->size].name = name; section->entry[section->size].key = key; section->entry[section->size].type = ENT_NUMERIC; section->entry[section->size].data = entry_numeric_new(key, max, min, unit); section->size++; return 0; } void entry_numeric_free_data(entry_t *entry) { free(entry->data); return; } void entry_numeric_display(window_t *window, entry_t *entry, int x, int y, int state) { entry_numeric_t *data; data = entry->data; display_numeric(window, x, y, data->current, data->unit, DC_NORMAL); } int entry_numeric_edit(window_t *window, entry_t *entry, int x, int y) { entry_numeric_t *data; int buffer; data = entry->data; buffer = read_one(); switch (buffer) { case KEY_ESC: case 10: return -1; case KEY_UP: data->current *= 2; if ((data->max != -1) && (data->current > data->max)) data->current = data->max; entry->modified = 1; return 1; /* redraw */ case KEY_DOWN: data->current /= 2; if ((data->min != -1) && (data->current < data->min)) data->current = data->min; entry->modified = 1; return 1; /* redraw */ case KEY_RIGHT: if ((data->max == -1) || (data->current < data->max)) { data->current++; entry->modified = 1; } return 1; /* redraw */ case KEY_LEFT: if ((data->min == -1) || (data->current > data->min)) { entry->modified = 1; data->current--; } return 1; /* redraw */ default: /* ignore */ return 0; } } ���������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_numeric.h�������������������������������������������������0000664�0000000�0000000�00000001262�14412033640�0022404�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ typedef struct { int initial; int current; int max; int min; const char *unit; } entry_numeric_t; entry_numeric_t *entry_numeric_new(const char *key, int max, int min, const char *unit); int entry_numeric_add(section_t *section, const char *name, const char *key, int min, int max, const char *unit); void entry_numeric_free_data(entry_t *entry); void entry_numeric_apply(entry_t *entry); void entry_numeric_reset(entry_t *entry); void entry_numeric_display(window_t *window, entry_t *entry, int x, int y, int state); int entry_numeric_edit(window_t *window, entry_t *entry, int x, int y); ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_radio.c���������������������������������������������������0000664�0000000�0000000�00000006127�14412033640�0022040�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include <string.h> /* strncasecmp/strcasecmp/strdup/strchr/strrchr/memmove*/ #include <stdlib.h> /* free/malloc */ #include "comm.h" #include "data.h" #include "data_entry_radio.h" int entry_radio_edit(window_t *window, entry_t *entry, int x, int y) { entry_radio_t *data; int buffer; data = entry->data; buffer = read_one(); switch (buffer) { case KEY_ESC: case 10: return -1; case KEY_RIGHT: case KEY_DOWN: if (data->current < data->num) { data->current++; entry->modified = 1; } return 1; /* redraw */ case KEY_LEFT: case KEY_UP: if (data->current > 0) { data->current--; entry->modified = 1; } return 1; /* redraw */ default: /* ignore */ return 0; } } static int get_sel(char *str, char **terms) { int i = 0; if (!str) return 0; while (strcasecmp(str, terms[i])) { i++; if (!terms[i]) return -1; } return i; } void entry_radio_reset(entry_t *entry) { entry_radio_t *data = entry->data; mlterm_set_param(entry->key, data->term[data->initial]); } void entry_radio_apply(entry_t *entry) { entry_radio_t *data = entry->data; mlterm_set_param(entry->key, data->term[data->current]); } entry_radio_t *entry_radio_new(const char *key, const char *terms) { int i = 0; char *p; char *src; entry_radio_t *entry; entry = malloc(sizeof(entry_radio_t)); src = strdup(terms); p = strchr(src, '/'); while (p) { i++; p = strchr(p + 1, '/'); } entry->num = i + 1; entry->term = malloc(sizeof(char *) * (i + 1)); entry->term[i] = NULL; /* garrison */ for (; i > 0; i--) { p = strrchr(src, '/'); entry->term[i] = strdup(p + 1); *p = 0; } entry->term[0] = strdup(src); free(src); entry->initial = get_sel(mlterm_get_param(key), entry->term); entry->current = entry->initial; return entry; } int entry_radio_add(section_t *section, const char *name, const char *key, const char *terms) { if (section->maxwidth < strlen(name)) section->maxwidth = strlen(name); section->entry[section->size].name = name; section->entry[section->size].key = key; section->entry[section->size].type = ENT_RADIO; section->entry[section->size].data = entry_radio_new(key, terms); section->size++; return 0; } void entry_radio_free_data(entry_t *entry) { entry_radio_t *data; int i; data = entry->data; for (i = 0; i < data->num; i++) { free(data->term[i]); /*last term is always null and free is not required (but harmless)*/ } free(data->term); free(data); return; } void entry_radio_display(window_t *window, entry_t *entry, int x, int y, int state) { entry_radio_t *data; int i; data = entry->data; for (i = 0; i < data->num; i++) { if (i == data->current) { if (state) display_str(window, x, y, data->term[i], DC_POINTED); else display_str(window, x, y, data->term[i], DC_CHOOSED); } else { display_str(window, x, y, data->term[i], DC_NORMAL); } x += strlen(data->term[i]) + 2; } } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_radio.h���������������������������������������������������0000664�0000000�0000000�00000001130�14412033640�0022032�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ typedef struct { int initial; int current; int num; char **term; } entry_radio_t; entry_radio_t *entry_radio_new(const char *key, const char *terms); int entry_radio_add(section_t *section, const char *name, const char *key, const char *terms); void entry_radio_free_data(entry_t *entry); void entry_radio_apply(entry_t *entry); void entry_radio_reset(entry_t *entry); void entry_radio_display(window_t *window, entry_t *entry, int x, int y, int state); int entry_radio_edit(window_t *window, entry_t *entry, int x, int y); ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_string.c��������������������������������������������������0000664�0000000�0000000�00000011444�14412033640�0022246�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include <string.h> /* strncasecmp/strcasecmp/strdup/strchr/strrchr/memmove*/ #include <stdlib.h> /* free/malloc */ #include "comm.h" #include "data.h" #include "data_entry_string.h" int entry_string_edit(window_t *window, entry_t *entry, int x, int y) { entry_string_t *data; int result; char *str_new = NULL; window_t *edit; data = entry->data; edit = window_new(x + 1, y, window->right, y + 2, 1, window); /*XXX*/ result = string_edit(edit, data->current, &str_new); if (result && str_new) { free(data->current); data->current = str_new; entry->modified = 1; } return -1; /* finished */ } void entry_string_reset(entry_t *entry) { entry_string_t *data = entry->data; if (data->initial) { mlterm_set_param(entry->key, data->initial); } else { mlterm_set_param(entry->key, ""); } } void entry_string_apply(entry_t *entry) { entry_string_t *data = entry->data; if (data->current) { mlterm_set_param(entry->key, data->current); free(data->current); } else { mlterm_set_param(entry->key, ""); } data->current = mlterm_get_param(entry->key); if (data->current) data->current = strdup(data->current); } entry_string_t *entry_string_new(const char *key) { entry_string_t *entry; entry = malloc(sizeof(entry_string_t)); entry->initial = mlterm_get_param(key); if (entry->initial) { entry->initial = strdup(entry->initial); entry->current = strdup(entry->initial); } else { entry->initial = NULL; entry->current = NULL; } entry->max = -1; entry->min = 0; return entry; } int entry_string_add(section_t *section, const char *name, const char *key) { if (section->maxwidth < strlen(name)) section->maxwidth = strlen(name); section->entry[section->size].name = name; section->entry[section->size].key = key; section->entry[section->size].type = ENT_STRING; section->entry[section->size].data = entry_string_new(key); section->size++; return 0; } void entry_string_free_data(entry_t *entry) { entry_string_t *data; data = entry->data; free(data->initial); free(data->current); free(data); return; } void entry_string_display(window_t *window, entry_t *entry, int x, int y, int state) { entry_string_t *data; data = entry->data; if (data->current) display_str(window, x, y, data->current, DC_NORMAL); else display_str(window, x, y, "(error?)", DC_NORMAL); } int string_edit(window_t *window, char *src, char **result) { int input; int offset = 0; int cur_pos = 0; int width; char buffer[256]; /*XXX*/ char *work; int flag = 1; width = window_width(window); work = malloc(width * (sizeof(char))); if (src) { strncpy(buffer, src, sizeof(buffer)); buffer[255] = 0; } else buffer[0] = 0; cursor_show(); while (1) { if (flag) { window_clear(window); strncpy(work, buffer + offset, width - 2); window_addstr(window, 0, 0, work); if (strlen(buffer) - offset < width - 2) { memset(work, ' ', width - (strlen(buffer) - offset) - 2); work[width - (strlen(buffer) - offset) - 2] = 0; window_addstr(window, width - strlen(work) - 2, 0, work); } set_cursor_pos(window, cur_pos - offset, 1); flush_stdout(); flag = 0; } input = read_one(); switch (input) { case KEY_BS: /* BS */ if (cur_pos > 1) { memmove(buffer + cur_pos - 2, buffer + cur_pos - 1, strlen(buffer) - cur_pos + 2); cur_pos--; } flag = 1; break; case 10: /* ret */ *result = strdup(buffer); cursor_hide(); free(work); return 1; case KEY_ESC: cursor_hide(); free(work); *result = NULL; return 0; /* discard */ case KEY_DOWN: case KEY_RIGHT: if (cur_pos > strlen(buffer)) break; cur_pos++; flag = 1; if (cur_pos > offset + width - 2) offset++; break; case KEY_UP: case KEY_LEFT: if (cur_pos <= 0) break; cur_pos--; flag = 1; if (cur_pos < offset) offset--; break; case KEY_DEL: /* DEL */ if ((cur_pos > 0) && (cur_pos <= strlen(buffer))) memmove(buffer + cur_pos - 1, buffer + cur_pos, strlen(buffer) - cur_pos + 2); flag = 1; break; case -1: /* ignore */ break; default: /*discard non-printable chars?*/ if (cur_pos > 0) { memmove(buffer + cur_pos, buffer + cur_pos - 1, strlen(buffer) - cur_pos + 2); buffer[cur_pos - 1] = input; } else { memmove(buffer + 1, buffer, strlen(buffer) + 2); buffer[0] = input; } cur_pos++; if (cur_pos > offset + width - 2) offset++; flag = 1; } } /* never reached */ return 0; } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/data_entry_string.h��������������������������������������������������0000664�0000000�0000000�00000001073�14412033640�0022250�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ typedef struct { char *initial; char *current; int max; int min; } entry_string_t; entry_string_t *entry_string_new(const char *key); int entry_string_add(section_t *section, const char *name, const char *key); void entry_string_free_data(entry_t *entry); void entry_string_apply(entry_t *entry); void entry_string_reset(entry_t *entry); void entry_string_display(window_t *window, entry_t *entry, int x, int y, int state); int entry_string_edit(window_t *window, entry_t *entry, int x, int y); ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/main.c���������������������������������������������������������������0000664�0000000�0000000�00000034527�14412033640�0017461�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include <stdio.h> /* printf */ #include <signal.h> /* sigaction */ #include <stdlib.h> #include <string.h> #ifdef __sunos #include <alloca.h> #endif #include "comm.h" #include "data.h" /* should be removed... */ #include "data_entry_string.h" #include "data_entry_bool.h" #include "data_entry_color.h" #include "data_entry_radio.h" #include "data_entry_numeric.h" #define MAX_SECTION 8 typedef struct { section_t section[MAX_SECTION]; int filled; int selected; display_state_t state; } config_data_t; /* * global variables */ /* must be global to be changed by signal handler */ static int cols; static int rows; static int redraw_all = 0; section_t *current_section(config_data_t *data); section_t *section_from_name(config_data_t *data, char *name); section_t *section_from_name(config_data_t *data, char *name); window_t *section_window_new(window_t *parent, config_data_t *data); section_t *section_add(config_data_t *data, const char *name); int section_reset(section_t *section); int display_section(window_t *window, config_data_t *data); int data_reset(config_data_t *data); void data_free(config_data_t *data); int edit_entry(window_t *window, config_data_t *data); int display_entry(window_t *window, config_data_t *data); int select_entry(config_data_t *data); int query_exit(window_t *parent); int init_data(config_data_t *data); static void help_msg(void) { printf("[Usage]\n"); printf(" mlcc : Show configuration screen.\n"); printf(" mlcc -h/--help : Show this message.\n"); printf( " mlcc exec [command]: Execute mlterm command. (full_reset, mlclient, " "open_pty and so on)\n"); printf(" mlcc [key] : Get current value of [key].\n"); printf(" mlcc [key] [value] : Set [value] for [key].\n"); printf( " mlcc [font file name] [charset] : Get font name of [charset] in [font " "file name].\n"); printf( " mlcc [font file name] [charset] [font name] : Set [font name] in [font " "file name].\n"); printf(" mlcc color [color name] [rgb] : Set [rgb] for [color name].\n"); printf(" mlcc color [color name] : Get rgb of [color name].\n"); printf( " (See doc/en/PROTOCOL, PROTOCOL.font and PROTOCOL.color for " "configuration details.)\n"); } /* * backyard */ /* recover terminal settings and die gracefully */ static void finalize(void) { termios_final(); unset_altscr(); unset_keypad(); normal_char(); cursor_show(); exit(0); } /* * signal handler */ static void signal_int(int signo) { finalize(); } static void signal_winch(int signo) { term_size(&cols, &rows); redraw_all = 1; /* do not redraw immediately to avoid overload */ } /* * config data handler */ section_t *current_section(config_data_t *data) { return &(data->section[data->selected]); } section_t *section_from_name(config_data_t *data, char *name) { int i; for (i = 0; i < data->filled; i++) if (strcmp(data->section[i].name, name) == 0) return &(data->section[i]); return NULL; } section_t *section_add(config_data_t *data, const char *name) { if (data->filled > MAX_SECTION - 2) return NULL; data->section[data->filled].name = name; data->section[data->filled].size = 0; data->section[data->filled].selected = 0; data->section[data->filled].modified = 0; data->section[data->filled].maxwidth = 0; return &(data->section[data->filled++]); } window_t *section_window_new(window_t *parent, config_data_t *data) { int cur = 0; int pos = 1; int skip = 0; while (cur < data->filled) { pos += (strlen(data->section[cur].name) + 2); if (pos > (window_width(parent))) { cur--; pos = 2; skip++; } cur++; } return window_new(0, 0, pos, skip + 3, 1, parent); } int section_reset(section_t *section) { int i; for (i = 0; i < section->size; i++) { entry_reset(&(section->entry[i])); } return 0; } int display_section(window_t *window, config_data_t *data) { int cur = 0; int pos = 0; int len; int skip = 0; while (cur < data->filled) { len = strlen(data->section[cur].name) + 2; if ((pos + len) > (window->right - window->left)) { cur--; pos = 1; skip++; } else { display_str(window, pos + 1, skip + 1, (data->section[cur].name), (data->selected == cur) ? (data->state == DS_SELECT ? DC_POINTED : DC_CHOOSED) : DC_NORMAL); pos += len; } cur++; } return 0; } int data_reset(config_data_t *data) { int i; for (i = 0; i < data->filled; i++) section_reset(&(data->section[i])); return 0; } void data_free(config_data_t *data) { for (; data->filled > 0; (data->filled)--) section_free(&data->section[data->filled - 1]); } int edit_entry(window_t *window, config_data_t *data) { section_t *section; entry_t *entry; int result = 0xDEADBEEF; section = current_section(data); entry = &(section->entry[section->selected]); result = entry_edit(window, entry, section->maxwidth + 4, section->selected * 2); if (result == 0) return 0; if (result < 0) data->state = DS_SELECT; entry_apply(entry); if (entry->modified) section->modified = 1; return 1; } int display_entry(window_t *window, config_data_t *data) { section_t *current; int i; current = current_section(data); for (i = 0; i < current->size; i++) { display_str(window, 1, i * 2, (current->entry[i].name), (current->selected == i) ? (data->state == DS_SELECT ? DC_CHOOSED : DC_POINTED) : DC_NORMAL); window_addstr(window, current->maxwidth + 3, i * 2, ":"); if ((i == current->selected) && (data->state == DS_EDIT)) entry_display(window, &(current->entry[i]), current->maxwidth + 4, i * 2, 1); else entry_display(window, &(current->entry[i]), current->maxwidth + 4, i * 2, 0); } return 0; } int select_entry(config_data_t *data) { int buffer; section_t *cur; cur = current_section(data); buffer = read_one(); switch (buffer) { case KEY_ESC: data->state = DS_CANCEL; return 1; /* redraw */ case KEY_UP: if (cur->selected > 0) cur->selected--; return 1; /* redraw */ case KEY_DOWN: /* DOWN */ if (cur->selected < cur->size - 1) cur->selected++; return 1; /* redraw */ case KEY_RIGHT: /* RIGHT */ if (data->selected < data->filled - 1) data->selected++; return 1; /* redraw */ case KEY_LEFT: /* LEFT */ if (data->selected > 0) data->selected--; return 1; /* redraw */ case 10: /* ret */ data->state = DS_EDIT; return 1; /* redraw */ default: /* ignore */ return 0; /* don't redraw*/ } } int query_exit(window_t *parent) { window_t *query; int flag, buffer; int state = 0; flag = 1; query = window_new((parent->right - parent->left) / 2 - 7, (parent->bottom - parent->top) / 2 - 2, (parent->right - parent->left) / 2 + 7, (parent->bottom - parent->top) / 2 + 3, 1, parent); while (1) { if (flag) { window_clear(query); window_addstr(query, 0, 0, " Really Quit?"); if (state == 0) { window_addstr(query, 1, 2, " <apply>"); window_addstr(query, 1, 3, " discard "); } else { window_addstr(query, 1, 2, " apply "); window_addstr(query, 1, 3, "<discard>"); } flush_stdout(); flag = 0; } buffer = read_one(); switch (buffer) { case KEY_ESC: /* cursor key or ESC */ window_free(query); return -1; case KEY_UP: case KEY_DOWN: case KEY_RIGHT: case KEY_LEFT: state = 1 - state; flag = 1; break; case 10: /* ret */ window_free(query); return state; default: break; } } } /* * initialize ... may be separated into conffile */ int init_data(config_data_t *data) { section_t *section; data->state = DS_SELECT; data->selected = 0; data->filled = 0; /* Check the number of entries in each section and change MAX_ENTRY in data.h as necessary. */ section = section_add(data, "Encoding"); entry_string_add(section, "Encoding", "encoding"); entry_string_add(section, "Input Method", "input_method"); entry_bool_add(section, "Bidi", "use_bidi"); entry_bool_add(section, "Indic", "use_ind"); entry_bool_add(section, "Combining", "use_combining"); entry_bool_add(section, "Process via unicode", "copy_paste_via_ucs"); section = section_add(data, "Appearance"); entry_numeric_add(section, "Font size", "fontsize", 5, 50, "pix"); entry_numeric_add(section, "Line space", "line_space", 0, 5, "pix"); entry_numeric_add(section, "Width", "screen_width_ratio", 0, 100, "%"); entry_bool_add(section, "Variable column width", "use_variable_column_width"); entry_string_add(section, "Anti alias", "use_anti_alias"); entry_string_add(section, "Type engine", "type_engine"); section = section_add(data, "Color"); entry_color_add(section, "Foreground color", "fg_color"); entry_color_add(section, "Background color", "bg_color"); entry_numeric_add(section, "Fade ratio", "fade_ratio", 0, 100, "%"); entry_string_add(section, "Wall picture", "wall_picture"); entry_numeric_add(section, "Brightness", "brightness", 0, -1, "%"); entry_numeric_add(section, "Contrast", "contrast", 0, -1, "%"); entry_numeric_add(section, "Gammma", "gamma", 0, -1, "%"); entry_numeric_add(section, "Alpha", "alpha", 0, -1, "%"); entry_bool_add(section, "Transparent background", "use_transbg"); section = section_add(data, "Scrollbar"); entry_radio_add(section, "Position", "scrollbar_mode", "none/left/right"); entry_string_add(section, "View", "scrollbar_view_name"); entry_color_add(section, "Foreground color", "sb_fg_color"); entry_color_add(section, "Background color", "sb_bg_color"); section = section_add(data, "Others"); entry_numeric_add(section, "Tab width", "tabsize", 0, 100, "column"); entry_numeric_add(section, "Backlog size", "logsize", 128, 2048, "line"); entry_radio_add(section, "Meta key outputs", "mod_meta_mode", "none/esc/8bit"); entry_radio_add(section, "Vertical mode", "vertical_mode", "none/cjk/mongol"); entry_radio_add(section, "Bel mode", "bel_mode", "none/sound/visual"); entry_bool_add(section, "Combining", "use_dynamic_comb"); entry_bool_add(section, "Fullwidth", "use_multi_column_char"); entry_bool_add(section, "Clipboard", "use_clipboard"); return 0; } int main(int argc, char **argv) { static config_data_t data; struct sigaction act; window_t *win_root = NULL, *win_section = NULL, *win_entry = NULL; if (argc == 2) { if (strcmp(argv[1], "-h") == 0 || strcmp(argv[1], "--help") == 0) { help_msg(); } else { mlterm_get_param(argv[1]); } exit(0); } else if (argc >= 3 && strcmp(argv[1], "exec") == 0) { int i; char *cmd; size_t cmd_len = 0; for (i = 2; i < argc; i++) { /* +3 is for "" and space(or NULL terminator). */ cmd_len += (strlen(argv[i]) + 3); } cmd = alloca(cmd_len); i = 2; strcpy(cmd, argv[i]); while (++i < argc) { int enclose; strcat(cmd, " "); if (strncmp(argv[2], "mlclient", 8) == 0 || strcmp(argv[2], "snapshot") == 0 || strcmp(argv[2], "show_picture") == 0 || strcmp(argv[2], "scp") == 0) { enclose = 1; strcat(cmd, "\""); } else { enclose = 0; } strcat(cmd, argv[i]); if (enclose) { strcat(cmd, "\""); } } mlterm_exec(cmd); exit(0); } else if (argc == 3 || argc == 4) { char *p; if (argv[1][0] == 't' || argv[1][0] == 'v') { p = argv[1] + 1; } else { p = argv[1]; } if (strcmp(p, "font") == 0 || strcmp(p, "aafont") == 0) { if (argc == 3) { mlterm_get_font_param(argv[1], argv[2]); exit(0); } if (argc == 4) { mlterm_set_font_param(argv[1], argv[2], argv[3]); exit(0); } } else if (strcmp(p, "color") == 0) { if (argc == 3) { mlterm_get_color_param(argv[2]); exit(0); } if (argc == 4) { mlterm_set_color_param(argv[2], argv[3]); exit(0); } } else if (argc == 3) { mlterm_set_param(argv[1], argv[2]); exit(0); } } if (!getenv("MLTERM")) { printf("MLTERM environment variable not set.\n"); printf( "mlcc without options doesn't work on a terminal except mlterm " "or on a remote host.\n"); exit(1); } sigemptyset(&(act.sa_mask)); sigaddset(&act.sa_mask, SIGINT | SIGWINCH); act.sa_flags = SA_RESTART; act.sa_handler = signal_int; sigaction(SIGINT, &act, NULL); act.sa_handler = signal_winch; sigaction(SIGWINCH, &act, NULL); cursor_hide(); set_keypad(); set_altscr(); termios_init(); init_data(&data); if (term_size(&cols, &rows) == -1) goto FIN; redraw_all = 1; while (1) { if (redraw_all) { redraw_all = 0; window_free(win_section); window_free(win_entry); window_free(win_root); win_root = window_new(0, 0, cols - 1, rows - 1, 0, NULL); window_clear(win_root); win_section = section_window_new(win_root, &data); window_clear(win_section); win_entry = entry_window_new(win_section); window_clear(win_entry); display_section(win_section, &data); display_entry(win_entry, &data); flush_stdout(); } switch (data.state) { case DS_SELECT: if (select_entry(&data)) { window_clear(win_entry); /* clear garbage */ display_section(win_section, &data); display_entry(win_entry, &data); flush_stdout(); } break; case DS_EDIT: if (edit_entry(win_entry, &data)) { window_clear(win_entry); /* clear garbage */ display_section(win_section, &data); /* change color */ display_entry(win_entry, &data); flush_stdout(); } break; case DS_CANCEL: switch (query_exit(win_entry)) { case 1: goto CANCEL; case 0: goto FIN; case -1: data.state = DS_SELECT; redraw_all = 1; } break; } } CANCEL: /*XXX reset params to initial state*/ data_reset(&data); FIN: data_free(&data); /* destruct date tree. segv should be caught here if there are bugs*/ finalize(); /*recover terminal setting*/ return 0; } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/mlcc.1���������������������������������������������������������������0000664�0000000�0000000�00000002412�14412033640�0017355�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������.\" mlcc.1 -*- nroff -*- .TH MLCC 1 "2018-10-27" .SH NAME mlcc \- simple configurator for mlterm .SH SYNOPSIS .B mlcc .RB [\fIoptions\fP] .RB [\fIarguments\fP] .\" ******************************************************************** .SH DESCRIPTION \fBmlcc\fR is a helper to configure \fBmlterm\fR(1) by sending special escape sequences. .nf (See https://github.com/arakiken/mlterm/blob/master/doc/en/PROTOCOL) .\" ******************************************************************** .SH OPTIONS \fB\-h\fR, \fB\-\-help\fR Show help messages. .\" ******************************************************************** .SH EXAMPLE .TP \fBmlcc\fR .nf Show configuration screen. .TP \fBmlcc fg_color blue\fR Change the value of "fg_color" option to "blue". .TP \fBmlcc exec full_reset\fR Execute "full_reset" command. .TP \fBmlcc aafont ISO10646_UCS4_1 Courier\fR Change font name of "ISO10646_UCS4_1" in aafont configuration to "Courier". .TP \fBmlcc color red rgb:ff/00/00\fR Change RGB of "red" to rgb:ff/00/00. .\" ******************************************************************** .SH SEE ALSO \fBmlterm\fR(1), .\" ******************************************************************** .SH CONTACT Subscribe mlterm-dev-en ML (https://lists.sourceforge.net/lists/listinfo/mlterm-dev-en). ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������mlterm-3.9.3/contrib/tool/mlcc/mlcc.html������������������������������������������������������������0000664�0000000�0000000�00000003267�14412033640�0020172�0����������������������������������������������������������������������������������������������������ustar�00root����������������������������root����������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <HTML LANG="en"> <HEAD> <META NAME=author CONTENT="MINAMI Hirokazu"> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"> <TITLE>mlconfig on console

mlconfig on console

What is mlcc?

A tiny tool to change terminal setting of mlterm.

If you can use mlconfig (a GUI configurator), you may never need this tool. Check it first.

This tool enables you to change many aspects of mlterm's setting. Such as ...

  • Terminal encoding
  • X Input Method
  • Font size/color
  • Anti Aliasing
  • Wall picture
  • Transparent background
  • ... and more .

Theoretically, you can send an escape sequence to mlterm by hand and do not need any tool to control mlterm's settings.

For example,

 echo -e "\e]5379;wall_picture=/path/to/file.jpg\x07"
 

will change wall picture to /path/to/file.jpg. This tool was written to automagically generate such a magic word on behalf of you.

Requirement

None to use. To compile and install, only a modern C compiler and POSIX compatible libraries are required.

Install

As usual, do

./configure & make & make install

To Do

  • Implement file selector (someday)
  • Handle errors (REQUIRED)
  • Write documents (who reads?)
  • NLS (gettext?)
  • Serialization (write back changes to config file)

Author

MINAMI Hirokazu (minami@chem.s.u-tokyo.ac.jp)

mlterm-3.9.3/contrib/tool/mlterm-menu/000077500000000000000000000000001441203364000177025ustar00rootroot00000000000000mlterm-3.9.3/contrib/tool/mlterm-menu/LICENCE000066400000000000000000000026411441203364000206720ustar00rootroot00000000000000Copyright (c) KATO Kazuyoshi (kzys@users.sourceforge.net) Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. The name of any author may not be used to endorse or promote products derived from this software without their specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. mlterm-3.9.3/contrib/tool/mlterm-menu/Makefile.in000066400000000000000000000033511441203364000217510ustar00rootroot00000000000000top_builddir = ../../.. top_srcdir = @top_srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ libexecdir = @libexecdir@ bindir = @bindir@ sysconfdir = @sysconfdir@ datadir = @datadir@ VPATH = ${top_srcdir}/contrib/tool/mlterm-menu CC = @CC@ LIBTOOL = @LIBTOOL@ INSTALL = @INSTALL@ LIBEXECDIR = $(DESTDIR)$(libexecdir)/mlterm LIBEXECDIR_win32 = $(DESTDIR)$(bindir) SYSCONFDIR = $(DESTDIR)$(sysconfdir) LPOBL = @LPOBL@ CFLAGS = $(CFLAGS_LOCAL) @POBL_CFLAGS@ @CFLAGS@ @CPPFLAGS@ @GTK_CFLAGS@ \ -DSYSCONFDIR=\"$(sysconfdir)\" LIBS1 = $(LIBS_LOCAL) @DL_SELF@ @GTK_LIBS@ LIBS2_xlib = $(LPOBL) LIBS2_wayland = $(LPOBL) LIBS2_sdl2 = $(LPOBL) # mlterm-menu is statically linked with libpobl. # Then it works if installed libpobl.dll is compiled with USE_WIN32API or not. LIBS2_win32 = -mwindows ${top_builddir}/baselib/src/.libs/libpobl.a LIBS2_quartz = $(LPOBL) LIBS = $(LIBS1) $(LIBS2_@GUI@) LIBTOOL_LINK = $(LIBTOOL) --mode=link $(CC) @LDFLAGS@ LIBTOOL_INSTALL = $(LIBTOOL) --mode=install $(INSTALL) PACKAGE = @PACKAGE@ VERSION = @VERSION@ OBJS = mlterm-menu.o LPOBL_DEB=-lpobl_deb all: mlterm-menu debug: $(MAKE) LPOBL="$(LPOBL_DEB)" all mlterm-menu: $(OBJS) $(LIBTOOL_LINK) $(OBJS) $(CFLAGS) -o mlterm-menu $(LIBS) .c.o: $(CC) $(DEFS) $(CFLAGS) -c $< install: $(LIBEXECDIR@WIN32TAG@) $(SYSCONFDIR)/mlterm $(LIBTOOL_INSTALL) -m 755 mlterm-menu $(LIBEXECDIR@WIN32TAG@) $(INSTALL) -m 644 ${top_srcdir}/contrib/tool/mlterm-menu/menu $(SYSCONFDIR)/mlterm uninstall: rm -f $(LIBEXECDIR@WIN32TAG@)/mlterm-menu $(SYSCONFDIR)/mlterm/menu $(LIBEXECDIR@WIN32TAG@): mkdir -p $(LIBEXECDIR@WIN32TAG@) $(SYSCONFDIR)/mlterm: mkdir -p $(SYSCONFDIR)/mlterm clean: rm -rf $(OBJS) mlterm-menu mlterm-menu.exe *.core .libs distclean: clean rm -f Makefile mlterm-3.9.3/contrib/tool/mlterm-menu/README000066400000000000000000000006021441203364000205600ustar00rootroot00000000000000= mlterm-menu mlterm-menu is a popup-menu-style configuration tool for mlterm. == File * ~/.mlterm/menu * SYSCONFDIR/menu (e.g. /etc/mlterm/menu) When ~/.mlterm/menu exists, mlterm-menu ignores SYSCONFDIR/menu. == Syntax menu = (normal-entry | special-entry) * normal-entry = STRING (STRING | submenu) submenu = "{" menu "}" special-entry = "pty_list" | "-" mlterm-3.9.3/contrib/tool/mlterm-menu/menu000066400000000000000000000005061441203364000205720ustar00rootroot00000000000000"Font Size" { "Larger" "fontsize=larger" "Smaller" "fontsize=smaller" } "Encoding" { "Auto" "encoding=auto" "UTF-8" "encoding=UTF-8" } "Full Reset" "full_reset" "Zmodem" "zmodem_start" "Font" { "Kochi Gothic" "aafont:DEFAULT=Kochi Gothic" "Kochi Mincho" "aafont:DEFAULT=Kochi Mincho" } - pty_list "New PTY" "open_pty" mlterm-3.9.3/contrib/tool/mlterm-menu/mlterm-menu.c000066400000000000000000000164311441203364000223150ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ /* * mlterm-menu - a popup-menu-style configuration tool for mlterm * * $Id$ */ #include #include #include #include #include #include #include #include #include /* USE_WIN32API */ #if defined(USE_WIN32API) #define CONFIG_PATH "." #elif defined(SYSCONFDIR) #define CONFIG_PATH SYSCONFDIR #else #define CONFIG_PATH "/etc" #endif #define MENU_RCFILE "mlterm/menu" #ifndef gtk_menu_append #define gtk_menu_append(menu, child) gtk_menu_shell_append((GtkMenuShell*)(menu), (child)) #endif static GScannerConfig menu_scanner_config = { " \t\n", G_CSET_A_2_Z G_CSET_a_2_z "-_", G_CSET_A_2_Z G_CSET_a_2_z "-_", "#\n", TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, }; static char *progname; GtkWidget *create_menu(); int append_menu_from_file(GtkMenu *menu, char *filename); int append_menu_from_scanner(GtkMenu *menu, GScanner *scanner, int level); int append_pty_list(GtkMenu *menu); void activate_callback(GtkWidget *widget, gpointer data); #if !defined(G_PLATFORM_WIN32) void activate_callback_copy(GtkWidget *widget, gpointer data); #endif void toggled_callback(GtkWidget *widget, gpointer data); char *get_value(char *dev, char *key); int main(int argc, char *argv[]) { GtkWidget *menu; #if !GTK_CHECK_VERSION(2, 90, 0) gtk_set_locale(); #endif progname = argv[0]; gtk_init(&argc, &argv); bl_set_sys_conf_dir(CONFIG_PATH); menu = create_menu(); g_signal_connect(menu, "deactivate", gtk_main_quit, NULL); gtk_menu_popup(GTK_MENU(menu), NULL, NULL, NULL, NULL, 0, 0); gtk_main(); return 0; } GtkWidget *create_menu(void) { GtkWidget *menu; char *rc_path; int userexist = 0; menu = gtk_menu_new(); if ((rc_path = bl_get_user_rc_path(MENU_RCFILE))) { userexist = append_menu_from_file(GTK_MENU(menu), rc_path); free(rc_path); } if (userexist == 0 && (rc_path = bl_get_sys_rc_path(MENU_RCFILE))) { append_menu_from_file(GTK_MENU(menu), rc_path); free(rc_path); } gtk_widget_show_all(menu); return menu; } int append_menu_from_file(GtkMenu *menu, char *filename) { FILE* file; GScanner *scanner; file = fopen(filename, "r"); if (file == NULL) { return 0; } scanner = g_scanner_new(&menu_scanner_config); g_scanner_input_file(scanner, fileno(file)); append_menu_from_scanner(menu, scanner, 0); g_scanner_destroy(scanner); fclose(file); return 1; } int append_menu_from_scanner(GtkMenu *menu, GScanner *scanner, int level) { GtkWidget *item; GtkWidget *submenu; GTokenType tt; GTokenValue tv; while (g_scanner_peek_next_token(scanner) != G_TOKEN_EOF) { tt = g_scanner_get_next_token(scanner); switch (tt) { case G_TOKEN_STRING: tv = g_scanner_cur_value(scanner); item = gtk_menu_item_new_with_label(tv.v_string); gtk_menu_append(menu, item); switch (g_scanner_peek_next_token(scanner)) { case G_TOKEN_STRING: g_scanner_get_next_token(scanner); tv = g_scanner_cur_value(scanner); g_signal_connect(item, "activate", G_CALLBACK(activate_callback), (gpointer)strdup(tv.v_string)); break; case G_TOKEN_LEFT_CURLY: g_scanner_get_next_token(scanner); submenu = gtk_menu_new(); append_menu_from_scanner(GTK_MENU(submenu), scanner, level + 1); gtk_menu_item_set_submenu(GTK_MENU_ITEM(item), submenu); break; default: break; } break; case G_TOKEN_IDENTIFIER: tv = g_scanner_cur_value(scanner); if (strcmp(tv.v_identifier, "pty_list") == 0) { append_pty_list(GTK_MENU(menu)); } else if (strcmp(tv.v_identifier, "-") == 0) { gtk_menu_append(GTK_MENU(menu), gtk_menu_item_new()); } else { fprintf(stderr, "%s: undefined identifier `%s'.\n", progname, tv.v_identifier); } break; case G_TOKEN_RIGHT_CURLY: if ((level - 1) < 0) { fprintf(stderr, "%s: mismatched parentheses.\n", progname); return 0; } else { return 1; } break; default: break; } } return 1; } int append_pty_list(GtkMenu *menu) { GtkWidget *item; char *my_pty; char *pty_list; char *name_locale; char *name_utf8; char *pty; char *command; int is_active; GSList *group = NULL; if ((my_pty = get_value(NULL, "pty_name")) == NULL) return 1; if ((pty_list = get_value(NULL, "pty_list")) == NULL) return 1; while (pty_list) { pty = pty_list; pty_list = strchr(pty_list, ':'); if (pty_list) *pty_list = 0; else break; if (*(pty_list + 1) == '1') is_active = 1; else is_active = 0; pty_list = strchr(pty_list + 1, ';'); if (pty_list) pty_list++; if (is_active && strcmp(my_pty, pty) != 0) continue; if ((name_locale = get_value(pty, "pty_name")) == NULL) name_locale = pty; if (strncmp(name_locale, "/dev/", 5) == 0) name_locale += 5; name_utf8 = g_locale_to_utf8(name_locale, -1, NULL, NULL, NULL); command = malloc(strlen(pty) + 12); sprintf(command, "select_pty %s", pty); item = gtk_radio_menu_item_new_with_label(group, name_utf8); group = gtk_radio_menu_item_get_group(GTK_RADIO_MENU_ITEM(item)); g_signal_connect(item, "toggled", G_CALLBACK(toggled_callback), (gpointer)command); gtk_menu_append(menu, item); g_free(name_utf8); if (strcmp(my_pty, pty) == 0) { gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(item), TRUE); } } return 1; } void activate_callback(GtkWidget *widget, gpointer data) { char *command = data; printf("\x1b]5379;%s\x07", command); } #if !defined(G_PLATFORM_WIN32) void activate_callback_copy(GtkWidget *widget, gpointer data) { u_char *sel = (u_char*)data; size_t len = strlen(sel); size_t count; GtkClipboard *clipboard; if (!(clipboard = gtk_clipboard_get(GDK_SELECTION_CLIPBOARD))) { return; } /* Replace CR to NL. */ for (count = 0; count < len; count++) { if (sel[count] == '\r') { sel[count] = '\n'; } } gtk_clipboard_set_text(clipboard, sel, len); /* * Gtk+ win32 doesn't support gtk_clipboard_store for now. * (see gdk_display_store_clipboard() in gdk/win32/gdkdisplay-win32.c). */ gtk_clipboard_store(clipboard); } #endif void toggled_callback(GtkWidget *widget, gpointer data) { char *command = data; if (gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(widget))) { printf("\x1b]5379;%s\x07", command); } } char *get_value(char *dev, char *key) { size_t count; char *ret; size_t len; char c; if (dev) printf("\x1b]5381;%s:%s\x07", dev, key); else printf("\x1b]5381;%s\x07", key); fflush(stdout); len = 1024; ret = malloc(len); count = 0; while (read(STDIN_FILENO, &c, 1) == 1 && c != '\n') { ret[count] = c; if (++count >= len) { ret = realloc(ret, (len += 1024)); } } ret[count] = '\0'; if (count < 2 + strlen(key) || strcmp(ret, "#error") == 0) { free(ret); return NULL; } /* * #key=value */ return ret + 2 + strlen(key); } mlterm-3.9.3/contrib/tool/mlterm-zoom/000077500000000000000000000000001441203364000177225ustar00rootroot00000000000000mlterm-3.9.3/contrib/tool/mlterm-zoom/LICENSE000066400000000000000000000027031441203364000207310ustar00rootroot00000000000000Copyright (c) 2004, KATO Kazuyoshi All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the University nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. mlterm-3.9.3/contrib/tool/mlterm-zoom/Makefile.in000066400000000000000000000024151441203364000217710ustar00rootroot00000000000000top_builddir = ../../.. top_srcdir = @top_srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ libexecdir = @libexecdir@ bindir = @bindir@ sysconfdir = @sysconfdir@ datadir = @datadir@ VPATH = ${top_srcdir}/contrib/tool/mlterm-zoom CC = @CC@ LIBTOOL = @LIBTOOL@ INSTALL = @INSTALL@ LIBEXECDIR = $(DESTDIR)$(libexecdir)/mlterm LIBEXECDIR_win32 = $(DESTDIR)$(bindir) SYSCONFDIR = $(DESTDIR)$(sysconfdir) CFLAGS = $(CFLAGS_LOCAL) @CFLAGS@ @CPPFLAGS@ @X_CFLAGS@ -DSYSCONFDIR=\"$(sysconfdir)\" LIBS = $(LIBS_LOCAL) @X_LIBS@ @X_EXTRA_LIBS@ #LIBS = $(LIBS_LOCAL) @X_LIBS@ @X_PRE_LIBS@ @X_EXTRA_LIBS@ LIBTOOL_LINK = $(LIBTOOL) --mode=link $(CC) @LDFLAGS@ LIBTOOL_INSTALL = $(LIBTOOL) --mode=install $(INSTALL) PACKAGE = @PACKAGE@ VERSION = @VERSION@ OBJS = mlterm-zoom.o all: mlterm-zoom mlterm-zoom: $(OBJS) $(LIBTOOL_LINK) $(OBJS) $(CFLAGS) -o mlterm-zoom $(LIBS) .c.o: $(CC) $(DEFS) $(CFLAGS) -c $< install: $(LIBEXECDIR@WIN32TAG@) $(SYSCONFDIR)/mlterm $(LIBTOOL_INSTALL) -m 755 mlterm-zoom $(LIBEXECDIR@WIN32TAG@) uninstall: rm -f $(LIBEXECDIR@WIN32TAG@)/mlterm-zoom $(LIBEXECDIR@WIN32TAG@): mkdir -p $(LIBEXECDIR@WIN32TAG@) $(SYSCONFDIR)/mlterm: mkdir -p $(SYSCONFDIR)/mlterm clean: rm -rf $(OBJS) mlterm-zoom mlterm-zoom.exe *.core .libs distclean: clean rm -f Makefile mlterm-3.9.3/contrib/tool/mlterm-zoom/README000066400000000000000000000011421441203364000206000ustar00rootroot00000000000000mlterm-zoom - Change MLTerm Font Size with the Mouse Wheel Installation ============ % ./configure ... --with-tools=mlterm-zoom,... % make % su # make install % echo 'conf_menu_path_2 = mlterm-zoom' >> ~/.mlterm/main How To Use ========== Click mouse wheel with CTRL key, mlterm-zoom displays a small white window. Scrolling the wheel up or down on the white window, you can increase or decrease font size. If you finish adjusting font size, Click mouse button or focus out on the white window. License ======= BSD license (modified or no `advertising clause') See "LICENCE" file for details. mlterm-3.9.3/contrib/tool/mlterm-zoom/mlterm-zoom.c000066400000000000000000000036371441203364000223610ustar00rootroot00000000000000/* -*- c-basic-offset:2; tab-width:2; indent-tabs-mode:nil -*- */ #include #include #include #define BUTTON_4_COMMAND "\x1b]5379;fontsize=larger\x07" #define BUTTON_5_COMMAND "\x1b]5379;fontsize=smaller\x07" void event_loop(Display *display); int main(int argc, char *argv[]) { Display *display; Window window; XSetWindowAttributes attrs; char *display_name = NULL; int screen_no; int x, y, w, h, i; x = 0; y = 0; i = 1; while (i < argc) { if (strcmp(argv[i], "--display") == 0) { i++; display_name = argv[i]; } else if (strcmp(argv[i], "--geometry") == 0) { i++; XParseGeometry(argv[i], &x, &y, &w, &h); } i++; } w = h = 32; display = XOpenDisplay(display_name); screen_no = DefaultScreen(display); attrs.override_redirect = True; attrs.event_mask = ButtonPressMask | KeyPressMask | LeaveWindowMask; attrs.background_pixel = WhitePixel(display, screen_no); attrs.border_pixel = BlackPixel(display, screen_no); window = XCreateWindow(display, RootWindow(display, screen_no), x - (w / 2), y - (h / 2), w, h, 2, DefaultDepth(display, screen_no), InputOutput, DefaultVisual(display, screen_no), CWOverrideRedirect | CWEventMask | CWBackPixel | CWBorderPixel, &attrs); XMapWindow(display, window); event_loop(display); return 0; } void event_loop(Display *display) { XEvent event; while (1) { XNextEvent(display, &event); switch (event.type) { case ButtonPress: if (event.xbutton.button == 4) { fprintf(stdout, BUTTON_4_COMMAND); } else if (event.xbutton.button == 5) { fprintf(stdout, BUTTON_5_COMMAND); } else { return; } fflush(stdout); break; case LeaveNotify: return; break; default: break; } } return; } mlterm-3.9.3/doc/000077500000000000000000000000001441203364000135705ustar00rootroot00000000000000mlterm-3.9.3/doc/en/000077500000000000000000000000001441203364000141725ustar00rootroot00000000000000mlterm-3.9.3/doc/en/ChangeLog.old000066400000000000000000000643531441203364000165340ustar00rootroot00000000000000[20020422] * ml_picture_gdk.c is added. (Thanks to Minami Hirokazu san) [20020421] * ml_picture_dep.[ch], where graphic library dependent codes are implements, is separated from ml_picture.c. * if larger number than 0 is specified for --lsp, underlines cannot be cleared. fixed. (Thanks to Nanashi san) * aafont config files are replaced by contributed ones. (Thanks to Kubota Tomohiro san) [20020414] * 2.4.0 release [20020413] * each line had its tab stop list and "\x1bH" didn't work as expected. fixed. * doc/ja/README.comb is added. [20020410] * man/mlterm.1 is updated. * scroll by 'd' and 'u' keys was NA. fixed. * compilation failed in ml_vt100_parser.c if __DEBUG is defined. fixed. (Thanks to Nadim Shaikli) [20020407] * backscroll_rows and is_backscroll_mode variables are not initialized. fixed. * PAGE_DOWN,PAGE_UP,SCROLL_DOWN,SCROLL_UP shortcut keys are processed twice per one press. fixed. [20020407] * PAGE_DOWN,SCROLL_DOWN shortcut keys are added, and PAGE_DOWN,PAGE_UP,SCROLL_DOWN, SCROLL_UP shortcut keys are available under backscroll mode. (Thanks to Nobuyoshi Nakada) * ml_term_xxx.[ch] are cleaned up. * meta key is processed even when shift key, control key or so is pressed. fixed. (Thanks to Nanashi san) * 2.3.1 => 2.4.0 in version.h, mlterm.spec [20020329] * memory leaks in ml_color_custom.c. fixed. [20020329] * all the colors defined in rgb.txt are available. * #RRGGBB format is supported for fg_color,bg_color,sb_fg_color,sb_bg_color. [20020328] * lines sometimes get left-aligned. fixed. (Thanks to Nadim Shaikli) [20020328] * parsing sequence from pty is stopped after 4096 bytes are parsed even if it is still left in pty.(Thanks to Nanashi san) * LF on the first char of an arabic word gets the original line not to be redrawn correctly. fixed.(Thanks to Nadim Shaikli) * There were a bug around calculating the meeting position of ltr and rtl characters. fixed. (Thanks to Nadim Shaikli) * if cursor is on a space after a RTL word at the end of line, the RTL word strangely moves. fixed. (Thanks to Nadim Shaikli) [20020324] * strange cursor movement on bidi is fixed. * memory leak in ml_bidi.c:ml_bidi() is fixed. * -J/--dyncomb option can be dynamically changed. [20020323] * if mlterm doesn't work as a genuine daemon and cannot start any pty windows, it outputs error messages and do exit(1). (Thanks to Nadim Shaikli) * cursor movement in ltr-rtl meeting point is improved. (Thanks to Nadim Shaikli) * on some enviroments Xutf8LookupString was not found even if it exits because of failure of '-lX11'. fixed. (Thanks to Kubota Tomohiro san & Nakada Nobuyoshi san) [20020321] * cursor doesn't move correctly before the meeting point of LTR and RTL characters. fixed. * the line cursor is previously located should be redrawn even if it is not modified. [20020320] * cursor movement policy before the meeting point of LTR and RTL characters is changed. * character set designated to G1 is unexpectedly changed if enacs=\E)0,smacs=^N,rmacs=^O. fixed. [20020317] * some scrolled out lines aren't bidi rendered. fixed. (Thanks to Nadim Shaikli) * login,logout are not used for utmp operations on *BSD. [20020316] * if the cursor is at the end of line under bidi mode, according to the previous character whose property is STRONG and the base direction of the line, output of fribidi_log2vis is modified for more natural cursor movement. * -J/--dyncomb couldn't be used without arguments. fixed. [20020316] * scrolling downward over the lowest filled line fails. fixed. * arabic combined characters are processed as the one which occupies one column, not two. * -J/--dyncomb, use_dynamic_comb option is added. * "-- INSERT (lang) --" message can be shown in a strange line on vim. fixed. (Thanks to Nadim Shaikli) [20020315] * some bugs in man/mlterm.1 are fixed. (Thanks to Nadim Shaikli) * arabic shaping errors are fixed. (Thanks to Nadim Shaikli) * redrawn region under bidi mode is optimized. [20020314] * ml_char_copy() frees necessary memory area if src and dst is equal. fixed. (Thanks to Sakamoto Hironori san) * -J/--rtl, bidi_base_dir_is_rtl option is removed. (Thanks to Nadim Shaikli) * when all lines in scroll region is scrolled out, cursor position is not moved correctly. fixed. [20020312] * if USE_FRIBIDI is not defined, compilation fails in ml_bidi() because of shortage of arguments. (Thanks to Nanashi san) * primitive data structure around ml_image* is changed. [20020310] * compilation fails in ml_term_manager.c by configure --disable-fribidi because of undefined reference to ml_bidi_set_base_dir(). (Thanks to Nanashi san) * only limited region is scrolled when output characters is over screen buffer. * -J,--rtl,bidi_base_direction_rtl option is dynamically changeable. [20020308] * COLORTERM_BCE is unset from the beginning. * arabic characters two of which can turn into one glyph are supported. * -J,--rtl,bidi_base_direction_rtl option is added. This option lets bidi base direction RTL. [20020306] * core dump in processing _XROOTPMAP_ID. fixed. (Thanks to Nanashi san) * strange format of man page is fixed. (Thanks to Mike Fabian) * when line is wrapped around, characters at the end of line are swapped. fixed. (Thanks to Mike Fabian) [20020304] * -q/--extkey use_extended_scroll_shortcut option , which enables scroll shortcutkey extension(scrolling by arrow keys, 'j' and 'k'), is added.(disabled by default) * ISO8859_1 and ISO8859_1X in xxfont config files aren't distinguished. fixed. (Thanks to Kubota Tomohiro san) * 0x1b is inserted when INSERT_SELECTION etc keys are pressed if they are assigned to Mod + Foo. (Thanks to Nobuyoshi Nakada san) * whether Xutf8LookupString exists or not is checked in configure. (Thanks to Nobuyoshi Nakada san) [20020302] * whether libsocket exists or not is checked in configure. (Thanks to Nadim Shaikli) * ISO-8859-N character sets except ISO-8859-1 cannnot be shown correctly under anti alias mode. fixed. (Thanks to Kubota Tomohiro san) [20020228] * ESC [ J clears characters to the left side of the cursor. fixed. (Thanks to KATO Kazuyoshi san) * another (experimental) engine of getting transparent background picture is implemented. [20020225] * -e option fails on Linux etc. fixed. * 2.3.1 released. [20020223] * 2.3.0 released. [20020222] * scroll fails ? [20020222] [20020222] * mlterm can dump core if screen is scrolled while cursor is out of scroll region. fixed. (Thanks to Minami Hirokazu san) [20020222] * 2.3.0 release date is added to mlterm.spec. [20020222] * transparency by _XROOTPMAP_ID behaves strangely if Window is moved to outside of Display. fixed. [20020222] * transparency by _XROOTPMAP_ID is also supported without Imlib. * w3mmlconfig/section/scrollbar is lost. fixed. (Thanks to Sakamoto Hironori san) [20020221] * garbage is left on arrow images of scrollbar. fixed. * w3mmlconfig is updated. (Thanks to Sakamoto Hironori san) [20020221] * brightness cannot be changed in transparent mode. fixed. (Thanks to Minami Hirokazu san) [20020221] * man/mlterm.1 is updated. * -H option accepts over 100. [20020221] * transparent background using root pixmap by "_XROOTPMAP_ID" atom is supported. [20020220] * compilation fails on platforms where snprintf doesn't exist. fixed. * ISCII rendering fails. fixed. * extra processing which can cause core dump under utf8 + bidi mode or iscii mode without fribidi or libind is removed. (Thanks to Takahasi Tamotsu san) [20020219] * utmp,wtmp operation by login,logout,logwtmp is supported on both Linux/glibc2 and *BSD. (Thanks to Minami Hirokazu san) [20020219] * performance of utf8 + bidi mode without fribidi is improved. * if scroll region is changed multiple times , scroll can fail. fixed. * README.bidi is added. [20020218] * mlclient appends extra white space for ipc message. fixed. * character background color which is different from Window background one is not drawn under transparent mode. fixed. (Thanks to KATO Kazuyoshi san) * mlconf_curses is updated (2002/02/18 version). (Thanks to Minami Hirokazu san) [20020217] * mlclient with invalid options causes mlterm process to exit. fixed. * typo in LICENCE file is fixed. (Thanks to Fumitake Taniguchi san) [20020217] * iscii_lang is added to mlterm configuration protocol. * mlclient --help or --version causes mlterm process to exit. fixed. (Thanks to Ikezoe Hiroyuki san) [20020216] * typo fixed. (Thanks to Mike Fabian) [20020215] * New documents(doc/ja/README.server,doc/ja/README.tate) are added and doc/ja/README.ja doc/en/PROTOCOL doc/en/History are updated. [20020215] * code clean up [20020215] * ImlibData is created and managed for each Display. * existing test of socklen_t fails because of my typo. fixed. (Thanks to Sakamoto Hironori san) [20020214] * some bugs around utmp are fixed. (Thanks to Mike Fabian) [20020213] * priv_fg and priv_bg cannot be customized. fixed. (Thanks to Nekoie san) * utmper is supported. (Thanks to Mike Fabian) [20020213] * before starting daemon , whether /tmp/mlterm.unix exists or not is checked. and it is also unlinked when mlterm server exits. [20020213] * compilation failed in tool/mlclient/main.c. fixed. (Thanks to Okazaki Tetsurou san) * memory leaks when mlclient is connected. fixed. * transparent sample scrollbar is 1 dot wider than expected. fixed. * scrollbar_view_name , sb_fg_color , sb_bg_color can be dynamically changed. * mlconfig layout is changed. [20020212] * -e option fails for memory allocation. fixed. (Thanks to Nekoie san) * mlterm with -j and -P 0 options can start without X. * mlterm can manage multiple display connections. * compilation fails around socket on HP-UX 10.20. fixed. [20020211] * daemon mode is supported and -j/--daemon/daemon_mode option is added. * mlclient program (tool/mlclient) is added. * characters in the beginning of lines cannot be selected. fixed. (Thanks to nekoie san) * 2 dot margin area in both right and left sides are cleared since garbages can be left there. [20020210] * -Y/--decsp/compose_dec_special_font option is added. [20020210] * #include is omitted in kiklib/src/kik_utmp_bsd.c. fixed. (Thanks to Nanashi san) [20020209] * README.ja is rewritten. * BSD type utmp/wtmp/lastlog is supported. (--enable-utmp configure option) [20020208] * brightness-adjusted transparent background costs when fvwm2 style virtual screens are changed. fixed.(thanks to Nanashi san) [20020208] * if --enable-anti-alias is not specified , compilation fails. fixed. [20020208] * processing half width character in vertical view is improved. * XLFD font name to query internally is strange. fixed. (Thanks to Karl Koehler) * when fade_ratio is set 100 from mlconfig , screen is not completely cleared. fixed. [20020207] * window increment/decrement size and minimum window width and height can be wrong. fixed. (Thanks to Minami Hirokazu san) [20020207] * underline is drawn on the left side of character under vertical mode. [20020207] * strange mouse position is reported under vertical mode. fixed. [20020207] * vertical mode and veriable column width mode are considered for reporting mouse position to console applications. * -Q/--vcur/use_vertical_cursor option is added. * mlconfig_curses is updated.(see [patch tracker 513620]) (thanks to Minami Hirokazu san) [20020206] * -Z/--multicol/use_multi_column_char option is added. [20020206] * if scrollbar_mode is none and window is resized , garbages are left on screen. fixed. * w3mmlconfig is updated(around scrollbar_mode). (thanks to Sakamoto Hironori san) [20020206] * -O/--sbpos/scrollbar_position option is removed and -O/--sbmod/scrollbar_mode option is added. * scrollbar can be dynamically switched among off , right and left. * default value of use_scrollbar option is true , not false. [20020206] * step in resizing window gets wrong. fixed. [20020206] * when font size is changed with right scrollbar , scrollbar is placed in strange position. fixed. [20020205] * -O/--sbpos/scrollbar_position option is added. * processing brightness adjustment under transparent mode is tuned. * doc/ja/README.ja is updated. [20020205] * cywin port patch is merged.(thanks to Tetsurou Okazaki san) * XRegisterIMInstantiateCallback is never called on sunos. [20020204] * When CapsLock or NumLock is on , control mask or shift mask etc is not recogized. fixed. (Thanks to K.Kawabata san) * cursor disappears when screen scrolled with scrollbar. fixed. (Thanks to Sakamoto Hironori san/Minami Hirokazu san) * w3mmlconfig is updated.(thanks to Sakamoto Hironori san) * baurates are explicitly set with cfsetispeed,cfsetospeed.(thanks to t-matsuo san) [20020203] * If --xim=false is specified , XRegisterIMInstatiateCallback is not done. [20020203] * mlterm dumps core under cjk vertical mode. fixed. * doc/ja/README.ja doc/ja/FAQ doc/en/PROTOCOL are updated. [20020203] * cursor disappears under backscroll mode. fixed. (Thanks to Sakamoto Hironori san) * -K/--maxptys/max_ptys option is added. You can use more than 5 pty windows in one process. Note that max_ptys option accepts numbers between 1 and 32. [20020202] * --shade/shade_ratio option is renamed to --bright/brightness. * brightness option works under transparent mode. [20020202] * -H/--shade/shade_ratio option is added. [20020202] * if number of terminal rows is double as many as that of cols under vertical mode , mlterm dumps core. fixed. * mongol vertical mode is added. * "Font" Tab is added to mlconfig. [20020201] * -o/--lsp/line_space option is added. [20020131] * If both vertical view and bidi are used at the same time , terminal window can become too large. fixed. * under vertical mode settings in etc/tfont and etc/taafont are used. [20020130] * vertical view support is added.(-G/--vertical/vertical_mode option) * actual screen size can be specified with -1/--wscr/screen_width_ratio and -2/--hscr/screen_height_ratio options regardless of console columns and rows. [20020129] * 2.2.0 released [20020129] * mlcurses_conf is updated(20020127 version).(thanks to Minami Hirokazu san) [20020129] * copy&paste with kterm fails. fixed. (thanks to Sakamoto Hironori san) * minus value specified for unsigned int is treated as error. (thanks to Minami Hirokazu san) [20020128] * variable column width and character combining are turned on in ISCII encoding. [20020128] * doc/en/README.iscii is added. * fribidi-config is used to check libs and cflags for fribidi. * -h help messages are improved.(thanks to Kubota Tomohiro san) * font_larger_smaller_size option is renamed to step_in_changing_font_size. * man/mlterm.1 manual is updated.(thanks to Kubota Tomohiro san) [20020126] * big5_buggy option didn't work(is always true). fixed. * XIM fg/bg color may be faded. fixed. * man/mlterm.1 manual is updated. [20020125] * mlconf_curses is updated(20020125 version) and LICENCE,Makefile,mlcc.html files are added. (thanks to Minami Hirokazu san) * CP932 gaiji characters (IBM , NEC , NECIBM) <=> UCS conversion is supported. * -z/--largesmall/font_larger_smaller_size option is added. [20020124] * use_cp932_ucs_for_xft option is true by default. * screen is corrupt when scrolled. fixed. * if font_size_range is not set , mlterm behaves unexpectedly. fixed. * mlconf_curses(2002/01/24 version) is added. (thanks to Minami Hirokazu san) * doc/ja/FAQ is added. [20020124] * NEC Gaiji couldn't be converted to UCS. fixed. * Japanese gaiji characters are converted to UCS. * if -w [fontsize] is too small or too large , mlterm may dump core. fixed. * foreground color couldn't be change run time. fixed. [20020124] * cursor may disappear when selected region color is restored. fixed. * w3mmlconfig(2002/01/15 version) is added(tool/w3mmlconfig) * contrib/scrollbar/sample is moved to scrollbar/sample [20020123] * ISCII rendering is tuned up. * etc/font and etc/vfont format is changed. (default font can be specified.) [20020122] * -c/--cp932/use_cp932_ucs_for_xft option is added. [20020122] * aafont file format is changed. ([Font Family]-[Font Encoding](:[Percentage])) * font or vfont is used when XIM fontset is created under AA mode. [20020120] * many codes are cleaned up. * 'l' instead of 'i' is checked for DynaFont problem. [20020119] * DynaFont problem is fixed by checking 'i' character width before 'W' character. (thanks to Asaki Takumi san) * font,aafont are read before vfont,vaafont for variable column width fonts. [20020118] * XftTextExtents returns full width extents for DynaFont "W" , which makes space between characters too wide. fixed(there is still room for improvement). (thanks to Asaki Takumi san) * not only background color but foreground color is faded. [20020115] * calculating width of anti alias font was somewhat wrong. fixed. * variable column width anti alias fonts , which are specified in ~/.mlterm/vaafont , are supported. * #error instead of #=#error is returned. * ESC]5380;wall_pictureBEL returns #wall_picture= instead of #error when no wall picture is used. [20020115] * JISX0201 katakana copy&paste failed. fixed.(thanks to Kubota Tomohiro san) * ESC]5380;pwdBEL is supported. * #=#error instead of #=error is returned when error happens around ESC]5380;ptBEL sequence. [20020114] * fade_ratio can be dynamically changed. * ESC]5379;fade_ratio=BEL , ESC]5380;fade_ratioBEL , ESC]5380;wall_pictureBEL are supported.(see doc/en/PROTOCOL) * FocusIn/FocusOut events to windows except a top window are ignored. [20020113] * MSB of single shifted G3 characters in EUCJP(EUCJISX0213) is set.(thanks to Kubota Tomohiro san) * ESC]5379;wall_picture=BEL stops wall picture. [20020113] * mlterm configuration protocol is decided and implemented.(see doc/en/PROTOCOL) * cursor highlight bug is fixed. [20020111] * cursor form is changed when window is focused or unfocused. * when a character whose color is reversed is drawn under wall paper or tranparent mode , not background image but the background color of the charcter is used. (thanks to Masao Uebayashi san) * ESC ] 20 ; pt BEL sequence is supported.(thanks to Minami Hirokazu san) [20020110] * big5 unstandard characters can be converted to and from ucs4. [20020109] * -r/--fade/fade_ratio option is added. * infinite loop owing to malformed escape sequence like "ESC ] ;" can be escaped by pressing LF.(Minami Hirokazu san) [20020108] * fribidi 0.10.0(where FriBidiStrIndex is 32bit , not 16bit) is supported. * selecting region policy is changed(character is selected after mouse pointer passing over it) , and some bug are fixed. [20020108] * mlterm with --enable-debug option can dump core owing to failure of list operations. fixed. (thanks to Karl Koehler) * ISCII / Bidi codes are more shared. * mlterm.spec is updated (thanks to Kiyoshi Nishizawa san) * ISCII characters in backscroll logs cannot be selected(and copyed) correctly. fixed. * Window is not resized when font size is changed. fixed. * -g option accepts minus x/y position. * vertical tab sometimes fails. fixed.(thanks to nekoie san) * default font size range is 6 - 30. [20020106] * ISCII support codes are added. (still unstable) * INIT_PARSER short cut key is removed and "Full Rest" button is added to mlconfig. * when color rgb is explicitly assigned in ~/.mlterm/color , reversed color is not drawn correctly under Anti Alias mode. fixed. (thanks to nekoie san) * ISO-8859-11 can be used as a -E option value. * ~/.mlterm/vlfont is renamed to ~/.mlterm/vfont * -V/--varlen/use_variable_length_column option is renamed to -V/--varwidth/use_variable_column_width * Kochi Mincho sample is added to etc/aafont. [20020102] * variable length column is supported. (-V/--verlen/use_variable_length_column option) * DEC_SPECIAL characters are not shown under TERM=kterm and non-iso2022 encoding. fixed. [20020102] * selected region is reset in scrolling with dragging mouse. fixed. * 2.1.2 is released. [20011230] * cursor doesn't move correctly on full width characters(critical bug!). fixed. * If scroll commands appear with scroll region changing one by one , the number of redrawing screen becomes too much. fixed. * mistake of mlterm.spec is fixed. * 2.1.1 is released. [20011229] * 2.1.0 is released. [20011229] * compilation of src/ml_image.c fails in Solaris,HP-UX,EWS4800. fixed. (thanks to Sakamoto Hironori san) * support for the sequences invoking dec-special characters is improved. * memory leaks when combining chars are selected twice or more. fixed. [20011228] * screen can be illegally scrolled when characters are inserted at the buttom of screen. fixed. (thanks to Minami Hirokazu san) [20011228] * INIT_PARSER short cut key (which initializes status of pty encoding parser) is added. * invoking dec-special characters by SI/SO is supported.(non-ISO2022 encoding only) [20011227] * if pty encoding is stateless , state of pty encoding parser is not reset when key is pressed. * "ESC [ ? 25 h" , "ESC [ ? 25 l" sequences are supported. [20011226] * typos in mlterm.1 are fixed.(thanks to Kubota Tomohiro san) * something like "ESC [ 34 ; 0 ; m" sequence is parsed incorrectly.fixed. (thanks to Sakamoto Hironori san) * cursor is not repainted under transparent mode. fixed. (thanks to Uebayashi Masao san) [20011225] * memory leaks if you use both -m and -bi options under utf8 encoding. fixed. * mkf/mkf_ucs4_xxx.c are thread-safe. * Shift + Mouse Button operations under console apps useing mouse tracking are supported. [20011225] * wraparound word can be selected. * mlterm core dumps if XMODIFIERS variable is empty or illegal value. fixed. [20011224] * US-ASCII chars may be shown incorrectly under EUC-CN/GBK/GB18030. fixed. * mlterm.1 document is updated a little more.(thanks to Kubota Tomohiro san) * Unicode <=> CNS11643-1992 plane 3 convertion table is added. * EUC-TW is excluded from Unicode subset group. * the default value of use_bidi and use_combining is true. * if mlterm is resized under bidi-mode , you cannot copy&paste RTL chars. fixed. [20011222] * Hangul chars are not shown correctly in --noucsfont. fixed. * manual page(mlterm.1) is updated. (thanks to Kubota Tomohiro san) * the same CTEXT generator engine is used whether --big5bug option is set or not. fixed. [20011221] * option names are changed. --ucs2other => --noucsfont unicode_to_other_cs => not_use_unicode_font --all2ucs => --onlyucsfont all_cs_to_unicode => only_use_unicode_font * full width chars are not shown correctly in --onlyucsfont. fixed. * -8/--88591 (iso88591_font_for_usascii) option is added. * -R /usr/local/lib -R /usr/X11R6/lib options are added to LIBS macro in src/Makefile.in tool/mlconfig/Makefile.in (thanks to Uebayashi Masao san) * illegal chars which is not based on ISO2022 (e.g. KOI8-R) are also accepted if at all possible in ISO2022-based encodings. [20011220] * prefer_utf8_selection and xct_process_mode options are removed , and copy_paste_via_ucs option is added. * BIG5HKSCS is separated into BIG5 and HKSCS. * memory leaks when copy&paste combined chars. fixed. * illegal chars based on ISO2022 are accepted if at all possible in ISO2022-based encodings. * ISO2022 parser doesn't parse correctly when sequence is splited. fixed. * core dump when copy&paste with no chars selected. fixed. [20011216] * prefer_utf8_selection includes auto_detect_utf8_selection. that is , true/false/auto can be used as value. * conv_to_generic_iso2022 and pre_conv_xct_to_ucs options are obsoleted. * xct_process_mode(-c/--xct) option is added. this accepts ucs , raw or normal value. * new "copy&paste" tab is added to mlconfig * --ucshater => --ucs2other --ucslover => --all2ucs [20011215] * prefer_utf8_selection (-U/--utf8sel) , auto_detect_utf8_selection (-o/--autoutf8) options are added. * when window resized , font changed or encoding changed , screen may not be redrawn or cursor position may be strange. fixed. [20011215] * ESC H (set tab) ESC [ 0 g (clear tab) ESC [ 3 g (clear all tabs) are supported. * Big5HKSCS encoding/charset is supported. * US ASCII font is not changed when encoding is changed to ISO8859 variant or UTF8. fixed. * huge memory leaks when window is resized. fixed. * input text is received in order of XmbLookupString => XLookupString => Xutf8LookupString. * UTF8 selection is received as it is. * Big5 buggy sequence is automatically detected. [20011214] * mlconfig is replaced by the new one designed by Kubota Tomohiro san(thanks) * mlconfig works asynchronous. * documentation for big5_buggy option is added. * memory leaks when pre_conv_xct_to_ucs option is changed more than twice. fixed. [20011214] * mlterm can core dump in kik_locale_init(). fixed. * XA_STRING property is supported in copy and paste. * cursor-control characters inside ESC sequences are partially supported. (Thanks to Minami Hirokazu san) [20011213] * memory leaks around encoding parsers. fixed. * XIM codes are rewritten. XRegisterIMInstantiateCallback() is used. [20011212] * garbages can be left on screen in scrolling. fixed. * The implementation of VT102 INS/DEL lines functions was buggy. fixed. * If XMODIFIERS's xim is executed after mlterm started , mlterm won't use it even if XIM_OPEN key is pressed. fixed. [20011212] * the number of redrawing in bidi mode is reduced. * ml_image modules is cleaned up. * INDEX/RINDEX vt100 implementation was wrong. fixed. * ESC # , ESC E , ESC [ ? l 3 , ESC [ ? l 5 , ESC [ ? h 3 , ESC [ ? h 5 are supported. * "ESC [ ; ..." is regarded as "ESC [ 0 ; ..." * buffer overflow in parsing ESC [ ... sequence is fixed. * the size of mlconfig window is shrunk. [20011210] * Big5 copy and paste problem is fixed. (--big5bug option is added) * minor bugs of bidi are fixed. * documents are updated except --big5bug option. * character shaping stops unless mlterm works on bidi mode. [20011208] * Bidi is supported.(FriBidi is required) * Arabic character shaping is supported. * ml_image module is cleaned up. * many minor bugs are fixed. * mlterm icons are added.(thanks to Kubota Tomohiro san.) [20011203] * ml_get_locale() in ml_locale.c returns "C" if setlocale() failed in ml_locale_init(). * ml_get_xim() in ml_xim.c returns NULL if xim_locale argument is "C" or ml_locale_init(xim_locale) fails. * doc/en/README.sb is added. * doc/{ja|en}/README.xim is added. [20011202] * BEL(0x7) is supported and bel_mode option(none/visual/sound) is added. * VWERSE typo is fixed.(ml_pty_fork_{streams|bsd}.c) * LC_CTYPE=C mlterm and pressing Shift + Space causes segmentation fault. fixed. * WINDOWID env var doesn't set that of VT100 Window but Top Window. * pink and brown colors are added. * "update: ..." lines of all files are removed. mlterm-3.9.3/doc/en/ControlSequences000066400000000000000000000645231441203364000174230ustar00rootroot00000000000000comment -*- mode: text; tab-width:2; indent-tabs-mode:nil -*- List of escape/control sequences which mlterm supports. O: Support, -: Not support MNEMONIC SEQUENCE https://vt100.net/docs/vt520-rm/ek-vt520-rm.pdf O CBT (Cursor Backward Tabulation) CSI Pn Z O CHA (Cursor Horizontal Absolute) CSI Pn G O CHT (Cursor Horizontal Forward Tabulation) CSI Pn I O CNL (Cursor Next Line) CSI Pn E O CPL (Cursor Previous Line) CSI Pn F O CPR (Cursor Position Report) CSI 6 n - CRM (Show Control Character Mode) CSI 3 [hl] O CUB (Cursor Backward) CSI Pn D O CUD (Cursor Down) CSI Pn B O CUF (Cursor Forward) CSI Pn C O CUP (Cursor Position) CSI Pl;Pc H O CUU (Cursor Up) CSI Pn A O DA1 (Primary Device Attributes) CSI c O DA2 (Secondary Device Attributes) CSI > c O DA3 (Tertiary Device Attributes) CSI = c O DCH (Delete Character) CSI Pn P - DECAAM (Set/Reset Auto Answerback Mode) CSI ? 100 [hl] O DECAC (Assign Color) CSI Ps1;Ps2;Ps3 , l O DECALN (Screen Alignment Pattern) ESC # 8 O DECANM (ANSI Mode) CSI ? 2 [hl] - DECARM (Autorepeat Mode) CSI ? 8 [hl] - DECARR (Select Auto Repeat Rate) CSI Ps - p - DECARSM (Set/Reset Auto Resize Mode) CSI ? 98 [hl] O DECATC (Alternate Text Color) CSI Ps1;Ps2;Ps3 , } - DECATCBM (Set/Reset Alternate Text Color Blink Mode) CSI ? 115 [hl] - DECATCUM (Set/Reset Alternate Text Color Underline Mode) CSI ? 114 [hl] - DECAUPSS (Assigning User-Preferred Supplemental Sets) DCS Pn ! u Dscs ST O DECAWM (Autowrap Mode) CSI ? 7 [hl] O DECBI (Back Index) ESC 6 O DECBBSM (Bold and Blink Style Mode) CSI ? 116 [hl] O DECBKM (Backarrow Key Mode) CSI ? 67 [hl] - DECCANSM (Conceal Answerback Message Mode) CSI ? 101 [hl] - DECCAPSLK (Caps Lock Mode) CSI ? 109 [hl] O DECCARA (Change Attributes in Rectangular Area) CSI Pt;Pl;Pb;Pr;Ps1;...;Psn $ r - DECCKD (Copy Key Default) DCS " z D...D ST O DECCKM (Cursor Keys Mode) CSI ? 1 [hl] O DECCKSR (Memory Checksum Report) CSI ? 63;Pid n DCS Pid ! ~ D...D ST O DECCOLM (Select 80 or 132 Columns per Page) CSI ? 3 [hl] O DECCRA (Copy Rectangular Area) CSI Pts;Pls;Pbs;Prs;Pps;Ptd;Pld;Ppd $ v - DECCRTSM (Set/Reset CRT Save Mode) CSI ? 97 [hl] - DECCRTST (CRT Saver Timing) CSI Ps - q O DECCTR (Color Table Request) CSI 2;Pu $ u O DECDC (Delete Column) CSI Pn ' ~ O DECDHL (Double-WidthDouble-Height Line) ESC # [34] O DECDLD (Dynamically Redefinable Character Sets) DCS Pfn;Pcn;Pe;Pcmw;Pss;Pt;Pcmh;Pcss f Dscs Sxbp1;...;Sxbpn ST O DECDMAC (Define Macro) DCS Pid;Pdt;Pen ! z D...D ST - DECDLDA (Down Line Load Allocation) CSI Ps , z O DECDWL (Double-WidthSingle-Height Line) ESC # 6 O DECECM (Erase Color Mode) CSI ? 117 [hl] - DECEKBD (Extended Keyboard Report) APC : ppp mm ST - DECELF (Enable Local Functions) CSI Pf1;Pc1;...;Pfn;Pcn + q O DECERA (Erase Rectangular Area) CSI Pt;Pl;Pb;Pr $ z - DECES (Enable Session) CSI & x - DECESKM (Enable Secondary Keyboard Language Mode) CSI ? 104 [hl] O DECFI (Forward Index) ESC 9 O DECFRA (Fill Rectangular Area) CSI Pch;Pt;Pl;Pb;Pr $ x - DECFWM (Set/Reset Framed Windows Mode) CSI ? 111 [hl] - DECHDPXM (Set/Reset Half-Duplex Mode) CSI ? 103 [hl] - DECHEBM (Hebrew/N-A Keyboard Mapping) CSI ? 35 [hl] - DECHEM (Hebrew Encoding Mode) CSI ? 36 [hl] - DECHWUM (Host Wake-Up Mode (CRT and Energy Saver)) CSI ? 113 [hl] O DECIC (Insert Column) CSI Pn ' } O DECID (Identify Device) ESC Z O DECINVM (Invoke Macro) CSI Pid * z - DECIPEM (Enter/Return from IBM ProPrinter Emulation Mode) CSI ? 58 [hl] - DECKBD (Keyboard Language Selection) CSI Ps1;Ps2 SP } - DECKBUM (Typewriter or Data Processing Keys) CSI ? 68 [hl] O DECKLHIM (Keyboard LED's Host Indicator Mode) CSI ? 110 [hl] O DECKPAM (Keypad Application Mode) ESC = - DECKPM (Key Position Mode) CSI ? 81 [hl] O DECKPNM (Keypad Numeric Mode) ESC > - DECLANS (Load Answerback Message) DCS Ps v D...D ST - DECLBAN (Load Banner Message) DCS Ps r D...D ST - DECLFKC (Local Function Key Control) CSI Pk1;Pf1;...;Kpn;Pfn * } - DECLL (Load LEDs) CSI Ps q O DECLRMM (Left Right Margin Mode) CSI ? 69 [hl] - DECLTOD (Load Time of Day) CSI Ps1;Ps2 , p - DECMCM (Set/Reset Modem Control Mode) CSI ? 99 [hl] - DECNAKB (Greek/N-A Keyboard Mapping) CSI ? 57 [hl] O DECNCSM (Set/Reset No Clearing Screen On Column Change) CSI ? 95 [hl] O DECNKM (Numeric Keypad Mode) CSI ? 66 [hl] - DECNRCM (National Replacement Character Set Mode) CSI ? 42 [hl] - DECNULM (Set/Reset Ignoring Null Mode) CSI ? 102 [hl] - DECNUMLK (Num Lock Mode) CSI ? 108 [hl] O DECOM (Origin Mode) CSI ? 6 [hl] - DECOSCNM (Set/Reset Overscan Mode) CSI ? 106 [hl] - DECPAK (Program Alphanumeric Key) DCS " y D...D ST - DECPCCM (Page Cursor-Coupling Mode) CSI ? 64 [hl] - DECPCTERM (Enter/Exit PCTerm or Scancode Mode) CSI ? Ps1;Ps2 r - DECPEX (Printer Extent Mode) CSI ? 19 [hl] - DECPFF (Print Form Feed Mode) CSI ? 18 [hl] - DECPFK (Program Function Key) DCS " x D...D ST - DECPKA (Program Key Action) CSI Ps + z - DECPS (Play Sound) CSI Pv;Pd;Pn , ~ O DECRARA (Reverse Attributes in Rectangular Area) CSI Pt;Pl;Pb;Pr;Ps1;...;Psn $ t O DECRC (Restore Cursor) ESC 8 - DECRLCM (Right-to-Left Copy) CSI ? 96 [hl] - DECRLM (Cursor Right to Left Mode) CSI ? 34 [hl] O DECRQCRA (Request Checksum of Rectangular Area) CSI Pid;Pp;Pt;Pl;Pb;Pr * y O DECRQDE (Request Displayed Extent) CSI " v - DECRQKD (Request Key Definition) CSI Ps1;Ps2 , w - DECRQKT (Key Type Inquiry) CSI Ps , u O DECRQM (Request Mode Host To Terminal) (ANSI) CSI Pa $ p (DEC) CSI ? Pd $ p - DECRQPKFM (Program Key Free Memory Inquiry) CSI + x O DECRQPSR (Request Presentation State Report) CSI Ps $ w O DECRQSS (Request Selection or Setting) DCS $ q D...D ST O DECRQTSR (Request Terminal State Report) CSI Ps $ u - DECRQUPSS (User-Preferred Supplemental Set) CSI & u O DECRSPS (Restore Presentation State) DCS Ps $ t D...D ST - DECRSTS (Restore Terminal State) DCS Ps $ p D...D ST O DECSACE (Select Attribute Change Extent) CSI Ps * x O DECSASD (Select Active Status Display) CSI Ps $ } O DECSC (Save Cursor) ESC 7 O DECSCA (Select Character Protection Attribute) CSI Ps " q - DECSCL (Select Conformance Level) (L1) CSI 61 " p (L4) CSI 6 n ; Pn " p - DECSCLM (Scrolling Mode) CSI ? 4 [hl] O DECSCNM (Screen ModeLight or Dark Screen) CSI ? 5 [hl] - DECSCP (Select Communication Port) CSI Ps1;Ps2 * u O DECSCPP (Select 80 or 132 Columns per Page) CSI Ps $ | - DECSCS (Select Communication Speed) CSI Ps1;Ps2 * r O DECSCUSR (Set Cursor Style) CSI Ps SP q - DECSDDT (Select Disconnect Delay Time) CSI Ps $ q - DECSDPT (Select Digital Printed Data Type) CSI Ps ) p O DECSED (Selective Erase in Display) CSI ? Ps J O DECSEL (Selective Erase in Line) CSI ? Ps K - DECSEST (Energy Saver Timing) CSI Ps - r O DECSERA (Selective Erase Rectangular Area) CSI Pt;Pl;Pb;Pr $ { - DECSFC (Select Flow Control) CSI Ps1;Ps2;Ps3;Ps4 * s - DECSIN (Set Icon Name) OSC 2 L; ST - DECSKCV (Set Key Click Volume) CSI Ps SP r - DECSLCK (Set Lock Key Style) CSI Ps SP v O DECSLPP (Set Lines Per Page) CSI Pn t O DECSLRM (Set Left and Right Margins) CSI Pl;Pr s - DECSMBV (Set Margin Bell Volume) CSI Ps SP u - DECSMKR (Select Modifier Key Reporting) CSI Pm1;Pf1;...;Pmn;Pfn + r O DECSNLS (Set Lines Per Screen) CSI Pn * | - DECSPMA (Session Page Memory Allocation) CSI Pn1;Pn2;Pn3;Pn4; ' x - DECSPP (Set Port Parameter) CSI Ps1;Ps2;Ps3;Ps4 + w - DECSPPCS (Select ProPrinter Character Set) CSI Pn * p - DECSPRTT (Select Printer Type) CSI Ps $ s O DECSR (Secure Reset) CSI Pr + p - DECSSCLS (Set Scroll Speed) CSI Ps SP p O DECSSDT (Select Status Display (LineType)) CSI Ps $ ~ - DECSSL (Select Set-Up Language) CSI Ps p O DECST8C (Set Tab at Every Columns) CSI ? 5 W O DECSTBM (Set Top and Bottom Margins) CSI Pt;Pb r O DECSTGLT (Select Color Look-Up Table) CSI Pn ) { O DECSTR (Soft Terminal Reset) CSI ! p - DECSTUI (Setting Terminal Unit ID) DCS ! { D...D ST - DECSTRL (Set Transmit Rate Limit) CSI Ps1;Ps2 " u - DECSWBV (Set Warning Bell Volume) CSI Ps SP t O DECSWL (Single-Width, Single-Height Line) ESC # 5 - DECSZS (Select Zero Symbol) CSI Ps , { - DECSWT (Set Window Title) OSC 2 1; ST O DECTCEM (Text Cursor Enable Mode) CSI ? 25 [hl] - DECTID (Select Terminal ID) CSI Ps , q - DECTME (Terminal Mode Emulation) CSI Ps SP ~ - DECTST (Invoke Confidence Test) CSI 4;Ps;...;Ps y - DECUDK (User Defined Keys) DCS Ps1;Ps2;Ps3 | D...D ST - DECUS (Update Session) CSI PS , y - DECVCCM (Vertical Cursor-Coupling Mode) CSI ? 61 [hl] - DECXRLM (Transmit Rate Limiting) CSI ? 73 [hl] O DL (Delete Line) CSI Pn M O DSR (Cursor Position Report (CPR)) CSI 6 n O DSR (Data Integrity Report) CSI ? 75 n O DSR (Extended Cursor Position Report (DECXCPR)) CSI ? 6 n O DSR (Keyboard) CSI ? 26 n O DSR (Locator) CSI ? 53 n or CSI ? 55 n O DSR (Locator Exist) CSI ? 56 n O DSR (Macro Space Report) CSI ? 62 n O DSR (Memory Checksum (DECCKSR)) CSI ? 63;Pid n DCS Pid ! ~ D...D ST O DSR (Multiple Session) CSI ? 83 n O DSR (Operating Status) CSI 5 n O DSR (Printer Port) CSI ? 15 n O DSR (User-Defined Keys (VT Level Only)) CSI ? 25 n O ECH (Erase Character) CSI Pn X O ED (Erase in Display) CSI Ps J O EL (Erase in Line) CSI Ps K O HPA (Horizontal Position Absolute) CSI Pn ` O HPR (Horizontal Position Relative) CSI Pn a O HTS (Horizontal Tab Set) ESC H O HVP (Horizontal and Vertical Position) CSI Pl;Pc f O ICH (Insert Character) CSI Pn @ O IL (Insert Line) CSI Pn L O IND (Index) ESC D O IRM (Insert/Replace Mode) CSI 4 [hl] O KAM (Keyboard Action Mode) CSI 2 [hl] O LNM (Line Feed/New Line Mode) CSI 20 [hl] O MC (Media Copy) (ANSI) CSI Pn i (DEC) CSI ? Pn i O NEL (Next Line) ESC E O NP (Next Page) CSI Pn U O PP (Preceding Page) CSI Pn V O PPA (Page Position Absolute) CSI Pn SP P O PPB (Page Position Backward) CSI Pn SP R O PPR (Page Position Relative) CSI Pn SP Q O RIS (Reset to Initial State) ESC c - S7C1T (Send CControl Character to the Host) ESC SP F - S8C1T (Send CControl Character to the Host) ESC SP G O SD (Pan Up) CSI Pn T O SGR (Select Graphic Rendition) CSI Ps;Ps;... m O SRM (Local Echo: Send/Receive Mode) CSI 12 [hl] O SU (Pan Down) CSI Pn S O TBC (Tab Clear) CSI Ps g O VPA (Vertical Line Position Absolute) CSI Pn d O VPR (Vertical Position Relative) CSI Pn e --- SCO Console Emulation - SCODFK (Define Function Key) ESC Q Fn string - SCODPCC (Display PC Characters) ESC xx (xx = hex value) O SCOSC CSI s O SCORC CSI u https://vt100.net/docs/vt510-rm/contents.html - DECSRFR (Select Refresh Rate) CSI Ps " t ftp://ftp.invisible-island.net/shuford/terminal/dec_vt_mouse.html https://www.vt100.net/docs/vt3xx-gp/contents.html O DECEFR (Enable Filter Rectangle) CSI Pt;Pl;Pb;Pr ' w O DECELR (Enable Locator Reports) CSI Pn;Ps ' z O DECREGIS DCS Pn p D...D ST O DECRQLP (Request Locator Position) CSI ' | O DECSIXEL DCS Pn1;Pn2;Pn3;Pn4 q D...D ST O DECSDM (Sixel Scrolling) CSI ? 80 [hl] O DECSLE (Select Locator Events) CSI Pn ' { https://vt100.net/docs/vt100-ug/chapter3.html O DECREQTPARM (Request Terminal Parameters) CSI Pn x https://vt100.net/emu/ctrlfunc_dec.html O DECCAHT (Clear All Horizontal Tabs) ESC 2 - DECCAVT (Clear All Vertical Tabs) ESC 4 - DECHTS (Horizontal Tab Set) ESC 1 - DECVTS (Vertical Tab Set) ESC 3 - DECSHTS (Set Horizontal Tabulation Stops) CSI Pn u - DECSVTS (Set Vertical Tabulation Stops) CSI Pn v ftp://ftp.invisible-island.net/shuford/terminal/ansi_dec_controls_news.txt O WYSTCURM (Wyse Steady Cursor Mode) CSI 33 [hl] O WYULCURM (Wyse Underline Cursor Mode) CSI 34 [hl] https://www.vt100.net/docs/vt220-rm/table4-11.html O CUP (Cursor Up) ESC A O BPH (Cursor Down) ESC B - ESA (Exit Graphics Mode) ESC G O MCP (Direct Cursor Address) ESC Y y x O NBH (Cursor Right) ESC C O V5EX (Exiting ANSI(VT52) Mode) ESC < - SCI (Identify) ESC Z - SSA (Enter Graphics Mode) ESC F O (Cursor Left) ESC D O (Cursor to Home Position) ESC H O (Reverse Line Feed) ESC I O (Erase to end of screen) ESC J O (Erase to end of line) ESC K - (Enter Alternate Keypad Mode) ESC = - (Exit Alternate Keypad Mode) ESC > - (Enter Auto Print Mode) ESC ^ - (Exit Auto Print Mode) ESC _ - (Enter Printer Contoller Mode) ESC W - (Exit Printer COntroller Mode) ESC X - (Print Screen) ESC ] - (Print cursor line) ESC V https://invisible-island.net/xterm/ctlseqs/ctlseqs.txt O XTALTSCRN (Use Alternate Screen Buffer) CSI ? 47 [hl] O XTALTS47 (Use Alternate Screen Buffer) CSI ? 1047 [hl] O XTALTS48 (Save cursor as in DECSC) CSI ? 1048 [hl] O XTEXTSCRN (Save cursor as in DECSC and use Alternate Screen Buffer) CSI ? 1049 [hl] O XTBRACKET (Set bracketed paste mode) CSI ? 2004 [hl] O XTMDKEY CSI > Pn;Ps m O XTMDKYD CSI > Pn n O XTMSEANY (Use All Motion Mouse Tracking) CSI ? 1003 [hl] O XTMSEBTN (Use Cell Motion Mouse Tracking) CSI ? 1002 [hl] O XTMSERXVT (Enable urxvt Mouse Mode) CSI ? 1015 [hl] O XTMSESGR (Enable SGR Mouse Mode) CSI ? 1006 [hl] O XTMSEUTF (Enable UTF-8 Mouse Mode) CSI ? 1005 [hl] O XTMSEWIN (Send FocusIn/FocusOut events) CSI ? 1004 [hl] O XTMSEX11 (Send Mouse X & Y on button press and release) CSI ? 1000 [hl] O (Scroll to bottom on tty output (rxvt)) CSI ? 1010 [hl] X (Scroll to bottom on key press (rxvt)) CSI ? 1011 [hl] O (Interpret "meta" key (set eighth bit of keyboard input)) CSI ? 1034 [hl] O (Send ESC when Meta modifiers a key) CSI ? 1036 [hl] O XTSMPOINTER (Set resource value pointerMode) CSI > Pn p O XTREST (Restore DEC Private Mode Values) CSI ? Pn r O XTSAVE (Save DEC Private Mode Values) CSI ? Pn s O XTSMTT (Set one or more features of the title modes) CSI > Pn t O XTRMTT (Reset one or more features of the title modes to the default value) CSI > Pn T O XTVERSION CSI > Ps q O XTWOP (Window manipulation) CSI Pn;P1;P2 t - XTSTCAP (Set Termcap/Terminfo Data) DCS + p D...D ST O XTRQCAP (Request Termcap/Terminfo String) DCS + q D...D ST - XTCOLREG CSI ? Pi;Pa;Pv S - XTMSEX10 (X10 xterm mouse protocol) CSI ? 9 [hl] - XTCBLINK (Start Blinking Cursor (att610)) CSI ? 12 [hl] O (Allow 80 -> 132 Mode) CSI ? 40 [hl] - (more(1) fix) CSI ? 41 [hl] - (Reverse-wraparound Mode) CSI ? 45 [hl] - (Use Hilite Mouse Tracking) CSI ? 1001 [hl] O (Enable Urgency window manager hint) CSI ? 1042 [hl] O (Change Icon Name and Window Title) OSC 0;Pt ST O (Change Icon Name) OSC 1;Pt ST O (Change Window Title) OSC 2;Pt ST - (Set X property on top-level window) OSC 3;Pt ST O (Change Color Number c to the color spec) OSC 4;c;spec ST O (Change Special Color Number c to the color spec) OSC 5;c;spec - (Enable/disable Special Color Number c) OSC 6;c;f OSC 106;c;f O (Change VT100 text foreground color) OSC 10;Pt ST O (Change VT100 text background color) OSC 11;Pt ST O (Change text cursor color) OSC 12;Pt ST - (Change mouse foreground color) OSC 13;Pt ST - (Change mouse background color) OSC 14;Pt ST - (Change Tektronix foreground color) OSC 15;Pt ST - (Change Tektronix background color) OSC 16;Pt ST - (Change highlight background color) OSC 17;Pt ST - (Change Tektronix cursor color) OSC 18;Pt ST - (Change highlight foreground color) OSC 19;Pt ST - (Change Log File) OSC 46;Pt ST - (Set Font) OSC 50;Pt ST O (Manipulate Selection Data) OSC 52;Pt ST O (Reset Color Number c) OSC 104;c ST O (Reset Special Color Number c) OSC 105;c ST - (Reset VT100 text foreground color) OSC 110;Pt ST - (Reset VT100 text background color) OSC 111;Pt ST - (Reset text cursor color) OSC 112;Pt ST - (Reset mouse foreground color) OSC 113;Pt ST - (Reset mouse background color) OSC 114;Pt ST - (Reset Tektronix foreground color) OSC 115;Pt ST - (Reset Tektronix background color) OSC 116;Pt ST - (Reset highlight color) OSC 117;Pt ST - (Reset Tektronix cursor color) OSC 118;Pt ST - (Reset highlight foreground color) OSC 119;Pt ST https://www.ecma-international.org/publications/standards/Ecma-048.htm O CTC (Cursor Tabulation Control) CSI Pn W - DAQ (Define Area Qualification) CSI Pn o - EA (Erase in Area) CSI Pn O - EF (Erase in Field) CSI Pn N - EPA (End of Guarded Area) ESC W - FNT (Font Selection) CSI Pn SP D O HPB (Character Position Backward) CSI Pn j O HTJ (Character Tabulation with Justification) ESC I - PLD (Partial Line Forward) ESC K - PLU (Partial Line Backward) ESC L O REP (Repeat) CSI Pn b O RI (Reverse Line Feed) ESC M O SL (Scroll Left) CSI Pn SP @ - SPA (Start of Guarded Area) ESC V O SR (Scroll Right) CSI Pn SP A O VPB (Line Position Backward) CSI Pn k - VTS (Line Tabulation Set) ESC J https://ttssh2.osdn.jp/manual/ja/about/ctrlseq.html O TTIMERS CSI < r O TTIMEST CSI < Pn t O TTIMESV CSI < s https://github.com/mintty/mintty/wiki/CtrlSeqs O (Application Escape Mode) CSI ? 7727 [hl] - CSI ? 7700/7728/7730/7766/7767/7783/7786/7787/7796/ http://nanno.dip.jp/softlib/man/rlogin/ctrlcode.html - C25LCT CSI = Pn S O RLAMBCHM CSI ? 8428 [hl] - RLBFAT CSI Pn p - RLCURCOL CSI < Pn ! q - RLIMGCP CSI < Pn ! i - RLSCD CSI Pn v O (Sixel scrolling leaves cursor to right of graphic) CSI ? 8452 [hl] - CSI ? 8400/8401/8402/8403/8405/8406/8435/8437/8440/8441/8442/8443/8448/8449/8450/8451/8453/8455/8456/8457/8458 [hl] https://www.iterm2.com/documentation-escape-codes.html O OSC 1337;Pt ST O DRCSMMv1 CSI ? 8800 [hl] O TNREPTAMB CSI ? 8840 n O OSC 20;Pt ST O OSC 5379/5380/5381/5383;Pt ST * References http://bjh21.me.uk/all-escapes/all-escapes.txt mlterm-3.9.3/doc/en/FAQ000066400000000000000000000005431441203364000145260ustar00rootroot00000000000000comment -*- mode: text; tab-width:2; indent-tabs-mode:nil -*- Frequently Asked Questions [Q1] I cannot copy&paste UTF-8 characters into the command-line. [A1] If you use bash, add the following two lines to your ~/.inputrc. set convert-meta off set output-meta on If you use tcsh, all you have to do is set dspmbyte=utf8 (Thanks to Nadim Shaikli) mlterm-3.9.3/doc/en/PLATFORMS.old000066400000000000000000000276771441203364000162640ustar00rootroot00000000000000comment -*- mode: text -*- Following platforms are not actually tested by developers, but were supported in the past and are probably supported now. * Ubuntu 15.10 / X, framebuffer (CC=gcc, CC=clang) (x86) * Ubuntu 14.10 / X, framebuffer (CC=gcc, CC=clang) (x86) * Ubuntu 14.04 / X, framebuffer (CC=gcc, CC=clang) (x86) * Ubuntu 13.10 / X, framebuffer (CC=gcc, CC=clang) (x86) * Ubuntu 10.10 (CC=gcc, CC=llvm-gcc-4.2) (x86) * Ubuntu 11.04 (CC=gcc, CC=clang) (x86) * Ubuntu 11.10 (CC=gcc, CC=clang) (x86) * Ubuntu 12.04 (CC=gcc, CC=clang) (x86) * Debian GNU/Linux Sid, GNU libc 2.3.2 (x86) * Solaris 8 (x86) * Solaris 2.6 (SunOS 5.6) (CC=cc) * Mac OS X 10.2 (ppc) * OpenBSD 3.5 (x86) * Fedora Core 2 (x86) * Fedora 25 / X, framebuffer, wayland (x86) * Fedora 24 / X, framebuffer (x86) * SuSE Linux 9.1 (x86) * Arch Linux 2013.05.01 / X (CC=gcc) (x86) * HP-UX 10.20 (CC="cc -Ae") * EWS4800 (UX/4800 R11.7) + X11R6 (CC=/usr/abiccs/bin/cc) * EWS4800 (UX/4800 R13.5, 64bit) (CC=/usr/ccs64/bin/cc) * FreeBSD 3.3R * FreeBSD 4.4R * NetBSD teokure 6.0.1 / frmebuffer (x86) * NetBSD 1.6Q current (x86) * NetBSD 1.6.2 (x86) * RedHat Linux 7.1 * Ubuntu 10.04 (x86) * MS Windows 98/Cygwin 1.5.13 with x-org 6.8.2.0-1 (x86) * MS Windows XP SP3 (x86) * MS Windows XP SP3/MSYS 1.0.10 (x86) * MS Windows XP SP3/Cygwin 1.7.1-1 (x86) * MS Windows XP SP3/Cygwin 1.7.1-1 with X (x86) * MS Windows 7/Cygwin 1.7.9 (CC=gcc, CC="gcc -mno-cygwin") (x86) * MS Windows 7/Cygwin 1.7.9 with X (x86) * MS Windows 7/Cygwin 1.7.10 (CC=gcc, CC="gcc -mno-cygwin") (x86) * MS Windows 7/Cygwin 1.7.10 with X (x86) * MS Windows 7/Cygwin 1.7.13 (CC=gcc, CC="gcc-3 -mno-cygwin") (x86) * MS Windows 7/Cygwin 1.7.13 with X (x86) * MS Windows 7 + Cygwin 1.7.17 / GDI (CC=gcc, CC="gcc-3 -mno-cygwin") (x86) * MS Windows 7 + Cygwin 1.7.17 / X (x86) * MS Windows 7 + Cygwin 1.7.22 / GDI (CC=gcc, CC="i686-pc-mingw32-gcc") (x86) * MS Windows 7 + Cygwin 1.7.22 / X (x86) * MS Windows 7 + Cygwin 1.7.26 / GDI (CC=gcc, CC="i686-pc-mingw32-gcc") (x86) * MS Windows 7 + Cygwin 1.7.26 / X (x86) * MS Windows 8 + Cygwin 2.4.1 / GDI (CC=gcc, CC="i686-pc-mingw32-gcc") (x86) * MS Windows 7 / GDI (x86) * MS Windows 7 + MSYS 1.0.10 / GDI (x86) supported platforms (mlterm-2.9.3 pre/cvs-1.922) * tested by Seiichi SATO NetBSD 2.0.2 (x86) configure options: --with-tools= Note: compilation succeeded, but I don't know whether it works or not. Solaris 9 (Sparc) configure options: --with-tools= Note: compilation succeeded, but I don't know whether it works or not. MS Windows XP/Cygwin-1.5.19 with x-org 6.8.2.0-1 (x86) configure options: --with-type-engines=xcore,xft --with-scrollbars=sample,extra --with-imagelib=gdk-pixbuf --with-tools=mlclient,mlconfig,mlterm-menu,mlcc supported platforms (mlterm-2.9.2 pre/cvs-1.865) * tested by Seiichi SATO Solaris 8 (x86), gcc-3.4.2 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc --with-scrollbars=sample,extra MS Windows NT 4.0/Cygwin-1.5.12 with x-org 6.8.1.0-3 (x86) configure options: --with-type-engines=xcore,xft --with-scrollbars=sample,extra --with-imagelib=gdk-pixbuf --with-tools=mlclient,mlconfig,mlterm-menu,mlcc Note: It seems that Cygwin/X has libXrender.la. You can get it at: OpenBSD 3.5, gcc-2.95.3 (x86) configure options: --with-tools=mlclient,mlcc --with-scrollbars=sample --with-type-engines=xcore --enable-utmp supported platforms (mlterm-2.9.2 pre/cvs-1.838) * tested by Seiichi SATO HP-UX 11.11 (PA-RISC), CC=/usr/bin/cc configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc Note: "mlterm --help" and mlcc seem to work, but I don't know whether mletrm itself works or not. supported platforms (mlterm-2.9.1 pre/cvs-1.787) * tested by MURASE, Masaki san Mac OS X 10.3.6 (PowerPC G4), Apple's cc based on gcc 3.3 20030304, gtk+-1.2.10-27, uim-0.4.5, anthy-5500 configure options: --with-type-engines=xcore --with-imagelib=imlib --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --enable-uim --enable-shared supported platforms (mlterm-2.9.1 pre/cvs-1.784) * tested by Seiichi SATO Fedora Core 2 (x86) configure options: --with-type-engines=xft,xcore --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --with-imagelib=imlib --with-scrollbars=sample,extra,pixmap_engine --enable-iiimf --enable-m17nlib supported platforms (mlterm-2.9.1 pre/cvs-1.783) * tested by Seiichi SATO HP-UX 11.11 (PA-RISC), gcc-3.4.1 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc Note: "mlterm --help" and mlcc seem to work, but I don't know whether mletrm itself works or not. supported platforms (mlterm-2.9.1 pre/cvs-1.778) * tested by Seiichi SATO MS Windows NT 4.0/Cygwin-1.5.12 with x-org 6.8.1.0-3 (x86) configure options: --with-type-engines=xft,xcore --with-scrollbars=sample,extra --with-tools=mlclient,mlconfig,mlterm-menu,mlcc Solaris 8 (x86), gcc-3.4.2 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc --with-scrollbars=sample,extra --enable-utmp Notes: - Using XIM with multiple displays is unstable on Xsun. - configure scripts could not find libiiimcf, (Solaris 8 doesn't have it?) - utmp support is unstable yet. OpenBSD 3.5, gcc-2.95.3 (x86) configure options: --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --with-scrollbars=sample,extra,pixmap_engine --with-type-engines=xcore,xft --with-imagelib=gdk-pixbuf --enable-utmp Mac OS X 10.1 Server (PowerPC G4), Apple's cc based on gcc 2.95.2, GTK+-1.2.10 configure options: --with-type-engines=xcore --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --with-scrollbars=sample,extra --with-imagelib=imlib $ chmod 755 script/* {mkf,kiklib}/script/* $ MISSING=`pwd`/script/missing install_sh=`pwd`/script/install-sh \ ./configure .. supported platforms (mlterm-2.9.0 post/cvs-1.758) * tested by Seiichi SATO Red Hat Linux 7.3 (x86), gcc-2.96 20000731, early xft without fontconfig configure options: --with-type-engines=xcore,xft --with-tools=mlclient,mlconfig supported platforms (mlterm-2.8.0 post/cvs-1.744) * tested by Seiichi SATO FreeBSD 4.10-BETA (x86), gcc-2.95.4 20020320 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc --with-scrollbars=sample,extra supported platforms (mlterm-2.8.0 post/cvs-1.740) * tested by Seiichi SATO HP-UX 11.11 (PA-RISC), gcc-3.4.1 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc Notes: compilation succeeded, but I don't know whether it works or not. HP-UX 11.11 (PA-RISC), CC="cc -Dinline=" configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc Notes: - "mlterm --help" and mlcc seem to work, but I don't know whether mletrm itself works or not. - CC="cc -Dinline= " is a quick and durty hack! gcc is recomended now. SuSE Linux 8 ES (x86_64), gcc-3.2.2, gtk+-1.2.10 configure options: --with-type-engines=xcore --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --with-scrollbars=sample,extra Solaris 8 (x86), gcc-3.4.2 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc --with-scrollbars=sample,extra Notes: - Using XIM with multiple displays is unstable on Xsun. - configure scripts could not find libiiimcf, (Solaris 8 doesn't have it?) Solaris 9 (Sparc), gcc-3.3.2 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc --with-scrollbars=sample,extra Note: compilation succeeded, but I don't know whether it works or not. Solaris 9 (x86) Sun ONE Studio 8 C compiler (CC="cc -Dinline="), gtk+-2.1.0 configure options: --with-type-engines=xcore --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --with-scrollbars=sample,extra Notes: - "mlterm --help" seems to work, but I don't know whether mletrm itself works or not. - CC="cc -Dinline= " is a quick and durty hack! gcc is recomended now. Mac OS X 10.2 Server (PowerPC G4), gcc version 3.3 20030304 configure options: --with-type-engines=xcore --with-tools=mlclient,mlcc --with-scrollbars=sample,extra supported platforms (mlterm-2.8.0 post/cvs-1.738) * tested by Seiichi SATO NetBSD 1.6.2 (x86) configure options: --with-type-engines=xcore --with-tools=mlcc Notes: compilation succeeded, but I don't know whether it works or not. Solaris 9 (Sparc) configure options: --with-type-engines=xcore --with-tools=mlcc Notes: compilation succeeded, but I don't know whether it works or not. supported platforms (mlterm-2.8.0 post/cvs-1.735) * tested by Seiichi SATO Fedora Core 2 (x86) configure options: --with-type-engines=xft,xcore --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --enable-iiimf supported platforms (mlterm-2.8.0 post/cvs-1.732) * tested by Seiichi SATO Debian GNU/Linux Sid, GNU libc 2.3.2, gcc-3.3.5 (x86) configure options: --enable-fribidi --enable-ind --with-tools=mlclient,mlconfig,mlterm-menu,mlcc,mlterm-zoom --with-scrollbars=sample,extra,pixmap_engine --with-imagelib=gdk-pixbuf2 --with-type-engines=xft,xcore --enable-optimize-redrawing --enable-uim --enable-iiimf --enable-m17nlib --enable-utmp OpenBSD 3.5, gcc-2.95.3 (x86) configure options: --with-tools=mlclient,mlconfig,mlterm-menu,mlcc --with-scrollbars=sample,extra --with-type-engines=xcore MS Windows 98/Cygwin-1.5.11 with x-org 6.8.1.0-3 (x86) configure options: --with-type-engines=xft,xcore --with-scrollbars=sample,extra --with-tools=mlclient,mlconfig,mlcc SuSE LINUX 9.1 (x86) configure options: --with-type-engines=xcore,xft --with-tools=mlclient,mlconfig --with-scrollbars=sample,extra,pixmap_engine supported platforms (mlterm-2.2.0pl1) * tested by Okazaki Tetsurou san cygwin-1.3.9-1 with Cygwin/XFree86 4.2.0 cygwin-1.3.9-1 with Cygwin/XFree86 4.1.0 supported platforms (mlterm-2.1.0) * tested by Araki Ken NetBSD 1.5Y current HP-UX 10.20 (CC="cc -Ae") ([notice] kinput2 doesn't work) supported platforms (mlterm-2.0.0) * tested by Araki Ken NetBSD 1.5Y current HP-UX 10.20 (CC="cc -Ae") * tested by Sakamoto Hironori san FreeBSD 3.3R RedHat Linux 7.1 Solaris 2.6 (SunOS 5.6) (CC=cc) HP-UX 10.20 (CC="cc -Ae") EWS4800 (UX/4800 R11.7) + X11R6 (CC=/usr/abiccs/bin/cc) EWS4800 (UX/4800 R13.5, 64bit) (CC=/usr/ccs64/bin/cc) * tested by Daichi Goto san FreeBSd 4.4R * tested by Kiyoshi Nisizawa san(1.9.47) Kondara MNU/Linux 1.2, i586 Kondara MNU/Linux 2.0, i586 * tested by Tomohiro Kubota san(1.9.47) Debian GNU/Linux Sid, GNU libc 2.2.4 mlterm-3.9.3/doc/en/PROTOCOL000066400000000000000000000273441441203364000153700ustar00rootroot00000000000000comment -*- mode: text; tab-width:2; indent-tabs-mode:nil -*- mlterm configuration protocol version 20230401 * Protocol exec = "\x1b]5379;" "\x07" set = "\x1b]5379" ( ";" ( "/dev/..." ":" ) "=" )* "\x07" get(pty) = "\x1b]5380;" ( ";") ( "/dev/..." ":" ) "\x07" get(GUI menu) = "\x1b]5381;" ( "/dev/..." ":" ) "\x07" set&save = "\x1b]5383;" ( ";" ( "/dev/..." ":" ) "=" )* "\x07" set font = "\x1b]5379;" ":" "=" "\x07" get(pty) = "\x1b]5380;" ( ";") ":" "\x07" get(GUI menu) = "\x1b]5381;" ":" "\x07" set&save = "\x1b]5383;" ";" ":" "=" "\x07" set color = "\x1b]5379;color:" "=" "\x07" get(pty) = "\x1b]5380;" ( ";color:") "\x07" get(GUI menu) = "\x1b]5381;color:" "\x07" set&save = "\x1b]5383;" ";color:" "=" "\x07" return value = "#" "=" "\x0a" | "#error\x0a" | "#forbidden\x0a" exec command = autoscroll | close_pty () | close_screen | full_reset | gen_proto_challenge | hresize_screen (+|-||%) | hsplit_screen (|%) | mlclient "" "" | mlclientx "" "" | mlconfig | next_pty | next_screen | open_pty | open_screen | paste (clipboard) (*) | prev_pty | prev_screen | scp "(local:|remote:)" "(local:|remote:)" "()" | search_next | search_prev | select_pty | set_shortcut = (*) | snapshot ("") ("") | update_all | vresize_screen (+|-||%) | vsplit_screen (|%) | zmodem_start set key = alpha | allow_osc52 (*) | allow_scp (*) | auto_detect_encodings | auto_restart | baseline_offset | bd_color | bel_mode | bg_color | bidi_mode | bidi_separators | bl_color | borderless | box_drawing_font | brightness | click_interval | co_color | col_size_of_width_a | console_encoding | console_sixel_colors | contrast | cursor_bg_color | cursor_fg_color | emoji_path | encoding | exit_backscroll_by_pty | fade_ratio | fg_color | fontsize | format_other_keys | gamma | geometry | hide_underline | icon_path | input_method | it_color | letter_space | line_space | local_echo_wait | locale | logging_msg | logging_vt_seq | logsize | mod_meta_key | mod_meta_mode | not_use_unicode_font | only_use_unicode_font | ot_features | ot_script | receive_string_via_ucs | regard_uri_as_word | rv_color | sb_bg_color | sb_fg_color | screen_width_ratio | scrollbar_mode | scrollbar_view_name | send_file static_backscroll_mode | tabsize | trim_trailing_newline_in_pasting | type_engine | ul_color | underline_offset | unicode_full_width_areas | unicode_half_width_areas | unicode_noconv_areas | use_alt_buffer | use_ansi_colors | use_anti_alias | use_auto_detect | use_bold_font | use_clipboard | use_combining | use_ctl | use_dynamic_comb | use_italic_font | use_local_echo | use_multi_column_char | use_ot_layout | use_transbg | use_urgent_bell | use_variable_column_width | use_vertical_cursor | vertical_mode | vt_color_mode | vt_seq_format | wall_picture | word_separators get key = alpha | allow_osc52 | allow_scp | auto_detect_encodings | baseline_offset | bd_color | bel_mode | bg_color | bidi_mode | bidi_separators | bl_color | borderless | box_drawing_font | brightness | click_interval | co_color | col_size_of_width_a | cols | contrast | cursor_bg_color | cursor_fg_color | depth | emoji_path | encoding | fade_ratio | fg_color | fontconfig | fontsize | format_other_keys | gamma | gui | hide_underline | icon_path | input_method | is_auto_encoding | it_color | letter_space | line_space | local_echo_wait | locale | logging_vt_seq | logsize | mod_meta_key | mod_meta_mode | not_use_unicode_font | only_use_unicode_font | ot_features | ot_script | pty_list | pty_name | pwd | receive_directory | receive_string_via_ucs | regard_uri_as_word | rows | rv_color | sb_bg_color | sb_fg_color | screen_width_ratio | scrollbar_mode | scrollbar_view_name | send_file | static_backscroll_mode | tabsize | trim_trailing_newline_in_pasting | type_engine | ul_color | underline_offset | unicode_full_width_areas | unicode_half_width_areas | unicode_noconv_areas | use_aafont | use_alt_buffer | use_ansi_colors | use_anti_alias | use_auto_detect | use_bold_font | use_clipboard | use_combining | use_ctl | use_dynamic_comb | use_italic_font | use_local_echo | use_multi_column_char | use_ot_layout | use_transbg | use_variable_column_width | use_vertical_cursor | vertical_mode | vt_seq_format | wall_picture | word_separators (*): Works as "proto:xxxx" shortcut in ~/.mlterm/key alone. value = challenge = font filename = font | aafont | vfont | tfont | vaafont | taafont font key = see man/mlterm.1 or "USASCII" font value = see man/mlterm.1 fontsize = color key = see man/mlterm.1 color value = see man/mlterm.1 * Values for each key alpha = allow_osc52 = true | false | switch allow_scp = true | false | switch auto_restart = true | false | switch | auto_detect_encodings = (,)* baseline_offset = bidi_mode = normal | left | right | switch bidi_separators = * bd_color = | bl_color = | bel_mode = none | sound | visual bg_color = | box_drawing_font = unicode | decsp | noconv brightness = click_interval = cols = col_size_of_width_a = 1 | 2 | switch contrast = co_colors = | console_encoding = | auto console_sixel_colors = 16 | 256 | full cursor_bg_color = | cursor_fg_color = | depth = 8 | 16 | 24 | 32 (xlib only) emoji_path = | encoding = | auto fade_ratio = fg_color = | format_other_keys = true | false fontsize = | larger | smaller gamma = hide_underline = true | false | switch icon_path = input_method = ":" ... it_color = | line_space = locale = local_echo_wait = logsize = mod_meta_key = none | mod1 | mod2 | mod3 | mod4 | meta | alt | super | hyper mod_meta_mode = none | esc | 8bit not_use_unicode_font = true | false | switch only_use_unicode_font = true | false | switch ot_script =