Skip to content

Commit

Permalink
Cocoapods Build From Source (#118)
Browse files Browse the repository at this point in the history
* setup podspec for build from source

* build from source solution

* remove plists from source files

* update podspec to new dir structure

* updating turf pointer

* adding comma

* PR Comments
  • Loading branch information
Neel Mistry authored Feb 22, 2021
1 parent 1e792ae commit 78d8adc
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 11 deletions.
3 changes: 3 additions & 0 deletions Mapbox/Configurations/Mapbox.xcconfig
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,6 @@ BUILD_LIBRARY_FOR_DISTRIBUTION = YES
// TODO: Enable warnings-as-errors
//OTHER_SWIFT_FLAGS[config=Debug] = $(inherited)
//OTHER_SWIFT_FLAGS[config=Release] = $(inherited) -warnings-as-errors

SWIFT_ACTIVE_COMPILATION_CONDITIONS[config=Debug] = $(inherited) DEBUG USING_TURF_WITH_LIBRARY_EVOLUTION
SWIFT_ACTIVE_COMPILATION_CONDITIONS[config=Release] = $(inherited) RELEASE USING_TURF_WITH_LIBRARY_EVOLUTION
19 changes: 9 additions & 10 deletions MapboxMaps.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,18 @@ Pod::Spec.new do |m|
m.author = { 'Mapbox' => '[email protected]' }
m.social_media_url = 'https://twitter.com/mapbox'
m.documentation_url = 'https://docs.mapbox.com/ios/beta/maps/api-reference/'

m.source = { http: "https://api.mapbox.com/downloads/v2/mobile-maps-ios/releases/ios/packages/#{maps_version.to_s}/MapboxMaps.xcframework.zip" }
m.vendored_frameworks = 'MapboxMaps.xcframework'


m.source = { :git => 'https://github.com/mapbox/mapbox-maps-ios.git', :tag => maps_version }
m.platform = :ios
m.ios.deployment_target = '11.0'
m.swift_version = '5.3'
m.requires_arc = true
m.pod_target_xcconfig = { 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'arm64' }

m.dependency 'MapboxCoreMaps', '10.0.0-beta.14.1'
m.dependency 'MapboxCommon', '10.0.0-beta.9.1'
m.dependency 'MapboxMobileEvents', '0.10.7'
m.dependency 'Turf', '2.0.0-alpha.2'
m.source_files = 'Sources/MapboxMaps/**/*.{swift,h}'
m.resources = 'Sources/**/*.{xcassets,strings}'

m.dependency 'MapboxCoreMaps', '10.0.0-beta.15'
m.dependency 'MapboxCommon', '10.0.0-beta.11'
m.dependency 'MapboxMobileEvents', '0.10.8'
m.dependency 'Turf', '~> 1.2'

end
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ extension MBXGeometry {
case .geometryCollection(let geometryCollection):
let geometryValues = geometryCollection.geometries.map {( MBXGeometry.init(geometry: $0) )}
self.init(geometryCollection: geometryValues)
#if !SWIFT_PACKAGE

#if USING_TURF_WITH_LIBRARY_EVOLUTION
@unknown default:
fatalError("Could not determine MBXGeometry from given Turf Geometry")
#endif
Expand Down

0 comments on commit 78d8adc

Please sign in to comment.