Subject: bug#9755: 24.0.90; trying to configure with GCC 4.6.1 on intel Mac OS X 10.6.8

From: Glenn Morris <[email-masked]>
Date: Wed, 16 May 2012 03:17:40 -0400

close 9755 24.2
stop

Peter Dyballa wrote:

> The configure scripts adds "-no-cpp-precomp" to CPPFLAGS although GCC
> 4.6.1 does not support this Apple addition:

The history here is that -no-cpp-precomp was needed for some reason with
some older versions of Apple's version of gcc. The Emacs configure
script unconditionally set CPP to 'cc -E -no-cpp-precomp' on all darwin
builds for this reason, without bothering to test which compiler was
being used.

This is not too much of an issue in gcc prior to 4.6, because gcc
-no-foo returns status 0, even when -no-foo is an unknown option
(it warns but continues). In gcc 4.6 and later, it returns an error.

Hence Emacs 24.1 will not configure with gcc 4.6 and later on OS X.

The Hydra darwin builds of Emacs seem to have been failing for this
reason for some time.

I just installed a change to the trunk to hopefully fix this (r108250).

It might be better to just remove this -no-cpp-precomp altogether.
AFAICS, it is only needed for Apple gcc earlier than 3.3 (not sure).
That is pretty old.

This might be something to backport to 24.1, I'm not sure.
The patch might need altering if bug#11485 is fixed in 24.1.

Also even after making this change, the build fails during dumping.
http://debbugs.gnu.org/9927
http://hydra.nixos.org/build/2630203