-
-
Save Calimerorulez/54e9035aa432b80a96fb4a013573b81b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
## Build Script by Caio Oliveira aka Caio99BR <[email protected]> | |
# For Open-PS2-Loader | |
## Thanks to: | |
# - izdubar@psx-scene and jimmikaelkael@psx-scene | |
# <http://psx-scene.com/forums/f150/%5Blinux%5D-opl-compile-guides-63749/> | |
# - Bat Rastard@psx-scene and doctorxyz@psx-scene | |
# <http://psx-scene.com/forums/f150/2015-linux-mint-vm-creation-opl-compiling-guide-ps2sdk-127047/index3.html#post1169435> | |
# - and a lot of people around internet :) | |
## Clone your OPL | |
git clone https://github.com/Caio99BR/Open-PS2-Loader | |
## Save env dir | |
cd Open-PS2-Loader/ | |
export TRAVIS_BUILD_DIR=$(pwd) | |
cd ../ | |
export TRAVIS_ENV_DIR=$(pwd) | |
## Dependencies | |
sudo apt-get install -yqqq gcc-4.4 patch wget make git libc6-dev zlib1g zlib1g-dev libucl1 libucl-dev | |
## Make cleanup, just for prevent anything | |
rm -rf ${TRAVIS_ENV_DIR}/gsKit/ ${TRAVIS_ENV_DIR}/ps2eth/ ${TRAVIS_ENV_DIR}/ps2toolchain/ ${TRAVIS_ENV_DIR}/ps2-packer/ ${TRAVIS_ENV_DIR}/ps2sdk-ports/ | |
## Set up the environment | |
export PS2DEV=${TRAVIS_ENV_DIR}/ps2dev | |
export PS2SDK=${PS2DEV}/ps2sdk | |
export PATH=${PATH}:${PS2DEV}/bin:${PS2DEV}/ee/bin:${PS2DEV}/iop/bin:${PS2DEV}/dvp/bin:${PS2SDK}/bin | |
export PS2ETH=${PS2DEV}/ps2eth | |
export GSKIT=${PS2DEV}/gsKit | |
export LANG=C | |
export LC_ALL=C | |
## Clone all | |
git clone --quiet https://github.com/ps2dev/ps2toolchain.git ${TRAVIS_ENV_DIR}/ps2toolchain/ | |
git clone --quiet https://github.com/ps2dev/ps2sdk-ports.git ${TRAVIS_ENV_DIR}/ps2sdk-ports/ | |
git clone --quiet https://github.com/ps2dev/ps2eth ${TRAVIS_ENV_DIR}/ps2eth/ | |
git clone --quiet https://github.com/ps2dev/gsKit.git ${TRAVIS_ENV_DIR}/gsKit/ | |
git clone --quiet https://github.com/ps2dev/ps2-packer.git ${TRAVIS_ENV_DIR}/ps2-packer/ | |
chmod +x $(find . -name \*sh) | |
## ps2dev/PS2Toolchain | |
cd ${TRAVIS_ENV_DIR}/ps2toolchain/ | |
bash ./toolchain.sh | |
## ps2dev/PS2SDKPorts/zlib | |
cd ${TRAVIS_ENV_DIR}/ps2sdk-ports/zlib/ | |
make | |
make install | |
## ps2dev/PS2SDKPorts/libpng | |
cd ${TRAVIS_ENV_DIR}/ps2sdk-ports/libpng/ | |
make | |
make install | |
## ps2dev/PS2SDKPorts/libjpeg | |
cd ${TRAVIS_ENV_DIR}/ps2sdk-ports/libjpeg/ | |
make | |
make install | |
## ps2dev/PS2SDKPorts/freetype | |
cd ${TRAVIS_ENV_DIR}/ps2sdk-ports/freetype-2.4.12/ | |
bash ./SetupPS2.sh | |
## ps2dev/PS2ETH | |
cd ${TRAVIS_ENV_DIR}/ps2eth/ | |
make | |
sudo mkdir -p /usr/lib/ps2dev/ps2eth | |
sudo tar c $(find . -name \*irx) | sudo tar x -C /usr/lib/ps2dev/ps2eth | |
## ps2dev/gsKit | |
cd ${TRAVIS_ENV_DIR}/gsKit/ | |
make | |
make install | |
## ps2dev/PS2Packer | |
cd ${TRAVIS_ENV_DIR}/ps2-packer/ | |
make | |
make install | |
script: | |
## Go back to opl dir | |
cd ${TRAVIS_BUILD_DIR}/ | |
## Make a new changelog and pack of langs | |
bash ./make_changelog.sh | |
bash ./lng_pack.sh | |
## Hack to prevent '-dirty' flag | |
git add -A | |
## Let's build Open PS2 Loader Release! | |
make release | |
## Export the version | |
make oplversion |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment