conda-forge / conda-forge/thrift-cpp-feedstock

thrift-cpp compiled with /GL on Windows?

Open
#19 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Batchfile
Stars
2
Forks
14
PR merge metrics
No merged PRs in 30d

Description

When linking Arrow and Parquet-cpp on Windows we get this warning a lot:
```
2018-09-27T17:40:50.0352271Z [202/227] Linking CXX executable release\parquet-column_reader-test.exe
2018-09-27T17:40:50.0352766Z thriftmd.lib(TTransportException.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
```

LTCG (link-time code generation) slows down linking. Also, according to the following blog post, /GL should never be used on redistributable libraries:
https://blogs.msdn.microsoft.com/vcblog/2009/02/24/quick-tips-on-using-whole-program-optimization/

> Never use /GL for code you intend to put in a library and ship to your customers. Doing so means that your customers will be doing the code gen for your library when they link their application. Since some of your customers could have different versions of the compiler, shipping a lib built this way could cause various maintenance problems for you. If your customer’s compiler is from a prior release, their link may fail. If their version is newer than yours, the code they generate won’t be exactly equal to what you’ve tested, and could behave differently for them than when you tested it. In VS 2008, the IDE default for the class library template release configuration is to build using /GL, and I strongly encourage everyone to reset that.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.