From b6fce7201ed29e601b0f7e4fd2f1fd0ce4faf042 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 14 Nov 2018 13:57:41 -0600 Subject: [PATCH] xboxdrv: add dontUseSconsInstall flag MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit xboxdrv doesn’t use scons for installing, but instead using a makefile! Everything else is in scons so we have to keep that. I’ve added a dontUseSconsInstall flag to the scons setup-hook to skip the automatic overwrite of default “make install” call. --- pkgs/development/tools/build-managers/scons/setup-hook.sh | 2 +- pkgs/misc/drivers/xboxdrv/default.nix | 8 +++----- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/development/tools/build-managers/scons/setup-hook.sh b/pkgs/development/tools/build-managers/scons/setup-hook.sh index bb5591c4620..55159aa5a93 100644 --- a/pkgs/development/tools/build-managers/scons/setup-hook.sh +++ b/pkgs/development/tools/build-managers/scons/setup-hook.sh @@ -75,7 +75,7 @@ if [ -z "$buildPhase" ]; then buildPhase=sconsBuildPhase fi -if [ -z "$installPhase" ]; then +if [ -z "$dontUseSconsInstall" -a -z "$installPhase" ]; then installPhase=sconsInstallPhase fi diff --git a/pkgs/misc/drivers/xboxdrv/default.nix b/pkgs/misc/drivers/xboxdrv/default.nix index 3cc7869eb0a..c942ec59f37 100644 --- a/pkgs/misc/drivers/xboxdrv/default.nix +++ b/pkgs/misc/drivers/xboxdrv/default.nix @@ -11,12 +11,10 @@ in stdenv.mkDerivation { sha256 = "0jx2wqmc7602dxyj19n3h8x0cpy929h7c0h39vcc5rf0q74fh3id"; }; - patchPhase = '' - substituteInPlace Makefile --replace /usr/local "$out" - ''; - + makeFlags = "PREFIX=$(out)"; nativeBuildInputs = [ pkgconfig ]; - buildInputs = [ scons libX11 libusb1 boost glib dbus-glib]; + buildInputs = [ scons libX11 libusb1 boost glib dbus-glib ]; + dontUseSconsInstall = true; meta = with stdenv.lib; { homepage = https://pingus.seul.org/~grumbel/xboxdrv/;