-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BuildXL fails with vcxproj and ProjectReferences #719
Comments
Hi @wjk, Unfortunately all devs that work on the MsBuild integration our out of office. I have added them as assignees for then they are back. |
@dannyvv I have a slightly off-topic question for you. How should I submit ideas for improvement regarding vcxproj such that the team at MS will actually review them? I have found quite a few pain points over my years of using it. I have posted them in several areas, including several MSVC-related GitHub repos as well as VS Developer Community, and I have never received a response anywhere. Other developers have also complained about these issues, and they have not received a response either. (For example, take this Developer Community thread. The only response from MS it received was a boilerplate "comment received" message that every new issue there gets.) If you could help me route my comments to the approrpiate team, I would greatly appreciate it. Thanks so much! |
In the meantime, you might want to try to set |
@jbayardo Unfortunately, setting |
@wjk this section describes how to let static graph know what targets projects call each other with: https://github.com/Microsoft/msbuild/blob/master/documentation/specs/static-graph.md#inferring-which-targets-to-run-for-a-project-within-the-graph As you've noticed, we've added the managed sdk specification in Microsoft.Managed.targets, because traditionally the managed sdk shipped parts of itself with msbuild. But vcxproj is pretty isolated, we don't have a story for them yet. Probably we'll have to send a PR to the vcxproj team to add the target reference protocol, and setup a CI to prevent them from regressing. |
@cdmihai, if this is not implemented as part of the official SDK yet, maybe specifying the target protocol at the repo level is an option? I'm not super familiar with this, but if I remember correctly that was possible. In that case maybe we can help @wjk to come up with a definition for it that can be injected for his particular repository. |
The official c++ SDK most likely does not have the target protocol specified. Couple of options:
|
This knob allows you to turn off static graph project isolation and just rely on the 'do not build my parent' honor code, which is respected but many SDKs (but no engine enforcements are in place). |
This:
Worked for me, thanks for your help. I've hit another (unrelated?) issue, error DX0500 writing to output files that already exist when building projects referenced by the module being built.
Wondering if this is something to do with building referenced vcxproj files or something to do with the location of the output directories relative to the other files. .bc file here: C:\svn\c0\code |
By default BuildXL expects writes to happen under the repo root. This is just a default policy to block a build from writing into random places of your disk. You can declare additional places where outputs are expected to happen using the 'additionalOutputDirectories' in the main BuildXL configuration file. |
I did try that in LusasWin.bc
Tried plenty of variations of additionalOutputDirectories but it didn't change the output. |
There should be additional info about the violation in the main bxl log file that explain the underlying reason with more detail. E.g. if those files already exist, bxl will also block the write. If you don't actually care about those files (in the sense of being part of the outputs of your build, or if no relevant decision is made based on its presence) you can also untrack them and bxl will allow the rewrite. |
When I point BuildXL at an MSBuild C++ project that contains a
<ProjectReference>
element, it fails with the following error message (line-wrapped for readability):As I understand it, this is because the vcxproj infrastructure lacks the content in
Microsoft.Managed.targets
that provides information required by BuildXL. Unfortunately, I do not know enough about BuildXL to provide the correct metadata myself.The text was updated successfully, but these errors were encountered: