From 4c77d471e40ae1b1581cdbc33fb8fae00e6fd0b7 Mon Sep 17 00:00:00 2001 From: Cole Mickens Date: Sat, 16 Mar 2019 16:56:49 -0700 Subject: [PATCH] libdrm: build with meson --- pkgs/development/libraries/libdrm/default.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/pkgs/development/libraries/libdrm/default.nix b/pkgs/development/libraries/libdrm/default.nix index 7415aa754e7d..4ed3ad356a9f 100644 --- a/pkgs/development/libraries/libdrm/default.nix +++ b/pkgs/development/libraries/libdrm/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, pkgconfig, libpthreadstubs, libpciaccess, valgrind-light }: +{ stdenv, fetchurl, pkgconfig, meson, ninja, libpthreadstubs, libpciaccess, valgrind-light }: stdenv.mkDerivation rec { name = "libdrm-2.4.98"; @@ -10,9 +10,8 @@ stdenv.mkDerivation rec { outputs = [ "out" "dev" "bin" ]; - nativeBuildInputs = [ pkgconfig ]; + nativeBuildInputs = [ pkgconfig meson ninja ]; buildInputs = [ libpthreadstubs libpciaccess valgrind-light ]; - # libdrm as of 2.4.70 does not actually do anything with udev. postPatch = '' for a in */*-symbol-check ; do @@ -20,13 +19,15 @@ stdenv.mkDerivation rec { done ''; - configureFlags = [ "--enable-install-test-programs" ] + mesonFlags = + [ "-Dinstall-test-programs=true" ] ++ stdenv.lib.optionals (stdenv.isAarch32 || stdenv.isAarch64) - [ "--enable-tegra-experimental-api" "--enable-etnaviv-experimental-api" ] - ++ stdenv.lib.optional stdenv.isDarwin "-C" - ++ stdenv.lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) "--disable-intel" + [ "-Dtegra=true" "-Detnaviv=true" ] + ++ stdenv.lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) "-Dintel=false" ; + enableParallelBuilding = true; + meta = { homepage = https://dri.freedesktop.org/libdrm/; description = "Library for accessing the kernel's Direct Rendering Manager";