libretro-buildbot-recipe.sh: Further clean up of redundant code.
This commit is contained in:
parent
0372f12f4d
commit
b03626e4c5
|
@ -797,25 +797,19 @@ while read line; do
|
||||||
ARGS="${ARGS# }"
|
ARGS="${ARGS# }"
|
||||||
ARGS="${ARGS%"${ARGS##*[![:space:]]}"}"
|
ARGS="${ARGS%"${ARGS##*[![:space:]]}"}"
|
||||||
BUILD="NO"
|
BUILD="NO"
|
||||||
|
UPDATE="YES"
|
||||||
|
|
||||||
if [ ! -d "${DIR}/.git" ] || [ "${CLEANUP}" = "YES" ]; then
|
if [ ! -d "${DIR}/.git" ] || [ "${CLEANUP}" = "YES" ]; then
|
||||||
rm -rfv -- "$DIR"
|
rm -rfv -- "$DIR"
|
||||||
echo "cloning repo $URL..."
|
echo "cloning repo $URL..."
|
||||||
git clone --depth=1 -b "$GIT_BRANCH" "$URL" "$DIR"
|
git clone --depth=1 -b "$GIT_BRANCH" "$URL" "$DIR"
|
||||||
cd "$DIR"
|
BUILD="YES"
|
||||||
|
UPDATE="NO"
|
||||||
if [ "${TYPE}" = "SUBMODULE" ]; then
|
|
||||||
git submodule update --init --recursive
|
|
||||||
elif [ "${TYPE}" = "psp_hw_render" ]; then
|
|
||||||
git remote set-branches origin "$TYPE"
|
|
||||||
git fetch --depth=1 origin "$TYPE"
|
|
||||||
git checkout "$TYPE"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
BUILD="YES"
|
|
||||||
else
|
|
||||||
cd "$DIR"
|
cd "$DIR"
|
||||||
|
|
||||||
|
if [ "${UPDATE}" != "NO" ]; then
|
||||||
if [ -f .forcebuild ]; then
|
if [ -f .forcebuild ]; then
|
||||||
echo "found .forcebuild file, building $NAME"
|
echo "found .forcebuild file, building $NAME"
|
||||||
BUILD="YES"
|
BUILD="YES"
|
||||||
|
@ -825,7 +819,7 @@ while read line; do
|
||||||
OUT="$(git pull)"
|
OUT="$(git pull)"
|
||||||
echo "$OUT"
|
echo "$OUT"
|
||||||
|
|
||||||
if [[ $OUT == *"Already up-to-date"* ]] && [ ! "${BUILD}" = "YES" ]; then
|
if [[ $OUT == *"Already up-to-date"* ]] && [ "${BUILD}" != "YES" ]; then
|
||||||
BUILD="NO"
|
BUILD="NO"
|
||||||
else
|
else
|
||||||
echo "resetting repo state $URL..."
|
echo "resetting repo state $URL..."
|
||||||
|
@ -833,12 +827,11 @@ while read line; do
|
||||||
git clean -xdf
|
git clean -xdf
|
||||||
BUILD="YES"
|
BUILD="YES"
|
||||||
fi
|
fi
|
||||||
|
elif [ "${TYPE}" = "psp_hw_render" ]; then
|
||||||
if [ "${TYPE}" = "SUBMODULE" ]; then
|
git remote set-branches origin "$TYPE"
|
||||||
git submodule update --init --recursive
|
git fetch --depth=1 origin "$TYPE"
|
||||||
|
git checkout "$TYPE"
|
||||||
fi
|
fi
|
||||||
fi
|
|
||||||
cd $WORK
|
|
||||||
|
|
||||||
if [ "${TYPE}" = "PROJECT" ]; then
|
if [ "${TYPE}" = "PROJECT" ]; then
|
||||||
FORCE_ORIG=$FORCE
|
FORCE_ORIG=$FORCE
|
||||||
|
@ -874,8 +867,12 @@ while read line; do
|
||||||
BUILD="YES"
|
BUILD="YES"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
elif [ "${TYPE}" = "SUBMODULE"]; then
|
||||||
|
git submodule update --init --recursive
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
cd "$WORK"
|
||||||
|
|
||||||
if [ "${BUILD}" = "YES" ] || [ "${FORCE}" = "YES" ]; then
|
if [ "${BUILD}" = "YES" ] || [ "${FORCE}" = "YES" ]; then
|
||||||
touch $TMPDIR/built-cores
|
touch $TMPDIR/built-cores
|
||||||
CORES_BUILT=YES
|
CORES_BUILT=YES
|
||||||
|
|
Loading…
Reference in New Issue