git.iko.soy/typeable/nixpkgs
on master help sign in
rmlint: fix build without patch
commite7ad1fb97770cee7189e86e3e40ae39afbac162a authorJörg Thalheim <joerg@thalheim.io> dateSun 23 Dec 2018, 22:41 (8 years ago) parent3b2506b
2 files changed+9−24
pkgs/tools/misc/rmlint/blkid-hack.patch−18 pkgs/tools/misc/rmlint/default.nix+9−6
pkgs/tools/misc/rmlint/blkid-hack.patchdeleted−18
@@ -1,18 +0,0 @@
1−# HACK: For some reason the file blkid/blkid.h is not found during build.
2−# I assueme it is due to the fact that -I [...]util-linux-2.33-dev/include/blkid
3−# is added during the build and not just -I [...]util-linux-2.33-dev/include
4−# For the time being this patch is the only way I could find to fix the build.
5−
6−diff --git a/lib/utilities.c b/lib/utilities.c
7−index e768fa41..1f96fd68 100644
8−--- a/lib/utilities.c
9−+++ b/lib/utilities.c
10−@@ -76,7 +76,7 @@
11− #endif
12−
13− #if HAVE_BLKID
14−-#include <blkid/blkid.h>
15−+#include <blkid.h>
16− #endif
17−
18− #if HAVE_JSON_GLIB
pkgs/tools/misc/rmlint/default.nix+9−6
@@ -1,5 +1,6 @@
1−{ stdenv, fetchFromGitHub,
2− gettext, glib, json-glib, libelf, pkgconfig, scons, sphinx, utillinux }:
1+{ stdenv, fetchFromGitHub
2+, gettext, pkgconfig, scons
3+, glib, json-glib, libelf, sphinx, utillinux }:
34
45with stdenv.lib;
56stdenv.mkDerivation rec {
@@ -13,13 +14,15 @@ stdenv.mkDerivation rec {
1314 sha256 = "1gc7gbnh0qg1kl151cv1ld87vhpm1v3pnkn7prhscdcc21jrg8nz";
1415 };
1516
17+ CFLAGS="-I${stdenv.lib.getDev utillinux}/include";
1618
17− patches = [
18− ./blkid-hack.patch
19+ nativeBuildInputs = [
20+ pkgconfig sphinx gettext scons
1921 ];
2022
21− nativeBuildInputs = [ pkgconfig sphinx ];
22− buildInputs = [ gettext glib json-glib libelf scons utillinux ];
23+ buildInputs = [
24+ glib json-glib libelf utillinux
25+ ];
2326
2427 prefixKey = "--prefix=";
2528