+2006-01-19 Darin Adler <darin@apple.com>
+
+ * Scripts/webkitdirs.pm: Changed SVG check to work even if the path has
+ spaces in it by using the form of open that treats each argument as a string
+ rather than backtick syntax for reading the output of the nm tool.
+
2006-01-12 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
my $count = 0;
foreach my $result (@results) {
- $count++;
- my $success = 0;
- open RESULT, "<$result";
- while (<RESULT>) {
- if (/Success/) {
- $success = 1;
- last;
- }
- }
- close RESULT;
- if (!$success) {
- push @failures, $result;
- }
+ $count++;
+ my $success = 0;
+ open RESULT, "<$result";
+ while (<RESULT>) {
+ if (/Success/) {
+ $success = 1;
+ last;
+ }
+ }
+ close RESULT;
+ if (!$success) {
+ push @failures, $result;
+ }
}
my $disabledCount = (scalar @disabled);
print " ($disabledCount disabled)" if $disabledCount;
print "\n";
if ($verbose) {
- print "\n";
- if (@disabled) {
- print " Disabled:\n";
-
- foreach my $failure (sort @disabled) {
- $failure =~ s|.*/||;
- $failure =~ s|-disabled||;
- print " ${directory}/${failure}";
- }
- }
- if (@failures) {
- print " Failed:\n";
-
- foreach my $failure (sort @failures) {
+ print "\n";
+ if (@disabled) {
+ print " Disabled:\n";
+
+ foreach my $failure (sort @disabled) {
+ $failure =~ s|.*/||;
+ $failure =~ s|-disabled||;
+ print " ${directory}/${failure}";
+ }
+ }
+ if (@failures) {
+ print " Failed:\n";
+
+ foreach my $failure (sort @failures) {
$directory =~ m|^dom/(\w+)|;
my $extension = $1;
- $failure =~ s|.*/||;
- $failure =~ s|-expected\.txt|.${extension}|;
- print " ${directory}/${failure}";
- }
- }
+ $failure =~ s|.*/||;
+ $failure =~ s|-expected\.txt|.${extension}|;
+ print " ${directory}/${failure}";
+ }
+ }
- print "\n";
+ print "\n";
}
$totalCount += $count;
if ($testSVGs) {
$extensionPart = "-name '*.svg' -or -name '*.xml'";
} elsif ($haveSVGSupport) {
- $extensionPart .= " -or -name '*.svg'";
+ $extensionPart .= " -or -name '*.svg'";
} else {
$prunePart .= " -or \\( -name svg \\! -prune \\)";
}
my ($fullpath, $prefix, $base) = ($1, $2, $4);
my $previousRevision = 0;
- if($patch =~ /\n--- .+\(revision (\d+)\)\n/) {
- $previousRevision = $1;
- }
+ if($patch =~ /\n--- .+\(revision (\d+)\)\n/) {
+ $previousRevision = $1;
+ }
if ($previousRevision != 0 || $patch !~ /\ndiff -N/) {
# Standard patch, patch tool can handle this.
}
chdir $dir or die "Failed to chdir to $dir\n";
}
-}
\ No newline at end of file
+}
return if !$patch;
my $previousRevision = 0;
- if($patch =~ /\n--- .+\(revision (\d+)\)\n/) {
- $previousRevision = $1;
- }
+ if($patch =~ /\n--- .+\(revision (\d+)\)\n/) {
+ $previousRevision = $1;
+ }
if ($previousRevision != 0 || $patch !~ /\ndiff -N/) {
# Standard patch, patch tool can handle this.
-# Copyright (C) 2005 Apple Computer, Inc. All rights reserved.
+# Copyright (C) 2005, 2006 Apple Computer, Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
sub XcodeOptionString
{
- return join " ", XcodeOptions();
+ return join " ", XcodeOptions();
}
sub XcodeOptionStringNoConfig
{
- return join " ", @baseProductDirOption;
+ return join " ", @baseProductDirOption;
}
my $passedConfiguration;
sub hasSVGSupport
{
my $path = shift;
- my $frameworkSymbols = `nm $path`;
- my $hasSVGSupport = ($frameworkSymbols =~ /SVGElementImpl/);
+ open NM, "-|", "nm", $path or die;
+ my $hasSVGSupport = 0;
+ while (<NM>) {
+ $hasSVGSupport = 1 if /SVGElement/;
+ }
+ close NM;
return $hasSVGSupport;
}
sub checkWebCoreSVGSupport
{
- my $required = shift;
+ my $required = shift;
my $framework = "WebCore";
my $path = builtDylibPathForName($framework);
my $hasSVG = hasSVGSupport($path);
if ($required && !$hasSVG) {
- die "$framework at \"$path\" does not include SVG Support, please run build-webkit --svg\n";
+ die "$framework at \"$path\" does not include SVG Support, please run build-webkit --svg\n";
}
return $hasSVG;
}