cmdline-docs: fix make install with configure --disable-docs

make -C docs/cmdline-opts install depends on all-am, which in turn
depends on $(MANS), unconditionally defined to be $(man_MANS).

As with CLEANFILES, only add curl.1 to man_MANS when BUILD_DOCS is true
so we don't try to build curl.1 unnecessarily.

Closes #13198
This commit is contained in:
Chris Webb 2024-03-27 10:09:54 +00:00 committed by Daniel Stenberg
parent de7b3e8921
commit 4b42cda3df
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -27,8 +27,6 @@ AUTOMAKE_OPTIONS = foreign no-dependencies
MANPAGE = curl.1
ASCIIPAGE = curl.txt
man_MANS = $(MANPAGE)
include Makefile.inc
EXTRA_DIST = $(DPAGES) MANPAGE.md $(SUPPORT) CMakeLists.txt mainpage.idx
@ -42,6 +40,7 @@ MANAGEN=$(abs_top_srcdir)/scripts/managen
if BUILD_DOCS
CLEANFILES = $(MANPAGE) $(ASCIIPAGE)
man_MANS = $(MANPAGE)
all: $(MANPAGE) $(ASCIIPAGE)