Last active
April 23, 2016 09:36
-
-
Save btrepp/eebb85a23b721ca789673a9caf21bbf6 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| #Obviously change this to a different folder if you want | |
| mkdir ~/rpi && cd ~/rpi | |
| LIBSDLVERSION=SDL2-2.0.4 | |
| #build deps | |
| sudo apt-get install build-essential g++-arm-linux-gnueabihf cmake | |
| curl https://www.libsdl.org/release/$LIBSDLVERSION.tar.gz | tar xvf | |
| git clone --recursive https://github.com/SDLash3D/xash3d.git | |
| git clone https://github.com/raspberrypi/tools.git --depth=1 | |
| mkdir -p $LIBSDLVERSION/build && cd $LIBSDLVERSION/build | |
| cmake -DCMAKE_TOOLCHAIN_FILE=~/rpitoolchain.cmake .. | |
| make | |
| make install #installs to the sysroot | |
| mkdir -p ../../xash3d/build && cd ../../xash3d/build | |
| cmake -DHL_SDK_DIR=../hlsdk -DXASH_SDL=yes -DXASH_GLES=yes -DXASH_VGUI=no -DCMAKE_TOOLCHAIN_FILE=~/rpitoolchain.cmake .. | |
This file contains hidden or 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
| set(CMAKE_SYSTEM_NAME Linux) | |
| set(CMAKE_SYSROOT /home/beau/tools/arm-bcm2708/arm-rpi-4.9.3-linux-gnueabihf/arm-linux-gnueabihf/sysroot/) | |
| set(CMAKE_STAGING_PREFIX /home/beau/tools/arm-bcm2708/arm-rpi-4.9.3-linux-gnueabihf/arm-linux-gnueabihf/sysroot/) | |
| set(CMAKE_C_COMPILER /home/beau/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf-gcc) | |
| set(CMAKE_CXX_COMPILER /home/beau/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf-g++) | |
| set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | |
| set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) | |
| set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) | |
| set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment