Installing Linux games (via mojosetup)

Hey everyone,

I have been using FreeBSD 11 for a couple of weeks now as a desktop system and so far it is going well. However, I am a bit at a loss when it comes to installing Linux games obtained from using the Linux compatibility layer. I have followed the instructions in the handbook and elsewhere, i.e. I installed emulators/linux-c6 and emulators/linux_base-c6 (I compiled them with ’DEFAULT_VERSIONS+=linux=c6_64’ in /etc/make.conf to obtain the 64-bit files) and added the entries to /etc/rc.conf and /etc/fstab.

To add a bit of context, distributes Linux games as Makeself packages (though they look like shell scripts), within them a ‘mojosetup’ binary image (which is supposed to handle the installation). Executing the script seems to work until it reaches the mojosetup binary image, as it manages to extract the contents to /tmp first. The execution just hangs at that point and the command line does not respond anymore (I have to pkill the process). I have tried several games and they all have the same problem.

$ ./
Verifying archive integrity... All good.
Uncompressing Bastion ( 100%
Collecting info for this system...
Warning: No binaries for "freebsd" found, trying to default to Linux...
Operating system: linux
CPU Arch: x86_64
trying mojosetup in bin/linux/x86_64

I am not sure where to begin. I have tried executing the ‘shell script’ as verbose ( sh -v) and as debug ( sh -x), but it does not show any messages at that point. Using ldd mojosetup results in this (I omitted the long numbers within parentheses at the end, as I am currently typing this out by hand):

mojosetup: => => /lib64/ => /lib64/ => /lib64/ => /lib64/

Are the first and last lines correct that way? brandelf does not seem to do anything.

There is something else I noticed. Before I installed emulators/linux-c6, I only installed emulators/linux_base-c6. When I started the shell script, I received an error message that it could not find ‘xterm-256color’. At this point I installed emulators/linux-c6 as well, which required me to add this line to /etc/fstab: tmpfs /compat/linux/dev/shm tmpfs rw,mode=1777 0 0

However, I did not do that immediately and the mojosetup binary did start (but I could not complete the installation due to a fatal error). Upon rebooting the system, Gnome 3 would not start anymore (it would just go on and off before I could reach the login screen). I was able to resolve this by adding the line above, but hence mojosetup hangs.

Any ideas where I could look for clues?
Not linux subsystem user, but I saw c7 landed to the port tree. Maybe it's worth to try it.
You can try to debug the process with ktrace(1)() . Use kdump -HAR to make trace file human readable. Maybe you will see some unimplemented calls or something obvious.
Thanks for the response. I managed to recompile x11/nvidia-driver-340 with emulators/linux_base-c7. Unfortunately, the issue is the same.

I haven't used ktrace or like before and I am not sure what to look for. I posted the log here.

I am still wondering why it worked and managed to present a GUI before I added the tmpfs line (above) to /etc/fstab.
I've tried to run ./ manually, it flashes something blue (installer I suppose) then spins without output taking 98% CPU.
Indeed, the simplest solution. Although the only linux binary which I could 'use' here is glxgears from graphics/linux-c7-glx-utils. If not complaining about missed binaries from older linux base, all of them segfault on me (I'm speaking of GoG game as well as demos from ports).