Commit 44cdbd34 authored by Skythrew's avatar Skythrew Committed by Maël GUERIN
Browse files

lutris: migrate to the new meson build system

This commit makes the Lutris package use the meson build system, which is more appropriate to build the desktop app.
Indeed, the meson build of Lutris is the only one supporting translations for the desktop app.
However, the presence of the Makefile at the source root is preventing the Nix build system from building the package with meson without overriding the different build phases.
parent 0f36a1ad
Loading
Loading
Loading
Loading
+17 −15
Original line number Diff line number Diff line
@@ -6,6 +6,7 @@
  # build inputs
  atk,
  file,
  glib,
  gdk-pixbuf,
  glib-networking,
  gnome-desktop,
@@ -16,6 +17,8 @@
  pango,
  webkitgtk_4_1,
  wrapGAppsHook3,
  meson,
  ninja,

  # check inputs
  xvfb-run,
@@ -45,11 +48,15 @@
  pulseaudio,
  p7zip,
  xgamma,
  gettext,
  libstrangle,
  fluidsynth,
  xorgserver,
  xorg,
  util-linux,
  pkg-config,
  desktop-file-utils,
  appstream-glib,
}:

let
@@ -83,9 +90,18 @@ buildPythonApplication rec {
    hash = "sha256-CAXKnx5+60MITRM8enkYgFl5ZKM6HCXhCYNyG7kHhuQ=";
  };

  format = "other";

  nativeBuildInputs = [
    wrapGAppsHook3
    appstream-glib
    desktop-file-utils
    gettext
    glib
    gobject-introspection
    meson
    ninja
    wrapGAppsHook3
    pkg-config
  ];
  buildInputs =
    [
@@ -128,20 +144,6 @@ buildPythonApplication rec {
      --replace '"libmagic.so.1"' "'${lib.getLib file}/lib/libmagic.so.1'"
  '';

  nativeCheckInputs = [
    xvfb-run
    nose2
    flake8
  ] ++ requiredTools;
  checkPhase = ''
    runHook preCheck

    export HOME=$PWD
    xvfb-run -s '-screen 0 800x600x24' make test

    runHook postCheck
  '';

  # avoid double wrapping
  dontWrapGApps = true;
  makeWrapperArgs = [
+3 −1
Original line number Diff line number Diff line
@@ -13207,7 +13207,9 @@ with pkgs;
  luddite = with python3Packages; toPythonApplication luddite;
  lutris-unwrapped = python3.pkgs.callPackage ../applications/misc/lutris { };
  lutris-unwrapped = python3.pkgs.callPackage ../applications/misc/lutris {
    inherit (pkgs) meson;
  };
  lutris = callPackage ../applications/misc/lutris/fhsenv.nix { };
  lutris-free = lutris.override {
    steamSupport = false;