* CMake: 3rdParty/zlib fixes
1. zlib already provides a CMakeLists.txt, use it.
2. Stub find_package for source build. ZLIB is used by libpng via `find_package(ZLIB)`.
3. amiga.cmake: Remove `find_package(ZLIB)`.
* Update UWP build directory for zlibstatic.lib
Co-authored-by: staphen <staphen@gmail.com>
1. Adds a `libdevilution_so` target when tests are enabled.
2. Each test file is now a separate binary target linked against `libdevilutionx_so` (can now run tests in parallel).
3. Tests are now defined in a separate `test/CMakeLists.txt` file.
4. Building the tests is now controlled by the standard `BUILD_TESTING` option (defined by CTest).
5. Tests are now built by default.
6. On CI, test errors are now reported.
Also:
* `.clang-format`: Enable SortIncludes in tests
* `path_test.cpp`: Fix -Wsign-compare
1. Run Docker as the current user instead of root,
removing the need to chown directories.
2. Copy `devilutionx.info` via CMake, removing the need to do it
manually.
3. Cleanup `prep.sh` somewhat.
1. Platform and toolchain files are now all under `platforms/`, with a
single `CMake/platforms/${platform}.cmake` per platform.
2. Custom functions/macros are under `functions/`.
3. Finder modules are in `/finders`.
libmpq is a much simpler alternative to StormLib for reading MPQ archives.
We use our own fork of libmpq: https://github.com/diasurgical/libmpq
Impact:
* DevilutionX is now a lot more portable. Unlike StormLib, libmpq only
needs platform-specific code for Windows.
* Locks around file access **removed** (instead we duplicate the file descriptor for streamed audio only).
* RAM usage is **300 KiB** lower than StormLib.
* Stripped release linux_x86_64 binary is **32 KiB** smaller.
* Amiga build now hangs instead of crashing.
* Adding top-level CPACK option
* Setting CMAKE_BUILD_TYPE should always be Cache variables
This initializes CMAKE_CXX_FLAGS_RELEASE during project() correctly. With out
this, changes to CMakeLists.txt may result in a complete rebuild because
CMAKE_BUILD_TYPE wasn't in the cache before, and wasn't respected by project(),
but now it is.
https://cmake.org/pipermail/cmake/2008-September/023808.html
* Always build deb and rpm packages where possible
* Searching for .ttf instead of hard-coding it's full path