On Mon, Oct 9, 2023 at 11:21 AM Lorenz (xha) <m...@xha.li> wrote: > hi misc@, > > i'm currently porting the hare programming language to openbsd and i am > having quite a few problems trying to use a linker script. i am always > getting a "/bin/ksh: .bin/hare: Invalid argument" error. > > so far i tried a lot of stuff like comparing a working version without a > linker script, looking if any of the programm headers are missing, etc. >
So you have a working binary (w/o linker script) and a not-working binary (w/linker script) and you've even done the comparison of the program headers of the two...and you're not going to show those but rather ask what, in general, could be wrong? Oooookay. Lacking the specifics of those differences (which you've already identified), the general advice is this: Read /usr/src/sys/kern/*exec* and review the logic around the 10 occurrences of EINVAL in that code. Presumably the differences you identified will point to one or more of them Philip Guenther