Now there are:
- dependencies-vs
- dependencies-vs-64bit
- dependencies-mingw
- dependencies-mingw64
And if it's not found, then fallback to:
- dependencies
- dependencies-64bit
So that if you use only one compiler, then you can just still use "dependencies" or "dependencies-64bit".
And I didn't restrict it to WIN32 only, because in theory it should be possible to put there openglrecorder for linux build.
Atm. use it only on linux, because there is no need to spam with cmake warnings on other platforms.
Also fallback to built-in enet if system enet is not found.
It's not 100% ready yet, but some testing won't hurt.
It's possible to switch between wayland/x11 using
export IRR_DEVICE_TYPE=x11
or
export IRR_DEVICE_TYPE=wayland
so that x11 device can be forced in wayland session.
The option is enabled by default, but the system version will only be used
if found and newer than 2.0.0 (to ensure that https://sourceforge.net/p/glew/patches/40/
is fixed). When missing, we silently fallback to the vendored source code,
so there is no change for e.g. Windows compilation.
It's possible that STK was using these files for compilation when cmake was run from main directory. In this case compiled files are stored in stk-code/lib, so that CMAKE_CURRENT_BINARY_DIR is stk-code/lib/irrlicht rather than stk-code/build/lib/irrlicht and we include whole lib/libpng rather than non-existing directory.
It should be possible to simplify it with something like
find_library(CURL_LIBRARIES NAMES libcurl libcurldll PATHS "${PROJECT_SOURCE_DIR}/dependencies/lib")
so you can look if it works on Visual Studio.
And as far as I see pkgconfig is used only on unix. Btw. I'm also not sure if it should be if(UNIX AND NOT APPLE) ?