rusticl: fails to find X11 headers via pkg-config under non-default prefix
Regressed by df0623e5 (missing dep_x11
?). Affects FreeBSD, other BSDs and maybe even Nix due to using different prefix for each package. To reproduce install libX11 outside of /usr
and /usr/local
thus not part of default C compiler search path.
$ meson setup -Dvulkan-drivers= -Dgallium-drivers=iris -Dgallium-rusticl=true _build
$ meson compile -C _build
[...]
/path/to/mesa/include/./GL/glx.h:30:10: fatal error: 'X11/Xlib.h' file not found
panicked at main.rs:52:36:
Unable to generate bindings: ClangDiagnostic("/path/to/mesa/include/./GL/glx.h:30:10: fatal error: 'X11/Xlib.h' file not found\n")
$ pkg-config --cflags x11
-I/prefix/libX11/include -D_THREAD_SAFE
Tried workarounds:
-
-Dglvnd=true
doesn't help as rusticl still uses bundled<GL/glx.h>
-
-Dglx=disabled -Dxlib-lease=disabled
doesn't help as rusticl still uses GLX -
-I/prefix/libX11/include
doesn't help as rusticl ignoresCPPFLAGS
andCFLAGS
-
CPATH=/prefix/libX11/include
does help
Edited by Jan Beich