Build Windows

in3otd edited this page Apr 7, 2018 · 22 revisions

Build Instructions

Currently Qucs is built under Windows using the MSYS2 environment and the MinGW compiler. (The old build instructions can be found below)

Download MSYS2

  • Download the latest msys2-x86_64 from (currently msys2-x86_64-20170918.exe)

  • install it in C:\msys64, the default proposed installation directory, and run the shell, as proposed at the end of the installation. The shell can also be started manually, by running C:\msys64\mingw64.exe

    • MSYS2 NEEDS to be installed on a NTFS partition. If its installed at C:\msys64 it should not be a problem.

Install the needed packages

The following commands will be typed in the MSYS2 shell environment.

  • set the path using export PATH=/usr/local/bin:/usr/bin:/bin to be sure to use the MSYS2 tools in case you previously had installed MSYS1

  • update the package manager mirrors, pacman --noconfirm --sync pacman-mirrors

  • install the compiler, pacman --noconfirm -S base-devel mingw-w64-x86_64-toolchain

  • exit and relaunch the mingw64.exe

  • install these other packages

    • pacman --noconfirm -S git (takes some time)
    • pacman --noconfirm -S mingw-w64-x86_64-qt4 (takes even more time...)


Apparently on Windows 10 setting --prefix=/usr/local is needed, otherwise the default installation directory is /mingw64. It can be omitted for other Windows versions.

Download and compile admsXml

tar -xf adms-2.3.4.tar.gz
cd adms-2.3.4
./configure --prefix=/usr/local && make install
cd ..

Get the Qucs source code

Clone the Git repository

git clone

Build the Qucs GUI application

Building the documentation will be disabled, as it requires a lot of dependencies. Ready-made PDF files for all the Qucs documentation for the current release can be found at

cd qucs 
QTDIR=/c/msys64/mingw64/ ./configure --disable-doc --prefix=/usr/local
make install
cd ..

Qucs will be installed in /usr/local/bin

run qucs -v to check it's working correctly

Build Qucs-core

cd qucs-core 
./configure --disable-dependency-tracking --with-mkadms=`which admsXml`
 make install
cd ..

the Qucs simulator will be installed in /usr/local/bin

run qucsator -v to check it's working correctly

OLD Build Instructions - Windows 8.1 - MinGW 4.8.2 - Qt 4.8.6

This page contains instructions on how to build and install with the Autotools and CMake build systems. The install path can be any of your choice, here we use C:\qucs-auto\ and C:\qucs-cmake to make a distinction.

Tested with Windows 8.1 Enterprise 90-day evaluation version, installed on a [Virtual box instance](instructions


MinGW compiler

  • Use the same version used to compile the Qt libraries.

  • Compiler of choice (for Qt 4.8.6) i686-4.8.2-release-posix-dwarf-rt_v3-rev3.7z

  • Get a tool to extract the compressed file, 7-Zip for instance.

  • Extract it to C:\

  • Add C:\mingw32\bin to the Windows PATH environment variable


  • We will be using a snapshot release of Qt 4.8.6. This version is compiled against the above MinGW 4.8.2.

  • Download the latest snapshot/or stable release if available [] - 326MB

  • Execute the installer

  • When asked, point the Qt installer to the location of MinGW in C:\mingw32

  • Add it to path

  • Make sure C:\Qt\4.8.6\bin is on the PATH


  • Git for Windows. Only in case you want to clone the repository.

  • Note that Git on Windows provides also flex, bison. In case you want to use these tools you to have add C:\Program Files (x86)\Git\bin to the Windows PATH.

Get pre-compiled gperf and admsXml

Get the Qucs source code

Either (1) clone the Git repository or (2) download a repository snapshot.

Clone repository

  cd \
  mkdir git; cd git
  git clone git:// qucs

Repository snapshot

Build with Autotools / MSYS

Install MSYS terminal and further development tools

  • Download and run mingw-get installer

  • Select mingw-developer-tool, apply changes to install

  • When asked point to the installation to C:\mingw32

  • Make sure C:\mingw32\bin is on the Windows PATH

  • You might need to include C:\mingw32\msys\1.0\bin to path (for flex, bison)

  • Copy gperf.exe, admsXml.exe into C:\mingw\bin

  • Launch C:\mingw32\msys\1.0\msys.bat

  • run mount -r C:/mingw32 /mingw (you might need to use the long format options style mount --replace C:/mingw32 /mingw)

Build Qucs GUI (and tools)

  export QTDIR=/c/Qt/4.8.6/
  cd /c/git/qucs/qucs
  ./configure --enable-maintainer-mode --prefix=/c/qucs-auto/
  make install

Build Qucs Core

  cd /c/git/qucs/qucs-core
  ./configure --enable-maintainer-mode --with-mkadms=/mingw/bin/admsXml.exe --prefix=/c/qucs-auto/
  make install

After install, remember to copy amdsXml.exe also into C:\qucs-auto\bin so it can be used by Qucs.


From the MSYS terminal

  export QUCSDIR=c:\qucs-auto
  • To launch from Windows Explorer it will be necessary to add a Windows environment variable QUCSDIR=c:\qucs-auto.

Build with Cmake / cmd terminal

Build Qucs GUI (and tools)

Open a cmd window

  cd C:\git\qucs\qucs
  mkdir build
  cd build
  cmake .. -G "MinGW Makefiles" -DCMAKE_INSTALL_PREFIX=C:\qucs-cmake
  make install

Build Qucs Core

  cd C:\git\qucs\qucs-core
  mkdir build
  cd build
  cmake .. -G "MinGW Makefiles" -DCMAKE_INSTALL_PREFIX=C:\qucs-cmake
  make install
  • In case admsXml.exe is not found, let CMake know about its location with -DADMSXML_DIR=C:\MinGW\bin

  • After install, remember to copy amdsXml.exe also into C:\qucs-cmake\bin so it can be used by Qucs.


From the cmd terminal

  set QUCSDIR=c:\qucs-cmake
  • To lauch from Windows Explorer it will be necessary to add a Windows environemnt variable QUCSDIR=c:\qucs-cmake.


The debug messages on Windows are normally sent to the debugger, not the console. Qucs has a redirection routine to handle the situation (see qucs/main.cpp method qucsMessageOutput).

The user has to install the DebugView tool to intercept the debug messages from Qucs. Open DebugView before running Qucs. It should capture the debug messages that are normally printed to the console on Linux/OSX.

Final notes

  • Note that the CMakeLists.txt files can be used as projects on the QtCreator IDE. It makes it easier for new contributors.
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.