Bug 134745

Summary: [Win] Implement auto-version as a Perl program
Product: WebKit Reporter: Brent Fulgham <bfulgham>
Component: Tools / TestsAssignee: Brent Fulgham <bfulgham>
Status: RESOLVED FIXED    
Severity: Normal CC: bfulgham, ddkilzer, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: PC   
OS: All   
Attachments:
Description Flags
Patch
none
Patch ddkilzer: review+

Description Brent Fulgham 2014-07-08 15:19:40 PDT
Reduce reliance on Cygwin and Bash behaviors by writing the 'auto-version' utility as a Perl script, rather than a bash script. This will make it easier to drive the build using native Windows-based utilities rather than requiring Cygwin.
Comment 1 Brent Fulgham 2014-07-08 15:24:52 PDT
Created attachment 234600 [details]
Patch
Comment 2 Radar WebKit Bug Importer 2014-07-08 15:25:09 PDT
<rdar://problem/17597791>
Comment 3 Radar WebKit Bug Importer 2014-07-08 15:25:11 PDT
<rdar://problem/17597801>
Comment 4 Brent Fulgham 2014-07-08 16:21:47 PDT
Created attachment 234605 [details]
Patch
Comment 5 David Kilzer (:ddkilzer) 2014-07-08 16:55:44 PDT
Comment on attachment 234605 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=234605&action=review

r=me

> WebKitLibraries/win/tools/scripts/auto-version.pl:98
> +my $VARIANT_VERSION =$BUILD_TINY_VERSION;

Nit:  Space after '='.

> WebKitLibraries/win/tools/scripts/auto-version.pl:104
> +if (!defined $ENVIRONMENT_VERSION) {

Technically, the equivalent to "-z" would be:

if (!$ENVIRONMENT_VERSION) {

Not sure if that matters.  (Defined returns true if the string is empty, but "!" will not, IIRC.)
Comment 6 Brent Fulgham 2014-07-08 16:58:53 PDT
(In reply to comment #5)
> (From update of attachment 234605 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=234605&action=review
> 
> r=me
> 
> > WebKitLibraries/win/tools/scripts/auto-version.pl:98
> > +my $VARIANT_VERSION =$BUILD_TINY_VERSION;
> 
> Nit:  Space after '='.

Done.

> > WebKitLibraries/win/tools/scripts/auto-version.pl:104
> > +if (!defined $ENVIRONMENT_VERSION) {
> 
> Technically, the equivalent to "-z" would be:
> 
> if (!$ENVIRONMENT_VERSION) {
> 
> Not sure if that matters.  (Defined returns true if the string is empty, but "!" will not, IIRC.)

I'll switch to your version. It may not matter, but I'd like to be as close to the bash version as possible in behavior.
Comment 7 Brent Fulgham 2014-07-08 16:59:35 PDT
This EWS bot seems broken. The file builds fine locally. I will land it and watch the bots and correct as necessary.
Comment 8 Brent Fulgham 2014-07-08 17:02:38 PDT
Committed r170905: <http://trac.webkit.org/changeset/170905>