mirror of
https://gitlab.com/Nanolx/patchimage.git
synced 2024-12-18 05:21:49 +01:00
fix issue with relative paths
This commit is contained in:
parent
a2926cfc92
commit
6a18fc7da2
@ -103,6 +103,7 @@ for game in ${GAME[@]}; do
|
|||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
rm -rf "${BUILD_DIR}"
|
||||||
mkdir -p "${BUILD_DIR}"
|
mkdir -p "${BUILD_DIR}"
|
||||||
cd "${BUILD_DIR}"
|
cd "${BUILD_DIR}"
|
||||||
|
|
||||||
@ -142,5 +143,4 @@ for game in ${GAME[@]}; do
|
|||||||
esac
|
esac
|
||||||
|
|
||||||
cd "${CURDIR}"
|
cd "${CURDIR}"
|
||||||
rm -rf "${BUILD_DIR}"
|
|
||||||
done
|
done
|
||||||
|
@ -154,7 +154,11 @@ check_riivolution_patch () {
|
|||||||
x=0
|
x=0
|
||||||
if [[ ! -d ${RIIVOLUTION_DIR} ]]; then
|
if [[ ! -d ${RIIVOLUTION_DIR} ]]; then
|
||||||
x=1
|
x=1
|
||||||
if [[ -f "${PWD}/${RIIVOLUTION_ZIP}" ]]; then
|
if [[ -f "${RIIVOLUTION_ZIP_CUSTOM}" ]]; then
|
||||||
|
echo "*** >> unpacking"
|
||||||
|
x=2
|
||||||
|
unpack "${RIIVOLUTION_ZIP_CUSTOM}"
|
||||||
|
elif [[ -f "${PWD}/${RIIVOLUTION_ZIP}" ]]; then
|
||||||
echo "*** >> unpacking"
|
echo "*** >> unpacking"
|
||||||
x=2
|
x=2
|
||||||
unpack "${PWD}/${RIIVOLUTION_ZIP}"
|
unpack "${PWD}/${RIIVOLUTION_ZIP}"
|
||||||
|
@ -13,7 +13,7 @@ while [[ $xcount -lt $pcount ]]; do
|
|||||||
ISO_PATH="${1/*=}"
|
ISO_PATH="${1/*=}"
|
||||||
|
|
||||||
if [[ -f "${ISO_PATH}" ]]; then
|
if [[ -f "${ISO_PATH}" ]]; then
|
||||||
IMAGE="${ISO_PATH}"
|
IMAGE=$(readlink -m "${ISO_PATH}")
|
||||||
else
|
else
|
||||||
echo -e "ISO not found"
|
echo -e "ISO not found"
|
||||||
exit 15
|
exit 15
|
||||||
@ -24,7 +24,7 @@ while [[ $xcount -lt $pcount ]]; do
|
|||||||
ROM_PATH="${1/*=}"
|
ROM_PATH="${1/*=}"
|
||||||
|
|
||||||
if [[ -f "${ROM_PATH}" ]]; then
|
if [[ -f "${ROM_PATH}" ]]; then
|
||||||
ROM="${ROM_PATH}"
|
ROM=$(readlink -m "${ROM_PATH}")
|
||||||
else
|
else
|
||||||
echo -e "ROM not found"
|
echo -e "ROM not found"
|
||||||
exit 15
|
exit 15
|
||||||
@ -34,7 +34,7 @@ while [[ $xcount -lt $pcount ]]; do
|
|||||||
--riivolution=* )
|
--riivolution=* )
|
||||||
RIIVOLUTION="${1/*=}"
|
RIIVOLUTION="${1/*=}"
|
||||||
if [[ -f "${RIIVOLUTION}" ]]; then
|
if [[ -f "${RIIVOLUTION}" ]]; then
|
||||||
"${UNP}" "${RIIVOLUTION}" >/dev/null
|
RIIVOLUTION_ZIP_CUSTOM=$(readlink -m "${RIIVOLUTION}")
|
||||||
else
|
else
|
||||||
echo -e "Riivolution patch ${RIIVOLUTION} not found."
|
echo -e "Riivolution patch ${RIIVOLUTION} not found."
|
||||||
exit 21
|
exit 21
|
||||||
@ -44,7 +44,7 @@ while [[ $xcount -lt $pcount ]]; do
|
|||||||
--patch=* )
|
--patch=* )
|
||||||
PATCH="${1/*=}"
|
PATCH="${1/*=}"
|
||||||
if [[ -f "${PATCH}" ]]; then
|
if [[ -f "${PATCH}" ]]; then
|
||||||
PATCH="${PATCH}"
|
PATCH=$(readlink -m "${PATCH}")
|
||||||
else
|
else
|
||||||
echo -e "IPS/PPF patch ${PATCH} not found."
|
echo -e "IPS/PPF patch ${PATCH} not found."
|
||||||
exit 21
|
exit 21
|
||||||
@ -229,11 +229,21 @@ while [[ $xcount -lt $pcount ]]; do
|
|||||||
;;
|
;;
|
||||||
|
|
||||||
--xdelta=* )
|
--xdelta=* )
|
||||||
export XDELTA_PATH="${1/*=}"
|
if [[ -d ${1/*=} ]]; then
|
||||||
|
export XDELTA_PATH=$(readlink -m "${1/*=}")
|
||||||
|
else
|
||||||
|
echo "given directory ${1/*=} does no exist."
|
||||||
|
exit 75
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
|
|
||||||
--cpk=* )
|
--cpk=* )
|
||||||
export CPK_PATH="${1/*=}"
|
if [[ -d ${1/*=} ]]; then
|
||||||
|
export CPK_PATH=$(readlink -m "${1/*=}")
|
||||||
|
else
|
||||||
|
echo "given directory ${1/*=} does no exist."
|
||||||
|
exit 75
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
|
|
||||||
--help | -h )
|
--help | -h )
|
||||||
|
Loading…
Reference in New Issue
Block a user