[MPlayer-DOCS] [PATCH] make configure and generated main.xml's more "spec-valid"
Torinthiel
torinthiel at megapolis.pl
Thu Jan 4 22:08:13 CET 2007
On Thu, Jan 04, 2007 at 04:38:32PM +0300, Andrew Savchenko wrote:
> Local DTD is currently detected in my system. But if it will not
> for some reason? Of if there are some people with no DTDs in
> default path?
For what reason? Either the file exists, and it is detected, or not. If
there are some people without DTDs, then right now they're doomed. With
this patch and an active internet connection they can build the docs.
> Interesting, there are my locations of dtd's:
> ---
> $ locate docbookx.dtd
> /usr/share/apps/ksgmltools2/docbook/xml-dtd-4.1.2/docbookx.dtd
> /usr/share/apps/ksgmltools2/docbook/xml-dtd-4.2/docbookx.dtd
> /usr/share/sgml/docbook/sgml-dtd-4.4-1.0-26/docbookx.dtd
> /usr/share/sgml/docbook/sgml-dtd-4.3-1.0-26/docbookx.dtd
> /usr/share/sgml/docbook/sgml-dtd-4.2-1.0-26/docbookx.dtd
> /usr/share/sgml/docbook/xml-dtd-4.3-1.0-26/docbookx.dtd
> /usr/share/sgml/docbook/xml-dtd-4.2-1.0-26/docbookx.dtd
> /usr/share/sgml/docbook/xml-dtd-4.4-1.0-26/docbookx.dtd
> /usr/share/sgml/docbook/xml-dtd-4.1.2-1.0-26/docbookx.dtd
> ---
> However, only the last location could be detected with current
> configure script.
See the attached patch, it should detect some more paths ;)
Diego, should I?
> > > Imho it is bad idea to access internet for compilation
> > > purposes without expilcit user permission to do this. Programs
> > > shouldn't surf the internet on their own. This can be optional
> > > but _not_ default behaviour.
> >
> > It's not default. It's fallback if everything else fails.
> > Current behaviour guarantees failure, as it sets the _required_
> > DTD path to a path that already was checked and didn't contain
> > the DTD. A fallback to internet at least gives some chances of
> > success.
>
> Yes it is usefull in such case, but I don't want to allow any
> progams to access internet beyond my eyes and without my
> permission.
OK, that's your POV. Mine is 'Don't provide as default something that is
guaranteed not to work'. And each one has some logic behind it. Let's
delay this for some time. And how about the first part of patch (file://
URIs)?
> > If it's really an issue I can modify patch to use http only if
> > --use-http was passed to configure, but there are some problems
> > with it: 1) It'll be the first command-line argument to
> > configure. More will likely follow, so some proper general
> > parsing is to be done.
>
> Maybe bash builtin getopt will help? If you don't want rely on
> bash, you may use external getopt program.
I think something along what's now in trunk/configure is better. getopt
is good, but for short options, which I don't find attractive in a run
once in a loong while script.
> > 2) what if user passed --use-http and
> > proper DTD exists? Which one should be used? Maybe two different
> > options --fallback-to-http and --force-http? Even more ugly. And
> > it makes configure more complicated, like the main one is.
>
> Perhaps, another solution exists: issue an error message about
> missing DTD, and print help message with link to the address from
> which DTD must be downloaded?
Not good enough IMHO. The DocBook DTD consists of several files,
downloading just one is not enough. And anyone is better of installing
them in some standard location and in one piece, and this is
distro-specific.
And just thought of another issue with adding options to configure:
3) the script absolutely has to remember the options with which it was
run, as it is sometimes re-run automatically. This has caused some
problems in trunk/configure.
Torinthiel
--
Waclaw "Torinthiel" Schiller GG#: 3073512
torinthiel(at)megapolis(dot)pl
gpg: 0906A2CE fpr: EE3E DFB4 C4D6 E22E 8999 D714 7CEB CDDC 0906 A2CE
"No classmates may be used during this examination"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-docs/attachments/20070104/42fe18c1/attachment.pgp>
More information about the MPlayer-DOCS
mailing list