Title: [99729] trunk/Tools
- Revision
- 99729
- Author
- [email protected]
- Date
- 2011-11-09 09:40:35 -0800 (Wed, 09 Nov 2011)
Log Message
Add webkitdirs.pm:getArchitecture implementation for GTK
https://bugs.webkit.org/show_bug.cgi?id=71370
Patch by Andy Wingo <[email protected]> on 2011-11-09
Reviewed by Xan Lopez.
* Scripts/webkitdirs.pm (determineArchitecture): Add an
implementation for ports using autotools, so that a vanilla
`run-_javascript_core-tests --gtk' invocation doesn't pass --32-bit
to build-jsc on x86-64 machines.
Modified Paths
Diff
Modified: trunk/Tools/ChangeLog (99728 => 99729)
--- trunk/Tools/ChangeLog 2011-11-09 17:32:47 UTC (rev 99728)
+++ trunk/Tools/ChangeLog 2011-11-09 17:40:35 UTC (rev 99729)
@@ -1,3 +1,15 @@
+2011-11-09 Andy Wingo <[email protected]>
+
+ Add webkitdirs.pm:getArchitecture implementation for GTK
+ https://bugs.webkit.org/show_bug.cgi?id=71370
+
+ Reviewed by Xan Lopez.
+
+ * Scripts/webkitdirs.pm (determineArchitecture): Add an
+ implementation for ports using autotools, so that a vanilla
+ `run-_javascript_core-tests --gtk' invocation doesn't pass --32-bit
+ to build-jsc on x86-64 machines.
+
2011-11-09 Simon Hausmann <[email protected]>
Unreviewed, rolling out r99707.
Modified: trunk/Tools/Scripts/webkitdirs.pm (99728 => 99729)
--- trunk/Tools/Scripts/webkitdirs.pm 2011-11-09 17:32:47 UTC (rev 99728)
+++ trunk/Tools/Scripts/webkitdirs.pm 2011-11-09 17:40:35 UTC (rev 99729)
@@ -239,26 +239,39 @@
sub determineArchitecture
{
return if defined $architecture;
- # make sure $architecture is defined for non-apple-mac builds
+ # make sure $architecture is defined in all cases
$architecture = "";
- return unless isAppleMacWebKit();
determineBaseProductDir();
- if (open ARCHITECTURE, "$baseProductDir/Architecture") {
- $architecture = <ARCHITECTURE>;
- close ARCHITECTURE;
- }
- if ($architecture) {
- chomp $architecture;
- } else {
- if (isLeopard()) {
+
+ if (isGtk()) {
+ determineConfigurationProductDir();
+ my $host_triple = `grep -E '^host = ' $configurationProductDir/GNUmakefile`;
+ if ($host_triple =~ m/^host = ([^-]+)-/) {
+ # We have a configured build tree; use it.
+ $architecture = $1;
+ } else {
+ # Fall back to output of `arch', if it is present.
$architecture = `arch`;
+ chomp $architecture;
+ }
+ } elsif (isAppleMacWebKit()) {
+ if (open ARCHITECTURE, "$baseProductDir/Architecture") {
+ $architecture = <ARCHITECTURE>;
+ close ARCHITECTURE;
+ }
+ if ($architecture) {
+ chomp $architecture;
} else {
- my $supports64Bit = `sysctl -n hw.optional.x86_64`;
- chomp $supports64Bit;
- $architecture = $supports64Bit ? 'x86_64' : `arch`;
+ if (isLeopard()) {
+ $architecture = `arch`;
+ } else {
+ my $supports64Bit = `sysctl -n hw.optional.x86_64`;
+ chomp $supports64Bit;
+ $architecture = $supports64Bit ? 'x86_64' : `arch`;
+ }
+ chomp $architecture;
}
- chomp $architecture;
}
}
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes