libretro-super/libretro-install.sh

27 lines
450 B
Bash
Raw Normal View History

2011-11-02 15:27:23 +00:00
#!/bin/sh
2013-05-03 09:32:01 +00:00
SCRIPT=$(readlink -f $0)
BASE_DIR=$(dirname $SCRIPT)
RARCH_DIR=$BASE_DIR/dist
RARCH_DIST_DIR=$RARCH_DIR/pc
2011-11-02 15:27:23 +00:00
if [ -z "$1" ]; then
2012-04-16 17:33:18 +00:00
LIBRETRO_DIR="/usr/local/lib/libretro"
2011-11-02 15:27:23 +00:00
else
2012-04-16 17:33:18 +00:00
LIBRETRO_DIR="$1"
2011-11-02 15:27:23 +00:00
fi
2012-04-22 15:12:15 +00:00
if [ ! -d "$LIBRETRO_DIR" ]; then
2012-04-16 17:33:18 +00:00
mkdir -p "$LIBRETRO_DIR"
2011-11-02 15:27:23 +00:00
fi
2013-05-03 09:32:01 +00:00
for lib in "$RARCH_DIST_DIR"/*
2011-11-02 15:27:23 +00:00
do
if [ -f $lib ]; then
2012-04-16 17:33:18 +00:00
install -v -m644 $lib "$LIBRETRO_DIR"
2011-11-02 15:27:23 +00:00
else
echo "Library $lib not found, skipping ..."
fi
done