mesa: Fix cross build
This commit is contained in:
parent
f005272623
commit
62e6d73a09
@ -1,4 +1,4 @@
|
|||||||
{ stdenv, lib, fetchurl, fetchpatch
|
{ stdenv, lib, fetchurl, fetchpatch, buildPackages
|
||||||
, pkgconfig, intltool, ninja, meson
|
, pkgconfig, intltool, ninja, meson
|
||||||
, file, flex, bison, expat, libdrm, xorg, wayland, wayland-protocols, openssl
|
, file, flex, bison, expat, libdrm, xorg, wayland, wayland-protocols, openssl
|
||||||
, llvmPackages, libffi, libomxil-bellagio, libva-minimal
|
, llvmPackages, libffi, libomxil-bellagio, libva-minimal
|
||||||
@ -73,6 +73,12 @@ stdenv.mkDerivation {
|
|||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
|
||||||
|
postPatch = ''
|
||||||
|
substituteInPlace meson.build --replace \
|
||||||
|
"find_program('pkg-config')" \
|
||||||
|
"find_program('${buildPackages.pkg-config.targetPrefix}pkg-config')"
|
||||||
|
'';
|
||||||
|
|
||||||
outputs = [ "out" "dev" "drivers" "osmesa" ];
|
outputs = [ "out" "dev" "drivers" "osmesa" ];
|
||||||
|
|
||||||
# TODO: Figure out how to enable opencl without having a runtime dependency on clang
|
# TODO: Figure out how to enable opencl without having a runtime dependency on clang
|
||||||
@ -112,10 +118,14 @@ stdenv.mkDerivation {
|
|||||||
++ lib.optionals stdenv.isLinux [ libomxil-bellagio libva-minimal ]
|
++ lib.optionals stdenv.isLinux [ libomxil-bellagio libva-minimal ]
|
||||||
++ lib.optional withValgrind valgrind-light;
|
++ lib.optional withValgrind valgrind-light;
|
||||||
|
|
||||||
|
depsBuildBuild = [ pkgconfig ];
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
pkgconfig meson ninja
|
pkgconfig meson ninja
|
||||||
intltool bison flex file
|
intltool bison flex file
|
||||||
python3Packages.python python3Packages.Mako
|
python3Packages.python python3Packages.Mako
|
||||||
|
] ++ lib.optionals (elem "wayland" eglPlatforms) [
|
||||||
|
wayland # For wayland-scanner during the build
|
||||||
];
|
];
|
||||||
|
|
||||||
propagatedBuildInputs = with xorg; [
|
propagatedBuildInputs = with xorg; [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user