cmake conversion - Pb headers generated with automoc #1

Chiuso
aperto 5 anni fa da Ghost · 1 commenti
Ghost 5 anni fa ha commentato

While trying to bring cmake support in Kasablanca, I've run into something rather peculiar.

I get this error:

AUTOMOC error: 'Q_mainwindow.moc' cannot be generated.
   Reason: '/home/cethyel/Public/trinity-pot/CMAKECONV/kasablanca/src/Q_mainwindow.cpp.h' not found.

I've overcome this by generating Q_mainwindow.h manually:

tquic Q_mainwindow.ui | perl -pe "s,public TQWizard,public KWizard,g; s,#include <ntqwizard.h>,#include <kwizard.h>,g; s,public QWizard,public KWizard,g; s,#include <qwizard.h>,#include <kwizard.h>,g" >> Q_mainwindow.h ;

Same problem goes on with:

  • Q_bookmarkdialog.ui
  • Q_fileexistsdialog.ui
  • Q_mainwindow.ui
  • Q_colorspreferencesdialog.ui
  • Q_userinterfacepreferencesdialog.ui
  • Q_generalpreferencesdialog.ui
  • Q_customconnectdialog.ui
  • Q_importdialog.ui

Here is how I try to build the executable:

tde_add_executable( kasablanca AUTOMOC
  SOURCES
         kbconfig.kcfgc
         Q_bookmarkdialog.ui Q_fileexistsdialog.ui
         Q_mainwindow.ui Q_colorspreferencesdialog.ui
         Q_userinterfacepreferencesdialog.ui Q_generalpreferencesdialog.ui
         Q_customconnectdialog.ui Q_importdialog.ui
         main.cpp kasablanca.cpp bookmarkdialog.cpp customconnectdialog.cpp
         fileexistsdialog.cpp kbitem.cpp 
         eventhandler.cpp ftpthread.cpp ftplib.cpp ftpsession.cpp
         kbfileinfo.cpp kbdirinfo.cpp kbdir.cpp kbfile.cpp kbtransferitem.cpp
         kbtransferdir.cpp kbtransferfile.cpp
         kbtaskview.cpp kbbookmarkitem.cpp kbsiteinfo.cpp
         importdialog.cpp kbstatustip.cpp
  LINK tdeui-shared tdecore-shared tdeio-shared ssl crypto
While trying to bring cmake support in Kasablanca, I've run into something rather peculiar. I get this error: ``` AUTOMOC error: 'Q_mainwindow.moc' cannot be generated. Reason: '/home/cethyel/Public/trinity-pot/CMAKECONV/kasablanca/src/Q_mainwindow.cpp.h' not found. ``` I've overcome this by generating Q_mainwindow.h manually: ``` tquic Q_mainwindow.ui | perl -pe "s,public TQWizard,public KWizard,g; s,#include <ntqwizard.h>,#include <kwizard.h>,g; s,public QWizard,public KWizard,g; s,#include <qwizard.h>,#include <kwizard.h>,g" >> Q_mainwindow.h ; ``` Same problem goes on with: - Q_bookmarkdialog.ui - Q_fileexistsdialog.ui - Q_mainwindow.ui - Q_colorspreferencesdialog.ui - Q_userinterfacepreferencesdialog.ui - Q_generalpreferencesdialog.ui - Q_customconnectdialog.ui - Q_importdialog.ui Here is how I try to build the executable: ``` tde_add_executable( kasablanca AUTOMOC SOURCES kbconfig.kcfgc Q_bookmarkdialog.ui Q_fileexistsdialog.ui Q_mainwindow.ui Q_colorspreferencesdialog.ui Q_userinterfacepreferencesdialog.ui Q_generalpreferencesdialog.ui Q_customconnectdialog.ui Q_importdialog.ui main.cpp kasablanca.cpp bookmarkdialog.cpp customconnectdialog.cpp fileexistsdialog.cpp kbitem.cpp eventhandler.cpp ftpthread.cpp ftplib.cpp ftpsession.cpp kbfileinfo.cpp kbdirinfo.cpp kbdir.cpp kbfile.cpp kbtransferitem.cpp kbtransferdir.cpp kbtransferfile.cpp kbtaskview.cpp kbbookmarkitem.cpp kbsiteinfo.cpp importdialog.cpp kbstatustip.cpp LINK tdeui-shared tdecore-shared tdeio-shared ssl crypto ```
SlavekB ha aggiunto una nuova dipendenza 5 anni fa
SlavekB 5 anni fa ha commentato
Proprietario

The solution turned out to be easier than I expected. The CPP files that cause the problem should not have been part of the source code – these are generated files. Therefore, simply removing the files was enough to solve the problem. Then, instead of unintentionally processing these CPP files from the source directory, the CPP files are processed from the binary directory and therefore everything is done properly.

The solution turned out to be easier than I expected. The CPP files that cause the problem should not have been part of the source code – these are generated files. Therefore, simply removing the files was enough to solve the problem. Then, instead of unintentionally processing these CPP files from the source directory, the CPP files are processed from the binary directory and therefore everything is done properly.
SlavekB aggiunta alle pietre miliari R14.0.7 release 5 anni fa
SlavekB chiuso questo probleam 5 anni fa
Effettua l'accesso per partecipare alla conversazione.
Nessuna milestone
Nessuna assegnatario
2 Partecipanti
Notifiche
Data di scadenza

Nessuna data di scadenza impostata.

Dipende da
#2 cmake conversion
TDE/kasablanca
Riferimento: TDE/kasablanca#1
Caricamento…
Non ci sono ancora contenuti.