Copyright 2004 by M. Uli Kusterer Fri, 29 Nov -1901 11:06:32 GMT Comments on article blog-shared-precompiled-headers at Zathras.de http://www.zathras.de/angelweb/blog-shared-precompiled-headers.htm blog-shared-precompiled-headers Comments witness_dot_of_dot_teachtext_at_gmx_dot_net (M. Uli Kusterer) witness_dot_of_dot_teachtext_at_gmx_dot_net (M. Uli Kusterer) en-us Comment 1 by Chris Hanson http://www.zathras.de/angelweb/blog-shared-precompiled-headers.htm#comment1 http://www.zathras.de/angelweb/blog-shared-precompiled-headers.htm#comment1 Chris Hanson writes:
It's only really a problem to share these precompiled headers if they're actually incompatible. Generally Xcode tries to be aggressive about calculating the hash of settings it uses to determine whether headers should be shared; look inside the cached precompiled header folder to see what criteria it actually used.

For example, if you're using gcc 4.0, the same set of preprocessor definitions, the same precompiled header name, and the contents of your prefix files are the same, there should be no issue sharing the precompiled versions among multiple projects - even projects representing v1.0 and v2.0 of the same product.

It's only if there's some criteria that should be affecting whether Xcode thinks they're the same but isn't that they shouldn't be shared. And if you've found that to be the case, please please please file a bug report and describe what that criteria is. Again, you can take a look inside the shared, precompiled prefix file to see what the hashing criteria were; it can be useful to include this information in your bug report along with the build settings that you think should be influencing sharing but aren't.