autoconf
[Top][All Lists]
Advanced

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

Re: Objections? Re: Checking for CXX libraries -- AC_CXX_CHECK_LIB ?


From: Sebastian Huber
Subject: Re: Objections? Re: Checking for CXX libraries -- AC_CXX_CHECK_LIB ?
Date: Mon, 30 Sep 2002 18:28:38 -0700

Hello,
I think that AC_CXX_CHECK_LIB fits not very good into the AC_LANG_PUSH ... 
concept but I suppose there is no chance to avoid a new function. The problem 
with AC_CHECK_LIB is that it uses C linkage for C++ libraries. I think the 
interface to a C++ library check should look like:

AC_CXX_CHECK_LIB (LIBRARY, DECLARATION-SECTION,CALL-SECTION,
        [ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND], [OTHER-LIBRARIES])

If someone uses header files in the DECLARATION-SECTION he is responsible to 
check them. If header files are not availible, she can write the necessary 
declarations explicitly.

An alternative is to write no new function, but place a hint into the 
documentation that you cannot use AC_CHECK_LIB for C++ an should use 
AC_TRY_LINK.

Ciao
        Sebastian




reply via email to

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