2024-06-11 11:54:18 +00:00
|
|
|
# The Darwin build of Mesa is different enough that we just give it an entire separate expression.
|
|
|
|
{
|
|
|
|
lib,
|
|
|
|
stdenv,
|
|
|
|
fetchurl,
|
|
|
|
bison,
|
|
|
|
flex,
|
|
|
|
meson,
|
|
|
|
ninja,
|
|
|
|
pkg-config,
|
|
|
|
python3Packages,
|
|
|
|
Xplugin,
|
|
|
|
xorg,
|
|
|
|
zlib,
|
|
|
|
}:
|
|
|
|
let
|
|
|
|
common = import ./common.nix { inherit lib fetchurl; };
|
|
|
|
in stdenv.mkDerivation {
|
|
|
|
inherit (common) pname version src meta;
|
|
|
|
|
|
|
|
outputs = [ "out" "dev" ];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
bison
|
|
|
|
flex
|
|
|
|
meson
|
|
|
|
ninja
|
|
|
|
pkg-config
|
2024-07-01 09:33:16 +00:00
|
|
|
python3Packages.packaging
|
2024-06-11 11:54:18 +00:00
|
|
|
python3Packages.python
|
|
|
|
python3Packages.mako
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
Xplugin
|
|
|
|
xorg.libX11
|
|
|
|
xorg.libXext
|
|
|
|
xorg.libXfixes
|
|
|
|
zlib
|
|
|
|
];
|
|
|
|
|
|
|
|
mesonAutoFeatures = "disabled";
|
|
|
|
|
|
|
|
mesonFlags = [
|
|
|
|
"--sysconfdir=/etc"
|
|
|
|
"--datadir=${placeholder "out"}/share"
|
|
|
|
(lib.mesonEnable "glvnd" false)
|
|
|
|
(lib.mesonEnable "shared-glapi" true)
|
|
|
|
];
|
2024-06-15 06:22:51 +00:00
|
|
|
|
|
|
|
# Don't need this on Darwin.
|
|
|
|
passthru.llvmpipeHook = null;
|
2024-06-11 11:54:18 +00:00
|
|
|
}
|