If I try to execute a Linux ELF file on FreeBSD what would happen? reddit / BSD ---------------------------------------------------------------------- B99fanboy · 2021-03-27 17:18 It's a stupid question but I'm curious, will BSD recognise the file as executable? EDIT: Thank you for the insight guys. I think I will give FreeBSD a try. ---------------------------------------------------------------------- [deleted] · 2021-03-27 17:26 it simply won't run. you'll get what I believe is called an exec format error or something like that ---------------------------------------------------------------------- B99fanboy · 2021-03-27 17:31 Got it, thnx. ---------------------------------------------------------------------- Kormoraan · 2021-03-27 17:38 why not try it yourself instead of asking? ---------------------------------------------------------------------- [deleted] · 2021-03-27 17:48 [deleted] ---------------------------------------------------------------------- neel1337 · 2021-03-27 17:49 If you enable the Linuxulator and install the particular userland, you may be able to get a Linux ELF working. ---------------------------------------------------------------------- LowerSeaworthiness · 2021-03-27 18:51 If you have Linux emulation enabled, and have the right support libraries installed, it'll run. Otherwise, it'll recognise it as executable but fail to start it. ---------------------------------------------------------------------- BumpitySnook · 2021-03-27 19:15 Not if you load linux64.ko first :-). Then you'll likely get a dynamic link error instead, unless you have the corresponding Linux .so libraries installed. ---------------------------------------------------------------------- [deleted] · 2021-03-27 19:25 well for freebsd yeah, but that's not on others ---------------------------------------------------------------------- masta · 2021-03-27 20:37 You can use `brandelf` to run the Linux Elf binary software, so long as you have the Linux user land installed. ---------------------------------------------------------------------- FUZxxl · 2021-03-27 22:18 Unbranded Linux binaries won't run. After you use `brandelf` to brand them as Linux binaries, they'll run if the Linuxulator is loaded (and of course all required shared libraries are present). ---------------------------------------------------------------------- B99fanboy · 2021-03-28 04:04 Indeed I could, but I'm still reluctant to go through the hassle. One day I will try FreeBSD. ---------------------------------------------------------------------- BumpitySnook · 2021-03-28 04:32 Sure, that's fair. The question posed specified FreeBSD, though. ---------------------------------------------------------------------- sehnsuchtbsd · 2021-03-28 08:25 The Linux ABI, in spite of all its limits, works well on netbsd too. ---------------------------------------------------------------------- [deleted] · 2021-03-28 09:16 oops my bad, don't know how I didn't see that ---------------------------------------------------------------------- BumpitySnook · 2021-03-28 18:36 No worries!