microsoft / krabsetw

KrabsETW provides a modern C++ wrapper and a .NET wrapper around the low-level ETW trace consumption functions.
Other
589 stars 149 forks source link

Fix errors when building with /permissive- (#42) #43

Closed jrave closed 6 years ago

jrave commented 6 years ago

This should address #42

Tested that examples and tests build with:

msftclas commented 6 years ago

CLA assistant check
All CLA requirements met.

zacbrown commented 6 years ago

Thanks for your help! Not sure why I got an error making these changes. Maybe just dirty build.

Could you add the /permissive- setting to the NativeExamples and krabstest projects? That'll just ensure the project continues to be compliant with /permissive- going forward.

jrave commented 6 years ago

As far as I understand things /permissive- is only available in the v141 aka VS 2017 toolset. Currently this project has the v140 aka VS 2015 toolset as the default. So should I switch the default toolset as well then? And as already mentioned the Win 8.1 SDK is also not compatible so would also need switching. Should that then also be done?

zacbrown commented 6 years ago

Hi,

Yes - let's go ahead and upgrade the project toolchain to VS2017 and Win10 SDK.

jrave commented 6 years ago

Alright updated the projects and solution to VS 2017 and enabled /permissive- for the NativeExamples and krabstests projects.

There is one caveat with this change: Boost now throws the following messages: Unknown compiler version - please run the configure tests and report the results. Tests run fine so this is likely just an annoyance.

Tried updating to Boost 1.66.0 but that gave the following message along a similar line: Info: Boost.Config is older than your compiler version - probably nothing bad will happen - but you may wish to look for an update Boost version. Define BOOST_CONFIG_SUPPRESS_OUTDATED_MESSAGE to suppress this message.. So it seemed not worth it to also drag a Boost update into this.

zacbrown commented 6 years ago

Thanks!

I missed this the other day so I’ll be taking a look today.