GLEW segfault

25 views
Skip to first unread message

Tommy Hughes

unread,
Mar 29, 2023, 2:41:41 PM3/29/23
to hugin and other free panoramic software
I decided to build hugin from source to get the latest version as ubuntu is still on version 2021. The build succeeded but hugin fails to start with the following error. I understand this is related to wxWidgets being compiled with EGL support, but I don't know how to proceed from here?

(hugin:5957): Gtk-CRITICAL **: 19:36:35.424: gtk_widget_set_size_request: assertion 'height >= -1' failed
/usr/local/share/hugin/data/plugins/woa.py
  CAT:Control Points
  NAM:Warped Overlap Analysis
  fails @api-max
/usr/local/share/hugin/data/plugins/top_five.py
  CAT:Control Points
  NAM:keep 5 CPs per image pair
  fails @api-max
ERROR: 19:36:35.687688 (/home/thomas/src/hugin/hugin.hg/src/hugin1/hugin/GLViewer.cpp:155) SetUpContext(): Error initialising GLEW: Unknown
error.
[1]    5957 segmentation fault (core dumped)  hugin


Tommy Hughes

unread,
Mar 29, 2023, 3:12:06 PM3/29/23
to hugin and other free panoramic software
I solved it by building glew 2.2.0 from https://sourceforge.net/projects/glew/ using:

make SYSTEM=linux-egl              
cd lib
sudo cp * /usr/lib/x86_64-linux-gnu

Then rebuild hugin.

T. Modes

unread,
Mar 29, 2023, 3:16:22 PM3/29/23
to hugin and other free panoramic software
This is mentioned in INSTALL_cmake file (which seems nobody is reading...):

On Linux wxWidgets 3.1.5 and later is by default compiled with EGL support for the wxGLCanvas class.
In this case you need to activate EGL support explicitly also in GLEW, otherwise there are crashes when
intializing the wxGLCanvas.

For the default branch there is also the following alternative added:
Alternatively you can also use the epoxy library instead of GLEW, which does
the detection at run time. To build with epoxy add -DBUILD_WITH_EPOXY=on to the CMake command line.

irthoma...@gmail.com

unread,
Mar 29, 2023, 3:33:57 PM3/29/23
to hugi...@googlegroups.com
I read it but didn't know how to activate egl support in glew. I had glew version 2.1, which doesn't mention it. Only glew 2.2.0 has it. 

--
A list of frequently asked questions is available at: http://wiki.panotools.org/Hugin_FAQ
---
You received this message because you are subscribed to the Google Groups "hugin and other free panoramic software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hugin-ptx+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/hugin-ptx/f6762a36-1942-4490-b5f3-7ea45e22f020n%40googlegroups.com.

T. Modes

unread,
Mar 29, 2023, 3:43:11 PM3/29/23
to hugin and other free panoramic software
irthoma...@gmail.com schrieb am Mittwoch, 29. März 2023 um 21:33:57 UTC+2:
I read it but didn't know how to activate egl support in glew. I had glew version 2.1, which doesn't mention it. Only glew 2.2.0 has it. 
glew 2.1 was released in July 2017, glew 2.2 in January 2021.
So nothing really new.



Tommy Hughes

unread,
Mar 30, 2023, 6:13:08 AM3/30/23
to hugin and other free panoramic software
Ah, to start with, I was following the hugin build instructions from the website.
The website needs updating to tell people to follow the build instructions in the download. Otherwise, the path you naturally follow is:  Search for hugin > find https://hugin.sourceforge.io/download/
> Compile from Source

T. Modes

unread,
Mar 30, 2023, 11:54:09 AM3/30/23
to hugin and other free panoramic software
irthoma...@gmail.com schrieb am Donnerstag, 30. März 2023 um 12:13:08 UTC+2:
Ah, to start with, I was following the hugin build instructions from the website.
The website needs updating to tell people to follow the build instructions in the download. Otherwise, the path you naturally follow is:  Search for hugin > find https://hugin.sourceforge.io/download/
> Compile from Source

thanks for the hint. I made some changes to make it more obviously that the first source is the INSTALL_cmake file and the links to the panotools wiki instructions are community contributed and may not be up-to-date.
We can't update the instructions for all possible distributions. So updates/corrections/fixes/clarifications by the users/community are always welcomes. This should be straightforward and can be done directly in the panotools wiki by the users.

Thomas
Reply all
Reply to author
Forward
0 new messages