Skip to content

Commit 165145c

Browse files
committed
Added OS X framework target
Added an OS X framework target and scheme.
1 parent fa1b643 commit 165145c

File tree

8 files changed

+421
-6
lines changed

8 files changed

+421
-6
lines changed

MapboxGeocoder.xcodeproj/project.pbxproj

Lines changed: 305 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Scheme
3+
LastUpgradeVersion = "0730"
4+
version = "1.3">
5+
<BuildAction
6+
parallelizeBuildables = "YES"
7+
buildImplicitDependencies = "YES">
8+
<BuildActionEntries>
9+
<BuildActionEntry
10+
buildForTesting = "YES"
11+
buildForRunning = "YES"
12+
buildForProfiling = "YES"
13+
buildForArchiving = "YES"
14+
buildForAnalyzing = "YES">
15+
<BuildableReference
16+
BuildableIdentifier = "primary"
17+
BlueprintIdentifier = "DA5170951CF1B18F00CD6DCF"
18+
BuildableName = "MapboxGeocoder.framework"
19+
BlueprintName = "MapboxGeocoderMac"
20+
ReferencedContainer = "container:MapboxGeocoder.xcodeproj">
21+
</BuildableReference>
22+
</BuildActionEntry>
23+
</BuildActionEntries>
24+
</BuildAction>
25+
<TestAction
26+
buildConfiguration = "Debug"
27+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
28+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
29+
shouldUseLaunchSchemeArgsEnv = "YES"
30+
codeCoverageEnabled = "YES">
31+
<Testables>
32+
<TestableReference
33+
skipped = "NO">
34+
<BuildableReference
35+
BuildableIdentifier = "primary"
36+
BlueprintIdentifier = "DA51709E1CF1B18F00CD6DCF"
37+
BuildableName = "MapboxGeocoderTests.xctest"
38+
BlueprintName = "MapboxGeocoderMacTests"
39+
ReferencedContainer = "container:MapboxGeocoder.xcodeproj">
40+
</BuildableReference>
41+
</TestableReference>
42+
</Testables>
43+
<MacroExpansion>
44+
<BuildableReference
45+
BuildableIdentifier = "primary"
46+
BlueprintIdentifier = "DA5170951CF1B18F00CD6DCF"
47+
BuildableName = "MapboxGeocoder.framework"
48+
BlueprintName = "MapboxGeocoderMac"
49+
ReferencedContainer = "container:MapboxGeocoder.xcodeproj">
50+
</BuildableReference>
51+
</MacroExpansion>
52+
<AdditionalOptions>
53+
</AdditionalOptions>
54+
</TestAction>
55+
<LaunchAction
56+
buildConfiguration = "Debug"
57+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
58+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
59+
launchStyle = "0"
60+
useCustomWorkingDirectory = "NO"
61+
ignoresPersistentStateOnLaunch = "NO"
62+
debugDocumentVersioning = "YES"
63+
debugServiceExtension = "internal"
64+
allowLocationSimulation = "YES">
65+
<MacroExpansion>
66+
<BuildableReference
67+
BuildableIdentifier = "primary"
68+
BlueprintIdentifier = "DA5170951CF1B18F00CD6DCF"
69+
BuildableName = "MapboxGeocoder.framework"
70+
BlueprintName = "MapboxGeocoderMac"
71+
ReferencedContainer = "container:MapboxGeocoder.xcodeproj">
72+
</BuildableReference>
73+
</MacroExpansion>
74+
<AdditionalOptions>
75+
</AdditionalOptions>
76+
</LaunchAction>
77+
<ProfileAction
78+
buildConfiguration = "Release"
79+
shouldUseLaunchSchemeArgsEnv = "YES"
80+
savedToolIdentifier = ""
81+
useCustomWorkingDirectory = "NO"
82+
debugDocumentVersioning = "YES">
83+
<MacroExpansion>
84+
<BuildableReference
85+
BuildableIdentifier = "primary"
86+
BlueprintIdentifier = "DA5170951CF1B18F00CD6DCF"
87+
BuildableName = "MapboxGeocoder.framework"
88+
BlueprintName = "MapboxGeocoderMac"
89+
ReferencedContainer = "container:MapboxGeocoder.xcodeproj">
90+
</BuildableReference>
91+
</MacroExpansion>
92+
</ProfileAction>
93+
<AnalyzeAction
94+
buildConfiguration = "Debug">
95+
</AnalyzeAction>
96+
<ArchiveAction
97+
buildConfiguration = "Release"
98+
revealArchiveInOrganizer = "YES">
99+
</ArchiveAction>
100+
</Scheme>

MapboxGeocoder/Info.plist

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
33
<plist version="1.0">
44
<dict>
5+
<key>NSHumanReadableCopyright</key>
6+
<string>Copyright © 2014–2016 Mapbox. All rights reserved.</string>
57
<key>CFBundleDevelopmentRegion</key>
68
<string>en</string>
79
<key>CFBundleExecutable</key>

MapboxGeocoder/MBGeocodeOptions.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public class ForwardGeocodeOptions: GeocodeOptions {
103103

104104
- parameter postalAddress: A `CNPostalAddress` object to search for.
105105
*/
106-
@available(iOS 9.0, *)
106+
@available(iOS 9.0, OSX 10.11, *)
107107
public convenience init(postalAddress: CNPostalAddress) {
108108
let formattedAddress = CNPostalAddressFormatter().stringFromPostalAddress(postalAddress)
109109
self.init(query: formattedAddress.stringByReplacingOccurrencesOfString("\n", withString: ", "))

MapboxGeocoder/MBPlacemark.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ public class Placemark: NSObject, NSCopying, NSSecureCoding {
226226

227227
To format the postal address, use a `CNPostalAddressFormatter` object.
228228
*/
229-
@available(iOS 9.0, *)
229+
@available(iOS 9.0, OSX 10.11, *)
230230
public var postalAddress: CNPostalAddress? {
231231
return nil
232232
}
@@ -424,7 +424,7 @@ public class GeocodedPlacemark: Placemark {
424424
return scope == .Address ? lines : Array(lines.suffixFrom(1))
425425
}
426426

427-
@available(iOS 9.0, *)
427+
@available(iOS 9.0, OSX 10.11, *)
428428
public override var postalAddress: CNPostalAddress? {
429429
let postalAddress = CNMutablePostalAddress()
430430

MapboxGeocoderTests/ReverseGeocodingTests.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,6 @@ class ReverseGeocodingTests: XCTestCase {
6767

6868
let southWest = CLLocationCoordinate2D(latitude: 37.033229992893, longitude: -95.927990005645)
6969
let northEast = CLLocationCoordinate2D(latitude: 37.35632800706, longitude: -95.594628992671)
70-
XCTAssertNotNil(placePlacemark?.region, "reverse geocode should populate region")
7170
let region = placePlacemark?.region as! RectangularRegion
7271
XCTAssertEqualWithAccuracy(region.southWest.latitude, southWest.latitude, accuracy: 0.000000000001)
7372
XCTAssertEqualWithAccuracy(region.southWest.longitude, southWest.longitude, accuracy: 0.000000000001)

Podfile

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
platform :ios, '8.0'
21
use_frameworks!
32

43
#def shared_pods
@@ -8,6 +7,16 @@ use_frameworks!
87
# shared_pods
98
#end
109

10+
def shared_test_pods
11+
pod 'Nocilla', :configurations => ['Debug']
12+
end
13+
1114
target 'MapboxGeocoderTests' do
12-
pod 'Nocilla'
15+
platform :ios, '8.0'
16+
shared_test_pods
17+
end
18+
19+
target 'MapboxGeocoderMacTests' do
20+
platform :osx, '10.10'
21+
shared_test_pods
1322
end

0 commit comments

Comments
 (0)