# HG changeset patch # User John D # Date 1481009278 18000 # Node ID a45374f7d9a33321ea10c8ef073e8fb40c152fc6 # Parent 8f71549f53b9eb0666f02910df3584c47f796880 Use 8.3 format for octave path * installer-files/octave-firsttime.vbs: convert OctavePath to shortpath * installer-files/octave.vbs: convert OctavePath to shortpath * installer-files/octave.bat: convert OCT_HOME to 8.3 path * tools/makeinst-script.sh.in: call pkg rbuild and fc_cache with 8.3 pathname diff -r 8f71549f53b9 -r a45374f7d9a3 installer-files/octave-firsttime.vbs --- a/installer-files/octave-firsttime.vbs Mon Dec 05 17:46:56 2016 -0500 +++ b/installer-files/octave-firsttime.vbs Tue Dec 06 02:27:58 2016 -0500 @@ -5,6 +5,10 @@ ' get the directory that script resides in Set fso = CreateObject("Scripting.FileSystemObject") OctavePath = fso.GetParentFolderName(WScript.ScriptFullName) +' get path as a 8.3 path +Set fo = fso.GetFolder(OctavePath) +OctavePath = fo.ShortPath +Set fo = Nothing Set fso = Nothing ' set up path to ensure octave bin comes first diff -r 8f71549f53b9 -r a45374f7d9a3 installer-files/octave.bat --- a/installer-files/octave.bat Mon Dec 05 17:46:56 2016 -0500 +++ b/installer-files/octave.bat Tue Dec 06 02:27:58 2016 -0500 @@ -5,6 +5,8 @@ Rem This trick finds the location where the batch file resides. Rem Note: the result ends with a backslash set OCT_HOME=%~dp0 +Rem Coonvert to 8.3 format so dont have to worry about spaces +for %%I in ("%OCT_HOME%") do set OCT_HOME=%%~sI Rem Set up PATH. Make sure the octave bin dir Rem comes first. diff -r 8f71549f53b9 -r a45374f7d9a3 installer-files/octave.vbs --- a/installer-files/octave.vbs Mon Dec 05 17:46:56 2016 -0500 +++ b/installer-files/octave.vbs Tue Dec 06 02:27:58 2016 -0500 @@ -5,6 +5,10 @@ ' get the directory that script resides in Set fso = CreateObject("Scripting.FileSystemObject") OctavePath = fso.GetParentFolderName(WScript.ScriptFullName) +' get path as a 8.3 path +Set fo = fso.GetFolder(OctavePath) +OctavePath = fo.ShortPath +Set fo = Nothing Set fso = Nothing ' set up path to ensure octave bin comes first diff -r 8f71549f53b9 -r a45374f7d9a3 tools/makeinst-script.sh.in --- a/tools/makeinst-script.sh.in Mon Dec 05 17:46:56 2016 -0500 +++ b/tools/makeinst-script.sh.in Tue Dec 06 02:27:58 2016 -0500 @@ -255,8 +255,9 @@ Pop \$0 ; run fc-cache updater + GetFullPathName /SHORT \$1 \$INSTDIR DetailPrint "Building font cache (may take a while)" - ExecWait "\$INSTDIR\\fc_update.bat" + ExecWait "\$1\\fc_update.bat" SectionEnd Section make_uninstaller @@ -344,8 +345,9 @@ Section "InstallPackages" ; fix the installed packages (if any) - SetOutPath "\$INSTDIR" - ExecWait '"\$INSTDIR\\bin\\octave-cli.exe" --no-gui -W -H -f -q --eval "pkg rebuild"' \$0 + GetFullPathName /SHORT \$1 \$INSTDIR + SetOutPath "\$1" + ExecWait '"\$1\\bin\\octave-cli.exe" --no-gui -W -H -f -q --eval "pkg rebuild"' \$0 SectionEnd Section "Uninstall"