libretro-super/libretro-build.sh

279 lines
6.7 KiB
Bash
Raw Normal View History

2011-11-02 15:27:23 +00:00
#!/bin/sh
die()
{
echo $1
2012-04-16 17:33:18 +00:00
#exit 1
2011-11-02 15:27:23 +00:00
}
2012-04-16 17:33:18 +00:00
build_libretro_bsnes()
2011-11-02 15:27:23 +00:00
{
if [ -z "$CC" ]; then
CC=gcc
fi
2012-04-16 17:33:18 +00:00
if [ -d "libretro-bsnes/perf" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building bSNES performance ==="
2013-01-15 11:24:05 +00:00
cd libretro-bsnes/perf/higan
make compiler="$CC" ui=target-libretro profile=performance -j4 || die "Failed to build bSNES performance core"
cp -f out/libretro.so ../../libretro-bsnes-performance.so
cd ../../..
2011-11-02 15:27:23 +00:00
else
echo "bSNES performance not fetched, skipping ..."
fi
2013-01-15 11:24:05 +00:00
if [ -d "libretro-bsnes/balanced" ]; then
echo "=== Building bSNES balanced ==="
cd libretro-bsnes/balanced/higan
make compiler="$CC" ui=target-libretro profile=balanced -j4 || die "Failed to build bSNES balanced core"
cp -f out/libretro.so ../../libretro-bsnes-balanced.so
cd ../../..
2011-11-02 15:27:23 +00:00
else
echo "bSNES compat not fetched, skipping ..."
fi
2012-04-16 17:33:18 +00:00
if [ -d "libretro-bsnes" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building bSNES accuracy ==="
2013-01-15 11:24:05 +00:00
cd libretro-bsnes/higan
make compiler="$CC" ui=target-libretro profile=accuracy -j4 || die "Failed to build bSNES accuracy core"
cp -f out/libretro.so ../libretro-bsnes-accuracy.so
cd ../..
2011-11-02 15:27:23 +00:00
fi
}
2012-11-08 21:55:59 +00:00
build_libretro_mednafen()
{
if [ -d "libretro-mednafen" ]; then
echo "=== Building Mednafen ==="
cd libretro-mednafen
2012-11-25 02:47:40 +00:00
for core in psx pce-fast wswan ngp gba snes vb
2012-11-08 21:55:59 +00:00
do
2012-11-29 12:28:46 +00:00
if [ -d $core ]; then
cd $core
make core=${core} -j4 || die "Failed to build mednafen/${core}"
cp mednafen_$(echo ${core} | tr '[\-]' '[_]')_libretro.so ../libretro-mednafen-${core}.so
cd ..
fi
2012-11-08 21:55:59 +00:00
done
2012-11-08 22:14:01 +00:00
cd ..
2012-11-08 21:55:59 +00:00
else
echo "Mednafen not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_s9x()
2011-11-02 15:27:23 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-s9x" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building SNES9x ==="
2012-04-16 17:33:18 +00:00
cd libretro-s9x/libretro
2011-11-02 15:27:23 +00:00
make -j4 || die "Failed to build SNES9x"
2012-04-16 17:33:18 +00:00
cp libretro.so ../libretro-snes9x.so
2011-11-02 15:27:23 +00:00
cd ../..
else
echo "SNES9x not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_s9x_next()
2011-11-08 20:20:44 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-s9x-next" ]; then
2011-11-08 20:20:44 +00:00
echo "=== Building SNES9x-Next ==="
2012-04-16 17:33:18 +00:00
cd libretro-s9x-next/
make -f Makefile.libretro -j4 || die "Failed to build SNES9x-Next"
2013-02-02 19:54:19 +00:00
cp snes9x_next_libretro.so libretro-snes9x-next.so
2011-11-28 16:43:07 +00:00
cd ..
2011-11-08 20:20:44 +00:00
else
echo "SNES9x-Next not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_genplus()
2011-11-02 15:27:23 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-genplus" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building Genplus GX ==="
2012-04-16 17:33:18 +00:00
cd libretro-genplus/
make -f Makefile.libretro -j4 || die "Failed to build Genplus GX"
2013-02-02 19:54:19 +00:00
cp genesis_plus_gx_libretro.so libretro-genplus.so
2011-11-28 16:43:07 +00:00
cd ..
2011-11-02 15:27:23 +00:00
else
echo "Genplus GX not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_fba()
2011-11-02 15:27:23 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-fba" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building Final Burn Alpha ==="
2012-04-16 17:33:18 +00:00
cd libretro-fba/
./compile_libretro.sh make || die "Failed to build Final Burn Alpha"
2013-02-02 19:54:19 +00:00
cp svn-current/trunk/fb_alpha_libretro.so libretro-fba.so
2011-11-29 04:39:27 +00:00
cd ..
2011-11-02 15:27:23 +00:00
else
echo "Final Burn Alpha not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_vba()
2011-11-02 15:27:23 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-vba" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building VBA-Next ==="
2012-04-16 17:33:18 +00:00
cd libretro-vba/
make -f Makefile.libretro -j4 || die "Failed to build VBA-Next"
2013-02-02 19:54:19 +00:00
cp vba_next_libretro.so libretro-vba.so
2011-11-28 16:43:07 +00:00
cd ..
2011-11-02 15:27:23 +00:00
else
echo "VBA-Next not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_bnes()
2011-11-02 15:27:23 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-bnes" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building bNES ==="
2012-04-16 17:33:18 +00:00
cd libretro-bnes
2011-11-02 15:27:23 +00:00
mkdir -p obj
make -j4 || die "Failed to build bNES"
2012-04-16 17:33:18 +00:00
cp libretro.so libretro-bnes.so
2011-11-02 15:27:23 +00:00
cd ..
else
echo "bNES not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_fceu()
2011-11-02 15:27:23 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-fceu" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building FCEU ==="
2012-04-16 17:33:18 +00:00
cd libretro-fceu
2013-02-02 19:54:19 +00:00
make -C fceumm-code -f Makefile.libretro -j4 || die "Failed to build FCEU"
cp fceumm-code/fceumm_libretro.so libretro-fceu.so
2011-11-28 16:43:07 +00:00
cd ..
2011-11-02 15:27:23 +00:00
else
2011-11-19 19:53:53 +00:00
echo "FCEU not fetched, skipping ..."
2011-11-02 15:27:23 +00:00
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_gambatte()
2011-11-02 15:27:23 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-gambatte" ]; then
2011-11-02 15:27:23 +00:00
echo "=== Building Gambatte ==="
2012-04-16 17:33:18 +00:00
cd libretro-gambatte/libgambatte
make -f Makefile.libretro -j4 || die "Failed to build Gambatte"
2013-02-02 19:54:19 +00:00
cp gambatte_libretro.so ../libretro-gambatte.so
2012-04-16 17:33:18 +00:00
cd ../..
2011-11-02 15:27:23 +00:00
else
echo "Gambatte not fetched, skipping ..."
fi
}
2012-04-16 17:33:18 +00:00
build_libretro_meteor()
2012-01-03 14:15:33 +00:00
{
2012-04-16 17:33:18 +00:00
if [ -d "libretro-meteor" ]; then
2012-01-03 14:15:33 +00:00
echo "=== Building Meteor ==="
2012-04-16 17:33:18 +00:00
cd libretro-meteor/libretro
2012-01-03 14:15:33 +00:00
make -j4 || die "Failed to build Meteor"
2012-04-16 17:33:18 +00:00
cp libretro.so ../libretro-meteor.so
2012-04-22 18:45:51 +00:00
cd ../..
2012-01-03 14:15:33 +00:00
else
echo "Meteor not fetched, skipping ..."
fi
}
2012-04-22 18:45:51 +00:00
build_libretro_nx()
{
if [ -d "libretro-nx" ]; then
echo "=== Building NXEngine ==="
2013-01-16 18:29:34 +00:00
cd libretro-nx
2012-04-22 18:45:51 +00:00
make -j4 || die "Failed to build NXEngine"
2013-02-02 19:54:19 +00:00
cp nxengine_libretro.so libretro-nx.so
2013-01-16 18:29:34 +00:00
cd ..
2012-04-22 18:45:51 +00:00
else
echo "NXEngine not fetched, skipping ..."
fi
}
2011-11-02 15:27:23 +00:00
2012-05-16 21:22:42 +00:00
build_libretro_prboom()
{
if [ -d "libretro-prboom" ]; then
echo "=== Building PRBoom ==="
cd libretro-prboom
make -j4 || die "Failed to build PRBoom"
2013-02-02 19:54:19 +00:00
cp prboom_libretro.so libretro-prboom.so
2012-05-16 21:22:42 +00:00
cd ../
else
echo "PRBoom not fetched, skipping ..."
fi
}
2012-08-28 08:07:58 +00:00
build_libretro_stella()
2012-08-28 07:49:17 +00:00
{
2012-08-28 08:07:58 +00:00
if [ -d "libretro-stella" ]; then
echo "=== Building Stella ==="
cd libretro-stella
make -j4 || die "Failed to build Stella"
cp libretro.so libretro-stella.so
2012-08-28 07:49:17 +00:00
cd ../
else
2012-08-28 08:07:58 +00:00
echo "Stella not fetched, skipping ..."
fi
}
2012-10-31 20:05:58 +00:00
build_libretro_desmume()
{
if [ -d "libretro-desmume" ]; then
echo "=== Building Desmume ==="
cd libretro-desmume
make -f Makefile.libretro -j4 || die "Failed to build Desmume"
cp libretro.so libretro-desmume.so
cd ../
else
echo "Desmume not fetched, skipping ..."
fi
}
2012-08-28 08:07:58 +00:00
2013-01-10 13:33:48 +00:00
build_libretro_quicknes()
{
if [ -d "libretro-quicknes" ]; then
echo "=== Building QuickNES ==="
cd libretro-quicknes/libretro
2013-01-10 13:51:06 +00:00
make -j4 || die "Failed to build QuickNES"
2013-01-10 13:33:48 +00:00
cp libretro.so ../libretro-quicknes.so
cd ../..
else
echo "QuickNES not fetched, skipping ..."
fi
}
2013-01-16 08:08:42 +00:00
build_libretro_nestopia()
{
if [ -d "libretro-nestopia" ]; then
echo "=== Building Nestopia ==="
cd libretro-nestopia/libretro
make -j4 || die "Failed to build Nestopia"
2013-02-02 19:54:19 +00:00
cp nestopia_libretro.so ../libretro-nestopia.so
2013-01-16 08:08:42 +00:00
cd ../..
else
echo "Nestopia not fetched, skipping ..."
fi
}
2013-01-10 13:33:48 +00:00
2012-04-16 17:33:18 +00:00
build_libretro_bsnes
2012-11-08 21:55:59 +00:00
build_libretro_mednafen
2012-04-16 17:33:18 +00:00
build_libretro_s9x
build_libretro_s9x_next
build_libretro_genplus
build_libretro_fba
build_libretro_vba
build_libretro_bnes
build_libretro_fceu
build_libretro_gambatte
build_libretro_meteor
2012-04-22 18:45:51 +00:00
build_libretro_nx
2012-05-16 21:22:42 +00:00
build_libretro_prboom
2012-08-28 08:07:58 +00:00
build_libretro_stella
2012-10-31 20:05:58 +00:00
build_libretro_desmume
2013-01-10 13:33:48 +00:00
build_libretro_quicknes
2013-01-16 08:08:42 +00:00
build_libretro_nestopia
2011-11-02 15:27:23 +00:00