Automatic moc generation

Mickael Faivre-Macon mickael at
Fri Aug 22 15:42:51 BST 2003

Hi Sigmund and Alexandro,

Thanks for the replies !

> If you generated your project with KDevelope then it should automatically 
> generate *.moc files, and compile them, when you build the project. 

Yes, I generated it with KDevelop using the wizard and using "Generate a
QWidject child class" but I switched from Mandrake to Red Hat making a
source backup only (stupid of me), then I have created a new project and
loaded the classes in the project. It worked from the Qt .ui files (the
moc are generated) but KDevelop does not generate the moc files
automatically for the other classes like before.

If the wizard can tell KDevelop to generate a QWidget child class, how
can we do it manually ? Do we have to modify the makefile by hand ? I
don't know what to modify.

> (in reality, kdevelop generates a
>, which automake uses to create a Makefile).

Do you know what to change in this .am file in order that the makefile
call the moc compiler automatically so I don't have to call it my hand
every time I want to compile my project ? I just want this process to be
automatic to save time.


Free SMS:

to unsubscribe from this list send an email to kdevelop-request at with the following body:
unsubscribe »your-email-address«

More information about the KDevelop mailing list