Xref: news2.mv.net comp.os.msdos.djgpp:6743 From: Charles Sandmann Newsgroups: comp.os.msdos.djgpp Subject: Re: __attribute__((section)) Date: Fri, 02 Aug 1996 13:52:07 CDT Organization: Rice University, Houston, Texas Lines: 9 Message-ID: <32024e57.sandmann@clio.rice.edu> References: <838840319 DOT 11194 DOT 2 AT abwillms DOT demon DOT co DOT uk> Reply-To: sandmann AT clio DOT rice DOT edu NNTP-Posting-Host: clio.rice.edu To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp > >The hack is OK, but where does MYDATA section go? Does it go to separate > >segment when proggy is loaded? If so, you have to use far pointers/switch DS > >selector if you want to access the data - BY HAND. If MYDATA is a separate section, the stub will be confused and either load the wrong things or ignore it completely. Look at the stub's source - it only loads the first 2 sections and zeros the memory associated with the third section. If the first 3 sections aren't text,data,bss in that order, badness will happen. Sections 4..n will be ignored completely.