home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / binutils-2.7-src.tgz / tar.out / fsf / binutils / ld / scripttempl / sparclynx.sc < prev    next >
Text File  |  1996-09-28  |  1KB  |  48 lines

  1. # Linker script for Sparc LynxOS.
  2. test -z "$ENTRY" && ENTRY=_start
  3. cat <<EOF
  4. OUTPUT_FORMAT("${OUTPUT_FORMAT}")
  5. ${LIB_SEARCH_DIRS}
  6.  
  7. ENTRY(${ENTRY})
  8.  
  9. SECTIONS
  10. {
  11.   .text ${RELOCATING+ SIZEOF_HEADERS} : {
  12.     *(.init)
  13.     *(.text)
  14.     ${RELOCATING+ etext  =  .;}
  15.     ${CONSTRUCTING+ ___CTOR_LIST__ = .;}
  16.     ${CONSTRUCTING+ LONG((___CTOR_END__ - ___CTOR_LIST__) / 4 - 2)}
  17.     ${CONSTRUCTING+ *(.ctors)}
  18.     ${CONSTRUCTING+ LONG(0)}
  19.     ${CONSTRUCTING+ ___CTOR_END__ = .;}
  20.     ${CONSTRUCTING+ ___DTOR_LIST__ = .;}
  21.     ${CONSTRUCTING+ LONG((___DTOR_END__ - ___DTOR_LIST__) / 4 - 2)}
  22.     ${CONSTRUCTING+ *(.dtors)}
  23.     ${CONSTRUCTING+ LONG(0)}
  24.     ${CONSTRUCTING+ ___DTOR_END__ = .;}
  25.     *(.fini)
  26.     ${RELOCATING+ etext  =  .};
  27.   }
  28.   .data ${RELOCATING+ 0x400000 + (. & 0xffc00fff)} : {
  29.     *(.data)
  30.     ${RELOCATING+ edata  =  .};
  31.   }
  32.   .bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
  33.   {                     
  34.     *(.bss)
  35.     *(COMMON)
  36.     ${RELOCATING+ end = .};
  37.   }
  38.   .stab  0 ${RELOCATING+(NOLOAD)} : 
  39.   {
  40.     [ .stab ]
  41.   }
  42.   .stabstr  0 ${RELOCATING+(NOLOAD)} :
  43.   {
  44.     [ .stabstr ]
  45.   }
  46. }
  47. EOF
  48.