Solved Xcodebuild failed.
-
@jsulm @J-Hilk I update Qt to 5.11 and i've the same problem.
** BUILD FAILED **
The following build commands failed:
CopyPNGFile Debug-iphonesimulator/TEST_IOS.app/Default-568h@2x.png TEST_IOS.xcodeproj/Default-568h@2x.png
(1 failure)
make: *** [xcodebuild-debug-simulator] Error 65
18:51:31: The process "/usr/bin/make" exited with code 2.
Error while building/deploying project TEST_IOS (kit: Qt 5.11.1 for iOS Simulator)
When executing step "Make"COMPILE OUTPUT:
Accounts preference pane. -allowProvisioningDeviceRegistration Allow xcodebuild to register your destination device on the developer portal if necessary. This flag only takes effect if -allowProvisioningUpdates is also passed. Can't exec "": No such file or directory at /Applications/Xcode.app/Contents/Developer/usr/bin/copypng line 89. ERROR: Failed to run -q -iphone -f 0 -rem text /Users/ME/Documents/Qt_PRJ/build-TEST_IOS-Qt_5_11_1_for_iOS_Simulator-Debug/TEST_IOS.xcodeproj/Default-568h@2x.png /Users/ME/Documents/Qt_PRJ/build-TEST_IOS-Qt_5_11_1_for_iOS_Simulator-Debug/Debug-iphonesimulator/TEST_IOS.app/Default-568h@2x.png Command /Applications/Xcode.app/Contents/Developer/usr/bin/copypng failed with exit code 255
Please help me!
-
@edoardo.videx
ok, first things first,
do you have an ios developer account and is it registered/setup on your mac? -
@J.Hilk Yes!
-
@edoardo.videx
Did you register your target device in the Apple-Developer portal? -
@J.Hilk
How i do it? -
Did you once start Xcode itself to check that you have everything needed available ?
-
@SGaist
Yes! I also start an example app. And everythings work! -
Did you update Qt in the interval ?
The how are you setting up your project ?
Are you compiling with QtCreator ? -
I'm stuck with a similar problem after upgrading to macOS 10.13.6, XCode 9.4, running Qt5.6.2:
CopyPNGFile Debug-iphoneos/CmsMobileApp.app/Icon-29.png /Users/appbuilder/Home/workspace/iOS-AutoRecloser3/appCMS_Mobile/CmsMobileApp/ios/Icon-29.png cd /Users/appbuilder/Home/workspace/iOS-AutoRecloser3/iosbuild/appCMS_Mobile/CmsMobileApp export DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin;" export SDKROOT=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.4.sdk export TOOLCHAINS= /Applications/Xcode.app/Contents/Developer/usr/bin/copypng -compress -strip-PNG-text /Users/appbuilder/Home/workspace/iOS-AutoRecloser3/appCMS_Mobile/CmsMobileApp/ios/Icon-29.png /Users/appbuilder/Home/workspace/iOS-AutoRecloser3/iosbuild/appCMS_Mobile/CmsMobileApp/Debug-iphoneos/CmsMobileApp.app/Icon-29.png xcrun: error: invalid option '-f' Usage: xcrun [-project <projectname>] [[-target <targetname>]... Can't exec "": No such file or directory at /Applications/Xcode.app/Contents/Developer/usr/bin/copypng line 89. ERROR: Failed to run -q -iphone -f 0 -rem text /Users/appbuilder/Home/workspace/iOS-AutoRecloser3/appCMS_Mobile/CmsMobileApp/ios/Icon-29.png /Users/appbuilder/Home/workspace/iOS-AutoRecloser3/iosbuild/appCMS_Mobile/CmsMobileApp/Debug-iphoneos/CmsMobileApp.app/Icon-29.png Command /Applications/Xcode.app/Contents/Developer/usr/bin/copypng failed with exit code 255
There were a few other issues related to recent update to the environment (development team, license agreement thing, sdk version check) which were solved apparently, but unfortunately can't find solution for the problem above. Tried as suggested in some places installing/reseting command line tools for xcode (current xcode-select version 2349), the issue persists. The same project can be built by xcode opening .xcodeproj generated by
qmake -spec macx-xcode -r myproject.pro
However, the following fails as shown above
/$QMAKE ../$PROJECT_NAME.pro -r -spec macx-ios-clang CONFIG+=iphoneos QMAKE_MAC_XCODE_SETTINGS=team team.name=DEVELOPMENT_TEAM team.value=/$TEAMID
Any advice will be very much appreciated!
-
@ppnp, you might want to check with a more recent version of Qt. If you need LTS, then 5.9 is the current one.
-
@SGaist, thanks. Due to license terms Qt5.6.2 is the latest available for the time being. Fortunately, re-install of Xcode app fixed the issue for me. Cheers!