Gentoo Archives: gentoo-user

From: Grant Edwards <grant.b.edwards@×××××.com>
To: gentoo-user@l.g.o
Subject: [gentoo-user] Running 3rd-party Ubuntu apps on Gentoo
Date: Sun, 07 Jan 2018 03:51:15
Message-Id: p2s5at$avd$
What's a good way to run 3rd party apps packaged for Ubuntu?

There are a few third-party binary applications on which I depend.

They're usually distributed as .rpm for RedHat and .deb for Ubuntu.

AFAICT, Gentoo and Ubuntu library names generally match, while RedHat
seems to slightly munge many (all?) library names.  So, I've always
had better luck with .deb than with .rpm.  Usually I try unpacking the
.deb file into it's own tree under /opt and then running the app.

Sometimes it requires a shell wrapper to set LD_LIBRARY_PATH,
sometimes the app is smart enough to locate it's libraries.

This has always been a bit fragile.

For example, one app I use frequently requires qt4 webkit.  It works
at the moment, but the qt4 webkit ebuild has been masked and is
scheduled for removal. In other cases, the Gentoo libraries don't have
quite the same features expected by the app.  In cases like this I've
ended up copying .so files from an Ubuntu machine into the app's
directory in /opt.  Figuring out which libraries you need to copy can
be a bit tedious.  It's simple enough to figure out when you're
_missing_ a library, but incompatibilities can be very difficult to
figure out.

I'm looking for a more robust way to deal with this.  I haven't tried
any of these options yet...

 1) Create a docker container for each of the apps and share the X
    server Unix domain socket with the container (they're almost
    always GUI apps).  Will this stop working under Wayland since it
    doesn't support "remote" applications.  [I really don't want to
    deal with a remote desktop -- I just want the app to open a window
    on my normal desktop.]

 2) Install Ubuntu in a second partition and install the apps there.
    Then under Gentoo, mount that partition and run the app binaries
    in situ after setting LD_LIBRARY_PATH to make sure the app finds
    the Ubuntu libraries instead of the Gentoo ones.  Or instead of
    setting LD_LIBRARY_PATH, run the apps in a chroot environment that
    shares the X11 Unix domain socket and some directories with the
    Gentoo portion?

 3) Run the apps in a VM that's running Ubuntu using a TCP connection
    between the Ubuntu app (X11 client), and the X11 server on Gentoo.
    Booting up a VM each time I want to run one of the apps seems
    pretty heavyweight.

Any other suggestions?



Subject Author
Re: [gentoo-user] Running 3rd-party Ubuntu apps on Gentoo Neil Bothwick <neil@××××××××××.uk>