Author Topic: Why do i need libqt5pas?  (Read 2362 times)


  • New Member
  • *
  • Posts: 30
Why do i need libqt5pas?
« on: January 28, 2021, 09:18:59 am »
Other widgetsets that freepascal supports doesn't need a dynamicly linked interface for freepascal. But qt5 does. Why was it done this way?


  • Hero Member
  • *****
  • Posts: 4266
  • Compiler Developer
Re: Why do i need libqt5pas?
« Reply #1 on: January 28, 2021, 09:21:04 am »
Qt is written in C++. FPC can't directly access C++ classes, thus a flattening library is required. In theory it would be possible to do this with a static library as well, but that would result in even larger executables. (Sidenote: Qt4 also has the dependency on a libqt4pas).


  • Hero Member
  • *****
  • Posts: 2045
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Why do i need libqt5pas?
« Reply #2 on: January 28, 2021, 11:04:11 am »
In practice, its a non issue el3ctrolyte, all Lazarus apps have dependencies, if you build a GTK2 app, you will specify it requires GTK2. And, yep, some Linux systems are available that don't have GTK2 installed by default.  By specifying that your Qt5 app depends on libqt5pas, you cover all its QT5 dependencies.

Most current linux disros have a viable libqt5pas in their repositories. There is a 'generic' one suitable for a few older distros at


Lazarus 2, Linux (and reluctantly Win10, OSX)
My Project -


TinyPortal © 2005-2018