Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #130 from dak180/topic/build-system

Clarifies the build process
  • Loading branch information...
commit 9834fdc7b4c59adc5ba57b8f9065de3d3dc35fee 2 parents dca9215 + 32ab9ea
@barijaona barijaona authored
View
16 configs/scripts/Release-for-upload.sh
@@ -1,6 +1,6 @@
#!/bin/bash
-. "${OBJROOT}/autorevision.tmp"
+. "${OBJROOT}/autorevision.cache"
BUILD_NUMBER="2821" # Magic number; do not touch!
N_VCS_NUM="$(echo "${BUILD_NUMBER} + ${VCS_NUM}" | bc)"
N_VCS_TAG="$(echo "${VCS_TAG}" | sed -e 's:^v/::')" # for urls/files
@@ -28,7 +28,7 @@ DOWNLOAD_BASE_URL="${DOWNLOAD_BASE_URL}/${DOWNLOAD_SUB_DIR}/${DOWNLOAD_TAG_DIR}"
# codesign setup
function signd {
- if [ ! -z "${CODE_SIGN_IDENTITY}" ]; then
+ if [[ ! -z "${CODE_SIGN_IDENTITY}" ]] && [[ ! -z ${CODE_SIGN_REQUIREMENTS_PATH} ]]; then
# Local Config
local appth="${1}"
local idetd="${CODE_SIGN_IDENTITY}"
@@ -36,14 +36,10 @@ function signd {
local csreq="${CODE_SIGN_REQUIREMENTS_PATH}"
# Sign and verify the app
- if [[ ! -z "${resrul}" ]] && [[ ! -z "${csreq}" ]]; then
- cp -a "${resrul}" "${appth}/ResourceRules.plist"
- codesign -f --sign "${idetd}" --resource-rules="${appth}/ResourceRules.plist" --requirements "${csreq}" -vvv "${appth}"
- rm "${appth}/ResourceRules.plist"
- else
- codesign -f --sign "${idetd}" --requirements "${csreq}" -vvv "${appth}"
- fi
- if ! codesign -vvv --verify "${appth}"; then
+ cp -a "${resrul}" "${appth}/ResourceRules.plist"
+ /usr/bin/codesign -f --sign "${idetd}" --resource-rules="${appth}/ResourceRules.plist" --requirements "${csreq}" -vvv "${appth}"
+ rm "${appth}/ResourceRules.plist"
+ if ! codesign --verify -vvv "${appth}"; then
echo "warning: Code is improperly signed!" 1>&2
fi
else
View
18 configs/scripts/autorevision.sh
@@ -3,19 +3,20 @@
# Config
export PATH=${PATH}:/sw/bin:/opt/local/bin:/usr/local/bin:/usr/local/git/bin
BUILD_NUMBER="2821"
-hauto="${SRCROOT}/src/autorevision.h"
+hauto="${DERIVED_FILE_DIR}/autorevision.h"
+fauto="${SRCROOT}/src/autorevision.h"
xauto="${OBJROOT}/autorevision.h"
cauto="${OBJROOT}/autorevision.cache"
tauto="${OBJROOT}/autorevision.tmp"
-if ! ./3rdparty/autorevision -o "${tauto}" -t sh; then
+if ! ./3rdparty/autorevision -o "${cauto}" -t sh; then
exit ${?}
fi
# Source the initial autorevision output for filtering.
-. "${tauto}"
+. "${cauto}"
# Filter the output.
@@ -27,18 +28,21 @@ N_VCS_BRANCH="$(echo "${VCS_BRANCH}" | sed -e 's:remotes/:remote/:' -e 's:/:-:'
if [[ ! "${VCS_TICK}" = "0" ]] && [[ ! -z "${VCS_BRANCH}" ]]; then
# If we are not exactly on a tag try using the branch name instead
- sed -e "s:${VCS_TAG}:${N_VCS_BRANCH}:" -e "s:${VCS_BRANCH}:${N_VCS_BRANCH}:" -e "s:${VCS_NUM}:${N_VCS_NUM}:" "${tauto}" > "${cauto}"
+ sed -e "s:${VCS_TAG}:${N_VCS_BRANCH}:" -e "s:${VCS_BRANCH}:${N_VCS_BRANCH}:" -e "s:${VCS_NUM}:${N_VCS_NUM}:" "${cauto}" > "${tauto}"
else
# Prettify the tag name
N_VCS_TAG="$(echo "${VCS_TAG}" | sed -e 's:^v/::' | sed -e 's:_beta: Beta :' -e 's:_rc: RC :')"
- sed -e "s:${VCS_TAG}:${N_VCS_TAG}:" -e "s:${VCS_BRANCH}:${N_VCS_BRANCH}:" -e "s:${VCS_NUM}:${N_VCS_NUM}:" "${tauto}" > "${cauto}"
+ sed -e "s:${VCS_TAG}:${N_VCS_TAG}:" -e "s:${VCS_BRANCH}:${N_VCS_BRANCH}:" -e "s:${VCS_NUM}:${N_VCS_NUM}:" "${cauto}" > "${tauto}"
fi
# Output for src/autorevision.h.
-./3rdparty/autorevision -f -o "${tauto}" -t h > "${hauto}"
+./3rdparty/autorevision -f -o "${cauto}" -t h > "${hauto}"
+if [[ ! -f "${fauto}" ]] || ! cmp -s "${hauto}" "${fauto}"; then
+ cp -a "${hauto}" "${fauto}"
+fi
# Output for info.plist prepossessing.
-./3rdparty/autorevision -f -o "${cauto}" -t xcode > "${xauto}"
+./3rdparty/autorevision -f -o "${tauto}" -t xcode > "${xauto}"
exit ${?}
View
8 signing/codesignrequirement.txt
@@ -1,9 +1,11 @@
designated => (
certificate leaf[field.1.2.840.113635.100.6.1.9] /* exists */
or
- certificate 1[field.1.2.840.113635.100.6.2.6] /* exists */
- and certificate leaf[field.1.2.840.113635.100.6.1.13] /* exists */
- and certificate leaf[subject.OU] = KUU2LM7U9K
+ (
+ certificate 1[field.1.2.840.113635.100.6.2.6] /* exists */
+ and certificate leaf[field.1.2.840.113635.100.6.1.13] /* exists */
+ and certificate leaf[subject.OU] = KUU2LM7U9K
+ )
)
and anchor apple generic
and identifier "uk.co.opencommunity.vienna2"
Please sign in to comment.
Something went wrong with that request. Please try again.