Permalink
Browse files

configure: skip useless/harmful C++/F77 checks by libtool

AC_PROG_LIBTOOL configure macro wants to run a lot of C++ and Fortran checks
Since vzctl does not use any C++ or Fortran code, those checks are useless.

But this is not a problem -- the problem is in case of there is no C++
compiler, configure fails miserably with the following diagnostics:

  checking how to run the C++ preprocessor... /lib/cpp
  configure: error: C++ preprocessor "/lib/cpp" fails sanity check

So we have a strange situation -- inability to compile C code on a system
without C++ compiler. This is weird. The word is they have fixed it in
libtool-1.5.10, but still there is no ability to skip useless C++/F77 checks
in libtool 1.5.

The word is libtool 1.6 and newer has this fixed by introducing macro
AC_LIBTOOL_TAGS. If one put AC_LIBTOOL_TAGS([]) in configure.ac, those
checks will be skipped completely. Do not forget to use that in future.
For now, this dirty hack should suffice.
  • Loading branch information...
1 parent e2d8ca8 commit 3b041b25ef06d7a9c6e0d4d9b3ec985ec3949b67 @kolyshkin kolyshkin committed Jan 11, 2007
Showing with 3 additions and 0 deletions.
  1. +3 −0 acinclude.m4
View
@@ -0,0 +1,3 @@
+# Dirty hack: remove useless/harmful C++/F77 checks invoked by libtool
+AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [:])
+AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [:])

0 comments on commit 3b041b2

Please sign in to comment.