-
Notifications
You must be signed in to change notification settings - Fork 4
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
Support Framework Build Phase, Rework Dependency Mapping #45
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NinjaLikesCheez
force-pushed
the
missing_dependency_tracking
branch
from
September 11, 2023 13:32
dba950b
to
d6540bb
Compare
NinjaLikesCheez
changed the title
Support Framework Build Phase
Support Framework Build Phase, Rework Dependency Mapping
Sep 25, 2023
This allows for determining the 'Link Binary with Libraries' build phase (which... for no reason... isn't listed as a dependency in the target?!)
Include tests
This change adds: * the ability to write a DOT file representing the dependency graph of the project with new CLI option * fixes the graph by correcting a mistake where edges could be linked multiple times, and removes original transitive depependency finding since that's now in the graph * adds support for 'embed frameworks' copy files build phase
NinjaLikesCheez
force-pushed
the
missing_dependency_tracking
branch
from
December 1, 2023 10:28
08d0779
to
de5d42d
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Gen IR parses through Xcode files that represents the project - pbxproj files - and uses
PBXNativeTarget
(and others) to represent the main targets. This is also used to do a lot of the dependency tracking as they have a helpfuldependency
andpackageProductDependencies
arrays which we can use.Turns out, as is often the case with this undocumented format, that is not the only way Xcode handles dependencies! There also exists a special build phase (
PBXFrameworksBuildPhase
- more commonly known to developers as ‘Link Binary with Libraries’) that doesn’t list targets in the dependency arrays. Instead, this phase has afiles
array - which lists some additional dependencies (some of which are included in either the dependency or package array… but it turns out not all!).This change adds support for parsing this file list.
In addition, this change also adds a new and improved way of tracking dependencies via a directed graph which improves our ability to control how and when we move files - so as not to miss transitive dependencies.