In my application I want to merge PDF’s with Ghostscript using the windows console. So I make a system() call to cmd.exe.
I call Ghostscript like that:
gswin64c.exe -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=o.pdf i1.pdf i2.pdf
I was wondering if I can just use the bin folder of the Ghostscript installation to deploy it with my application. Meaning just copying gswin64c.exe and gsdll64.dll with my application.
Or do I have to install Ghostscript on every computer I use it?
I copied this 2 files to another computer and it seemed to worked.
In other words:
Is the Ghostscript installation doing anything that I need for merging PDF’s in my app?
When you install Ghostscript it will (generally) try to locate fonts on the system and set them up for use by Ghostscript. If you don’t do that then it won’t be able to use those fonts.
More to the point, I think you will be in violation of the GPL if you don’t distribute Ghostscript ‘as is’ including all support files and copyright notices. Presumably you want to be compliant with the GPL or you will need to approach Artifex for a commercial licence.