-
Notifications
You must be signed in to change notification settings - Fork 370
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 'install-nodoc' target for make #890
Conversation
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.
@jougs Thanks for fixing this. Could you add a line to the INSTALL
file documenting this possibility and have a look at the one questions I put into the code?
@@ -361,4 +361,8 @@ install( FILES LICENSE README.md NEWS | |||
DESTINATION ${CMAKE_INSTALL_DOCDIR} | |||
) | |||
|
|||
add_custom_target( install-nodoc | |||
COMMAND make NEST_INSTALL_NODOC=true install |
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 I still use -j N
with this?
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.
The short answer is yes.
The slightly longer answer is that my changes do not alter the behavior of your call to make
for any target but install-nodoc
. And for install
-j N
did not have an effect anyway as the installation is always performed serially in order to avoid problems with concurrent writes.
@heplesser: Thanks for the review. I've addressed your comments in my commit |
@jougs I can use the |
@jougs I just sent you a PR adding a required "optional" flag. With this, things work in a way: as long as one only ever calls I wonder if a complete solution of this problem would require introduction of proper build and install configurations, such as deploy/develop/debug. |
…ature/add-install-nodoc
This makes the install-nodoc target work by first deleting the help directory, creating help for the install target, install the help directory if it was created, and generating the help index for the installed help directory if that exists.
@heplesser: I've come up with a reasonably stable solution in my recent commits. Can you please test again? Thanks! |
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.
@jougs Great, thanks! I works! I just have two little details, see comments in the code.
extras/help_generator/writers.py
Outdated
@@ -152,6 +152,10 @@ def write_helpindex(helpdir): | |||
--------------------------------------- | |||
|
|||
""" | |||
|
|||
if not os.path.exists(helpdir): |
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.
Please add a comment explaining why just returning is fine instead of raising an error. In the future, we may not remember the logic behind the return here.
doc/CMakeLists.txt
Outdated
) | ||
|
||
# Update the global help index to include all help files in | ||
# the global installation directory for |
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.
Fix indentation.
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.
Perfect, Works for me.
This fixes #153.
Unfortunately, CMake does not support custom code or conditionals in the
install
target. I therefore implemented this as an extension to the help extraction system itself.