File tree Expand file tree Collapse file tree 1 file changed +16
-7
lines changed
Expand file tree Collapse file tree 1 file changed +16
-7
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,11 @@ CMAKE_MINIMUM_REQUIRED(VERSION 3.0)
33cmake_policy (SET CMP0048 NEW)
44project (DXFRW VERSION 1.0.1)
55
6+ # set preferred cache variables
7+ set (LIBDXFRW_BUILD_DOC TRUE CACHE BOOL "Build the documentation" )
8+ set (LIBDXFRW_BUILD_DWG2DXF TRUE CACHE BOOL "Build the dwg2dxf application" )
9+
10+
611# set compiler warnings
712if (MSVC )
813 add_compile_options (/W4 /WX)
@@ -90,15 +95,19 @@ target_include_directories(dxfrw
9095 $<INSTALL_INTERFACE:${LIBDXFRW_INSTALL_INCLUDEDIR} >
9196)
9297
93- add_custom_command (OUTPUT doc /html/index.html
94- COMMAND doxygen ARGS ${CMAKE_CURRENT_SOURCE_DIR} /libdxfrw.dox
95- MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR} /libdxfrw.dox
96- VERBATIM )
98+ if (LIBDXFRW_BUILD_DOC)
99+ add_custom_command (OUTPUT doc /html/index.html
100+ COMMAND doxygen ARGS ${CMAKE_CURRENT_SOURCE_DIR} /libdxfrw.dox
101+ MAIN_DEPENDENCY ${CMAKE_CURRENT_SOURCE_DIR} /libdxfrw.dox
102+ VERBATIM )
97103
98- add_custom_target (doc
99- DEPENDS doc /html/index.html)
104+ add_custom_target (doc
105+ DEPENDS doc /html/index.html)
106+ endif ()
100107
101- add_subdirectory (dwg2dxf)
108+ if (LIBDXFRW_BUILD_DWG2DXF)
109+ add_subdirectory (dwg2dxf)
110+ endif ()
102111
103112# INSTALLATION
104113set (INSTALL_CONFIGDIR ${CMAKE_INSTALL_LIBDIR} /cmake/libdxfrw)
You can’t perform that action at this time.
0 commit comments