AmigaLabs / clib4

Clib4 for AmigaOS4
Other
14 stars 7 forks source link

clib4 as shared object and UND dlopen symbol #168

Closed 3246251196 closed 7 months ago

3246251196 commented 7 months ago

Please see: https://github.com/3246251196/adtools_testing/tree/main/tests/15_rjd_runtimeLoadSO_dynld which is a reproducible, at least for me.

To build the test just do:

make -f sa.makefile V=1

Copy all of the files to the AmigaOne machine (you will need the relevant clib4.library in the PROGDIR: when you execute main).

I notice that I get an unfound dlopen when loading the program.

===

Compare this with https://github.com/3246251196/adtools_testing/tree/main/tests/16_rjd_runtimeLoadSO_NO_dynld where the only difference is the final link step to create the executable file. In this case, -use-dynld is not used - but, this is not how things should be done; at least, that is my understanding of the section titled "Compiling the Main Program" in the SDK PDF. In the non-dynld case, the test passes.

3246251196 commented 7 months ago

It seems that I was forgetting to copy over the SO files from the clib4 repository! If there SO files are not there, then the elf library will search in SOBJS: and be picking up newlib versions of things.