-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of github.com:eressea/server
- Loading branch information
Showing
350 changed files
with
8,433 additions
and
6,784 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# -*- cmake -*- | ||
|
||
# - Find BerkeleyDB | ||
# Find the BerkeleyDB includes and library | ||
# This module defines | ||
# DB_INCLUDE_DIR, where to find db.h, etc. | ||
# DB_LIBRARIES, the libraries needed to use BerkeleyDB. | ||
# DB_FOUND, If false, do not try to use BerkeleyDB. | ||
# also defined, but not for general use are | ||
# DB_LIBRARY, where to find the BerkeleyDB library. | ||
|
||
FIND_PATH(DB_INCLUDE_DIR db.h | ||
/usr/local/include/db4 | ||
/usr/local/include | ||
/usr/include/db4 | ||
/usr/include | ||
) | ||
|
||
SET(DB_NAMES ${DB_NAMES} db) | ||
FIND_LIBRARY(DB_LIBRARY | ||
NAMES ${DB_NAMES} | ||
PATHS /usr/lib /usr/local/lib | ||
) | ||
|
||
IF (DB_LIBRARY AND DB_INCLUDE_DIR) | ||
SET(DB_LIBRARIES ${DB_LIBRARY}) | ||
SET(DB_FOUND "YES") | ||
ELSE (DB_LIBRARY AND DB_INCLUDE_DIR) | ||
SET(DB_FOUND "NO") | ||
ENDIF (DB_LIBRARY AND DB_INCLUDE_DIR) | ||
|
||
|
||
IF (DB_FOUND) | ||
IF (NOT DB_FIND_QUIETLY) | ||
MESSAGE(STATUS "Found BerkeleyDB: ${DB_LIBRARIES}") | ||
ENDIF (NOT DB_FIND_QUIETLY) | ||
ELSE (DB_FOUND) | ||
IF (DB_FIND_REQUIRED) | ||
MESSAGE(FATAL_ERROR "Could not find BerkeleyDB library") | ||
ENDIF (DB_FIND_REQUIRED) | ||
ENDIF (DB_FOUND) | ||
|
||
# Deprecated declarations. | ||
SET (NATIVE_DB_INCLUDE_PATH ${DB_INCLUDE_DIR} ) | ||
GET_FILENAME_COMPONENT (NATIVE_DB_LIB_PATH ${DB_LIBRARY} PATH) | ||
|
||
MARK_AS_ADVANCED( | ||
DB_LIBRARY | ||
DB_INCLUDE_DIR | ||
) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# Locate PDCurses library | ||
# This module defines | ||
# PDCURSES_LIBRARIES, the name of the library to link against | ||
# PDCURSES_FOUND, if false, do not try to link to PDCurses | ||
# PDCURSES_INCLUDE_DIR, where to find curses.h | ||
|
||
FIND_PATH(PDCURSES_INCLUDE_DIR curses.h | ||
HINTS | ||
$ENV{PDCURSESDIR} | ||
PATH_SUFFIXES include/pdcurses include) | ||
|
||
FIND_LIBRARY(PDCURSES_LIBRARY | ||
NAMES pdcurses | ||
HINTS | ||
$ENV{PDCURSESDIR} | ||
PATH_SUFFIXES lib64 lib) | ||
|
||
FIND_LIBRARY(PDCURSES_PANEL_LIBRARY | ||
NAMES panel | ||
HINTS | ||
$ENV{PDCURSESDIR} | ||
PATH_SUFFIXES lib64 lib) | ||
|
||
IF(PDCURSES_LIBRARY) | ||
SET(PDCURSES_LIBRARIES ${PDCURSES_LIBRARY}) | ||
IF(PDCURSES_PANEL_LIBRARY) | ||
SET(PDCURSES_LIBRARIES ${PDCURSES_LIBRARIES} ${PDCURSES_PANEL_LIBRARY}) | ||
ENDIF(PDCURSES_PANEL_LIBRARY) | ||
ENDIF(PDCURSES_LIBRARY) | ||
|
||
SET(PDCURSES_FOUND "NO") | ||
IF(PDCURSES_INCLUDE_DIR AND PDCURSES_LIBRARY) | ||
# message(STATUS "Found PDCurses library: ${PDCURSES_LIBRARIES}") | ||
# Set the final string here so the GUI reflects the final state. | ||
SET(PDCURSES_LIBRARIES PDCURSES_LIBRARY} CACHE STRING "Where the PDCurses Library can be found") | ||
|
||
SET(PDCURSES_FOUND "YES") | ||
ENDIF(PDCURSES_INCLUDE_DIR AND PDCURSES_LIBRARY) |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
SCRIPTS=compress.sh send-bz2-report send-zip-report create-orders \ | ||
run-turn sendreports.sh | ||
IGNORE=sendreport.sh | ||
|
||
shellcheck: $(SCRIPTS) | ||
shellcheck $(SCRIPTS) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,25 @@ | ||
#!/bin/bash | ||
|
||
if [ -z $ERESSEA ]; then | ||
if [ -z "$ERESSEA" ]; then | ||
echo "You need to define the \$ERESSEA environment variable to run $0" | ||
exit -2 | ||
fi | ||
|
||
GAME=$ERESSEA/game-$1 | ||
GAME_NAME=$(grep -w name $GAME/eressea.ini | sed 's/.*=\s*//') | ||
GAME="$ERESSEA/game-$1" | ||
GAME_NAME=$(grep -w name "$GAME/eressea.ini" | sed 's/.*=\s*//') | ||
|
||
TURN=$2 | ||
if [ -z $TURN ] | ||
if [ -z "$TURN" ] | ||
then | ||
TURN=`cat $GAME/turn` | ||
TURN=$(cat "$GAME/turn") | ||
fi | ||
|
||
if [ ! -d $GAME/reports ]; then | ||
if [ ! -d "$GAME/reports" ]; then | ||
echo "cannot find reports directory in $GAME" | ||
exit -1 | ||
fi | ||
|
||
cd $GAME/reports | ||
$ERESSEA/server/bin/compress.py $TURN "$GAME_NAME" | ||
cd - | ||
cd "$GAME/reports" || exit | ||
"$ERESSEA/server/bin/compress.py" "$TURN" "$GAME_NAME" | ||
cd - || exit | ||
|
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
#!/bin/sh | ||
|
||
GAME=$1 | ||
TURN=$2 | ||
GAME="$1" | ||
TURN="$2" | ||
|
||
if [ ! -d $ERESSEA/game-$GAME ] ; then | ||
if [ ! -d "$ERESSEA/game-$GAME" ] ; then | ||
echo "No such game: $GAME" | ||
exit 1 | ||
fi | ||
|
||
cd $ERESSEA/game-$GAME | ||
cd "$ERESSEA/game-$GAME" || exit | ||
|
||
echo "running turn $TURN, game $GAME" | ||
$ERESSEA/server/bin/eressea -t $TURN run-turn.lua | ||
"$ERESSEA/server/bin/eressea" -t "$TURN" run-turn.lua | ||
mkdir -p log | ||
ln -f eressea.log log/eressea.log.$TURN | ||
ln -f eressea.log "log/eressea.log.$TURN" | ||
|
This file contains 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
Oops, something went wrong.