How to translate this .pro file to build with Cs?

opaque
Posts: 19
Joined: Sat Mar 28 2020 11:53 am

How to translate this .pro file to build with Cs?

Post by opaque »

I grabbed an opensource project written in Qt5 and learn to migrate it to Cs. However the document only talk about CMake, but this one is a Qt .pro project file. How I could translate it to build with Cs? Convert it to a CMakeLists.txt or modify it to support Cs? Please help me. I'm still figuring out what to do.

Code: Select all

#******************************************************************************
#  Copyright (c) 2005-2013 by Jan Van hijfte
#  
#  See the included file COPYING.TXT for details about the copyright.
#
#  This program is distributed in the hope that it will be useful,
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
#******************************************************************************



# Binding Release Version 2.6 against Qt5 5.6 LTS release.
# WebKit widgets are disabled until webenginewidgets are implemented.

VERSION = 1.2.6

QT += gui network printsupport
TARGET = Qt5Pas
TEMPLATE = lib
VPATH = src
MOC_DIR = tmp
OBJECTS_DIR = tmp
QMAKE_CXXFLAGS += -Wfatal-errors

# Match Intel x86_64 i686 i586 i386 x86 ...
is86 = $$find(QMAKE_HOST.arch, ".*86")
# Match 64 bit
is64 = $$find(QMAKE_HOST.arch, ".*64")

!mac:!isEmpty(is86):isEmpty(is64) {
  message("Added stack alignment options to CXXFLAGS in support of SSE on arch:" $$QMAKE_HOST.arch)
  QMAKE_CXXFLAGS += -mstackrealign -mincoming-stack-boundary=2 
}  

!equals(QT_MAJOR_VERSION,5)|!equals(QT_MINOR_VERSION,6) {
  message("Note: This binding version was generated for Qt 5.6.1. Current Qt is" $$QT_VERSION)
  message("Qt documents binary compatibility in each Version Change Note: http://qt.nokia.com/developer/changes")
}

# Available Qt5 Pascal Binding Platforms: see http://wiki.freepascal.org/Qt5_binding#Supported_Platforms  

target.path = $$[QT_INSTALL_LIBS]
win32 : {
  PLATFORM = MSWINDOWS
  target.path = $$[QT_INSTALL_BINS]
  }
                           
embedded:PLATFORM = QTOPIA  

unix:!embedded:!mac:!haiku:PLATFORM = BINUX

mac {
  PLATFORM = DARWIN
  CONFIG += lib_bundle
  }

contains(PLATFORM, BINUX): {
  message("Adding x11extras for XOrg platform.")
  QT += x11extras
}

contains(CONFIG, maemo5): {
  message("Detected Maemo5")
  PLATFORM = MAEMO5
  QT += maemo5
  }
  
CONFIG -= debug_and_release
CONFIG -= debug_and_release_target
CONFIG -= debug
CONFIG -= warn_on
CONFIG -= create_prl
CONFIG -= link_prl

CONFIG -= release
CONFIG += debug
CONFIG += dll
CONFIG += warn_off
  
message("Pascal Qt Interface for binding platform:" $$PLATFORM)
DEFINES += $$PLATFORM   
message("Install location:" $$target.path)

INSTALLS += target


HEADERS +=  \
           chandles.h \
           qobject_hook.h \
           qobject_hook_c.h \
           pascalbind.h \
           flatfuncs.h \
           qobject_c.h \
           qobjectdefs_c.h \
           qvariant_c.h \
           qmetaobject_c.h \
           qcoreevent_c.h \
           qeventloop_c.h \
           qcoreapplication_c.h \
           qcoreapplication_hook.h \
           qtranslator_c.h \
           qtimer_c.h \
           qtimer_hook.h \
           qabstracteventdispatcher_c.h \
           qmimedata_c.h \
           qsocketnotifier_c.h \
           qsocketnotifier_hook.h \
           qabstractitemmodel_c.h \
           qabstractitemmodel_hook.h \
           qitemselectionmodel_c.h \
           qitemselectionmodel_hook.h \
           qthread_c.h \
           qthread_hook.h \
           qlclthread_c.h \
           qchar_c.h \
           qsize_c.h \
           qstring_c.h \
           qstringlist_c.h \
           qsurface_c.h \           
           qsurfaceformat_c.h \
           qrect_c.h \
           qmargins_c.h \                      
           qdatetime_c.h \
           qbytearray_c.h \
           qlocale_c.h \
           qiodevice_c.h \
           qiodevice_hook.h \
           qprocess_c.h \
           qprocess_hook.h \
           qbuffer_c.h \           
           qfiledevice_c.h \
           qfile_c.h \
           qfileinfo_c.h \
           qdir_c.h \
           qurl_c.h \
           qfilesystemwatcher_c.h \
           qfilesystemwatcher_hook.h \
           qpalette_c.h \
           qkeysequence_c.h \
           qevent_c.h \
           qlclmessageevent_c.h \
           qcursor_c.h \
           qclipboard_c.h \
           qclipboard_hook.h \
           qdrag_c.h \
           qdrag_hook.h \
           qsessionmanager_c.h \
           qguiapplication_c.h \
           qguiapplication_hook.h \
           qapplication_c.h \
           qapplication_hook.h \
           qwhatsthis_c.h \
           qsizepolicy_c.h \
           qscreen_c.h \
           qscreen_hook.h \
           qwindow_c.h \
           qwindow_hook.h \           
           qwidget_c.h \
           qwidget_hook.h \
           qlayoutitem_c.h \
           qlayout_c.h \
           qlayout_hook.h \
           qboxlayout_c.h \
           qstackedlayout_c.h \
           qstackedlayout_hook.h \
           qaction_c.h \
           qaction_hook.h \
           qactiongroup_c.h \
           qactiongroup_hook.h \
           qgridlayout_c.h \
           qdesktopwidget_c.h \
           qdesktopwidget_hook.h \
           qtooltip_c.h \
           qx11info_x11_c.h \
           qshortcut_c.h \
           qshortcut_hook.h \
           qgesture_c.h \
           qgesturerecognizer_c.h \
           qcolor_c.h \
           qmatrix_c.h \
           qbrush_c.h \
           qpen_c.h \
           qpolygon_c.h \
           qbackingstore_c.h \
           qpainter_c.h \
           qpaintengine_c.h \
           qpaintdevice_c.h \
           qregion_c.h \
           qpainterpath_c.h \
           qtransform_c.h \
           qpagedpaintdevice_c.h \
           qprinter_c.h \
           qprinterinfo_c.h \
           qfont_c.h \
           qfontdatabase_c.h \
           qtextformat_c.h \
           qtextcursor_c.h \
           qtextoption_c.h \
           qfontmetrics_c.h \
           qfontinfo_c.h \
           qtextdocument_c.h \
           qabstracttextdocumentlayout_c.h \
           qabstracttextdocumentlayout_hook.h \
           qtextlayout_c.h \
           qtextobject_c.h \
           qtextdocumentwriter_c.h \
           qicon_c.h \
           qpixmap_c.h \
           qimage_c.h \
           qbitmap_c.h \
           qpicture_c.h \
           qimageiohandler_c.h \
           qimagereader_c.h \
           qimagewriter_c.h \
           qvalidator_c.h \
           qstandarditemmodel_c.h \
           qstandarditemmodel_hook.h \
           qframe_c.h \
           qframe_hook.h \
           qstackedwidget_c.h \
           qstackedwidget_hook.h \
           qabstractscrollarea_c.h \
           qabstractscrollarea_hook.h \
           qlclabstractscrollarea_c.h \
           qabstractslider_c.h \
           qabstractslider_hook.h \
           qscrollbar_c.h \
           qscrollbar_hook.h \
           qmenu_c.h \
           qmenu_hook.h \
           qmenubar_c.h \
           qmenubar_hook.h \
           qbuttongroup_c.h \
           qbuttongroup_hook.h \
           qabstractbutton_c.h \
           qabstractbutton_hook.h \
           qpushbutton_c.h \
           qpushbutton_hook.h \
           qradiobutton_c.h \
           qlineedit_c.h \
           qlineedit_hook.h \
           qplaintextedit_c.h \
           qplaintextedit_hook.h \
           qtextedit_c.h \
           qtextedit_hook.h \
           qtabwidget_c.h \
           qtabwidget_hook.h \
           qlcltabwidget_c.h \
           qmainwindow_c.h \
           qmainwindow_hook.h \
           qtoolbar_c.h \
           qtoolbar_hook.h \
           qsizegrip_c.h \
           qlcdnumber_c.h \
           qlcdnumber_hook.h \
           qabstractspinbox_c.h \
           qabstractspinbox_hook.h \
           qlclabstractspinbox_c.h \
           qspinbox_c.h \
           qspinbox_hook.h \
           qsplitter_c.h \
           qsplitter_hook.h \
           qcombobox_c.h \
           qcombobox_hook.h \
           qcheckbox_c.h \
           qcheckbox_hook.h \
           qslider_c.h \
           qslider_hook.h \
           qtextbrowser_c.h \
           qtextbrowser_hook.h \
           qlabel_c.h \
           qlabel_hook.h \
           qgroupbox_c.h \
           qgroupbox_hook.h \
           qdockwidget_c.h \
           qdockwidget_hook.h \
           qtabbar_c.h \
           qtabbar_hook.h \
           qprogressbar_c.h \
           qprogressbar_hook.h \
           qstatusbar_c.h \
           qstatusbar_hook.h \
           qtoolbox_c.h \
           qtoolbox_hook.h \
           qtoolbutton_c.h \
           qtoolbutton_hook.h \
           qscrollarea_c.h \
           qmdiarea_c.h \
           qmdiarea_hook.h \
           qmdisubwindow_c.h \
           qmdisubwindow_hook.h \
           qcalendarwidget_c.h \
           qcalendarwidget_hook.h \
           qrubberband_c.h \
           qfontcombobox_c.h \
           qfontcombobox_hook.h \
           qabstractitemview_c.h \
           qabstractitemview_hook.h \
           qlistview_c.h \
           qlistview_hook.h \
           qlistwidget_c.h \
           qlistwidget_hook.h \
           qtreeview_c.h \
           qtreeview_hook.h \
           qtreewidget_c.h \
           qtreewidget_hook.h \
           qheaderview_c.h \
           qheaderview_hook.h \
           qabstractitemdelegate_c.h \
           qabstractitemdelegate_hook.h \
           qitemdelegate_c.h \
           qlclitemdelegate_c.h \
           qtableview_c.h \
           qtableview_hook.h \
           qtablewidget_c.h \
           qtablewidget_hook.h \
           qitemeditorfactory_c.h \
           qstyleditemdelegate_c.h \
           qdialog_c.h \
           qdialog_hook.h \
           qfontdialog_c.h \
           qmessagebox_c.h \
           qinputdialog_c.h \
           qcolordialog_c.h \
           qfiledialog_c.h \
           qfiledialog_hook.h \
           qprogressdialog_c.h \
           qprogressdialog_hook.h \
           qabstractprintdialog_c.h \
           qabstractprintdialog_hook.h \
           qprintdialog_c.h \
           qprintdialog_hook.h \
           qpagesetupdialog_c.h \
           qprintpreviewdialog_c.h \
           qprintpreviewdialog_hook.h \
           qprintpreviewwidget_c.h \
           qprintpreviewwidget_hook.h \
           qsystemtrayicon_c.h \
           qsystemtrayicon_hook.h \
           qdesktopservices_c.h \
           qstyle_c.h \
           qstyleoption_c.h \
           qstylefactory_c.h \
           qgraphicsscene_c.h \
           qgraphicsscene_hook.h \
           qgraphicsview_c.h \
           qsslcipher_c.h \
           qsslkey_c.h \
           qsslerror_c.h \
           qabstractsocket_c.h \
           qabstractsocket_hook.h \
           qudpsocket_c.h \
           qudpsocket_hook.h \
           qtcpsocket_c.h \
           qtcpsocket_hook.h \
           qtcpserver_c.h \
           qtcpserver_hook.h \
           qsslconfiguration_c.h \
           qsslsocket_c.h \
           qnetworkaccessmanager_c.h \
           qnetworkaccessmanager_hook.h \
           qnetworkrequest_c.h \
           qnetworkreply_c.h \
           qnetworkreply_hook.h \
           qnetworkcookiejar_c.h \
           qnetworkproxy_c.h \
           qauthenticator_c.h \
           qcoreapplication_hook_c.h \
           qtimer_hook_c.h \
           qsocketnotifier_hook_c.h \
           qabstractitemmodel_hook_c.h \
           qitemselectionmodel_hook_c.h \
           qthread_hook_c.h \
           qiodevice_hook_c.h \
           qprocess_hook_c.h \
           qfilesystemwatcher_hook_c.h \
           qclipboard_hook_c.h \
           qdrag_hook_c.h \
           qguiapplication_hook_c.h \
           qapplication_hook_c.h \
           qscreen_hook_c.h \           
           qwindow_hook_c.h \
           qwidget_hook_c.h \
           qlayout_hook_c.h \
           qstackedlayout_hook_c.h \
           qaction_hook_c.h \
           qactiongroup_hook_c.h \
           qdesktopwidget_hook_c.h \
           qshortcut_hook_c.h \
           qabstracttextdocumentlayout_hook_c.h \
           qstandarditemmodel_hook_c.h \
           qframe_hook_c.h \
           qstackedwidget_hook_c.h \
           qabstractscrollarea_hook_c.h \
           qabstractslider_hook_c.h \
           qscrollbar_hook_c.h \
           qmenu_hook_c.h \
           qmenubar_hook_c.h \
           qbuttongroup_hook_c.h \
           qabstractbutton_hook_c.h \
           qpushbutton_hook_c.h \
           qlineedit_hook_c.h \
           qplaintextedit_hook_c.h \
           qtextedit_hook_c.h \
           qtabwidget_hook_c.h \
           qmainwindow_hook_c.h \
           qtoolbar_hook_c.h \
           qlcdnumber_hook_c.h \
           qabstractspinbox_hook_c.h \
           qspinbox_hook_c.h \
           qsplitter_hook_c.h \
           qcombobox_hook_c.h \
           qcheckbox_hook_c.h \
           qslider_hook_c.h \
           qtextbrowser_hook_c.h \
           qlabel_hook_c.h \
           qgroupbox_hook_c.h \
           qdockwidget_hook_c.h \
           qtabbar_hook_c.h \
           qprogressbar_hook_c.h \
           qstatusbar_hook_c.h \
           qtoolbox_hook_c.h \
           qtoolbutton_hook_c.h \
           qmdiarea_hook_c.h \
           qmdisubwindow_hook_c.h \
           qcalendarwidget_hook_c.h \
           qfontcombobox_hook_c.h \
           qabstractitemview_hook_c.h \
           qlistview_hook_c.h \
           qlistwidget_hook_c.h \
           qtreeview_hook_c.h \
           qtreewidget_hook_c.h \
           qheaderview_hook_c.h \
           qabstractitemdelegate_hook_c.h \
           qtableview_hook_c.h \
           qtablewidget_hook_c.h \
           qdialog_hook_c.h \
           qfiledialog_hook_c.h \
           qprogressdialog_hook_c.h \
           qabstractprintdialog_hook_c.h \
           qprintdialog_hook_c.h \
           qprintpreviewdialog_hook_c.h \
           qprintpreviewwidget_hook_c.h \
           qsystemtrayicon_hook_c.h \
           qgraphicsscene_hook_c.h \
           qabstractsocket_hook_c.h \
           qudpsocket_hook_c.h \
           qtcpsocket_hook_c.h \
           qtcpserver_hook_c.h \
           qnetworkaccessmanager_hook_c.h \
           qnetworkreply_hook_c.h 
SOURCES +=  \
           qobject_hook_c.cpp \
           pascalbind.cpp \
           flatfuncs.cpp \
           qobject_c.cpp \
           qobjectdefs_c.cpp \
           qvariant_c.cpp \
           qmetaobject_c.cpp \
           qcoreevent_c.cpp \
           qeventloop_c.cpp \
           qcoreapplication_c.cpp \
           qtranslator_c.cpp \
           qtimer_c.cpp \
           qabstracteventdispatcher_c.cpp \
           qmimedata_c.cpp \
           qsocketnotifier_c.cpp \
           qabstractitemmodel_c.cpp \
           qitemselectionmodel_c.cpp \
           qthread_c.cpp \
           qlclthread_c.cpp \
           qchar_c.cpp \
           qsize_c.cpp \
           qstring_c.cpp \
           qstringlist_c.cpp \
           qsurface_c.cpp \
           qsurfaceformat_c.cpp \
           qrect_c.cpp \
           qmargins_c.cpp \           
           qdatetime_c.cpp \
           qbytearray_c.cpp \
           qlocale_c.cpp \
           qiodevice_c.cpp \
           qprocess_c.cpp \
           qbuffer_c.cpp \           
           qfiledevice_c.cpp \
           qfile_c.cpp \
           qfileinfo_c.cpp \
           qdir_c.cpp \
           qurl_c.cpp \
           qfilesystemwatcher_c.cpp \
           qpalette_c.cpp \
           qkeysequence_c.cpp \
           qevent_c.cpp \
           qlclmessageevent_c.cpp \
           qcursor_c.cpp \
           qclipboard_c.cpp \
           qdrag_c.cpp \
           qsessionmanager_c.cpp \
           qguiapplication_c.cpp \
           qapplication_c.cpp \
           qwhatsthis_c.cpp \
           qsizepolicy_c.cpp \
           qscreen_c.cpp \
           qwindow_c.cpp \           
           qwidget_c.cpp \
           qlayoutitem_c.cpp \
           qlayout_c.cpp \
           qboxlayout_c.cpp \
           qstackedlayout_c.cpp \
           qaction_c.cpp \
           qactiongroup_c.cpp \
           qgridlayout_c.cpp \
           qdesktopwidget_c.cpp \
           qtooltip_c.cpp \
           qx11info_x11_c.cpp \
           qshortcut_c.cpp \
           qgesture_c.cpp \
           qgesturerecognizer_c.cpp \
           qcolor_c.cpp \
           qmatrix_c.cpp \
           qbrush_c.cpp \
           qpen_c.cpp \
           qpolygon_c.cpp \
           qbackingstore_c.cpp \
           qpainter_c.cpp \
           qpaintengine_c.cpp \
           qpaintdevice_c.cpp \
           qregion_c.cpp \
           qpainterpath_c.cpp \
           qtransform_c.cpp \
           qpagedpaintdevice_c.cpp \
           qprinter_c.cpp \
           qprinterinfo_c.cpp \
           qfont_c.cpp \
           qfontdatabase_c.cpp \
           qtextformat_c.cpp \
           qtextcursor_c.cpp \
           qtextoption_c.cpp \
           qfontmetrics_c.cpp \
           qfontinfo_c.cpp \
           qtextdocument_c.cpp \
           qabstracttextdocumentlayout_c.cpp \
           qtextlayout_c.cpp \
           qtextobject_c.cpp \
           qtextdocumentwriter_c.cpp \
           qicon_c.cpp \
           qpixmap_c.cpp \
           qimage_c.cpp \
           qbitmap_c.cpp \
           qpicture_c.cpp \
           qimageiohandler_c.cpp \
           qimagereader_c.cpp \
           qimagewriter_c.cpp \
           qvalidator_c.cpp \
           qstandarditemmodel_c.cpp \
           qframe_c.cpp \
           qstackedwidget_c.cpp \
           qabstractscrollarea_c.cpp \
           qlclabstractscrollarea_c.cpp \
           qabstractslider_c.cpp \
           qscrollbar_c.cpp \
           qmenu_c.cpp \
           qmenubar_c.cpp \
           qbuttongroup_c.cpp \
           qabstractbutton_c.cpp \
           qpushbutton_c.cpp \
           qradiobutton_c.cpp \
           qlineedit_c.cpp \
           qplaintextedit_c.cpp \
           qtextedit_c.cpp \
           qtabwidget_c.cpp \
           qlcltabwidget_c.cpp \
           qmainwindow_c.cpp \
           qtoolbar_c.cpp \
           qsizegrip_c.cpp \
           qlcdnumber_c.cpp \
           qabstractspinbox_c.cpp \
           qlclabstractspinbox_c.cpp \
           qspinbox_c.cpp \
           qsplitter_c.cpp \
           qcombobox_c.cpp \
           qcheckbox_c.cpp \
           qslider_c.cpp \
           qtextbrowser_c.cpp \
           qlabel_c.cpp \
           qgroupbox_c.cpp \
           qdockwidget_c.cpp \
           qtabbar_c.cpp \
           qprogressbar_c.cpp \
           qstatusbar_c.cpp \
           qtoolbox_c.cpp \
           qtoolbutton_c.cpp \
           qscrollarea_c.cpp \
           qmdiarea_c.cpp \
           qmdisubwindow_c.cpp \
           qcalendarwidget_c.cpp \
           qrubberband_c.cpp \
           qfontcombobox_c.cpp \
           qabstractitemview_c.cpp \
           qlistview_c.cpp \
           qlistwidget_c.cpp \
           qtreeview_c.cpp \
           qtreewidget_c.cpp \
           qheaderview_c.cpp \
           qabstractitemdelegate_c.cpp \
           qitemdelegate_c.cpp \
           qlclitemdelegate_c.cpp \
           qtableview_c.cpp \
           qtablewidget_c.cpp \
           qitemeditorfactory_c.cpp \
           qstyleditemdelegate_c.cpp \
           qdialog_c.cpp \
           qfontdialog_c.cpp \
           qmessagebox_c.cpp \
           qinputdialog_c.cpp \
           qcolordialog_c.cpp \
           qfiledialog_c.cpp \
           qprogressdialog_c.cpp \
           qabstractprintdialog_c.cpp \
           qprintdialog_c.cpp \
           qpagesetupdialog_c.cpp \
           qprintpreviewdialog_c.cpp \
           qprintpreviewwidget_c.cpp \
           qsystemtrayicon_c.cpp \
           qdesktopservices_c.cpp \
           qstyle_c.cpp \
           qstyleoption_c.cpp \
           qstylefactory_c.cpp \
           qgraphicsscene_c.cpp \
           qgraphicsview_c.cpp \
           qsslcipher_c.cpp \
           qsslkey_c.cpp \
           qsslerror_c.cpp \
           qabstractsocket_c.cpp \
           qudpsocket_c.cpp \
           qtcpsocket_c.cpp \
           qtcpserver_c.cpp \
           qsslconfiguration_c.cpp \
           qsslsocket_c.cpp \
           qnetworkaccessmanager_c.cpp \
           qnetworkrequest_c.cpp \
           qnetworkreply_c.cpp \
           qnetworkcookiejar_c.cpp \
           qnetworkproxy_c.cpp \
           qauthenticator_c.cpp \
           qcoreapplication_hook_c.cpp \
           qtimer_hook_c.cpp \
           qsocketnotifier_hook_c.cpp \
           qabstractitemmodel_hook_c.cpp \
           qitemselectionmodel_hook_c.cpp \
           qthread_hook_c.cpp \
           qiodevice_hook_c.cpp \
           qprocess_hook_c.cpp \
           qfilesystemwatcher_hook_c.cpp \
           qclipboard_hook_c.cpp \
           qdrag_hook_c.cpp \
           qguiapplication_hook_c.cpp \
           qapplication_hook_c.cpp \
           qscreen_hook_c.cpp \           
           qwindow_hook_c.cpp \
           qwidget_hook_c.cpp \
           qlayout_hook_c.cpp \
           qstackedlayout_hook_c.cpp \
           qaction_hook_c.cpp \
           qactiongroup_hook_c.cpp \
           qdesktopwidget_hook_c.cpp \
           qshortcut_hook_c.cpp \
           qabstracttextdocumentlayout_hook_c.cpp \
           qstandarditemmodel_hook_c.cpp \
           qframe_hook_c.cpp \
           qstackedwidget_hook_c.cpp \
           qabstractscrollarea_hook_c.cpp \
           qabstractslider_hook_c.cpp \
           qscrollbar_hook_c.cpp \
           qmenu_hook_c.cpp \
           qmenubar_hook_c.cpp \
           qbuttongroup_hook_c.cpp \
           qabstractbutton_hook_c.cpp \
           qpushbutton_hook_c.cpp \
           qlineedit_hook_c.cpp \
           qplaintextedit_hook_c.cpp \
           qtextedit_hook_c.cpp \
           qtabwidget_hook_c.cpp \
           qmainwindow_hook_c.cpp \
           qtoolbar_hook_c.cpp \
           qlcdnumber_hook_c.cpp \
           qabstractspinbox_hook_c.cpp \
           qspinbox_hook_c.cpp \
           qsplitter_hook_c.cpp \
           qcombobox_hook_c.cpp \
           qcheckbox_hook_c.cpp \
           qslider_hook_c.cpp \
           qtextbrowser_hook_c.cpp \
           qlabel_hook_c.cpp \
           qgroupbox_hook_c.cpp \
           qdockwidget_hook_c.cpp \
           qtabbar_hook_c.cpp \
           qprogressbar_hook_c.cpp \
           qstatusbar_hook_c.cpp \
           qtoolbox_hook_c.cpp \
           qtoolbutton_hook_c.cpp \
           qmdiarea_hook_c.cpp \
           qmdisubwindow_hook_c.cpp \
           qcalendarwidget_hook_c.cpp \
           qfontcombobox_hook_c.cpp \
           qabstractitemview_hook_c.cpp \
           qlistview_hook_c.cpp \
           qlistwidget_hook_c.cpp \
           qtreeview_hook_c.cpp \
           qtreewidget_hook_c.cpp \
           qheaderview_hook_c.cpp \
           qabstractitemdelegate_hook_c.cpp \
           qtableview_hook_c.cpp \
           qtablewidget_hook_c.cpp \
           qdialog_hook_c.cpp \
           qfiledialog_hook_c.cpp \
           qprogressdialog_hook_c.cpp \
           qabstractprintdialog_hook_c.cpp \
           qprintdialog_hook_c.cpp \
           qprintpreviewdialog_hook_c.cpp \
           qprintpreviewwidget_hook_c.cpp \
           qsystemtrayicon_hook_c.cpp \
           qgraphicsscene_hook_c.cpp \
           qabstractsocket_hook_c.cpp \
           qudpsocket_hook_c.cpp \
           qtcpsocket_hook_c.cpp \
           qtcpserver_hook_c.cpp \
           qnetworkaccessmanager_hook_c.cpp \
           qnetworkreply_hook_c.cpp
# end of file

barbara
Posts: 175
Joined: Sat Apr 04 2015 2:32 am

Re: How to translate this .pro file to build with Cs?

Post by barbara »

opaque wrote:
Sat Mar 28 2020 4:20 pm
I grabbed an opensource project written in Qt5 and learn to migrate it to Cs. However the document only talk about CMake, but this one is a Qt .pro project file. How I could translate it to build with Cs? Convert it to a CMakeLists.txt or modify it to support Cs? Please help me. I'm still figuring out what to do.
* *
CopperSpice uses the CMake build system so you will need to rewrite the .pro file to build the application using CMake. In our "CS Overview" documentation we have a sample .pro file and the corresponding CMake build files for a project called HelloLunch. Please have a look at the following link.

https://www.copperspice.com/docs/cs_overview/main-sample-project.html

* *
You may also be interested in our documentation about migrating the code. This part depends on how the original project was written. You will most likely need to run PepperMill one time on the original code and then adjust a few other lines.

https://www.copperspice.com/docs/cs_overview/cs-peppermill.html
https://www.copperspice.com/docs/cs_overview/cs-migration.html

If you have other questions just let us know and someone on the team will help.

Barbara

opaque
Posts: 19
Joined: Sat Mar 28 2020 11:53 am

Re: How to translate this .pro file to build with Cs?

Post by opaque »

barbara wrote:
Sat Mar 28 2020 5:23 pm
opaque wrote:
Sat Mar 28 2020 4:20 pm
I grabbed an opensource project written in Qt5 and learn to migrate it to Cs. However the document only talk about CMake, but this one is a Qt .pro project file. How I could translate it to build with Cs? Convert it to a CMakeLists.txt or modify it to support Cs? Please help me. I'm still figuring out what to do.
* *
CopperSpice uses the CMake build system so you will need to rewrite the .pro file to build the application using CMake. In our "CS Overview" documentation we have a sample .pro file and the corresponding CMake build files for a project called HelloLunch. Please have a look at the following link.

https://www.copperspice.com/docs/cs_overview/main-sample-project.html

* *
You may also be interested in our documentation about migrating the code. This part depends on how the original project was written. You will most likely need to run PepperMill one time on the original code and then adjust a few other lines.

https://www.copperspice.com/docs/cs_overview/cs-peppermill.html
https://www.copperspice.com/docs/cs_overview/cs-migration.html

If you have other questions just let us know and someone on the team will help.

Barbara
The project file I posted above is a library, it build to a dll or .so file. Your example project is a normal executable so it will not help me much there. And I don't know anything about CMake, too. I think it will be a steep learning curve for me.

barbara
Posts: 175
Joined: Sat Apr 04 2015 2:32 am

Re: How to translate this .pro file to build with Cs?

Post by barbara »

The project file I posted above is a library, it build to a dll or .so file. Your example project is a normal executable so it will not help me much there. And I don't know anything about CMake, too. I think it will be a steep learning curve for me.
The build file for a library versus an executable is not that different. It may take a few hours to convert the file but then you will a new skill set, a better build system, and more flexibility by using CopperSpice.

If you want to see how a library is built have a look at our CMake files for CsCore and some of our other CS libraries.

CMake is currently the de-facto standard and something every developer will need to learn if you want to build C++ projects.

We have a great team who monitor this forum and as you have questions I am sure we can help you while you learn. I would encourage to take the risk if for no other reason than to learn CMake.

Barbara

CandL
Posts: 40
Joined: Mon Oct 14 2019 6:37 pm

Re: How to translate this .pro file to build with Cs?

Post by CandL »

I know the debate of qmake (.pro) vs cmake will go on for some time. But even the Qt company is transitioning to CMake.

QBS was supposed to be sort of a qmake ver 2, and was going to be the build platform for Qt 6. But then in late 2018 "Deprecation of Qbs" (https://www.qt.io/blog/2018/10/29/deprecation-of-qbs)

CMake seems to be the build system everybody loves to hate, but yet it seems to me to be the one with the most cross platform capability.

There is a product / company called Plex. I would encourage you to watch "Tobias Hieta : Modernizing Plex C++ toolchain" ( https://www.youtube.com/watch?v=wrF0Yc3n1DE )

Let me say I don't work for Plex ( I do have a PlexPass) but I consider their business model for building code to be a good example to follow. I know the video is long but if you watch I think you will walk away thinking:
- This company has spent a few pennies think about this... and could have chosen any system they wanted
- By and large these guys know there stuff
- They need to support MANY platforms

So yes I migrated from qmake to cmake about 18 months ago... and I will be dragging others where I work soon enough. ;)

barbara
Posts: 175
Joined: Sat Apr 04 2015 2:32 am

Re: How to translate this .pro file to build with Cs?

Post by barbara »

Thank you for posting this information about companies making the switch to CMake. The documentation can be a bit vague however the basic functionality is comprehensible. A contributor to CopperSpice wrote our first set of CMake files several years ago and then the team did an overhaul last year. We have over 150 build files in the project and the consistency in styling and command usage makes them easier to read.

We have also improved the CMake build files for our KitchenSink demo and DoxyPress. The Diamond program is getting another look so making bundles will be easier. The more examples we have the better our users will be able to migrate to CMake.

Will watch the video you mentioned as we always enjoy learning how other successful companies operate.

Barbara

opaque
Posts: 19
Joined: Sat Mar 28 2020 11:53 am

Re: How to translate this .pro file to build with Cs?

Post by opaque »

Hi, I still can't translate this qmake project file to cmake.

Here are my CMakeLists.txt:

Code: Select all

 cmake_minimum_required(VERSION 3.8 FATAL_ERROR)
 project(Qt5Pas)
  
 include(CheckCXXCompilerFlag)
 include(CheckCXXSourceCompiles)
 include(CheckIncludeFile)
 include(CheckIncludeFiles)
 include(CheckTypeSize)
  
 find_package(CopperSpice REQUIRED)
  
 set(PACKAGE "Qt5Pas")
 set(PACKAGE_NAME "Qt5Pas")
  
 set(CMAKE_INCLUDE_CURRENT_DIR ON)
 set(CMAKE_INCLUDE_DIRECTORIES_BEFORE ON)
 set(CMAKE_CXX_STANDARD_REQUIRED ON)
 set(CMAKE_CXX_STANDARD 17)
  
 # location for building binary files
# set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
  
 add_subdirectory(src)

Code: Select all

 list(APPEND Qt5Pas_INCLUDES
    ${CMAKE_CURRENT_SOURCE_DIR}/chandles.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qobject_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qobject_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/pascalbind.h
    ${CMAKE_CURRENT_SOURCE_DIR}/flatfuncs.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qobject_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qobjectdefs_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qvariant_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmetaobject_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcoreevent_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qeventloop_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcoreapplication_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcoreapplication_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtranslator_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtimer_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtimer_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstracteventdispatcher_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmimedata_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsocketnotifier_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsocketnotifier_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemmodel_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemmodel_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemselectionmodel_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemselectionmodel_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qthread_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qthread_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclthread_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qchar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsize_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstring_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstringlist_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsurface_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsurfaceformat_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qrect_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmargins_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdatetime_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbytearray_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlocale_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qiodevice_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qiodevice_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprocess_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprocess_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbuffer_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfiledevice_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfile_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfileinfo_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdir_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qurl_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfilesystemwatcher_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfilesystemwatcher_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpalette_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qkeysequence_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qevent_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclmessageevent_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcursor_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qclipboard_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qclipboard_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdrag_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdrag_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsessionmanager_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qguiapplication_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qguiapplication_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qapplication_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qapplication_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qwhatsthis_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsizepolicy_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qscreen_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qscreen_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qwindow_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qwindow_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclopenglwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlayoutitem_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlayout_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlayout_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qboxlayout_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedlayout_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedlayout_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qaction_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qaction_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qactiongroup_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qactiongroup_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgridlayout_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdesktopwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdesktopwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtooltip_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qx11info_x11_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qshortcut_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qshortcut_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgesture_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgesturerecognizer_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcolor_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmatrix_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbrush_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpen_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpolygon_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbackingstore_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpainter_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpaintengine_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpaintdevice_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qregion_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpainterpath_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtransform_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpagedpaintdevice_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprinter_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprinterinfo_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfont_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontdatabase_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextformat_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextcursor_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextoption_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontmetrics_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontinfo_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextdocument_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstracttextdocumentlayout_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstracttextdocumentlayout_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextlayout_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextobject_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextdocumentwriter_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qicon_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpixmap_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qimage_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbitmap_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpicture_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qimageiohandler_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qimagereader_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qimagewriter_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qvalidator_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstandarditemmodel_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstandarditemmodel_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qframe_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qframe_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractscrollarea_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractscrollarea_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclabstractscrollarea_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractslider_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractslider_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qscrollbar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qscrollbar_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenu_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenu_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenubar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenubar_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbuttongroup_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbuttongroup_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractbutton_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractbutton_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpushbutton_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpushbutton_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qradiobutton_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlineedit_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlineedit_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qplaintextedit_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qplaintextedit_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextedit_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextedit_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlcltabwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmainwindow_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmainwindow_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbar_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsizegrip_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlcdnumber_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlcdnumber_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractspinbox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractspinbox_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclabstractspinbox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qspinbox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qspinbox_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsplitter_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsplitter_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcombobox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcombobox_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcheckbox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcheckbox_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qslider_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qslider_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextbrowser_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextbrowser_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlabel_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlabel_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgroupbox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgroupbox_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdockwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdockwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabbar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabbar_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressbar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressbar_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstatusbar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstatusbar_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbox_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbutton_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbutton_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qscrollarea_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdiarea_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdiarea_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdisubwindow_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdisubwindow_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcalendarwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcalendarwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qrubberband_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontcombobox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontcombobox_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemview_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemview_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistview_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistview_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreeview_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreeview_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreewidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreewidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qheaderview_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qheaderview_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemdelegate_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemdelegate_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemdelegate_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclitemdelegate_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtableview_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtableview_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtablewidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtablewidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemeditorfactory_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstyleditemdelegate_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdialog_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmessagebox_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qinputdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcolordialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfiledialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfiledialog_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressdialog_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractprintdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractprintdialog_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintdialog_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpagesetupdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewdialog_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewdialog_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewwidget_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewwidget_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsystemtrayicon_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsystemtrayicon_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdesktopservices_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstyle_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstyleoption_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstylefactory_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgraphicsscene_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgraphicsscene_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgraphicsview_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslcipher_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslkey_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslerror_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractsocket_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractsocket_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qudpsocket_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qudpsocket_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpsocket_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpsocket_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpserver_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpserver_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslconfiguration_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslsocket_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkaccessmanager_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkaccessmanager_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkrequest_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkreply_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkreply_hook.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkcookiejar_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkproxy_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qauthenticator_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcoreapplication_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtimer_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsocketnotifier_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemmodel_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemselectionmodel_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qthread_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qiodevice_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprocess_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfilesystemwatcher_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qclipboard_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdrag_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qguiapplication_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qapplication_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qscreen_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qwindow_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlayout_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedlayout_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qaction_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qactiongroup_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdesktopwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qshortcut_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstracttextdocumentlayout_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstandarditemmodel_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qframe_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractscrollarea_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractslider_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qscrollbar_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenu_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenubar_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qbuttongroup_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractbutton_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qpushbutton_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlineedit_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qplaintextedit_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextedit_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmainwindow_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbar_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlcdnumber_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractspinbox_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qspinbox_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsplitter_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcombobox_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcheckbox_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qslider_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextbrowser_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlabel_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgroupbox_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdockwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabbar_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressbar_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qstatusbar_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbox_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbutton_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdiarea_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdisubwindow_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qcalendarwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontcombobox_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemview_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistview_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreeview_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreewidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qheaderview_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemdelegate_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtableview_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtablewidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qdialog_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qfiledialog_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressdialog_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractprintdialog_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintdialog_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewdialog_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewwidget_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qsystemtrayicon_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qgraphicsscene_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractsocket_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qudpsocket_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpsocket_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpserver_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkaccessmanager_hook_c.h
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkreply_hook_c.h
 )
  
 list(APPEND Qt5Pas_SOURCES
    ${CMAKE_CURRENT_SOURCE_DIR}/qobject_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/pascalbind.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/flatfuncs.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qobject_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qobjectdefs_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qvariant_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmetaobject_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcoreevent_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qeventloop_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcoreapplication_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtranslator_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtimer_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstracteventdispatcher_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmimedata_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsocketnotifier_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemmodel_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemselectionmodel_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qthread_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclthread_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qchar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsize_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstring_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstringlist_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsurface_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsurfaceformat_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qrect_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmargins_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdatetime_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qbytearray_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlocale_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qiodevice_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprocess_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qbuffer_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfiledevice_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfile_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfileinfo_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdir_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qurl_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfilesystemwatcher_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpalette_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qkeysequence_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qevent_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclmessageevent_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcursor_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qclipboard_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdrag_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsessionmanager_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qguiapplication_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qapplication_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qwhatsthis_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsizepolicy_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qscreen_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qwindow_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclopenglwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlayoutitem_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlayout_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qboxlayout_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedlayout_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qaction_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qactiongroup_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgridlayout_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdesktopwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtooltip_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qx11info_x11_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qshortcut_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgesture_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgesturerecognizer_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcolor_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmatrix_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qbrush_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpen_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpolygon_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qbackingstore_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpainter_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpaintengine_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpaintdevice_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qregion_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpainterpath_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtransform_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpagedpaintdevice_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprinter_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprinterinfo_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfont_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontdatabase_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextformat_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextcursor_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextoption_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontmetrics_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontinfo_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextdocument_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstracttextdocumentlayout_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextlayout_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextobject_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextdocumentwriter_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qicon_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpixmap_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qimage_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qbitmap_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpicture_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qimageiohandler_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qimagereader_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qimagewriter_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qvalidator_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstandarditemmodel_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qframe_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractscrollarea_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclabstractscrollarea_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractslider_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qscrollbar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenu_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenubar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qbuttongroup_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractbutton_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpushbutton_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qradiobutton_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlineedit_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qplaintextedit_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextedit_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlcltabwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmainwindow_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsizegrip_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlcdnumber_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractspinbox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclabstractspinbox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qspinbox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsplitter_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcombobox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcheckbox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qslider_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextbrowser_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlabel_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgroupbox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdockwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabbar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressbar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstatusbar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbutton_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qscrollarea_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdiarea_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdisubwindow_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcalendarwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qrubberband_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontcombobox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemview_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistview_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreeview_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreewidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qheaderview_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemdelegate_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemdelegate_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlclitemdelegate_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtableview_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtablewidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemeditorfactory_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstyleditemdelegate_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmessagebox_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qinputdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcolordialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfiledialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractprintdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpagesetupdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewdialog_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewwidget_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsystemtrayicon_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdesktopservices_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstyle_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstyleoption_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstylefactory_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgraphicsscene_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgraphicsview_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslcipher_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslkey_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslerror_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractsocket_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qudpsocket_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpsocket_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpserver_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslconfiguration_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsslsocket_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkaccessmanager_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkrequest_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkreply_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkcookiejar_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkproxy_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qauthenticator_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcoreapplication_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtimer_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsocketnotifier_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemmodel_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qitemselectionmodel_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qthread_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qiodevice_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprocess_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfilesystemwatcher_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qclipboard_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdrag_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qguiapplication_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qapplication_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qscreen_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qwindow_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlayout_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedlayout_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qaction_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qactiongroup_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdesktopwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qshortcut_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstracttextdocumentlayout_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstandarditemmodel_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qframe_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstackedwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractscrollarea_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractslider_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qscrollbar_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenu_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmenubar_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qbuttongroup_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractbutton_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qpushbutton_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlineedit_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qplaintextedit_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextedit_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmainwindow_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbar_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlcdnumber_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractspinbox_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qspinbox_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsplitter_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcombobox_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcheckbox_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qslider_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtextbrowser_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlabel_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgroupbox_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdockwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtabbar_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressbar_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qstatusbar_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbox_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtoolbutton_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdiarea_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qmdisubwindow_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qcalendarwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfontcombobox_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemview_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistview_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qlistwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreeview_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtreewidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qheaderview_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractitemdelegate_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtableview_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtablewidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qdialog_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qfiledialog_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprogressdialog_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractprintdialog_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintdialog_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewdialog_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qprintpreviewwidget_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qsystemtrayicon_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qgraphicsscene_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qabstractsocket_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qudpsocket_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpsocket_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qtcpserver_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkaccessmanager_hook_c.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/qnetworkreply_hook_c.cpp
 )
  
 # # run rcc to generate qrc output
 # COPPERSPICE_RESOURCES(
    # ${CMAKE_CURRENT_SOURCE_DIR}/../hellolunch.qrc
 # )
  # 
 # # run uic to generate source
 # COPPERSPICE_RESOURCES(
    # ${CMAKE_CURRENT_SOURCE_DIR}/lunch.ui
 # )
  
 add_library(Qt5Pas
    ${Qt5Pas_SOURCES}
 )
  
 target_include_directories(Qt5Pas
    PRIVATE
    ${CMAKE_SOURCE_DIR}/src
 )
  
 target_link_libraries(Qt5Pas
    CopperSpice::CsCore
    CopperSpice::CsGui
    CopperSpice::CsNetwork
 )
  
 # if(CMAKE_SYSTEM_NAME MATCHES "Windows")
    # # disable console on windows
    # target_link_libraries(Qt5Pas -lnetapi32 -lmpr -mwindows)
 # endif()
  
 install(TARGETS Qt5Pas DESTINATION .)
According to this: https://www.copperspice.com/docs/cs_overview/sample-cs-cmake.html, when I run:

Code: Select all

cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=[path_to_copperspice] .
it failed. I suppose [path_to_copperspice] is the path to the directory extracted from the .tar.bz2 archive?

If it is so what is the meaning of these errors:

Code: Select all

CMake Error at CMakeLists.txt:10 (find_package):
  By not providing "FindCopperSpice.cmake" in CMAKE_MODULE_PATH this project
  has asked CMake to find a package configuration file provided by
  "CopperSpice", but CMake did not find one.

  Could not find a package configuration file provided by "CopperSpice" with
  any of the following names:

    CopperSpiceConfig.cmake
    copperspice-config.cmake

  Add the installation prefix of "CopperSpice" to CMAKE_PREFIX_PATH or set
  "CopperSpice_DIR" to a directory containing one of the above files.  If
  "CopperSpice" provides a separate development package or SDK, be sure it
  has been installed.


-- Configuring incomplete, errors occurred!
See also "/home/opaque/Downloads/Untitled Folder/cbindings/CMakeFiles/CMakeOutput.log".
In nowhere even the source code of CopperSpice did I found these .cmake file.

So what is the meaning of them?

I use cmake and ninja-build from Debian 10:

Code: Select all

cmake version 3.13.4

CMake suite maintained and supported by Kitware (kitware.com/cmake).

opaque
Posts: 19
Joined: Sat Mar 28 2020 11:53 am

Re: How to translate this .pro file to build with Cs?

Post by opaque »

Please let me know if I did anything wrong but I tried to compile Diamond it's also failed with the same error. I downloaded CopperSpice 1.5.3 and nowhere inside the directory extracted from the .tar.bz2 archive these .cmake files could be found.

opaque
Posts: 19
Joined: Sat Mar 28 2020 11:53 am

Re: How to translate this .pro file to build with Cs?

Post by opaque »

The error was solved by switching to CopperSpice 1.6.2. Should we clarify when we write [path_to_copperspice] it really means path to lib/cmake/CopperSpice but not path to the root directory of CopperSpice? It took me too much time to figure it out.

barbara
Posts: 175
Joined: Sat Apr 04 2015 2:32 am

Re: How to translate this .pro file to build with Cs?

Post by barbara »

1
I tried to compile Diamond it's also failed with the same error. I downloaded CopperSpice 1.5.3 and nowhere inside the directory extracted from the .tar.bz2 archive these .cmake files could be found.
The error was solved by switching to CopperSpice 1.6.2.
Sorry for the confusion. CS 1.5.3 does not have the updated CMake files for installing as you discovered. We will review the CS Overview docs and add this information.

2
Should we clarify when we write [path_to_copperspice] it really means path to lib/cmake/CopperSpice but not path to the root directory of CopperSpice? It took me too much time to figure it out.
Just chatted with our CI person and yes indeed, it turns out this is platform specific. Thank you for pointing this out. Will get the docs updated.

Barbara

Post Reply