1 Crosscompiling Maxima for Windows
2 =================================
4 On a Ubuntu/Debian System just install some tools for crosscompiling:
6 apt-get install g++-mingw-w64-i686 cmake nsis wine automake texinfo texlive texlive-plain-generic texlive-xetex rsync p7zip-full g++ gettext tcl pandoc po4a
8 (If you are using a 64 bit operating system, it might be necessary to add
9 the i386 architecture (https://wiki.debian.org/Multiarch/HOWTO) before).
10 If you want a 64Bit installer, install the compiler g++-mingw-w64-x86-64.
12 You will need CMake >= 3.7, if that is not included in your distribution,
13 download a recent CMake from https://cmake.org/files/
15 Then you can extract the Maxima sourcecode or clone the git repository
16 and start the crosscompiling-process:
18 mkdir crosscompile-windows/build
19 cd crosscompile-windows/build # change to the build directory
20 cmake .. # use the right CMake executable (CMake >= 3.7)
24 The build directory should be called "build", because the Maxima code
25 is copied during the build and this directory will be excluded.
27 This will download the required Software (CLISP, SBCL, Gnuplot, wxMaxima,
28 wxWidgets, Tcl, Tk, VTK) from the Internet into the directory
29 "crosscompile-windows/download".
31 The packages will be compiled (if necessary) and a Windows
32 installer for Maxima is generated.
34 This should work (at least) on Ubuntu and Debian (I hope on other
35 Linux-Distributions too...).
36 (if you want you may even omit the first "make")
38 Instead of "make clean" just remove everything in the build directory.
40 If you want to use the current wxMaxima development version, you can use
41 cmake -DUSE_WXMAXIMA_GIT=YES ..
43 If you want to exclude VTK, use
45 (The size of the installer with VTK will approximately be 50% larger
48 One can also include ABCL - a Java based lisp compiler - with the option
50 Of course you will need a java installation.
52 If you want to change the default Lisp, which will be used, you can
53 use the option "-DWITH_DEFAULT_LISP=sbcl" in the cmake call (otherwise
54 Clisp would be the default).
57 In case a new release of a software is released (and no new patches are needed),
58 it should be sufficient to just increase the version number and MD5-checksum
59 for the new release in CMakeLists.txt.
62 Building a 64 bit installer
63 ===========================
65 By default a 32 bit installer (which works on 32 and 64 bit Windows) will be
66 generated. If you want to crosscompile a 64 bit installer, install the 64 bit
67 crosscompiler package (g++-mingw-w64-x86-64) and a recent 64 bit 'wine'.
68 (see https://www.winehq.org/download how to get a development version
69 for your Linux distribution). For the 64bit crosscompiliation procedure wine64
70 will be searched in /opt/wine-devel - where the packages from the wine team
71 will install their packages.
73 Then use the following commands to build a 64 bit installer:
74 cmake -DBUILD_64BIT=YES ..
79 Installing the package
80 ======================
82 Of course just by double-clicking/executing the generated EXE on
83 Windows. This Maxima installer installs into C:\maxima-VERSION,
84 changing this directory is not recommended (because special characters
85 or foreign language characters might cause problems).
87 If you want to do an *unattended* installation (e.g. if you plan to
88 install Maxima on many computers in a school, university or company),
89 this installer (and uninstaller) understands the command line switch
90 "/S" (for 'silent install').
92 To select a installation directory for a unattended installation, use
93 "/D=directory", e.g. to install to C:\maxima the command would be:
94 maxima-clisp-sbcl-VERSION-win32.exe /S /D=C:\maxima
95 This parameter must be the last one.
97 The installer supports components, you can deselect (by default a full
98 installation is done) some parts either during the installation process
99 or using the command line switches:
100 - VTK using the command line option /no_vtk
101 - Gnuplot using /no_gnuplot (installation is strongly recommended!)
102 - wxMaxima using /no_wxmaxima (installation is strongly recommended!)
104 These switches are mainly useful for an unattended installation.
107 Testing the installed package:
108 ==============================
110 After building it, you can (and should) test the new Maxima installation
111 package. Install it on Windows and check that the installation (and later
112 the deinstallation) works properly. To test Maxima, try the following:
114 o Run the maxima testsuite: run_testsuite();
115 o Try compiling a function. This has been a problem in the past
119 o Test the graphics systems in both xmaxima and wxmaxima
120 plot2d(sin(x),[x,0,10]);
121 plot2d(sin(x),[x,0,10],[plot_format,xmaxima]);
122 plot3d(x*y,[x,-1,1],[y,-1,1]);
123 plotdf([-y,x],[trajectory_at,5,0]);
125 draw3d(xu_grid = 30, yv_grid = 60, surface_hide = true,
126 parametric_surface(cos(phi) * sin(theta),
127 sin(phi) * sin(theta),
129 theta, 0, %pi, phi, 0, 2 * %pi))$
130 o Check that plotting to Postscript works
131 plot2d(sin(x),[x,0,10],[ps_file,"ps_test.ps"]);
132 o Try out the on-line help: describe(sin);
133 o Try out, if external packages (e.g. lapack) work:
136 M : matrix ([9.5, 1.75], [3.25, 10.45]);
139 should return the eigenvalues of M (and false, false since we did
140 not compute eigenvectors: [[7.54331, 12.4067], false, false]
142 o Try if double-clicking on a .wxmx file opens it
143 o The wxMaxima source comes with a file (test/testbench_simple.wxmx)
144 that tries to trigger everything that has gone wrong in previous
145 wxMaxima builds. They include the commands that will test the
146 graphics system in the next step.
147 Open that file and then select "Cells/Evaluate all cells" in this
148 file and check if the file is processed correctly.
151 Further development / TODO:
152 ===========================
154 More packages could be included in the Windows installer.
156 - Userinterface: Emacs maxima/imaxima mode:
157 Should be rather easy, there are Windows zip files which could be included.
158 But the size of the Maxima installer would be *much* larger.
159 (Discussion on the Maxima mailing list (2020-02-28), that that does not
161 Users should install Emacs / Miktex(or Texlive) by themselves, if they want
162 to use that interface).
163 - Userinterface Climaxima (https://github.com/lokedhs/maxima-client):
164 Might be possible, but many dependencies, which must be crosscompiled.
165 - rlwrap (https://github.com/hanslub42/rlwrap):
166 would provide readline features (advanced command line editing) for
167 command line Maxima, when using SBCL or ABCL (CLISP already supports this).
168 Dependencies: readline and that requires either termcap or ncurses
169 (and neither termcap nor ncurses can be crosscompiled here...)
170 - Other Lisp versions:
171 Must have a Windows port or be crosscompileable and be usable in Wine.
172 I tried other Lisps, but currently only CLISP, SBCL and ABCL work.
173 And including many more Lisp versions might confuse ordinary users.