kde and moc files

Matthias Kretz kretz at kde.org
Wed May 14 17:16:02 BST 2008


On Tuesday 13 May 2008, Alexander Neundorf wrote:
> On Tuesday 13 May 2008, Alexander Neundorf wrote:
> > On Monday 12 May 2008, André Wöbbeking wrote:
> > > I had a similar issue with kdelibs/kate/expand...model...
> > >
> > > I tried:
> > > 1) rm expand...moc
> > > 2) touch CMakeLists.txt
> > > 3) touch expand...{h,cpp}
> > >
> > > nothing worked for me so I removed the complete kdelibs build dir. I'm
> > > using CMake 2.4.x (whatever is in ubuntu 8.10).
> >
> > I could have saved a lot of time if I would have updated my
> > kdesupport/automoc/ before... I missed the last change from last week,
> > which seems to have caused these issues.
>
> Ok, it seems it currently doesn't work as it should.
> Please update automoc from svn.
> The new automoc generates a file "<target>_automoc.cpp.notclean", which now
> the target depends on.
> To enforce regenerating the moc files for a target, delete that file.

My fault. I didn't test whether QFile::open/close would update the timestamp. 
It doesn't, but it seemed it did when I tested it.

The real fix is to make <target>_automoc.cpp.files newer than 
<target>_automoc.cpp. AFAICT the only sensible way to do that is to use 
utime(2) which is part of POSIX.1-2001. and therefore hopefully portable to 
all platforms automoc is supposed to run on.

I committed to kdesupport. When you still have problems then it's because 
automoc4 doesn't get run and doesn't get a chance to update the .files 
timestamp. In that case either do a make clean or simply a "touch 
**/*_automoc.cpp.files"

-- 
________________________________________________________
Matthias Kretz (Germany)                            <><
http://Vir.homelinux.org/
MatthiasKretz at gmx.net, kretz at kde.org,
Matthias.Kretz at urz.uni-heidelberg.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080514/2ae666f2/attachment.sig>


More information about the kde-core-devel mailing list