Modified: trunk/Tools/ChangeLog (97734 => 97735)
--- trunk/Tools/ChangeLog 2011-10-18 10:04:54 UTC (rev 97734)
+++ trunk/Tools/ChangeLog 2011-10-18 10:36:28 UTC (rev 97735)
@@ -1,5 +1,24 @@
2011-10-18 Tor Arne Vestbø <[email protected]>
+ [Qt] Remove dead code in build-webkit
+
+ build-webkit will iterate over a list of subdirectories to build,
+ but this feature is only used by the Apple ports. For QtWebKit we
+ always pass an empty directory to buildQMakeProject, which makes
+ the logic for dealing with sub-projects in buildQMakeProject just
+ added noise.
+
+ If we do want this feature at some point, we should redo it in
+ the context of the upcoming build system changes for Qt.
+
+ Reviewed by Simon Hausmann.
+
+ * Scripts/build-webkit:
+ * Scripts/webkitdirs.pm:
+ (buildQt):
+
+2011-10-18 Tor Arne Vestbø <[email protected]>
+
Remove traces of Symbian support from the build scripts
Reviewed by Simon Hausmann.
Modified: trunk/Tools/Scripts/build-webkit (97734 => 97735)
--- trunk/Tools/Scripts/build-webkit 2011-10-18 10:04:54 UTC (rev 97734)
+++ trunk/Tools/Scripts/build-webkit 2011-10-18 10:36:28 UTC (rev 97735)
@@ -594,6 +594,13 @@
exit exitStatus($result) if exitStatus($result);
}
+if (isQt()) {
+ # Qt doesn't build by project directories.
+ @projects = ();
+ my $result = buildQt($clean, @options);
+ exit exitStatus($result) if exitStatus($result);
+}
+
if (isEfl()) {
# By default we build using all of the available CPUs.
$makeArgs .= ($makeArgs ? " " : "") . "-j" . numberOfCPUs() if $makeArgs !~ /-j\s*\d+/;
@@ -609,8 +616,8 @@
chdir $dir or die;
my $result = 0;
- # For Gtk and Qt the WebKit project builds all others
- if ((isGtk() || isQt()) && $dir ne "Source/WebKit") {
+ # For Gtk the WebKit project builds all others
+ if ((isGtk()) && $dir ne "Source/WebKit") {
chdirWebKit();
next;
}
@@ -618,9 +625,6 @@
my $project = basename($dir);
if (isGtk()) {
$result = buildGtkProject($project, $clean, !$noWebKit2, @options);
- } elsif (isQt()) {
- #FIXME: $dir should probably be $project.
- $result = buildQMakeQtProject($dir, $clean, @options);
} elsif (isAppleMacWebKit()) {
my @local_options = @options;
push @local_options, XcodeCoverageSupportOptions() if $coverageSupport && $project ne "ANGLE";
Modified: trunk/Tools/Scripts/webkitdirs.pm (97734 => 97735)
--- trunk/Tools/Scripts/webkitdirs.pm 2011-10-18 10:04:54 UTC (rev 97734)
+++ trunk/Tools/Scripts/webkitdirs.pm 2011-10-18 10:36:28 UTC (rev 97735)
@@ -1643,17 +1643,11 @@
exit($returnCode) if $returnCode;
}
-sub buildQMakeProject($@)
+sub buildQt($@)
{
- my ($project, $clean, @buildParams) = @_;
+ my ($clean, @buildParams) = @_;
my @subdirs = ("_javascript_Core", "WebCore", "WebKit/qt/Api");
- if (grep { $_ eq $project } @subdirs) {
- @subdirs = ($project);
- } else {
- $project = 0;
- }
-
my @buildArgs = ("-r");
my $makeargs = "";
@@ -1683,14 +1677,8 @@
my $dir = File::Spec->canonpath(productDir());
my $originalCwd = getcwd();
- my $configArgs = "CONFIG+=compute_defaults";
- if (isWK2()) {
- chdir File::Spec->catfile(sourceDir(), "Source", "WebKit2");
- $configArgs = "CONFIG+=webkit2 $configArgs";
- } else {
- chdir File::Spec->catfile(sourceDir(), "Source", "WebCore");
- }
- my $defaults = `$qmakebin $configArgs 2>&1`;
+ chdir File::Spec->catfile(sourceDir(), "Source", "WebCore");
+ my $defaults = `$qmakebin CONFIG+=compute_defaults 2>&1`;
chdir $originalCwd;
File::Path::mkpath($dir);
@@ -1723,9 +1711,6 @@
my @dsQmakeArgs = @buildArgs;
push @dsQmakeArgs, "-r";
push @dsQmakeArgs, sourceDir() . "/Source/DerivedSources.pro";
- if ($project) {
- push @dsQmakeArgs, "-after SUBDIRS=" . $project. "/DerivedSources.pro";
- }
push @dsQmakeArgs, "-o Makefile.DerivedSources";
print "Calling '$qmakebin @dsQmakeArgs' in " . $dir . "\n\n";
my $result = system "$qmakebin @dsQmakeArgs";
@@ -1733,23 +1718,21 @@
die "Failed while running $qmakebin to generate derived sources!\n";
}
- if ($project ne "_javascript_Core") {
- # FIXME: Iterate over different source directories manually to workaround a problem with qmake+extraTargets+s60
- # To avoid overwriting of Makefile.DerivedSources in the root dir use Makefile.DerivedSources.Tools for Tools
- if (grep { $_ eq "CONFIG+=webkit2"} @buildArgs) {
- push @subdirs, "WebKit2";
- if ( -e sourceDir() ."/Tools/DerivedSources.pro" ) {
- @dsQmakeArgs = @buildArgs;
- push @dsQmakeArgs, "-r";
- push @dsQmakeArgs, sourceDir() . "/Tools/DerivedSources.pro";
- push @dsQmakeArgs, "-o Makefile.DerivedSources.Tools";
- print "Calling '$qmakebin @dsQmakeArgs' in " . $dir . "\n\n";
- my $result = system "$qmakebin @dsQmakeArgs";
- if ($result ne 0) {
- die "Failed while running $qmakebin to generate derived sources for Tools!\n";
- }
- push @subdirs, "WebKitTestRunner";
+ # FIXME: Iterate over different source directories manually to workaround a problem with qmake+extraTargets+s60
+ # To avoid overwriting of Makefile.DerivedSources in the root dir use Makefile.DerivedSources.Tools for Tools
+ if (grep { $_ eq "CONFIG+=webkit2"} @buildArgs) {
+ push @subdirs, "WebKit2";
+ if ( -e sourceDir() ."/Tools/DerivedSources.pro" ) {
+ @dsQmakeArgs = @buildArgs;
+ push @dsQmakeArgs, "-r";
+ push @dsQmakeArgs, sourceDir() . "/Tools/DerivedSources.pro";
+ push @dsQmakeArgs, "-o Makefile.DerivedSources.Tools";
+ print "Calling '$qmakebin @dsQmakeArgs' in " . $dir . "\n\n";
+ my $result = system "$qmakebin @dsQmakeArgs";
+ if ($result ne 0) {
+ die "Failed while running $qmakebin to generate derived sources for Tools!\n";
}
+ push @subdirs, "WebKitTestRunner";
}
}
@@ -1782,12 +1765,6 @@
}
}
- if ($project) {
- push @buildArgs, "-after SUBDIRS=" . $project . "/" . $project . ".pro ";
- if ($project eq "_javascript_Core") {
- push @buildArgs, "-after SUBDIRS+=" . $project . "/jsc.pro ";
- }
- }
push @buildArgs, sourceDir() . "/Source/WebKit.pro";
print "Calling '$qmakebin @buildArgs' in " . $dir . "\n\n";
print "Installation headers directory: $installHeaders\n" if(defined($installHeaders));
@@ -1799,36 +1776,30 @@
}
my $makefile = "";
- if (!$project) {
- $buildArgs[-1] = sourceDir() . "/Tools/Tools.pro";
- $makefile = "Makefile.Tools";
+ $buildArgs[-1] = sourceDir() . "/Tools/Tools.pro";
+ $makefile = "Makefile.Tools";
- print "Calling '$qmakebin @buildArgs -o $makefile' in " . $dir . "\n\n";
- $result = system "$qmakebin @buildArgs -o $makefile";
- if ($result ne 0) {
- die "Failed to setup build environment using $qmakebin!\n";
- }
+ print "Calling '$qmakebin @buildArgs -o $makefile' in " . $dir . "\n\n";
+ $result = system "$qmakebin @buildArgs -o $makefile";
+ if ($result ne 0) {
+ die "Failed to setup build environment using $qmakebin!\n";
}
- if (!$project) {
- # Manually create makefiles for the examples so we don't build by default
- my $examplesDir = $dir . "/WebKit/qt/examples";
- File::Path::mkpath($examplesDir);
- $buildArgs[-1] = sourceDir() . "/Source/WebKit/qt/examples/examples.pro";
- chdir $examplesDir or die;
- print "Calling '$qmakebin @buildArgs' in " . $examplesDir . "\n\n";
- $result = system "$qmakebin @buildArgs";
- die "Failed to create makefiles for the examples!\n" if $result ne 0;
- chdir $dir or die;
- }
+ # Manually create makefiles for the examples so we don't build by default
+ my $examplesDir = $dir . "/WebKit/qt/examples";
+ File::Path::mkpath($examplesDir);
+ $buildArgs[-1] = sourceDir() . "/Source/WebKit/qt/examples/examples.pro";
+ chdir $examplesDir or die;
+ print "Calling '$qmakebin @buildArgs' in " . $examplesDir . "\n\n";
+ $result = system "$qmakebin @buildArgs";
+ die "Failed to create makefiles for the examples!\n" if $result ne 0;
+ chdir $dir or die;
my $makeTools = "echo";
- if (!$project) {
- $makeTools = "echo No Makefile for Tools. Skipping make";
+ $makeTools = "echo No Makefile for Tools. Skipping make";
- if (-e "$dir/$makefile") {
- $makeTools = "$make $makeargs -f $makefile";
- }
+ if (-e "$dir/$makefile") {
+ $makeTools = "$make $makeargs -f $makefile";
}
if ($clean) {
@@ -1845,13 +1816,6 @@
return $result;
}
-sub buildQMakeQtProject($$@)
-{
- my ($project, $clean, @buildArgs) = @_;
-
- return buildQMakeProject("", $clean, @buildArgs);
-}
-
sub buildGtkProject
{
my ($project, $clean, $enableWebKit2, @buildArgs) = @_;