Based on https://github.com/r-windows/rtools-installer. In msys2, run make_rtools_chroot.sh. It will produce build directory with selected msys2 tools for building R. Then extract the toolchain+libs (see ../toolchain_libs) into "build/rtools44". Finally, build the installer using Inno Setup by running "iscc rtools64.iss".