Build fails on Sonoma 14.1.2 intel mac
ishubham-k opened this issue · 4 comments
Swift info
swift --version
swift-driver version: 1.87.1 Apple Swift version 5.9 (swiftlang-5.9.0.128.108 clang-1500.0.40.1)
Target: x86_64-apple-macosx14.0
Output of swift build
swift build
warning: 'vulkan': ignoring declared target(s) 'Vulkan' in the system package
warning: 'vulkan': system packages are deprecated; use system library targets instead
Building for debugging...
error: unknown argument: '-fprofile-instr-generate'
[0/7] Compiling SPIRV-Cross-static spirv_msl.cpp
Not sure how to get around this
I am currently looking for a way to fix this issue.
As a simple workaround, you can open Package.swift in Xcode and build it, but IIRC, you will get an error because Float16 is not available on Intel Macs.
This issue has not been resolved yet. ( I have not tested it on the latest macOS-sonoma.),
I've fixed the issue, it was a deprecated linker option that was causing the problem. I'm closing this issue now, if you have any other issues please open a new one.
@Hongtae Thanks for working on this. You are right it doesn't work for intel macs due to Float16 errors. Is intel mac not a target ?
As long as macOS continues to be released on Intel Macs, Intel Macs are a valid target.
However, since there is no way to distinguish CPU architecture in Swift, I need to find a way to support Float16 on Intel only. As far as I know, CPU distinction is only possible in C/C++/Objective-C.
I'm backlogged with other work right now, so it's hard to look into this issue in detail, I apologize.