uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
34
pkgs/os-specific/linux/usbip/default.nix
Normal file
34
pkgs/os-specific/linux/usbip/default.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{ lib, stdenv, fetchpatch, kernel, udev, autoconf, automake, libtool, hwdata, kernelOlder }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "usbip-${kernel.name}";
|
||||
|
||||
src = kernel.src;
|
||||
|
||||
patches = lib.optionals (kernelOlder "5.4") [
|
||||
# fixes build with gcc8
|
||||
./fix-snprintf-truncation.patch
|
||||
# fixes build with gcc9
|
||||
./fix-strncpy-truncation.patch
|
||||
] ++ kernel.patches;
|
||||
|
||||
nativeBuildInputs = [ autoconf automake libtool ];
|
||||
buildInputs = [ udev ];
|
||||
|
||||
NIX_CFLAGS_COMPILE = [ "-Wno-error=address-of-packed-member" ];
|
||||
|
||||
preConfigure = ''
|
||||
cd tools/usb/usbip
|
||||
./autogen.sh
|
||||
'';
|
||||
|
||||
configureFlags = [ "--with-usbids-dir=${hwdata}/share/hwdata/" ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/torvalds/linux/tree/master/tools/usb/usbip";
|
||||
description = "allows to pass USB device from server to client over the network";
|
||||
license = with licenses; [ gpl2Only gpl2Plus ];
|
||||
platforms = platforms.linux;
|
||||
broken = kernelOlder "4.10";
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue