This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: undefined reference to `_CAPI_INSTALLED@0', why?


----Original Message----
>From: Gerrit P. Haase
>Sent: 30 June 2005 21:09

> Ok, I try to build a Cygwin application that requires CAPI functions
> which are installed with the drivers for an ISDN card, the DLL is named
> capi2032.dll, I have an import library which comes from the manufacturer
> AVM but this contains symbols not included in the DLL or elsewhere.
> 
> In the .lib library are these symbols:
> 
> $ nm capi2032.lib | grep ' T '

> 00000000 T _CAPI_INSTALLED@0

  That's a stdcall symbol.

> in the import library I created are these symbols:
> 
> $ nm libcapi2032.dll.a | grep ' T '

> 00000000 T _CAPI_INSTALLED

  That's a cdecl symbol.

> Where does the @0 in capi20.o: _CAPI_INSTALLED@0 came from?

  It comes from it being a stdcall symbol.
 
> I see in the source:
> 
> extern DWORD APIENTRY CAPI_INSTALLED (void);
> 
> unsigned CAPI20_ISINSTALLED (void) {
> #if defined(CYGWIN) || defined(WIN32)
>      return (unsigned)CAPI_INSTALLED () == 0;
> #elif defined(LINUX)
>      return capi20_isinstalled() == CapiNoError;
> #endif
> 
> 
> So why does the compiler creats a reference to _CAPI_INSTALLED@0 or
> is it the linker who wants to resolve CAPI_INSTALLED with @0 attached.

  Has the definition of APIENTRY has changed between the mfr's build from
which the import library came and the build from which you generated your
import lib?

    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]