tmxlite
tmxlite copied to clipboard
Compile Using MinGW
How to compile Using MinGW ?
use the cmake file with the generator set to MinGW-make, then make as usual
https://cmake.org/cmake/help/v3.1/manual/cmake-generators.7.html
you mean using this command "cmake .. -G MinGW Makefiles"?
i got this error:
CMake Error at CMakeLists.txt:44 (add_library): Cannot find source file:
WIN32
Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp .hxx .in .txx
CMake Error: CMake can not determine linker language for target: tmxlite CMake Error: Cannot determine link language for target "tmxlite".
thanks
the following works for me:
make sure you have the following directories in your system path variable - adjust to your existing folder names, which mustn't include white spaces - for me it is:
-C:\projects\cmake\bin -C:\mingw\mingw32\bin (and, optional) -C:\projects\sdk\tools -C:\projects\sdk\platform-tools -C:\projects\sdk -C:\projects\ndk
open cmd as admin cd to your tmxlite project dir (NOT into src but one above)
mkdir build && cd build
mkdir armeabi-v7a && cd armeabi-v7a
(replace armeabi-v7 with other architecture as needed)
for android build: copy/integrate the whole "cmake" directory of SFML sources into your tmxlite project dir's cmake folder (or otherwise reference to a working/valid cmake toolchain file)
then (for example)
cmake -G "MinGW Makefiles" -DANDROID_ABI=armeabi-v7a -DANDROID_TOOLCHAIN_NAME=arm-linux-androideabi-4.9 -DANDROID_NATIVE_API_LEVEL=21 -DCMAKE_TOOLCHAIN_FILE=cmake/toolchains/android.toolchain.cmake ../..
and
mingw32-make clean && mingw32-make install
Edit: note the quotation marks around "MinGW Makefiles", also it is case sensitive