eudev-project / eudev

Repository for eudev development
GNU General Public License v2.0
529 stars 144 forks source link

xml stuff breaks build #70

Closed rofl0r closed 10 years ago

rofl0r commented 11 years ago

make[2]: Entering directory `/home/rofl/cdev/cdev/eudev/man'
/usr/bin/xsltproc -o udev.7 --nonet --stringparam man.output.quietly 1 --stringparam funcsynopsis.style ansi --stringparam man.th.extra1.suppress 1 --stringparam man.authors.section.enabled 0 --stringparam man.copyright.section.enabled 0 http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl udev.xml
/usr/bin/xsltproc -o udevd.8 --nonet --stringparam man.output.quietly 1 --stringparam funcsynopsis.style ansi --stringparam man.th.extra1.suppress 1 --stringparam man.authors.section.enabled 0 --stringparam man.copyright.section.enabled 0 http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl udevd.xml
/usr/bin/xsltproc -o udevadm.8 --nonet --stringparam man.output.quietly 1 --stringparam funcsynopsis.style ansi --stringparam man.th.extra1.suppress 1 --stringparam man.authors.section.enabled 0 --stringparam man.copyright.section.enabled 0 http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl udevadm.xml
I/O error : Attempt to load network entity http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl
warning: I/O I/O failed to load external entity "http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl"
error : error : cannot parse http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl
Attempt to load network entity http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl
Attempt to load network entity http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl
warning: warning: failed to load external entity "http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl"
failed to load external entity "http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl"
cannot parse http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl
cannot parse http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl
make[2]: *** [udev.7] Error 4

imo, it's bad style to depend on xml facilities to generate documentation. even worse when it depends on some external stylesheets - making it impossible to build without working network connection.

rofl0r commented 11 years ago

as a temporary workaround, --disable-manpages prevents this stuff from getting built.

rofl0r commented 11 years ago

seems it's related to or the same as #46

rofl0r commented 11 years ago

ping

blueness commented 11 years ago

Sorry I haven't had time to work on this. I'm not sure how to proceed.

rofl0r commented 11 years ago

problem 1) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl is referenced but nowhere to be found, so the build process should use a local copy. maybe one can be fetched from web.archive.org. problem 2) the manpage generation requires xsltproc and other stuff. i don't understand why this has to run on user's box. the manpages could be generated on eudev maintainers machine and distributed inside the release tarball, so the user needs less bloat installed on his pc.

blueness commented 11 years ago

The link downloads for me. It only seems to no work in musl so I'm not sure what's happening. We could consider just doing that locally.

axs-gentoo commented 11 years ago

On gentoo, that docbook.xsl is available locally when (docbook? whatever package it is) is installed; I expect this is standard as part of that package and not a gentoo'ism. I do recall there is an issue with systemd's udev too that docbook is needed even though manpages are supposed to have been pre-generated. This will probably need some looking into.

axs-gentoo commented 11 years ago

Apologies -- on Gentoo, we depend on the package "app-text/docbook-xsl-stylesheets" to provide this file.

blueness commented 11 years ago

so if we include docbook-xsl-stylesheets in a gentoo musl stage3, this will work? I guess the question is, should we start bundling a local copy of docbook.xsl?

rofl0r commented 11 years ago

how big is it ? if it's not seriously bloating the release tarball it could be added - but then the better solution is still to provide the generated manpages together with the release tarball so the user needs neither xsltproc nor docbook. alternatively the generated manpages could be distributed as a separate tarball.

btw, i suspect the documentation wasn't touched in ages anyway...

gmm42 commented 11 years ago

I would also like to see pregenerated man pages in the eudev tarball. LFS might replace udev extracted from systemd with eudev in that case, see: http://wiki.linuxfromscratch.org/lfs/ticket/3384

fjaell commented 11 years ago

Indeed, to lower the build-time dependencies it's best to ship the generated man-pages with the release tarball. Please :)

axs-gentoo commented 11 years ago

"how big is it ?"

it's big enough -- you most likely need the full set of xml files, not just one; and that's ~100ish files iirc.

Documentation is changed with every version tho -- not much, but enough to match the differences in the tools from one version to another.

I don't know what the repercussions are of manpage generation within a tarball (ie, if the version of man on a system matters, etc. etc.), but i'll look into it along with issue 75.

axs-gentoo commented 11 years ago

OK, so distributing manpages is trivial enough; confirmed it works with the following:

--- a/man/Makefile.am +++ b/man/Makefile.am @@ -16,7 +16,7 @@ MANPAGES = \ udevd.8 \ udevadm.8

-man_MANS = \ +dist_man_MANS = \ $(MANPAGES)

CLEANFILES = \

...but I haven't committed it because I haven't researched yet whether there are any implications with doing this.

blueness commented 10 years ago

This issue is obsolete because I'm going to start shipping pre-built man pages.