From 0e0bd1de9b6668635ee7883487fb1e69aae4d35e Mon Sep 17 00:00:00 2001 From: radius Date: Fri, 15 Dec 2017 17:23:16 -0500 Subject: [PATCH] update script --- environment/psp-env.sh | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/environment/psp-env.sh b/environment/psp-env.sh index 170cebaa..11d36f8f 100644 --- a/environment/psp-env.sh +++ b/environment/psp-env.sh @@ -1,24 +1,15 @@ display_usage() { - echo "Usage: [install] [build]" + echo "Usage: [install] [build] [export]" echo -e "It will install the toolchain in /home/buildbot/tools\n" echo -e "Arguments:\n" echo -e "install:\n install or re(install) the toolchain" echo -e "build:\n update the source tree and build everything" + echo -e "export:\n setup the environment for local building, run with source psp-env.sh" } #!/bin/bash -export PATH=$PATH:/home/buildbot/tools/devkitpro/devkitPSP/bin/ -export DEVKITPRO=/home/buildbot/tools/devkitpro/ -export DEVKITPSP=/home/buildbot/tools/devkitpro/devkitPSP/ -export platform=psp1 -export PLATFORM=psp1 -export CC=psp-gcc -export CXX=psp-g++ - -cd ~ - if [ "$1" = "install" ]; then if [[ "$MSYSTEM" == *"MINGW64"* ]]; then pacman -S git make p7zip tar wget @@ -61,6 +52,19 @@ if [ "$1" = "build" ]; then ./libretro-buildbot-recipe.sh recipes/playstation/psp fi; -if [ $# -le 1 ]; then +if [ "$1" = "export" ]; then + export PATH=$PATH:/home/buildbot/tools/devkitpro/devkitPSP/bin/ + export DEVKITPRO=/home/buildbot/tools/devkitpro/ + export DEVKITPSP=/home/buildbot/tools/devkitpro/devkitPSP/ + export platform=psp1 + export PLATFORM=psp1 + export CC=psp-gcc + export CXX=psp-g++ + + echo environment ready... +fi + +if [ $# -le 0 ]; then display_usage fi +