Post

Replies

Boosts

Views

Activity

Reply to Swift Package Manager not building external dependencies correctly
Ok, so I managed to fix this by adding dependency to my target. Here's the update Package.swift // swift-tools-version: 5.10 // The swift-tools-version declares the minimum version of Swift required to build this package. let package = Package( name: "MyPackage", platforms: [.iOS(.v16), .macCatalyst(.v16), .macOS(.v14)], products: [.library(name: "MyPackage", targets: ["MyPackage"]),], dependencies: [ .package(path: "../external-package") ], targets: [ .target( name: "MyPackage", dependencies: [ 👉❗️ .product(name: "ExternalPackageName", package: "external-package") ], path: "Sources" ), .testTarget(name: "MyPackageTests", dependencies: ["MyPackage"]), ] )
Aug ’24