[gtk+] build: Use the appropriate symbol visibility annotation
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] build: Use the appropriate symbol visibility annotation
- Date: Tue, 22 Aug 2017 09:33:46 +0000 (UTC)
commit e3f99fa2df0ef52f3624159e19d2828552a8a1c5
Author: Emmanuele Bassi <ebassi gnome org>
Date: Tue Aug 22 10:27:14 2017 +0100
build: Use the appropriate symbol visibility annotation
We cargo-culted this from Autotools, but GCC on Windows supports the
same __declspec syntax as MSVC. The only difference is the additional
flag needed for GCC-like compilers.
meson.build | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/meson.build b/meson.build
index 158e5c8..52a0807 100644
--- a/meson.build
+++ b/meson.build
@@ -279,10 +279,8 @@ endforeach
if get_option('default_library') != 'static'
if host_machine.system() == 'windows'
cdata.set('DLL_EXPORT', true)
- if cc.get_id() == 'msvc'
- cdata.set('_GDK_EXTERN', '__declspec(dllexport) extern')
- else
- cdata.set('_GDK_EXTERN', '__attribute__((visibility("default"))) __declspec(dllexport) extern')
+ cdata.set('_GDK_EXTERN', '__declspec(dllexport) extern')
+ if cc.get_id() != 'msvc'
common_cflags += ['-fvisibility=hidden']
endif
else
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]