From 7e216bcb0c31df1a1af015e7f8b620117829b64a Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Fri, 19 Jun 2015 21:33:29 -0700 Subject: [PATCH] Allow printing and HTML export to work when running from build directory Yet more things that wouldn't work for a native build under Windows. Signed-off-by: Dirk Hohndel --- CMakeLists.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index e31822e0d..5e2c7de8a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -465,6 +465,12 @@ if(NOT NO_TESTS) TEST(TestParse testparse.cpp) endif() +# install a few things so that one can run Subsurface from the build +# directory +add_custom_target(createLinks ALL COMMAND rm -f ${CMAKE_BINARY_DIR}/theme && ln -s ${CMAKE_SOURCE_DIR}/theme ${CMAKE_BINARY_DIR}/theme) +if(NOT NO_PRINTING) + add_custom_target(printing_templates ALL COMMAND rm -f ${CMAKE_BINARY_DIR}/printing_templates && ln -s ${CMAKE_SOURCE_DIR}/printing_templates ${CMAKE_BINARY_DIR}/printing_templates) +endif() if(NOT NO_DOCS) add_custom_target( documentation ALL