Add workaround for Xcode bug
This commit is contained in:
parent
5df16e0d2e
commit
39160d389f
|
@ -13,4 +13,5 @@ Pod::Spec.new do |s|
|
||||||
s.ios.deployment_target = '10.0'
|
s.ios.deployment_target = '10.0'
|
||||||
s.tvos.deployment_target = '10.0'
|
s.tvos.deployment_target = '10.0'
|
||||||
s.watchos.deployment_target = '3.0'
|
s.watchos.deployment_target = '3.0'
|
||||||
|
s.weak_framework = 'Combine'
|
||||||
end
|
end
|
||||||
|
|
|
@ -646,6 +646,10 @@
|
||||||
MACOSX_DEPLOYMENT_TARGET = 10.12;
|
MACOSX_DEPLOYMENT_TARGET = 10.12;
|
||||||
MTL_ENABLE_DEBUG_INFO = YES;
|
MTL_ENABLE_DEBUG_INFO = YES;
|
||||||
ONLY_ACTIVE_ARCH = YES;
|
ONLY_ACTIVE_ARCH = YES;
|
||||||
|
OTHER_LDFLAGS = (
|
||||||
|
"-weak_framework",
|
||||||
|
Combine,
|
||||||
|
);
|
||||||
SDKROOT = iphoneos;
|
SDKROOT = iphoneos;
|
||||||
SWIFT_COMPILATION_MODE = singlefile;
|
SWIFT_COMPILATION_MODE = singlefile;
|
||||||
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
|
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
|
||||||
|
@ -701,6 +705,10 @@
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
|
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
|
||||||
MACOSX_DEPLOYMENT_TARGET = 10.12;
|
MACOSX_DEPLOYMENT_TARGET = 10.12;
|
||||||
MTL_ENABLE_DEBUG_INFO = NO;
|
MTL_ENABLE_DEBUG_INFO = NO;
|
||||||
|
OTHER_LDFLAGS = (
|
||||||
|
"-weak_framework",
|
||||||
|
Combine,
|
||||||
|
);
|
||||||
SDKROOT = iphoneos;
|
SDKROOT = iphoneos;
|
||||||
SWIFT_VERSION = 5.0;
|
SWIFT_VERSION = 5.0;
|
||||||
TARGETED_DEVICE_FAMILY = "1,2";
|
TARGETED_DEVICE_FAMILY = "1,2";
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
> Swifty and modern [UserDefaults](https://developer.apple.com/documentation/foundation/userdefaults)
|
> Swifty and modern [UserDefaults](https://developer.apple.com/documentation/foundation/userdefaults)
|
||||||
|
|
||||||
#### Note: The readme reflects the master branch. [Click here](https://github.com/sindresorhus/Defaults/tree/55ffea9487fb9b559406d909ee31dcd955fe77aa#readme) for docs for the latest version. The code in the master branch cannot be released until Apple fixes [this bug](https://github.com/feedback-assistant/reports/issues/44).
|
Store key-value pairs persistently across launches of your app.
|
||||||
|
|
||||||
It uses `NSUserDefaults` underneath but exposes a type-safe facade with lots of nice conveniences.
|
It uses `NSUserDefaults` underneath but exposes a type-safe facade with lots of nice conveniences.
|
||||||
|
|
||||||
|
@ -16,7 +16,6 @@ It's used in production by apps like [Gifski](https://github.com/sindresorhus/Gi
|
||||||
- **Debuggable:** The data is stored as JSON-serialized values.
|
- **Debuggable:** The data is stored as JSON-serialized values.
|
||||||
- **Observation:** Observe changes to keys.
|
- **Observation:** Observe changes to keys.
|
||||||
- **Publishers:** Combine publishers built-in.
|
- **Publishers:** Combine publishers built-in.
|
||||||
- **Lightweight:** It's only some hundred lines of code.
|
|
||||||
|
|
||||||
## Compatibility
|
## Compatibility
|
||||||
|
|
||||||
|
@ -27,12 +26,14 @@ It's used in production by apps like [Gifski](https://github.com/sindresorhus/Gi
|
||||||
|
|
||||||
## Install
|
## Install
|
||||||
|
|
||||||
#### SwiftPM
|
#### Swift Package Manager
|
||||||
|
|
||||||
```swift
|
```swift
|
||||||
.package(url: "https://github.com/sindresorhus/Defaults", from: "3.1.1")
|
.package(url: "https://github.com/sindresorhus/Defaults", from: "3.1.1")
|
||||||
```
|
```
|
||||||
|
|
||||||
|
You need to set the build setting “Other Linker Flags” to `-weak_framework Combine` to work around [this Xcode bug](https://github.com/feedback-assistant/reports/issues/44).
|
||||||
|
|
||||||
#### Carthage
|
#### Carthage
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in New Issue