Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 10 Feb 2021 21:21:21 -0700
From:      Gary Aitken <freebsd@dreamchaser.org>
To:        Pete Wright <pete@nomadlogic.org>, FreeBSD Mailing List <freebsd-questions@freebsd.org>
Subject:   Re: which linux libfuse.so.2?
Message-ID:  <d16ac20b-45a3-e11c-140e-f4a9e3fd439d@dreamchaser.org>
In-Reply-To: <51a444f0-c920-1764-0480-ca99e2ac8186@nomadlogic.org>
References:  <79254130-e926-fab3-9d5b-b6862c6b747b@dreamchaser.org> <8e50ba4b-a419-0d60-c2b5-1c379e2dc604@nomadlogic.org> <c55fa527-c0fe-97f2-d9d9-bc01aa092e23@dreamchaser.org> <51a444f0-c920-1764-0480-ca99e2ac8186@nomadlogic.org>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
I'm still trying to get my head around what's going on here.
I *thought* the /compat/linux stuff was meant to work with fbsd stuff
to some extent...

On 2/9/21 9:03 PM, Pete Wright wrote:
> On 2/9/21 7:23 PM, Gary Aitken wrote:
>> 
>> Is there a way to run /compat/linux/usr/bin/ldd to figure out what
>> it is really looking for?  I get the same error whether the symlink
>> for libfuse.so.2 is present or not.  If I try to run the linux ldd
>> I get:
>> 
>> $ /compat/linux/usr/bin/ldd
>> PrusaSlicer-2.3.0+linux-x64-202101111322.AppImage bash:
>> /compat/linux/usr/bin/ldd: /usr/bin/bash: bad interpreter: No such
>> file or directory
>> 
>> There is no /usr/bin/bash (it's in /usr/local/bin/bash), but there
>> is a /compat/linux/usr/bin/bash.
>> 
> you might want to chroot into the /compat/linux environment like this
> for example: $ sudo chroot /compat/linux /usr/bin/bash
> 
> that should make tools like ldd friendlier while you debug.

Not sure if this is friendlier or not :-(:

$ sudo chroot /compat/linux /usr/bin/bash
/$ cd /home/garya/
/home/garya$ ./PrusaSlicer-2.3.0+linux-x64-202101111322.AppImage
dlopen(): error loading libfuse.so.2

AppImages require FUSE to run.
You might still be able to extract the contents of this AppImage
if you run it with the --appimage-extract option.

/home/garya$ ldd PrusaSlicer-2.3.0+linux-x64-202101111322.AppImage
ELF binary type "3" not known.
/bin/ldd: line 161: /lib/ld-linux.so.2: cannot execute binary file
         not a dynamic executable

So, I exploded the .AppImage, which leaves a subtree squashfs-root with
a script "AppRun" which basically runs usr/bin/prusa-slicer.  So

/home/garya$ cd squashfs-root/
/home/garya/squashfs-root$ ./AppRun
/home/garya/squashfs-root/usr/bin/bin/prusa-slicer: error while loading shared libraries: libGLU.so.1: cannot open shared object file: No such file or directory
/home/garya/squashfs-root$ ldd /usr/bin/prusa-slicer
ELF binary type "3" not known.
/bin/ldd: line 161: /lib/ld-linux.so.2: cannot execute binary file
         not a dynamic executable

I don't understand why bin/ldd is a script in compat/linux, which tries to
execute a shared library, but even if that made sense...

It appears the binary file prusa-slicer is looking for libGLU.so.1, which is
not in the /compat/linux tree.  Am I correct that running with this linux
compatibility mode is restricted to stuff in /compat/linux?

If the .AppImage is supposed to be a self-contained binary executable which
can run on any linux system, then what does "self-contained" mean?  Does it
mean "only self-contained enough that libraries we think are on all linux
systems by default are not included."?

> you also might want to give setting your LD_LIBRARY_PATH when
> executing the command from freebsd to include the linux locations and
> see how far you get: $
> LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/compat/linux/lib:/compat/linux/lib64
> PrusaSlicer...

my default environment has no LD_LIBRARY_PATH; I think that's normal in fbsd,
correct?  In any case, the following still does not find libfuse when run
from fbsd:

$ LD_LIBRARY_PATH=/compat/linux/lib:/compat/linux/lib64:/usr/local/lib:/usr/lib ./PrusaSlicer-2.3.0+linux-x64-202101111322.AppImage
dlopen(): error loading libfuse.so.2

This feels like the whole concept of .AppImage doesn't play well with the
compat/linux environment.

I guess it is time to upgrade to 12.x and try the ubuntu linuxulator...

Gary




Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?d16ac20b-45a3-e11c-140e-f4a9e3fd439d>