-
-
Notifications
You must be signed in to change notification settings - Fork 31
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
Creating binaries from SDK for wrapping into XCFramework fails #60
Comments
I hit a similar error when trying to generate documentation: #52 (comment) |
Sounds like the same problem. |
I'm seeing the same thing as well |
Can you give me a hint or lead me in the right direction to get this going? I'm happy to help here... I'm just not an expert on the subject matter. This will help us in the flutter world. Thanks! -Rick |
Same issue here. Also needing this for flutter dev. |
Do you think this PR will solve this issue as well?? #95 |
I don't expect it to. |
The workaround for me was to create an Xcode project and rebuild the Package.swift, so creating targets for MapboxNavigation, MapboxNavigationObjC, MapboxCoreNavigation, and MapboxCoreNavigationObjC. Stitching together all the dependencies like in the Package.swift and getting the targets to compile was some hassle and I am still struggling with the ObjC imports, as SPM needs double-quoted imports and xcodebuild/Carthage needs angle-bracket imports. What I am trying is to set preprocessing flags but I couldn't get them to work until now, so I adjust the import each time I need them one way or another:
I know that building an Xcode project in conjunction with Cartfiles is a step backwards, but for me it was the only way to build an XCFramework with MapLibre as a binary dependency. |
I am working on a fork of the SDK with some closed-source additions. I need the ability to deploy the SDK as a binary. So far I am using the pre-SPM version which I can compile using
xcodebuild archive
,xcodebuild -create-xcframework
or Carthage. Since the switch to SPM, this option is no longer available, so I try to build the current version (main branch) viaswift build
orswift create-xc-framework
. Unfortunately I encounter errors when building the dependencies.Steps to Trigger Behavior
xcodebuild
orswift
commandsExpected Behavior
Build / archive command should complete without errors
Actual Behavior
I.e.
swift build
leads to error: ".../maplibre-navigation-ios/MapboxNavigationObjC/MLNMapView+MLNNavigationAdditions.h:1:9: fatal error: 'MapLibre/Mapbox.h' file not found#import <MapLibre/Mapbox.h>
^~~~~~~~~~~~~~~~~~~
1 error generated."
Version(s) affected
Has anyone ever tried to build maplibre-navigation-ios as a binary? I want to deploy it as XCFramework binary as part of a Swift package.
The text was updated successfully, but these errors were encountered: