Mercurial > mxe-octave
changeset 4183:cc549d1865cb
pstoedit: use GS environment var if set in windows
* src/pstoedit-5-use_gs_env.patch: new file
* installer-files/cmdshell.bat,
installer-files/octave-firsttime.vbs,
installer-files/octave.bat,
installer-files/octave.vbs: set GS env var to gs.exe
* dist-files.mk: added pstoedit-5-use_gs_env.patc
author | John D |
---|---|
date | Fri, 05 Aug 2016 21:24:58 -0400 |
parents | be6b10b6faf5 |
children | fc1bee8ff2d4 |
files | dist-files.mk installer-files/cmdshell.bat installer-files/octave-firsttime.vbs installer-files/octave.bat installer-files/octave.vbs src/pstoedit-5-use_gs_env.patch |
diffstat | 6 files changed, 28 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/dist-files.mk Fri Aug 05 21:24:57 2016 -0400 +++ b/dist-files.mk Fri Aug 05 21:24:58 2016 -0400 @@ -558,6 +558,7 @@ pstoedit-2-gs.patch \ pstoedit-3-nosecapi.patch \ pstoedit-4-winlibemf.patch \ + pstoedit-5-use_gs_env.patch \ pstoedit.mk \ pthread-stubs.mk \ pthreads-test.c \
--- a/installer-files/cmdshell.bat Fri Aug 05 21:24:57 2016 -0400 +++ b/installer-files/cmdshell.bat Fri Aug 05 21:24:58 2016 -0400 @@ -7,6 +7,7 @@ set PATH=%OCTAVE_HOME%bin;%PATH% set TERM=cygwin +set GS=gs.exe %OCTAVE_HOME%\bin\bash.exe
--- a/installer-files/octave-firsttime.vbs Fri Aug 05 21:24:57 2016 -0400 +++ b/installer-files/octave-firsttime.vbs Fri Aug 05 21:24:58 2016 -0400 @@ -13,6 +13,9 @@ ' set terminal type wshSystemEnv("TERM") = "cygwin" +wshSystemEnv("GNUTERM") = "windows" + +wshSystemEnv("GS") = "gs.exe" ' set Qt plugin directory wshSystemEnv("QT_PLUGIN_PATH") = OctavePath & "\plugins"
--- a/installer-files/octave.bat Fri Aug 05 21:24:57 2016 -0400 +++ b/installer-files/octave.bat Fri Aug 05 21:24:58 2016 -0400 @@ -15,6 +15,7 @@ set TERM=cygwin set GNUTERM=windows +set GS=gs.exe Rem Check for args to see if we are told to start GUI Rem with the --force-gui option or not (--no-gui)
--- a/installer-files/octave.vbs Fri Aug 05 21:24:57 2016 -0400 +++ b/installer-files/octave.vbs Fri Aug 05 21:24:58 2016 -0400 @@ -15,6 +15,8 @@ wshSystemEnv("TERM") = "cygwin" wshSystemEnv("GNUTERM") = "windows" +wshSystemEnv("GS") = "gs.exe" + ' set Qt plugin directory wshSystemEnv("QT_PLUGIN_PATH") = OctavePath & "\plugins"
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/pstoedit-5-use_gs_env.patch Fri Aug 05 21:24:58 2016 -0400 @@ -0,0 +1,20 @@ +diff -ur pstoedit-3.70.orig/src/callgs.cpp pstoedit-3.70/src/callgs.cpp +--- pstoedit-3.70.orig/src/callgs.cpp 2016-07-27 13:04:53.173499210 -0400 ++++ pstoedit-3.70/src/callgs.cpp 2016-07-27 13:56:54.686649091 -0400 +@@ -364,7 +364,15 @@ + } else { + if (verbose) errstream<< "nothing found in gsview32.ini file - using find_gs to lookup latest version of Ghostscript in registry " << endl; + static char buf[1000]; +- if (find_gs(buf, sizeof(buf), 550 /* min ver*/ , getPstoeditsetDLLUsage() , gsregbase)) { ++ ++ ++ gstocall = getenv("GS"); ++ ++ if(gstocall) { ++ if (verbose) ++ errstream << "GS is set to:" << gstocall << endl; ++ ++ } else if (find_gs(buf, sizeof(buf), 550 /* min ver*/ , getPstoeditsetDLLUsage() , gsregbase)) { + if (verbose) { + (void)dumpgsvers(gsregbase); + if (getPstoeditsetDLLUsage()) errstream << "Latest GS DLL is " << buf << endl;