summaryrefslogtreecommitdiffstats
path: root/WebKitTools/Scripts/build-dumprendertree
diff options
context:
space:
mode:
Diffstat (limited to 'WebKitTools/Scripts/build-dumprendertree')
-rwxr-xr-xWebKitTools/Scripts/build-dumprendertree39
1 files changed, 32 insertions, 7 deletions
diff --git a/WebKitTools/Scripts/build-dumprendertree b/WebKitTools/Scripts/build-dumprendertree
index 46e86e0..72e81b0 100755
--- a/WebKitTools/Scripts/build-dumprendertree
+++ b/WebKitTools/Scripts/build-dumprendertree
@@ -1,6 +1,6 @@
#!/usr/bin/perl -w
-# Copyright (C) 2005 Apple Computer, Inc. All rights reserved.
+# Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
@@ -26,29 +26,54 @@
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
use strict;
+use File::Basename;
use FindBin;
+use Getopt::Long qw(:config pass_through);
use lib $FindBin::Bin;
use webkitdirs;
use POSIX;
+my $showHelp = 0;
+my $clean = 0;
+
+my $programName = basename($0);
+my $usage = <<EOF;
+Usage: $programName [options] [options to pass to build system]
+ --help Show this help message
+ --clean Clean up the build directory
+ --gtk Build the GTK+ port
+ --qt Build the Qt port
+ --wx Build the wxWindows port
+EOF
+
+GetOptions(
+ 'help' => \$showHelp,
+ 'clean' => \$clean,
+);
+
+if ($showHelp) {
+ print STDERR $usage;
+ exit 1;
+}
+
checkRequiredSystemConfig();
setConfiguration();
chdirWebKit();
-my @options = XcodeOptions();
# Build
chdir "WebKitTools/DumpRenderTree" or die;
+
my $result;
if (isAppleMacWebKit()) {
- $result = system "xcodebuild", "-project", "DumpRenderTree.xcodeproj", @options, @ARGV;
+ $result = buildXCodeProject("DumpRenderTree", $clean, XcodeOptions(), @ARGV);
} elsif (isAppleWinWebKit()) {
- $result = buildVisualStudioProject("DumpRenderTree.sln");
-} elsif (isQt() || isGtk()) {
- # Qt and Gtk build everything in one shot. No need to build anything here.
+ $result = buildVisualStudioProject("DumpRenderTree.sln", $clean);
+} elsif (isQt() || isGtk() || isWx()) {
+ # Qt, Gtk and wxWindows build everything in one shot. No need to build anything here.
$result = 0;
} else {
die "Building not defined for this platform!\n";
}
+
exit exitStatus($result);