Bug 29802 - [Qt] Make build-webkit script work on Windows
Summary: [Qt] Make build-webkit script work on Windows
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Windows XP
: P2 Normal
Assignee: Nobody
URL:
Keywords: Qt
Depends on:
Blocks: 29656
  Show dependency treegraph
 
Reported: 2009-09-28 04:38 PDT by Csaba Osztrogonác
Modified: 2009-09-29 09:20 PDT (History)
2 users (show)

See Also:


Attachments
proposed patch (1.65 KB, patch)
2009-09-28 04:45 PDT, Csaba Osztrogonác
ddkilzer: review-
Details | Formatted Diff | Diff
proposed patch (1.65 KB, patch)
2009-09-29 05:52 PDT, Csaba Osztrogonác
no flags Details | Formatted Diff | Diff
proposed patch (2.38 KB, patch)
2009-09-29 05:54 PDT, Csaba Osztrogonác
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Csaba Osztrogonác 2009-09-28 04:38:08 PDT
If using cmd.exe shell on Windows, you should give correct parameters to mkdir command.
The mkdir doesn't handle slashes in filepath, but backslashes. And if you pass -p parameter
to mkdir, it will create directory named -p. You can create 1\2\3 directory structure without
any additional switch on Windows.
Comment 1 Csaba Osztrogonác 2009-09-28 04:45:05 PDT
Created attachment 40225 [details]
proposed patch
Comment 2 David Kilzer (:ddkilzer) 2009-09-28 16:49:25 PDT
Comment on attachment 40225 [details]
proposed patch

Overall, this is a nice clean-up!  Comments below.

> +    my $mkdirParentsSwitch = (($^O eq "MSWin32") ? "" : "-p");

A couple things here:

- Instead of making a custom $mkdirParentsSwitch variable, I'd rather see you add an @mkdirArgs variable, and only add the "-p" switch to it if necessary.

my @mkdirArgs;
push @mkdirArgs, "-p" if !isWindows();

- The ($^O eq "MSWin32") test should really be isWindows() instead.  (If you don't want to test for Cygwin, then fix isWindows() to only test for Windows, and update run-webkit-test to use "isCygwin() || isWindows()" in the place where it uses isWindows() now.)

The rest of the changes look good!

r- to address the above issues.
Comment 3 Csaba Osztrogonác 2009-09-29 05:52:18 PDT
Created attachment 40297 [details]
proposed patch

Thx for constructive suggestions, I followed them, and patch updated.
Comment 4 Csaba Osztrogonác 2009-09-29 05:54:07 PDT
Created attachment 40298 [details]
proposed patch
Comment 5 David Kilzer (:ddkilzer) 2009-09-29 09:07:07 PDT
Comment on attachment 40298 [details]
proposed patch

Very nice!  r=me
Comment 6 WebKit Commit Bot 2009-09-29 09:19:42 PDT
Comment on attachment 40298 [details]
proposed patch

Clearing flags on attachment: 40298

Committed r48880: <http://trac.webkit.org/changeset/48880>
Comment 7 WebKit Commit Bot 2009-09-29 09:20:02 PDT
All reviewed patches have been landed.  Closing bug.