Skip to content

Commit c84df0d

Browse files
KimLSKimLS
andauthored
Build Improvements (EQEmu#5033)
* Start rewrite, add vcpkg * Simple vcpkg manifest, will almost certainly need tweaking * Remove cmake ext we wont be using anymore * Update vcpkg to no longer be from 2022, update cmake lists (wip) * Add finds to the toplevel cmakelists * WIP, luabind and perlbind build. Common only partially builds. * Fix common build. * shared_memory compiles * client files compile * Tests and more cmake version updates * World, had to swap out zlib-ng for now because it wasn't playing nicely along side the zlib install. May revisit. * UCS compiles now too! * queryserv and eqlaunch * loginserver works * Zone works but is messy, tomorrow futher cleanup! * Cleanup main file * remove old zlibng, remove perlwrap, remove hc * More cleanup * vcpkg baseline set for CI * Remove pkg-config, it's the suggested way to use luajit with vcpkg but it causes issues with CI and might be a pain point for windows users * Actually add file * Set perlbind include dir * Perl link got lost * PERL_SET_INTERP causes an issue on newer versions of perl on windows because a symbol is not properly exported in their API, change the lines so it's basically what it used to be * Remove static unix linking, we dont do automated released anymore and this was tightly coupled to that. Can explore this again if we decide to change that. * Remove unused submodules, set cmake policy for boost * Fix some cereal includes * Improve some boilerplate, I'd still like to do better about getting linker stuff set. * Going through and cleaning up the build. * Fix world, separate out data_buckets. * add fixes for other servers * fix zone * Fix client files, loginserver and tests * Newer versions of libmariadb default to tls forced on, return to the default of not forcing that. auto_login were breaking on linux builds loginserver wasn't setting proper openssl compile flag * Move set out of a giant cpp file include. * Convert show * convert find * Add uuid to unix builds * Remove some cpp includes. * Restructure to remove more things. * change db update manifest to header change build yml * Move world CLI include cpps to cmake. * Move zone cli out of source and into cmake * Sidecar stuff wont directly include cpp files now too. * Fix uuid-dev missing on linux runner * Reorg common cmake file * Some cleanup * Fix libsodium support (oops). Fix perl support (more oops) * Change doc --------- Co-authored-by: KimLS <KimLS@peqtgc.com>
1 parent 9b3f9f3 commit c84df0d

File tree

510 files changed

+1518
-46461
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

510 files changed

+1518
-46461
lines changed

.github/workflows/build.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
- name: Install dependencies
2424
run: |
2525
sudo apt-get update
26-
sudo apt-get install -y build-essential ninja-build ccache libmariadb-dev libmariadb-dev-compat libboost-all-dev libperl-dev liblua5.1-0-dev libluajit-5.1-dev zlib1g-dev uuid-dev libssl-dev libsodium-dev libmbedtls-dev
26+
sudo apt-get install -y build-essential ninja-build ccache uuid-dev
2727
2828
- name: Configure
2929
run: |

.gitmodules

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,6 @@
1-
[submodule "submodules/glm"]
2-
path = submodules/glm
3-
url = https://github.com/g-truc/glm.git
4-
[submodule "submodules/fmt"]
5-
path = submodules/fmt
6-
url = https://github.com/fmtlib/fmt.git
7-
[submodule "submodules/libuv"]
8-
path = submodules/libuv
9-
url = https://github.com/libuv/libuv.git
10-
[submodule "submodules/cereal"]
11-
path = submodules/cereal
12-
url = https://github.com/USCiLab/cereal.git
131
[submodule "submodules/websocketpp"]
142
path = submodules/websocketpp
153
url = https://github.com/zaphoyd/websocketpp.git
16-
[submodule "submodules/recastnavigation"]
17-
path = submodules/recastnavigation
18-
url = https://github.com/EQEmu/recastnavigation.git
4+
[submodule "submodules/vcpkg"]
5+
path = submodules/vcpkg
6+
url = https://github.com/microsoft/vcpkg.git

BUILD.md

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,46 +4,35 @@ This guide is far from exhaustive, you should expect to have some experience wit
44

55
### CMake
66

7-
EQEmu uses CMake as the build system on all platforms. You will need CMake 3.2 or higher to build from source.
7+
EQEmu uses CMake as the build system on all platforms. You will need CMake 3.20 or higher to build from source.
88

99
### Dependencies
1010

1111
The following libraries are required to build from source:
12-
- [boost](https://www.boost.org/ "boost")
13-
- [zlib](https://www.zlib.net/ "zlib") (If not included the source will build [zlib-ng](https://github.com/zlib-ng/zlib-ng "zlib-ng") instead)
14-
- [libmysql](https://dev.mysql.com/downloads/connector/c/ "libmysql") or [libmariadb](https://github.com/MariaDB/mariadb-connector-c "libmariadb")
12+
- uuid (unix)
1513

1614
The following libraries are not strictly required but in many cased recommended.
17-
- [OpenSSL](https://www.openssl.org/ "OpenSSL") or [mbedTLS](https://tls.mbed.org/ "mbedTLS") (Required for the loginserver and headless client)
18-
- [libsodium](https://github.com/jedisct1/libsodium "libsodium") (Required for strong password hashing on the loginserver)
19-
- [Lua 5.1](https://www.lua.org/ "Lua 5.1") or [LuaJit](http://luajit.org/ "LuaJit") (Required for Lua Quest Scripting)
2015
- [Perl](https://www.perl.org/ "Perl") (Required for Perl Quest Scripting)
2116

2217
##### Windows
23-
For windows it is suggested you make use of [vcpkg](https://github.com/microsoft/vcpkg "vcpkg") if you wish to build your own dependencies.
24-
2518
If you wish to use Perl then you should use whichever version of Perl you have installed on the target system.
2619

27-
You can also download a vcpkg export from our releases section for Visual Studio [x86](https://github.com/EQEmu/Server/releases/download/v1.2/vcpkg-export-x86.zip "x86") or [x64](https://github.com/EQEmu/Server/releases/download/v1.2/vcpkg-export-x64.zip "x64") that includes a toolchain file you can pass to CMake.
28-
2920
##### Linux
3021
For Linux you simply can install the dependencies from your package manager, below is an example of doing it on Ubuntu using apt-get.
3122

32-
sudo apt-get install libmysqlclient-dev libperl-dev libboost-dev liblua5.1-0-dev zlib1g-dev uuid-dev libssl-dev
23+
sudo apt-get install libperl-dev uuid-dev
3324

3425
### Running CMake
3526

3627
##### Windows
3728
The following is a modified command our automated build server uses to run CMake via the release vcpkg export and its toolchain file.
3829

39-
Assuming it is starting in c:/projects/eqemu and the x64 dependencies were extracted to c:/projects/eqemu/vcpkg.
40-
4130
mkdir build
4231
cd build
43-
cmake -G "Visual Studio 15 2017 Win64" -DEQEMU_BUILD_TESTS=ON -DEQEMU_BUILD_LOGIN=ON -DEQEMU_BUILD_ZLIB=ON -DCMAKE_TOOLCHAIN_FILE="c:/projects/eqemu/vcpkg/vcpkg-export-20180828-145455/scripts/buildsystems/vcpkg.cmake" ..
32+
cmake -G "Visual Studio 15 2022 Win64" -DEQEMU_BUILD_TESTS=ON -DEQEMU_BUILD_LOGIN=ON ..
4433

4534
##### Linux
46-
Similarly to Windows running CMake on Linux is simple it just omits the toolchain file and uses a different generator.
35+
Similarly to Windows running CMake on Linux is simple it just uses a different generator.
4736

4837
mkdir build
4938
cd build

0 commit comments

Comments
 (0)