[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
ac_ext problems
From: |
Werner LEMBERG |
Subject: |
ac_ext problems |
Date: |
Mon, 02 May 2005 13:09:22 +0200 (CEST) |
At least the MSVC compiler doesn't like `foo.cc' as names for C++
files. A longer time ago, I've changed the extension of all C++ files
in groff to `foo.cpp', and this indeed works with all tested platforms
(thanks to Nelson Beebe).
Is there any reason to stay with `.cc' as the extension for C++ files
for the autoconf tests, given that `.cpp' is much more portable?
Thus I suggest the patch below.
Werner
======================================================================
--- c.m4.old 2005-02-27 18:06:35.000000000 +0100
+++ c.m4 2005-05-02 13:04:43.309329920 +0200
@@ -90,7 +90,7 @@
# ------------
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
m4_define([AC_LANG(C++)],
-[ac_ext=cc
+[ac_ext=cpp
ac_cpp='$CXXCPP $CPPFLAGS'
ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&AS_MESSAGE_LOG_FD'
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS
conftest.$ac_ext $LIBS >&AS_MESSAGE_LOG_FD'
- ac_ext problems,
Werner LEMBERG <=