From 81ff593b02bc6ec5b5e2e8aa5f88ae2fec85c7cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Mon, 13 Jan 2003 11:28:36 +0000 Subject: [PATCH] Added .fini section to the ld scripts. Fixed a bug that asked ld to discard the .dtors section. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2450 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kernel/ldscripts/x86/app.ld | 5 ++--- src/kernel/ldscripts/x86/library.ld | 3 ++- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/kernel/ldscripts/x86/app.ld b/src/kernel/ldscripts/x86/app.ld index 607f8cc7c6..e54a156259 100644 --- a/src/kernel/ldscripts/x86/app.ld +++ b/src/kernel/ldscripts/x86/app.ld @@ -32,11 +32,11 @@ SECTIONS .rel.plt : { *(.rel.plt) } .rela.plt : { *(.rela.plt) } .init : { *(.init) } =0x9090 + .fini : { *(.fini) } =0x9090 .plt : { *(.plt) } /* text/read-only data */ .text : { *(.text .gnu.linkonce.t.*) } - .rodata : { *(.rodata) } /* writable data */ @@ -60,7 +60,6 @@ SECTIONS .got : { *(.got.plt) *(.got) } .dynamic : { *(.dynamic) } - /* unintialized data (in same segment as writable data) */ PROVIDE (__bss_start = .); .bss : { *(.bss) } @@ -69,5 +68,5 @@ SECTIONS PROVIDE (_end = .); /* Strip unnecessary stuff */ - /DISCARD/ : { *(.comment .note .eh_frame .dtors) } + /DISCARD/ : { *(.comment .note .eh_frame) } } diff --git a/src/kernel/ldscripts/x86/library.ld b/src/kernel/ldscripts/x86/library.ld index 607f8cc7c6..80d3734bd0 100644 --- a/src/kernel/ldscripts/x86/library.ld +++ b/src/kernel/ldscripts/x86/library.ld @@ -32,6 +32,7 @@ SECTIONS .rel.plt : { *(.rel.plt) } .rela.plt : { *(.rela.plt) } .init : { *(.init) } =0x9090 + .fini : { *(.fini) } =0x9090 .plt : { *(.plt) } /* text/read-only data */ @@ -69,5 +70,5 @@ SECTIONS PROVIDE (_end = .); /* Strip unnecessary stuff */ - /DISCARD/ : { *(.comment .note .eh_frame .dtors) } + /DISCARD/ : { *(.comment .note .eh_frame) } }