[project @ 2002-01-23 11:29:12 by sewardj] Fix two problems with the ELF linker:
[project @ 2002-01-23 11:29:12 by sewardj]
Fix two problems with the ELF linker:

1.  Determine section attributes by examining various bits in the
    section header tables, rather than from the section names.  This
    makes it robust against future changes / additions to the set of
    section names.

2.  Handle local symbols differently.  Do not add them to our own
    local symbol table for this object, since that's

    (a) wrong -- multiple local symbols can have the same name so long
        as each is in a different section, so if we just dump them into
        the local symbol table we'll wind up with apparently duplicate
        symbols

    (b) totally unnecessary, since the relocations against local symbols
        simply specify an index into the ELF symbol table for the object,
        from whence the address can be calculated without reference to the
        name.

TODO: Test on sparc-solaris
      Investigate whether PEi386 linker needs fixing similarly
and then
MERGE TO STABLE

ryantm/ghc,mfine/ghc,mcmaniac/ghc,hferreiro/replay,da-x/ghc,spacekitteh/smcghc,sgillespie/ghc,lukexi/ghc-7.8-arm64,forked-upstream-packages-for-ghcjs/ghc,ekmett/ghc,ilyasergey/GHC-XAppFix,mcschroeder/ghc,anton-dessiatov/ghc,mettekou/ghc,christiaanb/ghc,gcampax/ghc,nkaretnikov/ghc,nathyong/microghc-ghc,nkaretnikov/ghc,vTurbine/ghc,fmthoma/ghc,bitemyapp/ghc,ml9951/ghc,GaloisInc/halvm-ghc,nathyong/microghc-ghc,oldmanmike/ghc,ghc-android/ghc,wxwxwwxxx/ghc,fmthoma/ghc,anton-dessiatov/ghc,nomeata/ghc,holzensp/ghc,AlexanderPankiv/ghc,christiaanb/ghc,wxwxwwxxx/ghc,forked-upstream-packages-for-ghcjs/ghc,AlexanderPankiv/ghc,mcmaniac/ghc,acowley/ghc,anton-dessiatov/ghc,ml9951/ghc,lukexi/ghc,forked-upstream-packages-for-ghcjs/ghc,green-haskell/ghc,olsner/ghc,urbanslug/ghc,sdiehl/ghc,nkaretnikov/ghc,oldmanmike/ghc,shlevy/ghc,christiaanb/ghc,acowley/ghc,tjakway/ghcjvm,green-haskell/ghc,ghc-android/ghc,sgillespie/ghc,ml9951/ghc,frantisekfarka/ghc-dsi,tibbe/ghc,AlexanderPankiv/ghc,nomeata/ghc,sgillespie/ghc,sgillespie/ghc,nathyong/microghc-ghc,ryantm/ghc,gridaphobe/ghc,fmthoma/ghc,siddhanathan/ghc,nkaretnikov/ghc,jstolarek/ghc,siddhanathan/ghc,tibbe/ghc,da-x/ghc,TomMD/ghc,vTurbine/ghc,ml9951/ghc,christiaanb/ghc,olsner/ghc,olsner/ghc,ml9951/ghc,frantisekfarka/ghc-dsi,gridaphobe/ghc,shlevy/ghc,anton-dessiatov/ghc,christiaanb/ghc,hferreiro/replay,GaloisInc/halvm-ghc,tibbe/ghc,lukexi/ghc-7.8-arm64,GaloisInc/halvm-ghc,ezyang/ghc,lukexi/ghc,olsner/ghc,vikraman/ghc,vTurbine/ghc,GaloisInc/halvm-ghc,tjakway/ghcjvm,nathyong/microghc-ghc,wxwxwwxxx/ghc,bitemyapp/ghc,elieux/ghc,ghc-android/ghc,snoyberg/ghc,ezyang/ghc,AlexanderPankiv/ghc,wxwxwwxxx/ghc,acowley/ghc,ekmett/ghc,acowley/ghc,sdiehl/ghc,hferreiro/replay,sgillespie/ghc,gridaphobe/ghc,green-haskell/ghc,da-x/ghc,forked-upstream-packages-for-ghcjs/ghc,hferreiro/replay,urbanslug/ghc,tjakway/ghcjvm,vikraman/ghc,gridaphobe/ghc,spacekitteh/smcghc,mcschroeder/ghc,elieux/ghc,lukexi/ghc-7.8-arm64,AlexanderPankiv/ghc,sgillespie/ghc,ezyang/ghc,ml9951/ghc,urbanslug/ghc,mettekou/ghc,green-haskell/ghc,nushio3/ghc,vTurbine/ghc,fmthoma/ghc,jstolarek/ghc,AlexanderPankiv/ghc,nomeata/ghc,shlevy/ghc,da-x/ghc,ryantm/ghc,snoyberg/ghc,nushio3/ghc,nomeata/ghc,mcmaniac/ghc,sdiehl/ghc,ilyasergey/GHC-XAppFix,elieux/ghc,mcmaniac/ghc,tjakway/ghcjvm,lukexi/ghc,anton-dessiatov/ghc,tjakway/ghcjvm,siddhanathan/ghc,wxwxwwxxx/ghc,ryantm/ghc,frantisekfarka/ghc-dsi,wxwxwwxxx/ghc,mcschroeder/ghc,nushio3/ghc,olsner/ghc,elieux/ghc,frantisekfarka/ghc-dsi,ghc-android/ghc,nushio3/ghc,sgillespie/ghc,nushio3/ghc,spacekitteh/smcghc,holzensp/ghc,mcschroeder/ghc,gcampax/ghc,vikraman/ghc,TomMD/ghc,shlevy/ghc,fmthoma/ghc,tjakway/ghcjvm,acowley/ghc,nkaretnikov/ghc,vikraman/ghc,acowley/ghc,gcampax/ghc,snoyberg/ghc,fmthoma/ghc,nathyong/microghc-ghc,tibbe/ghc,gridaphobe/ghc,hferreiro/replay,sdiehl/ghc,fmthoma/ghc,lukexi/ghc,nomeata/ghc,mfine/ghc,jstolarek/ghc,ghc-android/ghc,urbanslug/ghc,nathyong/microghc-ghc,acowley/ghc,TomMD/ghc,ml9951/ghc,snoyberg/ghc,spacekitteh/smcghc,forked-upstream-packages-for-ghcjs/ghc,sdiehl/ghc,oldmanmike/ghc,holzensp/ghc,ezyang/ghc,elieux/ghc,mfine/ghc,mfine/ghc,gcampax/ghc,gcampax/ghc,ghc-android/ghc,gridaphobe/ghc,oldmanmike/ghc,mettekou/ghc,mettekou/ghc,christiaanb/ghc,ilyasergey/GHC-XAppFix,vTurbine/ghc,hferreiro/replay,mcmaniac/ghc,mcschroeder/ghc,mfine/ghc,urbanslug/ghc,elieux/ghc,urbanslug/ghc,da-x/ghc,snoyberg/ghc,shlevy/ghc,nathyong/microghc-ghc,nkaretnikov/ghc,da-x/ghc,ezyang/ghc,sdiehl/ghc,mcschroeder/ghc,GaloisInc/halvm-ghc,mettekou/ghc,gridaphobe/ghc,mfine/ghc,lukexi/ghc,AlexanderPankiv/ghc,GaloisInc/halvm-ghc,frantisekfarka/ghc-dsi,jstolarek/ghc,siddhanathan/ghc,oldmanmike/ghc,snoyberg/ghc,vikraman/ghc,wxwxwwxxx/ghc,spacekitteh/smcghc,shlevy/ghc,vikraman/ghc,ryantm/ghc,anton-dessiatov/ghc,siddhanathan/ghc,ezyang/ghc,jstolarek/ghc,nushio3/ghc,urbanslug/ghc,ml9951/ghc,shlevy/ghc,gcampax/ghc,siddhanathan/ghc,forked-upstream-packages-for-ghcjs/ghc,bitemyapp/ghc,siddhanathan/ghc,lukexi/ghc-7.8-arm64,ezyang/ghc,GaloisInc/halvm-ghc,mfine/ghc,vikraman/ghc,olsner/ghc,tibbe/ghc,mcschroeder/ghc,ekmett/ghc,nushio3/ghc,vTurbine/ghc,elieux/ghc,oldmanmike/ghc,gcampax/ghc,christiaanb/ghc,ekmett/ghc,mettekou/ghc,ilyasergey/GHC-XAppFix,bitemyapp/ghc,forked-upstream-packages-for-ghcjs/ghc,TomMD/ghc,nkaretnikov/ghc,anton-dessiatov/ghc,TomMD/ghc,oldmanmike/ghc,mettekou/ghc,bitemyapp/ghc,da-x/ghc,green-haskell/ghc,olsner/ghc,sdiehl/ghc,ekmett/ghc,holzensp/ghc,TomMD/ghc,holzensp/ghc,snoyberg/ghc,TomMD/ghc,hferreiro/replay,lukexi/ghc-7.8-arm64,ghc-android/ghc,tjakway/ghcjvm,vTurbine/ghc