Author Topic: Printing problems with GSView 5.0 and Ghostscript 9.15  (Read 12425 times)

Thomas Hellsén

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
  • Electronics engineer & OS2/eCS user
    • View Profile
Printing problems with GSView 5.0 and Ghostscript 9.15
« on: January 05, 2015, 12:23:21 am »
Hi all,
I'm having problems with printing in GSView 5.0. I have Ghostscript 8.63 and 9.15 installed and they can both be run standalone, though I haven't tried printing directly from them. If I configure GSView for gs 9.15 I can load and display a PDF file, but when I try to print, I get the following error message in the popup "GSView Print" box:

GPL Ghostscript 9.15 (2014-09-22)
Copyright (C) 2014 Artifex Software, Inc.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
Unknown device: pswrite
Unrecoverable error: syntaxerror in --nostringval--
Operand stack:
    defaultdevice
Unrecoverable error: undefined in .uninstallpagedevice
Operand stack:
    defaultdevice
gsapi_exit returns 0
DosFreeModule returns 12

Now I think I have followed Paul's instructions in the readme.os2 file about configuring GSView:
In GSView Advanced configuration, I have set the include path to

D:\APPS\GS\gs9.15\lib;D:\APPS\GS\gs9.15\Resource\init;D:\APPS\GS\gs9.15\Resource\font;D:\APPS\GS\fonts;E:\PSFONTS;E:\TTFONTS;

where D:\APPS\gs is the Ghostscript & GSView common directory. Also, in E:\OS2\gvpm.ini I have changed all occurrences of the device "pswrite" to "ps2write". This does not seem to help, since the "pswrite" device is still called, as seen from the error message above. This is when I select the tick box "Postscript printer" when printing. It would seem like the "pswrite" device is hardcoded into GSView.
If I instead leave the "Postscript printer" box unticked and manually select the "ps2write" device and try to print, I get the following error message in the printing status box:

GPL Ghostscript 9.15 (2014-09-22)
Copyright (C) 2014 Artifex Software, Inc.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
GPL Ghostscript 9.15: **** Could not open the file \\spool\E312PS .
**** Unable to open the initial device, quitting.
GPL Ghostscript 9.15: **** Could not open the file \\spool\E312PS .
Unrecoverable error: ioerror in setpagedevice
Operand stack:
    true  --nostringval--  --nostringval--  --nostringval--  --nostringval--  --nostringval--  --nostringval--  --nostringval--  --nostringval--
gsapi_exit returns 0
DosFreeModule returns 12

I have no real idea what this means. E312PS is the name of my Postscript printer in eCS 2.1. If I use GhostScript 8.63 instead of 9.15, it prints the following in the printing status box, and printing succeeds:

GPL Ghostscript 8.63 (2008-08-01)
Copyright (C) 2008 Artifex Software, Inc.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
GPL Ghostscript 8.63: **** Could not open the file \\spool\E312PS .
page 1

So I guess my questions are these:
1) Why does Ghostscript 9.15 refuse printing because it can't open the file \\spool\E312PS, while 8.63 works?
2) What is the \\spool\E312PS file, and can I add it to my system so that 9.15 can work? I assume it is part of the printer queue somehow but don't understand exactly how.
3) Any other useful comments...

Best regards, Thomas Hellsén
/Thomas Hellsén

ivan

  • Hero Member
  • *****
  • Posts: 1561
  • Karma: +18/-0
    • View Profile
Re: Printing problems with GSView 5.0 and Ghostscript 9.15
« Reply #1 on: January 05, 2015, 01:15:14 am »
A couple of questions.
1) Have you setup the printer correctly and can print using other programs without problems?
2) Have you also edited the printer ini in the gsview2 dir?
3) When you removed the pswrite entries did you also edit the ps2write entries to make them viable ie. giving defined values in place of [Not defined]?
4) Is there an empty directory named E312PS in the spool directory (maybe in var\spool on eCS) ?  If there isn't then the printer has not been setup correctly.
 

Paul Smedley

  • Hero Member
  • *****
  • Posts: 2095
  • Karma: +160/-0
    • View Profile
Re: Printing problems with GSView 5.0 and Ghostscript 9.15
« Reply #2 on: January 05, 2015, 06:07:22 am »
Hi,

There is some more information at http://mantis.smedley.id.au/view.php?id=627

Thomas Hellsén

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
  • Electronics engineer & OS2/eCS user
    • View Profile
Re: Printing problems with GSView 5.0 and Ghostscript 9.15
« Reply #3 on: January 05, 2015, 04:42:39 pm »
Hi Ivan,
1) Yes, printing from other applications works pretty well except for the usual trouble with the Lexmark E312 drivers, namely that printing to E312 PS from modern applications like OpenOffice and Seamonkey does not work while printing to E312 PCL works and some PDF files won't print correctly using Lucide (this is the reason I ran into the GSView problems, I usually use Lucide for PDF). Printing from "old" applications such as Clearlook, Mesa2 and StarOffice 5.1 works well. These are issues I've learned to work around.
2) Yes, as per Paul's instructions I've changed all instances of "pswrite" to "ps2write". I also changed one of the first lines in the file, namely
GhostscriptEXE=D:\APPS\GS\gs7.04\bin\gsos2.exe
to read
GhostscriptEXE=D:\APPS\GS\gs9.15\bin\gsos2.exe
The first appearance of the line is directly from GSView 5.0 install, even though I have no gs 7.04 on my system. Changing the line does not seem to produce any effect, and I have wondered what its purpose is.
3) Well they read as the "pswrite" entries before them since I only changed "pswrite" to "ps2write".
4) Yes, the directories in \var\SPOOL\ are there for each printer.

/Thomas
/Thomas Hellsén

Thomas Hellsén

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
  • Electronics engineer & OS2/eCS user
    • View Profile
Re: Printing problems with GSView 5.0 and Ghostscript 9.15
« Reply #4 on: January 05, 2015, 04:44:34 pm »
Hi Paul,
My experiences parallel the ones in ticket 627 pretty exactly, except I never tried gs 9.14 so wasn't affected by the cups17.dll missing. When I tested gs 9.15 (gsos2.exe) by itself, it complained about gcc491 missing. This was easily fixed by downloading your gcc 4.9.1 and extracting the gcc491.dll to a directory in the LIBPATH.

The discussion in ticket 627 contains two for me useful tips, thanks for the pointer:
a) Print to file using ps2write.
b) Printing works with gs 9.04.
With 9.04, the message "Could not open the file \\spool\E312PS" is still there but apparently does not affect printing. The spooler is active (E:\OS2\PMSPOOL.EXE) so I suppose that's not the problem. The double backslash suggests that \\SPOOL is some form of system device but I don't know enough about those things to have any intelligent guesses as to what Ghostscript wants.

Best regards
/Thomas Hellsén