[gimp/wip/sgrinkov/6257-meson-race-rc-win-build: 4/6] build: meson.build minor code refactoring




commit 9491f5a1aecf7b44f45ed78aa9a9fd0885ab74a5
Author: Stanislav Grinkov <43956-stanislavgrinkov users noreply gitlab gnome org>
Date:   Wed Sep 29 00:16:09 2021 +0600

    build: meson.build minor code refactoring

 meson.build | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/meson.build b/meson.build
index 626e67b46c..22c167a14e 100644
--- a/meson.build
+++ b/meson.build
@@ -15,11 +15,6 @@ conf = configuration_data()
 
 warnings = []
 
-# git-version.h is already present and not generated if dist tarball
-is_git_repository = run_command('python3', '-c',
-  'import sys,os; sys.exit(0 if os.path.exists(".git") else 1)'
-).returncode() == 0
-
 ################################################################################
 # Project info
 
@@ -1446,9 +1441,15 @@ endif
   #####   ####  #    # #      #  ####     #       # ###### ######  ####
 
 
+# git-version.h is already present and not generated if dist tarball
+is_git_repository = run_command('python3', '-c',
+  'import sys,os; sys.exit(0 if os.path.exists(".git") else 1)'
+).returncode() == 0
+
 has_version_h = run_command('python3', '-c',
   'import sys,os; sys.exit(0 if os.path.exists("git-version.h") else 1)'
 ).returncode() == 0
+
 if is_git_repository or not has_version_h
   gitversion_h1 = vcs_tag(
     input : 'app/git-version.h.in',


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