Results 26 comments of Vladimir Vrzić

@taviso Yeah, good catch. While BSD does not have `strndupa(3)`, it _does_ have plain `alloca(3)`, but it's declared in `stdlib.h` rather than `alloca.h`. Fixed.

Great, having a regression test suite is super helpful. Perhaps setting up an automated CI workflow is in order. Not sure about a cheap way to run CI for FreeBSD,...

I started working towards making it build on BSDs: https://github.com/vrza/123elf/tree/openbsd-1

I got it to compile, currently looking into how to make it link. `ld` is complaining about symbols that were undefined, and about multiple definitions: ``` cc forceplt.o -m32 -ggdb3...

Build is now working using the feature branch from https://github.com/taviso/123elf/pull/86 When invoked through `gdb` or `dtruss`, program runs fine! However, when starting it from the shell it fails: ``` $...

Note that FreeBSD port PR https://github.com/taviso/123elf/pull/86 should contain all the changes in this PR, so it can be merged instead, otherwise they should still merge cleanly on top of each...

Now I tried building 2.38 locally (we need to modify `binutils.sh` to build `as` as well!). Linker doesn't crash anymore, but I see the [same problem as on NetBSD](https://github.com/taviso/123elf/issues/77#issuecomment-1146757247): ```...

Okay, got it to link by modifying`undefine.lst` (removed "undefined reference" symbols and added "multiple definitions" symbols -- I'm still figuring out how this custom linking process works). Next step is...

Program segfaults on startup: ``` Program received signal SIGSEGV, Segmentation fault. Address not mapped to object. 0x0008e6f0 in ?? () (gdb) bt #0 0x0008e6f0 in ?? () #1 0x0811aa27 in...

System call trace from `truss(8)`: ``` sigaction(SIGUSR1,{ 0x8113e80 SA_RESTART ss_t },{ SIG_DFL 0x0 ss_t }) = 0 (0x0) sigaction(SIGHUP,{ 0x811976c SA_RESTART ss_t },{ 0x8119780 SA_RESTART ss_t }) = 0 (0x0)...