From 2758eebbcced92b605461ed49db9bf4315fd3ec3 Mon Sep 17 00:00:00 2001 From: "Zachary J. Slater" Date: Mon, 6 Jul 2015 17:14:34 -0700 Subject: [PATCH] server_compile.sh & start_server.sh for Linux ioq3 sysadmins MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If your distribution doesn’t include such niceties, these could help a newbie get started with a compiled build of ioquake3 for servers and a short script to get started. --- misc/linux/server_compile.sh | 23 +++++++++++++++++++++++ misc/linux/start_server.sh | 3 +++ 2 files changed, 26 insertions(+) create mode 100644 misc/linux/server_compile.sh create mode 100644 misc/linux/start_server.sh diff --git a/misc/linux/server_compile.sh b/misc/linux/server_compile.sh new file mode 100644 index 00000000..6b4ae118 --- /dev/null +++ b/misc/linux/server_compile.sh @@ -0,0 +1,23 @@ +#!/bin/bash +localPATH=`pwd` +export BUILD_CLIENT="0" +export BUILD_SERVER="1" +export USE_CURL="1" +export USE_CODEC_OPUS="1" +export USE_VOIP="1" +export COPYDIR="~/ioquake3" +IOQ3REMOTE="https://github.com/ioquake/ioq3.git" +IOQ3LOCAL="/tmp/ioquake3compile" +JOPTS="-j2" +echo "This process requires you to have the following installed through your distribution: \n make\n git\n and all of the ioquake3 dependencies necessary for an ioquake3 server. \n If you do not have the necessary dependencies this script will bail out. \n Please post a message to http://community.ioquake.org/ asking for help and include whatever error messages you received during the compile phase. \n Please edit this script. Inside you will find a COPYDIR variable you can alter to change where ioquake3 will be installed to." +while true; do + read -p "Are you ready to compile ioquake3 in the $IOQ3LOCAL directory, and have it installed into $COPYDIR?" yn +case $yn in + [Yy]* ) +if [ -x "$(command -v git)" ] && [ -x "$(command -v make)" ] ; then + git clone $IOQ3REMOTE $IOQ3LOCAL && cd $IOQ3LOCAL && make $JOPTS && make copyfiles && cd $localPATH && rm -rf $IOQ3LOCAL +fi ;; + [Nn]* ) exit;; + * ) echo "Please answer yes or no.";; +esac +done \ No newline at end of file diff --git a/misc/linux/start_server.sh b/misc/linux/start_server.sh new file mode 100644 index 00000000..82d28c03 --- /dev/null +++ b/misc/linux/start_server.sh @@ -0,0 +1,3 @@ +#!/bin/sh +echo "Edit this script to change the path to ioquake3's dedicated server executable and which binary if you aren't on x86_64.\n Set the sv_dlURL setting to a url like http://yoursite.com/ioquake3_path for ioquake3 clients to download extra data" +~/ioquake3/ioq3ded.x86_64 +set dedicated 2 +set sv_allowDownload 1 +set sv_dlURL "" +set com_hunkmegs 64