zj-58
zj-58 copied to clipboard
Can't compile PPD per instructions in README
$ cmake --build .
Scanning dependencies of target ppds
[ 33%] Building PPDs
[ 33%] Built target ppds
Scanning dependencies of target rastertozj
[ 66%] Building C object CMakeFiles/rastertozj.dir/rastertozj.c.o
/c0de/d0ngxi/src/zj-58/rastertozj.c: In function ‘initializeSettings’:
/c0de/d0ngxi/src/zj-58/rastertozj.c:37:3: warning: ‘ppdOpenFile’ is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
37 | ppd_file_t *pPpd = ppdOpenFile(getenv("PPD"));
| ^~~~~~~~~~
In file included from /c0de/d0ngxi/src/zj-58/rastertozj.c:4:
/usr/include/cups/ppd.h:389:20: note: declared here
389 | extern ppd_file_t *ppdOpenFile(const char *filename) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
| ^~~~~~~~~~~
/c0de/d0ngxi/src/zj-58/rastertozj.c:41:3: warning: ‘ppdClose’ is deprecated: Use cupsCopyDestInfo and friends instead. [-Wdeprecated-declarations]
41 | ppdClose(pPpd);
| ^~~~~~~~
In file included from /c0de/d0ngxi/src/zj-58/rastertozj.c:4:
/usr/include/cups/ppd.h:364:14: note: declared here
364 | extern void ppdClose(ppd_file_t *ppd) _CUPS_DEPRECATED_1_6_MSG("Use cupsCopyDestInfo and friends instead.");
| ^~~~~~~~
[100%] Linking C executable rastertozj
[100%] Built target rastertozj
What do you mean by 'can't compile'? Yes, there are couple of warnings. They are intended, as ppd is actually deprecated years ago, but it is still use wide-spread on tons of systems. It will be warnings so.
Our build policy is (by default) very strict, no warnings or it's not successful compile. 😉 https://github.com/apple/cups/blob/master/cups/ppd.h
have you investigated what type of effort would be required to remove the warning and perform as it suggests. Should I investigate further - what are your thoughts on the future of this library once the required library is removed? Thanks!
(is there are fork/dev branch, plan?)
I can't do anything with deprecated warning here, since it is intended. Apple deprecated CUPS interface, and that is nothing to do with it, everybody should struggle anytime we try to use that interface now.
You may try, looking to reported -Wdeprecated-declarations
- append compiler flag -Wno-deprecated-declarations
, and it could work.
@elasticdotventures , perhaps you could fix it and submit a pull request?