bug-automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#11893: Regression in automake 1.12.1 on Mac OS X


From: Max Horn
Subject: bug#11893: Regression in automake 1.12.1 on Mac OS X
Date: Mon, 9 Jul 2012 19:04:39 +0200

Hi there,

I am currently looking into packaging automake 1.12.1 for Fink 
<http://www.finkproject.org/> on Mac OS X 10.7. Doing that, several test suite 
failures popped up, which I am now working through to resolve.

The first one is t/silentcxx-gcc.sh failing. Note that t/silentcxx.sh 
incorrectly (!) succeeds.

There are two problems here:

1) The C++ compiler from Sun Studio is named "CC". This caused t/silentcxx.sh 
to fail, which was fixed with commit ad5d0be02dd42c200be2ffebb1e062e96a06f80c 
in the autonconf git repository. The same fix also needs to be applied to 
t/silentcxx-gcc.sh.

2) But actually I am happy this was there, because otherwise I wouldn't have 
detected this second, more serious bug: On Mac OS X, automake 1.12.1 
incorrectly thinks the C++ compiler is named CC (when really it should be 
clang++, c++ or g++). This is because (a( OS X by default uses a case 
in-sensitive file system, and so "CC" is equivalent to "cc", and (b) the 
automake 1.12.1 code for some reason duplicate some autoconf code for detecting 
the C++ compiler, but changed this code, breaking it. To quote automake's 
configure.ac:

<BEGIN QUOTE>
# The list of C++ compilers here has been copied, pasted and edited
# from 'lib/autoconf/c.m4:AC_PROG_CXX' in the Autoconf distribution.
# Keep it in sync, or better again, find out a way to avoid this code
# duplication.
_AM_COMPILER_CAN_FAIL([AC_PROG_CXX(dnl
  [aCC CC FCC KCC RCC xlC_r xlC c++ cxx cc++ gpp g++])],
  [CXX=false; _AM_SKIP_COMP_TESTS([C++])])
<END QUOTE>

But this is what my version of c.m4 contains:
<BEGIN QUOTE>
    AC_CHECK_TOOLS(CXX,
                   [m4_default([$1],
                               [g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC 
xlC_r xlC])],
                   g++)
<END QUOTE>
i.e. the order of the compilers has been changed, and this causes the breakage 
above. 

I wonder whether this different order of compilers is intentional -- and why 
this is duplicated in automake in the first place? The comment in configure.ac 
just says that the list was duplicated, not *why*. It would be nice if it could 
be extended to explain just that by somebody who knows :).


Finally, out of curiosity: I was wondering why silentcxx-gcc.sh is there -- and 
why there isn't a silentcxx-gcc3.sh ?


Thanks,
Max




reply via email to

[Prev in Thread] Current Thread [Next in Thread]