[Info-vax] GS convert PDF to PS.
Jan-Erik Söderholm
jan-erik.soderholm at telia.com
Sun Mar 13 11:40:59 EDT 2022
Den 2022-03-13 kl. 16:25, skrev Chris Townley:
> On 13/03/2022 15:13, Jan-Erik Söderholm wrote:
>> Hi.
>>
>> I'm new to Ghostscript.
>> I try to convert a PDF file to a PS file.
>>
>> And yes, this a step in the "print a PDF file" project.
>> I had some issues with getting the Xerox printer to print
>> a plain PDF file so I thought about converting i to to PS...
>>
>> Have tried with:
>>
>> $ gs "-dNOPAUSE" "-sDEVICE=ps2write" "-sOutputFile=out.ps" "-fOUT.PDF"
>>
>> The input file OUT.PDF only contains one page with 6-7 text lines
>> and one Code128 barcode. File created from the Python tool Reportlab.
>> And "out" refers to the Python step, it is the "input" file to GS.
>>
>> The PDf file opens fine on any other environment, also when put in
>> a VMS directory served by WASD.
>>
>> I have checked that the file org is as required by GS:
>>
>> Record format: Stream_LF, maximum 0 bytes, longest 16384 bytes
>> Record attributes: Carriage return carriage control
>>
>>
>> GS just hangs and consumes 100% cpu until I end it with ctrl-C.
>> Does it wait for some SYS$INPUT input? Any switch I'm missing?
>>
>> $ gs "-dNOPAUSE" "-sDEVICE=ps2write" "-sOutputFile=out.ps" "-fOUT.PDF"
>> GPL Ghostscript 9.55.0 (2021-09-27)
>> Copyright (C) 2021 Artifex Software, Inc. All rights reserved.
>> This software is supplied under the GNU AGPLv3 and comes with NO WARRANTY:
>> see the file COPYING for details.
>> HV04JES_01 16:01:48 GS CPU=00:04:01.95 PF=48109 IO=152495 MEM=1369
>> HV04JES_01 16:01:51 GS CPU=00:04:04.56 PF=48109 IO=152496 MEM=1369
>> HV04JES_01 16:01:53 GS CPU=00:04:06.37 PF=48109 IO=152497 MEM=1369
>> Interrupt
>>
>> $
>>
>> One empty OUT.PS file is created and some empty TMPDIR files.
>>
>> _TEMP_T45404.;1 1/52 13-MAR-2022 16:01:45.84
>> _TEMP_U45404.;1 0/0 13-MAR-2022 16:01:45.85
>> _TEMP_V45404.;1 0/0 13-MAR-2022 16:01:45.85
>> _TEMP_W45404.;1 0/0 13-MAR-2022 16:01:45.85
>>
>> Any ideas? Some simple example for a GS command line to convert
>> a PDF file to a PS file?
>>
>> Best Regards,
>>
>> Jan-Erik.
>>
> When I used GS in the past, ISTR there were command files ps2pdf.com &
> pdf2ps.com (or maybe PDFTO PS.COM) in the distribution
>
>
> Chris
>
Aha OK. I just picket the reasently published kit from M Barryman.
That one only has these files:
2022-03-12 14:49 1 620 aaa_readme.txt
2022-03-12 14:49 18 362 Fontmap.VMS
2022-03-12 14:49 34 507 776 GS.exe_alpha
2022-03-12 14:49 50 638 336 GS.exe_ia64
2022-03-12 14:49 46 333 952 GS.exe_x86_64
2022-03-12 14:49 2 177 showfonts.ps
I just copied GS.exe_alpha and tried. Later added the two
Fontmap.VMS and showfonts.ps into same directoy, no change.
Symbol GS is setup like this:
$ sh sym gs
GS == "$UTIL:[GHOSTSCRIPT]GS.EXE_ALPHA"
$
A copy of that pdf2ps.com would be nice, if someone happens to have that.
Regards.
Jan-Erik.
More information about the Info-vax
mailing list