Evidlo / remarkable_printer

Native printing to reMarkable.
GNU General Public License v3.0
257 stars 21 forks source link

pdftopdf (in PPV) is not available on OS X catalina #24

Closed gavinmcc closed 3 years ago

gavinmcc commented 3 years ago

Following https://github.com/Evidlo/remarkable_printer/issues/6 I used the PPV and lpadmin to set up on a mac, but I got an error in the CUPS interface that pdftopdf is not present.

38f9d35c0f7b: gavinmc$ ls /usr/libexec/cups/filter/
cgbannertopdf   cgpdftopdf      cgpdftoraster   commandtops     pstoappleps     pstopdffilter   rastertoepson   rastertolabel   rastertotiff    
cgimagetopdf    cgpdftops       cgtexttopdf     gziptoany       pstocupsraster  pstops          rastertohp      rastertopwg     rastertourf 

This patch seemed to solve this for me, ensuring that raw PDF is sent to the reMarkable jetdirect socket:

38f9d35c0f7b:remarkable_printer gavinmc$ git diff
diff --git a/remarkable.ppd b/remarkable.ppd
index 9fcf20d..9c0791a 100644
--- a/remarkable.ppd
+++ b/remarkable.ppd
@@ -40,7 +40,7 @@
 *JCLToPDFInterpreter: "@PJL ENTER LANGUAGE = PDF<0A>"
 *JCLEnd:              "<1B>%-12345X@PJL EOJ <0A><1B>%-12345X"
 *cupsFilter: "application/vnd.cups-pdf 0 -"
-*cupsFilter2: "application/pdf application/vnd.cups-pdf 0 pdftopdf"
+*cupsFilter2: "application/pdf application/vnd.cups-pdf 0 cgpdftopdf"

 *OpenGroup: General/General
 *JCLOpenUI *PageSize/Page Size: PickOne
gavinmcc commented 3 years ago

On reflection, looks like this is a dupe of https://github.com/Evidlo/remarkable_printer/issues/22

Evidlo commented 3 years ago

What if you replace pdftopdf with -?

gavinmcc commented 3 years ago

What if you replace pdftopdf with -?

Yep, that does seem to work (I missed that the line above it already did this!). I've sent a pull request.