From: wolfgang.thaller@gmx.net Date: Sun, 5 Feb 2006 16:26:18 +0000 (+0000) Subject: Darwin/x86 Mangler: Make sure each imported symbol stub gets a separate chunk. X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=6213757d9ad83e34f115a8877f6918a7dd39c71b;p=ghc-hetmet.git Darwin/x86 Mangler: Make sure each imported symbol stub gets a separate chunk. --- diff --git a/ghc/driver/mangler/ghc-asm.lprl b/ghc/driver/mangler/ghc-asm.lprl index bbfe142..18388b5 100644 --- a/ghc/driver/mangler/ghc-asm.lprl +++ b/ghc/driver/mangler/ghc-asm.lprl @@ -594,12 +594,19 @@ sub mangle_asm { $chk[++$i] = $_; $chkcat[$i] = 'dyld'; $chksymb[$i] = ''; + $dyld_section = $_; } elsif ( $TargetPlatform =~ /^.*-apple-darwin.*/ && $chkcat[$i] eq 'dyld' && /^\s*\.data/) { # non_lazy_symbol_ptrs that point to local symbols $chk[++$i] = $_; $chkcat[$i] = 'dyld'; $chksymb[$i] = ''; + $dyld_section = $_; + } elsif ( $TargetPlatform =~ /^.*-apple-darwin.*/ && $chkcat[$i] eq 'dyld' && /^L_.*:$/) + { # non_lazy_symbol_ptrs that point to local symbols + $chk[++$i] = $dyld_section . $_; + $chkcat[$i] = 'dyld'; + $chksymb[$i] = ''; } elsif ( /^\s+/ ) { # most common case first -- a simple line! # duplicated from the bottom