Skip to content
Snippets Groups Projects
Commit c29e62c2 authored by Oliver Wiese's avatar Oliver Wiese
Browse files

remove prints

parent cd7609c4
Branches
No related tags found
No related merge requests found
...@@ -3,10 +3,15 @@ set -e ...@@ -3,10 +3,15 @@ set -e
set -u set -u
set -o pipefail set -o pipefail
function on_error {
echo "$(realpath -mq "${0}"):$1: error: Unexpected failure"
}
trap 'on_error $LINENO' ERR
if [ -z ${UNLOCALIZED_RESOURCES_FOLDER_PATH+x} ]; then if [ -z ${UNLOCALIZED_RESOURCES_FOLDER_PATH+x} ]; then
# If UNLOCALIZED_RESOURCES_FOLDER_PATH is not set, then there's nowhere for us to copy # If UNLOCALIZED_RESOURCES_FOLDER_PATH is not set, then there's nowhere for us to copy
# resources to, so exit 0 (signalling the script phase was successful). # resources to, so exit 0 (signalling the script phase was successful).
exit 0 exit 0
fi fi
mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
...@@ -91,6 +96,12 @@ EOM ...@@ -91,6 +96,12 @@ EOM
;; ;;
esac esac
} }
if [[ "$CONFIGURATION" == "Debug" ]]; then
install_resource "${PODS_ROOT}/VENTokenField/VENTokenField/VENToken.xib"
fi
if [[ "$CONFIGURATION" == "Release" ]]; then
install_resource "${PODS_ROOT}/VENTokenField/VENTokenField/VENToken.xib"
fi
mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
......
...@@ -3,10 +3,15 @@ set -e ...@@ -3,10 +3,15 @@ set -e
set -u set -u
set -o pipefail set -o pipefail
function on_error {
echo "$(realpath -mq "${0}"):$1: error: Unexpected failure"
}
trap 'on_error $LINENO' ERR
if [ -z ${FRAMEWORKS_FOLDER_PATH+x} ]; then if [ -z ${FRAMEWORKS_FOLDER_PATH+x} ]; then
# If FRAMEWORKS_FOLDER_PATH is not set, then there's nowhere for us to copy # If FRAMEWORKS_FOLDER_PATH is not set, then there's nowhere for us to copy
# frameworks to, so exit 0 (signalling the script phase was successful). # frameworks to, so exit 0 (signalling the script phase was successful).
exit 0 exit 0
fi fi
echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
...@@ -36,8 +41,8 @@ install_framework() ...@@ -36,8 +41,8 @@ install_framework()
local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
if [ -L "${source}" ]; then if [ -L "${source}" ]; then
echo "Symlinked..." echo "Symlinked..."
source="$(readlink "${source}")" source="$(readlink "${source}")"
fi fi
# Use filter instead of exclude so missing patterns don't throw errors. # Use filter instead of exclude so missing patterns don't throw errors.
...@@ -47,8 +52,13 @@ install_framework() ...@@ -47,8 +52,13 @@ install_framework()
local basename local basename
basename="$(basename -s .framework "$1")" basename="$(basename -s .framework "$1")"
binary="${destination}/${basename}.framework/${basename}" binary="${destination}/${basename}.framework/${basename}"
if ! [ -r "$binary" ]; then if ! [ -r "$binary" ]; then
binary="${destination}/${basename}" binary="${destination}/${basename}"
elif [ -L "${binary}" ]; then
echo "Destination binary is symlinked..."
dirname="$(dirname "${binary}")"
binary="${dirname}/$(readlink "${binary}")"
fi fi
# Strip invalid architectures so "fat" simulator / device frameworks work on device # Strip invalid architectures so "fat" simulator / device frameworks work on device
...@@ -62,7 +72,7 @@ install_framework() ...@@ -62,7 +72,7 @@ install_framework()
# Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7.
if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then
local swift_runtime_libs local swift_runtime_libs
swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u)
for lib in $swift_runtime_libs; do for lib in $swift_runtime_libs; do
echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\""
rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}"
...@@ -101,8 +111,8 @@ install_dsym() { ...@@ -101,8 +111,8 @@ install_dsym() {
# Signs a framework with the provided identity # Signs a framework with the provided identity
code_sign_if_enabled() { code_sign_if_enabled() {
if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED:-}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then if [ -n "${EXPANDED_CODE_SIGN_IDENTITY:-}" -a "${CODE_SIGNING_REQUIRED:-}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then
# Use the current code_sign_identitiy # Use the current code_sign_identity
echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}"
local code_sign_cmd="/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS:-} --preserve-metadata=identifier,entitlements '$1'" local code_sign_cmd="/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS:-} --preserve-metadata=identifier,entitlements '$1'"
...@@ -131,7 +141,7 @@ strip_invalid_archs() { ...@@ -131,7 +141,7 @@ strip_invalid_archs() {
for arch in $binary_archs; do for arch in $binary_archs; do
if ! [[ "${ARCHS}" == *"$arch"* ]]; then if ! [[ "${ARCHS}" == *"$arch"* ]]; then
# Strip non-valid architectures in-place # Strip non-valid architectures in-place
lipo -remove "$arch" -output "$binary" "$binary" || exit 1 lipo -remove "$arch" -output "$binary" "$binary"
stripped="$stripped $arch" stripped="$stripped $arch"
fi fi
done done
...@@ -141,6 +151,31 @@ strip_invalid_archs() { ...@@ -141,6 +151,31 @@ strip_invalid_archs() {
STRIP_BINARY_RETVAL=1 STRIP_BINARY_RETVAL=1
} }
if [[ "$CONFIGURATION" == "Debug" ]]; then
install_framework "${BUILT_PRODUCTS_DIR}/AppAuth/AppAuth.framework"
install_framework "${BUILT_PRODUCTS_DIR}/BZipCompression/BZipCompression.framework"
install_framework "${BUILT_PRODUCTS_DIR}/FrameAccessor/FrameAccessor.framework"
install_framework "${BUILT_PRODUCTS_DIR}/GTMAppAuth/GTMAppAuth.framework"
install_framework "${BUILT_PRODUCTS_DIR}/GTMSessionFetcher/GTMSessionFetcher.framework"
install_framework "${BUILT_PRODUCTS_DIR}/KeychainAccess/KeychainAccess.framework"
install_framework "${BUILT_PRODUCTS_DIR}/Onboard/Onboard.framework"
install_framework "${BUILT_PRODUCTS_DIR}/QAKit/QAKit.framework"
install_framework "${BUILT_PRODUCTS_DIR}/Travellib/Travellib.framework"
install_framework "${BUILT_PRODUCTS_DIR}/VENTokenField/VENTokenField.framework"
fi
if [[ "$CONFIGURATION" == "Release" ]]; then
install_framework "${BUILT_PRODUCTS_DIR}/AppAuth/AppAuth.framework"
install_framework "${BUILT_PRODUCTS_DIR}/BZipCompression/BZipCompression.framework"
install_framework "${BUILT_PRODUCTS_DIR}/FrameAccessor/FrameAccessor.framework"
install_framework "${BUILT_PRODUCTS_DIR}/GTMAppAuth/GTMAppAuth.framework"
install_framework "${BUILT_PRODUCTS_DIR}/GTMSessionFetcher/GTMSessionFetcher.framework"
install_framework "${BUILT_PRODUCTS_DIR}/KeychainAccess/KeychainAccess.framework"
install_framework "${BUILT_PRODUCTS_DIR}/Onboard/Onboard.framework"
install_framework "${BUILT_PRODUCTS_DIR}/QAKit/QAKit.framework"
install_framework "${BUILT_PRODUCTS_DIR}/Travellib/Travellib.framework"
install_framework "${BUILT_PRODUCTS_DIR}/VENTokenField/VENTokenField.framework"
fi
if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then
wait wait
fi fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment