Rust 1.77.2 is the last version to support Windows 7.
rustup default 1.77.2
brew install mingw-w64
rustup target add x86_64-pc-windows-gnu
nano ~/.cargo/config.toml
[target.x86_64-pc-windows-gnu]
linker = "x86_64-w64-mingw32-gcc"
cargo build --release --target=x86_64-pc-windows-gnu
# See: https://github.com/messense/homebrew-macos-cross-toolchains
brew tap messense/macos-cross-toolchains
brew install x86_64-unknown-linux-gnu
nano ~/.cargo/config.toml
[target.x86_64-unknown-linux-gnu]
linker = "x86_64-linux-gnu-gcc"
cargo build --release --target=x86_64-unknown-linux-gnu
rustup target install x86_64-apple-darwin
cargo build --release --target=x86_64-apple-darwin