Build failed, Error code 65 for command: xcodebuild


#1

Build succeeds in new deploy-tutorial, and used to work with this app, but now ionic run iOS yields, after normal noise:

    /Users/home/DD/app/platforms/ios/build/Abhyaasa.build/Debug-iphonesimulator/Abhyaasa.build/Objects-normal/i386/IonicKeyboard-F8F832CB3BC6152.o
    /Users/home/DD/app/platforms/ios/build/Abhyaasa.build/Debug-iphonesimulator/Abhyaasa.build/Objects-normal/i386/IonicKeyboard-344B8E7C9B5F674.o
ld: 6 duplicate symbols for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

** BUILD FAILED **


The following build commands failed:
	Ld build/emulator/Abhyaasa.app/Abhyaasa normal i386
(1 failure)
Error code 65 for command: xcodebuild with args: -xcconfig,/Users/home/DD/app/platforms/ios/cordova/build-debug.xcconfig,-project,Abhyaasa.xcodeproj,ARCHS=i386,-target,Abhyaasa,-configuration,Debug,-sdk,iphonesimulator,build,VALID_ARCHS=i386,CONFIGURATION_BUILD_DIR=/Users/home/DD/app/platforms/ios/build/emulator,SHARED_PRECOMPS_DIR=/Users/home/DD/app/platforms/ios/build/sharedpch
ERROR running one or more of the platforms: Error: /Users/home/DD/app/platforms/ios/cordova/run: Command failed with exit code 2
You may not have the required environment or OS to run this project

I’ve already tried deleting ./platforms and reran ionic platform add ios, yielding lots of messages about existing files not being there, when they are, and not being able to delete things, etc. But I believe that’s normal noise.

Finally, the following has system info, along with what seems to be a problem with my new package setup.

~/DD/app$ ionic package list
Body: {"detail":"You do not have permission to perform this action."}



Error in package service. (CLI v1.7.13)

Your system information:

Cordova CLI: 5.4.1
Gulp version:  CLI version 3.9.0
Gulp local:   Local version 3.9.0
Ionic Version: 1.0.0
Ionic CLI Version: 1.7.13
Ionic App Lib Version: 0.6.5
ios-deploy version: 1.7.0
ios-sim version: 4.1.1
OS: Mac OS X El Capitan
Node Version: v0.12.7
Xcode version: Xcode 7.2 Build version 7C68

Help appreciated!


#2

Duplicated this error in standard context by creating new app with tabs template and running
ionic platform update ios. Deleting ./platforms and running ionic platform add ios fixed the problem. Looks to me like the update mechanism is somehow out of sync with platform addition.


#3

Hi Chaynes,

I followed your way to remove the ios platform and add it back again. After that I build ios and there was no error. But when I tried to build second time, it went back to same error again(code 65 for command…).

Do you have any idea for that?

so much appreciate for any help…


#4

No really good ideas. You’d expect the build process to be idempotent: with app code unchanged, repeated builds, at least after a successful one, should yield the same result.

I’ve found my way out of this sort of problem by trying to repeat things in a stock context such as the tabs starter template, gradually adding additional elements I’m using such as plugins. I’d be quite suspicious of any non-standard plugins. This is a process of incremental elimination and/or building up, converging between a starter template that works and your app until the problem starts (building up) or goes away (elimination). It’s tedious, but I saved a lot of time by building scripts that automate the process of creating these test configurations.

Good luck!


#5

Thanks Chaynes. I would give it a try…


#6

after removing that plugin (cordova-plugin-wkwebview), everything is working perfect. :smiley: