-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add building the manual to cmake #2423
base: master
Are you sure you want to change the base?
Conversation
Also raise cmake_minimum_required to 3.18 for the LibXslt::xsltproc target.
If the raised minimum cmake version is a problem, I could easily replace LibXslt::xsltproc with LIBXSLT_XSLTPROC_EXECUTABLE |
add_custom_command(OUTPUT | ||
"${CMAKE_CURRENT_BINARY_DIR}/manual.xml" | ||
COMMAND | ||
asciidoc --backend=docbook --doctype=book --out-file "${CMAKE_CURRENT_BINARY_DIR}/manual.xml" "${CMAKE_CURRENT_SOURCE_DIR}/manual.asciidoc" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing DEPENDS
for the input, doesn't it?
|
||
include(CheckSymbolExists) | ||
include(CheckIPOSupported) | ||
|
||
option(NINJA_BUILD_BINARY "Build ninja binary" ON) | ||
option(NINJA_BUILD_DOC "Build ninja's manual" ON) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you default this to OFF?
|
||
add_custom_target(doc ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/manual.html") | ||
|
||
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/manual.html" TYPE DOC) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the point of this?
add_custom_command(OUTPUT | ||
"${CMAKE_CURRENT_BINARY_DIR}/manual.xml" | ||
COMMAND | ||
asciidoc --backend=docbook --doctype=book --out-file "${CMAKE_CURRENT_BINARY_DIR}/manual.xml" "${CMAKE_CURRENT_SOURCE_DIR}/manual.asciidoc" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
asciidoc --backend=docbook --doctype=book --out-file "${CMAKE_CURRENT_BINARY_DIR}/manual.xml" "${CMAKE_CURRENT_SOURCE_DIR}/manual.asciidoc" | |
${Asciidoc_Executable} --backend=docbook --doctype=book --out-file "${CMAKE_CURRENT_BINARY_DIR}/manual.xml" "${CMAKE_CURRENT_SOURCE_DIR}/manual.asciidoc" |
to be safe?
Also raise cmake_minimum_required to 3.18 for the LibXslt::xsltproc target.