+2012-01-30 Tor Arne Vestbø <tor.arne.vestbo@nokia.com>
+
+ [Qt] Store build config immediately instead of waiting for a successfull build
+
+ Otherwise we will not pick up changes to the config if the build is aborted,
+ for example due to build errors or if the user pressed Ctrl+Z. We now write
+ the new config before starting a build, but still defer to write the SVN
+ revision once the build completes successfully.
+
+ Reviewed by Ossy.
+
+ * Scripts/webkitdirs.pm:
+ (buildQMakeProjects):
+
2012-01-30 Alexander Færøy <ahf@0x90.dk>
[Qt] Add "New Window" button to the Qt MiniBrowser
#}
}
+ # Save config up-front so we can detect changes to the build config even
+ # when the user re-configures after aborting the build.
+ open(DEFAULTS, ">$pathToDefinesCache");
+ print DEFAULTS "# These defines were set when building WebKit last time\n";
+ foreach my $key (sort keys %defines) {
+ print DEFAULTS "$key=$defines{$key}\n";
+ }
+ close(DEFAULTS);
+
my $result = 0;
my $makefile = File::Spec->catfile($dir, "Makefile");
chdir ".." or die;
if ($result eq 0) {
- $defines{"SVN_REVISION"} = $svnRevision;
- open(DEFAULTS, ">$pathToDefinesCache");
- print DEFAULTS "# These defines were set when building WebKit last time\n";
- foreach my $key (sort keys %defines) {
- print DEFAULTS "$key=$defines{$key}\n";
- }
+ # Now that the build completed successfully we can save the SVN revision
+ open(DEFAULTS, ">>$pathToDefinesCache");
+ print DEFAULTS "SVN_REVISION=$svnRevision\n";
close(DEFAULTS);
} elsif ($buildHint eq "" && exitStatus($result)) {
my $exitCode = exitStatus($result);