[gedit/zbrown/deteplification-src: 95/633] build: avoid the use of dir variables




commit d449eec75f385a6ce945e72b7667c8ddef31fa42
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Fri Dec 6 08:38:57 2019 +0100

    build: avoid the use of dir variables
    
    All those *dir variables make the code a bit less clear in my opinion.
    We need to look where the variable is assigned for the last time. All
    variables in meson are global, and they are not const, so another
    meson.build file can overwrite the value by accident.
    
    When reading "get_option('prefix')" etc, everybody who has learned meson
    is able to understand the code without looking elsewhere in the build
    system. And it's short enough.

 meson.build | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/meson.build b/meson.build
index 5d7780204..923b44b12 100644
--- a/meson.build
+++ b/meson.build
@@ -158,7 +158,8 @@ endif
 
 meson.add_install_script(
   'build-aux/meson/post_install.py',
-  libdir, datadir,
+  join_paths(get_option('prefix'), get_option('libdir')),
+  join_paths(get_option('prefix'), get_option('datadir'))
 )
 
 # Summary message


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