equal
deleted
inserted
replaced
39 my $sDiamondsTag = ''; |
39 my $sDiamondsTag = ''; |
40 my $bHudson = 0; |
40 my $bHudson = 0; |
41 my $bPublish = 1; |
41 my $bPublish = 1; |
42 my %hHlmDefines = (); |
42 my %hHlmDefines = (); |
43 my $bDisableAntiVirus = 0; |
43 my $bDisableAntiVirus = 0; |
|
44 my $sUseBom = ''; |
44 my $bHelp = 0; |
45 my $bHelp = 0; |
45 GetOptions(( |
46 GetOptions(( |
46 'configrepo=s' => \$sFbfConfigRepo, |
47 'configrepo=s' => \$sFbfConfigRepo, |
47 'configdir=s' => \$sFbfConfigDir, |
48 'configdir=s' => \$sFbfConfigDir, |
48 'projectrepo=s' => \$sFbfProjectRepo, |
49 'projectrepo=s' => \$sFbfProjectRepo, |
56 'tag=s' => \$sDiamondsTag, |
57 'tag=s' => \$sDiamondsTag, |
57 'hudson!' => \$bHudson, |
58 'hudson!' => \$bHudson, |
58 'publish!' => \$bPublish, |
59 'publish!' => \$bPublish, |
59 'define=s' => \%hHlmDefines, |
60 'define=s' => \%hHlmDefines, |
60 'disableav!' => \$bDisableAntiVirus, |
61 'disableav!' => \$bDisableAntiVirus, |
|
62 'bom=s' => \$sUseBom, |
61 'help!' => \$bHelp |
63 'help!' => \$bHelp |
62 )); |
64 )); |
63 |
65 |
64 if ($bHelp or !($sSubProject or $sFbfProjectRepo or $sFbfProjectDir)) |
66 if ($bHelp or !($sSubProject or $sFbfProjectRepo or $sFbfProjectDir)) |
65 { |
67 { |
79 print "\t--tag=TAG Apply Diamonds tag TAG to this build\n"; |
81 print "\t--tag=TAG Apply Diamonds tag TAG to this build\n"; |
80 print "\t--hudson Clean up all job dirs after the build)\n"; |
82 print "\t--hudson Clean up all job dirs after the build)\n"; |
81 print "\t--nopublish Use \\numbers_test.txt for numbers and disable publishing\n"; |
83 print "\t--nopublish Use \\numbers_test.txt for numbers and disable publishing\n"; |
82 print "\t--define ATTRIBUTE=VALUE Pass -D statements to the Helium Framework\n"; |
84 print "\t--define ATTRIBUTE=VALUE Pass -D statements to the Helium Framework\n"; |
83 print "\t--disableav Disable Anti-Virus for the duration of the build (also sync with other concurrent package builds)\n"; |
85 print "\t--disableav Disable Anti-Virus for the duration of the build (also sync with other concurrent package builds)\n"; |
|
86 print "\t--bom=LOCATION Use to build by taking the sources.csv from the build_BOM.zip at LOCATION\n"; |
84 exit(0); |
87 exit(0); |
85 } |
88 } |
86 |
89 |
87 if ($sSubProject and $sSubProject !~ m,^([^/]+)/[^/]+/([^/]+)$,) |
90 if ($sSubProject and $sSubProject !~ m,^([^/]+)/[^/]+/([^/]+)$,) |
88 { |
91 { |
167 $sProjectArg .= " -Dsf.project.rev=$sFbfProjectRev" if ($sFbfProjectRev); |
170 $sProjectArg .= " -Dsf.project.rev=$sFbfProjectRev" if ($sFbfProjectRev); |
168 $sProjectArg = "-Dsf.project.dir=$sFbfProjectDir" if ($sFbfProjectDir); |
171 $sProjectArg = "-Dsf.project.dir=$sFbfProjectDir" if ($sFbfProjectDir); |
169 my $sBootstrapCmd = "hlm -f bootstrap.xml $sConfigArg $sProjectArg -Dsf.target.dir=$sJobDir"; |
172 my $sBootstrapCmd = "hlm -f bootstrap.xml $sConfigArg $sProjectArg -Dsf.target.dir=$sJobDir"; |
170 print("$sBootstrapCmd\n"); |
173 print("$sBootstrapCmd\n"); |
171 system($sBootstrapCmd); |
174 system($sBootstrapCmd); |
|
175 |
|
176 # get sources.csv from supplied BOM location |
|
177 if ($sUseBom) |
|
178 { |
|
179 print("get sources.csv from supplied BOM location\n"); |
|
180 my $sGetSourcesCmd = "7z e -y -i!build_info\\logs\\BOM\\sources.csv -o$sJobDir\\build\\config\\$sSubProject $sUseBom\\build_BOM.zip"; |
|
181 print("$sGetSourcesCmd\n"); |
|
182 system($sGetSourcesCmd); |
|
183 } |
172 |
184 |
173 # check that $sNUMBERS_FILE exists, otherwise create it |
185 # check that $sNUMBERS_FILE exists, otherwise create it |
174 if (!-f $sNUMBERS_FILE) |
186 if (!-f $sNUMBERS_FILE) |
175 { |
187 { |
176 open FILE, ">$sNUMBERS_FILE"; |
188 open FILE, ">$sNUMBERS_FILE"; |