Almost all tests from iosMathTests pass with swift test command, except there are some numerical differences in MTTypesetterTest, probably coming from iOS/MacOS platform changes and unrelated to SPM.
The following things were added to satisfy the Swift Package Manager requirements:
Adds include folder under iosMath with symlinked headers. SPM will automatically create module.modulemap from these headers for interoperability with Swift and Objective-C @import.
Symlinks fonts folder under iosMath so that the folder is packaged into a module bundle. Pointing to ../fonts in Package.swift didn't work. Maybe it is cleaner to just move the fonts folder instead of symlinking?
Almost all tests from iosMathTests pass with
swift test
command, except there are some numerical differences inMTTypesetterTest
, probably coming from iOS/MacOS platform changes and unrelated to SPM.The following things were added to satisfy the Swift Package Manager requirements:
include
folder under iosMath with symlinked headers. SPM will automatically createmodule.modulemap
from these headers for interoperability with Swift and Objective-C@import
.fonts
folder under iosMath so that the folder is packaged into a module bundle. Pointing to../fonts
in Package.swift didn't work. Maybe it is cleaner to just move thefonts
folder instead of symlinking?SWIFTPM_MODULE_BUNDLE
preprocessor to access the module bundle. See: https://github.com/apple/swift-evolution/blob/master/proposals/0271-package-manager-resources.md