I create Flatpak for Gazebo, but have issue starting it

Hello,

I create Flatpak for Gazebo and hopefully I can submit it to Flathub (Flatpak app store).
Flatpak only work for Linux.
I create Flatpak hoping to make installing Gazebo easier, because Flatpak bundle all the required dependencies.

The Flatpak manifest (.yaml) and all the required patches are here.

To build, install and run it, simply do

install flatpak-builder from your Linux distro

git clone GitHub - kevinsmia1939/flathub at org.gazebosim.Gazebo --recursive

flatpak-builder --install --user build org.gazebosim.Gazebo --force-clean

flatpak run org.gazebosim.Gazebo

It builds, successfully.

However, when attempt to run it. It just show splash screen and shut down.
No error log in terminal either.
Does anyone know how to run Gazebo that will show log in terminal?

Thanks

Cool, thanks for making Gazebo available to more users.

Does Gazebo output any hints when you run it with --verbose?

Thanks for the help.
I have to put xx on http because the forum won’t allow new user to post link.
I got this.

I’m not sure if wrong JPEG lib version cause it to crash.
Do you know what the JPEG library it ask for refer to OpenJPEG or JPEG-turbo?

Gazebo multi-robot simulator, version 11.5.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
hxxp://gazebosim.org

[Msg] Waiting for master.
Gazebo multi-robot simulator, version 11.5.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
hxxp://gazebosim.org
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ hxxp://127.0.0.1:11345
[Msg] Publicized address: 192.168.2.16
[Msg] Loading world file [/app/share/gazebo-11/worlds/empty.world]
[Msg] Connected to gazebo master @ hxxp://127.0.0.1:11345
[Msg] Publicized address: 192.168.2.16
[Wrn] [GuiIface.cc:120] Wrong JPEG library version: library is 90, caller expects 62

Also, when Gazebo was being compile, I found multiple warning.

[ 0%] Building CXX object deps/opende/OPCODE/CMakeFiles/gazebo_opcode.dir/OPC_AABBCollider.cpp.o
[ 0%] Building CXX object gazebo/msgs/CMakeFiles/gazebomsgs_out.dir/generator/GazeboGenerator.cc.o
[ 0%] Building CXX object deps/opende/ou/CMakeFiles/gazebo_opende_ou.dir/src/malloc.cpp.o
[ 0%] Building CXX object gazebo/common/CMakeFiles/gazebo_common.dir/Animation.cc.o
cc1plus: warning: /app/app/include/bullet: No such file or directory [-Wmissing-include-dirs]
cc1plus: warning: /app/app/include/bullet: No such file or directory [-Wmissing-include-dirs]
cc1plus: warning: /app/app/include/bullet: No such file or directory [-Wmissing-include-dirs]
cc1plus: warning: /app/app/include/bullet: No such file or directory [-Wmissing-include-dirs]
cc1plus: warning: /app/app/include/bullet: No such file or directory [-Wmissing-include-dirs]

For Flatpak, the filesystem is /app instead of /usr
I think there might be a bug that cause /app/app instead of /app.

Edit: Maybe I put the wrong path when building bullet

Hello:

runtime problems about version dependencies seems a bug to me, it should be managed at configuration time. Would you mind to create an issue about it? Issues · gazebosim/gazebo-classic · GitHub

I have more doubts in this one. I would start checking what’s values are inside the bullet cmake module since Gazebo should just be consuming them.

Thanks!

I think I manage to fix

cc1plus: warning: /app/app/include/bullet: No such file or directory

I have to change bullet install include dir, I think I put in the wrong path.
This Flatpak package is so big, there are 54 dependencies.
Right now I use KDE Sdk (provide Qt), but I don’t think Gazebo use it. I will try Freedesktop Sdk later.

I see a lot of

TBB Warning: tbb/task.h is deprecated

likely this issue TBB task is deprecated and removed in oneTBB 2021.01 · Issue #2867 · gazebosim/gazebo-classic · GitHub

Ok, build finish, I still could not run Gazebo, I add --verbose but this is all I get, are there more way to debug Gazebo?

I install libjpeg62 (hxxp://jpegclub.org/support/files/jpegsrc.v6b2.tar.gz) just before building Gazebo, but the warning still show. Maybe I must rebuild other module as well.

Gazebo multi-robot simulator, version 11.5.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
hxxp://gazebosim.org

[Msg] Waiting for master.
Gazebo multi-robot simulator, version 11.5.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
hxxp://gazebosim.org

[Msg] Waiting for master.
[Msg] Connected to gazebo master @ hxxp://127.0.0.1:11345
[Msg] Publicized address: 192.168.2.16
[Msg] Loading world file [/app/share/gazebo-11/worlds/empty.world]
[Msg] Connected to gazebo master @ hxxp://127.0.0.1:11345
[Msg] Publicized address: 192.168.2.16
[Wrn] [Event.cc:61] Warning: Deleting a connection right after creation. Make sure to save the ConnectionPtr from a Connect call
[Wrn] [GuiIface.cc:120] Wrong JPEG library version: library is 90, caller expects 62

I don’t know if it is a problem, but FreeImage 3.18 (FreeImage download | SourceForge.net) that Gazebo need bundle libpng librawlite openexr zlib libopenjpeg libjpeg, particularly libjpeg 9c (which I think it mean 90?), that might conflict with libjpeg62 that we want.

Anyone know where can I find Gazebo screenshot for the app store?
Thanks.

I successfully build Gazebo with github CI.
hxxps://github.com/flathub/flathub/pull/2296

Please try it out.
First, install Flatpak. Setup according to your Linux distro.
hxxps://flatpak.org/setup/

Installing the test build by using this command.

flatpak install --user https://dl.flathub.org/build-repo/45107/org.gazebosim.Gazebo.flatpakref

Note that this is not release to Flathub yet.
This build is 500 MB in size because I did not delete any left over development files from its dependencies yet.

Gazebo flatpak can be run with.
flatpak run org.gazebosim.Gazebo

Pass option to it with something like this.
flatpak run org.gazebosim.Gazebo --verbose

I have issue Gazebo crash on start up. I would like for someone to help test it out.

Thanks.

I open an issue here in github.
hxxps://github.com/osrf/gazebo/issues/2986

I got this error when run gazebo with --verbose.

[Err] [main.cc:37] Ogre Error:RuntimeAssertionException: Ogre/ShadowExtrudePointLight not found. Verify that you referenced the ‘Shad
owVolume’ folder in your resources.cfg in initialise at /run/build/ORGE/OgreMain/src/OgreShadowVolumeExtrudeProgram.cpp (line 70)

Which I believe have the same problem as this issue.
hxxps://github.com/osrf/gazebo/issues/2700