mirror of
https://github.com/glest/glest-source.git
synced 2025-08-29 10:49:48 +02:00
CMakeLists.txt:checking, tuning the build system (#232)
* build.zg.sh scripts deprected * update for BSD * removed checking for VLC (not implemented) * docs updated * Install.md created. * scripts moved to scripts/ directory
This commit is contained in:
@@ -1,54 +0,0 @@
|
||||
#!/bin/bash
|
||||
# Use this script to Analyze world synchronization log files between two or
|
||||
# more networked players
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2011 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
MAX_SPLIT_SIZE_BYTES=75000000
|
||||
|
||||
echo 'Max split file size = '"$MAX_SPLIT_SIZE_BYTES"
|
||||
|
||||
echo 'Setting up temp folders...'
|
||||
|
||||
if [ -d temp ]; then
|
||||
echo 'Purging temp folders...'
|
||||
rm -r temp
|
||||
fi
|
||||
|
||||
if [ ! -d temp ]; then
|
||||
echo 'Creating temp folders...'
|
||||
mkdir temp
|
||||
fi
|
||||
|
||||
if [ ! -d temp ]; then
|
||||
echo 'Could not find temp folders, exiting...'
|
||||
exit
|
||||
fi
|
||||
|
||||
cd temp
|
||||
if [ ! -d temp1 ]; then
|
||||
echo 'Creating temp sub folders...'
|
||||
mkdir temp1
|
||||
fi
|
||||
|
||||
if [ -f xaa ] ; then
|
||||
rm x*
|
||||
fi
|
||||
|
||||
echo 'Copying logs to temp folders...'
|
||||
cp ../debugWorldSynch.log* .
|
||||
cp debugWorldSynch.log1 temp1/
|
||||
|
||||
echo 'Splitting logs in temp folders...'
|
||||
split -b $MAX_SPLIT_SIZE_BYTES debugWorldSynch.log
|
||||
|
||||
cd temp1
|
||||
if [ -f xaa ] ; then
|
||||
rm x*
|
||||
fi
|
||||
|
||||
split -b $MAX_SPLIT_SIZE_BYTES debugWorldSynch.log1
|
||||
cd ../
|
||||
|
||||
echo 'Please diff the files xaa (and other split files) in temp folders temp and temp1...'
|
@@ -6,6 +6,15 @@
|
||||
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
echo ""
|
||||
echo "This script has been deprecated. Please see"
|
||||
echo "https://github.com/ZetaGlest/zetaglest-source/blob/develop/BUILD.md"
|
||||
echo "For updated build instructions."
|
||||
echo ""
|
||||
|
||||
exit 0
|
||||
|
||||
|
||||
#
|
||||
# Configuration section
|
||||
#
|
||||
@@ -311,12 +320,12 @@ if [ $FORCE_32BIT_CROSS_COMPILE != 0 ]; then
|
||||
fi
|
||||
|
||||
if [ "$COMPILATION_WITHOUT" != "0" ] && [ "$COMPILATION_WITHOUT" != "" ]; then
|
||||
EXTRA_CMAKE_OPTIONS="${EXTRA_CMAKE_OPTIONS} -DBUILD_ZETAGLEST_MAP_EDITOR=OFF -DBUILD_ZETAGLEST_MODEL_VIEWER=OFF"
|
||||
EXTRA_CMAKE_OPTIONS="${EXTRA_CMAKE_OPTIONS} -DBUILD_MAP_EDITOR=OFF -DBUILD_MODEL_VIEWER=OFF"
|
||||
fi
|
||||
|
||||
if [ $MAKE_ONLY = 0 ]; then
|
||||
echo "Calling cmake with EXTRA_CMAKE_OPTIONS = ${EXTRA_CMAKE_OPTIONS} AND WANT_STATIC_LIBS = ${WANT_STATIC_LIBS}"
|
||||
cmake -DCMAKE_INSTALL_PREFIX='' -DWANT_DEV_OUTPATH=ON $WANT_STATIC_LIBS -DBUILD_ZETAGLEST_TESTS=$BUILD_ZETAGLEST_TESTS -DBREAKPAD_ROOT=$BREAKPAD_ROOT $EXTRA_CMAKE_OPTIONS ../../..
|
||||
cmake -DCMAKE_INSTALL_PREFIX='' $WANT_STATIC_LIBS -DBUILD_ZETAGLEST_TESTS=$BUILD_ZETAGLEST_TESTS -DBREAKPAD_ROOT=$BREAKPAD_ROOT $EXTRA_CMAKE_OPTIONS ../../..
|
||||
if [ $? -ne 0 ]; then
|
||||
echo 'ERROR: CMAKE failed.' >&2; exit 1
|
||||
fi
|
||||
|
@@ -1,3 +0,0 @@
|
||||
DataPath=$APPLICATIONPATH/../../../zetaglest-data/
|
||||
ServerListPath=$APPLICATIONPATH/../shared/
|
||||
GlestKeysIniPath=$APPLICATIONPATH/../shared/
|
@@ -1,96 +0,0 @@
|
||||
; === propertyMap File ===
|
||||
; This file defines default properties and values. Do not edit this file,
|
||||
; instead, to modify, copy any properties to glestuser.ini, then change these as
|
||||
; needed. Values contained in glestuser.ini will overwrite values found here.
|
||||
;
|
||||
; For explanation of these properties, please refer to the MegaGlest wiki at
|
||||
; http://wiki.megaglest.org/
|
||||
;
|
||||
AiLog=0
|
||||
AiRedir=false
|
||||
AllowDownloadDataSynch=false
|
||||
AllowGameDataSynchCheck=false
|
||||
AllowRotateUnits=true
|
||||
AnnouncementURL=http://zetaglest.dreamhosters.com/files/announcement.txt
|
||||
AutoMaxFullScreen=false
|
||||
AutoTest=false
|
||||
CheckGlCaps=true
|
||||
ColorBits=32
|
||||
ConsoleMaxLines=6
|
||||
ConsoleMaxLinesStored=25
|
||||
ConsoleTimeout=20
|
||||
DataPath=$APPLICATIONDATAPATH/
|
||||
LogPath=$HOME/.zetaglest/
|
||||
DayTime=1000
|
||||
DebugLogFile=debug.log
|
||||
DebugMode=false
|
||||
DebugPerformance=false
|
||||
DebugNetwork=false
|
||||
DebugWorldSynch=false
|
||||
DepthBits=16
|
||||
FactoryGraphics=OpenGL
|
||||
FactorySound=OpenAL
|
||||
FastSpeedLoops=8
|
||||
FileArchiveExtension=.7z
|
||||
FileArchiveExtractCommand=7z
|
||||
FileArchiveExtractCommandParameters=x -o{outputpath} {archivename}
|
||||
FileArchiveExtractCommandSuccessResult=0
|
||||
FileArchiveCompressCommand=7z
|
||||
FileArchiveCompressCommandParameters=a -r -xr!?svn\* {archivename} {archivefiles}
|
||||
FileArchiveCompressCommandSuccessResult=0
|
||||
Filter=Bilinear
|
||||
FilterMaxAnisotropy=1
|
||||
FirstTime=false
|
||||
FocusArrows=true
|
||||
FogOfWarSmoothing=true
|
||||
FogOfWarSmoothingFrameSkip=3
|
||||
FontConsoleBaseSize=14
|
||||
FontConsolePostfix=-*-*-*-*-*-*-*
|
||||
FontConsolePrefix=-*-arial-*-r-*-*-
|
||||
FontDisplayBaseSize=12
|
||||
FontDisplayPostfix=-*-*-*-*-*-*-*
|
||||
FontDisplayPrefix=-*-arial-*-r-*-*-
|
||||
FontDisplaySmallBaseSize=12
|
||||
FontMenuBigBaseSize=20
|
||||
FontMenuBigPostfix=-*-*-*-*-*-*-*
|
||||
FontMenuBigPrefix=-*-arial-*-r-*-*-
|
||||
FontMenuNormalBaseSize=14
|
||||
FontMenuNormalPostfix=-*-*-*-*-*-*-*
|
||||
FontMenuNormalPrefix=-*-arial-*-r-*-*-
|
||||
FontMenuVeryBigBaseSize=25
|
||||
FontSizeAdjustment=0
|
||||
FONT_HEIGHT_TEXT=yW
|
||||
Lang=english
|
||||
MaxLights=3
|
||||
Masterserver=http://zetaglest.dreamhosters.com/
|
||||
NetPlayerName=newbie
|
||||
NetworkConsistencyChecks=true
|
||||
NetworkInterfaces=lo,eth,wlan,vlan,vboxnet,br-lan,br-gest,enp0s,enp1s,enp2s,enp3s,enp4s,enp5s,enp6s,enp7s,enp8s,enp9s
|
||||
PhotoMode=false
|
||||
PortList=61357,61367,61377,61387,61397
|
||||
PortServer=61357
|
||||
RefreshFrequency=75
|
||||
ScreenHeight=600
|
||||
ScreenWidth=800
|
||||
ServerIp=192.168.0.107
|
||||
ShadowFrameSkip=2
|
||||
ShadowTextureSize=512
|
||||
Shadows=Projected
|
||||
SoundStaticBuffers=16
|
||||
SoundStreamingBuffers=4
|
||||
SoundVolumeAmbient=80
|
||||
SoundVolumeFx=80
|
||||
SoundVolumeMusic=90
|
||||
StencilBits=0
|
||||
Textures3D=true
|
||||
TranslationGetURL=https://www.transifex.com/api/2/project/megaglest/resource/$file/translation/$language
|
||||
TranslationGetURLDetails=https://www.transifex.com/api/2/project/megaglest/resource/$file/?details
|
||||
TranslationGetURLFileList=main-language-file|megapack-language-file|loading-screen-hints|tutorials-1-very-basic-tutorial|tutorials-2-basic-tutorial|tutorials-3-advanced-tutorial|scenarios-amazones|scenarios-amazones-light|scenarios-capture-enemy-flag|scenarios-storming
|
||||
TranslationGetURLFileListMapping=data/lang/$language.lng|techs/megapack/lang/megapack_$language.lng|data/lang/hint/hint_$language.lng|tutorials/1_very_basic_tutorial/1_very_basic_tutorial_$language.lng|tutorials/2_basic_tutorial/2_basic_tutorial_$language.lng|tutorials/3_advanced_tutorial/3_advanced_tutorial_$language.lng|scenarios/amazones/amazones_$language.lng|scenarios/amazones_light/amazones_light_$language.lng|scenarios/capture_enemy_flag/capture_enemy_flag_$language.lng|scenarios/storming/storming_$language.lng
|
||||
TranslationGetURLLanguage=en
|
||||
TranslationGetURLPassword=
|
||||
TranslationGetURLUser=<enter username>
|
||||
UnitParticles=true
|
||||
UserData_Root=$HOME/.zetaglest/
|
||||
VersionURL=http://zetaglest.dreamhosters.com/files/versions/
|
||||
Windowed=false
|
@@ -1,120 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
# Use this script to copy shared (libs) files to specified location
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Vivek Gite <http://www.cyberciti.biz/>
|
||||
# Copyright (c) 2006 nixCraft under GNU GPL v2.0+
|
||||
# Last updated on: Apr/06/2010 by Vivek Gite
|
||||
# ----------------------------------------------------------------------------
|
||||
# + Modified for megaglest deployment - Softcoder
|
||||
# + Added ld-linux support
|
||||
# + Added error checking support
|
||||
# + Added for loop so that we can process all files on cmd
|
||||
# ----------------------------------------------------------------------------
|
||||
# Set libs output directory name
|
||||
BASE="lib"
|
||||
file="$@"
|
||||
|
||||
sync_support_libs(){
|
||||
local d="$1" # folder to copy dependencies to
|
||||
local pFILE="$2" # bin file to scan for dependencies from
|
||||
local files=""
|
||||
local _cp="/bin/cp"
|
||||
#local skip_deps="libm.so libpthread.so libstdc++.so libgcc_s.so libc.so libdl.so libX11.so libpulse libfusion libdirect libnvidia libXext librt libxcb libICE libSM libXtst libwrap libdbus libXau libXdmcp libnsl libFLAC libGL"
|
||||
local skip_deps=""
|
||||
local keep_deps="libcurl libgnu libgcrypt libnghttp libidn libpsl libunistring librtmp libssh libnettle libicu liblua libjpeg libpng libvorbis libogg libircclient libminiupnpc libwx_ libGLEW libftgl libfreetype libfribidi libvlc libopenal libSDL2-"
|
||||
# libwx_ - recommended to keep always just because API/ABI compatibility, huge impact for map editor
|
||||
# libGLEW - most likely safe to keep embedded everywhere, its version matters with tools
|
||||
# libopenal - safe to keep but if any version is available locally then should be replaced
|
||||
# libSDL2 - safe to keep on .deb family only and even there, if any version is available locally then should be replaced
|
||||
# liblber & libldap_r - aren't safe to keep, very nasty secondary dependencies
|
||||
# libunistring - is it enough popular to not be necessary there? not sure
|
||||
# libfribidi - not enough popular to be installed by default on the "every fresh OS"
|
||||
|
||||
local scan_via_skiplist=1
|
||||
|
||||
if [ -n "$skip_deps" ]; then
|
||||
scan_via_skiplist=1
|
||||
echo "scanning for deps TO SKIP for '$pFILE'..."
|
||||
elif [ -n "$keep_deps" ]; then
|
||||
scan_via_skiplist=0
|
||||
echo "scanning for deps TO KEEP for '$pFILE'..."
|
||||
fi
|
||||
|
||||
|
||||
# get rid of blanks and (0x00007fff0117f000)
|
||||
files="$(ldd $pFILE | awk '{ print $3 }' | sed -e '/^$/d' -e '/(*)$/d')"
|
||||
|
||||
for i in $files
|
||||
do
|
||||
dcc="${i%/*}" # get dirname only
|
||||
# [ ! -d ${d}${dcc} ] && mkdir -p ${d}${dcc}
|
||||
# ${_cp} -f $i ${d}${dcc}
|
||||
# ${_cp} -f $i ${d}
|
||||
# echo ${_cp} -f $i ${d}
|
||||
|
||||
skipfile=0
|
||||
|
||||
if [ $scan_via_skiplist -eq 1 ]; then
|
||||
for j in $(echo $skip_deps)
|
||||
do
|
||||
if [ `awk "BEGIN {print index(\"$i\", \"$j\")}"` -ne 0 ]; then
|
||||
# echo Skipping file = [$i]
|
||||
skipfile=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
elif [ $scan_via_skiplist -eq 0 ]; then
|
||||
skipfile=1
|
||||
for j in $(echo $keep_deps)
|
||||
do
|
||||
if [ `awk "BEGIN {print index(\"$i\", \"$j\")}"` -ne 0 ]; then
|
||||
# echo Skipping file = [$i]
|
||||
skipfile=0
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
if [ "$skipfile" -eq "0" ] && [ ! -e "$d/$(basename "$i")" ]; then
|
||||
echo Including file = [$i]
|
||||
${_cp} -f $i ${d}
|
||||
fi
|
||||
done
|
||||
|
||||
# Works with 32 and 64 bit ld-linux
|
||||
#sldl="$(ldd $pFILE | grep 'ld-linux' | awk '{ print $1}')"
|
||||
#sldlsubdir="${sldl%/*}"
|
||||
# [ ! -f ${d}${sldl} ] && ${_cp} -f ${sldl} ${d}${sldlsubdir}
|
||||
#if [ ! -f ${d}${sldl} ] ; then
|
||||
# echo Including file = [${sldl}]
|
||||
# ${_cp} -f ${sldl} ${d}
|
||||
#fi
|
||||
}
|
||||
|
||||
usage(){
|
||||
echo "Error: Wrong syntax. Example: $0 megaglest"
|
||||
exit 1
|
||||
}
|
||||
|
||||
[ $# -eq 0 ] && usage
|
||||
if [ ! -d "$BASE" ]; then mkdir -p "$BASE"; fi
|
||||
|
||||
# copy all files
|
||||
for f in $file
|
||||
do
|
||||
sync_support_libs "${BASE}" "${f}"
|
||||
done
|
||||
|
||||
# copy vlc's plugins if libvlc was copied
|
||||
if [ "$(find $BASE -type f -name "libvlc.*")" != "" ]; then
|
||||
LIBVLC_DIR_CHECK="$( ldd "$1" | grep "libvlc\." | sort -u | awk '{print $3}' | head -1 )"
|
||||
if [ "$LIBVLC_DIR_CHECK" != "" ]; then
|
||||
LIBVLC_DIR="$(dirname "$LIBVLC_DIR_CHECK")"
|
||||
if [ -d "$LIBVLC_DIR/vlc/plugins" ]; then
|
||||
mkdir -p "$BASE/vlc"
|
||||
echo "Including plugins directory for VLC from = [$LIBVLC_DIR/vlc]"
|
||||
cp -f -r "$LIBVLC_DIR/vlc/plugins" "$BASE/vlc/"
|
||||
fi
|
||||
fi
|
||||
fi
|
@@ -1,124 +0,0 @@
|
||||
#!/bin/sh
|
||||
# Use this script to synchronize other scripts and installers with the version
|
||||
# in mg-version.sh for a Version Release
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2011-2015 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
CURRENTDIR="$(dirname "$(readlink -f "$0")")"
|
||||
cd "$CURRENTDIR"
|
||||
CURRENT_VERSION=`./mg-version.sh --version`
|
||||
OLD_VERSION=`./mg-version.sh --oldversion_binary`
|
||||
VERSION_INFO_FILE="$(dirname "$(readlink -f "$0")")/../../source/version.txt"
|
||||
LastCompatibleSaveGameVersion="$(awk -F '=' '/^LastCompatibleSaveGameVersion =/ {print $2}' "$VERSION_INFO_FILE" | awk -F '"' '{print $2}')"
|
||||
CurrYear="$(date +%y)"
|
||||
MapeditorVersion="$CURRENT_VERSION"
|
||||
G3dviewerVersion="$CURRENT_VERSION"
|
||||
modifymore="yes"
|
||||
echo
|
||||
echo '===== Updating Game ======'
|
||||
# const string glestVersionString = "v3.12-dev";
|
||||
echo 'Game version # before:'
|
||||
grep -E '^const string glestVersionString = "[^"]*";$' ../../source/glest_game/facilities/game_util.cpp
|
||||
sed -i 's/^const string glestVersionString = "[^"]*";$/const string glestVersionString = "v'$CURRENT_VERSION'";/' ../../source/glest_game/facilities/game_util.cpp
|
||||
echo 'Game version # after:'
|
||||
grep -E '^const string glestVersionString = "[^"]*";$' ../../source/glest_game/facilities/game_util.cpp
|
||||
echo
|
||||
echo 'Game Copyright date # before:'
|
||||
grep -E 'Copyright 2010-20[0-9][0-9] The MegaGlest Team' ../../source/glest_game/facilities/game_util.cpp
|
||||
sed -i 's/Copyright 2010-20[0-9][0-9] The MegaGlest Team/Copyright 2010-20'$CurrYear' The MegaGlest Team/' ../../source/glest_game/facilities/game_util.cpp
|
||||
grep -E '© 2001-20[0-9][0-9] The MegaGlest Team' ../../mk/macos/bundle_resources/Info.plist.in
|
||||
sed -i 's/© 2001-20[0-9][0-9] The MegaGlest Team/© 2001-20'$CurrYear' The MegaGlest Team/' ../../mk/macos/bundle_resources/Info.plist.in
|
||||
echo 'Game Copyright date # after:'
|
||||
grep -E 'Copyright 2010-20[0-9][0-9] The MegaGlest Team' ../../source/glest_game/facilities/game_util.cpp
|
||||
grep -E '© 2001-20[0-9][0-9] The MegaGlest Team' ../../mk/macos/bundle_resources/Info.plist.in
|
||||
echo
|
||||
if [ "$modifymore" = "yes" ]; then
|
||||
# const string lastCompatibleSaveGameVersionString = "v3.9.0";
|
||||
echo 'Compatible Save Game version # before:'
|
||||
grep -E '^const string lastCompatibleSaveGameVersionString = "[^"]*";$' ../../source/glest_game/facilities/game_util.cpp
|
||||
sed -i 's/^const string lastCompatibleSaveGameVersionString = "[^"]*";$/const string lastCompatibleSaveGameVersionString = "v'$LastCompatibleSaveGameVersion'";/' ../../source/glest_game/facilities/game_util.cpp
|
||||
echo 'Compatible Save Game version # after:'
|
||||
grep -E '^const string lastCompatibleSaveGameVersionString = "[^"]*";$' ../../source/glest_game/facilities/game_util.cpp
|
||||
echo
|
||||
fi
|
||||
if [ "$modifymore" = "yes" ] && [ "$(git status >/dev/null 2>&1; echo "$?")" -eq "0" ]; then
|
||||
# const string GIT_RawRev = "$4446.1a8673f$";
|
||||
GitCommitForRelease="`git rev-list HEAD --count`.`git log -1 --format=%h --abbrev=7`";
|
||||
echo 'GitCommitForRelease # before:'
|
||||
grep -E '^GitCommitForRelease = "[^"]*";$' "$VERSION_INFO_FILE"
|
||||
grep -E '^ const string GIT_RawRev = "\$[^"$]*\$";$' ../../source/glest_game/facilities/game_util.cpp
|
||||
sed -i 's/^GitCommitForRelease = "[^"]*";$/GitCommitForRelease = "'$GitCommitForRelease'";/' "$VERSION_INFO_FILE"
|
||||
sed -i 's/^ const string GIT_RawRev = "$[^"]*";$/ const string GIT_RawRev = "$'$GitCommitForRelease'$";/' ../../source/glest_game/facilities/game_util.cpp
|
||||
echo 'GitCommitForRelease # after:'
|
||||
grep -E '^GitCommitForRelease = "[^"]*";$' "$VERSION_INFO_FILE"
|
||||
grep -E '^ const string GIT_RawRev = "\$[^"$]*\$";$' ../../source/glest_game/facilities/game_util.cpp
|
||||
fi
|
||||
echo
|
||||
if [ "$modifymore" = "yes" ]; then
|
||||
echo '===== Updating Mapeditor ======'
|
||||
# const string mapeditorVersionString = "v1.6.1";
|
||||
echo 'Mapeditor version # before:'
|
||||
grep -E '^const string mapeditorVersionString = "[^"]*";$' ../../source/glest_map_editor/main.cpp
|
||||
sed -i 's/^const string mapeditorVersionString = "[^"]*";$/const string mapeditorVersionString = "v'$MapeditorVersion'";/' ../../source/glest_map_editor/main.cpp
|
||||
echo 'Mapeditor version # after:'
|
||||
grep -E '^const string mapeditorVersionString = "[^"]*";$' ../../source/glest_map_editor/main.cpp
|
||||
echo
|
||||
echo 'Mapeditor Copyright date # before:'
|
||||
grep -E 'Copyright 2010-20[0-9][0-9] The MegaGlest Team' ../../source/glest_map_editor/main.cpp
|
||||
sed -i 's/Copyright 2010-20[0-9][0-9] The MegaGlest Team/Copyright 2010-20'$CurrYear' The MegaGlest Team/' ../../source/glest_map_editor/main.cpp
|
||||
echo 'Mapeditor Copyright date # after:'
|
||||
grep -E 'Copyright 2010-20[0-9][0-9] The MegaGlest Team' ../../source/glest_map_editor/main.cpp
|
||||
echo
|
||||
echo '===== Updating G3dviewer ======'
|
||||
# const string g3dviewerVersionString= "v1.3.6";
|
||||
echo 'G3dviewer version # before:'
|
||||
grep -E '^const string g3dviewerVersionString= "[^"]*";$' ../../source/g3d_viewer/main.cpp
|
||||
sed -i 's/^const string g3dviewerVersionString= "[^"]*";$/const string g3dviewerVersionString= "v'$G3dviewerVersion'";/' ../../source/g3d_viewer/main.cpp
|
||||
echo 'G3dviewer version # after:'
|
||||
grep -E '^const string g3dviewerVersionString= "[^"]*";$' ../../source/g3d_viewer/main.cpp
|
||||
fi
|
||||
echo
|
||||
echo '===== Updating Linux Installer ======'
|
||||
# local GAME_VERSION = "x.x.x";
|
||||
echo 'Linux Installer version # before:'
|
||||
grep -E '^local GAME_VERSION = "[^"]*";$' tools-for-standalone-client/installer/scripts/config.lua
|
||||
sed -i 's/^local GAME_VERSION = "[^"]*";$/local GAME_VERSION = "'$CURRENT_VERSION'";/' tools-for-standalone-client/installer/scripts/config.lua
|
||||
echo 'Linux Installer version # after:'
|
||||
grep -E '^local GAME_VERSION = "[^"]*";$' tools-for-standalone-client/installer/scripts/config.lua
|
||||
echo
|
||||
echo '===== Updating Windows Installer ======'
|
||||
# !define APVER 3.6.0
|
||||
echo 'Windows Installer version # before:'
|
||||
grep -E '^\!define APVER [^"]*$' ../windows/Installer/MegaGlestInstaller.nsi
|
||||
sed -i 's/^\!define APVER [^"]*$/\!define APVER '$CURRENT_VERSION'/' ../windows/Installer/MegaGlestInstaller.nsi
|
||||
echo 'Windows Installer version # after:'
|
||||
grep -E '^\!define APVER [^"]*$' ../windows/Installer/MegaGlestInstaller.nsi
|
||||
echo
|
||||
if [ "$modifymore" = "yes" ]; then
|
||||
echo 'Windows Installer version # before:'
|
||||
grep -E '^\!define APVER_OLD [^"]*$' ../windows/Installer/MegaGlestInstaller.nsi
|
||||
sed -i 's/^\!define APVER_OLD [^"]*$/\!define APVER_OLD '$OLD_VERSION'/' ../windows/Installer/MegaGlestInstaller.nsi
|
||||
echo 'Windows Installer version # after:'
|
||||
grep -E '^\!define APVER_OLD [^"]*$' ../windows/Installer/MegaGlestInstaller.nsi
|
||||
echo
|
||||
echo '===== Updating Windows Updater ======'
|
||||
echo 'Windows Updater version # before:'
|
||||
grep -E '^\!define APVER [^"]*$' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
sed -i 's/^\!define APVER [^"]*$/\!define APVER '$CURRENT_VERSION'/' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
echo 'Windows Updater version # after:'
|
||||
grep -E '^\!define APVER [^"]*$' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
echo
|
||||
echo 'Windows Updater version # before:'
|
||||
grep -E '^\!define APVER_OLD [^"]*$' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
sed -i 's/^\!define APVER_OLD [^"]*$/\!define APVER_OLD '$OLD_VERSION'/' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
echo 'Windows Updater version # after:'
|
||||
grep -E '^\!define APVER_OLD [^"]*$' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
echo
|
||||
echo 'Windows Updater version # before:'
|
||||
grep -E '^\!define APVER_UPDATE [^"]*$' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
sed -i 's/^\!define APVER_UPDATE [^"]*$/\!define APVER_UPDATE '$CURRENT_VERSION'/' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
echo 'Windows Updater version # after:'
|
||||
grep -E '^\!define APVER_UPDATE [^"]*$' ../windows/Installer/MegaGlestUpdater.nsi
|
||||
echo
|
||||
fi
|
@@ -1,24 +0,0 @@
|
||||
#!/bin/sh
|
||||
# Use this script to idenitfy previous and current Version for a Version Release
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2011 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
KERNEL="$(uname -s | tr '[A-Z]' '[a-z]')"
|
||||
if [ "$KERNEL" = "darwin" ]; then
|
||||
CURRENTDIR="$(cd "$(dirname "$0")"; pwd)"
|
||||
else
|
||||
CURRENTDIR="$(dirname "$(readlink -f "$0")")"
|
||||
fi
|
||||
VERSION_INFO_FILE="$CURRENTDIR/../../source/version.txt"
|
||||
OLD_MG_VERSION="$(awk -F '=' '/^OldReleaseGameVersion =/ {print $2}' "$VERSION_INFO_FILE" | awk -F '"' '{print $2}')"
|
||||
OLD_MG_VERSION_BINARY="$OLD_MG_VERSION"
|
||||
MG_VERSION="$(awk -F '=' '/^CurrentGameVersion =/ {print $2}' "$VERSION_INFO_FILE" | awk -F '"' '{print $2}')"
|
||||
|
||||
if [ "$1" = "--oldversion" ]; then
|
||||
echo "$OLD_MG_VERSION"
|
||||
elif [ "$1" = "--oldversion_binary" ]; then
|
||||
echo "$OLD_MG_VERSION_BINARY"
|
||||
elif [ "$1" = "--version" ]; then
|
||||
echo "$MG_VERSION"
|
||||
fi
|
@@ -1,20 +0,0 @@
|
||||
#!/bin/bash
|
||||
# Use this script to produce a google-breakpad stacktrace from a megaglest dmp file
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2013 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
CURRENTDIR="$(dirname $(readlink -f $0))"
|
||||
SYMBOLS_DIR=${CURRENTDIR}/"linux_symbols"
|
||||
|
||||
usage(){
|
||||
echo "Syntax : $0 yourcrashfile.dmp
|
||||
echo "Example: $0 ./328eaddc-c1d5-9eee-3ca1e6a4-0ce3f6a6.dmp
|
||||
exit 1
|
||||
}
|
||||
|
||||
[ $# -eq 0 ] && usage
|
||||
|
||||
echo "About to produce stack trace for $1"
|
||||
echo "Symbols folder: ${SYMBOLS_DIR}"
|
||||
${CURRENTDIR}/../../google-breakpad/src/processor/minidump_stackwalk $1 ${CURRENTDIR}/${SYMBOLS_DIR}
|
@@ -1,13 +0,0 @@
|
||||
#!/bin/bash
|
||||
# Use this script to produce a google-breakpad symbol file for megaglest
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2013 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
CURRENTDIR="$(dirname $(readlink -f $0))"
|
||||
SYMBOLS_DIR=${CURRENTDIR}/"linux_symbols"
|
||||
|
||||
mkdir -p ${SYMBOLS_DIR}
|
||||
echo "Symbols folder: ${SYMBOLS_DIR}"
|
||||
python ${CURRENTDIR}/symbolstore.py ${CURRENTDIR}/../../google-breakpad/src/tools/linux/dump_syms/dump_syms ${SYMBOLS_DIR} ${CURRENTDIR}/megaglest
|
||||
|
@@ -1,18 +0,0 @@
|
||||
#! /bin/sh
|
||||
# Use this script to test performance while running MegaGlest
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2011 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
exec 3>&1
|
||||
export GLIBCPP_FORCE_NEW=1
|
||||
export GLIBCXX_FORCE_NEW=1
|
||||
export G_SLICE=always-malloc
|
||||
|
||||
exec valgrind --tool=callgrind \
|
||||
"$@" 2>&1 1>&3 3>&- |
|
||||
sed 's/^==[0-9]*==/==/' >&2 1>&2 3>&-
|
||||
|
||||
echo 'Look for a generated file called callgrind.out.x.'
|
||||
echo 'You can then use kcachegrind tool to read this file.'
|
||||
echo 'It will give you a graphical analysis of things with results like which lines cost how much.'
|
@@ -1,40 +0,0 @@
|
||||
#!/bin/bash
|
||||
# Use this script to check MegaGlest Source Code for errors using cppcheck
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2011 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
if ! cppcheck_loc="$(type -p "cppcheck")" || [ -z "$cppcheck_loc" ]; then
|
||||
# install cppcheck
|
||||
echo "CPPCHECK is not installed, installing now..."
|
||||
sudo apt install cppcheck
|
||||
fi
|
||||
|
||||
# (Actual) Location of the cppcheck binary
|
||||
CPPCHECK=$(readlink -f $(which cppcheck))
|
||||
|
||||
# cppcheck now depends on this library (see 'cppcheck --help' for the '--library' option)
|
||||
# If you use the Debian / Ubuntu package set this to: /usr/share/cppcheck/cfg/std.cfg
|
||||
if [ -e "$(dirname $CPPCHECK)/cfg/std.cfg" ]; then
|
||||
CPPCHECKLIB=$(dirname $CPPCHECK)/cfg/std.cfg
|
||||
elif [ -e "/usr/share/cppcheck/cfg/std.cfg" ]; then
|
||||
CPPCHECKLIB=/usr/share/cppcheck/cfg/std.cfg
|
||||
fi
|
||||
|
||||
|
||||
# File to write results to
|
||||
LOGFILE=/tmp/cppcheck.log
|
||||
|
||||
$CPPCHECK ../../source/ \
|
||||
-i ../../source/win32_deps \
|
||||
-i ../../source/configurator \
|
||||
-i ../../source/shared_lib/sources/libircclient \
|
||||
-i ../../source/shared_lib/sources/platform/miniupnpc \
|
||||
-i ../../source/shared_lib/sources/streflop \
|
||||
--library=$CPPCHECKLIB \
|
||||
--enable=all \
|
||||
--force \
|
||||
--verbose \
|
||||
2> $LOGFILE
|
||||
|
||||
echo "Results from cppcheck were written to $LOGFILE"
|
@@ -1,18 +0,0 @@
|
||||
#!/bin/bash
|
||||
# Use this script to gather MegaGlest performance stats
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2012 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
echo 'Recording performnce stats...'
|
||||
|
||||
echo 'cat /proc/sys/kernel/kptr_restrict'
|
||||
echo '1'
|
||||
#echo 'echo 0 > /proc/sys/kernel/kptr_restrict'
|
||||
echo 'sudo sh -c "echo 0 > /proc/sys/kernel/kptr_restrict"'
|
||||
echo 'cat /proc/sys/kernel/kptr_restrict'
|
||||
echo '0'
|
||||
|
||||
perf record ./megaglest $@
|
||||
|
||||
perf report
|
@@ -1,18 +0,0 @@
|
||||
#! /bin/sh
|
||||
# Use this script to track memory use and errors while running MegaGlest
|
||||
# ----------------------------------------------------------------------------
|
||||
# Written by Mark Vejvoda <mark_vejvoda@hotmail.com>
|
||||
# Copyright (c) 2011 Mark Vejvoda under GNU GPL v3.0+
|
||||
|
||||
exec 3>&1
|
||||
export GLIBCPP_FORCE_NEW=1
|
||||
export GLIBCXX_FORCE_NEW=1
|
||||
export G_SLICE=always-malloc
|
||||
|
||||
exec valgrind --num-callers=20 \
|
||||
--leak-check=yes \
|
||||
--leak-resolution=high \
|
||||
--show-reachable=yes \
|
||||
"$@" 2>&1 1>&3 3>&- |
|
||||
sed 's/^==[0-9]*==/==/' >&2 1>&2 3>&-
|
||||
|
Reference in New Issue
Block a user