Stream: brlcad

Topic: I package BRL-CAD as Flatpak for Linux. Anyone interest?


view this post on Zulip Kavin Teenakul (Jul 25 2023 at 09:42):

Hi,
I am experimenting on packaging BRL-CAD as Flatpak to distribute in Flathub for Linux distribution.
https://www.flatpak.org/
https://flathub.org/

The advantage is that once the package is distributed in Flathub. Any Linux distro can install and update BRL-CAD.
This also ensures that BRL-CAD that ships with Flathub are the same.

I have a Flatpak manifest here.
https://github.com/kevinsmia1939/flathub/tree/org.brlcad.BRL_CAD

I want to include more features, but failed to compile when I try to compile with Bullet.
https://github.com/BRL-CAD/brlcad/issues/86

Let me know if anyone is interest.

view this post on Zulip Daniel Rossberg (Jul 25 2023 at 17:57):

Hi @Kavin Teenakul, that's an interesting approach, which could work.

First, to answer your question: Don't use Bullet. It was included in the repository some time ago, because there were the chance it could be used. But, as far as I know, it won't be used anywhere in BRL-CAD.

I have however some more comments:

The only (open source) feature, which is not included in a default build, is the appleseed ray tracing art. But this requires an appleseed installation, and I would recommend to omit it for the moment.

view this post on Zulip Kavin Teenakul (Jul 25 2023 at 19:17):

Hi @Daniel Rossberg
Thank for the info. I temporary using the latest commit hoping that some of the issues were solved.
In the flatpak manifest, I use the bundled dependencies.
As for the optimization, did you mean building with -O3 or -O2 flag?
Edit: Found BRLCAD_OPTIMIZED:BOOL=ON which is ON by default.

view this post on Zulip Daniel Rossberg (Jul 26 2023 at 06:52):

On my machines, BRLCAD_OPTIMIZED is off by default.

However, have a look at the summery at the end of the CMake configuration, e.g.

CC       = /usr/bin/cc
CXX      = /usr/bin/c++
CFLAGS   = -std=c11 -D_POSIX_C_SOURCE=200809L -D_XOPEN_SOURCE=700 -pipe
           -fvisibility=hidden -fno-strict-aliasing -fno-common -fexceptions
           -m64 -g -ggdb3 -O3 -fipa-pta -fstrength-reduce
           -fexpensive-optimizations -finline-functions -flto
           -fno-omit-frame-pointer -pedantic -pedantic-errors -Wall -Wextra
           -Wundef -Wfloat-equal -Wshadow -Wbad-function-cast -Wc++-compat
           -Winline -Wno-long-long -Wno-variadic-macros -Werror
CXXFLAGS = -std=c++14 -D_POSIX_C_SOURCE=200809L -D_XOPEN_SOURCE=700 -pipe
           -fvisibility=hidden -fno-strict-aliasing -fno-common -fexceptions
           -ftemplate-depth-128 -m64 -g -ggdb3 -O3 -fipa-pta -fstrength-reduce
           -fexpensive-optimizations -finline-functions -flto
           -fno-omit-frame-pointer -pedantic -Wall -Wextra -Wundef
           -Wfloat-equal -Wshadow -Wbad-function-cast -Wno-inline
           -Wno-long-long -Wno-variadic-macros -Werror
LDFLAGS  = -m64 -g -ggdb3

Compile Tcl ........................: ON
Compile Tk .........................: ON
Compile Itcl/Itk ...................: ON
Compile Iwidgets ...................: ON
Compile libpng .....................: OFF
Compile libregex ...................: OFF
Compile zlib .......................: OFF
Compile STEPcode....................: ON

OpenGL support (optional) ..........: ON
X11 support (optional) .............: ON
Qt support (optional) ..............: OFF
Run-time debuggability (optional) ..: ON

Build 32/64-bit release ............: 64BIT (Auto)
Build with optimization ............: ON
Build static libraries .............: ON
Build dynamic libraries ............: ON
Install example geometry models ....: ON
Generate extra docs ................: ON (html/man)

There, you should see Build with optimization set to ON and CFLAGS and CXXFLAGS with -O3.

Which reminds me, when you build with Qt support, you get the experimental qged GUI as well.

view this post on Zulip Kavin Teenakul (Jul 26 2023 at 14:05):

Thanks. I start to build with Qt.

Do you know if BRLCAD_ENABLE_AQUA, BRLCAD_ENABLE_COVERAGE, BRLCAD_ENABLE_DTRACE, BRLCAD_ENABLE_OPENCL, and BRLCAD_ENABLE_OPENVDB are of any importance?

view this post on Zulip Daniel Rossberg (Jul 26 2023 at 17:10):

Aqua is the macOS GUI, i.e. not relevant for Linux. Code coverage tests and DTrace is useful for development only. Open Computing Language is used to execute parts of the ray-trace on the graphic card, which is still experimental and should not be used in production.

OpenVDB adds however the g-vdb export and a remesh for BOTs.

view this post on Zulip Kavin Teenakul (Aug 08 2023 at 22:50):

Hi,

I succeed in building BRL-CAD Flatpak.
Need some testers.

First install flatpak.
Ubuntu: sudo apt install flatpak
For other distros, follow this instructions. https://flathub.org/setup

optional: flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo

Then to install BRL-CAD flatpak.
flatpak install --user https://dl.flathub.org/build-repo/40303/org.brlcad.BRL_CAD.flatpakref

view this post on Zulip Sean (Aug 10 2023 at 22:40):

That's great to hear @Kavin Teenakul ... are there any metrics available for how many people end up installing via flatpak?

view this post on Zulip Kavin Teenakul (Aug 11 2023 at 00:23):

Sean said:

That's great to hear Kavin Teenakul ... are there any metrics available for how many people end up installing via flatpak?

Hi,
This is a test build, so the statistics are not collected.
The build is done here: https://github.com/flathub/flathub/pull/4363#

But once it is accept and upload to Flathub, there will be stats below. For example: https://flathub.org/apps/org.mozilla.firefox
Also, stats can also be view here: https://klausenbusk.github.io/flathub-stats/#ref=org.mozilla.firefox&interval=infinity&downloadType=installs

Right now, I just want someone to test BRL-CAD Flatpak. And I also want someone to be a co-owner of the repo in Github as well.
If anyone is interest in co-owner the Github repo let me know.

view this post on Zulip Kavin Teenakul (Aug 22 2023 at 22:55):

Anyone have give it a try?
Use this to install the latest test build.
flatpak install --user https://dl.flathub.org/build-repo/42975/org.brlcad.BRL_CAD.flatpakref

view this post on Zulip Daniel Rossberg (Aug 23 2023 at 16:23):

I haven't used Flatpak before, but I will definitely give it a try. However, it doesn't have top priority at the moment .


Last updated: Oct 09 2024 at 00:44 UTC