diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2017-11-26 13:00:48 +0000 |
---|---|---|
committer | Jonathan Yong <jyong@gcc.gnu.org> | 2017-11-26 13:00:48 +0000 |
commit | 8c7dbea9f193ae21d193453d7a9eb6d2089618d6 (patch) | |
tree | c02088e446e880dcebb2359db9e0c6d8c5681dd2 /config | |
parent | 44dfb822801cb19dd842c5eaa2bbfa3b64b375f7 (diff) | |
download | gcc-8c7dbea9f193ae21d193453d7a9eb6d2089618d6.zip gcc-8c7dbea9f193ae21d193453d7a9eb6d2089618d6.tar.gz gcc-8c7dbea9f193ae21d193453d7a9eb6d2089618d6.tar.bz2 |
Plugin support on Windows/MinGW
config/ChangeLog:
2017-11-14 Boris Kolpackov <boris@codesynthesis.com>
* gcc-plugin.m4: Add support for MinGW.
gcc/ChangeLog:
2017-11-14 Boris Kolpackov <boris@codesynthesis.com>
* plugin.c (add_new_plugin): Use platform-specific library extensions.
(try_init_one_plugin): Alternative implementation for MinGW.
* Makefile.in (plugin_implib): New.
(gengtype-lex.c): Fix broken AIX workaround.
* configure: Regenerate.
* doc/plugins.texi: Document support for MinGW.
gcc/c/ChangeLog:
2017-11-14 Boris Kolpackov <boris@codesynthesis.com>
* Make-lang.in (c.install-plugin): Install backend import library.
gcc/cp/ChangeLog:
2017-11-14 Boris Kolpackov <boris@codesynthesis.com>
* Make-lang.in (c++.install-plugin): Install backend import library.
libcc1/ChangeLog:
2017-11-14 Boris Kolpackov <boris@codesynthesis.com>
* configure: Regenerate.
From-SVN: r255154
Diffstat (limited to 'config')
-rw-r--r-- | config/ChangeLog | 4 | ||||
-rw-r--r-- | config/gcc-plugin.m4 | 15 |
2 files changed, 18 insertions, 1 deletions
diff --git a/config/ChangeLog b/config/ChangeLog index 2bb5244..a44722e 100644 --- a/config/ChangeLog +++ b/config/ChangeLog @@ -1,3 +1,7 @@ +2017-11-14 Boris Kolpackov <boris@codesynthesis.com> + + * gcc-plugin.m4: Add support for MinGW. + 2017-11-17 Igor Tsimbalist <igor.v.tsimbalist@intel.com> * cet.m4: New file. diff --git a/config/gcc-plugin.m4 b/config/gcc-plugin.m4 index dd06a58..38b2ae6 100644 --- a/config/gcc-plugin.m4 +++ b/config/gcc-plugin.m4 @@ -19,8 +19,21 @@ AC_DEFUN([GCC_ENABLE_PLUGINS], enable_plugin=yes; default_plugin=yes) pluginlibs= + plugin_check=yes case "${host}" in + *-*-mingw*) + # Since plugin support under MinGW is not as straightforward as on + # other platforms (e.g., we have to link import library, etc), we + # only enable it if explicitly requested. + if test x"$default_plugin" = x"yes"; then + enable_plugin=no + elif test x"$enable_plugin" = x"yes"; then + # Use make's target variable to derive import library name. + pluginlibs='-Wl,--export-all-symbols -Wl,--out-implib=[$]@.a' + plugin_check=no + fi + ;; *-*-darwin*) if test x$build = x$host; then export_sym_check="nm${exeext} -g" @@ -41,7 +54,7 @@ AC_DEFUN([GCC_ENABLE_PLUGINS], ;; esac - if test x"$enable_plugin" = x"yes"; then + if test x"$enable_plugin" = x"yes" -a x"$plugin_check" = x"yes"; then AC_MSG_CHECKING([for exported symbols]) if test "x$export_sym_check" != x; then |