Skip to content

Commit

Permalink
Remove the .bat files, explain how to use directly mith CMake instead.
Browse files Browse the repository at this point in the history
  • Loading branch information
ennorehling committed Nov 27, 2021
1 parent 929d18f commit 37f3530
Show file tree
Hide file tree
Showing 7 changed files with 65 additions and 87 deletions.
70 changes: 65 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# What is this?
# Eressea PBEM Server

This repository contains the source code for the Play-by-Mail
strategy game [Eressea](http://www.eressea.de/).

# Prerequisites
## Prerequisites

Eressea depends on a number of external libraries. On a recent
Debian-based Linux system, this is the apt-get command to
Expand All @@ -13,11 +13,10 @@ install all of them:
liblua5.2-dev libtolua-dev libncurses5-dev libsqlite3-dev \
libcjson-dev libiniparser-dev libexpat1-dev

# How to check out and build the Eressea server
## How to check out and build the Eressea server

This repository relies heavily on the use of submodules, and it pulls in
most of the code from those. The build system being used is cmake, which
can create Makefiles on Unix, or Visual Studio project files on Windows.
most of the code from those. The build system being used is CMake.
Here's how you clone and build the source on Linux or macOS:

git clone --recursive git://github.com/eressea/server.git source
Expand All @@ -31,3 +30,64 @@ it will have passed some basic functionality tests.
* [![Static Analysis](https://scan.coverity.com/projects/6742/badge.svg?flat=1)](https://scan.coverity.com/projects/6742/)
* [![Build Status](https://api.travis-ci.org/eressea/server.svg?branch=develop)](https://travis-ci.org/eressea/server)
* [![License: CC BY-NC-SA 4.0](https://licensebuttons.net/l/by-nc-sa/4.0/80x15.png)](http://creativecommons.org/licenses/by-nc-sa/4.0/)

## Building on Windows

To build on Windows, first install Visual Studio and VCPKG: https://github.com/microsoft/vcpkg#quick-start-windows
Set an environment variable named VCPKG_ROOT to the directory where you installed VCPKG globally, e.g. C:\VCPKG
Now, install the required packages:
```
VCPKG.EXE install sqlite3 expat pdcurses cjson iniparser tolua
VCPKG.EXE integrate install
```

Using luarocks, install the lunitx module (this can be complicated).

In Visual Studio, clone the reportitory from github, or if you've already done
that, choose File -> Open -> CMake and pick the CMakeLists.txt file in the root
of the repository. Build the project.

Select eressea.exe as the Stratup Item, then open the launch.vs.json file by
choosing Debug -> "Debug and Launch Settings for eressea.exe".

Here, add your data the directory in "currentDir", and command line arguments
in "args". On my own computer, the configuration looks like this:
```
{
"version": "0.2.1",
"defaults": {},
"configurations": [
{
"type": "default",
"project": "CMakeLists.txt",
"projectTarget": "eressea.exe",
"args": [
"-w0",
"-t1242",
"-v1",
"-D",
"${workspaceRoot}\\scripts\\run-turn.lua"
],
"currentDir": "${env.ERESSEA_ROOT}",
"env": {
"ERESSEA_ROOT": "${workspaceRoot}",
"LUA_PATH": "${workspaceRoot}\\scripts\\?.lua;${env.LUA_PATH}"
},
"name": "eressea.exe"
},
{
"type": "default",
"project": "CMakeLists.txt",
"projectTarget": "test_eressea.exe",
"name": "test_eressea.exe"
}
]
}
```

Note that I have an environment variable for my game directory called ERESSEA_ROOT. My LUA_PATH also contains the luarocks installation.

```
LUA_PATH=C:\Users\Enno\AppData\Roaming\Luarocks\share\lua\5.4\?.lua
ERESSEA_ROOT C:\Users\Enno\Documents\Eressea\test
```
9 changes: 0 additions & 9 deletions vs2010-build.bat

This file was deleted.

9 changes: 0 additions & 9 deletions vs2012-build.bat

This file was deleted.

11 changes: 0 additions & 11 deletions vs2013-build.bat

This file was deleted.

15 changes: 0 additions & 15 deletions vs2015-build.bat

This file was deleted.

19 changes: 0 additions & 19 deletions vs2017-build.bat

This file was deleted.

19 changes: 0 additions & 19 deletions vs2019-build.bat

This file was deleted.

0 comments on commit 37f3530

Please sign in to comment.