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

graphic: use GLVND to dispatch graphic API calls #3790

Merged
merged 5 commits into from Sep 18, 2019

Conversation

5schatten
Copy link
Contributor

@5schatten 5schatten commented Sep 3, 2019

This PR adds https://github.com/NVIDIA/libglvnd which is already supported by MESA 3D and newer Nvidia drivers. It slightly updates the xorg-configure script to create matching symlinks for the new libs and adjusts the mesa & xf86-video-nvidia package to use libglvnd. These changes are mandatory for all upcoming nvidia drivers past version 430 which will drop non-GLVND binaries.

It was tested on my Intel i3-6100, Asrock J3455-ITX systems which use the IGP, my workstation which uses a GTX 1060 6GB, on a systems using the legacy-driver with a 8400GS and on a ION2 based system owned by @MilhouseVH

Changes:

  • libglvnd: initial package v1.1.1 / added pkgconfig patch
  • mesa: updated to support libglvnd / clean up
  • xf86-video-nvidia: updated to support libglvnd / clean up / updated lima & panfrost to 19.2.0-rc1 / enabled GLES v1 for OpenGL ES builds -> necessary for some third party addons which needs these libs & headers
  • xorg-server: updated to support libglvnd / clean up
  • libepoxy: switched toolchain to meson / clean up

some docs:
https://devtalk.nvidia.com/default/topic/915640/multiple-glx-client-libraries-in-the-nvidia-linux-driver-installer-package/
https://devtalk.nvidia.com/default/topic/1032650/linux/unix-graphics-feature-deprecation-schedule/

@5schatten
Copy link
Contributor Author

Latest changes NVIDIA/libglvnd#179 build and work fine with mesa 19.2.0-rc1 🤔 @MilhouseVH mesa 19.1.5 works fine with this update too?

@lrusak
Copy link
Member

lrusak commented Sep 4, 2019

@evelikov if you possibly have some free time would you be able to give this a quick review? I know you're the one that said we should switch to use GLVND some time ago. 👍

@MilhouseVH MilhouseVH merged commit 12a609a into LibreELEC:master Sep 18, 2019
if [ "$DISPLAYSERVER" != "x11" ]; then
PKG_CONFIGURE_OPTS_TARGET="--disable-glx"
if [ "${DISPLAYSERVER}" != "x11" ]; then
PKG_MESON_OPTS_TARGET="-D glx=no"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no space between -D glx

cp -P nvidia_drv.so $INSTALL/$XORG_PATH_MODULES/drivers/nvidia-main_drv.so
ln -sf /var/lib/nvidia_drv.so $INSTALL/$XORG_PATH_MODULES/drivers/nvidia_drv.so
mkdir -p ${INSTALL}/${XORG_PATH_MODULES}/drivers
cp -P nvidia_drv.so ${INSTALL}/${XORG_PATH_MODULES}/drivers/nvidia-main_drv.so
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't align things like this. Same for all the lines below

ln -sf /usr/lib/vdpau/libvdpau_nvidia-main.so.1 /var/lib/libvdpau_nvidia.so
ln -sf /usr/bin/nvidia-main-smi /var/lib/nvidia-smi
ln -sf /usr/bin/nvidia-main-xconfig /var/lib/nvidia-xconfig
ln -sf /usr/lib/libnvidia-ml.so.@NVIDIA_VERSION@ /var/lib/libnvidia-ml.so.1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't align like this

@lrusak
Copy link
Member

lrusak commented Sep 18, 2019

looks like someone has a lot of cleanup to do now that this is merged 😸

@5schatten
Copy link
Contributor Author

Well what's the problem with the alignment? Otherwise readability is down to zero if you install a bunch of files 🤔

@lrusak
Copy link
Member

lrusak commented Sep 18, 2019

because if you add or remove one then you may have to move the alignment for all the lines.

@5schatten
Copy link
Contributor Author

That's the whole point. Nvidia tends to add, remove or rename libs out of the blue and with this alignment I see on first sight which is missing or has changed. If the "price" for this is to push the spacebar if the file with longest name has randomly changed then I'm willing to do it. ¯\_(ツ)_/¯

Beside that I guess nobody else is maintaining the Nvidia stuff actively anyway 😉

@5schatten 5schatten deleted the libglvnd branch September 18, 2019 19:19
@lrusak
Copy link
Member

lrusak commented Sep 18, 2019

we have never used alignment before and we aren't about to start now. So please fix it or revert the whole lot. Thanks.

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

Successfully merging this pull request may close these issues.

None yet

4 participants