[gnome-builder] build: use pie:true instead of manual link args



commit c7a10402371f05e25214f522c87ca67f1a948049
Author: Christian Hergert <chergert redhat com>
Date:   Mon Mar 25 18:06:56 2019 -0700

    build: use pie:true instead of manual link args
    
    Now that we can depend on 0.50 meson, we can fix warnings about
    using -fpie and -fPIE manually.

 src/meson.build               | 7 ++++---
 src/plugins/clang/meson.build | 4 ++--
 2 files changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/src/meson.build b/src/meson.build
index 0e7044eb4..014ee081e 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -13,8 +13,8 @@ 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 = [ '-pie', '-export-dynamic' ]
-exe_c_args = [ '-fPIE' ]
+exe_link_args = [ '-export-dynamic' ]
+exe_c_args = []
 
 subdir('gstyle')
 subdir('libide')
@@ -55,7 +55,7 @@ if get_option('fusermount_wrapper')
              install: true,
          install_dir: get_option('bindir'),
               c_args: exe_c_args + release_args,
-           link_args: exe_link_args,
+                 pie: true,
        install_rpath: pkglibdir_abs,
         dependencies: [libglib_dep],
   )
@@ -72,6 +72,7 @@ gnome_builder = executable('gnome-builder', 'main.c', 'bug-buddy.c',
            install: true,
             c_args: libide_args + exe_c_args + release_args,
          link_args: exe_link_args,
+               pie: true,
         link_whole: plugins,
      install_rpath: pkglibdir_abs,
       dependencies: gnome_builder_deps,
diff --git a/src/plugins/clang/meson.build b/src/plugins/clang/meson.build
index 3a7b87f0b..12a2366d3 100644
--- a/src/plugins/clang/meson.build
+++ b/src/plugins/clang/meson.build
@@ -76,7 +76,7 @@ executable('gnome-builder-clang', gnome_builder_clang_sources,
            install: true,
        install_dir: get_option('libexecdir'),
             c_args: exe_c_args,
-         link_args: exe_link_args,
+               pie: true,
      install_rpath: pkglibdir_abs,
 )
 
@@ -85,7 +85,7 @@ executable('test-daemon', ['test-daemon.c'],
            gui_app: false,
            install: false,
             c_args: exe_c_args,
-         link_args: exe_link_args,
+               pie: true,
 )
 
 install_data(['org.gnome.builder.clang.gschema.xml'], install_dir: schema_dir)


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