mirror of
https://github.com/libretro/libretro-super
synced 2024-12-03 01:01:51 +00:00
Protect more where needed, less where not.
This commit is contained in:
parent
8a767c1e52
commit
4d8c222f9c
@ -4,36 +4,27 @@
|
|||||||
# BSDs don't have readlink -f
|
# BSDs don't have readlink -f
|
||||||
read_link()
|
read_link()
|
||||||
{
|
{
|
||||||
TARGET_FILE="${1}"
|
TARGET_FILE="$1"
|
||||||
cd "`dirname "${TARGET_FILE}"`"
|
cd "`dirname "$TARGET_FILE"`"
|
||||||
TARGET_FILE="`basename "${TARGET_FILE}"`"
|
TARGET_FILE="`basename "$TARGET_FILE"`"
|
||||||
|
|
||||||
while [ -L "${TARGET_FILE}" ]; do
|
while [ -L "$TARGET_FILE" ]; do
|
||||||
TARGET_FILE="`readlink "${TARGET_FILE}"`"
|
TARGET_FILE="`readlink "$TARGET_FILE"`"
|
||||||
cd "`dirname "${TARGET_FILE}"`"
|
cd "`dirname "$TARGET_FILE"`"
|
||||||
TARGET_FILE="`basename "${TARGET_FILE}"`"
|
TARGET_FILE="`basename "$TARGET_FILE"`"
|
||||||
done
|
done
|
||||||
|
|
||||||
PHYS_DIR="`pwd -P`"
|
PHYS_DIR="`pwd -P`"
|
||||||
RESULT="${PHYS_DIR}/${TARGET_FILE}"
|
RESULT="$PHYS_DIR/$TARGET_FILE"
|
||||||
echo ${RESULT}
|
echo "$RESULT"
|
||||||
}
|
}
|
||||||
SCRIPT="`read_link "$0"`"
|
SCRIPT="`read_link "$0"`"
|
||||||
BASE_DIR="`dirname "${SCRIPT}"`"
|
BASE_DIR="`dirname "$SCRIPT"`"
|
||||||
|
|
||||||
. ${BASE_DIR}/iKarith-libretro-config.sh
|
. $BASE_DIR/iKarith-libretro-config.sh
|
||||||
|
|
||||||
WORKDIR=$(pwd)
|
WORKDIR=$(pwd)
|
||||||
|
|
||||||
DATESTAMP_FMT="%Y-%m-%d %H:%M:%S"
|
|
||||||
|
|
||||||
|
|
||||||
log_verbose() {
|
|
||||||
if [ -n "${VERBOSE}" ]; then
|
|
||||||
echo "$(date -u +${DATESTAMP_FMT}):${@}"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
echo_cmd() {
|
echo_cmd() {
|
||||||
echo "$@"
|
echo "$@"
|
||||||
"$@"
|
"$@"
|
||||||
@ -65,6 +56,8 @@ fetch_git() {
|
|||||||
|
|
||||||
|
|
||||||
# Keep three copies so we don't have to rebuild stuff all the time.
|
# Keep three copies so we don't have to rebuild stuff all the time.
|
||||||
|
# FIXME: If you need 3 copies of source to compile 3 sets of objects, you're
|
||||||
|
# doing it wrong. We should fix this.
|
||||||
fetch_project_bsnes()
|
fetch_project_bsnes()
|
||||||
{
|
{
|
||||||
fetch_git "${1}" "${2}"
|
fetch_git "${1}" "${2}"
|
||||||
|
Loading…
Reference in New Issue
Block a user