News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

Proposed change: ELFOSABI_NONE instead of ELFOSABI_LINUX

Started by lucho, July 05, 2022, 04:22:22 AM

Previous topic - Next topic

lucho

Hello! I built UASM 2.55 for Solaris the same way as for MacOS and FreeBSD (see my previous post). But it turned out that the Solaris linker doesn't like the ELFOSABI_LINUX value that UASM 2.55 was putting into the "modinfo->elf_osabi" field, when it was trying to link the ELF files generated by UASM. So I changed this line (the first one of the body of the "elf_init()" function in the "elf.c" file) to

modinfo->elf_osabi = ELFOSABI_NONE;

Then the Solaris linker started to successfully link the ELF object files generated by the so modified UASM 2.55, and the FreeBSD and Linux linkers also link them, like they did before. So I propose this change to allow using ELF object this generated by UASM not only in Linux, but also in other Unix-like operating systems. In fact, the ELFOSABI_NONE value is the same as ELFOSABI_SYSV designating the standard Unix world ABI.

johnsa

This is a reasonable suggestion. Could you log it on the github repo issues list and I can make this change for 2.56 ?
Thanks!

lucho

You're welcome! Just did it. Sorry for the big delay!