From: voidlinux-github@inbox.vuxu.org
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] [WIP] xbps-src, libGL: fix debug symbols generation for mesa libraries
Date: Tue, 22 Oct 2019 11:20:55 +0200 [thread overview]
Message-ID: <20191022092055.Muy50q1JMWVh9cfJ6Akr86IjD0Nq2N3VQCCCgyNwo_0@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-15683@inbox.vuxu.org>
[-- Attachment #1: Type: text/plain, Size: 1155 bytes --]
There is an updated pull request by st3r4g against master on the void-packages repository
https://github.com/st3r4g/void-packages mesa-fix-dbg
https://github.com/void-linux/void-packages/pull/15683
[WIP] xbps-src, libGL: fix debug symbols generation for mesa libraries
Aims to fix #12760 and #15104
I believe that two things must be addressed in order to fix the issue:
1. `xbps-src` must be aware of hard links when stripping debug symbols.
2. `libGL` must be reorganized by creating a subpackage for each "megadriver" that creates hard links (hard links to the same megadriver must be together in the same subpackage).
This is currently just a first step, I moved all the hard links to `libmesa_dri_drivers.so` to a new subpackage `mesa-dri` as a first example. Next would be to create a new subpackage for the aliases to `libgallium_dri.so` and so on, while also removing the current separation by vendors. The final result is going to be a pretty big change in the template structure, so let me know whether it's a good idea or not before I go on.
A patch file from https://github.com/void-linux/void-packages/pull/15683.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-mesa-fix-dbg-15683.patch --]
[-- Type: text/x-diff, Size: 8355 bytes --]
From fb9cc86cc393bd0d39dc55583d405e2b82abace3 Mon Sep 17 00:00:00 2001
From: Stefano Ragni <st3r4g@protonmail.com>
Date: Tue, 22 Oct 2019 00:44:41 +0200
Subject: [PATCH 1/2] xbps-src: strip hard links once
---
common/hooks/post-install/06-strip-and-debug-pkgs.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/hooks/post-install/06-strip-and-debug-pkgs.sh b/common/hooks/post-install/06-strip-and-debug-pkgs.sh
index a15dd1a96c3..34ed3553aef 100644
--- a/common/hooks/post-install/06-strip-and-debug-pkgs.sh
+++ b/common/hooks/post-install/06-strip-and-debug-pkgs.sh
@@ -65,7 +65,7 @@ hook() {
STRIPCMD=/usr/bin/$STRIP
- find ${PKGDESTDIR} -type f | while read f; do
+ find ${PKGDESTDIR} -type f -printf '%p %i\n' | awk '!seen[$2]++' | cut -d ' ' -f1 | while read f; do
if [[ $f =~ ^${PKGDESTDIR}/usr/lib/debug/ ]]; then
continue
fi
From 7bdeacd93fe66bdd3ce6e34208ecdb4803460d3b Mon Sep 17 00:00:00 2001
From: Stefano Ragni <st3r4g@protonmail.com>
Date: Tue, 22 Oct 2019 00:50:52 +0200
Subject: [PATCH 2/2] libGL: reorganize subpackages by megadrivers
Many Mesa libraries are hard links to the same file, called a
`megadriver`, so they should be grouped in the same subpackage.
---
srcpkgs/libGL/template | 86 +++++++++++--------
srcpkgs/{mesa-ati-dri => mesa-dri} | 0
srcpkgs/{mesa-intel-dri => mesa-gallium-dri} | 0
.../{mesa-nouveau-dri => mesa-vulkan-intel} | 0
.../{mesa-vmwgfx-dri => mesa-vulkan-radeon} | 0
5 files changed, 48 insertions(+), 38 deletions(-)
rename srcpkgs/{mesa-ati-dri => mesa-dri} (100%)
rename srcpkgs/{mesa-intel-dri => mesa-gallium-dri} (100%)
rename srcpkgs/{mesa-nouveau-dri => mesa-vulkan-intel} (100%)
rename srcpkgs/{mesa-vmwgfx-dri => mesa-vulkan-radeon} (100%)
diff --git a/srcpkgs/libGL/template b/srcpkgs/libGL/template
index 3ce62fe073f..dd35150c3c4 100644
--- a/srcpkgs/libGL/template
+++ b/srcpkgs/libGL/template
@@ -1,7 +1,7 @@
# Template file for 'libGL'
pkgname=libGL
version=19.2.1
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dshared-glapi=true -Dgbm=true -Degl=true
@@ -33,6 +33,7 @@ subpackages="libglapi libgbm libEGL libGLES libOSMesa"
case "$XBPS_TARGET_MACHINE" in
i686*|x86_64*)
# Enable all x86 drivers.
+ # TODO: Why not the gallium version of i915?
configure_args+=" -Dgallium-drivers=r300,r600,radeonsi,svga,swrast,nouveau,virgl"
configure_args+=" -Ddri-drivers=i915,i965,r100,r200,nouveau"
configure_args+=" -Dgallium-xa=true -Ddri3=true -Dgallium-nine=true"
@@ -40,8 +41,8 @@ i686*|x86_64*)
configure_args+=" -Dgallium-opencl=icd"
hostmakedepends+=" clang"
makedepends+=" libclc-git"
- subpackages+=" libxatracker mesa-ati-dri mesa-intel-dri mesa-nouveau-dri"
- subpackages+=" mesa-vmwgfx-dri mesa-opencl"
+ subpackages+=" libxatracker mesa-dri mesa-gallium-dri"
+ subpackages+=" mesa-opencl"
;;
ppc*)
# Enable all ppc drivers.
@@ -56,21 +57,21 @@ ppc*)
esac
hostmakedepends+=" clang"
makedepends+=" libclc-git"
- subpackages+=" mesa-ati-dri mesa-nouveau-dri"
+ subpackages+=" mesa-dri mesa-gallium-dri"
subpackages+=" mesa-opencl"
;;
aarch64*)
configure_args+=" -Dgallium-drivers=nouveau,tegra,swrast,vc4"
configure_args+=" -Dvulkan-drivers= -Ddri-drivers="
configure_args+=" -Dgallium-xa=false -Ddri3=true"
- subpackages+=" mesa-tegra-dri mesa-nouveau-dri mesa-vc4-dri"
+ subpackages+=" mesa-tegra-dri mesa-ati-dri mesa-gallium-dri mesa-vc4-dri"
;;
armv7l*)
# Enable Videocore IV and swrast for RaspberryPi
configure_args+=" -Dgallium-drivers=swrast,vc4"
configure_args+=" -Dvulkan-drivers= -Ddri-drivers= -Dgallium-xvmc=false"
configure_args+=" -Dgallium-xa=false -Dgallium-vdpau=false -Dgallium-va=false"
- subpackages+=" mesa-vc4-dri"
+ subpackages+=" mesa-gallium-dri mesa-vc4-dri"
;;
*)
# Enable swrast driver.
@@ -78,6 +79,7 @@ armv7l*)
configure_args+=" -Ddri-drivers= -Dvulkan-drivers= -Dgallium-va=false"
configure_args+=" -Dgallium-vdpau=false -Dgallium-xvmc=false"
configure_args+=" -Dgallium-xa=false"
+ subpackages+=" mesa-gallium-dri"
;;
esac
@@ -106,6 +108,7 @@ esac
post_install() {
vlicense docs/license.html
vmkdir usr/lib/xorg/modules/extensions
+# TODO: This file is not installed in musl
ln -s libglx-xorg.so ${DESTDIR}/usr/lib/xorg/modules/extensions/libglx.so
case "$XBPS_TARGET_MACHINE" in
i686*)
@@ -175,59 +178,59 @@ libxatracker_package() {
}
}
-mesa-ati-dri_package() {
- short_desc="Mesa DRI drivers for ATI GPUs"
- lib32files="/usr/share/vulkan/icd.d/radeon_icd.i686.json"
+mesa-dri_package() {
+ short_desc="Mesa DRI drivers for i915/i965/nouveau/r200/radeon"
+ pkg_install() {
+ vmove "usr/lib/xorg/modules/drivers/i9[16]5_dri.so"
+ vmove "usr/lib/xorg/modules/drivers/nouveau_vieux_dri.so"
+ vmove "usr/lib/xorg/modules/drivers/r200_dri.so"
+ vmove "usr/lib/xorg/modules/drivers/radeon_dri.so"
+ }
+}
+
+mesa-gallium-dri_package() {
+ short_desc="Mesa Gallium DRI drivers for r300/r600/radeonsi(...)"
pkg_install() {
vmove "usr/lib/libXvMCr[36]00.so.*"
vmove "usr/lib/vdpau/libvdpau_r[36]00.so*"
vmove "usr/lib/vdpau/libvdpau_radeon*.so*"
- vmove "usr/lib/xorg/modules/drivers/radeon*"
- vmove "usr/lib/xorg/modules/drivers/r[236]00*"
vmove usr/lib/dri/r*
- vmove "usr/share/vulkan/icd.d/radeon_icd*.json"
- vmove "usr/lib/libvulkan_radeon.so"
vmove "usr/lib/gallium-pipe/pipe_r[36]00.so"
vmove usr/lib/gallium-pipe/pipe_radeonsi.so
- }
-}
-mesa-intel-dri_package() {
- short_desc="Mesa DRI drivers for Intel GPUs"
- lib32files="/usr/share/vulkan/icd.d/intel_icd.i686.json"
- pkg_install() {
- vmove "usr/lib/xorg/modules/drivers/i9[16]5_dri.*"
- vmove "usr/share/vulkan/icd.d/intel_icd*.json"
- vmove "usr/lib/libvulkan_intel.so"
- }
-}
-
-mesa-nouveau-dri_package() {
- short_desc="Mesa DRI drivers for NVIDIA GPUs (nouveau dri)"
- pkg_install() {
vmove "usr/lib/libXvMCnouveau.so.*"
vmove "usr/lib/vdpau/libvdpau_nouveau.so*"
- vmove "usr/lib/xorg/modules/drivers/nouveau*"
vmove "usr/lib/dri/nouveau*"
case "$XBPS_TARGET_MACHINE" in
aarch64*) ;;
*) vmove usr/lib/gallium-pipe/pipe_nouveau.so ;;
esac
+
+ vmove "usr/lib/xorg/modules/drivers/vmwgfx*"
+ vmove usr/lib/gallium-pipe/pipe_vmwgfx.so
+
+# TODO: brace expansion doesn't work?
+ vmove "usr/lib/xorg/modules/drivers/swrast_dri.so"
+ vmove "usr/lib/xorg/modules/drivers/kms_swrast_dri.so"
+ vmove "usr/lib/xorg/modules/drivers/virtio_gpu_dri.so"
}
}
-mesa-vmwgfx-dri_package() {
- short_desc="Mesa DRI drivers for VMware"
+mesa-vulkan-radeon_package() {
+ short_desc="Mesa Radeon Vulkan driver"
+ lib32files="/usr/share/vulkan/icd.d/radeon_icd.i686.json"
pkg_install() {
- vmove "usr/lib/xorg/modules/drivers/vmwgfx*"
- vmove usr/lib/gallium-pipe/pipe_vmwgfx.so
+ vmove "usr/share/vulkan/icd.d/radeon_icd*.json"
+ vmove "usr/lib/libvulkan_radeon.so"
}
}
-mesa-vc4-dri_package() {
- short_desc="Mesa DRI drivers for Videocore IV GPU"
+mesa-vulkan-intel_package() {
+ short_desc="Mesa Intel Vulkan driver"
+ lib32files="/usr/share/vulkan/icd.d/intel_icd.i686.json"
pkg_install() {
- vmove "usr/lib/xorg/modules/drivers/vc4*"
+ vmove "usr/share/vulkan/icd.d/intel_icd*.json"
+ vmove "usr/lib/libvulkan_intel.so"
}
}
@@ -240,9 +243,16 @@ mesa-opencl_package() {
}
}
+mesa-vc4-dri_package() {
+ short_desc="Mesa DRI drivers for Videocore IV GPU"
+ pkg_install() {
+ vmove "usr/lib/xorg/modules/drivers/vc4*"
+ }
+}
+
mesa-tegra-dri_package() {
- short_desc="Mesa DRI drivers for Tegra GPU"
- depends="mesa-nouveau-dri"
+ short_desc="Mesa Gallium DRI drivers for Tegra GPU"
+ depends="mesa-gallium-dri"
pkg_install() {
vmove "usr/lib/xorg/modules/drivers/tegra*"
}
diff --git a/srcpkgs/mesa-ati-dri b/srcpkgs/mesa-dri
similarity index 100%
rename from srcpkgs/mesa-ati-dri
rename to srcpkgs/mesa-dri
diff --git a/srcpkgs/mesa-intel-dri b/srcpkgs/mesa-gallium-dri
similarity index 100%
rename from srcpkgs/mesa-intel-dri
rename to srcpkgs/mesa-gallium-dri
diff --git a/srcpkgs/mesa-nouveau-dri b/srcpkgs/mesa-vulkan-intel
similarity index 100%
rename from srcpkgs/mesa-nouveau-dri
rename to srcpkgs/mesa-vulkan-intel
diff --git a/srcpkgs/mesa-vmwgfx-dri b/srcpkgs/mesa-vulkan-radeon
similarity index 100%
rename from srcpkgs/mesa-vmwgfx-dri
rename to srcpkgs/mesa-vulkan-radeon
next prev parent reply other threads:[~2019-10-22 9:20 UTC|newest]
Thread overview: 73+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-21 23:34 [PR PATCH] " voidlinux-github
2019-10-22 9:20 ` voidlinux-github [this message]
2019-10-22 9:20 ` [PR PATCH] [Updated] " voidlinux-github
2019-10-22 9:30 ` voidlinux-github
2019-10-22 9:30 ` voidlinux-github
2019-10-22 10:15 ` [PR PATCH] [Updated] " voidlinux-github
2019-10-22 10:15 ` voidlinux-github
2019-10-22 15:17 ` voidlinux-github
2019-10-22 15:17 ` voidlinux-github
2019-10-22 22:30 ` voidlinux-github
2019-10-22 22:30 ` voidlinux-github
2019-10-22 23:32 ` voidlinux-github
2019-10-22 23:34 ` voidlinux-github
2019-10-22 23:39 ` voidlinux-github
2019-10-23 11:39 ` [PR PATCH] [Updated] " voidlinux-github
2019-10-23 11:39 ` voidlinux-github
2019-10-23 11:47 ` [WIP] " voidlinux-github
2019-10-23 11:48 ` voidlinux-github
2019-10-23 11:49 ` voidlinux-github
2019-10-23 11:55 ` voidlinux-github
2019-10-23 11:57 ` voidlinux-github
2019-10-23 15:19 ` [PR PATCH] [Updated] " voidlinux-github
2019-10-23 15:19 ` voidlinux-github
2019-10-23 15:26 ` voidlinux-github
2019-10-24 12:41 ` voidlinux-github
2019-10-24 12:41 ` voidlinux-github
2019-10-24 13:47 ` [PR PATCH] [Updated] " voidlinux-github
2019-10-24 13:47 ` voidlinux-github
2019-10-24 13:47 ` voidlinux-github
2019-10-26 12:56 ` [PR PATCH] [Updated] [RFC] libGL: reorganize dri drivers subpkgs (fixes debug info) voidlinux-github
2019-10-26 12:56 ` voidlinux-github
2019-10-26 13:01 ` voidlinux-github
2019-10-26 13:01 ` voidlinux-github
2019-10-26 13:03 ` voidlinux-github
2019-10-26 13:16 ` voidlinux-github
2019-10-26 13:17 ` voidlinux-github
2019-10-26 13:18 ` voidlinux-github
2019-10-27 6:17 ` voidlinux-github
2019-10-27 10:55 ` voidlinux-github
2019-10-27 10:58 ` voidlinux-github
2019-10-27 10:58 ` voidlinux-github
2019-10-27 11:00 ` voidlinux-github
2019-10-27 11:04 ` voidlinux-github
2019-10-27 11:07 ` voidlinux-github
2019-10-27 11:10 ` voidlinux-github
2019-10-27 11:23 ` voidlinux-github
2019-10-27 11:24 ` voidlinux-github
2019-10-27 11:34 ` voidlinux-github
2019-10-27 11:36 ` voidlinux-github
2019-10-27 11:51 ` [PR PATCH] [Updated] " voidlinux-github
2019-10-27 11:51 ` voidlinux-github
2019-10-27 12:00 ` voidlinux-github
2019-10-27 15:24 ` voidlinux-github
2019-11-02 10:14 ` voidlinux-github
2019-11-02 12:55 ` voidlinux-github
2019-11-10 10:15 ` voidlinux-github
2019-11-10 10:17 ` voidlinux-github
2019-11-10 10:36 ` voidlinux-github
2019-11-11 20:13 ` [PR PATCH] [Updated] " voidlinux-github
2019-11-11 20:19 ` voidlinux-github
2019-11-11 20:20 ` voidlinux-github
2019-11-11 20:21 ` voidlinux-github
2019-12-25 7:40 ` [RFC] mesa: " voidlinux-github
2019-12-25 7:41 ` voidlinux-github
2019-12-25 15:48 ` voidlinux-github
2019-12-25 19:05 ` [PR PATCH] [Closed]: " voidlinux-github
2019-12-27 17:03 ` voidlinux-github
2019-12-27 17:06 ` voidlinux-github
2019-12-27 17:06 ` voidlinux-github
2019-12-27 17:09 ` voidlinux-github
2019-12-27 17:53 ` voidlinux-github
2019-12-27 18:42 ` voidlinux-github
2019-12-27 18:42 ` voidlinux-github
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20191022092055.Muy50q1JMWVh9cfJ6Akr86IjD0Nq2N3VQCCCgyNwo_0@z \
--to=voidlinux-github@inbox.vuxu.org \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).