1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- #!/bin/ksh
- doas pkg_add cmake gmake sdl2 sdl2-image sdl2-mixer fluidsynth libmad portmidi libvorbis libzip
- application=dsda-doom
- repository=https://github.com/kraflab/dsda-doom.git
- export compile=
- mkdir -p ~/src
- cd ~/src || return
- if [ ! -d $application ]; then
- git clone $repository
- cd $application || return
- export compile=true
- else
- cd $application || return
- #git pull
- pwd
- git fetch
- LOCAL=$(git rev-parse HEAD)
- REMOTE=$(git rev-parse @{u})
- if [ ! $LOCAL = $REMOTE ]; then
- pwd
- echo "Need to pull"
- git pull
- export compile=true
- fi
- fi
- if [ "$compile" = "true" ]; then
- cd ~/src/$application || return
- cd prboom2 || return
- echo ""
- echo "NOTE: If getting a 'Provide an AUTOMAKE_VERSION environment variable, please' error do this:"
- echo "$ export AUTOMAKE_VERSION=1.16 # <- (version without minor number 1.16.5 > 1.16)"
- echo "$ export AUTOCONF_VERSION=2.71 # <- (version without minor number 2.71p3 > 2.71)"
- echo ""
- export AUTOMAKE_VERSION=1.16
- export AUTOCONF_VERSION=2.71
- mkdir -p build && cd build
- export CPPFLAGS="${CPPFLAGS} $(pkg-config --cflags osmesa) $(pkg-config --cflags glut) $(pkg-config --cflags gl)"
- cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_FLUIDSYNTH=OFF
- gmake
- fi
|