[cups] how to work around API changes?

Jiri Popelka jpopelka at redhat.com
Mon Aug 31 02:07:19 PDT 2015


On 29.8.2015 02:25, Jacob Marble wrote:
> Context:
> The following change makes API changes, so my software has to support <1.6
> or >=1.6, but can't support both.
> STR #3928 Add accessors for IPP APIs and make IPP structures private.
> 
> I need to support users who are building against older CUPS client APIs.
> The easy way is to copy the new accessor functions into my project
> (surrounded with #ifndef _CUPS_API_1_6), but that's a legal gray area.

That's how we do it in pycups, you can take a look at:
https://git.fedorahosted.org/cgit/pycups.git/tree/cupsmodule.h
https://git.fedorahosted.org/cgit/pycups.git/tree/cupsmodule.c

--
Jiri



More information about the cups mailing list