From 7e9956725b892992c0ee6ce41d86b6fffc38df3c Mon Sep 17 00:00:00 2001 From: Pedro Cuenca Date: Thu, 29 Dec 2022 18:27:27 +0100 Subject: [PATCH] Move code-signing to minimal xcconfig file. Code signing is disabled for macOS. Users are instructed to update the development team when they fork or clone the repo, if they want to target iOS. Co-authored-by: Fahim Farook --- Diffusion.xcodeproj/project.pbxproj | 6 ++++-- README.md | 4 ++++ config/common.xcconfig | 15 +++++++++++++++ 3 files changed, 23 insertions(+), 2 deletions(-) create mode 100644 config/common.xcconfig diff --git a/Diffusion.xcodeproj/project.pbxproj b/Diffusion.xcodeproj/project.pbxproj index 3517609..ac5f159 100644 --- a/Diffusion.xcodeproj/project.pbxproj +++ b/Diffusion.xcodeproj/project.pbxproj @@ -44,6 +44,7 @@ EB33A51E2954E1BC00B16357 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; path = Info.plist; sourceTree = ""; }; EBB5BA5229425BEE003A2A5B /* PipelineLoader.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PipelineLoader.swift; sourceTree = ""; }; EBB5BA5929426E06003A2A5B /* Downloader.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Downloader.swift; sourceTree = ""; }; + EBE3FF4A295DFE2400E921AA /* common.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = common.xcconfig; path = config/common.xcconfig; sourceTree = ""; }; EBE4438729488DCA00CDA605 /* README.md */ = {isa = PBXFileReference; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = ""; }; EBE443892948953600CDA605 /* LICENSE */ = {isa = PBXFileReference; lastKnownFileType = text; path = LICENSE; sourceTree = ""; }; EBE755C5293E37DD00806B32 /* Diffusion.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Diffusion.app; sourceTree = BUILT_PRODUCTS_DIR; }; @@ -101,6 +102,7 @@ EBE755BC293E37DD00806B32 = { isa = PBXGroup; children = ( + EBE3FF4A295DFE2400E921AA /* common.xcconfig */, EBE4438729488DCA00CDA605 /* README.md */, EBE443892948953600CDA605 /* LICENSE */, EBE755FF293E910800806B32 /* Packages */, @@ -478,6 +480,7 @@ }; EBE755EB293E37DE00806B32 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = EBE3FF4A295DFE2400E921AA /* common.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; @@ -485,7 +488,6 @@ CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_ASSET_PATHS = "\"Diffusion/Preview Content\""; - DEVELOPMENT_TEAM = ZWDJQ796RU; ENABLE_HARDENED_RUNTIME = YES; ENABLE_PREVIEWS = YES; GENERATE_INFOPLIST_FILE = YES; @@ -519,6 +521,7 @@ }; EBE755EC293E37DE00806B32 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = EBE3FF4A295DFE2400E921AA /* common.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; @@ -526,7 +529,6 @@ CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_ASSET_PATHS = "\"Diffusion/Preview Content\""; - DEVELOPMENT_TEAM = ZWDJQ796RU; ENABLE_HARDENED_RUNTIME = YES; ENABLE_PREVIEWS = YES; GENERATE_INFOPLIST_FILE = YES; diff --git a/README.md b/README.md index 4cc4ac2..b052551 100644 --- a/README.md +++ b/README.md @@ -16,6 +16,10 @@ For faster inference, we use a very fast scheduler: [DPM-Solver++](https://githu * ~10s in macOS on MacBook Pro M1 Max (64 GB). * ~1 min 15s in iPhone 14 Pro. +## How to Build + +If you clone or fork this repo, please update `common.xcconfig` with your development team identifier. Code signing is required to run on iOS, but it's currently disabled for macOS. + ## Limitations - The UI does not expose a way to configure the scheduler, number of inference steps, or generation seed. These are all available in the underlying code. diff --git a/config/common.xcconfig b/config/common.xcconfig new file mode 100644 index 0000000..6586cde --- /dev/null +++ b/config/common.xcconfig @@ -0,0 +1,15 @@ +// +// common.xcconfig +// Diffusion +// +// Created by Pedro Cuenca on 202212. +// + +// Configuration settings file format documentation can be found at: +// https://help.apple.com/xcode/#/dev745c5c974 + +// Update if you fork this repo +DEVELOPMENT_TEAM = ZWDJQ796RU + +// Disable code-signing for macOS +CODE_SIGN_IDENTITY[sdk=macos*] =