mirror of
https://github.com/fosslinux/live-bootstrap.git
synced 2026-03-04 10:25:25 +01:00
Ever since an old patch version, it has (for reasonable security reasons) not supported patched with ../ in the filename. Many of our patches have been relying on this behaviour being OK, because we start off with an ancient patch version that didn't perform such checks. As soon as we need this behaviour after we build a newer patch though, we will have problems. So, let's change the policy. Patches are relative to where tarballs are extracted, rather than the "working directory" - e.g. have patches for `coreutils-9.4/src/cp.c` instead of `src/cp.c`. Keeping this consistent has a few implications; - patches are applied from the build/ directory in bash era now, with `-p0` - when patches are manually applied in the bash era, use `-p` as required, usually `-p1` - in kaem era where patches are always manually applied, `-p1` is used
26 lines
915 B
Diff
26 lines
915 B
Diff
SPDX-FileCopyrightText: 2022 fosslinux <fosslinux@aussies.space>
|
|
|
|
SPDX-License-Identifier: PSF-2.0
|
|
|
|
I'm not sure what was going on here when this was written, or how
|
|
it ever worked! But this small simple fix works 0.0
|
|
|
|
--- Python-3.8.16/Lib/sre_constants.py 2022-12-20 18:30:21.883561534 +1100
|
|
+++ Python-3.8.16/Lib/sre_constants.py 2022-12-20 18:31:23.209190748 +1100
|
|
@@ -56,6 +56,7 @@
|
|
class _NamedIntConstant(int):
|
|
def __new__(cls, value, name):
|
|
self = super(_NamedIntConstant, cls).__new__(cls, value)
|
|
+ self.value = value
|
|
self.name = name
|
|
return self
|
|
|
|
@@ -219,7 +220,7 @@
|
|
def dump(f, d, prefix):
|
|
items = sorted(d)
|
|
for item in items:
|
|
- f.write("#define %s_%s %d\n" % (prefix, item, item))
|
|
+ f.write("#define %s_%s %d\n" % (prefix, item.name, item.value))
|
|
with open("sre_constants.h", "w") as f:
|
|
f.write("""\
|
|
/*
|