OSX build was a bit broken, it needs to be linked against zlib.
Furthermore it now uses the systems libSDL2 framework, unless you use
-DUSE_SYSTEM_SDL2=FALSE
i386 ASM is now disabled by default, we have plain C fallbacks for
everything that seems to work well enough (and if not they need more
testing which is likely to happen this way)
ssam expects lib* to be in the Debug subdir, so make cmake put it there,
this way it's easier to copy the binaries to your install/Bin/ dir to
test.
clang gives a lot of -Wlogical-op-parentheses warnings, suppress them.
Set the ENABLE_EXPORTS property on the main executables, which adds
linker flag -rdynamic if the compiler supports it. This ensures symbols
are available for dynamic objects (such as shared libEntitiesMPD.so) to
use.
- Detect FreeBSD.
- Set both PLATFORM_UNIX and PLATFORM_FREEBSD. The latter is required to
distinguish FreeBSD from other unixoid platforms like Linux.
- On FreeBSD 3rd party libs are installed to /usr/local, we need to add
/usr/local/include as include directory.
- Add linker options for FreeBSD. FreeBSD has no -ldl.
CMakeLists.txt: Modified to link system wide SDL2 libraries and link to
system wide headers
SplashScreen.cpp: commented out as its post SDL2.0.4 >> SDL_WINDOW_SKIP_TASKBAR
This help cross-compilation. You can do something like this now, to get a
native ECC that runs on the build machine, then build the rest for the
cross-compile target system:
rm -rf cmake-build-ecc
mkdir $_
cd $_
cmake ..
make ecc
cd ..
rm -rf cmake-build
mkdir $_
cd $_
cmake -DECC=/wherever/SeriousEngine/Sources/cmake-build-ecc/ecc ..
make
* Only use ENOSR and ENOPKG if defined
ENOSR and ENOPKG are part of the POSIX optional STREAMS extension, and
are not available on most other platforms than GNU/Linux.
* Support building on other GNU platforms than Linux
Build for other GNU platforms the same way as Linux: this includes
CMAKE_SYSTEM_NAME "GNU" (GNU/Hurd) and "GNU/kFreeBSD" (GNU/kFreeBSD).
and added to the target_link_libraries for SeriousSam and SeriousSamDedicated. I don't know not linking the SDL library was
the intended outcome but SeriousSam* was failing to link to libSeriousEngine.a.
(The EntitiesMP and/or GameMP libraries need symbols exported from the main
binary, but when we built the engine as a static library to reuse it between
the client and server, the Linux linker stripped out symbols those libraries
needed. If we can force these symbols to remain, or maybe move to shared
library..? then we can avoid building the engine sources twice to get the
dedicated server too. For now, though...good enough!)