home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!nntp1.radiomail.net!cronos!bombay!sanzgiri
- From: sanzgiri@bombay.metaphor.com (Ajit Sanzgiri)
- Newsgroups: comp.os.ms-windows.programmer.win32
- Subject: Re: Where do a DLL's global variables go?
- Message-ID: <2464@cronos.metaphor.com>
- Date: 25 Aug 92 20:08:20 GMT
- References: <KEVIN.92Aug18182306@buffalobill.edscom.demon.co.uk> <KEVIN.92Aug19123613@buffalobill.edscom.demon.co.uk> <KEVIN.92Aug24173237@buffalobill.edscom.demon.co.uk>
- Sender: news@cronos.metaphor.com
- Organization: Metaphor Computer Systems, Mountain View, CA
- Lines: 20
-
-
- In article <KEVIN.92Aug24173237@buffalobill.edscom.demon.co.uk> kevin@edscom.demon.co.uk (Kevin Broadey) writes:
-
- >SECTIONS
- >.data READ WRITE SHARED
- >.bss READ WRITE SHARED
- >
- >Do it for .data to share initialised variables, .bss for uninitialised,
- >but watch out, because Microsoft haven't quite sorted out DLLs that have
- >both shared and unshared sections.
-
- In this connection, the compiler no longer recognises the /ND option
- which would allow one to individually name (and manage) data segments.
-
- Of course one could use the above to make up a work-around. Break up
- the DLL (which is to have both shared and instance data) into two
- DLLs - one for the shared data and the other for the instance data
- and have the latter be the only client of the former one.
-
- Ajit Sanzgiri
-