LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-15-2008, 02:32 AM   #1
binarybob0001
Member
 
Registered: Dec 2004
Distribution: Debian Wheezy
Posts: 444

Rep: Reputation: 30
kdevelop 3.5.1 won't compile


I'm trying to compile kdevelop 3.5.1 on Slackware 12.0. When I try to make it I get an error. Here's the output.
Code:
make  all-recursive
make[1]: Entering directory `/home/bobby/kdevelop-3.5.1'
Making all in lib
make[2]: Entering directory `/home/bobby/kdevelop-3.5.1/lib'
Making all in util
make[3]: Entering directory `/home/bobby/kdevelop-3.5.1/lib/util'
/bin/sh ../../libtool --silent --tag=CXX   --mode=compile g++ -DHAVE_CONFIG_H -I. -I../.. -I../../lib/compat  -I../../lib/interfaces  -I../../lib/sourceinfo  -I/usr/lib/qt/include -I.   -DQT_THREAD_SUPPORT  -D_REENTRANT  -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -O2 -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common -DQT_CLEAN_NAMESPACE -DQT_NO_ASCII_CAST -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION  -MT blockingkprocess.lo -MD -MP -MF .deps/blockingkprocess.Tpo -c -o blockingkprocess.lo blockingkprocess.cpp
In file included from blockingkprocess.cpp:105:
blockingkprocess.moc:12:2: error: #error "The header file 'blockingkprocess.h' doesn't include <QObject>."
blockingkprocess.moc:20: error: expected constructor, destructor, or type conversion before 'static'
blockingkprocess.moc:47: error: 'const QMetaObject BlockingKProcess::staticMetaObject' is not a static member of 'class BlockingKProcess'
blockingkprocess.moc:47: error: variable 'const QMetaObject BlockingKProcess::staticMetaObject' has initializer but incomplete type
blockingkprocess.moc:49: error: 'qt_meta_data_BlockingKProcess' was not declared in this scope
blockingkprocess.moc:52: error: prototype for 'const QMetaObject* BlockingKProcess::metaObject() const' does not match any in class 'BlockingKProcess'
blockingkprocess.h:33: error: candidate is: virtual QMetaObject* BlockingKProcess::metaObject() const
blockingkprocess.moc:52: error: 'const QMetaObject* BlockingKProcess::metaObject() const' cannot be overloaded
blockingkprocess.h:33: error: with 'virtual QMetaObject* BlockingKProcess::metaObject() const'
blockingkprocess.moc: In member function 'const QMetaObject* BlockingKProcess::metaObject() const':
blockingkprocess.moc:54: error: cannot convert 'QMetaObject* (*)()' to 'const QMetaObject*' in return
blockingkprocess.moc: At global scope:
blockingkprocess.moc:57: error: no 'void* BlockingKProcess::qt_metacast(const char*)' member function declared in class 'BlockingKProcess'
blockingkprocess.moc: In member function 'void* BlockingKProcess::qt_metacast(const char*)':
blockingkprocess.moc:62: error: 'qt_metacast' is not a member of 'KProcess'
blockingkprocess.moc: At global scope:
blockingkprocess.moc:65: error: 'int BlockingKProcess::qt_metacall' is not a static member of 'class BlockingKProcess'
blockingkprocess.moc:65: error: incomplete type 'QMetaObject' used in nested name specifier
blockingkprocess.moc:65: error: expected primary-expression before 'int'
blockingkprocess.moc:65: error: expected primary-expression before 'void'
blockingkprocess.moc:65: error: initializer expression list treated as compound expression
blockingkprocess.moc:66: error: expected ',' or ';' before '{' token
blockingkprocess.moc:81: error: expected constructor, destructor, or type conversion at end of input
This looks like the output the compiler gives when moc is not run on a .cpp file, but why isn't this being done?
 
Old 05-15-2008, 04:59 AM   #2
binarybob0001
Member
 
Registered: Dec 2004
Distribution: Debian Wheezy
Posts: 444

Original Poster
Rep: Reputation: 30
Ok, I know what's going on. I recently installed qt-4.4.0 and hence installed another version of moc which requires that the header file QtCore/QObject, not qobject.h, be included in a header file which includes Q_OBJECT. The problem is that the moc generated from my qt-4.4.0 installation conflicts with the moc generated from my qt-3.3.0 installation. Both versions are included in my PATH variable. One located in /usr/bin, the other in /usr/lib/qt/bin.
Code:
bobby@Veronica:~$ echo $PATH
/usr/local/bin:/usr/bin:/bin:/usr/games:/usr/lib/java/bin:/usr/lib/java/jre/bin:/usr/lib/qt/bin:/usr/share/texmf/bin:.
How do I tell make which moc to use explicitly? Currently, the moc used defaults to 4.4.0 version.
 
Old 11-19-2008, 11:09 AM   #3
Peterius
Member
 
Registered: May 2004
Distribution: Gentoo, Debian, OpenBSD, NetBSD
Posts: 158

Rep: Reputation: 16
You probably figured this out months ago, being that its now mid november, but you would need to use "./configure --with-qt-dir=/path/to/qt3" where the moc is in the bin directory in that path.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Qt Designer + KDevelop doesn't compile pixmaps nirj Programming 1 09-28-2006 06:49 PM
can't compile kdevelop from source gaddargarson Slackware 5 06-30-2006 06:08 AM
Kdevelop saying I can't compile C++ programs tmchardy Programming 6 03-08-2006 08:45 PM
odd kdevelop compile error shishimo Linux - Software 0 01-27-2005 01:44 PM
kdevelop compile problems Phalloides Linux - Software 0 01-22-2005 09:04 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:29 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration