The Qt Messaging Framework, QMF, consists of a C++ library and daemon server process that can be used to build email clients, and more generally software that interacts with email and mail servers. Building and Compiling ====================== To build the Messaging Framework, ensure Qt5/Qt6 development packages are installed. Preferably also zlib and libicu. The Qt6 build is done with cmake and Qt5 with qmake. For basic buid on Qt6 one can do: mkdir build cd build cmake .. make make install On Qt5: mkdir build cd build qmake .. QMF_INSTALL_ROOT=/usr # or qmake-qt5 depending on the environment make make install Note: On Qt5 the QmfWidgets module, which depends on QtWidgets, will be built by default. To remove this dependency use the define QMF_NO_WIDGETS, e.g. on qmake run qmake .. DEFINES+=QMF_NO_WIDGETS For other qmake options DEFINES+=USE_HTML_PARSER enables HTML preview parsing via QtGui which might be a good idea. Note: By default QMF operations on the message store are atomic and durable, so long as the underlying OS supports durable writes, e.g. on Linux based systems so long as fsync makes durable writes. Atomic means all of an operation such as a delete/update/add take effect or none of it does. Durable means once an operation is reported to have succeeded it will survive permanently even in the event of a system crash. Ensuring these properties has a considerable performance cost. To increase performance both durability and atomicity can be disabled using the define QMF_NO_DURABILITY e.g.: DEFINES+=QMF_NO_DURABILITY Running Messaging Framework =========================== After make install has run the messageserver binary should be located in the bin directory. For custom paths some environment variables can be set prior to launching qmf related apps: PATH=:$PATH LD_LIBRARY_PATH=:$LD_LIBRARY_PATH QT_PLUGIN_PATH= Optionally set QMF_DATA to the location where you want the framework data files stored. If this is not set, the default of $HOME/.local/share/qmf will be used. Testing the Messaging Framework =============================== The messaging framework includes a series of unit tests designed to ensure that it is functioning correctly in an operating environment. Unit tests are located in the tests top-level directory. To run the tests execute 'make test' with cmake or 'make check' with qmake. With qmake building the tests needs to be also enabled with QT_BUILD_PARTS+=tests on the qmake execution. Note: some tests alter or remove data from the mailstore they operate against. It is prudent to use a different value for the QMF_DATA environment variable Code status =========== The QtWidgets side hasn't had much attention for years and should be considered unstable API. Likely any real life usage is better anyway to create their own widgets and UI. Qt5 has been used for years. Qt6 less so and might have issues. Fixes and enhancements are welcome. At the moment only Linux is really supported with D-Bus as IPC. Other platforms would need some other mechanism for IPC implemented.