Setup MSYS2 env - bryanch/random GitHub Wiki
Reference (note I tweak a little bit to fit my case)
MSYS2
- Download from
http://msys2.github.io
- Install into
$DEV/msys64
- Run
$DEV/msys2_shell.cmd
- Run
pacman -Syuu
- Close the shell; reopen it, and run
pacman -Syuu
again, just in case :p
Pacman
pacman
is the package manager bundled with msys. Use it to install useful things
like gcc, flex, bison, git. The commands are pretty cryptic, so use the
Pacman/Rosetta.
$PATH
Set up - Open "Environment Variables > System Variables > Path"
- At the end, add
$DEV/msys64/usr/bin
Adding a HOME in user's env variables will set the home directory in MSYS shell
Git
- Open an msys shell
- Run
pacman -S git
- If you want to use
git gui
/gitk
,- Run
pacman -S mingw-w64-x86_64-tk
to install the binaries - In system variables, add
$DEV/msys64/mingw64/bin
to$PATH
- Set
MSYS2_PATH_TYPE
toinherit
- Run