diff options
author | Chun-wei Fan <fanchunwei@src.gnome.org> | 2020-03-09 12:32:17 +0800 |
---|---|---|
committer | Chun-wei Fan <fanchunwei@src.gnome.org> | 2020-03-09 12:32:17 +0800 |
commit | 78868229b404a1cf52a7bebd57dab59a4a85f5a3 (patch) | |
tree | 8e84ef76062471887d6695836480f8d855d44984 /glib/meson.build | |
parent | 1f006eef387a519abfff9392dd158332fbac390d (diff) | |
download | glibmm-78868229b404a1cf52a7bebd57dab59a4a85f5a3.tar.gz |
meson: Do not allow static MSVC-style builds
The Visual Studio build files never really supported static builds, so
disallow that for now, until we can make sure that is tested better.
Diffstat (limited to 'glib/meson.build')
-rw-r--r-- | glib/meson.build | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/glib/meson.build b/glib/meson.build index bf9141c7..7b810d3a 100644 --- a/glib/meson.build +++ b/glib/meson.build @@ -32,7 +32,16 @@ pkg_conf_data.set('GLIBMM_MICRO_VERSION', glibmm_micro_version) pkg_conf_data.set('GIOMM_MAJOR_VERSION', glibmm_major_version) pkg_conf_data.set('GIOMM_MINOR_VERSION', glibmm_minor_version) pkg_conf_data.set('GIOMM_MICRO_VERSION', glibmm_micro_version) -if get_option('default_library') == 'static' + +library_build_type = get_option('default_library') + +if cpp_compiler.get_argument_syntax() == 'msvc' + if library_build_type == 'static' or library_build_type == 'both' + error('Static builds are not supported by MSVC-style builds') + endif +endif + +if library_build_type == 'static' pkg_conf_data.set('GLIBMM_STATIC_LIB', 1) pkg_conf_data.set('GIOMM_STATIC_LIB', 1) endif |