build: only find env once
authorMarcel Hollerbach <mail@marcel-hollerbach.de>
Wed, 2 Sep 2020 07:25:51 +0000 (09:25 +0200)
committerJongmin Lee <jm105.lee@samsung.com>
Wed, 2 Sep 2020 22:03:41 +0000 (07:03 +0900)
this was a bit messy, and we might have caused a bug on the ML with
that.

meson.build
src/bin/edje/meson.build
src/bin/elementary/meson.build

index 2fe9e84..f717d10 100644 (file)
@@ -126,6 +126,8 @@ if sys_sun
   add_global_arguments('-D_POSIX_PTHREAD_SEMANTICS', language: 'c')
 endif
 
+env = find_program('env', native: true)
+
 config_h = configuration_data()
 config_h.set_quoted('MODULE_ARCH', version_name)
 config_h.set_quoted('PACKAGE', meson.project_name())
index d795512..191e4d1 100644 (file)
@@ -46,7 +46,6 @@ else
   if sys_windows == true
     edje_cc_exe = [edje_cc.full_path()]
   else
-    env = find_program('env', native: true)
     edje_cc_exe = [env, asan_option, 'EFL_RUN_IN_TREE=1', edje_cc.full_path()]
   endif
   edje_depends = [edje_cc, epp, evas_engine_buffer_mod, embryo_cc]
@@ -104,7 +103,6 @@ if meson.is_cross_build()
   edje_codegen_path = _edje_codegen.path()
   edje_codegen_exe = [_edje_codegen]
 else
-  env = find_program('env', native: true)
   edje_codegen_exe = [env, asan_option, 'EFL_RUN_IN_TREE=1', edje_codegen.full_path()]
 endif
 
index f31ed79..1d7aa75 100644 (file)
@@ -234,7 +234,6 @@ endif
 if meson.is_cross_build()
   elementary_codegen_exe = [find_program('elementary_codegen', native: true)]
 else
-  env = find_program('env', native: true)
   elementary_codegen_exe = [env, asan_option, 'EFL_RUN_IN_TREE=1', elementary_codegen.full_path()]
 endif
 
@@ -260,7 +259,6 @@ if meson.is_cross_build()
   elm_prefs_cc_path = _elm_prefs_cc.path()
   elm_prefs_cc_exe = [_elm_prefs_cc]
 else
-  env = find_program('env', native: true)
   elm_prefs_cc_exe = [env, asan_option, 'EFL_RUN_IN_TREE=1', elm_prefs_cc.full_path()]
 endif