<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[179405] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/179405">179405</a></dd>
<dt>Author</dt> <dd>bfulgham@apple.com</dd>
<dt>Date</dt> <dd>2015-01-30 10:26:36 -0800 (Fri, 30 Jan 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>[Win] Switch to Apache on Windows
https://bugs.webkit.org/show_bug.cgi?id=141060

Reviewed by Alexey Proskuryakov.

Tools:

Update our scripts under Windows (and Cygwin) to locate and use
the XAMPP installation of Apache for running tests.

* Scripts/run-webkit-httpd:
* Scripts/webkitperl/httpd.pm:
(getHTTPDPath):
(getDefaultConfigForTestDirectory):
(getHTTPDConfigPathForTestDirectory):
* Scripts/webkitpy/common/system/executive_unittest.py:
(ExecutiveTest.serial_test_kill_process):
* Scripts/webkitpy/layout_tests/servers/apache_http_server.py:
(LayoutTestApacheHttpd.__init__):
(LayoutTestApacheHttpd._get_apache_config_file_path):
(LayoutTestApacheHttpd._stop_running_server):
* Scripts/webkitpy/layout_tests/servers/http_server_base.py:
(HttpServerBase._is_server_running_on_all_ports):
* Scripts/webkitpy/port/base.py:
(Port._apache_config_file_name_for_platform):
* Scripts/webkitpy/port/port_testcase.py:
(test_apache_config_file_name_for_platform):
* Scripts/webkitpy/port/win.py:
(WinPort.show_results_html_file):
(WinPort._uses_apache):
(WinPort):
(WinPort._path_to_apache):

LayoutTests:

Add a new Windows XAMPP Apache configuration file for running
the http test suite on Windows.

Reviewed by Alexey Proskuryakov.

* http/conf/apache2.4-httpd-win.conf: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkToolsChangeLog">trunk/Tools/ChangeLog</a></li>
<li><a href="#trunkToolsScriptsrunwebkithttpd">trunk/Tools/Scripts/run-webkit-httpd</a></li>
<li><a href="#trunkToolsScriptswebkitperlhttpdpm">trunk/Tools/Scripts/webkitperl/httpd.pm</a></li>
<li><a href="#trunkToolsScriptswebkitpycommonsystemexecutive_unittestpy">trunk/Tools/Scripts/webkitpy/common/system/executive_unittest.py</a></li>
<li><a href="#trunkToolsScriptswebkitpylayout_testsserversapache_http_serverpy">trunk/Tools/Scripts/webkitpy/layout_tests/servers/apache_http_server.py</a></li>
<li><a href="#trunkToolsScriptswebkitpylayout_testsservershttp_server_basepy">trunk/Tools/Scripts/webkitpy/layout_tests/servers/http_server_base.py</a></li>
<li><a href="#trunkToolsScriptswebkitpyportbasepy">trunk/Tools/Scripts/webkitpy/port/base.py</a></li>
<li><a href="#trunkToolsScriptswebkitpyportport_testcasepy">trunk/Tools/Scripts/webkitpy/port/port_testcase.py</a></li>
<li><a href="#trunkToolsScriptswebkitpyportwinpy">trunk/Tools/Scripts/webkitpy/port/win.py</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestshttpconfapache24httpdwinconf">trunk/LayoutTests/http/conf/apache2.4-httpd-win.conf</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/LayoutTests/ChangeLog        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -1,3 +1,17 @@
</span><ins>+2015-01-30  Brent Fulgham  &lt;bfulgham@apple.com&gt;
+
+        [Win] Switch to Apache on Windows
+        https://bugs.webkit.org/show_bug.cgi?id=141060
+
+        Reviewed by Alexey Proskuryakov.
+
+        Add a new Windows XAMPP Apache configuration file for running
+        the http test suite on Windows.
+
+        Reviewed by Alexey Proskuryakov.
+
+        * http/conf/apache2.4-httpd-win.conf: Added.
+
</ins><span class="cx"> 2015-01-29  Chris Dumez  &lt;cdumez@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Unreviewed. Further rebaselining after r179368.
</span></span></pre></div>
<a id="trunkLayoutTestshttpconfapache24httpdwinconf"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/http/conf/apache2.4-httpd-win.conf (0 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/http/conf/apache2.4-httpd-win.conf                                (rev 0)
+++ trunk/LayoutTests/http/conf/apache2.4-httpd-win.conf        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -0,0 +1,164 @@
</span><ins>+ServerRoot &quot;C:/xampp/apache&quot;
+
+# Mutex file:/tmp/WebKit
+PidFile &quot;/tmp/WebKit/httpd.pid&quot;
+#ScoreBoardFile &quot;/tmp/WebKit/httpd.scoreboard&quot;
+
+Timeout 300
+KeepAlive On
+MaxKeepAliveRequests 100
+KeepAliveTimeout 15
+
+# LoadModule unixd_module libexec/apache/mod_unixd.so 
+LoadModule access_compat_module modules/mod_access_compat.so
+LoadModule authn_core_module modules/mod_authn_core.so
+LoadModule authz_core_module modules/mod_authz_core.so
+LoadModule authz_host_module modules/mod_authz_host.so
+LoadModule include_module modules/mod_include.so
+LoadModule log_config_module modules/mod_log_config.so
+LoadModule headers_module modules/mod_headers.so
+LoadModule ssl_module modules/mod_ssl.so
+LoadModule mime_module modules/mod_mime.so
+LoadModule asis_module modules/mod_asis.so
+LoadModule cgi_module modules/mod_cgi.so
+LoadModule negotiation_module modules/mod_negotiation.so
+#LoadModule imagemap_module modules/mod_imagemap.so
+LoadModule actions_module modules/mod_actions.so
+LoadModule alias_module modules/mod_alias.so
+LoadModule rewrite_module modules/mod_rewrite.so
+LoadFile &quot;C:/xampp/php/php5ts.dll&quot;
+LoadFile &quot;C:/xampp/php/libpq.dll&quot;
+LoadModule php5_module &quot;C:/xampp/php/php5apache2_4.dll&quot;
+
+
+ServerName 127.0.0.1
+
+&lt;Directory /&gt;
+    Options Indexes FollowSymLinks MultiViews ExecCGI Includes
+    AllowOverride All
+    Order allow,deny
+    Allow from all
+&lt;/Directory&gt;
+
+AccessFileName .htaccess
+
+&lt;Files ~ &quot;^\.([Hh][Tt]|[Dd][Ss]_[Ss])&quot;&gt;
+    Order allow,deny
+    Deny from all
+    Satisfy All
+&lt;/Files&gt;
+
+UseCanonicalName On
+HostnameLookups Off
+
+ScriptInterpreterSource Registry-Strict
+# When using the above setting, specify the path to the Perl binary
+# using the registry keys below:
+# [HKEY_CLASSES_ROOT\.pl\Shell\ExecCGI\Command] @=&quot;c:\\PATH\TO\perl\\bin\\perl.exe&quot;
+# HKEY_CLASSES_ROOT\.cgi\Shell\ExecCGI\Command] @=&quot;c:\\PATH\TO\perl\\bin\\perl.exe&quot;
+
+LogLevel warn
+
+ErrorLog &quot;C:\xampp\apache\logs\error_log.txt&quot;
+
+LogFormat &quot;%h %l %u %t \&quot;%r\&quot; %&gt;s %b \&quot;%{Referer}i\&quot; \&quot;%{User-Agent}i\&quot;&quot; combined
+LogFormat &quot;%h %l %u %t \&quot;%r\&quot; %&gt;s %b %D&quot; common
+LogFormat &quot;%{Referer}i -&gt; %U&quot; referer
+LogFormat &quot;%{User-agent}i&quot; agent
+
+ServerSignature On
+
+&lt;IfModule mod_alias.c&gt;
+&lt;/IfModule&gt;
+
+&lt;IfModule mod_mime.c&gt;
+    AddLanguage da .dk
+    AddLanguage nl .nl
+    AddLanguage en .en
+    AddLanguage et .ee
+    AddLanguage fr .fr
+    AddLanguage de .de
+    AddLanguage el .el
+    AddLanguage he .he
+    AddCharset ISO-8859-8 .iso8859-8
+    AddLanguage it .it
+    AddLanguage ja .ja
+    AddCharset ISO-2022-JP .jis
+    AddLanguage kr .kr
+    AddCharset ISO-2022-KR .iso-kr
+    AddLanguage nn .nn
+    AddLanguage no .no
+    AddLanguage pl .po
+    AddCharset ISO-8859-2 .iso-pl
+    AddLanguage pt .pt
+    AddLanguage pt-br .pt-br
+    AddLanguage ltz .lu
+    AddLanguage ca .ca
+    AddLanguage es .es
+    AddLanguage sv .sv
+    AddLanguage cs .cz .cs
+    AddLanguage ru .ru
+    AddLanguage zh-TW .zh-tw
+    AddCharset Big5         .Big5    .big5
+    AddCharset WINDOWS-1251 .cp-1251
+    AddCharset CP866        .cp866
+    AddCharset ISO-8859-5   .iso-ru
+    AddCharset KOI8-R       .koi8-r
+    AddCharset UCS-2        .ucs2
+    AddCharset UCS-4        .ucs4
+    AddCharset UTF-8        .utf8
+
+    &lt;IfModule mod_negotiation.c&gt;
+        LanguagePriority en da nl et fr de el it ja kr no pl pt pt-br ru ltz ca es sv tw
+    &lt;/IfModule&gt;
+
+    AddType application/x-tar .tgz
+
+    AddEncoding x-compress .Z
+    AddEncoding x-gzip .gz .tgz
+
+    AddHandler cgi-script .cgi .pl
+
+    AddType text/html .shtml
+    AddHandler server-parsed .shtml
+
+    AddHandler send-as-is asis
+&lt;/IfModule&gt;
+
+&lt;IfModule mod_php5.c&gt;
+    PHPIniDir &quot;C:/xampp/php&quot;
+
+    AddType application/x-httpd-php .php
+    AddType application/x-httpd-php .bat
+    AddType application/x-httpd-php-source .phps
+
+    &lt;IfModule mod_dir.c&gt;
+        DirectoryIndex index.html index.php
+    &lt;/IfModule&gt;
+
+    php_flag log_errors on
+    php_flag short_open_tag on
+&lt;/IfModule&gt;
+
+&lt;IfModule mod_rewrite.c&gt;
+    RewriteEngine On
+    RewriteCond %{REQUEST_METHOD} ^TRACE
+    RewriteRule .* - [F]
+&lt;/IfModule&gt;
+
+# Secure (SSL/TLS) connections
+#Include conf/extra/httpd-ssl.conf
+#
+# Note: The following must must be present to support
+#       starting without SSL on platforms with no /dev/random equivalent
+#       but a statically compiled-in mod_ssl.
+#
+&lt;IfModule ssl_module&gt;
+SSLRandomSeed startup builtin
+SSLRandomSeed connect builtin
+&lt;/IfModule&gt;
+
+&lt;VirtualHost *:8443&gt;
+    ServerName 127.0.0.1
+    SSLEngine On
+&lt;/VirtualHost&gt;
</ins></span></pre></div>
<a id="trunkToolsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Tools/ChangeLog (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/ChangeLog        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/ChangeLog        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -1,3 +1,36 @@
</span><ins>+2015-01-30  Brent Fulgham  &lt;bfulgham@apple.com&gt;
+
+        [Win] Switch to Apache on Windows
+        https://bugs.webkit.org/show_bug.cgi?id=141060
+
+        Reviewed by Alexey Proskuryakov.
+
+        Update our scripts under Windows (and Cygwin) to locate and use
+        the XAMPP installation of Apache for running tests.
+
+        * Scripts/run-webkit-httpd:
+        * Scripts/webkitperl/httpd.pm:
+        (getHTTPDPath):
+        (getDefaultConfigForTestDirectory):
+        (getHTTPDConfigPathForTestDirectory):
+        * Scripts/webkitpy/common/system/executive_unittest.py:
+        (ExecutiveTest.serial_test_kill_process):
+        * Scripts/webkitpy/layout_tests/servers/apache_http_server.py:
+        (LayoutTestApacheHttpd.__init__):
+        (LayoutTestApacheHttpd._get_apache_config_file_path):
+        (LayoutTestApacheHttpd._stop_running_server):
+        * Scripts/webkitpy/layout_tests/servers/http_server_base.py:
+        (HttpServerBase._is_server_running_on_all_ports):
+        * Scripts/webkitpy/port/base.py:
+        (Port._apache_config_file_name_for_platform):
+        * Scripts/webkitpy/port/port_testcase.py:
+        (test_apache_config_file_name_for_platform):
+        * Scripts/webkitpy/port/win.py:
+        (WinPort.show_results_html_file):
+        (WinPort._uses_apache):
+        (WinPort):
+        (WinPort._path_to_apache):
+
</ins><span class="cx"> 2015-01-29  Alexey Proskuryakov  &lt;ap@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Built result takes too long to be compressed on bots
</span></span></pre></div>
<a id="trunkToolsScriptsrunwebkithttpd"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/run-webkit-httpd (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/run-webkit-httpd        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/run-webkit-httpd        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -1,6 +1,6 @@
</span><span class="cx"> #!/usr/bin/perl
</span><span class="cx"> 
</span><del>-# Copyright (C) 2005, 2006, 2007 Apple Inc.  All rights reserved.
</del><ins>+# Copyright (C) 2005, 2006, 2007, 2015 Apple Inc.  All rights reserved.
</ins><span class="cx"> # Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com)
</span><span class="cx"> # Copyright (C) 2011 Research In Motion Limited. All rights reserved.
</span><span class="cx"> #
</span><span class="lines">@@ -83,8 +83,6 @@
</span><span class="cx"> 
</span><span class="cx"> my @args = (
</span><span class="cx">     &quot;-C&quot;, &quot;Listen $listen&quot;,
</span><del>-    &quot;-c&quot;, &quot;CustomLog |/usr/bin/tee common&quot;,
-    &quot;-c&quot;, &quot;ErrorLog |/usr/bin/tee&quot;,
</del><span class="cx">     # Run in single-process mode, do not detach from the controlling terminal.
</span><span class="cx">     &quot;-X&quot;,
</span><span class="cx">     # Disable Keep-Alive support. Makes testing in multiple browsers easier (no need to wait
</span><span class="lines">@@ -92,6 +90,11 @@
</span><span class="cx">     &quot;-c&quot;, &quot;KeepAlive off&quot;
</span><span class="cx"> );
</span><span class="cx"> 
</span><ins>+if (!isAnyWindows()) {
+    push(@args, &quot;-c&quot;, &quot;CustomLog |/usr/bin/tee common&quot;);
+    push(@args, &quot;-c&quot;, &quot;ErrorLog |/usr/bin/tee&quot;);
+}
+
</ins><span class="cx"> my @defaultArgs = getDefaultConfigForTestDirectory($testDirectory);
</span><span class="cx"> @args = (@defaultArgs, @args);
</span><span class="cx"> openHTTPD(@args);
</span></span></pre></div>
<a id="trunkToolsScriptswebkitperlhttpdpm"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitperl/httpd.pm (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitperl/httpd.pm        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/webkitperl/httpd.pm        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -1,4 +1,4 @@
</span><del>-# Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved
</del><ins>+# Copyright (C) 2005, 2006, 2007, 2008, 2009, 2015 Apple Inc. All rights reserved
</ins><span class="cx"> # Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com)
</span><span class="cx"> # Copyright (C) 2010 Andras Becsi (abecsi@inf.u-szeged.hu), University of Szeged
</span><span class="cx"> # Copyright (C) 2011 Research In Motion Limited. All rights reserved.
</span><span class="lines">@@ -36,6 +36,7 @@
</span><span class="cx"> use File::Path;
</span><span class="cx"> use File::Spec;
</span><span class="cx"> use File::Spec::Functions;
</span><ins>+use File::Temp qw(tempdir);
</ins><span class="cx"> use IPC::Open2;
</span><span class="cx"> 
</span><span class="cx"> use webkitdirs;
</span><span class="lines">@@ -57,6 +58,11 @@
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> my $tmpDir = &quot;/tmp&quot;;
</span><ins>+if (isAnyWindows()) {
+   $tmpDir = tempdir(CLEANUP =&gt; 0);
+   $tmpDir = `cygpath -w $tmpDir`;
+   chomp($tmpDir);
+}
</ins><span class="cx"> my $httpdPidDir = File::Spec-&gt;catfile($tmpDir, &quot;WebKit&quot;);
</span><span class="cx"> my $httpdPidFile = File::Spec-&gt;catfile($httpdPidDir, &quot;httpd.pid&quot;);
</span><span class="cx"> my $httpdPid;
</span><span class="lines">@@ -72,6 +78,8 @@
</span><span class="cx">     my $httpdPath;
</span><span class="cx">     if (isDebianBased()) {
</span><span class="cx">         $httpdPath = &quot;/usr/sbin/apache2&quot;;
</span><ins>+    } elsif (isAnyWindows()) {
+        $httpdPath = &quot;httpd&quot;;
</ins><span class="cx">     } else {
</span><span class="cx">         $httpdPath = &quot;/usr/sbin/httpd&quot;;
</span><span class="cx">     }
</span><span class="lines">@@ -97,11 +105,16 @@
</span><span class="cx">     my ($testDirectory) = @_;
</span><span class="cx">     die &quot;No test directory has been specified.&quot; unless ($testDirectory);
</span><span class="cx"> 
</span><ins>+    if (isAnyWindows()) {
+        $testDirectory = `cygpath -w \&quot;$testDirectory\&quot;`;
+        chomp($testDirectory);
+    }
+
</ins><span class="cx">     my $httpdConfig = getHTTPDConfigPathForTestDirectory($testDirectory);
</span><del>-    my $documentRoot = &quot;$testDirectory/http/tests&quot;;
-    my $jsTestResourcesDirectory = $testDirectory . &quot;/resources&quot;;
-    my $mediaResourcesDirectory = $testDirectory . &quot;/media&quot;;
-    my $typesConfig = &quot;$testDirectory/http/conf/mime.types&quot;;
</del><ins>+    my $documentRoot = File::Spec-&gt;catfile($testDirectory, &quot;http&quot;, &quot;tests&quot;);
+    my $jsTestResourcesDirectory = File::Spec-&gt;catfile($testDirectory, &quot;resources&quot;);
+    my $mediaResourcesDirectory = File::Spec-&gt;catfile($testDirectory, &quot;media&quot;);
+    my $typesConfig = File::Spec-&gt;catfile($testDirectory, &quot;http&quot;, &quot;conf&quot;, &quot;mime.types&quot;);
</ins><span class="cx">     my $httpdLockFile = File::Spec-&gt;catfile($httpdPidDir, &quot;httpd.lock&quot;);
</span><span class="cx">     my $httpdScoreBoardFile = File::Spec-&gt;catfile($httpdPidDir, &quot;httpd.scoreboard&quot;);
</span><span class="cx"> 
</span><span class="lines">@@ -113,19 +126,20 @@
</span><span class="cx">         &quot;-c&quot;, &quot;Alias /media-resources \&quot;$mediaResourcesDirectory\&quot;&quot;,
</span><span class="cx">         &quot;-c&quot;, &quot;TypesConfig \&quot;$typesConfig\&quot;&quot;,
</span><span class="cx">         # Apache wouldn't run CGIs with permissions==700 otherwise
</span><del>-        &quot;-c&quot;, &quot;User \&quot;#$&lt;\&quot;&quot;,
</del><span class="cx">         &quot;-c&quot;, &quot;PidFile \&quot;$httpdPidFile\&quot;&quot;,
</span><span class="cx">         &quot;-c&quot;, &quot;ScoreBoardFile \&quot;$httpdScoreBoardFile\&quot;&quot;,
</span><span class="cx">     );
</span><span class="cx"> 
</span><ins>+    if (!isAnyWindows()) {
+        push(@httpdArgs, &quot;-c&quot;, &quot;User \&quot;#$&lt;\&quot;&quot;);
+    }
+
</ins><span class="cx">     if (getApacheVersion() eq &quot;2.2&quot;) {
</span><span class="cx">         push(@httpdArgs, &quot;-c&quot;, &quot;LockFile \&quot;$httpdLockFile\&quot;&quot;);
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    # FIXME: Enable this on Windows once &lt;rdar://problem/5345985&gt; is fixed
-    # The version of Apache we use with Cygwin does not support SSL
-    my $sslCertificate = &quot;$testDirectory/http/conf/webkit-httpd.pem&quot;;
-    push(@httpdArgs, &quot;-c&quot;, &quot;SSLCertificateFile \&quot;$sslCertificate\&quot;&quot;) unless isCygwin();
</del><ins>+    my $sslCertificate = File::Spec-&gt;catfile($testDirectory, &quot;http&quot;, &quot;conf&quot;, &quot;webkit-httpd.pem&quot;);
+    push(@httpdArgs, &quot;-c&quot;, &quot;SSLCertificateFile \&quot;$sslCertificate\&quot;&quot;);
</ins><span class="cx"> 
</span><span class="cx">     return @httpdArgs;
</span><span class="cx"> 
</span><span class="lines">@@ -142,13 +156,7 @@
</span><span class="cx">     my $apacheVersion = getApacheVersion();
</span><span class="cx"> 
</span><span class="cx">     if (isCygwin()) {
</span><del>-        my $libPHP4DllPath = &quot;/usr/lib/apache/libphp4.dll&quot;;
-        # FIXME: run-webkit-tests should not modify the user's system, especially not in this method!
-        unless (-x $libPHP4DllPath) {
-            copy(&quot;$httpdConfDirectory/libphp4.dll&quot;, $libPHP4DllPath);
-            chmod(0755, $libPHP4DllPath);
-        }
-        $httpdConfig = &quot;cygwin-httpd.conf&quot;;  # This is an apache 1.3 config.
</del><ins>+        $httpdConfig = &quot;apache$apacheVersion-httpd-win.conf&quot;;
</ins><span class="cx">     } elsif (isDebianBased()) {
</span><span class="cx">         $httpdConfig = &quot;debian-httpd-$apacheVersion.conf&quot;;
</span><span class="cx">     } elsif (isFedoraBased()) {
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpycommonsystemexecutive_unittestpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/common/system/executive_unittest.py (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/common/system/executive_unittest.py        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/webkitpy/common/system/executive_unittest.py        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -177,7 +177,8 @@
</span><span class="cx">         elif sys.platform == &quot;cygwin&quot;:
</span><span class="cx">             # FIXME: https://bugs.webkit.org/show_bug.cgi?id=98196
</span><span class="cx">             # cygwin seems to give us either SIGABRT or SIGKILL
</span><del>-            self.assertIn(process.wait(), (-signal.SIGABRT, -signal.SIGKILL))
</del><ins>+            # Native Windows (via Cygwin) returns ENOTBLK (-15)
+            self.assertIn(process.wait(), (-signal.SIGABRT, -signal.SIGKILL, -15))
</ins><span class="cx">         else:
</span><span class="cx">             expected_exit_code = -signal.SIGTERM
</span><span class="cx">             self.assertEqual(process.wait(), expected_exit_code)
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpylayout_testsserversapache_http_serverpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/layout_tests/servers/apache_http_server.py (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/layout_tests/servers/apache_http_server.py        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/servers/apache_http_server.py        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -1,3 +1,4 @@
</span><ins>+# Copyright (C) 2015 Apple Inc. All rights reserved.
</ins><span class="cx"> # Copyright (C) 2011 Google Inc. All rights reserved.
</span><span class="cx"> #
</span><span class="cx"> # Redistribution and use in source and binary forms, with or without
</span><span class="lines">@@ -60,6 +61,13 @@
</span><span class="cx">         self._pid_file = self._filesystem.join(self._runtime_path, '%s.pid' % self._name)
</span><span class="cx"> 
</span><span class="cx">         test_dir = self._port_obj.layout_tests_dir()
</span><ins>+
+        if port_obj.host.platform.is_win():
+            # Convert to MSDOS file naming:
+            output_dir = output_dir.replace(&quot;/cygdrive/c&quot;, &quot;C:&quot;)
+            test_dir = test_dir.replace(&quot;/cygdrive/c&quot;, &quot;C:&quot;)
+            self._pid_file = self._pid_file.replace(&quot;/tmp&quot;, &quot;C:/cygwin/tmp&quot;)
+
</ins><span class="cx">         js_test_resources_dir = self._filesystem.join(test_dir, &quot;resources&quot;)
</span><span class="cx">         media_resources_dir = self._filesystem.join(test_dir, &quot;media&quot;)
</span><span class="cx">         mime_types_path = self._filesystem.join(test_dir, &quot;http&quot;, &quot;conf&quot;, &quot;mime.types&quot;)
</span><span class="lines">@@ -79,10 +87,12 @@
</span><span class="cx">             '-c', &quot;\'TypesConfig \&quot;%s\&quot;\'&quot; % mime_types_path,
</span><span class="cx">             '-c', &quot;\'CustomLog \&quot;%s\&quot; common\'&quot; % access_log,
</span><span class="cx">             '-c', &quot;\'ErrorLog \&quot;%s\&quot;\'&quot; % error_log,
</span><del>-            '-C', &quot;\'User \&quot;%s\&quot;\'&quot; % os.environ.get(&quot;USERNAME&quot;, os.environ.get(&quot;USER&quot;, &quot;&quot;)),
</del><span class="cx">             '-c', &quot;\'PidFile %s'&quot; % self._pid_file,
</span><span class="cx">             '-k', &quot;start&quot;]
</span><span class="cx"> 
</span><ins>+        if not port_obj.host.platform.is_win():
+            start_cmd.extend(['-C', &quot;\'User \&quot;%s\&quot;\'&quot; % os.environ.get(&quot;USERNAME&quot;, os.environ.get(&quot;USER&quot;, &quot;&quot;))])
+
</ins><span class="cx">         enable_ipv6 = self._port_obj.http_server_supports_ipv6()
</span><span class="cx">         # Perform part of the checks Apache's APR does when trying to listen to
</span><span class="cx">         # a specific host/port. This allows us to avoid trying to listen to
</span><span class="lines">@@ -141,6 +151,9 @@
</span><span class="cx">         # FIXME: Why do we need to copy the config file since we're not modifying it?
</span><span class="cx">         self._filesystem.write_text_file(httpd_config_copy, httpd_conf)
</span><span class="cx"> 
</span><ins>+        if self._port_obj.host.platform.is_win():
+            httpd_config_copy = httpd_config_copy.replace(&quot;/cygdrive/c&quot;, &quot;C:&quot;)
+
</ins><span class="cx">         return httpd_config_copy
</span><span class="cx"> 
</span><span class="cx">     def _spawn_process(self):
</span><span class="lines">@@ -159,11 +172,17 @@
</span><span class="cx">     def _stop_running_server(self):
</span><span class="cx">         # If apache was forcefully killed, the pid file will not have been deleted, so check
</span><span class="cx">         # that the process specified by the pid_file no longer exists before deleting the file.
</span><del>-        if self._pid and not self._executive.check_running_pid(self._pid):
</del><ins>+        if self._pid and not self._port_obj.host.platform.is_win() and not self._executive.check_running_pid(self._pid):
</ins><span class="cx">             self._filesystem.remove(self._pid_file)
</span><span class="cx">             return
</span><span class="cx"> 
</span><span class="cx">         retval, err = self._run(self._stop_cmd)
</span><ins>+
+        # Windows httpd outputs shutdown status in stderr:
+        if self._port_obj.host.platform.is_win() and not retval and len(err):
+            _log.debug('Shutdown: %s' % err)
+            err = &quot;&quot;
+
</ins><span class="cx">         if retval or len(err):
</span><span class="cx">             raise http_server_base.ServerError('Failed to stop %s: %s' % (self._name, err))
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpylayout_testsservershttp_server_basepy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/layout_tests/servers/http_server_base.py (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/layout_tests/servers/http_server_base.py        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/servers/http_server_base.py        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -179,7 +179,7 @@
</span><span class="cx"> 
</span><span class="cx">     def _is_server_running_on_all_ports(self):
</span><span class="cx">         &quot;&quot;&quot;Returns whether the server is running on all the desired ports.&quot;&quot;&quot;
</span><del>-        if not self._executive.check_running_pid(self._pid):
</del><ins>+        if not self._port_obj.host.platform.is_win() and not self._executive.check_running_pid(self._pid):
</ins><span class="cx">             _log.debug(&quot;Server isn't running at all&quot;)
</span><span class="cx">             raise ServerError(&quot;Server exited&quot;)
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpyportbasepy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/port/base.py (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/port/base.py        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/webkitpy/port/base.py        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -1090,8 +1090,8 @@
</span><span class="cx"> 
</span><span class="cx">     # We pass sys_platform into this method to make it easy to unit test.
</span><span class="cx">     def _apache_config_file_name_for_platform(self, sys_platform):
</span><del>-        if sys_platform == 'cygwin':
-            return 'cygwin-httpd.conf'  # CYGWIN is the only platform to still use Apache 1.3.
</del><ins>+        if sys_platform == 'cygwin' or sys_platform == 'win32':
+            return 'apache' + self._apache_version() + '-httpd-win.conf'
</ins><span class="cx">         if sys_platform.startswith('linux'):
</span><span class="cx">             if self._is_redhat_based():
</span><span class="cx">                 return 'fedora-httpd-' + self._apache_version() + '.conf'
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpyportport_testcasepy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/port/port_testcase.py (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/port/port_testcase.py        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/webkitpy/port/port_testcase.py        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -542,7 +542,7 @@
</span><span class="cx">     def test_apache_config_file_name_for_platform(self):
</span><span class="cx">         port = TestWebKitPort()
</span><span class="cx">         port._apache_version = lambda: '2.2'
</span><del>-        self._assert_config_file_for_platform(port, 'cygwin', 'cygwin-httpd.conf')
</del><ins>+        self._assert_config_file_for_platform(port, 'cygwin', 'apache2.2-httpd-win.conf')
</ins><span class="cx"> 
</span><span class="cx">         self._assert_config_file_for_platform(port, 'linux2', 'apache2.2-httpd.conf')
</span><span class="cx">         self._assert_config_file_for_platform(port, 'linux3', 'apache2.2-httpd.conf')
</span><span class="lines">@@ -557,7 +557,7 @@
</span><span class="cx">         self._assert_config_file_for_platform(port, 'linux2', 'debian-httpd-2.2.conf')
</span><span class="cx"> 
</span><span class="cx">         self._assert_config_file_for_platform(port, 'mac', 'apache2.2-httpd.conf')
</span><del>-        self._assert_config_file_for_platform(port, 'win32', 'apache2.2-httpd.conf')  # win32 isn't a supported sys.platform.  AppleWin/WinCairo ports all use cygwin.
</del><ins>+        self._assert_config_file_for_platform(port, 'win32', 'apache2.2-httpd-win.conf')  # win32 isn't a supported sys.platform.  AppleWin/WinCairo ports all use cygwin.
</ins><span class="cx">         self._assert_config_file_for_platform(port, 'barf', 'apache2.2-httpd.conf')
</span><span class="cx"> 
</span><span class="cx">     def test_path_to_apache_config_file(self):
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpyportwinpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/port/win.py (179404 => 179405)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/port/win.py        2015-01-30 18:08:59 UTC (rev 179404)
+++ trunk/Tools/Scripts/webkitpy/port/win.py        2015-01-30 18:26:36 UTC (rev 179405)
</span><span class="lines">@@ -99,10 +99,6 @@
</span><span class="cx">     def show_results_html_file(self, results_filename):
</span><span class="cx">         self._run_script('run-safari', [abspath_to_uri(SystemHost().platform, results_filename)])
</span><span class="cx"> 
</span><del>-    # FIXME: webkitperl/httpd.pm installs /usr/lib/apache/libphp4.dll on cycwin automatically
-    # as part of running old-run-webkit-tests.  That's bad design, but we may need some similar hack.
-    # We might use setup_environ_for_server for such a hack (or modify apache_http_server.py).
-
</del><span class="cx">     def _runtime_feature_list(self):
</span><span class="cx">         supported_features_command = [self._path_to_driver(), '--print-supported-features']
</span><span class="cx">         try:
</span><span class="lines">@@ -117,10 +113,17 @@
</span><span class="cx">             return None
</span><span class="cx">         return match_object.group('features_string').split(' ')
</span><span class="cx"> 
</span><del>-    # Note: These are based on the stock Cygwin locations for these files.
</del><ins>+    # Note: These are based on the stock XAMPP locations for these files.
</ins><span class="cx">     def _uses_apache(self):
</span><del>-        return False
</del><ins>+        return True
</ins><span class="cx"> 
</span><ins>+    def _path_to_apache(self):
+        httpdPath = &quot;C:/xampp/apache/bin/httpd.exe&quot;
+        if self._filesystem.exists(httpdPath):
+            return httpdPath
+        _log.error(&quot;Could not find apache. Not installed or unknown path.&quot;)
+        return None
+
</ins><span class="cx">     def _path_to_lighttpd(self):
</span><span class="cx">         return &quot;/usr/sbin/lighttpd&quot;
</span><span class="cx"> 
</span></span></pre>
</div>
</div>

</body>
</html>