diff options
Diffstat (limited to 'debian/patches/changes-to-generation-of-pytsk3.c-for-re.patch')
-rw-r--r-- | debian/patches/changes-to-generation-of-pytsk3.c-for-re.patch | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/debian/patches/changes-to-generation-of-pytsk3.c-for-re.patch b/debian/patches/changes-to-generation-of-pytsk3.c-for-re.patch new file mode 100644 index 0000000..e74d7a3 --- /dev/null +++ b/debian/patches/changes-to-generation-of-pytsk3.c-for-re.patch @@ -0,0 +1,27 @@ +From: Chris Lamb <chris@chris-lamb.co.uk> +Date: Tue, 10 Aug 2021 11:57:34 +0100 +X-Dgit-Generated: 20200117-3.1 986f3e5bd0dd74f93dca15637e2c1242c6546d76 +Subject: Changes to generation of pytsk3.c for reproducible build + +(Closes: #992060) + +Merged upstream as +https://github.com/py4n6/pytsk/commit/f2b9ffa642a83127eb0e517a1f0ed4a22a99199a +in pull request https://github.com/py4n6/pytsk/pull/81 + +--- + +--- pytsk-20200117.orig/class_parser.py ++++ pytsk-20200117/class_parser.py +@@ -913,8 +913,9 @@ uint64_t integer_object_copy_to_uint64(P + for class_name in self.classes.keys(): + self.initialise_class(class_name, out, done) + +- # Add the constants in here +- for constant, type in self.constants: ++ # Add the constants here. Make sure they are sorted so builds ++ # of pytsk3.c are reproducible. ++ for constant, type in sorted(self.constants): + if type == "integer": + out.write( + " tmp = PyLong_FromUnsignedLongLong((uint64_t) {0:s});\n".format(constant)) |