Re: pkg-config wisdom

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

 



Matěj,

On 10/25/2009 8:05 AM, Matěj Týč wrote:
There is one big issue with AC_SEARCH_LIBS: If you use a different
calling convention than cdecl (like stdcall, but I don't know, they've
just told me), you will get unresolved symbols if you try to link
without a proper include file (or something like that). Which means you
can't rely on that macro, especially when it concerns Windows libraries.
This is quite catastrophic, isn't it? What else than pkg-config would be

Is not this an issue with AC_CHECK_LIB also? I don't believe AC_SEARCH_LIBS suffers any greater issues than AC_CHECK_LIB.

The problem is that both macros use a common prototype for all symbols: char * funcname(void);

cdecl is assumed here, because no other calling convention attribute is supplied on the prototype.

Ralf, one possible enhancement might be to allow the user to specify the function prototype manually in an optional argument to either of these macros. This might very well solve the C++ problem, however, it wouldn't really solve the C non-cdecl calling convention issue because calling convention decoration attributes are compiler specific.

John


_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
http://lists.gnu.org/mailman/listinfo/autoconf

[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux