Skip to content

Commit

Permalink
2009-12-19 Daniel Bates <dbates@webkit.org>
Browse files Browse the repository at this point in the history
        Reviewed by Timothy Hatcher.

        https://bugs.webkit.org/show_bug.cgi?id=32462

        Added --inspector-frontend flag to build-webkit to copy any changes
        to the inspector front-end files to the built WebCore framework. This
        will make inspector development more consistent with the rest of
        WebKit development.

        * Scripts/build-webkit:
        * Scripts/webkitdirs.pm:

Canonical link: https://commits.webkit.org/43806@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@52393 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
eseidel committed Dec 19, 2009
1 parent fba0953 commit 7ece3f1
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 0 deletions.
14 changes: 14 additions & 0 deletions WebKitTools/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
2009-12-19 Daniel Bates <dbates@webkit.org>

Reviewed by Timothy Hatcher.

https://bugs.webkit.org/show_bug.cgi?id=32462

Added --inspector-frontend flag to build-webkit to copy any changes
to the inspector front-end files to the built WebCore framework. This
will make inspector development more consistent with the rest of
WebKit development.

* Scripts/build-webkit:
* Scripts/webkitdirs.pm:

2009-12-19 Adam Barth <abarth@webkit.org>

Unreviewed fixes for me being terrible at python.
Expand Down
5 changes: 5 additions & 0 deletions WebKitTools/Scripts/build-webkit
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ Usage: $programName [options] [options to pass to build system]
--chromium Build the Chromium port on Mac/Win/Linux
--gtk Build the GTK+ port
--qt Build the Qt port
--inspector-frontend Copy changes to the inspector front-end files to the build directory
--makeargs=<arguments> Optional Makefile flags
Expand Down Expand Up @@ -311,6 +312,10 @@ if (isGtk()) {
# Force re-link of existing libraries if different than expected
removeLibraryDependingOnSVG("WebCore", $svgSupport);

if (isInspectorFrontend()) {
exit exitStatus(copyInspectorFrontendFiles());
}

if (isWx()) {
downloadWafIfNeeded();
push @projects, 'WebKitTools/DumpRenderTree';
Expand Down
46 changes: 46 additions & 0 deletions WebKitTools/Scripts/webkitdirs.pm
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ my $isGtk;
my $isWx;
my @wxArgs;
my $isChromium;
my $isInspectorFrontend;

# Variables for Win32 support
my $vcBuildPath;
Expand Down Expand Up @@ -237,6 +238,7 @@ sub argumentsForConfiguration()
push(@args, '--gtk') if isGtk();
push(@args, '--wx') if isWx();
push(@args, '--chromium') if isChromium();
push(@args, '--inspector-frontend') if isInspectorFrontend();
return @args;
}

Expand Down Expand Up @@ -775,6 +777,18 @@ sub checkWebCoreWCSSSupport
return $hasWCSS;
}

sub isInspectorFrontend()
{
determineIsInspectorFrontend();
return $isInspectorFrontend;
}

sub determineIsInspectorFrontend()
{
return if defined($isInspectorFrontend);
$isInspectorFrontend = checkForArgumentAndRemoveFromARGV("--inspector-frontend");
}

sub isQt()
{
determineIsQt();
Expand Down Expand Up @@ -1172,6 +1186,38 @@ sub setupCygwinEnv()
print "WEBKITLIBRARIESDIR is set to: ", $ENV{"WEBKITLIBRARIESDIR"}, "\n";
}

sub copyInspectorFrontendFiles
{
my $productDir = productDir();
my $sourceInspectorPath = sourceDir() . "/WebCore/inspector/front-end/";
my $inspectorResourcesDirPath = $ENV{"WEBKITINSPECTORRESOURCESDIR"};

if (!defined($inspectorResourcesDirPath)) {
$inspectorResourcesDirPath = "";
}

if (isAppleMacWebKit()) {
$inspectorResourcesDirPath = $productDir . "/WebCore.framework/Resources/inspector";
} elsif (isAppleWinWebKit()) {
$inspectorResourcesDirPath = $productDir . "/WebKit.resources/inspector";
} elsif (isQt() || isGtk()) {
my $prefix = $ENV{"WebKitInstallationPrefix"};
$inspectorResourcesDirPath = (defined($prefix) ? $prefix : "/usr/share") . "/webkit-1.0/webinspector";
}

if (! -d $inspectorResourcesDirPath) {
print "*************************************************************\n";
print "Cannot find '$inspectorResourcesDirPath'.\n" if (defined($inspectorResourcesDirPath));
print "Make sure that you have built WebKit first.\n" if (! -d $productDir || defined($inspectorResourcesDirPath));
print "Optionally, set the environment variable 'WebKitInspectorResourcesDir'\n";
print "to point to the directory that contains the WebKit Inspector front-end\n";
print "files for the built WebCore framework.\n";
print "*************************************************************\n";
die;
}
return system "rsync", "-aut", "--exclude=/.DS_Store", "--exclude=.svn/", !isQt() ? "--exclude=/WebKit.qrc" : "", $sourceInspectorPath, $inspectorResourcesDirPath;
}

sub buildXCodeProject($$@)
{
my ($project, $clean, @extraOptions) = @_;
Expand Down

0 comments on commit 7ece3f1

Please sign in to comment.