Patch performs the next changes:
- Create reserved symbols at one place.
- Add predefined sections at one place to output list.
- Separate processing commons to addCommonSymbols().
- Added fillSymTables() to keep logic about filling SymTab and DynSymTab.
- Moved scan relocations logic to scanRelocs().
I am trying to clean up this method as it do too much now, and not just what
it's name says. That hopefully will help to reuse sub-methods later for redesigning
linkerscript functionality.
Please use the same structure we use for the other comparisons:
AIsFoo = ...;
BIsFoo = ...;
if (AIsFoo != BIsFoo)
return ...;
I wonder if it wouldn't be nicer to just put Interp and BuildId at the start of the section list in addPredefinedSections and avoid having this special cases in the comparison function.