On 05/27/2015 03:04 PM, Lennart Poettering wrote:
> Hmm, any chance we can somehow define those entities without having to
> add 
> 
>  <!ENTITY % entities SYSTEM "custom-entities.ent" >
>  %entities;
>  ]>
> 
> To each file? Can't we tell xsltproc about this via some command line
> switch or so?
> 
> This is in a way similar to how we use gcc's "-include config.h"
> switch rather than really write "#include <config.h>" in each source
> file...

I've looked for some way to do this, but haven't found a nice solution
yet. The problem is that the full XML tag is:

<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
  "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"; [
   <!ENTITY % entities SYSTEM "custom-entities.ent" >
   %entities;
]>

So that !ENTITY tag needs to live inside the !DOCTYPE tag, which is not
something you can achieve with a command line switch AFAICS.

We could maybe add some hack to the xsl we feed xsltproc with, but
frankly, the above is the common way of including files to define own
entities, so it'd consider that more readable, even though it's a bit
more boilerplate.


Daniel

_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to