Skip to main content


@leonerd, you might know the answer to this, although only if you have time and interest to look.

Is there a better place for the pp_sys.c part of this patch? I tried adding it to perl.h, and it gave me an error I forgot to write down. I may try again.

https://github.com/afresh1/OpenBSD-perl/compare/blead...syscall_emulator

Background is, on OpenBSD, syscall(2) is likely going away, but someone who would put up a fuss apparently uses it from perl, so I need to fake it and that's good enough. Also, it's a proof-of-concept that could be used to make other programs work.
in reply to Andrew Hewus Fresh

Not quite sure I follow the question. You don't appear to have done anything to pp_sys.c in that series of commits.
in reply to Paul Evans

I seem to need to #include "syscall_emulator.h" and #define syscall syscall_emulator. The latter I can do with a cc flag or whatever, but the former complained about not having the definition. Making coffee now, so can't actually reproduce the error, though, but I'll try a few things.
in reply to Paul Evans

Oh, one of the changes is a patch that applies to pp_sys.c. I can work up something more familiar though.
in reply to Andrew Hewus Fresh

If there is a better place for it, I don't know of one. Maybe, if this is an OS-specific hack of the same overall shape as many of the MSWin32 ones, maybe take a look and see how those do it?
in reply to Paul Evans

I'll have a look, thanks for the confirmation though. This is a very OS specific hack and I don't (at the moment) see any way to upstream it since syscall(2) is so special.