Mercurial > mxe-octave
annotate installer-files/cmdshell.bat @ 6177:4ba9eb3f70c9 release
* installer-files/cmdshell.bat, installer-files/octave-firsttime.vbs,
installer-files/octave-launch.c, installer-files/octave.bat,
installer-files/octave.vbs: add pkg config path env
author | John Donoghue <john.donoghue@ieee.org> |
---|---|
date | Tue, 19 Apr 2022 09:26:38 -0400 |
parents | 27b4f385c45d |
children |
rev | line source |
---|---|
3963
9d402d735dd1
nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents:
diff
changeset
|
1 @echo off |
9d402d735dd1
nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents:
diff
changeset
|
2 |
4062
57bc5d4ff660
cmdshell: use OCTAVE_HOME variable instead of OCT_HOME
John D
parents:
3963
diff
changeset
|
3 set OCTAVE_HOME=%~dp0 |
5459
f146714a73c3
* installer-files/cmdshell.bat: allow path set in .bat file ti teh transfers through to bash
John Donoghue <john.donoghue@ieee.org>
parents:
5301
diff
changeset
|
4 Rem NOTE: OCTAVE_HOME has a end \ |
4257
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
5 Rem convert to 8.3 format |
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
6 for %%I in ("%OCTAVE_HOME%") do set OCTAVE_HOME=%%~sI |
3963
9d402d735dd1
nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents:
diff
changeset
|
7 |
4257
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
8 Rem set home if not already set |
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
9 if "%HOME%"=="" set HOME=%USERPROFILE% |
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
10 if "%HOME%"=="" set HOME=%HOMEDRIVE%%HOMEPATH% |
3963
9d402d735dd1
nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents:
diff
changeset
|
11 |
4257
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
12 Rem set HOME to 8.3 format |
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
13 for %%I in ("%HOME%") do set HOME=%%~sI |
3963
9d402d735dd1
nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents:
diff
changeset
|
14 |
4793
202fa20cf559
add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents:
4472
diff
changeset
|
15 set MSYSDIR=%OCTAVE_HOME% |
202fa20cf559
add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents:
4472
diff
changeset
|
16 set MSYSTEM=MSYS |
202fa20cf559
add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents:
4472
diff
changeset
|
17 |
202fa20cf559
add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents:
4472
diff
changeset
|
18 Rem if no msys-1.0, must be msys2 |
5649
27b4f385c45d
cmdshell.bat: Use double-quotes to allow for spaces in path (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents:
5459
diff
changeset
|
19 if NOT EXIST "%OCTAVE_HOME%bin\msys-1.0.dll" set MSYSDIR=%OCTAVE_HOME%usr |
4257
8f71549f53b9
cmdshell: set HOME and OCTAVE_HOME without spaces (Bug #49765)
John D
parents:
4232
diff
changeset
|
20 |
4793
202fa20cf559
add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents:
4472
diff
changeset
|
21 Rem 32 or 64 bit |
5649
27b4f385c45d
cmdshell.bat: Use double-quotes to allow for spaces in path (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents:
5459
diff
changeset
|
22 if EXIST "%OCTAVE_HOME%mingw32\bin\octave-cli.exe" set MSYSTEM=MINGW32 |
27b4f385c45d
cmdshell.bat: Use double-quotes to allow for spaces in path (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents:
5459
diff
changeset
|
23 if EXIST "%OCTAVE_HOME%mingw64\bin\octave-cli.exe" set MSYSTEM=MINGW64 |
4793
202fa20cf559
add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents:
4472
diff
changeset
|
24 |
5649
27b4f385c45d
cmdshell.bat: Use double-quotes to allow for spaces in path (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents:
5459
diff
changeset
|
25 if EXIST "%OCTAVE_HOME%mingw32\bin\octave-cli.exe" set OCTAVE_HOME=%OCTAVE_HOME%mingw32\ |
27b4f385c45d
cmdshell.bat: Use double-quotes to allow for spaces in path (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents:
5459
diff
changeset
|
26 if EXIST "%OCTAVE_HOME%mingw64\bin\octave-cli.exe" set OCTAVE_HOME=%OCTAVE_HOME%mingw64\ |
4953
cbf69a7357d9
* installer-files/cmdshell.bat: fix OCTAVE_HOME and PATH when is using msys2 mingw32 or mingw64
John Donoghue
parents:
4793
diff
changeset
|
27 |
6177
4ba9eb3f70c9
* installer-files/cmdshell.bat, installer-files/octave-firsttime.vbs,
John Donoghue <john.donoghue@ieee.org>
parents:
5649
diff
changeset
|
28 Rem pkgconfig .pc path |
4ba9eb3f70c9
* installer-files/cmdshell.bat, installer-files/octave-firsttime.vbs,
John Donoghue <john.donoghue@ieee.org>
parents:
5649
diff
changeset
|
29 set PKG_CONFIG_PATH=%OCTAVE_HOME%\lib\pkgconfig |
4ba9eb3f70c9
* installer-files/cmdshell.bat, installer-files/octave-firsttime.vbs,
John Donoghue <john.donoghue@ieee.org>
parents:
5649
diff
changeset
|
30 |
4953
cbf69a7357d9
* installer-files/cmdshell.bat: fix OCTAVE_HOME and PATH when is using msys2 mingw32 or mingw64
John Donoghue
parents:
4793
diff
changeset
|
31 Rem Set up PATH. Make sure the octave bin dir |
cbf69a7357d9
* installer-files/cmdshell.bat: fix OCTAVE_HOME and PATH when is using msys2 mingw32 or mingw64
John Donoghue
parents:
4793
diff
changeset
|
32 Rem comes first. |
5301 | 33 set PATH=%OCTAVE_HOME%qt5\bin;%OCTAVE_HOME%bin;%OCTAVE_HOME%python;%PATH% |
4953
cbf69a7357d9
* installer-files/cmdshell.bat: fix OCTAVE_HOME and PATH when is using msys2 mingw32 or mingw64
John Donoghue
parents:
4793
diff
changeset
|
34 set TERM=cygwin |
cbf69a7357d9
* installer-files/cmdshell.bat: fix OCTAVE_HOME and PATH when is using msys2 mingw32 or mingw64
John Donoghue
parents:
4793
diff
changeset
|
35 set GS=gs.exe |
cbf69a7357d9
* installer-files/cmdshell.bat: fix OCTAVE_HOME and PATH when is using msys2 mingw32 or mingw64
John Donoghue
parents:
4793
diff
changeset
|
36 set GNUTERM=wxt |
cbf69a7357d9
* installer-files/cmdshell.bat: fix OCTAVE_HOME and PATH when is using msys2 mingw32 or mingw64
John Donoghue
parents:
4793
diff
changeset
|
37 |
5459
f146714a73c3
* installer-files/cmdshell.bat: allow path set in .bat file ti teh transfers through to bash
John Donoghue <john.donoghue@ieee.org>
parents:
5301
diff
changeset
|
38 Rem tell msys2 to use the paths we set here which matches what octave would do |
f146714a73c3
* installer-files/cmdshell.bat: allow path set in .bat file ti teh transfers through to bash
John Donoghue <john.donoghue@ieee.org>
parents:
5301
diff
changeset
|
39 set MSYS2_PATH_TYPE=inherit |
f146714a73c3
* installer-files/cmdshell.bat: allow path set in .bat file ti teh transfers through to bash
John Donoghue <john.donoghue@ieee.org>
parents:
5301
diff
changeset
|
40 |
5649
27b4f385c45d
cmdshell.bat: Use double-quotes to allow for spaces in path (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents:
5459
diff
changeset
|
41 "%MSYSDIR%\bin\bash.exe" --login -i |
4793
202fa20cf559
add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents:
4472
diff
changeset
|
42 |