CMAKE Custom Definition Dependent Diagram

Should CMake’s –graphviz option depend on a custom target?

Sample CMakeLists.txt file:

cmake_minimum_required(VERSION 2.8)
add_executable(target0 test.cpp)
add_dependencies(target0 target1)
add_custom_target(target1 ALL
COMMAND echo hello
)

The output file “cmake –graphviz = test.dot.” will be:

digraph GG {
node [
fontsize = "12"
];
"node3" [label="target0" shape= "house"];
}

There is no trace of goal 1.

The CMake manual clearly states:

–graphviz=[file]

Generate a graphviz input file that will contain all the library and executable dependencies in the project. See the documentation for CMakeGraphVizOptions.cmake for more details.

So, according to me As you know, your custom target is neither – nor a library, nor an executable file that can be included in the result graph.

Whether the –graphviz option of CMake should be relied upon For custom goals?

Sample CMakeLists.txt file:

cmake_minimum_required(VERSION 2.8)
add_executable(target0 test.cpp)
add_dependencies(target0 target1)
add_custom_target(target1 ALL
COMMAND echo hello
)

The output file “cmake –graphviz = test.dot.” will be:

digraph GG {
node [
fontsize = "12"
];
"node3" [label="target0" shape= "house"];
}

There is no trace of target 1.

The CMake manual clearly states:

–graphviz=[file]

Generate a graphviz input file that will contain all the library and executable dependencies in the project. See the documentation for CMakeGraphVizOptions.cmake for more details.

So, as far as I know, your custom target is neither – nor Not a library, nor an executable file can be included in the result graph.

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 2284 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.