dimbor-ru / freenx-server

Evolution of classic nx technology - FreeNX. All these years, the classic nx was not as dead as it seemed ;) It is used in production and develops as fast as it can.
GNU General Public License v2.0
10 stars 5 forks source link

Add options ENABLE_GLX_PRELOAD and GLX_LD_PRELOAD #6

Open Djelff opened 4 years ago

Djelff commented 4 years ago

On some systems, in particular on systems with the NVidia driver on server, software glx drivers are not available. This problem is not only with us, read this: https://www.nomachine.com/AR01Q01012

The solution is to add "export LD_PRELOAD=/some_dir/libGL.so" to /home/user/.bashrc However, such a solution is not suitable if the user works both locally and remotely and complicates server administration.

I suggest adding options ENABLE_GLX_PRELOAD=1/0 and GLX_LD_PRELOAD=/some_dir/lib.so In this case, it will be possible to choose the fastest library, for example LLVMpipe or VirtualGL.

dimbor-ru commented 4 years ago

Does nxagent need to preload this library at startup? Not userapp only? freenx-server had a similar mechanism named SET_LD_LIBRARY_PATH (Now disabled for new nx-libs). It can help us, or we need to LD_PRELOAD for app immediate?

Djelff commented 4 years ago

Yes, I noticed that a similar mechanism used to be. No, this is not urgent, I work only remotely. But worth implementing.

uli42 commented 3 years ago

nxagent does not need that. It is the clients within the session the require it. I think the proper way is to provide a decent wrapper that takes care of that, say nxglxrun, which can be used to start an app. See https://wiki.x2go.org/doku.php/wiki:development:glx-xlib-workaround