summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--SConstruct17
1 files changed, 16 insertions, 1 deletions
diff --git a/SConstruct b/SConstruct
index b860995f06b..8499f0b7cb3 100644
--- a/SConstruct
+++ b/SConstruct
@@ -843,6 +843,8 @@ def concatjs(target, source, env):
fullSource = ""
+ first = True
+
for s in source:
f = open( str(s) , 'r' )
for l in f:
@@ -850,8 +852,21 @@ def concatjs(target, source, env):
if len ( l ) == 0:
continue
- fullSource += l + "\n"
+ if l == "}":
+ fullSource += "}"
+ continue
+
+ if first:
+ first = False
+ else:
+ fullSource += "\n"
+
+ fullSource += l
+
+ fullSource += "\n"
+ fullSource = re.compile( r'/\*\*.*?\*/' , re.M | re.S ).sub( "" , fullSource )
+
out = open( outFile , 'w' )
out.write( fullSource )