Skip to content

Commit

Permalink
Lower min. support OS version to iOS 7.0 ia cocoapods static lib appr…
Browse files Browse the repository at this point in the history
…oach
  • Loading branch information
tonyxiao committed Jun 1, 2016
1 parent 10dca69 commit 41b5a38
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 19 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ before_install:

script:
- pod lib lint
- cd Example && pod install
- make xctest

notifications:
Expand Down
2 changes: 1 addition & 1 deletion Analytics.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Pod::Spec.new do |s|
s.source = { :git => "https://github.com/segmentio/analytics-ios.git", :tag => s.version.to_s }
s.social_media_url = 'https://twitter.com/segment'

s.platform = :ios, '8.0'
s.platform = :ios, '7.0'
s.requires_arc = true

s.source_files = 'Pod/Classes/**/*'
Expand Down
24 changes: 12 additions & 12 deletions Example/Analytics.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
objects = {

/* Begin PBXBuildFile section */
122DABF232B657A04E9D6F2A /* Pods_Analytics_Tests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C833E37EF6F373E35551B383 /* Pods_Analytics_Tests.framework */; };
6003F58E195388D20070C39A /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F58D195388D20070C39A /* Foundation.framework */; };
6003F590195388D20070C39A /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F58F195388D20070C39A /* CoreGraphics.framework */; };
6003F592195388D20070C39A /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F591195388D20070C39A /* UIKit.framework */; };
Expand All @@ -21,8 +20,9 @@
6003F5B2195388D20070C39A /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F591195388D20070C39A /* UIKit.framework */; };
6003F5BA195388D20070C39A /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 6003F5B8195388D20070C39A /* InfoPlist.strings */; };
6003F5BC195388D20070C39A /* Tests.m in Sources */ = {isa = PBXBuildFile; fileRef = 6003F5BB195388D20070C39A /* Tests.m */; };
6DE67E5B3C92A7A719FB1109 /* Pods_Analytics_Example.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C25912115FF4A29B0521D876 /* Pods_Analytics_Example.framework */; };
873B8AEB1B1F5CCA007FD442 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 873B8AEA1B1F5CCA007FD442 /* Main.storyboard */; };
B6B69174B8EAA64C01EDD644 /* libPods-Analytics_Tests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = BAA8CFA2CA39DFEFB0B4A520 /* libPods-Analytics_Tests.a */; };
CC7D156E582FE75AAEF30570 /* libPods-Analytics_Example.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2ECB738061269756D79D2839 /* libPods-Analytics_Example.a */; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
Expand All @@ -36,6 +36,7 @@
/* End PBXContainerItemProxy section */

/* Begin PBXFileReference section */
2ECB738061269756D79D2839 /* libPods-Analytics_Example.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Analytics_Example.a"; sourceTree = BUILT_PRODUCTS_DIR; };
4398A76BA16301B343B055FF /* LICENSE */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = LICENSE; path = ../LICENSE; sourceTree = "<group>"; };
6003F58A195388D20070C39A /* Analytics_Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Analytics_Example.app; sourceTree = BUILT_PRODUCTS_DIR; };
6003F58D195388D20070C39A /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
Expand All @@ -59,9 +60,8 @@
873B8AEA1B1F5CCA007FD442 /* Main.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Main.storyboard; sourceTree = "<group>"; };
8FEA162EBB32A01193A36FD9 /* Pods-Analytics_Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Analytics_Tests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Analytics_Tests/Pods-Analytics_Tests.debug.xcconfig"; sourceTree = "<group>"; };
B8D03E96F2158F0BD5D007C2 /* Analytics.podspec */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = Analytics.podspec; path = ../Analytics.podspec; sourceTree = "<group>"; };
C25912115FF4A29B0521D876 /* Pods_Analytics_Example.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Analytics_Example.framework; sourceTree = BUILT_PRODUCTS_DIR; };
BAA8CFA2CA39DFEFB0B4A520 /* libPods-Analytics_Tests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Analytics_Tests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
C3D52AB1A713A4EC11A7AABA /* Pods-Analytics_Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Analytics_Example.release.xcconfig"; path = "Pods/Target Support Files/Pods-Analytics_Example/Pods-Analytics_Example.release.xcconfig"; sourceTree = "<group>"; };
C833E37EF6F373E35551B383 /* Pods_Analytics_Tests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Analytics_Tests.framework; sourceTree = BUILT_PRODUCTS_DIR; };
D4F0C65D9D06E2AA8DEDCB9A /* README.md */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = net.daringfireball.markdown; name = README.md; path = ../README.md; sourceTree = "<group>"; };
D55692E82B836889CD938ABC /* Pods-Analytics_Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Analytics_Tests.release.xcconfig"; path = "Pods/Target Support Files/Pods-Analytics_Tests/Pods-Analytics_Tests.release.xcconfig"; sourceTree = "<group>"; };
F58ADB4EB6592C175E408A45 /* Pods-Analytics_Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Analytics_Example.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Analytics_Example/Pods-Analytics_Example.debug.xcconfig"; sourceTree = "<group>"; };
Expand All @@ -75,7 +75,7 @@
6003F590195388D20070C39A /* CoreGraphics.framework in Frameworks */,
6003F592195388D20070C39A /* UIKit.framework in Frameworks */,
6003F58E195388D20070C39A /* Foundation.framework in Frameworks */,
6DE67E5B3C92A7A719FB1109 /* Pods_Analytics_Example.framework in Frameworks */,
CC7D156E582FE75AAEF30570 /* libPods-Analytics_Example.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand All @@ -86,7 +86,7 @@
6003F5B0195388D20070C39A /* XCTest.framework in Frameworks */,
6003F5B2195388D20070C39A /* UIKit.framework in Frameworks */,
6003F5B1195388D20070C39A /* Foundation.framework in Frameworks */,
122DABF232B657A04E9D6F2A /* Pods_Analytics_Tests.framework in Frameworks */,
B6B69174B8EAA64C01EDD644 /* libPods-Analytics_Tests.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -132,8 +132,8 @@
6003F58F195388D20070C39A /* CoreGraphics.framework */,
6003F591195388D20070C39A /* UIKit.framework */,
6003F5AF195388D20070C39A /* XCTest.framework */,
C25912115FF4A29B0521D876 /* Pods_Analytics_Example.framework */,
C833E37EF6F373E35551B383 /* Pods_Analytics_Tests.framework */,
2ECB738061269756D79D2839 /* libPods-Analytics_Example.a */,
BAA8CFA2CA39DFEFB0B4A520 /* libPods-Analytics_Tests.a */,
);
name = Frameworks;
sourceTree = "<group>";
Expand Down Expand Up @@ -466,7 +466,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down Expand Up @@ -499,7 +499,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
Expand All @@ -515,7 +515,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "Analytics/Analytics-Prefix.pch";
INFOPLIST_FILE = "Analytics/Analytics-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
MODULE_NAME = ExampleApp;
PRODUCT_NAME = "$(TARGET_NAME)";
WRAPPER_EXTENSION = app;
Expand All @@ -531,7 +531,7 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "Analytics/Analytics-Prefix.pch";
INFOPLIST_FILE = "Analytics/Analytics-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
MODULE_NAME = ExampleApp;
PRODUCT_NAME = "$(TARGET_NAME)";
WRAPPER_EXTENSION = app;
Expand Down
8 changes: 6 additions & 2 deletions Example/Podfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
source 'https://github.com/CocoaPods/Specs.git'
use_frameworks!

platform :ios, '7.0'
# TODO: We should probably have two test cases. One for iOS 7 and one for iOS 8+
# iOS 7 projects cannot use frameworks, we will go with lowest common denominator for now
# use_frameworks!

target 'Analytics_Example' do
pod "Analytics", :path => "../"
end

target 'Analytics_Tests' do
pod "Analytics", :path => "../"
# pod "Analytics", :path => "../"

pod 'Specta'
pod 'Expecta'
Expand Down
4 changes: 2 additions & 2 deletions Example/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ EXTERNAL SOURCES:
:path: "../"

SPEC CHECKSUMS:
Analytics: d9b9db09967ae2a37434799bc38caac67cdf4d8e
Analytics: 1393ae70310d801956c40d1b470de85499f15ddf
Expecta: 9d1bff6c8b0eeee73a166a2ee898892478927a15
Specta: 69bb134672aae190a1379ff91df07dad8dd1f869

PODFILE CHECKSUM: 6aa45f51c7bcf2c7423969960b94a840ad362b9c
PODFILE CHECKSUM: 244c8b6283b535c9cb0a624f80bcc0ebe6fc0b54

COCOAPODS: 1.0.0
4 changes: 2 additions & 2 deletions Example/Tests/Tests-Prefix.pch
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

#ifdef __OBJC__

@import Specta;
@import Expecta;
#import <Specta/Specta.h>
#import <Expecta/Expecta.h>

#endif

0 comments on commit 41b5a38

Please sign in to comment.