Download and install rtools40-x86_64.exe from https://cran.r-project.org/bin/windows/testing/rtools40.html, then launch RTools MinGW 64-bit
pacman -S mingw-w64-{i686,x86_64}-toolchain
pacman -S mingw-w64-{i686,x86_64}-cmake
git checkout v1.4.0a0
Download and install rtools40-x86_64.exe from https://cran.r-project.org/bin/windows/testing/rtools40.html, then launch RTools MinGW 64-bit
pacman -S mingw-w64-{i686,x86_64}-toolchain
pacman -S mingw-w64-{i686,x86_64}-cmake
git checkout v1.4.0a0