🚀 msvc-pkg offer you the scripts and following features to build all libraries from sources:
- No need to install Cygwin or MSYS2, but let you still can compile autotools based libraries on Git for Windows.
- Each build process of libraries have a rich colorful and meaningful terminal and save logging files separately.
- No need to install IDE, but only those Dependencies which can be installed automatically when run mpt in windows terminal.
- Use MSVC or MSVC-like toolsets for native build on Windows, i.e. without using MinGW.
- Build all dependencies on neccessary when build a library.
- Each dependencies for a library have a nice tree view on terminal
- Set up independent build process for each libraries, which is more convenience for Win32 and Bash environment build.
- and etc.
- Visual C++ Build Tools and Windows 10/11 SDK
- Intel oneAPI DPC++/C++ Compiler 2024.2.1
- Intel Fortran Compiler Classic and Intel Fortran Compiler 2024.2.1
- Intel MPI Library
- Rust for Windows
- Git for Windows
- Python 3
- CMake
- wget
- ninja
- meson
- yq
- Windows Terminal
📝Note
- We need Intel compiler mostly because MSVC is missing Fortran compiler and some C/C++ language extension are not supported yet.
- The final version of Intel compiler can support both 32 and 64bit are 2024.2.1, and this is also the last version to have ifort.
Before you start to use msvc-pkg, it is recommand to create a file settings.yaml and put it in the root folder of msvc-pkg. In case you want to install some libraries to your pre-defined location. Here is an example.
# settings.yaml
# The default location is msvc-pkg\x64 or msvc-pkg\x86
prefix:
x64:
llvm-project: D:\LLVM
lua: D:\Lua
perl: D:\Perl
ruby: D:\Ruby
tcl: D:\Tcl
tk: D:\Tcl
x86:
Using msvc-pkg is quick and simple. mpt.bat is the entry point from command line. Open the Windows terminal and follow the command from the below examples.
If you want to see the installation status of all available packages
mpt --list
If you want to build all available libraries on default host architecture
mpt
But if you want to build them on another architecture, e.g. x86
mpt x86
In case you don't want to build all but just some of them, e.g. gmp, gettext, ncurses, readline, on default host architecture
mpt gmp gettext ncurses readline
Many examples are available on packages folder, only following files are need for the libraries that you want to add:
- sync.sh work with common.sh, it is used to get the source of libraries and make patched if necessary before build.
- build.bat or build.sh is the build script on Win32 or Bash environment which depend on the libraries.
- config.yaml is the configuration file for libraries, some essential information have been defined there and will be used on mpt.py, sync.sh and build.bat or build.sh. Please notice that the name section in this file must be same as the folder name that contain config.yaml.
- The .diff files are depend on the libraries. If no patch needed before build, they will be no needed.
This project follows the all-contributors specification. 🚈 The goal of msvc-pkg is to use MSVC and MSVC-like toolset to build as many C/C++/Fortran open source librareis as possible. It is a ✨huge✨ effort. Any volunteer for further contribution is welcome.