Commit 57237325 authored by hausmann's avatar hausmann
Browse files

Make make-css-file-arrays.pl work on Windows by not calling /usr/bin/gcc as...

Make make-css-file-arrays.pl work on Windows by not calling /usr/bin/gcc as preprocessor for the Qt build.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@24688 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 8489c8ef
2007-07-27 Simon Hausmann <hausmann@kde.org>
Done with and reviewed by Lars and Zack.
Make make-css-file-arrays.pl work on Windows by not calling /usr/bin/gcc as preprocessor for the Qt build.
* WebCore.pro:
* css/make-css-file-arrays.pl:
2007-07-27 Simon Hausmann <hausmann@kde.org>
 
Done with and reviewed by Lars and Zack.
......@@ -1421,7 +1421,7 @@ QMAKE_EXTRA_COMPILERS += colordata
# GENERATOR 9:
stylesheets.output = tmp/UserAgentStyleSheetsData.cpp
stylesheets.commands = perl $$PWD/css/make-css-file-arrays.pl tmp/UserAgentStyleSheets.h tmp/UserAgentStyleSheetsData.cpp $$PWD/css/html4.css $$PWD/css/quirks.css $$PWD/css/svg.css $$PWD/css/view-source.css
stylesheets.commands = perl $$PWD/css/make-css-file-arrays.pl --preprocessor \"$${QMAKE_MOC} -E\" tmp/UserAgentStyleSheets.h tmp/UserAgentStyleSheetsData.cpp $$PWD/css/html4.css $$PWD/css/quirks.css $$PWD/css/svg.css $$PWD/css/view-source.css
stylesheets.input = STYLESHEETS_EMBED
stylesheets.CONFIG = target_predeps
stylesheets.variable_out = GENERATED_SOURCES
......
......@@ -21,6 +21,15 @@
# Usage: make-css-file-arrays.pl <header> <output> <input> ...
use strict;
use Getopt::Long;
my $preprocessor;
GetOptions('preprocessor=s' => \$preprocessor);
if (!$preprocessor) {
$preprocessor = "/usr/bin/gcc -E -P -x c++";
}
my $header = $ARGV[0];
shift;
......@@ -39,7 +48,7 @@ for my $in (@ARGV) {
my $name = $1;
# Slurp in the CSS file.
open IN, "-|", "/usr/bin/gcc", "-E", "-P", "-x", "c++", $in or die;
open IN, $preprocessor . " " . $in . "|" or die;
my $text; { local $/; $text = <IN>; }
close IN;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment