--- a/src/plugins/generic/screenshotplugin/screenshotplugin.pro
+++ b/src/plugins/generic/screenshotplugin/screenshotplugin.pro
@@ -52,7 +52,7 @@ HEADERS  +=    qxt/core/qxtglobal.h \
 SOURCES  +=    qxt/core/qxtglobal.cpp \
         qxt/gui/qxtwindowsystem.cpp
 
-unix:!macx {
+unix:!macx:!haiku {
     CONFIG += X11
     SOURCES += qxt/gui/qxtwindowsystem_x11.cpp \
             qxt/gui/x11info.cpp
