[ccache] Bail out on -arch?
bauerb at chromium.org
Tue May 11 05:03:36 MDT 2010
On Tue, May 11, 2010 at 11:04, Martin Pool <mbp at canonical.com> wrote:
> On 11 May 2010 10:47, Bernhard Bauer <bauerb at chromium.org> wrote:
>> Hi Joel,
>> I'm currently trying to get ccache to work under Mac OS X for the
>> Chromium build. In ccache 3.0pre1, there is a change to bail out early
>> on the -arch flag, which is used by xcodebuild (the standard OS X
>> build tool), because it's "too hard". What do you mean by that? Is
>> there a way to accept the flag if I know that I'm always compiling
>> with the same -arch option (i.e. i386)? So far I have been using
>> ccache with -arch without any problems.
> I don't know in detail but the manpage says
> FSF GCC on Darwin does not create "fat" object files; it will
> create an object file for the single architecture that it was built
> to target. Apple's GCC on Darwin does create "fat" files if
> multiple -arch options are used; it does so by running the compiler or
> linker multiple times and joining the results together with lipo.
> that sounds potentially complex to me. Perhaps ccache could at least
> cope with at least the case where only one is given.
I agree, with a single -arch option gcc should behave fully identical.
And even with multiple architectures we should be fine, because ccache
doesn't really depend on the output format of the compiler, as long as
the semantics of how the output file depends on the input files and
the compiler options are the same.
More information about the ccache