Subject: exported variables from dll
From: [email-masked] ("Philippe GIACINTI")

12 Jun 1997 23:14:36 -0700
Approved: [email-masked]
Distribution: cygnus
Message-ID: <[email-masked]>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Face: ^cJc2\tiS@#Ja@7laz+N]T)kL{-Kay)Oz"?}p[wuY#}}dO"enP!QVO{,}&4P2V[hEfJD]9&
             E1ou~|tY/|9d&7c,7yf>7n: Zj8FD(LtPXWHzy^OJIDi/~O~R]3x/5}"7P;|,*%f:3Z!>h8Ff/&)g?/
             }$RXQ
X-Mailer: Z-Mail (3.2.3 08feb96 MediaMail)
Original-To: [email-masked]
Original-Sender: [email-masked]

Hi,

First off, I am new in the list, I'm working with Cygwin32 b18 since a couple
of weeks and I think it's really a great job ...

I have to port an Unix application which is based on plugins and shared
libraries on Windows NT 4.0, and I have some troubles with dll:

I wish to define some variables in a dll and use them in another, on Unix I
have no problems: the variable is defined global in one .cc and extern in
another.
If I use the same code in Cygwin32, it seems that each dll have a local copy of
this variable ( ie: the addresses are different ).
I tried to do this with VisualC++, and it works if I use the directive
DllImport instead of extern.

( in fact I have this problem in a dll which uses stdout, I found that
"_impure_ptr" was correctly initialized in main, but was null in the dll )

I'm really new in Cygwin32 and Windows environment, and I think (hope) it comes
from my ignorance.

Thanks for your help.

-- 

 ==========================================================================
|                         Philippe GIACINTI                                |
|                                                                          |
| DALiM GmbH R&D                                email:  [email-masked]      |
| Daimler Strasse 2,                            tel:    +49.7851.9196-28   |
| D-77694 Kehl-Sundheim Germany                 fax:    +49.7851.73576	   |
|                                                                          |
 ==========================================================================
-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".