ℹ Please fill out this template when filing an issue.
All lines beginning with a quotation mark (>),
instruct you with what info we expect.
Please remove this paragraph.
- [ ] I've read and understood the *CONTRIBUTING guidelines and have done my best effort to follow.
Report
ℹ I update pod from 0.39 to 1.0
What did you expected to happen?
ℹ Build successfully
What happened instead?
ℹ PhaseScriptExecution 📦\ Copy\ Pods\ Resources /Users/hecq/Library/Developer/Xcode/DerivedData/kartor3-ewpbvogjcxhurfblvwdkjubcozcf/Build/Intermediates/kartor3.build/Release-iphoneos/kartor3.build/Script-566AE45A113C0E926E21190D.sh
cd /Users/hecq/.jenkins/workspace/kartor3_ep_4.8/Kartor3CI/Kartor3
/bin/sh -c /Users/hecq/Library/Developer/Xcode/DerivedData/kartor3-ewpbvogjcxhurfblvwdkjubcozcf/Build/Intermediates/kartor3.build/Release-iphoneos/kartor3.build/Script-566AE45A113C0E926E21190D.sh
/Users/hecq/.jenkins/workspace/kartor3_ep_4.8/Kartor3CI/Kartor3/Pods/BaiduMapKit/BaiduMapKit/BaiduMapAPI_Map.framework/Resources/mapapi.bundle
error: Resource "/Users/hecq/Library/Developer/Xcode/DerivedData/kartor3-ewpbvogjcxhurfblvwdkjubcozcf/Build/Products/Release-iphoneos/JSBadgeView/JSBadgeView.bundle" not found. Run 'pod install' to update the copy resources script.
* BUILD FAILED *
Jenkins overwrite the build and Symbol folder.
Embed Pods Framworks script looks like didn't use the new folder.
Does running pod install as the error suggests fix the issue?
seem
@segiddins this project can be compiled in XCode, the issue is jenkins'xcodebuild with a parameter CONFIGURATION_BUILD_DIR, but the shell script created by pod was still using the pod build path in XCODE default. like DerivedData/....../
when update cocoapods to 1.0,we found some error with jenkins
we use cocoapods-deintegrate remove pods and reuse pod install
jenkins will fail with Embed Pods Framworks
by the way,xcode build it's ok,just use jenkins will faild
How are you invoking xcodebuild and how are you setting CONFIGURATION_BUILD_DIR?
@segiddins xcodebuild was invokied by XCode plugin in jenknis. in fact, just a shell script, you can test it in Terminal, if you spefic any path for CONFIGURATION_BUILD_DIR you will fail. just like
xcodebuild -worspace xxx -scheme xxx -CONFIGURATION_BUILD_DIR xxx
[kartor3_ep_4.9] $ /usr/bin/xcodebuild -scheme kartor3 -workspace /Users/hecq/.jenkins/workspace/kartor3_ep_4.9/Kartor3CI/Kartor3/kartor3.xcworkspace -configuration Release build SYMROOT=/Users/hecq/.jenkins/workspace/kartor3_ep_4.9/build CONFIGURATION_BUILD_DIR=/Users/hecq/.jenkins/workspace/kartor3_ep_4.9/build
@mrackwitz I think this has to do with the new PODS_BUILD_DIR variable being used to set the library search paths?
PODS_BUILD_DIR is based on BUILD_DIR. You can configure that in Jenkins. I think that should be done as well by the Xcode plugin.
So how to fix it in detail?
Is there any option to fix this while still allowing an overwrite of CONFIGURATION_BUILD_DIR? For example, overwriting BUILD_DIR with the same value? Or explicitly setting PODS_BUILD_DIR?
@Chren, @zinndesign, in my case, moving the "Build output directory" value to "SYMROOT" value did the trick.
@Coeur, Do you have your "Symroot" setting set to anything specific please?
@jameswwwebster : in our previous project, using CocoaPods 1.0.0, we had "SYMROOT" set on "${WORKSPACE}/build". In our new project, we decided to stop using Jenkins and simply trigger an xcodebuild script when a pull request is merged.
Here is a part of our build script:
XCODE="/Applications/Xcode-beta.app"
XCODEBUILD="Scripts/xcbuild-safe.sh"
# archiving
ARCHIVE_DAY=$(date +%Y-%m-%d)
ARCHIVE_TIME=$(date +%H.%M.%S)
ARCHIVE_PATH="$HOME_PATH/Library/Developer/Xcode/Archives/${ARCHIVE_DAY}/${MyApplication} ${ARCHIVE_DAY} ${ARCHIVE_TIME}.xcarchive"
set -o pipefail \
&& DEVELOPER_DIR="${XCODE}" ${XCODEBUILD} -workspace "${MyApplication}.xcworkspace" \
-scheme ${SCHEME} \
-destination 'generic/platform=iOS' \
-archivePath "${ARCHIVE_PATH}" \
clean archive \
| xcpretty
# exporting
EXPORT_PATH="build/${SCHEME}"
rm -rf "${EXPORT_PATH}"
mkdir -p "${EXPORT_PATH}"
set -o pipefail \
&& DEVELOPER_DIR="${XCODE}" ${XCODEBUILD} -exportArchive \
-archivePath "${ARCHIVE_PATH}" \
-exportPath "${EXPORT_PATH}" \
-exportOptionsPlist "${EXPORT_OPTION_PLIST}" \
| xcpretty
xcbuild-safe.sh is taken from: https://github.com/fastlane/fastlane/blob/master/gym/lib/assets/wrap_xcodebuild/xcbuild-safe.sh
Most helpful comment
So how to fix it in detail?