Updated for DCMAKE_INSTALL_PREFIX as a replacement for copyfiles

This commit is contained in:
Jack Slater 2025-08-31 17:49:13 -10:00
parent 7fd46c86c4
commit 45788d29a3

View File

@ -7,7 +7,7 @@ export DBUILD_SERVER="${DBUILD_SERVER:-1}"
export DUSE_HTTP="${DUSE_HTTP:-1}"
export DUSE_CODEC_OPUS="${DUSE_CODEC_OPUS:-1}"
export DUSE_VOIP="${DUSE_VOIP:-1}"
export COPYDIR="${COPYDIR:-~/ioquake3}"
export DCMAKE_INSTALL_PREFIX="${DCMAKE_INSTALL_PREFIX:-~/ioquake3}"
IOQ3REMOTE="${IOQ3REMOTE:-https://github.com/ioquake/ioq3.git}"
CMAKE_OPTS="${CMAKE_OPTS:-}"
@ -23,17 +23,17 @@ echo " This build process requires all of the ioquake3 dependencies necessary fo
Please post a message to https://discourse.ioquake.org/ asking for help and include whatever error messages you received during the compile phase.
We will be building from the git repo at ${IOQ3REMOTE}
The resulting binary will be installed to ${COPYDIR}
The resulting binary will be installed to ${DCMAKE_INSTALL_PREFIX}
If you need to change these, please set variables as follows:
IOQ3REMOTE=https://github.com/something/something.git COPYDIR=~/somewhere $0"
IOQ3REMOTE=https://github.com/something/something.git DCMAKE_INSTALL_PREFIX=~/somewhere $0"
BUILD_DIR="$(mktemp -d)"
trap "rm -rf $BUILD_DIR" EXIT
while true; do
read -p "Are you ready to compile ioquake3 from ${IOQ3REMOTE}, and have it installed into $COPYDIR? " yn
read -p "Are you ready to compile ioquake3 from ${IOQ3REMOTE}, and have it installed into $DCMAKE_INSTALL_PREFIX? " yn
case $yn in
[Yy]*)
git clone $IOQ3REMOTE $BUILD_DIR/ioq3
@ -44,10 +44,10 @@ while true; do
-DUSE_HTTP="$DUSE_HTTP" \
-DUSE_CODEC_OPUS="$USE_CODEC_OPUS" \
-DUSE_VOIP="$USE_VOIP" \
-DCMAKE_INSTALL_PREFIX="$DCMAKE_INSTALL_PREFIX" \
$CMAKE_OPTS
cmake --build build
# This needs a replacement for the CMake era
# cmake copyfiles
cmake --install build
exit
;;
[Nn]*)