Compiling cups-pdf and Printing to File. - Suse
This is a discussion on Compiling cups-pdf and Printing to File. - Suse ; I am running Open Suse 10.2 on a system with no physical printer attached,
but sometimes need to print to a PDF file. My recollection of other
Linuxes that I've used is that a PDF virtual printer choice was always
...
-
Compiling cups-pdf and Printing to File.
I am running Open Suse 10.2 on a system with no physical printer attached,
but sometimes need to print to a PDF file. My recollection of other
Linuxes that I've used is that a PDF virtual printer choice was always
available in the print dialogue, and I must admit that I have never given
the matter much thought.
However when I want to print a document from this system the only printer
choice given is PostScript/default. Ok, I can do that then use ps2pdf to
get what I want, but that's not terribly efficient. So I had a look at the
Suse site and found the Printing to PDF HOWTO. So far so good. Downloaded
the relevant files and followed the compile instruction
gcc -O9 -s -o cups-pdf cups-pdf.c
This gave me the error message " unrecognised option '-09' ". So my first
question is what is option -09 supposed to do? Reading the gcc manual
was no help at all. Can somebody please give me a clue?
My other question relates to the print dialogue. The dialogue window that
comes up is titled "Print". I am using KDE, and wondered why it isn't the
kprinter dialogue that appears. I can invoke the kprinter dialogue from the
command line, and it does offer a choice of printing to a PDF file. I'm a
bit lost here. What determines which print dialogue appears, and why would
one dialogue offer the choice of PDF and the other not? Any clues here
will be gratefully received.
John
-
Re: Compiling cups-pdf and Printing to File.
ohnjay schrieb am 08.11.2007 22:52:
....
> gcc -O9 -s -o cups-pdf cups-pdf.c
>
> This gave me the error message " unrecognised option '-09' ". So my first
without knowing the details: did you notice the error message is
complaining about "zero nine" whereas you intended to type "oh nine"?
-
Re: Compiling cups-pdf and Printing to File.
On Thu, 08 Nov 2007 21:52:44 +0000, ohnjay wrote:
> However when I want to print a document from this system the only
> printer choice given is PostScript/default. Ok, I can do that then use
> ps2pdf to get what I want, but that's not terribly efficient. So I had a
> look at the Suse site and found the Printing to PDF HOWTO. So far so
> good. Downloaded the relevant files and followed the compile instruction
>
> gcc -O9 -s -o cups-pdf cups-pdf.c
>
> This gave me the error message " unrecognised option '-09' ". So my
> first question is what is option -09 supposed to do? Reading the gcc
> manual was no help at all. Can somebody please give me a clue?
>
n
man gcc only gives optimisation values of
-O -O0 -O1 -O2 -O3 -Os
-
Re: Compiling cups-pdf and Printing to File.
On Fri, 09 Nov 2007 08:37:33 +0000, graham wrote:
> On Thu, 08 Nov 2007 21:52:44 +0000, ohnjay wrote:
>
>
>> However when I want to print a document from this system the only
>> printer choice given is PostScript/default. Ok, I can do that then use
>> ps2pdf to get what I want, but that's not terribly efficient. So I had a
>> look at the Suse site and found the Printing to PDF HOWTO. So far so
>> good. Downloaded the relevant files and followed the compile instruction
>>
>> gcc -O9 -s -o cups-pdf cups-pdf.c
>>
>> This gave me the error message " unrecognised option '-09' ". So my
>> first question is what is option -09 supposed to do? Reading the gcc
>> manual was no help at all. Can somebody please give me a clue?
>>
> n
>
> man gcc only gives optimisation values of
> -O -O0 -O1 -O2 -O3 -Os
Yes, I found the same.
-
Re: Compiling cups-pdf and Printing to File.
On Thu, 08 Nov 2007 23:58:41 +0100, Rainer Latka wrote:
> ohnjay schrieb am 08.11.2007 22:52:
> ...
>> gcc -O9 -s -o cups-pdf cups-pdf.c
>>
>> This gave me the error message " unrecognised option '-09' ". So my first
>
> without knowing the details: did you notice the error message is
> complaining about "zero nine" whereas you intended to type "oh nine"?
I typed zero nine, and that is what gcc complained about. It's clearly
zero nine in the instructions. I suppose it could be a typo in the
original.
-
Re: Compiling cups-pdf and Printing to File.
On Thu, 08 Nov 2007 23:58:41 +0100, Rainer Latka wrote:
> ohnjay schrieb am 08.11.2007 22:52:
> ...
>> gcc -O9 -s -o cups-pdf cups-pdf.c
>>
>> This gave me the error message " unrecognised option '-09' ". So my first
>
> without knowing the details: did you notice the error message is
> complaining about "zero nine" whereas you intended to type "oh nine"?
I was so convinced that it read zero nine that I did not try the
alternative. Foolish of me. Following your suggestion I ran it with the oh
nine option and it compiled perfectly. Thank you.
-
Re: Compiling cups-pdf and Printing to File.
ohnjay wrote:
> I am running Open Suse 10.2 on a system with no physical printer attached,
> but sometimes need to print to a PDF file. My recollection of other
> Linuxes that I've used is that a PDF virtual printer choice was always
> available in the print dialogue, and I must admit that I have never given
> the matter much thought.
>
> However when I want to print a document from this system the only printer
> choice given is PostScript/default. Ok, I can do that then use ps2pdf to
> get what I want, but that's not terribly efficient. So I had a look at the
> Suse site and found the Printing to PDF HOWTO. So far so good. Downloaded
> the relevant files and followed the compile instruction
>
> gcc -O9 -s -o cups-pdf cups-pdf.c
>
> This gave me the error message " unrecognised option '-09' ". So my first
> question is what is option -09 supposed to do? Reading the gcc manual
> was no help at all. Can somebody please give me a clue?
>
> My other question relates to the print dialogue. The dialogue window that
> comes up is titled "Print". I am using KDE, and wondered why it isn't the
> kprinter dialogue that appears. I can invoke the kprinter dialogue from
> the command line, and it does offer a choice of printing to a PDF file.
> I'm a bit lost here. What determines which print dialogue appears, and why
> would one dialogue offer the choice of PDF and the other not? Any clues
> here will be gratefully received.
>
> John
There is always the option of using OpenOffice and several other tools in
KDE (and probably in Gnome also) that output to a file as pdf.
-
Re: Compiling cups-pdf and Printing to File.
On Fri, 09 Nov 2007 13:18:51 -0700, John Bowling wrote:
> ohnjay wrote:
>
>> I am running Open Suse 10.2 on a system with no physical printer attached,
>> but sometimes need to print to a PDF file. My recollection of other
>> Linuxes that I've used is that a PDF virtual printer choice was always
>> available in the print dialogue, and I must admit that I have never given
>> the matter much thought.
>>
>> However when I want to print a document from this system the only printer
>> choice given is PostScript/default. Ok, I can do that then use ps2pdf to
>> get what I want, but that's not terribly efficient. So I had a look at the
>> Suse site and found the Printing to PDF HOWTO. So far so good. Downloaded
>> the relevant files and followed the compile instruction
>>
>> gcc -O9 -s -o cups-pdf cups-pdf.c
>>
>> This gave me the error message " unrecognised option '-09' ". So my first
>> question is what is option -09 supposed to do? Reading the gcc manual
>> was no help at all. Can somebody please give me a clue?
>>
>> My other question relates to the print dialogue. The dialogue window that
>> comes up is titled "Print". I am using KDE, and wondered why it isn't the
>> kprinter dialogue that appears. I can invoke the kprinter dialogue from
>> the command line, and it does offer a choice of printing to a PDF file.
>> I'm a bit lost here. What determines which print dialogue appears, and why
>> would one dialogue offer the choice of PDF and the other not? Any clues
>> here will be gratefully received.
>>
>> John
>
> There is always the option of using OpenOffice and several other tools in
> KDE (and probably in Gnome also) that output to a file as pdf.
Yes, I have discovered a little more on the subject since my first post.
Having got cups-pdf to compile and install, I found that this only installs
a PDF driver for KDE programs (kwrite, konqueror etc.). Open Office seems
to use a different means of printing and there is a separate procedure
(using spadmin) for installing a PDF printer there.
OK, so I can now print to PDF from OpenOffice as well as from konqueror.
Problem is, I also want to print to PDF from Firefox and Thunderbird, and
their print dialogue still does not include a PDF option. I guess I'll go
to Mozilla and see what I can find out there.
What a mess this this is! Why is it necessary to install separate PDF
printers, using different procedures, for every separate suite of programs?
-
Re: Compiling cups-pdf and Printing to File.
ohnjay skrev:
>
> Yes, I have discovered a little more on the subject since my first post.
> Having got cups-pdf to compile and install, I found that this only installs
> a PDF driver for KDE programs (kwrite, konqueror etc.). Open Office seems
> to use a different means of printing and there is a separate procedure
> (using spadmin) for installing a PDF printer there.
>
> OK, so I can now print to PDF from OpenOffice as well as from konqueror.
>
> Problem is, I also want to print to PDF from Firefox and Thunderbird, and
> their print dialogue still does not include a PDF option. I guess I'll go
> to Mozilla and see what I can find out there.
>
> What a mess this this is! Why is it necessary to install separate PDF
> printers, using different procedures, for every separate suite of programs?
It's not...
My cups-pdf is working perfectly at openSUSE 10.3, and it is available
for all of the applications. Of course it is possible to build the
package yourself, but I used a slightly different method than the
default compile procedure. At my debian server the cups-pdf is working
perfectly, so I chose to steal the package from there (the following is
done as root):
-----
wget
http://ftp.de.debian.org/debian/pool...4.6-4_i386.deb
alien -r cups-pdf_2.4.6-4_i386.deb
rpm -Uvh cups-pdf_2.4.6-4_i386.deb
chmod 700 /usr/lib/cups/backend/cups-pdf
rccups restart
-----
And it is working very well at my computer... I did this a couple of
weeks ago and perhaps I have forgotten some minor steps, but this was my
base install procedure.
--
Best regards Jacob Tranholm
Karl R. Popper: Observation statements and statements of experimental
results are always interpretations of the facts observed.
-
Re: Compiling cups-pdf and Printing to File.
Jacob Tranholm skrev:
>
> rpm -Uvh cups-pdf_2.4.6-4_i386.deb
>
Sorry... The third command should of course have been something like:
rpm -Uvh cups-pdf-*.rpm
--
Best regards Jacob Tranholm
Karl R. Popper: Observation statements and statements of experimental
results are always interpretations of the facts observed.
-
Re: Compiling cups-pdf and Printing to File.
>>
>> What a mess this this is! Why is it necessary to install separate PDF
>> printers, using different procedures, for every separate suite of programs?
>
> It's not...
>
> My cups-pdf is working perfectly at openSUSE 10.3, and it is available
> for all of the applications. Of course it is possible to build the
> package yourself, but I used a slightly different method than the
> default compile procedure. At my debian server the cups-pdf is working
> perfectly, so I chose to steal the package from there (the following is
> done as root):
>
> -----
> wget
> http://ftp.de.debian.org/debian/pool...4.6-4_i386.deb
> alien -r cups-pdf_2.4.6-4_i386.deb
> rpm -Uvh cups-pdf_2.4.6-4_i386.deb
> chmod 700 /usr/lib/cups/backend/cups-pdf
> rccups restart
> -----
I compiled from source, following the procedure below, which is taken from
the HOWTO at http://en.opensuse.org/Printing_to_PDF_HOWTO
cd /some/path/cups-pdf-2.4.5/src
gcc -O9 -s -o cups-pdf cups-pdf.c
cp cups-pdf /usr/lib/cups/backend
cp ../extra/cups-pdf.conf /etc/cups/
cp ../extra/PostscriptColor.ppd /usr/share/cups/model
chmod 700 /usr/lib/cups/backend/cups-pdf
chown root /usr/lib/cups/backend/cups-pdf
You will notice that it does not mention rccups restart, but I have
restarted the PC.
>
> And it is working very well at my computer... I did this a couple of
> weeks ago and perhaps I have forgotten some minor steps, but this was my
> base install procedure.
>
Is it available in OpenOffice and Firefox?
-
Re: Compiling cups-pdf and Printing to File.
ohnjay skrev:
>
> Is it available in OpenOffice and Firefox?
Yes... It is available for *all* applications.
You also have to install the cups-pdf writer in cups. Perhaps you've
forgotten this step. In simple steps this should be possible using the
following commands (from firefox):
1) Connect to 'http://localhost:631/'
2) Select "Add Printer"
3) Write some name, description,...
4) For the device you select "CUPS-PDF (Virtual PDF Printer)"
5) And as PPD-file you select the provided "PostscriptColor.ppd"
(at /usr/share/cups/model/PostscriptColor.ppd in your description and at
/usr/share/ppd/cups-pdf/PostscriptColor.ppd in my description (created
from deb-package))
6) Click "Add Printer" and enter your root username and password
7) Now you are done!!! A printer using the name you entered in the third
point should now be available as a printer for all applications.
--
Best regards Jacob Tranholm
Karl R. Popper: Observation statements and statements of experimental
results are always interpretations of the facts observed.
-
Re: Compiling cups-pdf and Printing to File.
On Sat, 10 Nov 2007 23:32:13 +0100, Jacob Tranholm wrote:
> ohnjay skrev:
>
>>
>> Is it available in OpenOffice and Firefox?
>
> Yes... It is available for *all* applications.
>
> You also have to install the cups-pdf writer in cups. Perhaps you've
> forgotten this step. In simple steps this should be possible using the
> following commands (from firefox):
Didn't forget, just didn't know.
>
> 1) Connect to 'http://localhost:631/'
> 2) Select "Add Printer"
> 3) Write some name, description,...
> 4) For the device you select "CUPS-PDF (Virtual PDF Printer)"
> 5) And as PPD-file you select the provided "PostscriptColor.ppd"
> (at /usr/share/cups/model/PostscriptColor.ppd in your description and at
> /usr/share/ppd/cups-pdf/PostscriptColor.ppd in my description (created
> from deb-package))
> 6) Click "Add Printer" and enter your root username and password
> 7) Now you are done!!! A printer using the name you entered in the third
> point should now be available as a printer for all applications.
>
Yes,this worked perfectly. It is available in all programs that I have
tried, and is also visible in YAST -> Hardware -> Printer.
Thank you for your guidance, Jacob. Without it I would have wasted a
great deal of time looking in the wrong places. Where is this procedure
documented?
John
-
Re: Compiling cups-pdf and Printing to File.
ohnjay skrev:
>
> Yes,this worked perfectly. It is available in all programs that I have
> tried, and is also visible in YAST -> Hardware -> Printer.
>
> Thank you for your guidance, Jacob. Without it I would have wasted a
> great deal of time looking in the wrong places. Where is this procedure
> documented?
>
> John
You're welcome...
And I don't know where it is documented. I uninstalled my own cups-pdf
and wrote down the steps I used to reinstall. I have been using linux
since the spring of 1996 and the install procedure of cups have been the
same for some time. You can read most if it from
and fill in the gabs yourself.
--
Best regards Jacob Tranholm
Karl R. Popper: Observation statements and statements of experimental
results are always interpretations of the facts observed.