Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2011-06-13 07:09:14 +0400
committerCampbell Barton <ideasman42@gmail.com>2011-06-13 07:09:14 +0400
commitfedc811014196c5d7b30a6f4367bbdba429da135 (patch)
tree149a674d563643e78339b9a240658062fa9b9a99 /build_files/cmake/cmake_consistency_check.py
parentef1824cdcb9d78dd22316d48fd2d9c8bb6f41fa3 (diff)
minor updates to the cmake checker
Diffstat (limited to 'build_files/cmake/cmake_consistency_check.py')
-rwxr-xr-xbuild_files/cmake/cmake_consistency_check.py25
1 files changed, 14 insertions, 11 deletions
diff --git a/build_files/cmake/cmake_consistency_check.py b/build_files/cmake/cmake_consistency_check.py
index f55b2e95d5e..8dbfadb1187 100755
--- a/build_files/cmake/cmake_consistency_check.py
+++ b/build_files/cmake/cmake_consistency_check.py
@@ -23,15 +23,16 @@
# <pep8 compliant>
-IGNORE = \
- "/test/",\
- "/decimate_glut_test/",\
- "/BSP_GhostTest/",\
- "/release/",\
- "/xembed/",\
- "/decimation/intern/future/",\
- "/TerraplayNetwork/",\
- "/ik_glut_test/"
+IGNORE = (
+ "/test/",
+ "/decimate_glut_test/",
+ "/BSP_GhostTest/",
+ "/release/",
+ "/xembed/",
+ "/decimation/intern/future/",
+ "/TerraplayNetwork/",
+ "/ik_glut_test/",
+ )
import os
from os.path import join, dirname, normpath, abspath, splitext
@@ -104,7 +105,7 @@ def cmake_get_src(f):
found = True
break
- if "list(APPEND SRC" in l:
+ if "list(APPEND SRC" in l or ('list(APPEND ' in l and l.endswith("SRC")):
if l.endswith(")"):
raise Exception("strict formatting not kept 'list(APPEND SRC...)' on 1 line %s:%d" % (f, i))
found = True
@@ -136,7 +137,9 @@ def cmake_get_src(f):
if not l:
pass
elif l.startswith("$"):
- print("Cant use var '%s' %s:%d" % (l, f, i))
+ # assume if it ends with SRC we know about it
+ if not l.split("}")[0].endswith("SRC"):
+ print("Can't use var '%s' %s:%d" % (l, f, i))
elif len(l.split()) > 1:
raise Exception("Multi-line define '%s' %s:%d" % (l, f, i))
else: