美文网首页
ionic3 - 在Mac上build ios失败

ionic3 - 在Mac上build ios失败

作者: JoyoDuan | 来源:发表于2019-06-13 11:46 被阅读0次

    参照

    cordova-ios

    在Mac上执行ionic cordova build ios失败

    错误信息

    Build settings from command line:
        CONFIGURATION_BUILD_DIR = /Users/joyoduan/Downloads/Driveprince/Hybrid-App/drive-coach/drive-coach/platforms/ios/build/device
        SHARED_PRECOMPS_DIR = /Users/joyoduan/Downloads/Driveprince/Hybrid-App/drive-coach/drive-coach/platforms/ios/build/sharedpch
    
    Build settings from configuration file '/Users/joyoduan/Downloads/Driveprince/Hybrid-App/drive-coach/drive-coach/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
    

    解决办法

    1. 在打包命令后添加:
      -- --buildFlag="-UseModernBuildSystem=0"

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

    1. 修改build.json配置文件,在iOS版本或调试配置下添加以下内容:
    "buildFlag": [
      "-UseModernBuildSystem=0"
    ]
    

    相关文章

      网友评论

          本文标题:ionic3 - 在Mac上build ios失败

          本文链接:https://www.haomeiwen.com/subject/vmvjfctx.html