[cups] How to get the value of ServerRoot?
Jacob Marble
jacobmarble at google.com
Fri Nov 13 20:34:06 PST 2015
I need to write a new cupsGetPPD()-like function, including the hack
in cupsGetPPD3() under the comment "See if the PPD file is available
locally". This code attempts to fetch a PPD via the local filesystem,
if the server is localhost or /anything.
The problem with writing my own implementation is that the "cups
globals" are private, so my client code doesn't have access to the
value of ServerRoot. Certainly, I could go read cups-files.conf
myself, but ServerRoot isn't guaranteed to be set, allowing for the
default value, which varies by operating system.
The only other option I see is to call cups-config --serverroot from
the shell, which is kind of a hack.
Is there a better way to programmatically get the value of ServerRoot
from client code?
Thank you,
Jacob
More information about the cups
mailing list