File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -179,12 +179,15 @@ macro(create_manpage BINARY)
179
179
else ()
180
180
set (H2M_ARGS "" )
181
181
endif ()
182
- add_custom_command (TARGET ${ BINARY} POST_BUILD
182
+ add_custom_command (OUTPUT " ${CMAKE_CURRENT_BINARY_DIR} / ${ BINARY}.1"
183
183
COMMAND env LC_ALL=C ${HELP2MAN} --no-info --section 1 ${H2M_ARGS}
184
184
${CMAKE_CURRENT_BINARY_DIR} /${BINARY}
185
185
> ${BINARY} .1 || rm -f ${BINARY} .1
186
+ DEPENDS ${BINARY} "${CMAKE_SOURCE_DIR} /doc/${BINARY} .h2m"
186
187
COMMENT "Generating ${BINARY} man page"
187
188
VERBATIM )
189
+ add_custom_target (man-${BINARY} ALL DEPENDS
190
+ "${CMAKE_CURRENT_BINARY_DIR} /${BINARY} .1" )
188
191
install (FILES ${CMAKE_CURRENT_BINARY_DIR} /${BINARY}.1
189
192
DESTINATION ${CMAKE_INSTALL_MANDIR} /man1 )
190
193
endmacro (create_manpage )
You can’t perform that action at this time.
0 commit comments