Opened 5 years ago

Closed 5 years ago

#15120 closed enhancement (invalid)

Linux binary compatibility

Reported by: megastallman Owned by: nobody
Priority: normal Milestone: Unscheduled
Component: System Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description

Hi everyone!

Despite the bigger part of essential Free Software has already been ported to Haiku, why not just implement any ways to run Linux binaries from a chroot? Haiku already has BeOS compatibility layer in 32-bit versions, so is it possible to implement Linux compatibility for 64-bit versions? Of course, it would require the ELF-parser, half of the Linux syscalls implementation, networking for Linux, a VFS layer, pulseaudio client, X11 DDX-component. That is a big amount of work, but it can attract more new users to Haiku, especially those, relying on the software that is unavailable for Haiku.

Change History (1)

comment:1 by waddlesplash, 5 years ago

Resolution: invalid
Status: newclosed

Haiku already has BeOS compatibility layer in 32-bit versions, so is it possible to implement Linux compatibility for 64-bit versions?

No. The BeOS compatibility is not a "layer", it was that the Haiku ABI began as the BeOS ABI, and we extended it for GCC4 versions (but kept the ability to build a BeOS-compatible ABI on GCC2 versions.) BeOS syscalls were not public, which meant that Haiku syscalls and BeOS syscalls are very different; only the libc API was stable.

Linux, on the other hand, has public-facing syscalls that anyone can (and does) use. So to make a FreeBSD-style Linuxulator, we would need to do the same thing they did, and implement a syscall compatibility layer.

Of course, it would require the ELF-parser

Haiku already uses ELF format for binaries. Did you do any research at all before requesting this?

half of the Linux syscalls implementation

Half? Which half is that? It would require an entire syscalls implementation, just like FreeBSD does.

networking for Linux

I don't know what this means...

a VFS layer

All kernels have a VFS layer. We would not need a new one for this. FreeBSD's Linuxulator does not have its own, IIRC.

pulseaudio client, X11 DDX-component

These are not part of Linux. Were you really referring to "Linux GUI apps binary compatibility"? That is a completely different thing (and perhaps possible without doing an in-kernel syscalls emulation, as most GUI apps use a shared glibc or the like.)

But it is actually even more work than just the straight "Linux syscalls emulation." FreeBSD gets away with just that because, indeed, they use X11, and so Linux apps can talk to X like normal. We do not, so indeed we would have to port an X11 server.

That is a big amount of work, but it can attract more new users to Haiku, especially those, relying on the software that is unavailable for Haiku.

If there is software unavailable for Haiku, we should just port it. That's all.

So, we have no interest in this; it is a massive amount of work for little, if any, benefit.

Note: See TracTickets for help on using tickets.