Skip to content
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

Fix build issue of LinuxSys #7

Merged
merged 2 commits into from
Oct 23, 2023
Merged

Conversation

Kyle-Ye
Copy link
Contributor

@Kyle-Ye Kyle-Ye commented Oct 20, 2023

# On root of the package
swift build --product LinuxSys # ✅ works fine
swift build --product SwiftXlib # ✅ works fine

swift build --package-path ./Sys # ❌ error: 'sys': package has unsupported layout; missing system target module map at '/tmp/AppKid/Sys/Sources/LinuxSys/module.modulemap'
swift build --package-path ./SwiftXlib # ❌ error: 'sys': package has unsupported layout; missing system target module map at '/tmp/AppKid/Sys/Sources/LinuxSys/module.modulemap'

The problem is that the target config in /Sys/Package.swift is different from Package.swift.

AppKid/Package.swift

Lines 492 to 495 in 78c9c7e

static let linuxSys: Target = target(
name: "LinuxSys",
path: "Sys/Sources/LinuxSys"
)

@smumriak
Copy link
Owner

Looks good with one change: please make the type of LinuxSys product a static librar

@smumriak
Copy link
Owner

Tho right now you should use the Package manifest from the root of the repository. I left the manifest files in individual directories with intention to split repository in future, but I am not sure when that future will come

@smumriak smumriak self-requested a review October 20, 2023 14:33
Sys/Package.swift Outdated Show resolved Hide resolved
@Kyle-Ye Kyle-Ye requested a review from smumriak October 22, 2023 03:44
@smumriak smumriak merged commit de834ee into smumriak:main Oct 23, 2023
@Kyle-Ye Kyle-Ye deleted the optimize/kyle/fix branch October 24, 2023 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants