All the sources are delivered in an archive containing an SRC directory and several levels of sub-directories. The sources of the program are delivered with different Makefiles and BASH or BAT scripts that can be used for the compilation of the different targets:
The makefiles must be used with the GNU “make” command. This means that on Windows OS, you should install the corresponding binaries. “MSYS” is used for several UNIX commands, and have tested different versions of the GNU C/C++ compilers downloaded with different versions of “MINGW”. The compilation has also been tested with different versions of Microsoft Visual C++ compiler.
The “BASH” and “BAT” scripts are located in the “SRC” main directory. “BAT” scripts are used for the compilation on Windows OS, and “BASH” scripts on LINUX. These scripts define part of the compilation environment, and you may have to modify them if you want to recompile the sources.
The main Makefiles are located in “SRC/MAKEFILES” directory. They include sub-makefiles located in the “SRC/MAKEFILES” directory and in the sources sub-directories. The Makefiles in “SRC/MAKEFILES” directory also define part of the compilation environment and will have to be adapted in order to re-compile the sources. These adaptations consist mainly in modifying paths to match installation on your computer. (Ruby installation directory, for example.)
The makefiles in source directories are built automatically. You just have to ask for the building of “dependences” target. For example,you type the command “build_mingw32.bat dependences”. (You do not need to do this if you do not modify the sources.)
The association of script commands, makefiles and targets is summarized in Table X.A.1. Besides, several targets are also defined that do not depend on the platform:
“clean” cleans all the objects, libraries and other files produced by the compiler command.
“dependences” produces or updates the makefiles in the source directories.
“ruby” to build all the ruby extensions available in the Makefile.
“python” to build all the python extensions available in the Makefile.
“com” to build the COM component.
“archives” creates a 7Zip archive of the “OUTPUTS” directory.
“outputs” produces all the libraries in other outputs in “OUTPUTS” directory, and then builds the “archive”
Some targets are specific to the .NET assembly compilation:
“signkey” for the update of the assembly signature.
“install” to install the assembly in the Global Assembly Cache (GAC).
On Windows OS, the compilation of python extension is possible with the MSVC compilers (“build_python_msvc32.bat” and “build_python_msvc64.bat” scripts) or with GNU compiler (“build_mingw32.bat” and “build_mingw64.bat” scripts). It is advisable to use the GNU compilers as it allows to build all the 32-bits python extensions with a single version of the compiler.
Examples of builds follow:
build_linux32.bash ruby build_linux32.bash ruby_23 build_linux32.bash outputs build_mingw64.bat com build_mingw64.bat ruby build_mingw64.bat outputs build_python_27.bat buildbuild_python_win32 buildbuild_python_win64 ...
Note: for 32-bit version 2.4.* of ruby, the “include/ruby/ruby.h” has been slightly modified: “DEPRECATE_BY” lines 1381 and 1390 have been commented. Otherwise, the compilation resulted in error messages. This has been done on Windows and on Linux.
| SCRIPT | main Makefile | targets |
| build_linux32.bash | Makefile.LINUX_586 | ruby_31, ruby_30, ruby_27, ruby_26, ruby_25, ruby_24, ruby_23, ruby_22, ruby_21, ruby_20, ruby_19, ruby_18, python_26, python_27, python_30, python_31, python_32, python_33, python_34, python_35, python_36, python_37, python_38, python_39, python_310, python_311, python_312, python_313, develop |
| build_linux64.bash | Makefile.LINUX_I64 | ruby_34, ruby_33, ruby_32, ruby_31, ruby_30, ruby_27, ruby_26, ruby_25, ruby_24, ruby_23, ruby_22, ruby_21, ruby_20, ruby_19, ruby_18, python_26, python_27, python_30, python_31, python_32, python_33, python_34, python_36, python_37, python_38, python_39, python_310, python_311, python_312, python_313, develop |
| build_mingw32.bat | Makefile.WIN.32 | com, ruby_27, ruby_26, ruby_25, ruby_24, ruby_22, ruby_21, ruby_20, ruby_19, ruby_18, develop, python_26, python_27, python_30, python_31, python_32, python_33, python_34, python_35, python_36, python_37, python_38, python_39 |
| build_mingw32_345.bat | Makefile.WIN.32
(345 targets) HDF5 unsupported | com, ruby_23, ruby_22, ruby_21, ruby_20, ruby_19, ruby_18, develop, python_26, python_27, python_30, python_31, python_32, python_33, python_34, python_35, python_36, python_37, python_38, python_39 |
| build_mingw64.bat | Makefile.WIN.64 | com, ruby_34, ruby_33, ruby_32, ruby_31, ruby_30, ruby_27, ruby_26, ruby_25, ruby_24, ruby_23, ruby_22, ruby_21, ruby_20, develop, python_30, python_31, python_32, python_33, python_34, python_35, python_36, python_37, python_38, python_39, python_310, python_311, python_312, python_313 |
| build_net.bat | Makefile.NET | net |
| build_msvc_x86.bat | Makefile.MSVC_X86 | com, ruby, python, develop (for debugging the sources) |
| build_msvc_x64.bat | Makefile.MSVC_X64 | com, ruby, python, develop (for debugging the sources) |
| build_intel.bat | Makefile.INTEL.X64 | com, python, develop (for debugging the sources) |