Documentation Index
Fetch the complete documentation index at: https://mintlify.com/tuist/tuist/llms.txt
Use this file to discover all available pages before exploring further.
Dependencies
Target dependency types that define how targets depend on other code.Overview
TheTargetDependency enum defines all possible types of dependencies that a target can have, including dependencies on other targets, external packages, system frameworks, and prebuilt binaries.
Dependency Types
Target Dependency
Depend on another target within the same project.Name of the target to depend on.
The dependency status. Use
.optional for weak linking, .required for strong linking, or .none to skip linking.Condition under which to use this dependency.
nil means always use it.Macro Dependency
Depend on a Swift macro target within the same project.Name of the macro target to depend on.
Project Dependency
Depend on a target within another project.Name of the target to depend on.
Relative path to the other project directory.
The dependency status (optional dependencies are weakly linked).
Condition under which to use this dependency.
External Dependency
Depend on an external dependency imported throughPackage.swift. This is the recommended approach.
Name of the external dependency as declared in Package.swift.
Condition under which to use this dependency.
Package Dependency
Depend on a Swift Package Manager product using Xcode native integration. It’s recommended to use.external instead. For more info, check the external dependencies documentation.
The name of the output product (e.g., “RxSwift”).
The type of package being integrated:
.runtime- Standard package linked at runtime.runtimeEmbedded- Package embedded in the product at runtime.plugin- Build system plugin loaded at compile-time.macro- Swift Macro package
Condition under which to use this dependency.
Framework Dependency
Depend on a prebuilt framework.Relative path to the prebuilt framework.
The dependency status (optional dependencies are weakly linked).
Condition under which to use this dependency.
XCFramework Dependency
Depend on an XCFramework.Relative path to the xcframework.
The expected signature if the xcframework is signed. Used for verifying integrity.
.unsigned- The XCFramework is not signed.signedWithAppleCertificate(teamIdentifier:teamName:)- Signed with Apple Development certificate.selfSigned(fingerprint:)- Signed with self-issued code signing identity
The dependency status (optional dependencies are weakly linked).
Condition under which to use this dependency.
Library Dependency
Depend on a prebuilt static library.Relative path to the prebuilt library.
Relative path to the library’s public headers directory.
Relative path to the library’s Swift module map file.
Condition under which to use this dependency.
SDK Dependency
Depend on a system library or framework.Name of the system library or framework without extension (e.g., “ARKit”, “c++”).
The dependency type:
.framework- Framework SDK.library- Library SDK (inusr/lib).swiftLibrary- Swift library SDK (inusr/lib/swift)
The dependency status (optional dependencies are weakly linked).
Condition under which to use this dependency.
XCTest Dependency
Depend on XCTest framework.LinkingStatus
Controls how a dependency is linked:.required- Required dependency (strong linking).optional- Optional dependency (weak linking).none- Skip linking entirely