[gnome-builder/wip/lantw/build-dont-use-undocumented-export-dynamic-option: 3/3] build: don't use undocumented -export-dynamic option



commit e47932c64489d8b92af8159d63fc46cfb63c506b
Author: Ting-Wei Lan <lantw src gnome org>
Date:   Sat Sep 7 14:50:33 2019 +0800

    build: don't use undocumented -export-dynamic option
    
    GNU libtool is documented to support -export-dynamic and GNU ld is
    documented to support --export-dynamic. However, GCC isn't documented
    to support them. While GCC does support -export-dynamic for backwards
    compatibility, Clang doesn't support it and interprets it wrongly. This
    causes warnings to be shown during linking because Clang splits it into
    '-e xport-dynamic' and the linker can't find 'xport-dynamic' symbol.

 src/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/meson.build b/src/meson.build
index bc7f91841..3eb9ba535 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -13,7 +13,7 @@ gnome_builder_gir_extra_args = ['--pkg-export=gnome-builder-1.0']
 # inside the final executable, we delay compiling them until the
 # final binary (otherwise they are silenty dropped when linking).
 
-exe_link_args = [ '-export-dynamic' ]
+exe_link_args = [ '-Wl,--export-dynamic' ]
 exe_c_args = []
 
 subdir('gstyle')


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]