summaryrefslogtreecommitdiffstats
path: root/lib/libUPnP/Platinum/Build/Tools/Scripts/MakeAllVs.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libUPnP/Platinum/Build/Tools/Scripts/MakeAllVs.py')
-rw-r--r--lib/libUPnP/Platinum/Build/Tools/Scripts/MakeAllVs.py37
1 files changed, 37 insertions, 0 deletions
diff --git a/lib/libUPnP/Platinum/Build/Tools/Scripts/MakeAllVs.py b/lib/libUPnP/Platinum/Build/Tools/Scripts/MakeAllVs.py
new file mode 100644
index 0000000..32f1bd0
--- /dev/null
+++ b/lib/libUPnP/Platinum/Build/Tools/Scripts/MakeAllVs.py
@@ -0,0 +1,37 @@
+#! /usr/bin/env python
+
+import os
+import sys
+import getopt
+import subprocess
+
+
+configs = ['Debug', 'Release']
+solutions = ['../../../Build/Targets/x86-microsoft-win32-vs2008/Platinum.sln']
+
+try:
+ opts, args = getopt.getopt(sys.argv[1:], "b:rc")
+except getopt.GetoptError, (msg, opt):
+ print 'No build_config, defaulting to build all'
+
+for opt, arg in opts:
+ if opt == '-b':
+ config = arg
+
+
+def CallVsMake(sln, cfg):
+ cmd = 'python VsMake.py -s %s -b %s' % (sln, cfg)
+ print cmd
+ retVal = subprocess.call(cmd.split())
+ if retVal != 0:
+ sys.exit(retVal)
+
+for sln in solutions:
+ if 'config' not in locals() and 'config' not in globals():
+ print '************ Building all configurations **************'
+ for cfg in configs:
+ CallVsMake(sln, cfg)
+ else:
+ print '************ Building configuration=' + config + ' ****************'
+ CallVsMake(sln, config)
+ \ No newline at end of file