I've been documenting my attempt to work around this problem here:
https://stackoverflow.com/questions/47415198/missing-gl-version-from-
glewinit-using-egl/54668271#54668271

I discovered an nvidia blog post - https://devblogs.nvidia.com/linking-
opengl-server-side-rendering/ - which says:

"If you want to use EGL context management instead, link against
libOpenGL.so and libEGL.so."

After installing the nvidia-410 package, as reported in the original
post, the EGL test program from the original post doesn't work if
linking against libGL.so:

$ wget 
https://gist.githubusercontent.com/funchal/bff0a8d6dae5b3ace1a88c392416b5bc/raw/1427821a2390a30779881ab59c55b5550a468919/main.c
$ gcc main.c -lGL -lEGL
$ ./a.out
egl 1.5
a.out: main.c:53: main: Assertion `renderer' failed.
Aborted (core dumped)

However it does work if linking against libOpenGL.so:

$ wget 
https://gist.githubusercontent.com/funchal/bff0a8d6dae5b3ace1a88c392416b5bc/raw/1427821a2390a30779881ab59c55b5550a468919/main.c
$ gcc main.c -L/usr/lib/nvidia-410 -lOpenGL -lEGL
$ ./a.out
egl 1.5
renderer: Tesla K80/PCIe/SSE2
version: 4.6.0 NVIDIA 410.78

With installing via a runfile as mentioned by mmatl in post #8, the test
program works when linking against either libGL.so or libOpenGL.so.

The difference between the packaged and runfile drivers may be due to
the dependencies linked into libGL.so (I included a comparison in the
stackoverflow post).

The final solution is therefore to link against libOpenGL.so instead of
libGL.so.

-- 
You received this bug notification because you are a member of Ubuntu-X,
which is subscribed to nvidia-graphics-drivers in Ubuntu.
https://bugs.launchpad.net/bugs/1731968

Title:
  384.90-0ubuntu0.16.04.2 EGL crashes at startup

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/nvidia-graphics-drivers/+bug/1731968/+subscriptions

_______________________________________________
Mailing list: https://launchpad.net/~ubuntu-x-swat
Post to     : ubuntu-x-swat@lists.launchpad.net
Unsubscribe : https://launchpad.net/~ubuntu-x-swat
More help   : https://help.launchpad.net/ListHelp

Reply via email to