Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread Till Oliver Knoll
Am 19.02.2014 um 05:10 schrieb Constantin Makshin cmaks...@gmail.com: Look at the problem from the other side: 1) separate moc_*.cpp has to be compiled only during full [re]builds or when the corresponding class' header file is changed; 2) when moc_*.cpp is #include-d into the implementation

Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread Yves Bailly
Le 19/02/2014 09:21, Till Oliver Knoll a écrit : - Use the private *d idiom (there is a name for it which I don't recall at the moment) The pimpl (pointer to implementation) idiom, or Cheshire cat. http://en.wikipedia.org/wiki/Pimpl see also

Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread Till Oliver Knoll
Am 19.02.2014 um 09:28 schrieb Yves Bailly yves.bai...@sescoi.fr: Le 19/02/2014 09:21, Till Oliver Knoll a écrit : - Use the private *d idiom (there is a name for it which I don't recall at the moment) The pimpl (pointer to implementation) idiom, or Cheshire cat. Yes, the cat it was ;)

Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread Gisle Vanem
Till Oliver Knoll till.oliver.kn...@gmail.com wrote: With regards to 1): A ful rebuild takes the time it takes, no matter what. You can speed that up things as others have suggested (#include the mocced files, AUTOMOC), but that's that. What about using pre-compiled headers (pch) with

Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread Till Oliver Knoll
Am 19.02.2014 um 09:51 schrieb Gisle Vanem gva...@yahoo.no: ... I ask since I've not tried it. I'm not sure it's possible to use MSVC's PCH with Qt. Ah yes, precompiled headers will also help speed-up (subsequent) full rebuilds. That is supported by qmake, depending on the

Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread Konstantin Tokarev
19.02.2014, 12:52, Gisle Vanem gva...@yahoo.no: Till Oliver Knoll till.oliver.kn...@gmail.com wrote:  With regards to 1): A ful rebuild takes the time it takes, no matter what.  You can speed that up things as others have suggested (#include the mocced files,  AUTOMOC), but that's that.

Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread Till Oliver Knoll
Am 19.02.14 09:21, schrieb Till Oliver Knoll: ... When you follow those advises and really need to change a header in some lower library class then the impact will be kept to a minimum :) Just to get an idea from my pet project which mostly follows the advices I gave: Number of header files

Re: [Interest] Compile Speed Question regarding MOC

2014-02-19 Thread andre
On Wed, Feb 19, 2014 at 09:21:01AM +0100, Till Oliver Knoll wrote: Am 19.02.2014 um 05:10 schrieb Constantin Makshin cmaks...@gmail.com: Look at the problem from the other side: 1) separate moc_*.cpp has to be compiled only during full [re]builds or when the corresponding class' header

[Interest] Compile Speed Question regarding MOC

2014-02-18 Thread Michael Jackson
I have what seems to be an obvious question/answer but the subtleties may not be what I think they are. We have a project with about 500 files most of which inherit from QObject or QWidget which means they all have moc run on them. Currently I have each moc created file compiled as a separate

Re: [Interest] Compile Speed Question regarding MOC

2014-02-18 Thread Stephen Kelly
On Tuesday, February 18, 2014 17:04:54 Michael Jackson wrote: I have what seems to be an obvious question/answer but the subtleties may not be what I think they are. We have a project with about 500 files most of which inherit from QObject or QWidget which means they all have moc run on them.

Re: [Interest] Compile Speed Question regarding MOC

2014-02-18 Thread Tony Rietwyk
Mike wrote: Sent: Wednesday, 19 February 2014 9:05 AM I have what seems to be an obvious question/answer but the subtleties may not be what I think they are. We have a project with about 500 files most of which inherit from QObject or QWidget which means they all have moc run on them.

Re: [Interest] Compile Speed Question regarding MOC

2014-02-18 Thread Michael Jackson
On Feb 18, 2014, at 7:48 PM, Tony Rietwyk t...@rightsoft.com.au wrote: Mike wrote: Sent: Wednesday, 19 February 2014 9:05 AM I have what seems to be an obvious question/answer but the subtleties may not be what I think they are. We have a project with about 500 files most of which

Re: [Interest] Compile Speed Question regarding MOC

2014-02-18 Thread Constantin Makshin
Look at the problem from the other side: 1) separate moc_*.cpp has to be compiled only during full [re]builds or when the corresponding class' header file is changed; 2) when moc_*.cpp is #include-d into the implementation .cpp file, they are both compiled at every change. I think it's pretty