-
-
Notifications
You must be signed in to change notification settings - Fork 843
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Target iOS 12.0 #786
Target iOS 12.0 #786
Conversation
That's a compilation error from RCTTypeSafety, which is a react library. Please search first (it shows up in the first results on a web search as a react-native issue already fixed in later versions - facebook/react-native#34106 |
@mikehardy This issue is affecting multiple libs across the ecosystem. For example react-native-svg: software-mansion/react-native-svg#2041 Yes, I'm aware of the GitHub issue about Furthermore, it looks like RCTTypeSafety sets 12.4 as the iOS version. So I still believe this PR is valid, although I agree it's a bit weird. |
This PR is a breaking change that causes this library to no longer support older versions, and is related to code that is not in the library. It is off-target here, I do not believe it is valid. Use a Podfile post_install step to modify the target versions if you need it, I think. |
I verified this would drop support for anyone on react-native < 0.69, 0.68 supported iOS11 This may be something @zoontek agrees with, it may not, but it seems pretty strange for me for a react-native issue to force libraries to adopt a breaking change that cuts off older versions - this is part of what forces people to prematurely landfill devices for no good reason |
28dabef
to
a505b43
Compare
I've updated the PR as per @numandev1's suggestion. |
@hsjoberg Hi, and thanks for the PR! I have a small suggestion: maybe we should migrate to require "json"
package = JSON.parse(File.read(File.join(__dir__, "package.json")))
Pod::Spec.new do |s|
s.name = "RNPermissions"
s.version = package["version"]
s.license = package["license"]
s.summary = package["description"]
s.author = package["author"]
s.homepage = package["homepage"]
s.requires_arc = true
s.source = { :git => package["repository"]["url"], :tag => s.version }
s.source_files = "ios/*.{h,m,mm}"
if ENV['RCT_NEW_ARCH_ENABLED'] == '1' then
install_modules_dependencies(s)
s.platforms = { :ios => "12.4", :tvos => "12.4" }
else
s.dependency "React-Core"
s.platforms = { :ios => "10.0", :tvos => "11.0" }
end
end This solve the issue without any breaking and its IMHO a cleaner way to handle both archs. Could you make the change and copy this instead? |
@zoontek sure I'll fix that. |
a505b43
to
f216709
Compare
I've changed to suggested code and tested building with new arch both activated and inactivated. |
Thanks, it's published under 3.8.4: https://github.com/zoontek/react-native-permissions/releases/tag/3.8.4 |
Summary
Hey.
value
which is available in iOS >= 12.0 is being used, causing compilation to fail on newer XCode versions.This PR bumps the iOS target to version 12.0.
I'm not sure about tvOS.
Checklist