This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Creating a NOLOAD section with contents


Hi all,

Is it possible to create a code section as part of an ELF that has
contents but is not loadable?

I tried this in my linker script:

  .my_funcs 0x80000000 (NOLOAD)	:
  {
    *(.my_funcs)
  }

Which creates a .my_funcs in the output ELF that is not loadable, but
it also has no contents (ALLOC, READONLY, CODE) whereas I would like a
section that was (CONTENTS, READONLY, CODE).

Is there a simple way to do that?

Thanks,


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]