Title: [191766] trunk/Tools
Revision
191766
Author
bfulg...@apple.com
Date
2015-10-29 17:20:10 -0700 (Thu, 29 Oct 2015)

Log Message

[Win] build-jsc and run-_javascript_core-tests do not work
https://bugs.webkit.org/show_bug.cgi?id=150700

Reviewed by Mark Lam.
        
Correct our build system so that it expects Windows to be using CMake,
and to build the correct sub-projects for our JSC helper scripts.

* Scripts/build-jsc: Make sure to build the testapi harness when
  building for Windows.
* Scripts/build-webkit:
  (1) Use the existing 'cmakeBasedPortName()'
  (2) Use File::Spec rather than hard-coding path delimeters.
  (3) Refer to Visual Studio 14.0, rather than the unsupported 12.0.
method rather than hard-coding the name based on conditional.
* Scripts/run-_javascript_core-tests:
(testapiPath): Use File::Spec rather than hard-coding path delimeters.
* Scripts/run-jsc: Ditto.
* Scripts/webkitdirs.pm:
(cmakeBasedPortName): Update to return the right value for the Apple
Windows port and the WinCairo port.
(isCMakeBuild): Expect CMake build for all Windows ports.

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (191765 => 191766)


--- trunk/Tools/ChangeLog	2015-10-30 00:03:22 UTC (rev 191765)
+++ trunk/Tools/ChangeLog	2015-10-30 00:20:10 UTC (rev 191766)
@@ -1,3 +1,28 @@
+2015-10-29  Brent Fulgham  <bfulg...@apple.com>
+
+        [Win] build-jsc and run-_javascript_core-tests do not work
+        https://bugs.webkit.org/show_bug.cgi?id=150700
+
+        Reviewed by Mark Lam.
+        
+        Correct our build system so that it expects Windows to be using CMake,
+        and to build the correct sub-projects for our JSC helper scripts.
+
+        * Scripts/build-jsc: Make sure to build the testapi harness when
+          building for Windows.
+        * Scripts/build-webkit:
+          (1) Use the existing 'cmakeBasedPortName()'
+          (2) Use File::Spec rather than hard-coding path delimeters.
+          (3) Refer to Visual Studio 14.0, rather than the unsupported 12.0.
+        method rather than hard-coding the name based on conditional.
+        * Scripts/run-_javascript_core-tests:
+        (testapiPath): Use File::Spec rather than hard-coding path delimeters.
+        * Scripts/run-jsc: Ditto.
+        * Scripts/webkitdirs.pm:
+        (cmakeBasedPortName): Update to return the right value for the Apple
+        Windows port and the WinCairo port.
+        (isCMakeBuild): Expect CMake build for all Windows ports.
+
 2015-10-29  Alex Christensen  <achristen...@webkit.org>
 
         Fix build-jsc on Mac after r191749.

Modified: trunk/Tools/Scripts/build-jsc (191765 => 191766)


--- trunk/Tools/Scripts/build-jsc	2015-10-30 00:03:22 UTC (rev 191765)
+++ trunk/Tools/Scripts/build-jsc	2015-10-30 00:20:10 UTC (rev 191766)
@@ -101,7 +101,8 @@
     $makeArgs .= ($makeArgs ? " " : "") . "-j" . numberOfCPUs() if $makeArgs !~ /-j\s*\d+/;
 
     # This call only returns if nothing wrong happened
-    buildCMakeProjectOrExit(0, cmakeBasedPortName(), undef, "jsc $makeArgs", (cmakeBasedPortArguments(), $cmakeArgs));
+    my $testapi = (isAnyWindows() ? "testapi" : "");
+    buildCMakeProjectOrExit(0, cmakeBasedPortName(), undef, "jsc $testapi $makeArgs", (cmakeBasedPortArguments(), $cmakeArgs));
     writeCongrats();
     exit exitStatus(0);
 }

Modified: trunk/Tools/Scripts/build-webkit (191765 => 191766)


--- trunk/Tools/Scripts/build-webkit	2015-10-30 00:03:22 UTC (rev 191765)
+++ trunk/Tools/Scripts/build-webkit	2015-10-30 00:20:10 UTC (rev 191766)
@@ -252,15 +252,15 @@
 my $baseProductDir = baseProductDir();
 if (isAppleWinWebKit() || isWinCairo()) {
     chdirWebKit();
-    if (exitStatus(generateBuildSystemFromCMakeProject(isWinCairo() ? "WinCairo" : "AppleWin"))) {
-        die "Run \"C:/Program Files (x86)/Microsoft Visual Studio 12.0/VC/vcvarsall.bat\" before build-webkit when using ninja";
+    if (exitStatus(generateBuildSystemFromCMakeProject(cmakeBasedPortName()))) {
+        die "Run \"C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/vcvarsall.bat\" before build-webkit when using ninja";
     }
     chdirWebKit();
     if (canUseNinja()) {
-        chdir "WebKitBuild/" . configuration();
+        chdir File::Spec->catdir("WebKitBuild", configuration());
         $result = system("ninja");
     } else {
-        $result = buildVisualStudioProject("WebKitBuild/" . configuration() . "/WebKit.sln", $clean);
+        $result = buildVisualStudioProject(File::Spec->catfile("WebKitBuild", configuration(), "WebKit.sln"), $clean);
     }
     if (exitStatus($result)) {
         my $scriptDir = relativeScriptsDir();

Modified: trunk/Tools/Scripts/run-_javascript_core-tests (191765 => 191766)


--- trunk/Tools/Scripts/run-_javascript_core-tests	2015-10-30 00:03:22 UTC (rev 191765)
+++ trunk/Tools/Scripts/run-_javascript_core-tests	2015-10-30 00:20:10 UTC (rev 191766)
@@ -145,7 +145,7 @@
     push(@buildArgs, argumentsForConfiguration());
 
     print "Running: build-jsc " . join(" ", @buildArgs) . "\n";
-    my $buildResult = system "perl", "Tools/Scripts/build-jsc", @buildArgs;
+    my $buildResult = system "perl", File::Spec->catfile("Tools", "Scripts", "build-jsc"), @buildArgs;
     if ($buildResult) {
         print STDERR "Compiling jsc failed!\n";
         exit exitStatus($buildResult);
@@ -171,7 +171,7 @@
     my ($productDir) = @_;
     my $jscName = "testapi";
     $jscName .= "_debug" if configuration() eq "Debug_All";
-    return "$productDir/$jscName";
+    return File::Spec->catfile($productDir, $jscName);
 }
 
 #run api tests

Modified: trunk/Tools/Scripts/run-jsc (191765 => 191766)


--- trunk/Tools/Scripts/run-jsc	2015-10-30 00:03:22 UTC (rev 191765)
+++ trunk/Tools/Scripts/run-jsc	2015-10-30 00:20:10 UTC (rev 191766)
@@ -44,7 +44,7 @@
 
 setConfiguration();
 
-my $jsc = jscProductDir() . "/jsc @ARGV";
+my $jsc = File::Spec->catfile(jscProductDir(), "jsc ") . "@ARGV";
 
 my $dyld = jscProductDir();
 

Modified: trunk/Tools/Scripts/webkitdirs.pm (191765 => 191766)


--- trunk/Tools/Scripts/webkitdirs.pm	2015-10-30 00:03:22 UTC (rev 191765)
+++ trunk/Tools/Scripts/webkitdirs.pm	2015-10-30 00:20:10 UTC (rev 191766)
@@ -2040,6 +2040,8 @@
     return "Efl" if isEfl();
     return "GTK" if isGtk();
     return "Mac" if isAppleMacWebKit();
+    return "WinCairo" if isWinCairo();
+    return "AppleWin" if isAppleWinWebKit();
     return "";
 }
 
@@ -2051,7 +2053,7 @@
 
 sub isCMakeBuild()
 {
-    if (isEfl() || isGtk()) {
+    if (isEfl() || isGtk() || isAnyWindows()) {
         return 1;
     }
     determineIsCMakeBuild();
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to