From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Lance Taylor To: John_W_Marshall@palm.com Cc: binutils@sourceware.cygnus.com Subject: Re: DJGPP and alignment Date: Thu, 22 Jul 1999 11:53:00 -0000 Message-id: <19990722185312.21803.qmail@daffy.airs.com> References: <199907221523.IAA22715@kovalevskaya.palm.com> X-SW-Source: 1999-q3/msg00296.html From: John Marshall Date: Thu, 22 Jul 1999 08:23:26 -0700 (PDT) I've been adding a collect-sections-to-make-data kind of thing to m68kcoff (it does the same sort of job as .rel.sdata in mipsecoff: loadtime relocations for data sections). My data is 10 byte records. It seems I have three choices: 1. Admit defeat and pad each record to 12 bytes. 2. Override coff_new_section_hook like in coff-sh.c. 3. Add yet another special case for my little section to coff_new_section_hook in coffcode.h. Is there any advice as to the "right way"? At the moment I'm using #2, but it feels like overkill, and, for a bfd neophyte like me, it took ages to figure out. I feel like maybe the "spirit of coff" is #1. I think the right way is choice 2, as you are doing. Actually, I think the right way is to switch to ELF, which permits the alignment to be specified on a section by section basis. Ian