-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Converted project to cmake, making it somewhat portable
- Loading branch information
Showing
10 changed files
with
87 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
cmake_minimum_required(VERSION 3.7 FATAL_ERROR) | ||
|
||
project(GraphicsProject4 VERSION 0.0.1 LANGUAGES CXX) | ||
|
||
find_package (OpenGL REQUIRED) | ||
find_package(GLEW REQUIRED) | ||
find_package(SOIL CONFIG REQUIRED) | ||
find_package(glfw3 REQUIRED) | ||
find_package(glm REQUIRED) | ||
|
||
add_executable(main | ||
|
||
src/TerrainFPS.cpp | ||
src/GridFloatData.cpp | ||
) | ||
|
||
target_link_libraries(main PRIVATE ${OPENGL_LIBRARIES}) | ||
|
||
target_include_directories(main PRIVATE GLEW) | ||
target_link_libraries(main PRIVATE GLEW::GLEW) | ||
|
||
target_link_libraries(main PRIVATE SOIL) | ||
|
||
target_link_libraries(main PUBLIC glm) | ||
|
||
target_include_directories(main PUBLIC glfw) | ||
target_link_libraries(main PRIVATE glfw) | ||
|
||
target_include_directories(main PRIVATE ${CMAKE_SOURCE_DIR}/src) | ||
|
||
add_custom_command(TARGET main POST_BUILD | ||
COMMAND ${CMAKE_COMMAND} -E copy_directory | ||
${PROJECT_SOURCE_DIR}/Resources $<TARGET_FILE_DIR:main>) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{ | ||
"configurations": [ | ||
{ | ||
"name": "x64-Debug", | ||
"generator": "Ninja", | ||
"configurationType": "Debug", | ||
"inheritEnvironments": [ "msvc_x64_x64" ], | ||
"buildRoot": "${env.USERPROFILE}\\CMakeBuilds\\${workspaceHash}\\build\\${name}", | ||
"cmakeCommandArgs": "", | ||
"buildCommandArgs": "-v", | ||
"variables": [ | ||
{ | ||
"name": "CMAKE_TOOLCHAIN_FILE", | ||
"value": "C:/src/vcpkg/scripts/buildsystems/vcpkg.cmake" | ||
} | ||
], | ||
"ctestCommandArgs": "" | ||
}, | ||
{ | ||
"name": "x64-RelWithDebInfo", | ||
"generator": "Ninja", | ||
"configurationType": "RelWithDebInfo", | ||
"inheritEnvironments": [ "msvc_x64_x64" ], | ||
"buildRoot": "${env.USERPROFILE}\\CMakeBuilds\\${workspaceHash}\\build\\${name}", | ||
"cmakeCommandArgs": "", | ||
"buildCommandArgs": "-v", | ||
"variables": [ | ||
{ | ||
"name": "CMAKE_TOOLCHAIN_FILE", | ||
"value": "C:/src/vcpkg/scripts/buildsystems/vcpkg.cmake" | ||
} | ||
], | ||
"ctestCommandArgs": "" | ||
}, | ||
{ | ||
"name": "x64-Release", | ||
"generator": "Ninja", | ||
"configurationType": "Release", | ||
"inheritEnvironments": [ "msvc_x64_x64" ], | ||
"buildRoot": "${env.USERPROFILE}\\CMakeBuilds\\${workspaceHash}\\build\\${name}", | ||
"cmakeCommandArgs": "", | ||
"buildCommandArgs": "-v", | ||
"variables": [ | ||
{ | ||
"name": "CMAKE_TOOLCHAIN_FILE", | ||
"value": "C:/src/vcpkg/scripts/buildsystems/vcpkg.cmake" | ||
} | ||
], | ||
"ctestCommandArgs": "" | ||
} | ||
] | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters