Skip to content

Commit d261bb4

Browse files
kriedbillyjbryant
authored andcommitted
Initial commit
0 parents  commit d261bb4

File tree

8 files changed

+206
-0
lines changed

8 files changed

+206
-0
lines changed

.gitignore

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
.DS_Store
2+
.idea
3+
4+
xcuserdata
5+
*.xccheckout
6+
*.moved-aside
7+
*.xcuserstate
8+
*.xcscmblueprint
9+
IDEWorkspaceChecks.plist
10+
11+
Pods/
12+
13+
Carthage/Build
14+
Carthage/Checkouts
15+
/documentation
16+
/build
17+
.build
18+
19+
vendor/bundle/ruby/
20+
.vscode
21+
.swiftpm
22+
/XCFrameworks
23+
Package.resolved

CODEOWNERS

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* @mapbox/navigation-ios

LICENSE.md

+63
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# License
2+
3+
Mapbox Navigation for iOS version 3.0
4+
Mapbox Navigation iOS SDK
5+
6+
Copyright © 2022 - 2024 Mapbox, Inc. All rights reserved.
7+
8+
The software and files in this repository (collectively, "Software") are licensed under the Mapbox TOS for use only with the relevant Mapbox product(s) listed at www.mapbox.com/pricing. This license allows developers with a current active Mapbox account to use and modify the authorized portions of the Software as needed for use only with the relevant Mapbox product(s) through their Mapbox account in accordance with the Mapbox TOS. This license terminates automatically if a developer no longer has a Mapbox account in good standing or breaches the Mapbox TOS. For the license terms, please see the Mapbox TOS at https://www.mapbox.com/legal/tos/ which incorporates the Mapbox Product Terms at www.mapbox.com/legal/service-terms. If this Software is a SDK, modifications that change or interfere with marked portions of the code related to billing, accounting, or data collection are not authorized and the SDK sends limited de-identified location and usage data which is used in accordance with the Mapbox TOS. [Updated 2024-11]
9+
10+
-------------------------------------------------------------------------------
11+
12+
## Third-party licenses
13+
14+
Mapbox Navigation iOS SDK uses adapted implementation of the `Minimum Edit Distance` algorithm in `MinimumEditDistance.swift`.
15+
URL: [https://github.com/raywenderlich/swift-algorithm-club/blob/master/Minimum%20Edit%20Distance/MinimumEditDistance.playground/Contents.swift](https://github.com/raywenderlich/swift-algorithm-club/blob/master/Minimum%20Edit%20Distance/MinimumEditDistance.playground/Contents.swift).
16+
License: [MIT License](https://github.com/raywenderlich/swift-algorithm-club/blob/master/LICENSE.txt).
17+
18+
Copyright (c) 2016 Matthijs Hollemans and contributors
19+
20+
Permission is hereby granted, free of charge, to any person obtaining a copy
21+
of this software and associated documentation files (the "Software"), to deal
22+
in the Software without restriction, including without limitation the rights
23+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
24+
copies of the Software, and to permit persons to whom the Software is
25+
furnished to do so, subject to the following conditions:
26+
27+
The above copyright notice and this permission notice shall be included in
28+
all copies or substantial portions of the Software.
29+
30+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
31+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
32+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
33+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
34+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
35+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
36+
THE SOFTWARE.
37+
38+
Mapbox Navigation iOS SDK uses `Solar`.
39+
URL: [https://github.com/ceeK/Solar](https://github.com/ceeK/Solar).
40+
License: [MIT License](https://github.com/ceeK/Solar/blob/master/LICENSE).
41+
42+
Mapbox Navigation iOS SDK uses `Turf`.
43+
URL: [https://github.com/mapbox/turf-swift](https://github.com/mapbox/turf-swift).
44+
License: [ISC License](https://github.com/mapbox/turf-swift/blob/main/LICENSE.md).
45+
46+
Mapbox Navigation iOS SDK uses `Polyline`.
47+
URL: [https://github.com/raphaelmor/Polyline](https://github.com/raphaelmor/Polyline).
48+
License: [MIT License](https://github.com/raphaelmor/Polyline/blob/master/LICENSE.txt).
49+
50+
-------------------------------------------------------------------------------
51+
52+
Mapbox Navigation for iOS version 1.2.1 and earlier is licensed under an ISC license.
53+
54+
Copyright © 2014–2024, Mapbox
55+
56+
Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is
57+
hereby granted, provided that the above copyright notice and this permission notice appear in all copies.
58+
59+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
60+
INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE
61+
FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
62+
OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
63+
OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

Package.swift

+106
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
// swift-tools-version:5.9
2+
// The swift-tools-version declares the minimum version of Swift required to build this package.
3+
4+
import PackageDescription
5+
6+
let commonVersion: Version = "24.8.0"
7+
let navNativeVersion: Version = "321.0.0"
8+
9+
let version = "3.5.0"
10+
11+
let binaries = ["MapboxCoreMaps": "5fa0cc70cc9ae5734096d325c638ed1bbbe5e1a7d1a1817dcc54922b14488716",
12+
"MapboxDirections": "5dcda5f3184c1cb37ca1e1e6f7fcd06cb7c8487c02ed1357e9aa0be77f88bff6",
13+
"MapboxMaps": "2abdddae11a2ca7e5c9d28ecf10b59d2b9c4e5efde1afaea378a3794965aff28",
14+
"MapboxNavigationCore": "bce6978b18dcd41d0354c480506faf9d4b72b5dced271bcaf4633ac1ba4a5001",
15+
"MapboxNavigationUIKit": "986af8c93ae51e5e5474b7d143d3a3c0a9e2871b75d359b2f33b0af7b94bc82a",
16+
"Turf": "8939eb0397390b43cb5af90e2597f858c704ebc07f4973799684a7a9a87e5946",
17+
"_MapboxNavigationHelpers": "a905f43b14466876da35d5cbbc76b991cf99efb824af5f5a145e756f47704954",
18+
]
19+
20+
let libraries = ["MapboxNavigationCustomRoute": "19936d0840f195b996588d53f33f3e0f7cbe30f196783d10b2842539675bd308",
21+
]
22+
23+
enum FrameworkType {
24+
case release
25+
case staging
26+
case local
27+
}
28+
29+
let frameworkType: FrameworkType = .release
30+
31+
let package = Package(
32+
name: "MapboxNavigation",
33+
platforms: [.iOS(.v14)],
34+
products: [
35+
.library(
36+
name: "MapboxNavigationCore",
37+
targets: ["MapboxNavigationCoreWrapper"]
38+
),
39+
.library(
40+
name: "MapboxNavigationUIKit",
41+
targets: ["MapboxNavigationUIKitWrapper"]
42+
),
43+
.library(
44+
name: "MapboxNavigationCustomRoute",
45+
targets: ["MapboxNavigationCustomRouteWrapper"]
46+
),
47+
],
48+
dependencies: [
49+
.package(url: "https://github.com/mapbox/mapbox-common-ios.git", exact: commonVersion),
50+
.package(url: "https://github.com/mapbox/mapbox-navigation-native-ios.git", exact: navNativeVersion),
51+
],
52+
targets: binaryTargets() + libraryTargets() + [
53+
.target(
54+
name: "MapboxNavigationCoreWrapper",
55+
dependencies: binaries.keys.map { .byName(name: $0) } + [
56+
.product(name: "MapboxCommon", package: "mapbox-common-ios"),
57+
.product(name: "MapboxNavigationNative", package: "mapbox-navigation-native-ios"),
58+
],
59+
path: "Sources/.empty/MapboxNavigationCoreWrapper"
60+
),
61+
.target(
62+
name: "MapboxNavigationUIKitWrapper",
63+
dependencies: [
64+
"MapboxNavigationCoreWrapper",
65+
],
66+
path: "Sources/.empty/MapboxNavigationUIKitWrapper"
67+
),
68+
.target(
69+
name: "MapboxNavigationCustomRouteWrapper",
70+
dependencies: libraries.keys.map { .byName(name: $0) } + [
71+
"MapboxNavigationCoreWrapper",
72+
],
73+
path: "Sources/.empty/MapboxNavigationCustomRouteWrapper"
74+
),
75+
]
76+
)
77+
78+
func binaryTargets() -> [Target] {
79+
binaries.map { binaryName, checksum in
80+
binaryTarget(binaryName: binaryName, checksum: checksum, packageName: "navsdk-v3-ios")
81+
}
82+
}
83+
84+
func libraryTargets() -> [Target] {
85+
libraries.map { binaryName, checksum in
86+
binaryTarget(binaryName: binaryName, checksum: checksum, packageName: "mapbox-navigation-custom-route-ios")
87+
}
88+
}
89+
90+
func binaryTarget(binaryName: String, checksum: String, packageName: String) -> Target {
91+
switch frameworkType {
92+
case .release, .staging:
93+
let host = frameworkType == .release ? "api.mapbox.com" : "cloudfront-staging.tilestream.net"
94+
return Target.binaryTarget(
95+
name: binaryName,
96+
url: "https://\(host)/downloads/v2/\(packageName)" +
97+
"/releases/ios/packages/\(version)/\(binaryName).xcframework.zip",
98+
checksum: checksum
99+
)
100+
case .local:
101+
return Target.binaryTarget(
102+
name: binaryName,
103+
path: "XCFrameworks/\(binaryName).xcframework"
104+
)
105+
}
106+
}

README.md

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# [Mapbox Navigation SDK for iOS](https://docs.mapbox.com/ios/navigation/)
2+
3+
[![SPM compatible](https://img.shields.io/badge/SPM-compatible-4BC51D.svg?style=flat)](https://swift.org/package-manager/)
4+
5+
Mapbox Navigation gives you all the tools you need to add turn-by-turn navigation to your iOS application.
6+
7+
Get up and running in a few minutes with our drop-in turn-by-turn navigation `NavigationViewController`, or build a completely custom turn-by-turn navigation app with our core components for routing and navigation.
8+
9+
### [Documentation](https://docs.mapbox.com/ios/navigation/api-reference/)
10+
11+
## License
12+
13+
The Mapbox Navigation SDK for iOS is released under the Mapbox Terms of Service. See [LICENSE.md](./LICENSE.md) for details.

Sources/.empty/MapboxNavigationCoreWrapper/dummy.swift

Whitespace-only changes.

Sources/.empty/MapboxNavigationCustomRouteWrapper/dummy.swift

Whitespace-only changes.

Sources/.empty/MapboxNavigationUIKitWrapper/dummy.swift

Whitespace-only changes.

0 commit comments

Comments
 (0)