Hi. I can not get Graphviz options to work. I generate a graph using a custom module below, and executing the target produces a png graph.
include_guard(GLOBAL)
add_custom_target(graphviz ALL
COMMAND ${CMAKE_COMMAND} "--graphviz=graphviz/${PROJECT_NAME}.dot" .
COMMAND dot -Tpng graphviz/${PROJECT_NAME}.dot -o graphviz/${PROJECT_NAME}.png
BYPRODUCTS graphviz/*
WORKING_DIRECTORY "${CMAKE_BINARY_DIR}"
COMMENT "Creates a project dependency graph as png, located under: build${CMAKE_BINARY_DIR}/graphviz")
CMakeGraphVizOptions.cmake
GRAPHVIZ_GRAPH_HEADER ("test")
The error: CMake Error at /home/user/CMakeGraphVizOptions.cmake:1 (GRAPHVIZ_GRAPH_HEADER): Unknown CMake command "GRAPHVIZ_GRAPH_HEADER".
How can i set options?
What would be nice if graphviz options could be set like below, but it does not work.
set_target_properties(graphviz PROPERTIES GRAPHVIZ_GRAPH_NAME "test")