Makefile woes in Kdevelop (was problems creating custom widget)

Ivica Bukvic ico at fuse.net
Mon Nov 26 19:35:40 GMT 2001


Hello again!

Upon advice from Waldo Bastian, I was finally able to create my custom
widget, but now I am having some Makefile problems (in Kdevelop) and am
seeking advice.

Basically, my current understanding that both Makefile.in and Makefile
files are the ones that are constantly changed based upon Makefile.am.
But what I am unsure of is how to alter Makefile.am, so that the linking
is done using $(LIBPTHREAD), which on my cpu is /usr/lib/libpthread.a,
without hard-wiring it into the Makefile, and thus losing it next time
around when Makefile is created?

What is even more weird is that even if I do include $(LIBPTHREAD) as
one of the flags (hardwired in Makefile), the Makefile never actually
replaces the LIBPTHREAD = @LIBPTHREAD@ line with LIBPTHREAD =
<path-to-libpthread-set-by-configure>/libpthread.a. Why is this the
case?

I tried "touch Makefile.am" and that did not do anything.

Finally, since I've added a new custom widget (located in QLCD.h), the
program only compiles if I manually do /usr/lib/qt2/bin/moc QLCD.h -o
QLCD.moc.o in the directory (in the shell) before compiling, since
otherwise I have no clue how to force the Makefile.am to add this to the
Makefile at the time of creation, even though I made all of the proper
includes (I've included #include "QLCD.moc.o" in the .cpp file of the
main widget class, at the end of the file), the KDevelop is completely
blind at the fact that this file needs its .moc file as well. So, my
question is how and where do I specify that this .moc file needs to be
created (my assumption is it has to go to Makefile.am, but am unsure of
where and what syntax, since Makefile.am seems rather abstract), so that
I don't have to hardwire it every time?

Finally, does anyone know if there is an easier GUI-like approach to
solving this problem within the Kdevelop, so that I can specify all this
without having to hack Makefile.am.

P.S. All of these additions/changes I've made to the Makefiles located
within the subfolder where the files in question are located so that it
is in the:

<location>/project_dir/projectname/

I have not touched the main Makefile located in the project_dir (maybe
this is one of my problems right there).

Any help would be greatly appreciated! Sincerely,

Ivica Bukvic




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



More information about the KDevelop mailing list