public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* RE: Trying to link an MSVC DLL with a Cygwin Application
@ 2004-05-04  9:07 Arash Partow
  0 siblings, 0 replies; 7+ messages in thread
From: Arash Partow @ 2004-05-04  9:07 UTC (permalink / raw)
  To: cygwin

Hi David,

That is a false assumption, I have been able to link a REAL win32 dll
against a cygwin application however linking a cygwin compiled dll
into a MSVC app is where you will come into troubles. This is because
neither cygwin's or ming's dlltool create dlls as specified by MS's
dll specification.

The name mangling is an issue from VC++ POV not the other way round.


My experience comes from building a win32 dll in Borland C++ builder
then having a simple console based cygwin gcc compiled app exercise
the dll's API - which btw was successful.




Arash Partow

__________________________________________________
Be one who knows what they don't know,
Instead of being one who knows not what they don't know,
Thinking they know everything about all things.
http://www.partow.net




>>From: john george
>>
>>I'm trying to link a MSVC++  created DLL with a cygwin
>>application.
>>
>>...
>>
>>This gives me undefined refernce to function name ...
>>
>>Is there anything that I'm missing?
>
>The g++ and MSVC++ mangle C++ names differently.  This makes
>it very difficult (perhaps impossible) to link a MSVC++ created DLL with a 
>g++ compiled (cygwin or mingw) application.
>
>--
>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/







.

_________________________________________________________________
Personalise your mobile chart ringtones and polyphonics. Go to  
http://ringtones.com.au/ninemsn/control?page=/ninemsn/main.jsp


--
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/

^ permalink raw reply	[flat|nested] 7+ messages in thread
* RE: Trying to link an MSVC DLL with a Cygwin Application
@ 2004-05-04  5:23 Billinghurst, David (CALCRTS)
  2004-05-04  5:57 ` john george
  0 siblings, 1 reply; 7+ messages in thread
From: Billinghurst, David (CALCRTS) @ 2004-05-04  5:23 UTC (permalink / raw)
  To: john george, cygwin

> From: john george
>
> I'm trying to link a MSVC++  created DLL with a cygwin
> application. 
>
> ...
>
> This gives me undefined refernce to function name ...
> 
> Is there anything that I'm missing?

The g++ and MSVC++ mangle C++ names differently.  This makes
it very difficult (perhaps impossible) to link a MSVC++ 
created DLL with a g++ compiled (cygwin or mingw) application.

--
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/

^ permalink raw reply	[flat|nested] 7+ messages in thread
* Trying to link an MSVC DLL with a Cygwin Application
@ 2004-05-04  5:07 john george
  0 siblings, 0 replies; 7+ messages in thread
From: john george @ 2004-05-04  5:07 UTC (permalink / raw)
  To: cygwin

Hi ,
I'm trying to link a MSVC++  created DLL with a cygwin
application. Could you please provide me any useful
link realted to this issue.
I'm trying the following commands but it doesn't seem
to work:

Trying to convert the MSVC++ created DLL to a shared
lib using the dlltool

dlltool --def test.def --dllname msvctest.dll
-llibtest.a
(test.def has the exported symbol names)

I keep this libtest.a in the /lib directory so that
there won't be any LD_LIBRARY_PATH related issues.
After this step I try 

gcc mytest.c -ltest

This gives me undefined refernce to function name ...

Is there anything that I'm missing?

Regards,
john




	
		
__________________________________
Do you Yahoo!?
Win a $20,000 Career Makeover at Yahoo! HotJobs  
http://hotjobs.sweepstakes.yahoo.com/careermakeover 

--
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/

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2004-05-05 16:58 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-05-04  9:07 Trying to link an MSVC DLL with a Cygwin Application Arash Partow
  -- strict thread matches above, loose matches on Subject: below --
2004-05-04  5:23 Billinghurst, David (CALCRTS)
2004-05-04  5:57 ` john george
2004-05-04 13:47   ` Igor Pechtchanski
2004-05-04 18:10   ` Jörg Schaible
     [not found]     ` <4098984F.8010505@luukku.com>
2004-05-05 16:58       ` Jörg Schaible
2004-05-04  5:07 john george

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).