Jakob Botsch Nielsen c2d7463a38 Add Clang to Travis and treat warnings as errors
The GCC version used by Travis is old and appears not to support all the
warnings we would like to get, so reenable Clang. Additionally make lots
of cleanups to Travis config and make the build a lot faster too.

Also change both Travis and AppVeyor builds to treat warnings as errors,
and include VS2017 in the matrix for AppVeyor. I have also removed
VS2010 because it is ancient at this point.

Updated Premake to alpha12 and fixed the premake build file
appropriately.
2018-06-16 17:04:54 +02:00

28 lines
1.1 KiB
CMake

file(GLOB SOURCES Source/*.cpp Contrib/fastlz/fastlz.c)
LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
find_package(OpenGL REQUIRED)
find_package(SDL2 REQUIRED)
include_directories(SYSTEM ${OPENGL_INCLUDE_DIR})
include_directories(SYSTEM ${SDL2_INCLUDE_DIR})
include_directories(SYSTEM Contrib/fastlz)
include_directories(SYSTEM Contrib)
include_directories(../DebugUtils/Include)
include_directories(../Detour/Include)
include_directories(../DetourCrowd/Include)
include_directories(../DetourTileCache/Include)
include_directories(../Recast/Include)
include_directories(Include)
add_executable(RecastDemo ${SOURCES})
file(COPY Bin/Meshes DESTINATION ${CMAKE_BINARY_DIR}/RecastDemo)
file(COPY Bin/TestCases DESTINATION ${CMAKE_BINARY_DIR}/RecastDemo)
file(COPY Bin/DroidSans.ttf DESTINATION ${CMAKE_BINARY_DIR}/RecastDemo)
add_dependencies(RecastDemo DebugUtils Detour DetourCrowd DetourTileCache Recast)
target_link_libraries(RecastDemo ${OPENGL_LIBRARIES} ${SDL2_LIBRARY} DebugUtils Detour DetourCrowd DetourTileCache Recast)
install(TARGETS RecastDemo RUNTIME DESTINATION bin)