Changeset 2405
- Timestamp:
- Jan 1, 2009 12:11:17 AM (16 years ago)
- Location:
- pjproject/trunk
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/build.symbian/00.bat
r1405 r2405 4 4 @rem set EPOCROOT=\Symbian\UIQ3SDK\ 5 5 @rem set EPOCROOT=\symbian\UIQ3.1\ 6 @rem set EPOCROOT=\symbian\9.2\S60_3rd_FP1\ 6 7 bldmake bldfiles -
pjproject/trunk/tests/cdash/builder.py
r2404 r2405 336 336 class MSVCTestBuilder(TestBuilder): 337 337 """\ 338 This class creates list of tests suitable for Visual Studio builds. 339 338 This class creates list of tests suitable for Visual Studio builds. 339 You need to set the MSVC environment variables (typically by calling 340 vcvars32.bat) prior to running this class. 341 340 342 """ 341 def __init__(self, config, vs_config="Release|Win32", build_config_name="",343 def __init__(self, config, target="Release|Win32", build_config_name="", 342 344 config_site="", exclude=[], not_exclude=[]): 343 345 """\ 344 346 Parameters: 345 347 config - BaseConfig instance 346 vs_config- Visual Studio build configuration to build.348 target - Visual Studio build configuration to build. 347 349 Sample: "Debug|Win32", "Release|Win32". 348 350 build_config_name - Optional name to be added as suffix to the build … … 359 361 config_site=config_site, exclude=exclude, 360 362 not_exclude=not_exclude) 361 self. vs_config = vs_config.lower()363 self.target = target.lower() 362 364 363 365 def build_tests(self): 364 366 365 (vsbuild,sys) = self. vs_config.split("|",2)367 (vsbuild,sys) = self.target.split("|",2) 366 368 367 369 build_name = sys + "-" + vs_get_version() + "-" + vsbuild … … 371 373 372 374 vccmd = "vcbuild.exe /nologo /nohtmllog /nocolor /rebuild " + \ 373 "pjproject-vs8.sln " + " \"" + self. vs_config+ "\""375 "pjproject-vs8.sln " + " \"" + self.target + "\"" 374 376 375 377 suffix = "-i386-win32-vc8-" + vsbuild … … 397 399 398 400 401 # 402 # Symbian test configurator 403 # 404 class SymbianTestBuilder(TestBuilder): 405 """\ 406 This class creates list of tests suitable for Symbian builds. You need to 407 set the command line build settings prior to running this class (typically 408 that involves setting the EPOCROOT variable and current device). 409 410 """ 411 def __init__(self, config, target="gcce urel", build_config_name="", 412 config_site="", exclude=[], not_exclude=[]): 413 """\ 414 Parameters: 415 config - BaseConfig instance 416 target - Symbian target to build. Default is "gcce urel". 417 build_config_name - Optional name to be added as suffix to the build 418 name. Sample: "APS", "VAS", etc. 419 config_site - Contents to be put on config_site.h 420 exclude - List of regular expression patterns for tests 421 that will be excluded from the run 422 not_exclude - List of regular expression patterns for tests 423 that will be run regardless of whether they 424 match the excluded pattern. 425 426 """ 427 TestBuilder.__init__(self, config, build_config_name=build_config_name, 428 config_site=config_site, exclude=exclude, 429 not_exclude=not_exclude) 430 self.target = target.lower() 431 432 def build_tests(self): 433 434 # Check that EPOCROOT is set 435 if not "EPOCROOT" in os.environ: 436 print "Error: EPOCROOT environment variable is not set" 437 sys.exit(1) 438 epocroot = os.environ["EPOCROOT"] 439 # EPOCROOT must have trailing backslash 440 if epocroot[-1] != "\\": 441 epocroot = epocroot + "\\" 442 os.environ["EPOCROOT"] = epocroot 443 sdk1 = epocroot.split("\\")[-2] 444 445 # Check that correct device is set 446 proc = subprocess.Popen("devices", stdout=subprocess.PIPE, 447 stderr=subprocess.STDOUT, shell=True) 448 sdk2 = "" 449 while True: 450 line = proc.stdout.readline() 451 if line.find("- default") > 0: 452 sdk2 = line.split(":",1)[0] 453 break 454 proc.wait() 455 456 if sdk1 != sdk2: 457 print "Error: default SDK in device doesn't match EPOCROOT" 458 print "Default device SDK =", sdk2 459 print "EPOCROOT SDK =", sdk1 460 sys.exit(1) 461 462 build_name = sdk2.replace("_", "-") + "-" + \ 463 self.target.replace(" ", "-") 464 465 if self.build_config_name: 466 build_name = build_name + "-" + self.build_config_name 467 468 cmdline = "cmd /C \"cd build.symbian && bldmake bldfiles && abld build %s\"" % (self.target) 469 470 cmds = [] 471 cmds.extend(update_ops) 472 cmds.extend([Operation(Operation.BUILD, cmdline)]) 473 474 self.ccdash_args = [] 475 suffix = "" 476 for c in cmds: 477 c.cmdline = c.cmdline.replace("$SUFFIX", suffix) 478 args = c.encode(self.config.base_dir) 479 args.extend(["-U", self.config.url, 480 "-S", self.config.site, 481 "-T", self.stamp(), 482 "-B", build_name, 483 "-G", self.config.group]) 484 args.extend(self.config.options) 485 self.ccdash_args.append(args) 486 -
pjproject/trunk/tests/cdash/cfg_gnu.py
r2401 r2405 24 24 # Each configurator must export this function 25 25 def create_builder(args): 26 usage = """\ 27 Usage: 28 main.py cfg_gnu [-h|--help] [cfg_site] 29 30 Arguments: 31 cfg_site: site configuration module. If not specified, "cfg_site" 32 is implied 33 -h, --help Show this help screen 34 35 """ 26 36 # (optional) args format: 27 37 # site configuration module. If not specified, "cfg_site" is implied 28 38 29 if len(args)>0: 30 file = args[0] 31 else: 32 file = "cfg_site" 33 34 if os.access(file+".py", os.F_OK) == False: 35 print "Error: file '%s.py' doesn't exist." % (file) 39 cfg_site = "cfg_site" 40 41 for arg in args: 42 if arg=="-h" or arg=="--help": 43 print usage 44 sys.exit(0) 45 elif arg[0]=="-": 46 print usage 47 sys.exit(1) 48 else: 49 cfg_site = arg 50 51 if os.access(cfg_site+".py", os.F_OK) == False: 52 print "Error: file '%s.py' doesn't exist." % (cfg_site) 36 53 sys.exit(1) 37 54 38 cfg_site = __import__( file)55 cfg_site = __import__(cfg_site) 39 56 test_cfg = builder.BaseConfig(cfg_site.BASE_DIR, \ 40 57 cfg_site.URL, \ -
pjproject/trunk/tests/cdash/cfg_msvc.py
r2404 r2405 24 24 # Each configurator must export this function 25 25 def create_builder(args): 26 # (optional) args format: 27 # [cfg_site] [--vs-config VSCFG] 28 # 29 # cfg_site: site configuration module. If not specified, "cfg_site" 30 # is implied 31 # VSCFG: Visual Studio build configuration to build. Sample values: 32 # "Debug|Win32", "Release|Win32". If not specified then 33 # "Release|Win32" is assumed 26 usage = """\ 27 Usage: 28 main.py cfg_msvc [-h|--help] [-t|--target TARGET] [cfg_site] 29 30 Arguments: 31 cfg_site: site configuration module. If not specified, "cfg_site" 32 is implied 33 -t,--target TARGET: Visual Studio build configuration to build. Default is 34 "Release|Win32". Sample values: "Debug|Win32" 35 -h, --help Show this help screen 36 37 """ 34 38 35 39 cfg_site = "cfg_site" 36 vs_cfg= "Release|Win32"40 target = "Release|Win32" 37 41 in_option = "" 38 42 39 43 for arg in args: 40 if in_option=="- -vs-config":41 vs_cfg= arg44 if in_option=="-t": 45 target = arg 42 46 in_option = "" 43 elif arg=="--vs-config": 44 in_option = arg 47 elif arg=="--target" or arg=="-t": 48 in_option = "-t" 49 elif arg=="-h" or arg=="--help": 50 print usage 51 sys.exit(0) 52 elif arg[0]=="-": 53 print usage 54 sys.exit(1) 45 55 else: 46 56 cfg_site = arg … … 59 69 builders = [ 60 70 builder.MSVCTestBuilder(test_cfg, 61 vs_config=vs_cfg,71 target=target, 62 72 build_config_name="default", 63 73 config_site="#define PJ_TODO(x)\n",
Note: See TracChangeset
for help on using the changeset viewer.