Re: Can I use a DLL compiled with bcc with a program compiled with gcc?
- From: gswork@xxxxxxxxxxxx
- Date: 21 Jun 2005 06:28:06 -0700
rozniy wrote:
> Can I use a DLL compiled with bcc with a program compiled with gcc (on
> Windows)?
in principle yes - any well written Win32 DLL is available to any other
development tool able to call it - whether it be another tool of the
same language or something else like VB or Delphi.
> Err, here's the background to my little problem. I'm using Dev-C++ (an
> IDE that uses gcc) with wxWidgets to create a GUI for a certain
> program (on Windows). The program is supposed to use this Data
> Acquisition card... but because of bureuacratic delays, I completed
> the GUI before the card arrived.
>
> WHen the card arrived, I saw, to program for the card, the provided
> libraries are for Visual C++ and Borland C++ (ending with ".lib"), and
> no provision for open source compilers (library files ending with
> ".a")...
Ah! Those aren't compiled DLL's but libraries for use with your
compiler as you would have noted with dissapointment!
> Dear oh dear oh dear...
>
> After thinking for a bit, I had 2 options:
> 1) Download wxWidgets for use with Visual C++, use the provided Data
> Acquisition libraries, and recompile my program
>
> 2) or... use Visual C++ or Borland C++ to create a dll using the
> provided .lib, to use with the original code, and recompile all with
> Dev-C++.
>
> Option 2 seems like less work... but I have doubts. I'm just learning
> to create dll's, so I'm a little fuzzy. Might it work?
there are certain things to remember when writing a DLL - a good Win32
book will explain them, there are also tutorials and code examples on
the www (though the quality varies). once you get the structure right,
the DllMain, imports/exports etc the rest is reasonably
straightforward.
msdn has an article about creating dll's here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore98/html/_core_prepare_the_win32_dll_for_use.asp
which may be of use if you use VC to make one.
Windows specific programming groups can help with the more indepth stuff
.
- References:
- Prev by Date: Re: Which programming language is better to start
- Next by Date: Re: puzzle
- Previous by thread: Can I use a DLL compiled with bcc with a program compiled with gcc?
- Index(es):
Relevant Pages
|