Since we migrated to Xcode 15.4, we are facing a crash of one of our application on Intel machines due to a missing symbol error:
Symbol not found: _$s7Network13NWPathMonitorCMa
This symbol is used by one of our internal SPM packages, targeting macOS 10.13, but the code using it is tagged @available(macOS 10.14.0, *).
After investigating, I can fix this crash by targeting 10.14 instead of 10.13 in package manifest. Sadly, this is not an option, as this SPM is used by products that supports macOS 10.13.
The linked libraries reported by otool differs significantly between the build targetting 10.13 and the build targetting 10.15:
The build targetting 10.13 weakly links links to
/System/Library/Frameworks/Network.framework/Versions/A/Network
The build targetting 10.15 does not link to Network.framework, but does link (not wealky) to a library that didn't appear before
/usr/lib/swift/libswiftNetwork.dylib
In previous builds that were performed by Xcode 14, the produced binary was weakly linking to
@rpath/libswiftNetwork.dylib
What can I do to work around this problem introduced by Xcode 15 ?