TelepathyIM / telepathy-morse

Telegram connection manager for the Telepathy framework
GNU General Public License v2.0
62 stars 10 forks source link

debug.moc missing? #25

Closed gasinvein closed 8 years ago

gasinvein commented 8 years ago

After commit f2b999e I am getting this build error (with telepathy-qt 0.9.7):

/home/gasinvein/rpmbuild/BUILD/telepathy-morse-0.0.1.git20160812/debug.cpp:117:21: fatal error: debug.moc: No such file or directory
 #include "debug.moc"
                     ^
compilation terminated.
Kaffeine commented 8 years ago

Hi.

I'm sorry for the issue. I pushed the correct implementation to the master branch, but didn't update the dev. The same case had a place with TelegramQt. I just synced both dev branches to master (all "experimental" stuff is polished enough to be in master). seems to be unrelated.

Kaffeine commented 8 years ago

I think you're talking about commit f5353de54b34a75a37eb45c0dcbb972fbb69b3c8, because I introduced debug.moc there. Still, it's very strange, because with AUTOMOC TRUE ( source, documentation ) CMake should parse source files for the .moc inclusion and run moc to generate all needed files. Works for me, but I would investigate. What is your CMake version?

Kaffeine commented 8 years ago

@gasinvein , do you still have this issue? I tested build on several systems and it works everywhere.

gasinvein commented 8 years ago

Yes. Maybe I'm doing something wrong? cmake 3.6.1, telepathy-qt5 0.9.7, telegram-qt5 from git, openSUSE Tumbleweed

gasinvein commented 8 years ago

@Kaffeine, found the problem. debug.moc is created in build directory, not in source one. So if I run cmake and make outside source directory, gcc can't find debug.moc, I guess.

Kaffeine commented 8 years ago

I always do "out of source" build, so this should not be a problem.

Kaffeine commented 8 years ago

Fixed by commit 399398640460d047ee80432ccec9a2bb19b0ab80

The build didn't work indeed. Distros don't ship telepathy-qt-0.9.7 package yet, so I used a bundle to build all three TelepathyQt, TelegramQt and Telepathy-Morse at once (out of tree). It seems that it worked for me because some flags from TelepathyQt cmake file affected my morse build.

@gasinvein, thank you so much!

Kaffeine commented 8 years ago

I had a script which generates and install packages one by one, but I lost it two months ago. Now I'm sure I should write it again and use it to test builds.