Bug 271930 - graphics/mesa-dri: i915_dri.so not installed
Summary: graphics/mesa-dri: i915_dri.so not installed
Status: Closed DUPLICATE of bug 269006
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Some People
Assignee: freebsd-x11 (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-06-09 23:09 UTC by Friedrich Volkmann
Modified: 2023-06-10 05:42 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (x11)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Friedrich Volkmann 2023-06-09 23:09:44 UTC
mesa-dri should install /usr/local/lib/dri/i915_dri.so but it doesn't.
This file is needed by libglvnd (OpenGL) which in turn is used by numerous applications.
When it's missing, they emit a barrage of error messages:

$ telegram-desktop 

(telegram-desktop:40602): Telegram-WARNING **: 22:54:23.721: Application was built without embedded fonts, this may lead to font issues.
libGL error: MESA-LOADER: failed to retrieve device information
libGL error: MESA-LOADER: failed to open i915: Cannot open "/usr/local/lib/dri/i915_dri.so" (search paths /usr/local/lib/dri, suffix _dri)
libGL error: failed to load driver: i915
error: : cannot open
error: : cannot open
error: : cannot open
...

When something goes wrong later on, the fault is given to the "broken libGL" no matter what, see: https://github.com/telegramdesktop/tdesktop/issues/26387

As recently discussed in https://forums.freebsd.org/threads/mesa-missing-i915-driver.88338/ the mesa-dri port contains everything to build the crucial i915_dri.so, but the port is not set up to install them. I tried to get it there e.g. by adding "INTEL" to the ALL_GALLIUM_DRIVERS=... line, but then I get an error:
meson.build:1704:6: ERROR: Dependency "libdrm_nouveau" not found, tried pkgconfig and cmake

Knowing nothing about meson or drivers, I am unable to fix this myself. The compiled file provided in the aforementioned discussion doesn't work for me, probably because it was built on i386 whereas my FreeBSD is amd64. Also, my FreeBSD version is 12.4-STABLE, while theirs is 13.

Please can you get the port to compile and install the file.
Comment 1 Jan Beich freebsd_committer freebsd_triage 2023-06-10 01:46:50 UTC
Regressed by ports 23e4dce35c4a. Try the patch in bug 269006 but the driver is different from before: gallium instead of classic.

*** This bug has been marked as a duplicate of bug 269006 ***
Comment 2 Friedrich Volkmann 2023-06-10 05:42:29 UTC
Thanks. That didn't resolve the entire problem, but the subject of this bug report, as the file is no longer missing. New output:

$ telegram-desktop 

(telegram-desktop:56841): Telegram-WARNING **: 07:13:09.785: Application was built without embedded fonts, this may lead to font issues.
libGL error: MESA-LOADER: failed to retrieve device information
MESA-LOADER: failed to retrieve device information
MESA-LOADER: failed to retrieve device information
libGL error: glx: failed to create dri2 screen
libGL error: failed to load driver: i915
error: : cannot open
error: : cannot open
error: : cannot open
...