Menu

Build executable setup for Windows on Linux

Dirk Krause
← Previous ↑ Home ↑ Installation Next →

Build executable setup for Windows on Linux

Simple procedure on Debian 12 (Bookworm)

Download and unpack source archive

As unprivileged user download the *.tar.gz file and unpack it:

cd ~/Downloads
tar xzf dktools-4.38.0.tar.gz

Prepare to build

As root install the developer packages required:

cd ~user/Downloads/dktools-4.38.0
scripts/debian-prepare-mingw64

Build packages

As unprivileged user run:

cd ~user/Downloads/dktools-4.38.0
scripts/debian-build-mingw64

You should end up with a file dktools-4.38.0-WINDOWS-10-mingw64-nsis.exe and a file dktools-4.38.0-mingw64.zip in the parent of the current directory.

Simple procedure on Fedora 41

Download and unpack source archive

As unprivileged user download the *.tar.gz file and unpack it:

cd ~/Downloads
tar xzf dktools-4.38.0.tar.gz

Prepare to build

As root install the developer packages required:

cd ~user/Downloads/dktools-4.38.0
scripts/fedora41-prepare-mingw64

Build packages

As unprivileged user run:

cd ~user/Downloads/dktools-4.38.0
scripts/fedora41-build-mingw64

You should end up with a file dktools-4.38.0-WINDOWS-10-mingw64-nsis.exe and a file dktools-4.38.0-mingw64.zip in the parent of the current directory.

Used directories and files

We refer to the parent directory of the unpacked archive as “DIR”.
In our simple example this was the “~user/Downloads” directory.

  • ~user/Downloads/dktools-dep
    is used to store the source archives of required libraries.

  • ${DIR}/dktools-4.38.0-depsrc
    contains the unpacked source archives of the required libraries.

  • ${DIR}/dktools-4.38.0-mingw
    is the build root.

  • ${DIR}/dktools-4.38.0-mingw.zip
    is an archive containing the software but no installation routine.

  • ${DIR}/dktools-4.38.0.nsi
    is the nsis control file to build the installer.

  • ${DIR}/dktools-4.38.0-WINDOWS-version-mingw64-nsis.exe
    is the executable installer.

Process optimization

A lot of I/O activity happens in the ${DIR} directory during the build process. If there is enough RAM in your computer, I suggest to build a RAM disk (4 GB should be sufficient), mount it as “/media/ramdisk” and use that directory as ${DIR}.

← Previous ↑ Home ↑ Installation Next →

Related

Wiki: Installation

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.