Skip to content

Commit f6057e6

Browse files
committed
[GTK] jhbuild cloning is not following WEBKITOUTPUTDIR.
https://bugs.webkit.org/show_bug.cgi?id=76161 Reviewed by Martin Robinson. * Scripts/webkitdirs.pm: (getJhbuildPath): New method to obtain the jhbuild base directory, using the product base directory (jhbuildConfigurationChanged): Use the new method (buildAutotoolsProject): Ditto. * efl/jhbuildrc: Use WEBKITOUTPUTDIR when calculating the path. * gtk/jhbuildrc: Ditto. * jhbuild/jhbuild-wrapper: Ditto. Canonical link: https://commits.webkit.org/102656@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@115532 268f45cc-cd09-0410-ab3c-d52691b4dbfc
1 parent 9301fa1 commit f6057e6

5 files changed

Lines changed: 47 additions & 10 deletions

File tree

Tools/ChangeLog

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
2012-04-27 Gustavo Noronha Silva <gns@gnome.org>
2+
3+
[GTK] jhbuild cloning is not following WEBKITOUTPUTDIR.
4+
https://bugs.webkit.org/show_bug.cgi?id=76161
5+
6+
Reviewed by Martin Robinson.
7+
8+
* Scripts/webkitdirs.pm:
9+
(getJhbuildPath): New method to obtain the jhbuild base directory,
10+
using the product base directory
11+
(jhbuildConfigurationChanged): Use the new method
12+
(buildAutotoolsProject): Ditto.
13+
* efl/jhbuildrc: Use WEBKITOUTPUTDIR when calculating the path.
14+
* gtk/jhbuildrc: Ditto.
15+
* jhbuild/jhbuild-wrapper: Ditto.
16+
117
2012-04-27 Scott Graham <scottmg@chromium.org>
218

319
[chromium] make case of npTestNetscapePlugIn.dll match case in copy rule

Tools/Scripts/webkitdirs.pm

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1841,10 +1841,15 @@ sub runAutogenForAutotoolsProjectIfNecessary($@)
18411841
}
18421842
}
18431843

1844+
sub getJhbuildPath()
1845+
{
1846+
return join(baseProductDir(), "Dependencies");
1847+
}
1848+
18441849
sub jhbuildConfigurationChanged()
18451850
{
18461851
foreach my $file (qw(jhbuildrc.md5sum jhbuild.modules.md5sum)) {
1847-
my $path = join('/', $sourceDir, "WebKitBuild", "Dependencies", $file);
1852+
my $path = join(getJhbuildPath(), $file);
18481853
if (! -e $path) {
18491854
return 1;
18501855
}
@@ -1957,7 +1962,8 @@ sub buildAutotoolsProject($@)
19571962
# If the configuration changed, dependencies may have been removed.
19581963
# Since we lack a granular way of uninstalling those we wipe out the
19591964
# jhbuild root and start from scratch.
1960-
if (system("rm -rf $baseProductDir/Dependencies/Root") ne 0) {
1965+
my $jhbuildPath = getJhbuildPath();
1966+
if (system("rm -rf $jhbuildPath/Root") ne 0) {
19611967
die "Cleaning jhbuild root failed!";
19621968
}
19631969

@@ -1982,7 +1988,7 @@ sub buildAutotoolsProject($@)
19821988
# Save md5sum for jhbuild-related files.
19831989
foreach my $file (qw(jhbuildrc jhbuild.modules)) {
19841990
my $source = join('/', $sourceDir, "Tools", "gtk", $file);
1985-
my $destination = join('/', $sourceDir, "WebKitBuild", "Dependencies", $file);
1991+
my $destination = join(getJhbuildPath(), $file);
19861992
open(SUM, ">$destination" . ".md5sum");
19871993
print SUM getMD5HashForFile($source);
19881994
close(SUM);

Tools/efl/jhbuildrc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,12 @@ modules = [ 'webkitefl-testing-dependencies', ]
3838
if __extra_modules != ['']:
3939
modules.extend(__extra_modules)
4040

41-
checkoutroot = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Source'))
42-
prefix = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Root'))
41+
if os.environ.has_key('WEBKITOUTPUTDIR'):
42+
checkoutroot = os.path.abspath(os.path.join(os.environ['WEBKITOUTPUTDIR'], 'Dependencies', 'Source'))
43+
prefix = os.path.abspath(os.path.join(os.environ['WEBKITOUTPUTDIR'], 'Dependencies', 'Root'))
44+
else:
45+
checkoutroot = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Source'))
46+
prefix = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Root'))
4347

4448
nonotify = True
4549
notrayicon = True

Tools/gtk/jhbuildrc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,12 @@ modules = [ 'webkitgtk-testing-dependencies', ]
3535
if __extra_modules != ['']:
3636
modules.extend(__extra_modules)
3737

38-
checkoutroot = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Source'))
39-
prefix = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Root'))
38+
if os.environ.has_key('WEBKITOUTPUTDIR'):
39+
checkoutroot = os.path.abspath(os.path.join(os.environ['WEBKITOUTPUTDIR'], 'Dependencies', 'Source'))
40+
prefix = os.path.abspath(os.path.join(os.environ['WEBKITOUTPUTDIR'], 'Dependencies', 'Root'))
41+
else:
42+
checkoutroot = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Source'))
43+
prefix = os.path.abspath(common.top_level_path('WebKitBuild','Dependencies', 'Root'))
4044

4145
nonotify = True
4246
notrayicon = True

Tools/jhbuild/jhbuild-wrapper

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,17 @@ def top_level_path(*args):
3535

3636
jhbuild_revision = '1eedc423f75c605224b430579e4c303292199507'
3737

38-
installation_prefix = os.path.abspath(top_level_path('WebKitBuild', 'Dependencies', 'Root'))
39-
source_path = os.path.abspath(top_level_path('WebKitBuild', 'Dependencies', 'Source'))
38+
if os.environ.has_key('WEBKITOUTPUTDIR'):
39+
dependencies_path = os.path.abspath(os.path.join(os.environ['WEBKITOUTPUTDIR'], 'Dependencies', 'Root'))
40+
else:
41+
dependencies_path = os.path.abspath(top_level_path('WebKitBuild', 'Dependencies', 'Root'))
42+
43+
installation_prefix = os.path.abspath(os.path.join(dependencies_path, 'Root'))
44+
source_path = os.path.abspath(os.path.join(dependencies_path, 'Source'))
4045
jhbuild_source_path = os.path.join(source_path, 'jhbuild')
41-
jhbuild_path = top_level_path('WebKitBuild', 'Dependencies', 'Root', 'bin', 'jhbuild')
46+
jhbuild_path = os.path.join(installation_prefix, 'bin', 'jhbuild')
47+
48+
4249
platform = None;
4350

4451

0 commit comments

Comments
 (0)