diffoscope: 52 -> 63
This commit is contained in:
parent
a2210a9efd
commit
ece67bfa01
@ -1,24 +1,30 @@
|
||||
{ lib, stdenv, fetchgit, fetchpatch, pythonPackages, docutils
|
||||
, acl, binutils, bzip2, cbfstool, cdrkit, colord, cpio, diffutils, e2fsprogs, file, fpc, gettext, ghc
|
||||
, gnupg1, gzip, jdk, libcaca, mono, pdftk, poppler_utils, sng, sqlite, squashfsTools, unzip, vim, xz
|
||||
, colordiff
|
||||
, enableBloat ? false
|
||||
}:
|
||||
|
||||
pythonPackages.buildPythonApplication rec {
|
||||
name = "diffoscope-${version}";
|
||||
version = "52";
|
||||
version = "63";
|
||||
|
||||
namePrefix = "";
|
||||
|
||||
src = fetchgit {
|
||||
url = "git://anonscm.debian.org/reproducible/diffoscope.git";
|
||||
rev = "refs/tags/${version}";
|
||||
sha256 = "18nqsd51rc0rldyxnjmzn86154asianhv415llhbxpr1a6zwqis6";
|
||||
sha256 = "018c0xcgf6pgq493dib29pfyqpj7vb93a6qfmdh790fpxa2j1zyd";
|
||||
};
|
||||
|
||||
patches =
|
||||
[ # Ignore different link counts.
|
||||
./ignore_links.patch
|
||||
|
||||
# Our Glibc doesn't have the C.UTF-8 locale yet
|
||||
# (https://sourceware.org/glibc/wiki/Proposals/C.UTF-8), so use
|
||||
# en_US.UTF-8 instead.
|
||||
./locale.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
@ -31,7 +37,7 @@ pythonPackages.buildPythonApplication rec {
|
||||
# FIXME: move xxd into a separate package so we don't have to pull in all of vim.
|
||||
propagatedBuildInputs = (with pythonPackages; [ debian libarchive-c python_magic tlsh rpm ]) ++
|
||||
map lib.getBin ([ acl binutils bzip2 cbfstool cdrkit cpio diffutils e2fsprogs file gettext
|
||||
gzip libcaca poppler_utils sng sqlite squashfsTools unzip vim xz
|
||||
gzip libcaca poppler_utils sng sqlite squashfsTools unzip vim xz colordiff
|
||||
] ++ lib.optionals enableBloat [ colord fpc ghc gnupg1 jdk mono pdftk ]);
|
||||
|
||||
doCheck = false; # Calls 'mknod' in squashfs tests, which needs root
|
||||
|
@ -1,21 +1,15 @@
|
||||
From: Eelco Dolstra <eelco.dolstra@logicblox.com>
|
||||
|
||||
Nix deduplicates by hard-linking identical files, so it's normal for
|
||||
the the number of links to a file to differ.
|
||||
---
|
||||
diff --git a/diffoscope/comparators/directory.py b/diffoscope/comparators/directory.py
|
||||
index 7d1cd75..bd91eb0 100644
|
||||
--- a/diffoscope/comparators/directory.py
|
||||
+++ b/diffoscope/comparators/directory.py
|
||||
@@ -47,6 +47,7 @@ class Stat(Command):
|
||||
diff -ru -x '*~' diffoscope-orig/diffoscope/comparators/directory.py diffoscope/diffoscope/comparators/directory.py
|
||||
--- diffoscope-orig/diffoscope/comparators/directory.py 1970-01-01 01:00:01.000000000 +0100
|
||||
+++ diffoscope/diffoscope/comparators/directory.py 2016-12-08 17:37:55.000315157 +0100
|
||||
@@ -49,6 +49,7 @@
|
||||
FILE_RE = re.compile(r'^\s*File:.*$')
|
||||
DEVICE_RE = re.compile(r'Device: [0-9a-f]+h/[0-9]+d')
|
||||
INODE_RE = re.compile(r'Inode: [0-9]+')
|
||||
+ LINKS_RE = re.compile(r'Links: [0-9]+')
|
||||
DEVICE_RE = re.compile(r'Device: [0-9a-f]+h/[0-9]+d\s+')
|
||||
INODE_RE = re.compile(r'Inode: [0-9]+\s+')
|
||||
+ LINKS_RE = re.compile(r'Links: [0-9]+\s+')
|
||||
ACCESS_TIME_RE = re.compile(r'^Access: [0-9]{4}-[0-9]{2}-[0-9]{2}.*$')
|
||||
CHANGE_TIME_RE = re.compile(r'^Change: [0-9]{4}-[0-9]{2}-[0-9]{2}.*$')
|
||||
|
||||
@@ -55,6 +56,7 @@ class Stat(Command):
|
||||
@@ -57,6 +58,7 @@
|
||||
line = Stat.FILE_RE.sub('', line)
|
||||
line = Stat.DEVICE_RE.sub('', line)
|
||||
line = Stat.INODE_RE.sub('', line)
|
||||
|
14
pkgs/tools/misc/diffoscope/locale.patch
Normal file
14
pkgs/tools/misc/diffoscope/locale.patch
Normal file
@ -0,0 +1,14 @@
|
||||
diff -ru -x '*~' diffoscope-orig/diffoscope/__init__.py diffoscope/diffoscope/__init__.py
|
||||
--- diffoscope-orig/diffoscope/__init__.py 1970-01-01 01:00:01.000000000 +0100
|
||||
+++ diffoscope/diffoscope/__init__.py 2016-12-08 17:48:51.732122110 +0100
|
||||
@@ -81,8 +81,8 @@
|
||||
for var in ['LANG', 'LC_NUMERIC', 'LC_TIME', 'LC_COLLATE', 'LC_MONETARY',
|
||||
'LC_MESSAGES', 'LC_PAPER', 'LC_NAME', 'LC_ADDRESS',
|
||||
'LC_TELEPHONE', 'LC_MEASUREMENT', 'LC_IDENTIFICATION']:
|
||||
- os.environ[var] = 'C'
|
||||
- os.environ['LC_CTYPE'] = 'C.UTF-8'
|
||||
+ os.environ[var] = 'en_US'
|
||||
+ os.environ['LC_CTYPE'] = 'en_US.UTF-8'
|
||||
os.environ['TZ'] = 'UTC'
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user