Re: [Wireshark-dev] New linker warnings compiling Wireshark on Windows

2018-10-17 Thread Peter Wu
On Thu, Oct 04, 2018 at 12:17:31PM -0700, Guy Harris wrote:
> On Oct 4, 2018, at 11:19 AM, Guy Harris  wrote:
> 
> > doesn't help, and there doesn't appear to *be* any documentation for the 
> > alleged "CMAKE_C_FLAGS_*" flags.
> 
> What they meant was "CMAKE__FLAGS_* flags".
> 
> And I've filed a bug against CMake complaining about the opacity of the 
> documentation.

I have analyzed the problem and replied to your report:
https://gitlab.kitware.com/cmake/cmake/issues/18422

Summary: CMake applies additional flags based on the configuration
(Debug, RelWithDebInfo). These may contain "/INCREMENTAL" and are
appended *after* CMAKE_EXE_LINKER_FLAGS.

So the "working" situation happened to have flags in this order:

- CMAKE_EXE_LINKER_FLAGS: (empty)
- CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO: /INCREMENTAL
- LINK_FLAGS: /INCREMENTAL:NO /RELEASE

After Guy's patch (now reverted), it changed to:

- CMAKE_EXE_LINKER_FLAGS: /INCREMENTAL:NO /RELEASE
- CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO: /INCREMENTAL
- LINK_FLAGS: (empty)

So the effective flags are /RELEASE /INCREMENTAL and that causes
warnings.

The best workaround I can think of is to filter out the /INCREMENTAL and
/INCREMENTAL:YES flags from _.
-- 
Kind regards,
Peter Wu
https://lekensteyn.nl
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe

Re: [Wireshark-dev] New linker warnings compiling Wireshark on Windows

2018-10-04 Thread Guy Harris
On Oct 4, 2018, at 11:19 AM, Guy Harris  wrote:

> doesn't help, and there doesn't appear to *be* any documentation for the 
> alleged "CMAKE_C_FLAGS_*" flags.

What they meant was "CMAKE__FLAGS_* flags".

And I've filed a bug against CMake complaining about the opacity of the 
documentation.
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe

Re: [Wireshark-dev] New linker warnings compiling Wireshark on Windows

2018-10-04 Thread Guy Harris
If anybody in the audience knows how CMake determines the flags to be used when 
linking a particular executable target, based on:

the setting of CMAKE_EXE_LINKER_FLAGS;

the setting of CMAKE_EXE_LINKER_FLAGS_ for the configuration 
being built;

the LINK_FLAGS property of the target being built;

any *other* variables and properties that affect the linker flags;

it would be appreciated if they'd let us know *and* convince the CMake people 
to document this in some fairly obvious place; the documentation for 
CMAKE_EXE_LINKER_FLAGS:

https://cmake.org/cmake/help/v3.12/variable/CMAKE_EXE_LINKER_FLAGS.html

"Linker flags to be used to create executables.

These flags will be used by the linker when creating an executable."

CMAKE_EXE_LINKER_FLAGS_:


https://cmake.org/cmake/help/v3.12/variable/CMAKE_EXE_LINKER_FLAGS_CONFIG.html

"Flags to be used when linking an executable.

Same as CMAKE_C_FLAGS_* but used by the linker when creating 
executables."

LINK_FLAGS:

https://cmake.org/cmake/help/v3.12/prop_tgt/LINK_FLAGS.html

"Additional flags to use when linking this target.

The LINK_FLAGS property can be used to add extra flags to the link step 
of a target.  LINK_FLAGS_ will add to the configuration , for 
example, DEBUG, RELEASE, MINSIZEREL, RELWITHDEBINFO, …"

LINK_FLAGS_:

https://cmake.org/cmake/help/v3.12/prop_tgt/LINK_FLAGS_CONFIG.html

"Per-configuration linker flags for a target.

This is the configuration-specific version of LINK_FLAGS."

doesn't help, and there doesn't appear to *be* any documentation for the 
alleged "CMAKE_C_FLAGS_*" flags.

Until then, I'll just go back to doing things the old way, even if that's not 
how you're supposed to set link flags that are to be used with all executables.

(And then explain the behaviors of linker flags for *other* types of targets, 
if they're similar, *mutatis mutandis*.)
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe

Re: [Wireshark-dev] New linker warnings compiling Wireshark on Windows

2018-10-04 Thread Graham Bloice
See change 30004: https://code.wireshark.org/review/#/c/30004/

On Thu, 4 Oct 2018 at 18:20, Maynard, Chris 
wrote:

> With master, I’m seeing 16 new linker warnings of the form, “LINK :
> warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' specification”.
>
> It seems the buildbot is seeing them too.  From
> *https://buildbot.wireshark.org/wireshark-master/builders/Windows%20Server%202016%20x64/builds/3776/steps/compile_1/logs/warnings%20%2816%29*
> 
> :
>
> 74>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\tools\lemon\lemon.vcxproj]
> 76>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\mmdbresolve.vcxproj]
> 91>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\idl2wrs.vcxproj]
> 93>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\text2pcap.vcxproj]
> 89>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\dumpcap.vcxproj]
> 97>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\captype.vcxproj]
> 98>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\capinfos.vcxproj]
>104>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\editcap.vcxproj]
>100>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\reordercap.vcxproj]
>103>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\mergecap.vcxproj]
>101>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\randpkt.vcxproj]
>108>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\dftest.vcxproj]
>115>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\tshark.vcxproj]
>119>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\rawshark.vcxproj]
>118>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\sharkd.vcxproj]
>122>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE'
> specification
> [C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\wireshark.vcxproj]
>
> - Chris
>
>
>

-- 
Graham Bloice
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe

[Wireshark-dev] New linker warnings compiling Wireshark on Windows

2018-10-04 Thread Maynard, Chris
With master, I'm seeing 16 new linker warnings of the form, "LINK : warning 
LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' specification".

It seems the buildbot is seeing them too.  From 
https://buildbot.wireshark.org/wireshark-master/builders/Windows%20Server%202016%20x64/builds/3776/steps/compile_1/logs/warnings%20%2816%29:

74>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\tools\lemon\lemon.vcxproj]
76>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\mmdbresolve.vcxproj]
91>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\idl2wrs.vcxproj]
93>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\text2pcap.vcxproj]
89>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\dumpcap.vcxproj]
97>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\captype.vcxproj]
98>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\capinfos.vcxproj]
   104>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\editcap.vcxproj]
   100>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\reordercap.vcxproj]
   103>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\mergecap.vcxproj]
   101>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\randpkt.vcxproj]
   108>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\dftest.vcxproj]
   115>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\tshark.vcxproj]
   119>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\rawshark.vcxproj]
   118>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\sharkd.vcxproj]
   122>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/RELEASE' 
specification 
[C:\buildbot\wireshark\wireshark-master-64\windows-2016-x64\build\cmbuild\wireshark.vcxproj]

- Chris











CONFIDENTIALITY NOTICE: This message is the property of International Game 
Technology PLC and/or its subsidiaries and may contain proprietary, 
confidential or trade secret information. This message is intended solely for 
the use of the addressee. If you are not the intended recipient and have 
received this message in error, please delete this message from your system. 
Any unauthorized reading, distribution, copying, or other use of this message 
or its attachments is strictly prohibited.
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe