FreeCAD and Raspberry Pi 4

This subforum is specifically to discuss packaging issues on different platforms (windows, mac, linux), and using different packaging systems (conda, etc...)
wmayer
Site Admin
Posts: 14991
Joined: Thu Feb 19, 2009 10:32 am

Re: FreeCAD and Raspberry Pi 4

Postby wmayer » Fri Oct 04, 2019 9:35 am

Here is the code of the function cc_glglue_instance: https://bitbucket.org/Coin3D/coin/src/a ... lines-2305
So to hunt down the problem we have to find out why setting up the GL context fails. Therefore, next step is to set the environment variable COIN_GL_NO_CURRENT_CONTEXT_CHECK

Code: Select all

export COIN_GL_NO_CURRENT_CONTEXT_CHECK=1
before starting FreeCAD. Then we can see if a current context is set or not.
User avatar
-alex-
Posts: 242
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: FreeCAD and Raspberry Pi 4

Postby -alex- » Fri Oct 04, 2019 6:34 pm

wmayer wrote:
Fri Oct 04, 2019 9:35 am
Therefore, next step is to set the environment variable COIN_GL_NO_CURRENT_CONTEXT_CHECK
Done:

Code: Select all

.....
SAL_USE_VCLPLUGIN=gtk3
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
MAIL=/var/mail/pi
COIN_GL_NO_CURRENT_CONTEXT_CHECK=1
OLDPWD=/home/pi/freecad-build
TEXTDOMAIN=Linux-PAM
_=/usr/bin/env
I get the following backtrace:

Code: Select all

pi@raspberrypi:~/freecad-build/bin $ gdb ./FreeCAD
GNU gdb (Raspbian 8.2.1-2) 8.2.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "arm-linux-gnueabihf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./FreeCAD...done.
(gdb) run
Starting program: /home/pi/freecad-build/bin/FreeCAD 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
FreeCAD 0.19, Libs: 0.19R18385 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2019
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##

[New Thread 0xad82f210 (LWP 1963)]
using qt5ct plugin
[New Thread 0xa775d210 (LWP 1964)]
D-Bus global menu: no
[New Thread 0xa09bd210 (LWP 1966)]
[New Thread 0x9fdff210 (LWP 1967)]
[New Thread 0x9f3ff210 (LWP 1968)]
D-Bus system tray: no
[New Thread 0x9d1ff210 (LWP 1969)]
connect failed: No such file or directory
Coin warning in cc_glglue_instance(): Error when setting up the GL context. This can happen if there is no current context, or if the context has been set up incorrectly.

Thread 1 "FreeCAD" received signal SIGSEGV, Segmentation fault.
0xaf43fe74 in XDefaultScreenOfDisplay () from /usr/lib/arm-linux-gnueabihf/libX11.so.6
(gdb) bt full
#0  0xaf43fe74 in XDefaultScreenOfDisplay () at /usr/lib/arm-linux-gnueabihf/libX11.so.6
#1  0xb3565ad0 in  () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#2  0xb3566454 in glxglue_init () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#3  0xb355f0e0 in cc_glglue_instance () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#4  0xb3410120 in SoGLRenderActionP::isDirectRendering(SoState const*) const () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#5  0xb3412358 in SoGLRenderActionP::render(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#6  0xb34125a0 in SoGLRenderAction::beginTraversal(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#7  0xb340c2fc in SoAction::apply(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#8  0xb5fb1b38 in Gui::SoBoxSelectionRenderAction::apply(SoNode*) (this=0x9b7b68, node=0xe90f28) at /home/pi/freecad-source/src/Gui/SoFCSelectionAction.cpp:1180
        __PRETTY_FUNCTION__ = "virtual void Gui::SoBoxSelectionRenderAction::apply(SoNode*)"
#9  0xb60a529c in Gui::View3DInventorViewer::renderScene() (this=0xfaab28) at /home/pi/freecad-source/src/Gui/View3DInventorViewer.cpp:2245
        vp = {winsize = {vec = {1650, 638}}, vporigin = {vec = {0, 0}}, vpsize = {vec = {1, 1}}, vporigin_s = {vec = {0, 0}}, vpsize_s = {vec = {1650, 638}}, pixperinch = 72}
        origin = {vec = {0, 0}}
        size = {vec = {1650, 638}}
        col = 
              {cspec = QColor::Rgb, ct = {argb = {alpha = 65535, red = 60138, green = 58853, blue = 56540, pad = 0}, ahsv = {alpha = 65535, hue = 60138, saturation = 58853, value = 56540, pad = 0}, acmyk = {alpha = 65535, cyan = 60138, magenta = 58853, yellow = 56540, black = 0}, ahsl = {alpha = 65535, hue = 60138, saturation = 58853, lightness = 56540, pad = 0}, array = {65535, 60138, 58853, 56540, 0}}}
        glra = 0x9b7b68
        state = 0xfa8de0
#10 0xb60a4bb8 in Gui::View3DInventorViewer::actualRedraw() (this=0xfaab28) at /home/pi/freecad-source/src/Gui/View3DInventorViewer.cpp:2128
#11 0xb604775c in SIM::Coin3D::Quarter::QuarterWidget::paintEvent(QPaintEvent*) (this=0xfaab28, event=0xbeffcfa0) at /home/pi/freecad-source/src/Gui/Quarter/QuarterWidget.cpp:922
        w = 0x10280b0
        __PRETTY_FUNCTION__ = "virtual void SIM::Coin3D::Quarter::QuarterWidget::paintEvent(QPaintEvent*)"
#12 0xb6050d24 in SIM::Coin3D::Quarter::SoQTQuarterAdaptor::paintEvent(QPaintEvent*) (this=0xfaab28, event=0xbeffcfa0) at /home/pi/freecad-source/src/Gui/Quarter/SoQTQuarterAdaptor.cpp:723
        start = 1570212998.821115
#13 0xb287d590 in QWidget::event(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#14 0xb29261bc in QFrame::event(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#15 0xb2b83118 in QGraphicsView::viewportEvent(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#16 0xb604792c in SIM::Coin3D::Quarter::QuarterWidget::viewportEvent(QEvent*) (this=0xfaab28, event=0xbeffcfa0) at /home/pi/freecad-source/src/Gui/Quarter/QuarterWidget.cpp:996
#17 0xb208a090 in QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Core.so.5
#18 0xb283ada0 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#19 0xb28432a8 in QApplication::notify(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#20 0x010280b0 in  ()
(gdb) quit
A debugging session is active.

	Inferior 1 [process 1947] will be killed.

Quit anyway? (y or n) y
Is it what you expected? AFAIK I don't see any difference with previous backtrace, however I'm like an ant in honey...


FYI sometimes I've got another error below when running ./FreeCAD. Freecad even don't start this time, the last time this error occured while opening "about Freecad" menu.

Code: Select all

Coin warning in cc_glglue_instance(): Error when setting up the GL context. This can happen if there is no current context, or if the context has been set up incorrectly.
Program received signal SIGSEGV, Segmentation fault.
#0  /lib/arm-linux-gnueabihf/libc.so.6(__default_sa_restorer+0) [0xb1a0e120]
QMutex: destroying locked mutex
pi@raspberrypi:~/freecad-build/bin $
One comment again: when I had updated the source code with "pull git", I've got an error message about 'Application.cpp' file, because of the modification QT_VERSION_CHECK( 5, 12, 0) -> 5, 11, 0. So, I've modified the file again with QT 5, 12, 0 only during the update. Then I've set again with QT 5, 11, 0 once pull git achieved. However, Before this last change, I've started Freecad to test, but the clipboard info mentioned 'Qt version/ 5.11.3.
I mean, now no matter if I set Qt 5,12,0 or Qt 5, 11, 0 in Application.cpp, Freecad info always mention QT version: 5.11.3.
Strange or not?

OS: Raspbian GNU/Linux 10 (buster) (LXDE/LXDE-pi)
Word size of OS: 32-bit
Word size of FreeCAD: 32-bit
Version: 0.19.18385 (Git)
Build type: Debug
Branch: master
Hash: c314edcaf675dd261e757bbf7b2f8b97c7e72130
Python version: 3.7.3
Qt version: 5.11.3
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)
Last edited by -alex- on Fri Oct 04, 2019 7:01 pm, edited 1 time in total.
vocx
Posts: 1852
Joined: Thu Oct 18, 2018 9:18 pm

Re: FreeCAD and Raspberry Pi 4

Postby vocx » Fri Oct 04, 2019 7:00 pm

-alex- wrote:
Fri Oct 04, 2019 6:34 pm
Is it what you expected? AFAIK I don't see any difference with previous backtrace, however I'm like an ant in honey...
Mmm. Honey.

Anyway, how are you setting the variable? Are you using some file that you find in Raspbian? That's not needed.

To test a single environmental variable, you can set it in the terminal, before running your command.

Code: Select all

export COIN_GL_NO_CURRENT_CONTEXT_CHECK=1
./FreeCAD
Or in the same line

Code: Select all

COIN_GL_NO_CURRENT_CONTEXT_CHECK=1 ./FreeCAD
You can do this as well before launching the debugger, or inside the debugger.

Code: Select all

(gdb) set env COIN_GL_NO_CURRENT_CONTEXT_CHECK 1
(gdb) run
User avatar
-alex-
Posts: 242
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: FreeCAD and Raspberry Pi 4

Postby -alex- » Fri Oct 04, 2019 7:24 pm

vocx wrote:
Fri Oct 04, 2019 7:00 pm
Mmm. Honey.
To be honest right now I'm eating some chocolate paste :D

vocx wrote:
Fri Oct 04, 2019 7:00 pm

Code: Select all

export COIN_GL_NO_CURRENT_CONTEXT_CHECK=1
./FreeCAD
Yes that's what I did, from bash.

I've tried it again, this time inside debugger as you say:

Code: Select all

pi@raspberrypi:~/freecad-build/bin $ gdb ./FreeCAD
GNU gdb (Raspbian 8.2.1-2) 8.2.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "arm-linux-gnueabihf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./FreeCAD...done.
(gdb) set env COIN_GL_NO_CURRENT_CONTEXT_CHECK=1
(gdb) run
Starting program: /home/pi/freecad-build/bin/FreeCAD 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
FreeCAD 0.19, Libs: 0.19R18385 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2019
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##

[New Thread 0xad82f210 (LWP 3687)]
using qt5ct plugin
[New Thread 0xa775d210 (LWP 3688)]
D-Bus global menu: no
[New Thread 0xa09bd210 (LWP 3689)]
[New Thread 0x9fdff210 (LWP 3690)]
[New Thread 0x9f3ff210 (LWP 3691)]
D-Bus system tray: no
[New Thread 0x9d1ff210 (LWP 3692)]
connect failed: No such file or directory
Coin warning in cc_glglue_instance(): Error when setting up the GL context. This can happen if there is no current context, or if the context has been set up incorrectly.

Thread 1 "FreeCAD" received signal SIGSEGV, Segmentation fault.
0xaf43fe74 in XDefaultScreenOfDisplay () from /usr/lib/arm-linux-gnueabihf/libX11.so.6
(gdb) bt full
#0  0xaf43fe74 in XDefaultScreenOfDisplay () at /usr/lib/arm-linux-gnueabihf/libX11.so.6
#1  0xb3565ad0 in  () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#2  0xb3566454 in glxglue_init () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#3  0xb355f0e0 in cc_glglue_instance () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#4  0xb3410120 in SoGLRenderActionP::isDirectRendering(SoState const*) const () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#5  0xb3412358 in SoGLRenderActionP::render(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#6  0xb34125a0 in SoGLRenderAction::beginTraversal(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#7  0xb340c2fc in SoAction::apply(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#8  0xb5fb1b38 in Gui::SoBoxSelectionRenderAction::apply(SoNode*) (this=0xa99e08, node=0xf2bae8) at /home/pi/freecad-source/src/Gui/SoFCSelectionAction.cpp:1180
        __PRETTY_FUNCTION__ = "virtual void Gui::SoBoxSelectionRenderAction::apply(SoNode*)"
#9  0xb60a529c in Gui::View3DInventorViewer::renderScene() (this=0xfaacf0) at /home/pi/freecad-source/src/Gui/View3DInventorViewer.cpp:2245
        vp = {winsize = {vec = {1650, 638}}, vporigin = {vec = {0, 0}}, vpsize = {vec = {1, 1}}, vporigin_s = {vec = {0, 0}}, vpsize_s = {vec = {1650, 638}}, pixperinch = 72}
        origin = {vec = {0, 0}}
        size = {vec = {1650, 638}}
        col = 
              {cspec = QColor::Rgb, ct = {argb = {alpha = 65535, red = 60138, green = 58853, blue = 56540, pad = 0}, ahsv = {alpha = 65535, hue = 60138, saturation = 58853, value = 56540, pad = 0}, acmyk = {alpha = 65535, cyan = 60138, magenta = 58853, yellow = 56540, black = 0}, ahsl = {alpha = 65535, hue = 60138, saturation = 58853, lightness = 56540, pad = 0}, array = {65535, 60138, 58853, 56540, 0}}}
        glra = 0xa99e08
        state = 0x1305e18
#10 0xb60a4bb8 in Gui::View3DInventorViewer::actualRedraw() (this=0xfaacf0) at /home/pi/freecad-source/src/Gui/View3DInventorViewer.cpp:2128
#11 0xb604775c in SIM::Coin3D::Quarter::QuarterWidget::paintEvent(QPaintEvent*) (this=0xfaacf0, event=0xbeffcfa0) at /home/pi/freecad-source/src/Gui/Quarter/QuarterWidget.cpp:922
        w = 0x8c8c10
        __PRETTY_FUNCTION__ = "virtual void SIM::Coin3D::Quarter::QuarterWidget::paintEvent(QPaintEvent*)"
#12 0xb6050d24 in SIM::Coin3D::Quarter::SoQTQuarterAdaptor::paintEvent(QPaintEvent*) (this=0xfaacf0, event=0xbeffcfa0) at /home/pi/freecad-source/src/Gui/Quarter/SoQTQuarterAdaptor.cpp:723
        start = 1570217811.1295891
#13 0xb287d590 in QWidget::event(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#14 0xb29261bc in QFrame::event(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#15 0xb2b83118 in QGraphicsView::viewportEvent(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#16 0xb604792c in SIM::Coin3D::Quarter::QuarterWidget::viewportEvent(QEvent*) (this=0xfaacf0, event=0xbeffcfa0) at /home/pi/freecad-source/src/Gui/Quarter/QuarterWidget.cpp:996
#17 0xb208a090 in QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Core.so.5
#18 0xb283ada0 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#19 0xb28432a8 in QApplication::notify(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#20 0x008c8c10 in  ()
(gdb) quit
A debugging session is active.

	Inferior 1 [process 3670] will be killed.

Quit anyway? (y or n) y
pi@raspberrypi:~/freecad-build/bin $ 
Lines

Code: Select all

        glra = 0xa99e08
        state = 0x1305e18
seem different with previous ones. I have no idea if it does matter...
wmayer
Site Admin
Posts: 14991
Joined: Thu Feb 19, 2009 10:32 am

Re: FreeCAD and Raspberry Pi 4

Postby wmayer » Sat Oct 05, 2019 11:58 am

By setting the env. variable this check was done: https://bitbucket.org/Coin3D/coin/src/a ... lines-2354
Because the assert() didn't fail it means that at least a current OpenGL context is set.

Because the last function call is glxglue_init() I think the crash only can happen here: https://bitbucket.org/Coin3D/coin/src/a ... #lines-486 where glXGetCurrentDisplay is a function pointer to XDefaultScreenOfDisplay.
One comment again: when I had updated the source code with "pull git", I've got an error message about 'Application.cpp' file, because of the modification QT_VERSION_CHECK( 5, 12, 0) -> 5, 11, 0. So, I've modified the file again with QT 5, 12, 0 only during the update.
You can revert your changes again as it appears that these settings are Windows-specific.
wmayer
Site Admin
Posts: 14991
Joined: Thu Feb 19, 2009 10:32 am

Re: FreeCAD and Raspberry Pi 4

Postby wmayer » Sat Oct 05, 2019 12:14 pm

When searching for "XDefaultScreenOfDisplay" and "crash" there I found this hit:
https://github.com/flathub/org.freecadw ... /issues/11

Can you try to set the env. variable

Code: Select all

export QT_QPA_PLATFORM=xcb
User avatar
-alex-
Posts: 242
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: FreeCAD and Raspberry Pi 4

Postby -alex- » Sun Oct 06, 2019 8:26 pm

Thanks Werner for you attention and explanations,
wmayer wrote:
Sat Oct 05, 2019 12:14 pm
Can you try to set the env. variable

Code: Select all

export QT_QPA_PLATFORM=xcb
Done:

Code: Select all

pi@raspberrypi:~ $ env
.......
XDG_GREETER_DATA_DIR=/var/lib/lightdm/data/pi
HOME=/home/pi
LANG=en_US.UTF-8
XDG_CURRENT_DESKTOP=LXDE
VTE_VERSION=5402
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
QT_QPA_PLATFORM=xcb
XDG_SESSION_CLASS=user
TERM=xterm-256color
USER=pi
.....
Then backtrace:

Code: Select all

pi@raspberrypi:~/freecad-build/bin $ gdb ./FreeCAD
GNU gdb (Raspbian 8.2.1-2) 8.2.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "arm-linux-gnueabihf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./FreeCAD...done.
(gdb) run
Starting program: /home/pi/freecad-build/bin/FreeCAD 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
FreeCAD 0.19, Libs: 0.19R18385 (Git)
© Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2019
  #####                 ####  ###   ####  
  #                    #      # #   #   # 
  #     ##  #### ####  #     #   #  #   # 
  ####  # # #  # #  #  #     #####  #   # 
  #     #   #### ####  #    #     # #   # 
  #     #   #    #     #    #     # #   #  ##  ##  ##
  #     #   #### ####   ### #     # ####   ##  ##  ##

[New Thread 0xad82f210 (LWP 2632)]
using qt5ct plugin
[New Thread 0xa775d210 (LWP 2634)]
D-Bus global menu: no
[New Thread 0xa09bd210 (LWP 2636)]
[New Thread 0x9fdff210 (LWP 2637)]
[New Thread 0x9f3ff210 (LWP 2638)]
D-Bus system tray: no
[New Thread 0x9d1ff210 (LWP 2639)]
connect failed: No such file or directory
[Detaching after fork from child process 2653]
[Detaching after fork from child process 2654]
Coin warning in cc_glglue_instance(): Error when setting up the GL context. This can happen if there is no current context, or if the context has been set up incorrectly.

Thread 1 "FreeCAD" received signal SIGSEGV, Segmentation fault.
0xaf43fe74 in XDefaultScreenOfDisplay () from /usr/lib/arm-linux-gnueabihf/libX11.so.6
(gdb) bt full
#0  0xaf43fe74 in XDefaultScreenOfDisplay () at /usr/lib/arm-linux-gnueabihf/libX11.so.6
#1  0xb3565ad0 in  () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#2  0xb3566454 in glxglue_init () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#3  0xb355f0e0 in cc_glglue_instance () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#4  0xb3410120 in SoGLRenderActionP::isDirectRendering(SoState const*) const () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#5  0xb3412358 in SoGLRenderActionP::render(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#6  0xb34125a0 in SoGLRenderAction::beginTraversal(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#7  0xb340c2fc in SoAction::apply(SoNode*) () at /usr/lib/arm-linux-gnueabihf/libCoin.so.80c
#8  0xb5fb1b38 in Gui::SoBoxSelectionRenderAction::apply(SoNode*) (this=0x941488, node=0x1025d88) at /home/pi/freecad-source/src/Gui/SoFCSelectionAction.cpp:1180
        __PRETTY_FUNCTION__ = "virtual void Gui::SoBoxSelectionRenderAction::apply(SoNode*)"
#9  0xb60a529c in Gui::View3DInventorViewer::renderScene() (this=0x12cd900) at /home/pi/freecad-source/src/Gui/View3DInventorViewer.cpp:2245
        vp = {winsize = {vec = {1650, 638}}, vporigin = {vec = {0, 0}}, vpsize = {vec = {1, 1}}, vporigin_s = {vec = {0, 0}}, vpsize_s = {vec = {1650, 638}}, pixperinch = 72}
        origin = {vec = {0, 0}}
        size = {vec = {1650, 638}}
        col = 
              {cspec = QColor::Rgb, ct = {argb = {alpha = 65535, red = 60138, green = 58853, blue = 56540, pad = 0}, ahsv = {alpha = 65535, hue = 60138, saturation = 58853, value = 56540, pad = 0}, acmyk = {alpha = 65535, cyan = 60138, magenta = 58853, yellow = 56540, black = 0}, ahsl = {alpha = 65535, hue = 60138, saturation = 58853, lightness = 56540, pad = 0}, array = {65535, 60138, 58853, 56540, 0}}}
        glra = 0x941488
        state = 0x1349a58
#10 0xb60a4bb8 in Gui::View3DInventorViewer::actualRedraw() (this=0x12cd900) at /home/pi/freecad-source/src/Gui/View3DInventorViewer.cpp:2128
#11 0xb604775c in SIM::Coin3D::Quarter::QuarterWidget::paintEvent(QPaintEvent*) (this=0x12cd900, event=0xbeffcf00) at /home/pi/freecad-source/src/Gui/Quarter/QuarterWidget.cpp:922
        w = 0x1148af8
        __PRETTY_FUNCTION__ = "virtual void SIM::Coin3D::Quarter::QuarterWidget::paintEvent(QPaintEvent*)"
#12 0xb6050d24 in SIM::Coin3D::Quarter::SoQTQuarterAdaptor::paintEvent(QPaintEvent*) (this=0x12cd900, event=0xbeffcf00) at /home/pi/freecad-source/src/Gui/Quarter/SoQTQuarterAdaptor.cpp:723
        start = 1570393357.2788661
#13 0xb287d590 in QWidget::event(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#14 0xb29261bc in QFrame::event(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#15 0xb2b83118 in QGraphicsView::viewportEvent(QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#16 0xb604792c in SIM::Coin3D::Quarter::QuarterWidget::viewportEvent(QEvent*) (this=0x12cd900, event=0xbeffcf00) at /home/pi/freecad-source/src/Gui/Quarter/QuarterWidget.cpp:996
#17 0xb208a090 in QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Core.so.5
#18 0xb283ada0 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#19 0xb28432a8 in QApplication::notify(QObject*, QEvent*) () at /usr/lib/arm-linux-gnueabihf/libQt5Widgets.so.5
#20 0x01148af8 in  ()
(gdb) quit
A debugging session is active.

	Inferior 1 [process 2617] will be killed.

Quit anyway? (y or n) y
pi@raspberrypi:~/freecad-build/bin $ 
OS: Raspbian GNU/Linux 10 (buster) (LXDE/LXDE-pi)
Word size of OS: 32-bit
Word size of FreeCAD: 32-bit
Version: 0.19.18385 (Git)
Build type: Debug
Branch: master
Hash: c314edcaf675dd261e757bbf7b2f8b97c7e72130
Python version: 3.7.3
Qt version: 5.11.3
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)
wmayer
Site Admin
Posts: 14991
Joined: Thu Feb 19, 2009 10:32 am

Re: FreeCAD and Raspberry Pi 4

Postby wmayer » Mon Oct 07, 2019 7:57 am

Now I have no idea what else you can try. Maybe it's a graphic driver problem.
User avatar
-alex-
Posts: 242
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: FreeCAD and Raspberry Pi 4

Postby -alex- » Mon Oct 07, 2019 3:43 pm

wmayer wrote:
Mon Oct 07, 2019 7:57 am
Now I have no idea what else you can try. Maybe it's a graphic driver problem.
Ok, thanks for your help anyway, much appreciated.
I'm not a developper, so I have not much idea than you of course.

However I have the RPI4 next to me, so I could:
- try to compile Freecad 0.19 with Py2/Qt4?
- try to compile Freecad 0.16 with Py2/Qt4 ? (because Papy told he ran 0.16 on RPI4 with success before this version was replaced by 0.18 in repo
https://forum.freecadweb.org/viewtopic. ... 14#p317122 (french)
I would like to see that by my own eyes, it could be a way to maybe track the bug?))
- try to compile Freecad's pivy in order to use it instead of pivy lib?

Could you guys tell me your opinion if such tries would make sens?
wmayer
Site Admin
Posts: 14991
Joined: Thu Feb 19, 2009 10:32 am

Re: FreeCAD and Raspberry Pi 4

Postby wmayer » Mon Oct 07, 2019 4:00 pm

- try to compile Freecad 0.19 with Py2/Qt4?
Yes, this should be possible. The current master branch still supports Py2 and Qt4.