Bug 242044

Summary: Some widgets are compiled 3 times.
Product: [Applications] kmymoney Reporter: Vincent Ordy <vincent>
Component: generalAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: RESOLVED FIXED    
Severity: minor    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: Suggested patch

Description Vincent Ordy 2010-06-18 03:16:01 UTC
Version:           unspecified (using Devel) 
OS:                Linux

The files in the ${_uncritial_common_sources} variable from kmymoney/widgets/CMakeLists.txt are compiled 3 times (twice when KMM_DESIGNER is not set).

libkmymoney_base.a is built from ${_uncritial_common_sources}.
kmymoneywidgets.so and libwidgets.a both depend on libkmymoney_base.a, but also have ${_uncritial_common_sources} as sources.

Moreover automoc was called with the same source files for each of these targets in the same building directory, but with different _automoc.cpp files => the moc files were regenerated.  The files were recompiled for the earlier targets the next time "make" was run.  This problem still occurs for the ${critial_common_sources}.

Reproducible: Always
Comment 1 Vincent Ordy 2010-06-18 03:17:01 UTC
Created attachment 48098 [details]
Suggested patch
Comment 2 Alvaro Soliverez 2010-06-18 03:24:35 UTC
Can you submit this through reviewboard.kde.org? It will be easier to follow, since there are multiple involved on the build system.

Thanks for your contribution, once again!
Comment 3 Vincent Ordy 2010-06-18 04:39:17 UTC
Sure, I've prepared it: http://reviewboard.kde.org/r/4379/

It's a draft, I can't publish it until I assign it to someone but I couldn't find your account ou ipwizard's on reviewboard.
Comment 4 Alvaro Soliverez 2010-06-18 04:43:41 UTC
My account is asoliverez, and the group is kmymoney. Assigning it to the group should do the trick.
Comment 5 Thomas Baumgart 2010-06-18 16:56:51 UTC
SVN commit 1139531 by tbaumgart:

- Remove useless library dependencies
- Remove ${_uncritial_common_sources} from kmymoneywidgets.so and libwidgets.a.  They are both linked to libkmymoney_base.a, which is built from ${_uncritial_common_sources}.  => the ${_uncritial_common_sources} files were built 3 times.
BUG: 242044

 M  +1 -1      CMakeLists.txt  
 M  +7 -9      widgets/CMakeLists.txt  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1139531