Re: Simple question about dllimport

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Michael C wrote:
I've got a h file for a usb device that has definitions

declarations

of function
exported

imported (apparently)

from a dll. An example would be (with #defines translated):

extern "C" __declspec(dllimport) int __stdcall FT_Open(int
deviceNumber, int *pHandle);

but where is the actual dll filename specified so my program knows
where to find it?

That should be resolved during linking. Your project needs to have
the "export library" of that DLL supplied in the linker inputs.

V
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask


.



Relevant Pages

  • Re: Why is this not an error in Visual C?
    ... says that when an old-style function definition is processed, ... That is, I think, `int fint x; ... Concerning the compatibility of function ... All declarations in the same scope that refer to the same object or function ...
    (comp.lang.c)
  • Re: Why is this not an error in Visual C?
    ... int foo ... What we're looking for to describe MSVC as broken is a constraint ... involve declarations of incompatible types. ... compatibility and of a composite type, ...
    (comp.lang.c)
  • Re: Why is this not an error in Visual C?
    ... says that when an old-style function definition is processed, ... That is, I think, `int fint x; ... Concerning the compatibility of function ... All declarations in the same scope that refer to the same object or function ...
    (comp.lang.c)
  • Re: range vs precisionC
    ... volatile int a; ... in this case that is volatile. ... and we have declarations like: ... What is needed now, I think, is to realize that subtypes (and all those ad ...
    (comp.lang.c)
  • Re: [PATCH 3/7] PCI PM: Fix saving of device state in pci_legacy_suspend
    ... so the icache is going to scream but gcc folks know ... I'll see Michael what exactly the situation is here and if we ... int smp_request_message_ipi ...
    (Linux-Kernel)