Skip to content
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

The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0 #8860

Open
kieranbarlow opened this issue Sep 17, 2020 · 11 comments

Comments

@kieranbarlow
Copy link

kieranbarlow commented Sep 17, 2020

Describe the bug

After installing the latest xcode for ios14 deployment I can no longer run

tns run ios

I get the error

warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 9.0 to 14.0.99. (in target 'MDFInternationalization' from project 'Pods') ** BUILD FAILED **

To Reproduce

  1. Install latest xcode
  2. tns create testApp
  3. tns run ios

Expected behavior

App to appear on ios simulator running ios14

Additional context

  • It was fully functional before the latest xcode update.
  • I've tried removing the cli and reinstalling
  • I've tried adding IPHONEOS_DEPLOYMENT_TARGET = 14.0; to the build.xcconfig file
  • The only way I can get it working is if I open the workspace directly in xcode and edit the POD file then hit run from xcode.

Environment

{
  "nativescript": {
    "id": "org.nativescript.srapp",
    "tns-android": {
      "version": "6.5.3-20200708-01"
    },
    "tns-ios": {
      "version": "6.5.2"
    }
  },
  "description": "NativeScript Application",
  "license": "SEE LICENSE IN <your-license-filename>",
  "repository": "<fill-your-repository-here>",
  "dependencies": {
    "@nativescript/theme": "~2.3.0",
    "nativescript-vue": "~2.4.0",
    "tns-core-modules": "6.6.0-next-2020-05-08-112112-01"
  },
  "devDependencies": {
    "@babel/core": "~7.1.0",
    "@babel/preset-env": "~7.1.0",
    "babel-loader": "~8.0.0",
    "nativescript-dev-webpack": "~1.5.0",
    "nativescript-vue-template-compiler": "~2.4.0",
    "node-sass": "^4.7.1",
    "vue-loader": "~15.4.0"
  },
...
@iMarwan-k
Copy link

iMarwan-k commented Sep 18, 2020

having the same issue

@tuliodiaz
Copy link

tuliodiaz commented Sep 18, 2020

Posible duplicated #8780

@wkjesus
Copy link

wkjesus commented Sep 18, 2020

i have exactly the same scenario.. just update xcode.. and the project get broken with that issue, any suggestion?

@farfromrefug
Copy link
Collaborator

farfromrefug commented Sep 18, 2020

@tuliodiaz @wkjesus @iMarwan-k @kieranbarlow this is a cocoapod issue.
It can be fixed by adding

post_install do |pi|
    pi.pods_project.targets.each do |t|
        t.build_configurations.each do |config|
            config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '9.0'
        end
    end
end

to your Podfile (create if not exist) in your app App_Resources/iOS/Podfile. Remember to remove platforms before building.

@rigor789 this can done automatically by the cli.

@asharghi
Copy link
Contributor

asharghi commented Sep 18, 2020

Better to delete it, then to set it to 9.0. Then it will inherit the project/workspace deployment taget (which is set in build.xcconfig). Source: https://www.jessesquires.com/blog/2020/07/20/xcode-12-drops-support-for-ios-8-fix-for-cocoapods/

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET'
    end
  end
end

@farfromrefug
Copy link
Collaborator

farfromrefug commented Sep 18, 2020

@asharghi good idea, like it!

@cjohn001
Copy link

cjohn001 commented Sep 18, 2020

same problem here

@lochstar
Copy link
Contributor

lochstar commented Sep 18, 2020

It works for me if I place the following in build.xconfig

EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64=arm64 arm64e armv7 armv7s armv6 armv8
EXCLUDED_ARCHS=$(inherited) $(EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_$(EFFECTIVE_PLATFORM_SUFFIX)__NATIVE_ARCH_64_BIT_$(NATIVE_ARCH_64_BIT))

Courtesy of Vidhi Gupta on the NativeScript Slack.

@iMarwan-k
Copy link

iMarwan-k commented Sep 18, 2020

It works for me if I place the following in build.xconfig

EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64=arm64 arm64e armv7 armv7s armv6 armv8
EXCLUDED_ARCHS=$(inherited) $(EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_$(EFFECTIVE_PLATFORM_SUFFIX)__NATIVE_ARCH_64_BIT_$(NATIVE_ARCH_64_BIT))

Courtesy of Vidhi Gupta on the NativeScript Slack.

This works with me, thanks

@d-mh
Copy link

d-mh commented Sep 23, 2020

Better to delete it, then to set it to 9.0. Then it will inherit the project/workspace deployment taget (which is set in build.xcconfig). Source: https://www.jessesquires.com/blog/2020/07/20/xcode-12-drops-support-for-ios-8-fix-for-cocoapods/

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET'
    end
  end
end

It works for me if I place the following in build.xconfig

EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64=arm64 arm64e armv7 armv7s armv6 armv8
EXCLUDED_ARCHS=$(inherited) $(EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_$(EFFECTIVE_PLATFORM_SUFFIX)__NATIVE_ARCH_64_BIT_$(NATIVE_ARCH_64_BIT))

Courtesy of Vidhi Gupta on the NativeScript Slack.

I had to include above two fixes to make build working again

@exeptionerror
Copy link

exeptionerror commented Apr 22, 2021

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants