[SERVER-27628] The compile commands database doesn't always write the actual commands used to build Created: 10/Jan/17 Updated: 05/Apr/17 Resolved: 13/Jan/17 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Build |
| Affects Version/s: | None |
| Fix Version/s: | 3.5.2 |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | Kasper Laudrup | Assignee: | Gabriel Russell (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Backwards Compatibility: | Fully Compatible |
| Operating System: | ALL |
| Sprint: | Platforms 2017-01-23 |
| Participants: |
| Description |
|
If building a target with eg.: env.Library("foo", ["foo.cpp"], CXXFLAGS=["-Dfoo"]) The compile command written to the compilation command database (compile_commands.json) will not use the updated flags in CXXFLAGS, but always use the environment in "env". This means that the compilation database will not always match the actual command line required to build the target. |
| Comments |
| Comment by Githook User [ 13/Jan/17 ] |
|
Author: {u'username': u'laudrup', u'name': u'Kasper Laudrup', u'email': u'laudrup@stacktrace.dk'}Message: When the compilation_db scons emitter saved compilation database That meant that using eg.: env.Library("foo", ["foo.cpp"], CXXFLAGS=["-Dfoo"]) Would not write the extra "-Dfoo" flag actually used to build the foo Instead save the environment used to generate the target and use that |