WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 197249
[Win] Add flag to enable version information stamping and disable by default.
https://bugs.webkit.org/show_bug.cgi?id=197249
Summary
[Win] Add flag to enable version information stamping and disable by default.
Basuke Suzuki
Reported
2019-04-24 15:07:41 PDT
There's no need to add version information while developing.
Attachments
PATCH
(4.07 KB, patch)
2019-04-24 15:11 PDT
,
Basuke Suzuki
no flags
Details
Formatted Diff
Diff
PATCH
(6.37 KB, patch)
2019-04-25 12:06 PDT
,
Basuke Suzuki
ross.kirsling
: review+
Details
Formatted Diff
Diff
PATCH
(5.75 KB, patch)
2019-04-25 15:29 PDT
,
Basuke Suzuki
no flags
Details
Formatted Diff
Diff
PATCH
(11.34 KB, patch)
2019-04-26 16:49 PDT
,
Basuke Suzuki
no flags
Details
Formatted Diff
Diff
PATCH
(5.52 KB, patch)
2019-04-26 16:50 PDT
,
Basuke Suzuki
no flags
Details
Formatted Diff
Diff
PATCH
(5.48 KB, patch)
2019-04-29 10:32 PDT
,
Basuke Suzuki
no flags
Details
Formatted Diff
Diff
Show Obsolete
(5)
View All
Add attachment
proposed patch, testcase, etc.
Basuke Suzuki
Comment 1
2019-04-24 15:11:12 PDT
Created
attachment 368186
[details]
PATCH
Brent Fulgham
Comment 2
2019-04-24 15:16:52 PDT
What constitutes DEVELOPER_MODE? I don't think it's used in Apple ports.
Basuke Suzuki
Comment 3
2019-04-24 15:35:30 PDT
Oh, that's interesting. I thought this is the standard option for every platform. It is defined in here.
https://github.com/WebKit/webkit/blob/master/Tools/Scripts/webkitdirs.pm#L2203
As you said, AppleWin doesn't use that. What is the best way for our case? We don't have VersionStamper tool. We are basically working on Git repository and not in SVN repository. There's no sense we use this feature.
Ross Kirsling
Comment 4
2019-04-24 16:47:45 PDT
Given that DEVELOPER_MODE is always set for WinCairo, it appears that this patch is only really differentiating between the Windows ports. If so, then what we really want to check is WTF_PLATFORM_WIN_CAIRO, no?
Stephan Szabo
Comment 5
2019-04-24 17:09:36 PDT
Well, theoretically, that flag could be turned on for a particular build of AppleWin port if someone put it into cmake flags, but it'd probably cause other problems. It probably makes more sense to do it explicitly based on port if it's desirable for AppleWin builds to fail if they didn't have the stamper tool.
Basuke Suzuki
Comment 6
2019-04-25 11:21:48 PDT
How about defining USE_VERSION_STAMPER and default to YES on AppleWin and NO on other ports?
Ross Kirsling
Comment 7
2019-04-25 11:25:19 PDT
(In reply to Basuke Suzuki from
comment #6
)
> How about defining USE_VERSION_STAMPER and default to YES on AppleWin and NO > on other ports?
SGTM
Basuke Suzuki
Comment 8
2019-04-25 12:06:30 PDT
Created
attachment 368256
[details]
PATCH Define new flag `USE_VERSION_STAMPER`.
Ross Kirsling
Comment 9
2019-04-25 12:50:00 PDT
Comment on
attachment 368256
[details]
PATCH View in context:
https://bugs.webkit.org/attachment.cgi?id=368256&action=review
r=me with one concern.
> Source/cmake/WebKitFeatures.cmake:224 > + WEBKIT_OPTION_DEFINE(USE_VERSION_STAMPER "Toggle stamping version information during build" PRIVATE OFF)
If this is Windows-specific then I'm not certain whether we should add it here. Note that OptionsGTK.cmake defines a bunch of port-specific options near the top:
https://github.com/WebKit/webkit/blob/master/Source/cmake/OptionsGTK.cmake#L72-L87
Perhaps we should do similarly for OptionsWin?
Basuke Suzuki
Comment 10
2019-04-25 13:00:41 PDT
Make sense. I'll try another patch.
Basuke Suzuki
Comment 11
2019-04-25 15:29:38 PDT
Created
attachment 368278
[details]
PATCH
WebKit Commit Bot
Comment 12
2019-04-25 16:08:14 PDT
Comment on
attachment 368278
[details]
PATCH Clearing flags on attachment: 368278 Committed
r244669
: <
https://trac.webkit.org/changeset/244669
>
WebKit Commit Bot
Comment 13
2019-04-25 16:08:16 PDT
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 14
2019-04-25 16:20:07 PDT
<
rdar://problem/50224412
>
Basuke Suzuki
Comment 15
2019-04-26 16:49:01 PDT
It was reverted.
https://trac.webkit.org/changeset/244676/webkit
Basuke Suzuki
Comment 16
2019-04-26 16:49:09 PDT
https://trac.webkit.org/changeset/244676/webkit
Basuke Suzuki
Comment 17
2019-04-26 16:49:28 PDT
Created
attachment 368363
[details]
PATCH
Basuke Suzuki
Comment 18
2019-04-26 16:50:28 PDT
Created
attachment 368364
[details]
PATCH
Ross Kirsling
Comment 19
2019-04-28 18:55:59 PDT
Comment on
attachment 368364
[details]
PATCH View in context:
https://bugs.webkit.org/attachment.cgi?id=368364&action=review
I'm a bit confused -- I thought the behavioral effect of this patch was simply to remove warning text from the WinCairo build. Do we understand why the clean build started failing for both Windows platforms?
> WebKitLibraries/win/tools/scripts/auto-version.pl:86 > + my $SVN_REVISION;
Seems that you could initialize to '' here and avoid the else branch below.
Basuke Suzuki
Comment 20
2019-04-29 10:32:36 PDT
Created
attachment 368466
[details]
PATCH
Basuke Suzuki
Comment 21
2019-04-29 10:32:56 PDT
(In reply to Ross Kirsling from
comment #19
)
> Comment on
attachment 368364
[details]
> PATCH > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=368364&action=review
> > I'm a bit confused -- I thought the behavioral effect of this patch was > simply to remove warning text from the WinCairo build. Do we understand why > the clean build started failing for both Windows platforms? > > > WebKitLibraries/win/tools/scripts/auto-version.pl:86 > > + my $SVN_REVISION; > > Seems that you could initialize to '' here and avoid the else branch below.
That would be better. Updated.
Basuke Suzuki
Comment 22
2019-04-29 10:47:09 PDT
(In reply to Ross Kirsling from
comment #19
)
> Comment on
attachment 368364
[details]
> PATCH > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=368364&action=review
> > I'm a bit confused -- I thought the behavioral effect of this patch was > simply to remove warning text from the WinCairo build. Do we understand why > the clean build started failing for both Windows platforms?
There're three version related location in this patch. 1. WTF/wtf/CMakeLists.txt 2. JavaScriptCore/CMakeLists.txt 3. WebKitLegacy/CMakeLists.txt In 1 and 2, there are two custom command invoked for MSVC: a: auto-version.pl to generate version information text file. b: version-stamp.pl to stamp version information to binary. On the other hand, third case, it generate a version information file using auto-version.pl and the file is used in the resource file to be compiled. This caused the previous build error. In the updated patch, I've remove the patch for WebKitLegacy and modify auto-version.pl not to invoke SVN if the directory isn't managed by SVN to avoid warning.
WebKit Commit Bot
Comment 23
2019-04-29 11:18:59 PDT
Comment on
attachment 368466
[details]
PATCH Clearing flags on attachment: 368466 Committed
r244741
: <
https://trac.webkit.org/changeset/244741
>
WebKit Commit Bot
Comment 24
2019-04-29 11:19:01 PDT
All reviewed patches have been landed. Closing bug.
Konstantin Tokarev
Comment 25
2019-04-29 11:37:42 PDT
If this feature makes no sense for any port other than AppleWin, it would be better if we moved it into PlatformAppleWin.cmake instead of introducing global option.
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