forked from mirrors/nixpkgs
mesa: update to 10.0.1, always enable R600
A few TODOs are pending, but of relatively low importance.
This commit is contained in:
parent
2e4eab1228
commit
8f0656c2f7
|
@ -1,9 +1,8 @@
|
|||
{ stdenv, fetchurl, pkgconfig, intltool, flex, bison, autoconf, automake, libtool
|
||||
{ stdenv, fetchurl, pkgconfig, intltool, flex, bison, autoreconfHook
|
||||
, python, libxml2Python, file, expat, makedepend
|
||||
, libdrm, xorg, wayland, udev, llvm, libffi
|
||||
, libvdpau
|
||||
, libvdpau, libelf
|
||||
, enableTextureFloats ? false # Texture floats are patented, see docs/patents.txt
|
||||
, enableR600LlvmCompiler ? true, libelf
|
||||
, enableExtraFeatures ? false # not maintained
|
||||
}:
|
||||
|
||||
|
@ -24,8 +23,8 @@ else
|
|||
*/
|
||||
|
||||
let
|
||||
version = "9.2.5";
|
||||
# this is the default search path for DRI drivers (note: X server introduces an overriding env var)
|
||||
version = "10.0.1";
|
||||
# this is the default search path for DRI drivers
|
||||
driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32";
|
||||
in
|
||||
with { inherit (stdenv.lib) optional optionals optionalString; };
|
||||
|
@ -35,15 +34,15 @@ stdenv.mkDerivation {
|
|||
|
||||
src = fetchurl {
|
||||
url = "ftp://ftp.freedesktop.org/pub/mesa/${version}/MesaLib-${version}.tar.bz2";
|
||||
sha256 = "1w3bxclgwl2hwyxk3za7dbdakb8jsya7afck35cz0v8pxppvjsml";
|
||||
sha256 = "0w1jh8pl4gbzazigsqc5pzc076gckb7b9xgw2w633jlrjn7qdprw";
|
||||
};
|
||||
|
||||
prePatch = "patchShebangs .";
|
||||
|
||||
patches = [
|
||||
patches = [ # some don't apply -- try without them ATM
|
||||
./static-gallium.patch
|
||||
./dricore-gallium.patch
|
||||
./werror-wundef.patch
|
||||
# ./dricore-gallium.patch
|
||||
# ./werror-wundef.patch
|
||||
];
|
||||
|
||||
# Change the search path for EGL drivers from $drivers/* to driverLink
|
||||
|
@ -54,8 +53,6 @@ stdenv.mkDerivation {
|
|||
|
||||
outputs = ["out" "drivers" "osmesa"];
|
||||
|
||||
preConfigure = "./autogen.sh";
|
||||
|
||||
configureFlags = [
|
||||
"--with-dri-driverdir=$(drivers)/lib/dri"
|
||||
"--with-egl-driver-dir=$(drivers)/lib/egl"
|
||||
|
@ -72,11 +69,9 @@ stdenv.mkDerivation {
|
|||
"--enable-osmesa" # used by wine
|
||||
|
||||
"--with-dri-drivers=i965,r200,radeon"
|
||||
("--with-gallium-drivers=i915,nouveau,r300,r600,svga,swrast"
|
||||
+ optionalString enableR600LlvmCompiler ",radeonsi")
|
||||
("--with-gallium-drivers=i915,nouveau,r300,r600,svga,swrast,radeonsi")
|
||||
"--with-egl-platforms=x11,wayland,drm" "--enable-gbm" "--enable-shared-glapi"
|
||||
]
|
||||
++ optional enableR600LlvmCompiler "--enable-r600-llvm-compiler"
|
||||
++ optional enableTextureFloats "--enable-texture-float"
|
||||
++ optionals enableExtraFeatures [
|
||||
"--enable-openvg" "--enable-gallium-egl" # not needed for EGL in Gallium, but OpenVG might be useful
|
||||
|
@ -90,17 +85,16 @@ stdenv.mkDerivation {
|
|||
++ optionals stdenv.isLinux [libdrm]
|
||||
;
|
||||
buildInputs = with xorg; [
|
||||
autoconf automake libtool intltool expat libxml2Python llvm
|
||||
autoreconfHook intltool expat libxml2Python llvm
|
||||
libXfixes glproto dri2proto libX11 libXext libxcb libXt
|
||||
libffi wayland libvdpau
|
||||
libffi wayland libvdpau libelf
|
||||
] ++ optionals enableExtraFeatures [ /*libXvMC*/ ]
|
||||
++ optional stdenv.isLinux udev
|
||||
++ optional enableR600LlvmCompiler libelf
|
||||
;
|
||||
|
||||
enableParallelBuilding = true;
|
||||
#doCheck = true; # https://bugs.freedesktop.org/show_bug.cgi?id=67672
|
||||
# TODO: best fix this before merging >=9.2 to master
|
||||
#doCheck = true; # https://bugs.freedesktop.org/show_bug.cgi?id=67672,
|
||||
#tests for 10.* fail to link due to some RTTI problem
|
||||
|
||||
# move gallium-related stuff to $drivers, so $out doesn't depend on LLVM;
|
||||
# also move libOSMesa to $osmesa, as it's relatively big
|
||||
|
|
Loading…
Reference in a new issue