Add a new cmake option WITH_SYSTEM_TINYXML=ON that allows to use the system
tinyxml library and header instead of the bundled copy. Adjust the include
path in the single source file referencing the header and add the thirdparty
path to the include search path if the use system option is unset or off.
Remove the two dependencies to ::Game from C4MapScript, so that ::Game
does not need to be linked into mape, which would basically drag the
whole rest of the engine after itself.
There's no point in splitting the audio library selection into multiple
CPP macros, since there can always only be one anyway. Merge all of them
into a single macro AUDIO_TK (for "toolkit") and have CMake select one
for the user, instead of making him choose (and potentially failing).
Recent MinGW releases ship a pthread implementation for Windows. So while
CMake is technically correct in finding pthread, we don't want it to, and
instead use the standard Win32 threading.
The -std=gnu++0x-Flag was removed from the compiler flags before
testing the <regex> header, and so just re-confirmed that <regex>
didn't work in previous C++ standards.
f897e95071 broke this by reusing the macro with the path to the binary
as the binary name, which doesn't work if the path contains directories.
Also, 0dcfe72148 moved the binaries, but the LOCATION property still
pointed to the old location. Luckily, CMake also has a non-broken option to
pass target file paths to custom commands.
The distinction between the "aul" and "non-aul" parts of
the script engine are mostly historical accident, and the
current organization of the source code does not use
sub-subdirectories. I'd like to keep it that way.
This reverts commit 69ba06b8d0.
This makes CMake use the dynamic library instead of the static library on
my system. The latter doesn't link on today's Debian unstable due to a
missing libmad.a.
Recent versions of MinGW do no longer declare vasprintf in <stdio.h>,
but they ship a compatible function called __mingw_vasprintf. Use this
function if vasprintf isn't available.
CheckFunctionExists only checks for the function to be linkable, it does
not require any declaration in a header. CheckSymbolExists requires a
declaration and also linking to succeed.