Edit

kc3-lang/automake/m4/minuso.m4

Branch :

  • Show log

    Commit

  • Author : Alexandre Duret-Lutz
    Date : 2004-09-10 20:03:28
    Hash : b8df7624
    Message : * m4/minuso.m4 (AM_PROG_CC_C_O): Make sure AC_PROG_CC is never called after this macro. * tests/distname.test, tests/subdir5.test, tests/subdir8.test, tests/subobj.test, tests/subobj4.test, tests/subobj5.test, tests/subobj6.test: Adjust. Report from Ralf Wildenhues.

  • m4/minuso.m4
  • # serial 2
    
    # AM_PROG_CC_C_O
    # --------------
    # Like AC_PROG_CC_C_O, but changed for automake.
    
    # Copyright (C) 1999, 2000, 2001, 2003, 2004 Free Software Foundation, Inc.
    
    # This program is free software; you can redistribute it and/or modify
    # it under the terms of the GNU General Public License as published by
    # the Free Software Foundation; either version 2, or (at your option)
    # any later version.
    
    # This program is distributed in the hope that it will be useful,
    # but WITHOUT ANY WARRANTY; without even the implied warranty of
    # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    # GNU General Public License for more details.
    
    # You should have received a copy of the GNU General Public License
    # along with this program; if not, write to the Free Software
    # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
    # 02111-1307, USA.
    
    AC_DEFUN([AM_PROG_CC_C_O],
    [AC_REQUIRE([AC_PROG_CC_C_O])dnl
    AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
    AC_REQUIRE_AUX_FILE([compile])dnl
    # FIXME: we rely on the cache variable name because
    # there is no other way.
    set dummy $CC
    ac_cc=`echo $[2] | sed ['s/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/']`
    if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" != yes"; then
       # Losing compiler, so override with the script.
       # FIXME: It is wrong to rewrite CC.
       # But if we don't then we get into trouble of one sort or another.
       # A longer-term fix would be to have automake use am__CC in this case,
       # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
       CC="$am_aux_dir/compile $CC"
    fi
    dnl Make sure AC_PROG_CC is never called again, or it will override our
    dnl setting of CC.
    m4_define([AC_PROG_CC],
              [m4_fatal([AC_PROG_CC cannot be called after AM_PROG_CC_C_O])])
    ])