简体   繁体   English

科尔多瓦无法构建iOS

[英]Cordova can't build ios

I have Cordova version (8.0.0) 我有Cordova版本(8.0.0)

Am trying to build the ios but shows a msg without any error and stops the build. 我正在尝试构建ios,但显示消息但没有任何错误,并停止了构建。

> Building for iPhone X Simulator Building project: /Users/FaisalAlzahrani/Customer_Prod_3/platforms/ios/Ajeer-Client.xcworkspace   Configuration: Debug    Platform: emulator Build settings from command line:
    CONFIGURATION_BUILD_DIR = /Users/FaisalAlzahrani/Customer_Prod_3/platforms/ios/build/emulator
    SDKROOT = iphonesimulator12.1
    SHARED_PRECOMPS_DIR = /Users/FaisalAlzahrani/Customer_Prod_3/platforms/ios/build/sharedpch Build settings from configuration file '/Users/FaisalAlzahrani/Customer_Prod_3/platforms/ios/cordova/build-debug.xcconfig':
    CLANG_ALLOW_NON_MODULAR_INCLUDES_IN_FRAMEWORK_MODULES = YES
    CODE_SIGN_ENTITLEMENTS = $(PROJECT_DIR)/$(PROJECT_NAME)/Entitlements-$(CONFIGURATION).plist
    CODE_SIGN_IDENTITY = iPhone Developer
    ENABLE_BITCODE = NO
    GCC_PREPROCESSOR_DEFINITIONS = DEBUG=1
    HEADER_SEARCH_PATHS = "$(TARGET_BUILD_DIR)/usr/local/lib/include" "$(OBJROOT)/UninstalledProducts/include" "$(OBJROOT)/UninstalledProducts/$(PLATFORM_NAME)/include" "$(BUILT_PRODUCTS_DIR)"
    OTHER_LDFLAGS = -ObjC
    SWIFT_OBJC_BRIDGING_HEADER = $(PROJECT_DIR)/$(PROJECT_NAME)/Bridging-Header.h

在此处输入图片说明

我通过使用以下命令在构建项目中解决了问题

cordova build ios --buildFlag="-UseModernBuildSystem=0"

From Xcode 10, the new build setting can be activated from Xcode Files-> Project/Workspace Settings where options to toggle between Legacy system and new build system. 在Xcode 10中,可以从Xcode文件->项目/工作区设置中激活新的构建设置,其中的选项可在旧版系统和新的构建系统之间切换。 To build manually for iOS platform we must use build flag="-UseModernBuildSystem=0" Reference : https://github.com/apache/cordova-ios/issues/407 要为iOS平台手动构建,我们必须使用build flag =“-UseModernBuildSystem = 0”参考: https : //github.com/apache/cordova-ios/issues/407

cordova build ios --buildFlag="-UseModernBuildSystem=0"
This will works !
Below error I was facing used the same solution
4001009: Invalid .ipa file: missing embedded mobileprovisionvalid .ipa file: missing embedded mobileprovision facing same problem.

Package.json file can also be included the below flag
"buildFlag": [
  "-UseModernBuildSystem=0"
]

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM