-
-
Notifications
You must be signed in to change notification settings - Fork 299
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
Generate project references before targets #518
Generate project references before targets #518
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @evandcoleman. Your fix makes a lot of sense. I'd just add a test to prevent the introduction of regressions in the future. After that, we are good to merge this PR.
@pepibumur done! |
Thanks @evandcoleman! |
Thanks a lot @evandcoleman. You can ignore that, it's a bit flakey so I'll have to look into it. |
@pepibumur Thanks! When can we expect this to be included in a release? Or is that something that I'm able to do and open a PR with the changes? |
I just released 7.7.0 so self-serve. |
Awesome, thank you!! |
Short description π
Previously, targets were generated before project references. This means that any build files in your main project that reference build files in another project will be generated with non-deterministic UUIDs.
Solution π¦
Generate project references before generating targets
Implementation π©βπ»π¨βπ»
This bug was surfaced to me while implementing a new feature in XcodeGen (yonaskolb/XcodeGen#701) which allows you to link with targets in external Xcode projects. Every time the project was generated, the UUIDs of the
PBXBuildFile
s were different. I realized that this is because thePBXProductReferenceProxy
object still had aTEMP
UUID by the time it got to generating build phases for the main project. After changing the order of generating, the problem went away because the reference proxy no longer had the temporary UUID.