diff options
author | Ivo Hinkelmann <ihi@openoffice.org> | 2009-04-30 12:02:03 +0000 |
---|---|---|
committer | Ivo Hinkelmann <ihi@openoffice.org> | 2009-04-30 12:02:03 +0000 |
commit | a69de49fe66f382e36cf99f805686335a9c2d795 (patch) | |
tree | 5cfb1c6e1d5656968a7e5261ab99c75d476d6d8e /smoketestoo_native | |
parent | f07e2fd59e6328b81702bf9c7b59ffc1a62e29af (diff) |
#i10000# build fix
Diffstat (limited to 'smoketestoo_native')
-rwxr-xr-x | smoketestoo_native/config.pl | 39 | ||||
-rw-r--r-- | smoketestoo_native/makefile.mk | 6 | ||||
-rwxr-xr-x | smoketestoo_native/smoketest.pl | 5 |
3 files changed, 41 insertions, 9 deletions
diff --git a/smoketestoo_native/config.pl b/smoketestoo_native/config.pl index d2e5bdae8bb6..642a256e33d4 100755 --- a/smoketestoo_native/config.pl +++ b/smoketestoo_native/config.pl @@ -75,6 +75,9 @@ $common_XML = "Common.xcu"; $setup_XML = "Setup.xcu"; $oooimprovement_XML = "Settings.xcu"; +# $(INPATH)\misc\Common.xcu +$inpath_Common_XCU = $ENV{INPATH} . $pathslash . "misc" . $pathslash . $common_XML; + ### main ### $idStr = ' $Revision: 1.5 $ '; @@ -92,8 +95,8 @@ if ( ($#ARGV >= 3) ) { chop($ARGV[3]); } -if ( ! ( ($#ARGV >= 3) && $ARGV[0] && $ARGV[1] && $ARGV[2] && $ARGV[3] && (-d $ARGV[3]) ) ) { - print "Usage: config <basispath> <brandpath> <userinstallpath> <datapath>\n" ; +if ( ! ( ($#ARGV >= 4) && $ARGV[0] && $ARGV[1] && $ARGV[2] && $ARGV[3] && (-d $ARGV[3]) && $ARGV[4] ) ) { + print "Usage: config <basispath> <brandpath> <userinstallpath> <datapath> <buildid>\n" ; exit(1); } @@ -101,6 +104,7 @@ $basisdir = $ARGV[0]; $branddir = $ARGV[1]; $userinstalldir = $ARGV[2]; $datapath = $ARGV[3]; +$buildid = $ARGV[4]; $fullquickstart_path = $branddir . "program" . $pathslash . "quickstart.exe"; @@ -113,9 +117,10 @@ if (!-d "$userinstalldir$OOoImprovement_Path") { } # copy Common.xcu - -print "cp $datapath$common_XML $userinstalldir$User_Office_Path$common_XML\n" if $is_debug; -copy ("$datapath$common_XML", "$userinstalldir$User_Office_Path$common_XML"); +print "Patching Common.xcu\n" if $is_debug; +PatchCommonXcu($buildid); +print "cp $inpath_Common_XCU $userinstalldir$User_Office_Path$common_XML\n" if $is_debug; +copy ("$inpath_Common_XCU", "$userinstalldir$User_Office_Path$common_XML"); # copy OOoImprovement/Settings.xcu @@ -140,3 +145,27 @@ unlink ($fullsource_path); exit(0); +############################################################################ +sub PatchCommonXcu #17.04.2009 10:37 +############################################################################ + { + my $buildid = shift; + open(INFILE, "< $datapath$common_XML") || die "Can't open $datapath$common_XML (read)\n"; + open(OUTFILE, "> $inpath_Common_XCU") || die "Can't open $inpath_Common_XCU (write)\n"; + my $patch_next_line = 0; + my $value = "<value>Patch" . $buildid . "</value>\n"; + while ( $line = <INFILE> ) { + if ( $patch_next_line ) { + print OUTFILE " $value"; + $patch_next_line = 0; + } else + { + print OUTFILE $line; + } + if ( $line =~ /ReminderDate/ ) { + $patch_next_line = 1; + } + } + close(INFILE); + close(OUTFILE); +} ##PatchCommonXcu diff --git a/smoketestoo_native/makefile.mk b/smoketestoo_native/makefile.mk index 5a00eb10f5cc..f21ae594bf33 100644 --- a/smoketestoo_native/makefile.mk +++ b/smoketestoo_native/makefile.mk @@ -48,11 +48,11 @@ ALLTAR : make_test make_test: .IF $(NOREMOVE) - @$(PERL) smoketest.pl -nr $(LAST_MINOR) + @$(PERL) smoketest.pl -nr $(LAST_MINOR) $(BUILD) .ELSE - @$(PERL) smoketest.pl $(LAST_MINOR) + @$(PERL) smoketest.pl $(LAST_MINOR) $(BUILD) .ENDIF noremove: - @$(PERL) smoketest.pl -nr $(LAST_MINOR) + @$(PERL) smoketest.pl -nr $(LAST_MINOR) $(BUILD) diff --git a/smoketestoo_native/smoketest.pl b/smoketestoo_native/smoketest.pl index 988d0602fcc8..61b95f7efa2f 100755 --- a/smoketestoo_native/smoketest.pl +++ b/smoketestoo_native/smoketest.pl @@ -272,6 +272,9 @@ if ($opt_nr) { if ( $ARGV[0] ) { $milestone = $ARGV[0]; } +if ( $ARGV[1] ) { + $buildid = $ARGV[1]; +} #### script id ##### @@ -480,7 +483,7 @@ sub doTest { # patch config (error 3) - $Command = "$PERL config.pl \"$basisdir \" \"$branddir \" \"$userinstallpath \" \"$DATA \""; + $Command = "$PERL config.pl \"$basisdir \" \"$branddir \" \"$userinstallpath \" \"$DATA \" \"$buildid\""; execute_Command ($Command, $error_patchConfig, $show_Message, $command_normal ); # copy basicscripts (error 9) |