On 01/28/2011 01:13 PM, Riccardo Bellini wrote: > Thank you all for your replies, however I would prefer using Qt > functions rather than kde4_add_unit_test. > I finally got it to work, but I had to split the test class in .h and > .cpp files, and call qt_wrap_cpp on header file, including mocs in > sources when I call add_executable. > Another question: it's not a big problem, just for my knowledge. I had > to create a static library from my project source and link the test > executable against it, otherwise it gives some "undefined reference > to". Is there a way to get it without creating a library and link it? Try adding the needed source files to your test makefile directly instead of linking a static library. That's easy if you put the test sources inside a subdirectory of your main project. You could then add them by referencing them in your makefile using the ../ prefix.
Bye, Valentin >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<