Commit graph

8 commits

Author SHA1 Message Date
cbnolok
eae1a45276 Formatted cmake files with gersemi. 2024-09-08 14:33:56 +02:00
cbnolok
4ea4325320 Fixed script parsing regression with empty strings, fixed undefined behaviors 2024-08-06 09:56:32 +02:00
cbnolok
75a07b4498 Several stability fixes
- Fixed: ini CommandPrefix being overwritten by data from other ini settings.
- Fixed: function call stack sometimes being subject to a race condition between two writing threads, corrupting it.
- Fixed: lots of memory corruption errors leaving the server unstable when loading a broken save file and recovering by loading a backup save.
- Fixed: CCacheableScriptFile sometimes not reading the last character.
- Fixed: .clang_format.
- Changed: RES_GET_INDEX macro to ResGetIndex function, allowing more integer type safety. Same for RES_GET_TYPE.
- Changed: Renamed THREAD_* macros to MT_*. Split them in always active macros (MT_*) and macros active only when MT_ENGINE is set to 1 (MT_ENGINE_*). There are some situations where we still need a mutex
even if not working with multithreaded script/networking engines (which are NOT complete).
- Changed: Disable signal handlers under Linux if running with ASAN or a debugger.
- Added: NOEXCEPT_DEBUG, it's simply the noexcept specifier, but it's ignored if running in a debug build (useful if we're using DEBUG_ASSERT inside a function which wouldn't otherwise throw an exception).
- Fixed: some undefined behaviors, like signed to unsigned conversion and vice versa.
- Added: additional checks for GCC and Clang ASAN builds.
2024-08-06 09:56:32 +02:00
cbnolok
d04dc35bd3 Updated phmap lib, fixed osx-arm64 executable name, removed _32/64BITS macro references, added llvm symbolizer path to windows clang util bat. 2024-05-27 19:12:00 +02:00
cbnolok
84888279c9 Updated toolchains to set options per target, instead of globally.
Windows and OS X not yet tested.
Moved toolchains .inc files to include/ folder.
Renamed folder lib/bin into _bin.
Moved bcrypt and twofish library into lib folder and into new cmake projects. Restored twofish library to the original version.


Fixed some format warnings.
2024-05-19 14:04:53 +02:00
cbnolok
4533f80f4c Moved each third-party library to a separate CMake project
This will allow setting per-project (build) settings and to build/link
Sphere using system-provided library source/headers/precompiled lib
(like the ones provided with -devel packages on Linux) instead of the
ones shipped with the projects.
This is also a necessary step to use git submodules.
2024-05-17 11:10:17 +02:00
cbnolok
4105d3b45e Updated parallel_hashmap external library, improved compiler flags for builds using sanitizers. 2023-10-07 19:58:49 +02:00
cbnolok
572e3f39fc Moved CMakeLists.txt from /src/ to the project root dir. WARNING: you will need to change the source directory in CMake!
Refactored 3rd party libraries folders, moving both source and binaries to /lib/.
Refactored CMakeLists.txt
Abandoned old MySQL C Connector in favor of MariaDB C Connector, which supports all MariaDB versions and MySQL 5.x and 8.x.
Windows: abandoned MySQL libmysql.dll. Now using MariaDB libmysql.dll (compatible with MySQL until 5.x) for x86 builds and libmariadb.dll for x86_64 builds, which supports MariaDB and MySQL versions above.
Switching from Make to Ninja for automatic Linux builds.
2023-04-27 20:54:45 +02:00