Skip to content

Commit

Permalink
feat: Support Carthage XCFrameworks (#88)
Browse files Browse the repository at this point in the history
* test: carthage download test
* feat(ios): create simple build script for building xcframework with carthage
* feat: update .gitignore to ignore Carthage build artifacts, update verify script
* fix(android): readme and to incr. version
* chore: cap 3.2.5 doc updates
* chore(android): updated Capacitor Dependency version to 3.2.5
* Release 0.2.2
* refactor: move cartfile to root to pull in cap dependency
Co-authored-by: Carl Poole <carl@ionic.io>
  • Loading branch information
thomasvidas authored Nov 4, 2021
1 parent c0aa4e5 commit 3b8ab2a
Show file tree
Hide file tree
Showing 8 changed files with 172 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -193,3 +193,7 @@ iOSInjectionProject/
# ==========
node_modules
plugin/dist

# Carthage
Carthage
IonicPortals.xcframework.zip
1 change: 1 addition & 0 deletions Cartfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github "ionic-team/capacitor" == 3.2.5
1 change: 1 addition & 0 deletions Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github "ionic-team/capacitor" "3.2.5"
3 changes: 3 additions & 0 deletions carthage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
carthage update --use-xcframeworks
carthage build --no-skip-current --use-xcframeworks
zip -r IonicPortals.xcframework.zip Carthage
8 changes: 6 additions & 2 deletions ios/IonicPortals/IonicPortals.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
BUILD_LIBRARY_FOR_DISTRIBUTION = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
Expand Down Expand Up @@ -372,6 +373,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
BUILD_LIBRARY_FOR_DISTRIBUTION = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
Expand Down Expand Up @@ -448,7 +450,7 @@
PRODUCT_BUNDLE_IDENTIFIER = io.ionic.IonicPortals;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
PROVISIONING_PROFILE_SPECIFIER = "";
SKIP_INSTALL = YES;
SKIP_INSTALL = NO;
SUPPORTS_MACCATALYST = NO;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 5.0;
Expand Down Expand Up @@ -478,7 +480,7 @@
PRODUCT_BUNDLE_IDENTIFIER = io.ionic.IonicPortals;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
PROVISIONING_PROFILE_SPECIFIER = "";
SKIP_INSTALL = YES;
SKIP_INSTALL = NO;
SUPPORTS_MACCATALYST = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
Expand All @@ -499,6 +501,7 @@
);
PRODUCT_BUNDLE_IDENTIFIER = io.ionic.IonicPortalsTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
Expand All @@ -518,6 +521,7 @@
);
PRODUCT_BUNDLE_IDENTIFIER = io.ionic.IonicPortalsTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1300"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "E985F87F269E2D260031F820"
BuildableName = "IonicPortals.framework"
BlueprintName = "IonicPortals"
ReferencedContainer = "container:IonicPortals.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "E985F888269E2D260031F820"
BuildableName = "IonicPortalsTests.xctest"
BlueprintName = "IonicPortalsTests"
ReferencedContainer = "container:IonicPortals.xcodeproj">
</BuildableReference>
</TestableReference>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "E985F87F269E2D260031F820"
BuildableName = "IonicPortals.framework"
BlueprintName = "IonicPortals"
ReferencedContainer = "container:IonicPortals.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1300"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "E985F809269E259D0031F820"
BuildableName = "PortalsTestApp.app"
BlueprintName = "PortalsTestApp (iOS)"
ReferencedContainer = "container:PortalsTestApp.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "E985F809269E259D0031F820"
BuildableName = "PortalsTestApp.app"
BlueprintName = "PortalsTestApp (iOS)"
ReferencedContainer = "container:PortalsTestApp.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "E985F809269E259D0031F820"
BuildableName = "PortalsTestApp.app"
BlueprintName = "PortalsTestApp (iOS)"
ReferencedContainer = "container:PortalsTestApp.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
3 changes: 2 additions & 1 deletion ios/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
},
"files": [],
"scripts": {
"verify": "xcodebuild -workspace IonicPortals.xcworkspace -scheme IonicPortals"
"verify": "xcodebuild -workspace IonicPortals.xcworkspace -scheme IonicPortals -destination generic/platform=iOS",
"carthage": "sh carthage.sh"
},
"private": true
}

1 comment on commit 3b8ab2a

@vercel
Copy link

@vercel vercel bot commented on 3b8ab2a Nov 4, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.