The problem is that our printers have very bad printing quality by default, printing quality of pdfs can be improved by using
lp -o raw.
Is it generally possible to mix other options, especially
-o sides=double-sided-long-edge with
-o raw, the printer I use simply ignores all other options.
lp -o raw -o sides=double-sided-long-edge
The printer only has a4 paper and when the pdf page size is not a4, then the printing job always gets stuck until I manually select the paper feed with the a4 paper, specifying
-o media=a4 also does not work in this case.