Shorter build times

Peter Kümmel syntheticpp at gmx.net
Sun Apr 29 14:18:53 BST 2007


David Faure wrote:
> So how do I tell the system that kconfigbackend.cpp is not const, i.e. has been modified?
> I forgot again how it's supposed to work exactly, and neither the patch nor the generated
> file has much documentation... Can you add docu to the generated file (which will therefore
> appear in the patch) to explain what people are supposed to do to benefit from this feature?
> 

This is now at the top of the master file:

// autogenerated file
//
//   * clear this file to build it again by a cmake run
//
//   * This file is the master file of the merged-file build.
//     In this file all files are included which could be assumed as untouched.
//     By default this file includes all files, as it is done by the KDE4_ENABLE_FINAL build.
//     The difference to the KDE4_ENABLE_FINAL build is that it is possible to exclude
//     source files from this file. By this it is possible to work on these files without
//     losing the advantage of the faster compilation of the KDE4_ENABLE_FINAL build.
//
//   * To compile a file separately suppress the including in this file
//     and comment out the corresponding macro definition, for instance:
//
//        //#define kdesktopfile___ASSUME_CONST
//        #if defined(kdesktopfile___ASSUME_CONST) && !defined(DONT_INCLUDE_CONST_FILES)
//        //#include "/home/user_name/kde/kdelibs/kdecore/config/kdesktopfile.cpp"
//        #endif
//
//     or delete these lines.


and in the other generated files which are also part of the build process:

// autogenerated file
//
//    * clear this file to build it again by cmake
//
//    * don't touch this file compile separately the code included by this file.
//      change C:/sandbox/kde/b/kdecore/_merged_kdecore_files.cpp, see explanation there.

// look for touched  files


This time attached a patch which is supposed for submitting, the last one
was only for demonstration.

The patch introduces the new command line option KDE4_ENABLE_MERGED which
effectively only switches to a other KDE4_CREATE_FINAL_FILES macro implementation.
The build with KDE4_ENABLE_FINAL is still available and is not changed
by this patch.

After a first cmake run the generated files are not generated again unless
one uses the KDE4_MERGED_REBUILD option. To re-generate one file by a
cmake run one have to delete or clear it.


Peter








-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: kde4_enable_merged.patch
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20070429/42365cd6/attachment.ksh>


More information about the kde-core-devel mailing list