GCC6 doesn't like getting some of its default include search paths
passed with the -isystem flag, and the devs seem unlikely to change
whatever they did back to before they broke it. Work around CMake
not dealing with it well either by figuring out the paths at
configure time and telling CMake about them so it can avoid adding
them superfluously.
MSVC already knows where the Windows SDK is located, so we don't have to
replicate that logic in CMake (then get it wrong and link to an outdated
one).
- The new code works with my router while libupnp didn't. :)
- There are some unexplainable crashes in libupnp: #1640
- Using miniupnpc seems to be less complex than libupnp.
- Apparently, miniupnpc also works on Windows, so we may be able to use
it for all platforms.
Disadvantage: UPnP queries aren't asynchronous anymore, but they seem to
be pretty fast (< 1 s).
Unmodified readline relies on, but doesn't link to, a termcap library.
Several Linux distributions patch this, but others don't; to avoid build
failures, we'll just link to a library that provides termcap symbols
even though we don't use them ourselves. Fixes Github #15.
This was used to name snapshot releases of the Network2 branch, and has
seen almost no use since.
C4ENGINEINFO(LONG) was a duplicate of C4ENGINENAME and C4ENGINECAPTION.
Hardly anyone ever tests the headless build, because it requires you to
run CMake a second time with -DUSE_CONSOLE=On. So now it's an included
project which you'll get whether you want it or not.
I'm well aware that this could be solved more nicely, and that we could
be splitting unchanged files out into a separate support library, but
that's left for a later date.
Nobody uses pkg-config on Windows, and we already have a perfectly
viable solution for finding libraries - it's called CMake. We're still
defering to pkg-config when it exists because who knows what arcane
cflags might be required on some systems.
Not only is FMOD neither free (libre) nor free (gratis), the version we
support(ed) is also impossible to legally obtain anymore. So there's no
reason we should keep code around that (pretends to) support a library
nobody can use or test.
On Windows, we need to know whether the library we're linking against is
a static library or a shared library import stub. If it's a shared lib
(and only then), we need to #define GLEW_STATIC.
Other OSes handle library imports differently and don't care.
* fix the if-conditional
* don't use pkgconfig (there is no .pc file upstream)
Signed-off-by: Julius Michaelis <caesar@hg.openclonk.org>
(Added license to FindTinyXML.cmake)
OpenAL's pkg-config database doesn't list include/AL as a location for
AL headers, but including <AL/al.h> is unusable because some systems
store the headers in OpenAL instead of AL. So check if the file can
actually be found as <al.h> and amend the include directory list
otherwise.
CMake 3.1's if() by default now interprets quoted variable names as
strings. This is a good idea from a strictness perspective, so make it
do this even if we're in 2.8.9 compatibility mode.
Auto-detecting UPnP might fail when CMake was invoked multiple times.
This would result in a broken build because the compiler would not find
<natupnp.h>.
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).
If pkg-config does not exist on the build system, then the old
FindFreetype.cmake behavior will be fallen back upon, but pkg-config
should be a lot more reliable.
As discussed in http://forum.openclonk.org/topic_show.pl?tid=2917, I
have merged all copyright notices into a single file and referenced that
merged file from each source file.
For the updated source files, the timeline has been split into three
parts:
1. Pre-RWD code (before 2001)
2. RWD code (2001 through 2009)
3. OpenClonk code (2009 and later)
All pre-RWD copyright notices have been left intact, as have RWD-era
copyright notices where the file did not have a RedWolf design copyright
notice but only individual author ones. All copyright notices of the
OpenClonk era have been replaced by a single notice ranging from the
first recorded year to the current year (2013). Mape code did not get a
OpenClonk Team copyright notice because it is somewhat separate from the
main OpenClonk codebase and has only been touched by Armin Burgmeier.