T
twostars
mingw support (#802)
Allow for compiling with mingw, and for cross-compilation support via the included docker container for convenience.
As mingw uses gcc, some changes to the client's codebase were required to fix compilation there, as it's a little more strict than MSVC. This should reduce the potential changes for when we actually support compilation with gcc down the track.
Some changes were also made to timeout checks on thread ticks; with mingw's implementation (not sure if this extends to gcc), threads were often unable to timeout due to spurious wakeups interrupting them frequently enough that an entire timeout could never complete.
We also make sure to only build N3Base_client with OPENKO_BUILD_CLIENT enabled, and N3Base_tool with OPENKO_BUILD_TOOLS, rather than having them both built when either is specified. This is because it doesn't support MFC, so we cannot build tools with mingw -- only the client.
Finally, @kenner2 adds a Docker container to make cross-compilation simple, though this will probably just be removed again later.
* Support building with mingw
This mostly covers our bases, just leaving libjpeg-turbo as the perpetual issue that it is, and more than likely still requiring some build-related config to ensure everything is statically linked still (aside from DX9).
* Import DX9 libs as needed
* Statically link to everything for consistency across projects.
* feat: Utility to cross-compile and run client in Linux (#797)
* Only build N3Base_client or N3Base_tool if we're building the client or tools respectively
Before we built both regardless, if we were building either.
* More robustly detect & ignore spurious thread wakeups
* Add algorithm import for std::clamp support
---------
Co-authored-by: Ken R. <13474249+kenner2@users.noreply.github.com>
Github Commit Görüntüle...
See Commints...
..
Allow for compiling with mingw, and for cross-compilation support via the included docker container for convenience.
As mingw uses gcc, some changes to the client's codebase were required to fix compilation there, as it's a little more strict than MSVC. This should reduce the potential changes for when we actually support compilation with gcc down the track.
Some changes were also made to timeout checks on thread ticks; with mingw's implementation (not sure if this extends to gcc), threads were often unable to timeout due to spurious wakeups interrupting them frequently enough that an entire timeout could never complete.
We also make sure to only build N3Base_client with OPENKO_BUILD_CLIENT enabled, and N3Base_tool with OPENKO_BUILD_TOOLS, rather than having them both built when either is specified. This is because it doesn't support MFC, so we cannot build tools with mingw -- only the client.
Finally, @kenner2 adds a Docker container to make cross-compilation simple, though this will probably just be removed again later.
* Support building with mingw
This mostly covers our bases, just leaving libjpeg-turbo as the perpetual issue that it is, and more than likely still requiring some build-related config to ensure everything is statically linked still (aside from DX9).
* Import DX9 libs as needed
* Statically link to everything for consistency across projects.
* feat: Utility to cross-compile and run client in Linux (#797)
* Only build N3Base_client or N3Base_tool if we're building the client or tools respectively
Before we built both regardless, if we were building either.
* More robustly detect & ignore spurious thread wakeups
* Add algorithm import for std::clamp support
---------
Co-authored-by: Ken R. <13474249+kenner2@users.noreply.github.com>
Github Commit Görüntüle...
See Commints...
..