cmake conversion - Pb headers generated with automoc #1

Kapalı
Ghost tarafından 5 yıl önce açıldı · 1 yorum
Ghost 5 yıl önce yorum yaptı

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 yeni bir 5 yıl önce bağımlılığı eklendi
SlavekB 5 yıl önce yorum yaptı
Sahibi

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 5 yıl önce R14.0.7 release kilometre taşına ekledi
SlavekB 5 yıl önce konusunu kapattı
Bu konuşmaya katılmak için oturum aç.
Kilometre Taşı Yok
Atanan Kişi Yok
2 Katılımcı
Bildirimler
Bitiş Tarihi

Bitiş tarihi atanmadı.

Bağımlılıklar
#2 cmake conversion
TDE/kasablanca
Referans: TDE/kasablanca#1
Yükleniyor…
Henüz bir içerik yok.