From 92351a70e0b9193a1def156a470d9156beb8528b Mon Sep 17 00:00:00 2001 From: Qt by Nokia Date: Wed, 27 Apr 2011 12:34:00 +0200 Subject: Long live the qt5 Qt repository --- ...ndows-Use-jom-instead-of-nmake-if-present.patch | 57 ++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 patches/qtwebkit/0014-QtWebKit-Windows-Use-jom-instead-of-nmake-if-present.patch (limited to 'patches/qtwebkit/0014-QtWebKit-Windows-Use-jom-instead-of-nmake-if-present.patch') diff --git a/patches/qtwebkit/0014-QtWebKit-Windows-Use-jom-instead-of-nmake-if-present.patch b/patches/qtwebkit/0014-QtWebKit-Windows-Use-jom-instead-of-nmake-if-present.patch new file mode 100644 index 00000000..91727468 --- /dev/null +++ b/patches/qtwebkit/0014-QtWebKit-Windows-Use-jom-instead-of-nmake-if-present.patch @@ -0,0 +1,57 @@ +From 845b4a908ee0c3f2467b797046bfcc3f834641b8 Mon Sep 17 00:00:00 2001 +From: Marius Storm-Olsen +Date: Tue, 22 Mar 2011 16:17:10 -0500 +Subject: [PATCH] QtWebKit/Windows: Use jom instead of nmake, if present + +Detect if jom.exe is in the PATH. If so, use Jom instead of +nmake to compile, since Jom supports building on several cores. + +Had to roll out own find_exe function, since File::Which doesn't +seem to be installed by default on certain Linux systems. +--- + Tools/Scripts/webkitdirs.pm | 15 ++++++++++++++- + 1 files changed, 14 insertions(+), 1 deletions(-) + +diff --git a/Tools/Scripts/webkitdirs.pm b/Tools/Scripts/webkitdirs.pm +index 1820f1e..8a5a03e 100644 +--- a/Tools/Scripts/webkitdirs.pm ++++ b/Tools/Scripts/webkitdirs.pm +@@ -1345,6 +1345,18 @@ sub retrieveQMakespecVar + return $varvalue; + } + ++sub find_exe { ++ my ($exe) = @_; ++ return if (!defined($exe)); ++ my @paths = split(/;/, $ENV{"PATH"}); ++ foreach my $path (@paths) { ++ $path =~ s/\\$//g; ++ $path =~ s/\\/\//g; ++ my $file = $path . '/' . $exe; ++ return $file if ((-e $file) && (-f $file)); ++ } ++} ++ + sub qtMakeCommand($) + { + my ($qmakebin) = @_; +@@ -1356,6 +1368,7 @@ sub qtMakeCommand($) + #print "compiler found: " . $compiler . "\n"; + + if ($compiler && $compiler eq "cl") { ++ return "jom" if(find_exe('jom.exe')); + return "nmake"; + } + +@@ -1640,7 +1653,7 @@ sub buildQMakeProject($@) + for my $subdir (@subdirs) { + my $dsMakefile = "Makefile.DerivedSources"; + print "Calling '$make $makeargs -C $subdir -f $dsMakefile generated_files' in " . $dir . "/$subdir\n\n"; +- if ($make eq "nmake") { ++ if ($make eq "nmake" || $make eq "jom") { + my $subdirWindows = $subdir; + $subdirWindows =~ s:/:\\:g; + $result = system "pushd $subdirWindows && $make $makeargs -f $dsMakefile generated_files && popd"; +-- +1.7.2.3.msysgit.0.311.gb27be + -- cgit v1.2.3