Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6.22.02 build failure with -Dx11=OFF #6368

Closed
cgleggett opened this issue Sep 16, 2020 · 6 comments · Fixed by #6502
Closed

6.22.02 build failure with -Dx11=OFF #6368

cgleggett opened this issue Sep 16, 2020 · 6 comments · Fixed by #6502
Assignees
Labels

Comments

@cgleggett
Copy link

Describe the bug

When building 6.22.02 with x11 disabled, there's a build error:

CMakeFiles/RGL.dir/src/TGLFormat.cxx.o: In function `TGLFormat::InitAvailableSamples()':
TGLFormat.cxx:(.text+0x35c): undefined reference to `XGetVisualInfo'
TGLFormat.cxx:(.text+0x476): undefined reference to `XFree'
CMakeFiles/RGL.dir/src/TGLWidget.cxx.o: In function `TGLWidget::CreateWindow(TGWindow const*, TGLFormat const&, unsigned int, unsigned int, std::pair<void*, void*>&)':
TGLWidget.cxx:(.text+0xcd5): undefined reference to `XCreateColormap'
TGLWidget.cxx:(.text+0xd28): undefined reference to `XCreateWindow'
CMakeFiles/RGL.dir/src/TGLWidget.cxx.o: In function `TGLWidget::~TGLWidget()':
TGLWidget.cxx:(.text+0x1765): undefined reference to `XFree'
collect2: error: ld returned 1 exit status
make[2]: *** [lib/libRGL.so] Error 1
make[1]: *** [graf3d/gl/CMakeFiles/RGL.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....

Expected behavior

a clean build

To Reproduce

setup gcc 9.2.0
> export CXX=g++
> export CC=gcc
> cmake -Dx11=OFF -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_EXTENSIONS=Off ../src
> make -j30

Setup

version: v6.22.02
OS: RHEL7
root built from git source (tag v6-22-02)
gcc: 9.2.0

@couet
Copy link
Member

couet commented Sep 17, 2020

Is it new problem with 6.22 ? This code (TGLFormat) is not recent and has not been changed recently.
The error messages you get would suggest X11 is not properly installed (or not found by the ROOT
install procedure) on your machine.

@oshadura
Copy link
Contributor

@cgleggett could you please post a CMake configuration log? Thanks!

@oshadura
Copy link
Contributor

Ah this issue is known https://sft.its.cern.ch/jira/browse/ROOT-10640 and in fact, I opened pr to fix it some time ago #5524. I will finish it and backport it to 6.22 as well.

@oshadura oshadura self-assigned this Sep 17, 2020
@couet couet removed their assignment Sep 17, 2020
@oshadura
Copy link
Contributor

@cgleggett I forgot to add that as a temporary fix you can just disable as opengl well.

@cgleggett
Copy link
Author

it wasn't there in 6.14.08 - I haven't tried anything in between.

This is on a host which has no X libraries installed (an HPC), and installing them myself is a non-starter.

I did rebuild successfully with -Dopengl=off

@oshadura
Copy link
Contributor

It is fixed in #5524

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants