From 165cf8d6e32528a8f655589419b2263096bfd697 Mon Sep 17 00:00:00 2001 From: ChUrl Date: Sun, 16 Apr 2023 16:53:02 +0200 Subject: [PATCH] Add some buildinputs to dell driver --- derivations/dell-b1160w/default.nix | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/derivations/dell-b1160w/default.nix b/derivations/dell-b1160w/default.nix index dc697844..281f1b61 100644 --- a/derivations/dell-b1160w/default.nix +++ b/derivations/dell-b1160w/default.nix @@ -3,6 +3,8 @@ stdenv, fetchurl, autoPatchelfHook, + cups, + libusb1 }: stdenv.mkDerivation rec { pname = "B1160_B1160w_UnifiedLinuxDriver"; @@ -11,19 +13,23 @@ stdenv.mkDerivation rec { src = fetchurl { url = "https://dl.dell.com/FOLDER00947576M/1/${pname}_${version}.tar.gz"; sha256 = "10b75a899ba7aff3b95158f6fc49f09d6eef670608480ee48c179337c5337375"; + curlOptsList = ["--user-agent" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:89.0) Gecko/20100101 Firefox/89.0"]; }; # https://nixos.org/manual/nixpkgs/unstable/#setup-hook-autopatchelfhook # https://nixos.wiki/wiki/Packaging/Binaries # https://unix.stackexchange.com/questions/522822/different-methods-to-run-a-non-nixos-executable-on-nixos/522823#522823 + # TODO: This step does not work nativeBuildInputs = [ - # dpkg + cups + stdenv.cc.cc.lib + libusb1 autoPatchelfHook ]; unpackCmd = '' mkdir -p root - tar xvf ${pname}_${version}.tar.gz --directory=root + tar xvf $curSrc --directory=root ''; # This is already built @@ -39,7 +45,7 @@ stdenv.mkDerivation rec { mkdir -p $out/sbin cp -r cdroot/Linux/x86_64/at_root/usr/sbin/* $out/sbin/ - cp -r cdroot/Linux/x86_64/at_root/usr/lib64/*.so $out/lib64/ + cp -r cdroot/Linux/x86_64/at_root/usr/lib64/*.so.* $out/lib64/ cp -r cdroot/Linux/x86_64/at_root/usr/lib64/cups/* $out/cups/ cp -r cdroot/Linux/x86_64/at_root/opt/smfp-common/lib/* $out/lib/ @@ -50,7 +56,7 @@ stdenv.mkDerivation rec { description = "CUPS driver for the Dell B1160w printer."; longDescription = "CUPS driver for the Dell B1160w printer."; homepage = "https://www.dell.com/support/home/de-de/drivers/driversdetails?driverid=1m4pc"; - license = licenses.nonfree; + license = licenses.unfree; platforms = ["x86_64-linux"]; }; }