Bug 188799

Summary: print/xfce4-print does not build when CUPS support is enaled
Product: Ports & Packages Reporter: Jason W. Bacon <jwb>
Component: Individual Port(s)Assignee: Olivier Duchateau <olivierd>
Status: Closed FIXED    
Severity: Affects Only Me CC: olivierd
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   

Description Jason W. Bacon freebsd_committer freebsd_triage 2014-04-19 19:10:00 UTC
Build fails due to direct use of ipp_t fields in cups.c, which is no longer supported.

Fix: cups.c needs to be edited to use accessor functions instead of referencing ipp_t fields directly.

Partial patch to demonstrate the approach:



Not all the fixes appear to be so straightforward and I don't have time to work on it at the moment.--2ik3nwqQhKoQQSRiKcRkCA4oUMUEN8Y2NnKHiZuZ4xSF7zIk
Content-Type: text/plain; name="file.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="file.diff"

--- printing-systems/cups/cups.c.orig   2014-04-19 12:20:18.000000000 -0500
+++ printing-systems/cups/cups.c        2014-04-19 12:27:02.000000000 -0500
@@ -133,8 +133,10 @@
 
   language = cupsLangDefault ();
   request = ippNew ();
-  request->request.op.operation_id = operation_id;
-  request->request.op.request_id = 1;
+  //request->request.op.operation_id = operation_id;
+  ippSetOperation(request,operation_id);
+  //request->request.op.request_id = 1;
+  ippSetRequestId(request,1);
 
   ippAddString (request, IPP_TAG_OPERATION, IPP_TAG_CHARSET, "attributes-charset", NULL, "utf-8");
 
@@ -242,7 +244,7 @@
 
       if (!request)
         continue;
-      if (request->state == IPP_ERROR || request->state == IPP_IDLE) {
+      if (ippGetState(request) == IPP_ERROR || request->state == IPP_IDLE) {
         ippDelete (request);
         continue;
       }
How-To-Repeat: 
make config
select CUPS
make
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2014-04-19 20:16:30 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-ports-bugs

ports PR.
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2014-04-19 20:16:49 UTC
Responsible Changed
From-To: freebsd-ports-bugs->freebsd-xfce

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 3 Kevin Zheng 2014-05-24 14:40:26 UTC
Hi there,

I'm having the same problem Jason is describing. The partial patch seems
to fix one error, but there are quite a few more to go.

Thanks,
Kevin Zheng