amiga-news DEUTSCHE VERSION
.
Links| Forums| Comments| Report news
.
Chat| Polls| Newsticker| Archive
.

[Login] [Register] [Forgot your password?]

< Next messagePrior message >
22.Jan.2024



AmigaOS 4: elf.library V54.1
Hyperion Entertainment has released the new version 54.1 of the elf.library (Executable and Linkable Format) for AmigaOS 4, which is available via AmiUpdate. Changes since version 53.30:
  • Added AmigaDOS pattern support in load-time-blacklist (as an example "amissl_v#?.library" will now exclude all of the AmiSSL sub-libraries without having to list each separate library explicitly).
  • Reduced Elf_Collector process to a bare minimal process without all the pointless and unused decorations, backed off the priority to -5 and increased the polling wait to 1 second, increased the cache flush time to 300 seconds.
  • Added ADDR24 reloc support required for kernel 54.48 and higher.
  • The filesize parameter from Openelf.c was downsized from INT64 to UINT32 and then passed to ObtainCachedElfHandle() where the value was then stored in the elfhandle as an INT64. Remove the downsizing in Openelf.c and ObtainCachedElfHandle() to pass and store only INT64 now.
  • Fixed CopyDataSegment() reloc failures from being silently ignored (was returning successfully, instead of an error).
  • Rewrote CopyDataSegment() to no longer need to load relocs from disk each time it is called. Instead, the required relocs and information are stored during ElfLoadSeg() for later use. This allows applications to set OET_NoDOS when opening the file handle, instead of needing to maintain a file lock until the application exits.
  • CopyDataSegment() will now additionally use a .bss, .sdata or .sbss section as the reference for the baseOffset, if a .data section is not present.
  • Fixed several bugs with error handling in Elf32_LoadSegment. Previously, a failed read would lead to either an infinite regress or a deadlock.
  • Implementation of Elf32_CallConstructors and Elf32_CallDestructors. These are now called from inside InitSHLib in place of __shlib_call_constructors and __shlib_call_destructors. This has the benefit of being compiler and stdlib independent (so more generic). It also solves the problem, that the previous solution would in fact not work but (due to some problem with gcc __attribute__((section)) probably) would call an incomplete array of constructor functions.
  • Fixed bug in the storing of any data relocs, which would crash if the buffer needed to be enlarged.
  • Fix CloseElfTag in Elf32_CallConstructors and Elf32_CallDestructors.
  • Ensure that RELA section has been loaded in Elf32_OpenReloc.
  • Add GST_Load, TRUE to RelocateSectionTags in Elf32_CallConstructors/Destructors.
  • Added crash condition to OpenElfTags() in Elf32_CallConstructors/Destructors.
  • Fix a case of very bad error handling in Elf32_HandleRelocs (Timberwolf).
  • Fix a bug in relocbuffer.c. ElfSeek would not be called before ElfRead in Elf32_RefillRelocBuffer, which would lead to faulty reads. Several names have been changed to better clarify structure. This completes the fix for Timberwolf in the last revision.
  • Elf32_CallConstructors/Destructors have been updated to account for .init_array and .fini_array sections.
  • Open/CloseElfTags calls have been updated in the same two functions to account for correct reopening/reclosing of elfhandles.
  • Fix closing of OET_ReadOnlyCopy DOS filehandle in CloseElfTags.
  • Added GetSOHandles() function.
  • Change Elf32_CallConstructors/Destructors to handle .ctors/.dtors array starting with -1 instead of NULL, which fixes shared objects crashing that were compiled using newlib SDK >= 53.84.
  • Change Elf32_CallConstructors/Destructors to better handle missing NULL termination in .ctors/.dtors and added debug output to report such cases.
  • DLOpen() will now return NULL if any attempt is made to use it to open an ELF file that is not actually a shared object type.
  • Fix OpenElf() not initializing the shared object array, which caused CloseElf() to crash unless ElfLoadSeg() had been called.
  • Fix internal elfhandle flag never actually being set for shared objects, due to the code being placed before the header was read.
  • Program header loadable segments are now always loaded as segments unless the .rodata section is contained in a section containing an executable section, in which case sections in that segment are loaded separately, as before.
  • Don't unnecessarily call CacheClearE() individually for each and every reloc applied during ElfLoadSeg(), as we already flush that memory from the caches soon after anyway. This should speed up the loading of large executables.
  • RelocateSection() now correctly flushes the processor cache when R_PPC_JMP_SLOT relocs make changes to the PLT.
  • Elf32_CallConstructors/Destructors no longer attempts to relocate .ctors/.dtors, as ElfLoadSeg() will have always already done this.
  • Elf32_CallConstructors/Destructors no longer needs to open and reread the file, as the section indices are now saved by Elf32_OpenSOLib() before unloading the string sections.
  • Do not ignore ELFCMD_DOS_SEEK errors.
  • Correct autodoc for ELFCMD_DOS_SEEK to specify OFFSET_BEGINNING instead of OFFSET_CURRENT and changed return value to be boolean.
  • Fix recursive loop, which overflowed stack and crashed, which could happen when attempting to load a corrupt file, if there is an issue with the section name string table.
  • Check section headers for signs of corruption and, instead of crashing, display a message on failure and fail gracefully.
  • Protect against attempted incorrect/large/invalid memory allocations when loading sections from a corrupt file.
  • Add new error code ELF32_INVALID_HEADER to .
  • UnloadSection() no longer crashes if no sections have been loaded.
  • Fix crashes triggered by R_PPC_REL24 relocs, mistakenly caused by an out of range address during the resolution of undefined symbols, instead of jumping to the PLT.
  • Fix symbol cache not adding entry, if the cache needs to be enlarged.
  • Fully utilise the symbol cache when reading the symbol name.
  • OpenElf() needs to close the file, if it opened one, should there be an issue reading the headers.
  • Fix incorrect detection of invalid headers where OET_MemoryAddr has been specified instead of a file.
  • Add filename to give context to the ElfLoadSeg() error requesters. Further tweak to the pointer equality fix, to completely skip R_PPC_REL24 and R_PPC_LOCAL24PC relocs with a st_value of 0, as the relative branches will already be correct - no relocation required. Fix Elf32_BlacklistCheck() from crashing when passed a handle with no filename set (e.g. OET_MemoryAddr). Replace semaphore usage with mutexes
(dr)

[News message: 22. Jan. 2024, 22:01] [Comments: 0]
[Send via e-mail]  [Print version]  [ASCII version]
< Next messagePrior message >

.
Masthead | Privacy policy | Netiquette | Advertising | Contact
Copyright © 1998-2024 by amiga-news.de - all rights reserved.
.