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
Man page installation and distribution #12921
Comments
So what is the issue?
This seems to imply you have not understood how dists are created: all Or check how current dists look like as daily snapshots. |
Indeed, my apologies. I wasn't familiar with how
Thanks for the link. |
One last issue I'd lilke to bring up: although curl.1 is distributed once again, on systems without perl, --disable-docs gets auto-selected, preventing its installation (though, I suppose it could be done manually by the packager). Should --disable-docs disable installation in both |
My thinking has been:
|
Distributed |
@michaelforney is there any still outstanding issue in the current tarballs? |
Yes, it doesn't look like anything has changed since I opened this issue. To reiterate:
|
Fixes #12921 Reported-by: Michael Forney
Fixes #12921 Reported-by: Michael Forney
Drop docs/mk-ca-bundle.1 from the tarball. It can be generated at will. Fixes #12921 Reported-by: Michael Forney
I did this
Recently there's been a lot of changes around man pages concerning generation, installation, distribution, and build-by-default.
First, here's my understanding of some automake variables used in curl:
man_MANS
: Man pages listed here will get built by default and installed, but not distributeddist_man_MANS
: Man pages listed here will get built by default, installed, and distributed.noinst_man_MANS
: This doesn't actually do anything. I don't see any reference to it in automake or the generated Makefile.nodist_MANS
: This doesn't do anything either. Looking at automake source, there isnodist_man_MANS
, which is the same asman_MANS
since man pages aren't distributed by default (see https://www.gnu.org/software/automake/manual/html_node/Man-Pages.html). The comment in the source says "We handle nodist_ for uniformity. man pages aren't distributed by default so it isn't actually very important".EXTRA_DIST
: Files here are distributed, but not installed or built by the default target.Here's a summary of the recent history of a few man pages:
Before 8.6.0,
mk-ca-bundle.1
was not generated, but it was distributed since it was innoinst_man_MANS
, which was present inEXTRA_DIST
.man_MANS
, making it get installed and built by default. Sincenoinst_man_MANS
was dropped fromEXTRA_DIST
, it no longer got distributed.man_MANS
, so it was no longer installed or built by default. The only reference left tomk-ca-bundle.1
at this point was throughnoinst_man_MANS
, a bogus variable not used by anything, andCLEANFILES
.dist_man_MANS
, making it get installed once again, distributed, and built by default. This is the current state.It seems to me that the intent is for it to be built by default and distributed, but not installed. I think the way to do this is to remove
mk-ca-bundle.1
fromdist_man_MANS
, add it toEXTRA_DIST
to distribute it, and add a dependencyall-local: $(MK_CA_DOCS)
to build it by default.Before 8.6.0,curl.1
was distributed since it was present innoinst_man_MANS
, which was added toEXTRA_DIST
.As above, eefcc1b droppednoinst_man_MANS
fromEXTRA_DIST
, which causedcurl.1
to no longer be distributed.cf5f604 added it back through a
# $(abs_builddir) is to disable VPATH when searching for this file, which
# would otherwise find the copy in $(srcdir) which breaks the $(HUGE)
# rule in src/Makefile.am in out-of-tree builds that references the file in the
# build directory.
#
# First, seed the used copy of curl.1 with the prebuilt copy (in an out-of-tree
# build), then run make recursively to rebuild it only if its dependencies
# have changed.
$(abs_builddir)/curl.1:
if test "$(top_builddir)x" != "$(top_srcdir)x" -a -e "$(srcdir)/curl.1"; then \
$(INSTALL_DATA) "$(srcdir)/curl.1" $@ \
&& touch -r "$(srcdir)/curl.1" $@; fi
cd cmdline-opts && $(MAKE)
# EXTRA_DIST breaks with $(abs_builddir) so build it using this variable
# but distribute it (using the relative file name) in the next variable
man_MANS = $(abs_builddir)/curl.1
dist-hook
copying it tocurl.1.dist
. This is fine, but this could have also been done by addingcurl.1
toEXTRA_DIST
, which is what was done prior to 8.6.0 (indirectly). If you do end up sticking with thedist-hook
and naming itcurl.1.dist
, there is some other logic that can be removed:curl/docs/Makefile.am
Lines 115 to 127 in 922091c
curl/docs/Makefile.am
Lines 34 to 36 in 922091c
I believe this was only needed to make the distinction between the distributed
curl.1
, and the builtcurl.1
for out-of-tree builds. If the distributed file is calledcurl.1.dist
, I think this tricky logic can be removed. However, for uniformity, if one distributed manual using the.dist
naming scheme, so should the others (curl-config.1
andmk-ca-bundle.1
).As described above, some automake variables set by curl aren't actually used by automake. I think
noinst_man_MANS
andnodist_MANS
should be removed fromdocs/Makefile.am
,docs/libcurl/Makefile.am
, anddocs/libcurl/opts/Makefile.am
, since it just adds to the confusion.I can work on a pull request to resolve these issues, but first, maybe you could confirm the desired behavior? I think it is
Additionally, should distributed man pages be namedfoo.[1-9]
orfoo.[1-9].dist
?I expected the following
No response
curl/libcurl version
Current master 5a4b2f9
operating system
N/A
The text was updated successfully, but these errors were encountered: