1,852
edits
(Remove redundant information. Use https.) |
(Some reorganization.) |
||
Line 9: | Line 9: | ||
# [http://wiki.octave.org/Windows_Installer#Installing_requirements_of_MXE_Octave Install all requirements of MXE Octave]. | # [http://wiki.octave.org/Windows_Installer#Installing_requirements_of_MXE_Octave Install all requirements of MXE Octave]. | ||
# <code>hg clone https://hg.octave.org/mxe-octave</code> | # <code>hg clone https://hg.octave.org/mxe-octave</code><ref>Use <code>hg clone https://hg.octave.org/mxe-octave <name of mxe-octave build dir></code> to choose another directory.</ref> | ||
# <code>cd mxe-octave</code> | # <code>cd mxe-octave</code> | ||
# <code>./bootstrap</code> | # <code>./bootstrap</code> | ||
Line 15: | Line 15: | ||
# <code>make all nsis-installer</code> | # <code>make all nsis-installer</code> | ||
=== | ===Step details=== | ||
====<code>./configure</code>==== | |||
The current Windows installers are build in three "flavors": for common 64- and 32-bit systems ('''"w64"''' and '''"w32"''') and for 64-bit systems exceeding 32 GB of main memory to store large data structures ('''"w64-64"'''). | |||
{| class="wikitable" | {| class="wikitable" | ||
Line 78: | Line 58: | ||
* <code>--enable-devel-tools</code>: Include gdb and an MSYS shell in the binary. | * <code>--enable-devel-tools</code>: Include gdb and an MSYS shell in the binary. | ||
** If you seriously want to work with gdb, you need <code>--disable-strip-dist-files</code> as configure option, | ** If you seriously want to work with gdb, you need <code>--disable-strip-dist-files</code> as configure option to keep debug symbols in the installed binaries for debugging on Windows. Beware as the total Octave distribution will be > 2 GB, the max. size for an NSIS installer. Your only options are to make 7z-dist, zip-dist or tar-dist installers. | ||
* <code>--enable-binary-packages</code>: Cross-compile binary modules in [[Octave Forge]] packages. This saves time when installing them once the installation runs on Microsoft Windows. | * <code>--enable-binary-packages</code>: Cross-compile binary modules in [[Octave Forge]] packages. This saves time when installing them once the installation runs on Microsoft Windows. | ||
* <code>--with-ccache</code>: The usage of [https://ccache.dev/ ccache] may speed up repetitive compilation drastically. | * <code>--with-ccache</code>: The usage of [https://ccache.dev/ ccache] may speed up repetitive compilation drastically. | ||
Line 89: | Line 69: | ||
* <code>--enable-fortran-int64</code>: Use 64-bit integers in Fortran code and especially in numerical library code. | * <code>--enable-fortran-int64</code>: Use 64-bit integers in Fortran code and especially in numerical library code. | ||
====<code>make</code>==== | |||
* Use <code>make all 7z-dist</code>, <code>make all tar-dist</code> or <code>make all zip-dist</code> instead of <code>make all nsis-installer</code> if you want to build just an archive of the files to install on Windows instead of an installer wizard. | |||
* By default, packages will be built one at a time, but you may use <code>make JOBS=4</code> (choose a number other than 4 that is appropriate for your system) to build each package in parallel. You may also combine this with the <code>-j</code> option for Make to build more than one package at a time, but be careful as using <code>make -j4 JOBS=4</code> can result in as many as 16 jobs running at once. | |||
* Include gdb in the installer by running <code>make gdb</code> before making the <code>nsis-installer</code> target. | |||
=== | ===Build Octave-for Windows development versions=== | ||
* build Octave on Linux (in separate source and build trees) including your favorite mods and patches. | * build Octave on Linux (in separate source and build trees) including your favorite mods and patches. | ||
* once Octave runs fine in Linux (using make check and trying your mods using ./run-octave --gui & from the build dir, all of this still on the Linux side), do: | * once Octave runs fine in Linux (using make check and trying your mods using ./run-octave --gui & from the build dir, all of this still on the Linux side), do: | ||
Line 108: | Line 87: | ||
This archive is always slightly behind the latest development branch of the source repository and is missing the metadata that indicates which Mercurial revision it was built from.}} | This archive is always slightly behind the latest development branch of the source repository and is missing the metadata that indicates which Mercurial revision it was built from.}} | ||
====Step 3A (second and later builds)==== | ====Step 3A (second and later builds)==== | ||
For next builds, mxe-octave is already configured and all dependencies have been built so the only thing to do is having a new Octave version + installer built: | For next builds, mxe-octave is already configured and all dependencies have been built so the only thing to do is having a new Octave version + installer built: | ||
Line 138: | Line 110: | ||
* However, do not keep mxe-octave build dirs for too long. I'd suggest to wipe a build dir after at most two or three months and start over with a fresh clone a la Step 1. | * However, do not keep mxe-octave build dirs for too long. I'd suggest to wipe a build dir after at most two or three months and start over with a fresh clone a la Step 1. | ||
* In the mean time, regularly clean up <mxe-octave build>/log to save disk space. After a first successful build there's no more use for the log subdirs for each package, so you can wipe them all. | * In the mean time, regularly clean up <mxe-octave build>/log to save disk space. After a first successful build there's no more use for the log subdirs for each package, so you can wipe them all. | ||
It can happen that you meet problems with Java. To build Octave with Java support built-in, mxe-octave needs: | |||
* A Java JDK (Java Development Kit) on the '''host''' system. IOW, the javac (Java compiler) and jar (Java archiver) executables should be in the PATH. | |||
* Java include files for windows (win32, even for w64 builds). They should reside in "<mxe-octave build dir>/usr/x86_64-w64-mingw32/include/java/win32". If not present, mxe-octave downloads them but this can occasionally go wrong. On a multi-boot system a solution (note: dirty hack warning!) is symlinking to the Windows include files on the Windows partition from the mxe-octave location. | |||
====If things go wrong==== | ====If things go wrong==== | ||
Line 274: | Line 250: | ||
* The image expires after 90 days. But if you make a VirtualBox snapshot it will last longer, and you don't need to uninstall Octave each time before installing a new build. | * The image expires after 90 days. But if you make a VirtualBox snapshot it will last longer, and you don't need to uninstall Octave each time before installing a new build. | ||
==Footnotes== | |||
<references/> | |||
[[Category:Packaging]] | [[Category:Packaging]] |