diff options
author | Mateja <mail@matejamaric.com> | 2021-02-19 20:40:55 +0100 |
---|---|---|
committer | Mateja <mail@matejamaric.com> | 2021-02-19 20:40:55 +0100 |
commit | b46c409749b7263492bca824c68eb58600d06841 (patch) | |
tree | 5cfec3697a1e5e1bf767fe4014d20c7aa2640b3d | |
parent | f63f623987612d48b0d5557ad7a4117787444ee4 (diff) | |
download | erender-b46c409749b7263492bca824c68eb58600d06841.tar.gz erender-b46c409749b7263492bca824c68eb58600d06841.zip |
CMake TARGET_FILE_DIR fix.
On Visual Studio `model` directory wasn't copied to build directory.
This commit fixes that.
-rw-r--r-- | CMakeLists.txt | 2 | ||||
-rw-r--r-- | README.md | 1 |
2 files changed, 1 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 39ff383..e8e8210 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -42,4 +42,4 @@ add_custom_command( TARGET ${PROJECT_NAME} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/model - ${CMAKE_CURRENT_BINARY_DIR}/model) + $<TARGET_FILE_DIR:${PROJECT_NAME}>/model) @@ -31,4 +31,3 @@ Then run following commands in project directory: ### On Windows and Mac: On Windows and Mac you don't have any dependencies, so you can use CMake without any worry. -**Just make sure `model` directory (where example model is located) is available where you built the executable.** |