FS#75063 - [mesa-demos] broken tile.rgp path

Attached to Project: Arch Linux
Opened by Natrio (natrio) - Tuesday, 14 June 2022, 11:32 GMT
Last edited by Andreas Radke (AndyRTR) - Thursday, 16 June 2022, 17:51 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Andreas Radke (AndyRTR)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

After build system change in version 8.5.0
the path "/usr/share/mesa-demos" is not specified anymore:

build() {
- ./configure --prefix=/usr \
- --disable-gles1 \
- --with-system-data-files=/usr/share/mesa-demos

+ arch-meson mesa-demos-$pkgver build \
+ -D gles1=disabled \
+ -D with-system-data-files=true

It's trying to open a broken path "share/mesa-demostile.rgb" instead of "/usr/share/mesa-demos/tile.rgb"

$ /usr/bin/tunnel -h
Tunnel V1.5
Written by David Bucciarelli (tech.hmw@plus.it)
share/mesa-demostile.rgb: No such file or directory
File not found
Error reading a texture.
This task depends upon

Closed by  Andreas Radke (AndyRTR)
Thursday, 16 June 2022, 17:51 GMT
Reason for closing:  Fixed
Comment by Andreas Radke (AndyRTR) - Wednesday, 15 June 2022, 05:57 GMT
The new meson build system currently doesn't allow to pass the path:

meson configure build

with-system-data-files true [true, false] with-system-data-files

I guess this needs to be added upstream. Please file an issue there:
https://gitlab.freedesktop.org/mesa/demos/-/issues
Comment by Natrio (natrio) - Wednesday, 15 June 2022, 17:39 GMT
Issue:
https://gitlab.freedesktop.org/mesa/demos/-/issues/26
Replacing the string
demos_data_dir = get_option('datadir') / 'mesa-demos'
to
demos_data_dir = get_option('prefix') / get_option('datadir') / 'mesa-demos' / ''
in "meson.build" file works for me and I was proposed it in that issue.
Comment by Natrio (natrio) - Thursday, 16 June 2022, 11:39 GMT
In order not to wait for the upstream reaction for two to four weeks, I offer a ready-made patch
Comment by Andreas Radke (AndyRTR) - Thursday, 16 June 2022, 15:21 GMT
Thanks for the patch - please try 8.5.0-2 in testing repo.
Comment by Natrio (natrio) - Thursday, 16 June 2022, 15:58 GMT
Thank you, it works!

Texture files are loaded successfully:
$ pacman -Q mesa-demos
mesa-demos 8.5.0-2
$ pacman -Ql mesa-demos | grep textures
mesa-demos /usr/bin/textures
$ /usr/bin/textures
Loaded /usr/share/mesa-demos/arch.rgb
Loaded /usr/share/mesa-demos/reflect.rgb
Loaded /usr/share/mesa-demos/tree2.rgba
Loaded /usr/share/mesa-demos/tile.rgb
...

Loading...