Distribution target now builds the XCFramework as well

This commit is contained in:
Jonas Zaugg committed 2020-08-03 01:43:33 +02:00
1 parent 17d78dfc0f
commit a56ca505ea
5 files changed
+134 -5

No files matched your search

-2
View File
@@ -4,6 +4,4 @@ osx_image:
- xcode11.4
- xcode12u
script:
- set -o pipefail && xcodebuild -scheme Sparkle -configuration Debug -derivedDataPath build -archivePath build/Build/Products/Debug/Sparkle.xcarchive BUILD_LIBRARY_FOR_DISTRIBUTION=YES SKIP_INSTALL=NO archive | xcpretty
- set -o pipefail && xcodebuild -create-xcframework -framework build/Build/Products/Debug/Sparkle.xcarchive/Products/Library/Frameworks/Sparkle.framework -output build/Build/Products/Debug/Sparkle.xcframework
- set -o pipefail && xcodebuild test -project Sparkle.xcodeproj -scheme Distribution -derivedDataPath build -enableCodeCoverage YES | xcpretty
-2
View File
@@ -13,8 +13,6 @@ localizable-strings:
rm Sparkle/en.lproj/Localizable.strings
release:
xcodebuild -scheme Sparkle -configuration Release -derivedDataPath "$(BUILDDIR)" -archivePath "$(BUILDDIR)/Build/Products/Release/Sparkle.xcarchive" BUILD_LIBRARY_FOR_DISTRIBUTION=YES SKIP_INSTALL=NO archive
xcodebuild -create-xcframework -framework "$(BUILDDIR)/Build/Products/Release/Sparkle.xcarchive/Products/Library/Frameworks/Sparkle.framework" -debug-symbols "$(BUILDDIR)/Build/Products/Release/Sparkle.xcarchive/dSYMs/Sparkle.framework.dSYM" -output "$(BUILDDIR)/Build/Products/Release/Sparkle.xcframework"
xcodebuild -scheme Distribution -configuration Release -derivedDataPath "$(BUILDDIR)" build
open "$(BUILDDIR)/Build/Products/Release/"
cat Sparkle.podspec
+1 -1
View File
@@ -2,7 +2,7 @@
import PackageDescription
let version = "1.24.0"
let checksum = "099ae1e045e254fbf803f98ff74607123bbd288c4f17725e19be5704b8039ef4"
let checksum = "2b6fec0cad2bb643ed222b708f37bf9e98f5ed84d77c9ba69e66dd2b82b0fffa"
let url = "https://github.com/sparkle-project/Sparkle/releases/download/\(version)/Sparkle-SPM-\(version).zip"
let package = Package(
+66
View File
@@ -25,6 +25,17 @@
name = All;
productName = All;
};
895C5DB924D75F370058A82D /* Sparkle.xcframework */ = {
isa = PBXAggregateTarget;
buildConfigurationList = 895C5DBC24D75F370058A82D /* Build configuration list for PBXAggregateTarget "Sparkle.xcframework" */;
buildPhases = (
895C5DBD24D75F590058A82D /* ShellScript */,
);
dependencies = (
);
name = Sparkle.xcframework;
productName = Sparkle.xcframework;
};
/* End PBXAggregateTarget section */
/* Begin PBXBuildFile section */
@@ -468,6 +479,13 @@
remoteGlobalIDString = 61B5F90109C4CEE200B25A18;
remoteInfo = "Sparkle Test App";
};
895C5DBE24D764DD0058A82D /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 0867D690FE84028FC02AAC07 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 895C5DB924D75F370058A82D;
remoteInfo = Sparkle.xcframework;
};
/* End PBXContainerItemProxy section */
/* Begin PBXCopyFilesBuildPhase section */
@@ -1749,6 +1767,7 @@
14732BCB1960F73500593899 /* PBXTargetDependency */,
1454BA1619637EDB00344E57 /* PBXTargetDependency */,
14732BCF1960F73500593899 /* PBXTargetDependency */,
895C5DBF24D764DD0058A82D /* PBXTargetDependency */,
1454BA1819637EE900344E57 /* PBXTargetDependency */,
);
name = Distribution;
@@ -2008,6 +2027,9 @@
LastSwiftMigration = 0800;
TestTargetID = 61B5F90109C4CEE200B25A18;
};
895C5DB924D75F370058A82D = {
CreatedOnToolsVersion = 12.0;
};
8DC2EF4F0486A6940098B216 = {
LastSwiftMigration = 0920;
};
@@ -2080,6 +2102,7 @@
14732BC51960F69300593899 /* Distribution */,
1420DF491962329200203BB0 /* Documentation */,
1495005F195FB89400BC5B5B /* All */,
895C5DB924D75F370058A82D /* Sparkle.xcframework */,
726B2B5C1C645FC900388755 /* UI Tests */,
722954B31D04ADAF00ECF9CA /* fileop */,
5AA96C541E0AE0DB00CA4346 /* generate_appcast */,
@@ -2225,6 +2248,23 @@
shellScript = "ln -sfh \"pt_BR.lproj\" \"$BUILT_PRODUCTS_DIR/$UNLOCALIZED_RESOURCES_FOLDER_PATH/pt.lproj\"";
showEnvVarsInLog = 0;
};
895C5DBD24D75F590058A82D /* ShellScript */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputFileListPaths = (
);
inputPaths = (
);
outputFileListPaths = (
);
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "# Deleting old products\nrm -rd \"$BUILT_PRODUCTS_DIR/Sparkle.xcarchive\"\nrm -rd \"$BUILT_PRODUCTS_DIR/Sparkle.xcframework\"\n\nxcodebuild archive -scheme Sparkle -archivePath \"$BUILT_PRODUCTS_DIR/Sparkle.xcarchive\" BUILD_LIBRARY_FOR_DISTRIBUTION=YES SKIP_INSTALL=NO\n\n# These build number checks are only because -debug-symbols is only available since Xcode 12 beta 3. Once Travis CI updates its Xcode images to the latests betas, this check can simplified to `[ $XCODE_VERSION_MAJOR -ge \"1200\" ]`\nre='^([0-9]+)[A-Z]{1}([0-9]+)[a-z]$'\n[[ $XCODE_PRODUCT_BUILD_VERSION =~ $re ]]\nXCODE_SHORT_BUILD=${BASH_REMATCH[2]}\nif [ $XCODE_VERSION_MAJOR -ge \"1200\" ] && [ $XCODE_SHORT_BUILD -ge \"8169\" ]; then\nxcodebuild -create-xcframework -framework \"$BUILT_PRODUCTS_DIR/Sparkle.xcarchive/Products/Library/Frameworks/Sparkle.framework\" -debug-symbols \"$BUILT_PRODUCTS_DIR/Sparkle.xcarchive/dSYMs/Sparkle.framework.dSYM\" -output \"$BUILT_PRODUCTS_DIR/Sparkle.xcframework\"\nelse\necho \"warning: Your Xcode version does not support bundling dSYMs in XCFrameworks directly. You should copy them manually into the XCFramework.\"\necho \"note: cp '$BUILT_PRODUCTS_DIR/Sparkle.xcarchive/dSYMs/Sparkle.framework.dSYM' '$BUILT_PRODUCTS_DIR/Sparkle.xcframework/your_architecture/dSYMs'\"\nxcodebuild -create-xcframework -framework \"$BUILT_PRODUCTS_DIR/Sparkle.xcarchive/Products/Library/Frameworks/Sparkle.framework\" -output \"$BUILT_PRODUCTS_DIR/Sparkle.xcframework\"\nfi\n";
};
/* End PBXShellScriptBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
@@ -2560,6 +2600,11 @@
target = 61B5F90109C4CEE200B25A18 /* Sparkle Test App */;
targetProxy = 726B2B621C645FC900388755 /* PBXContainerItemProxy */;
};
895C5DBF24D764DD0058A82D /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 895C5DB924D75F370058A82D /* Sparkle.xcframework */;
targetProxy = 895C5DBE24D764DD0058A82D /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin PBXVariantGroup section */
@@ -2984,6 +3029,18 @@
};
name = Release;
};
895C5DBA24D75F370058A82D /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
};
name = Debug;
};
895C5DBB24D75F370058A82D /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
};
name = Release;
};
EA4311A2229D5FBC00A5503D /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = EA4311C9229D614300A5503D /* ed25519-Debug.xcconfig */;
@@ -3141,6 +3198,15 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
895C5DBC24D75F370058A82D /* Build configuration list for PBXAggregateTarget "Sparkle.xcframework" */ = {
isa = XCConfigurationList;
buildConfigurations = (
895C5DBA24D75F370058A82D /* Debug */,
895C5DBB24D75F370058A82D /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
EA4311A1229D5FBC00A5503D /* Build configuration list for PBXNativeTarget "ed25519" */ = {
isa = XCConfigurationList;
buildConfigurations = (
@@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1200"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "895C5DB924D75F370058A82D"
BuildableName = "Sparkle.xcframework"
BlueprintName = "Sparkle.xcframework"
ReferencedContainer = "container:Sparkle.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">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "895C5DB924D75F370058A82D"
BuildableName = "Sparkle.xcframework"
BlueprintName = "Sparkle.xcframework"
ReferencedContainer = "container:Sparkle.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>