WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
55811
Fix webkit-patch on Win32 python
https://bugs.webkit.org/show_bug.cgi?id=55811
Summary
Fix webkit-patch on Win32 python
Patrick R. Gansterer
Reported
2011-03-04 18:09:05 PST
Fix webkit-patch on Win32 python
Attachments
Patch
(15.94 KB, patch)
2011-03-04 18:15 PST
,
Patrick R. Gansterer
no flags
Details
Formatted Diff
Diff
Patch
(1.34 KB, patch)
2011-04-02 08:56 PDT
,
Patrick R. Gansterer
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Patrick R. Gansterer
Comment 1
2011-03-04 18:15:18 PST
Created
attachment 84838
[details]
Patch
Eric Seidel (no email)
Comment 2
2011-03-07 19:06:55 PST
Comment on
attachment 84838
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=84838&action=review
> Tools/Scripts/webkitpy/common/config/ports.py:43 > + # Win32 perl needs a slash here to determinate the correct module directories. > + return "Tools/Scripts/" + script_name
Are you sure this is really what we want? I would suspect this is used in other places which might want a \ instead on windows.
> Tools/Scripts/webkitpy/common/config/ports.py:92 > + command = [cls.perl_executable(), cls.script_path("build-webkit")]
This is kinda sad. To encode the perl vs. python in the caller. I take it there is no way to run these under a shell in naked win32?
> Tools/Scripts/webkitpy/tool/steps/preparechangelog.py:64 > + args = ["perl", self._tool.port().script_path("prepare-ChangeLog")]
Why not perl_executable() here? Don't we expose both types of port objects on tool (I know, it's sad that we have 2 types!)
> Tools/Scripts/webkitpy/tool/steps/preparechangelogfordepsroll.py:37 > + self._run_script("perl", "prepare-ChangeLog")
Seems prepare-changeLog should just be one of the commands exposed on the Port object.
Patrick R. Gansterer
Comment 3
2011-03-07 21:53:46 PST
Comment on
attachment 84838
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=84838&action=review
>> Tools/Scripts/webkitpy/common/config/ports.py:43 >> + return "Tools/Scripts/" + script_name > > Are you sure this is really what we want? I would suspect this is used in other places which might want a \ instead on windows.
I don't like this too, but if i keep the backslash Win32 perl fail, because it can't find VCSUtils module. I'll try if passing the include directory via command line works.
>> Tools/Scripts/webkitpy/common/config/ports.py:92 >> + command = [cls.perl_executable(), cls.script_path("build-webkit")] > > This is kinda sad. To encode the perl vs. python in the caller. I take it there is no way to run these under a shell in naked win32?
Nope :-(, you find the same change in the previous "Win32 fixes".
Adam Barth
Comment 4
2011-03-07 21:58:14 PST
Maybe it's not worth making webkit-patch work on Win32 Python? These changes seem bad.
Dirk Pranke
Comment 5
2011-03-07 22:37:37 PST
Comment on
attachment 84838
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=84838&action=review
>>> Tools/Scripts/webkitpy/common/config/ports.py:43 >>> + return "Tools/Scripts/" + script_name >> >> Are you sure this is really what we want? I would suspect this is used in other places which might want a \ instead on windows. > > I don't like this too, but if i keep the backslash Win32 perl fail, because it can't find VCSUtils module. I'll try if passing the include directory via command line works.
At the very least this should probably be protected by an if platform == 'win32' sort of thing. Although, ironically, the code will work on all the non-win32 platforms as is.
>>> Tools/Scripts/webkitpy/common/config/ports.py:92 >>> + command = [cls.perl_executable(), cls.script_path("build-webkit")] >> >> This is kinda sad. To encode the perl vs. python in the caller. I take it there is no way to run these under a shell in naked win32? > > Nope :-(, you find the same change in the previous "Win32 fixes".
I suggest that we revamp this in a way such that it could be overridden in a port-specific manner. Maybe you need a routine that just takes the basename of the script and returns a list of arguments. The default implementation could return list(script_path(X)) and the win32 version could return list(lookup_interpreter_for(X), script_path(X)). Or, it could even figure out the interpreter by opening the file and reading the first line ...
Patrick R. Gansterer
Comment 6
2011-04-02 08:56:15 PDT
Created
attachment 87976
[details]
Patch
Eric Seidel (no email)
Comment 7
2011-04-03 04:51:59 PDT
Comment on
attachment 87976
[details]
Patch OK. Assuming it works. :)
WebKit Review Bot
Comment 8
2011-06-18 13:03:36 PDT
Comment on
attachment 87976
[details]
Patch Clearing flags on attachment: 87976 Committed
r89201
: <
http://trac.webkit.org/changeset/89201
>
WebKit Review Bot
Comment 9
2011-06-18 13:03:41 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug