summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2021-11-22 13:11:12 -0800
committerGuido van Rossum <guido@python.org>2021-11-22 13:18:02 -0800
commit4463a96da33e165b9f64afcaca6d04da5c8b5c40 (patch)
treede0e32eaba95b4969e75c26a900e3ac6ab404a11
parentdf1901ed254edf2f4c7c1164d00d9a9120f95960 (diff)
downloadcpython-git-unixdeepfreeze.tar.gz
Get rid of the MANIFEST fileunixdeepfreeze
-rw-r--r--Tools/scripts/freeze_modules.py43
1 files changed, 0 insertions, 43 deletions
diff --git a/Tools/scripts/freeze_modules.py b/Tools/scripts/freeze_modules.py
index 59bc50af1d..6614a2518f 100644
--- a/Tools/scripts/freeze_modules.py
+++ b/Tools/scripts/freeze_modules.py
@@ -25,7 +25,6 @@ STDLIB_DIR = os.path.join(ROOT_DIR, 'Lib')
# need to be updated.
MODULES_DIR = os.path.join(ROOT_DIR, 'Python', 'frozen_modules')
-MANIFEST = os.path.join(MODULES_DIR, 'MANIFEST')
FROZEN_FILE = os.path.join(ROOT_DIR, 'Python', 'frozen.c')
MAKEFILE = os.path.join(ROOT_DIR, 'Makefile.pre.in')
PCBUILD_PROJECT = os.path.join(ROOT_DIR, 'PCbuild', '_freeze_module.vcxproj')
@@ -456,45 +455,6 @@ def replace_block(lines, start_marker, end_marker, replacements, file):
return lines[:start_pos + 1] + replacements + lines[end_pos:]
-def regen_manifest(modules):
- header = 'module ispkg source frozen checksum'.split()
- widths = [5] * len(header)
- rows = []
- for mod in modules:
- info = mod.summarize()
- row = []
- for i, col in enumerate(header):
- value = info[col]
- if col == 'checksum':
- value = value[:12]
- elif col == 'ispkg':
- value = 'YES' if value else 'no'
- widths[i] = max(widths[i], len(value))
- row.append(value or '-')
- rows.append(row)
-
- modlines = [
- '# The list of frozen modules with key information.',
- '# Note that the "check_generated_files" CI job will identify',
- '# when source files were changed but regen-frozen wasn\'t run.',
- '# This file is auto-generated by Tools/scripts/freeze_modules.py.',
- ' '.join(c.center(w) for c, w in zip(header, widths)).rstrip(),
- ' '.join('-' * w for w in widths),
- ]
- for row in rows:
- for i, w in enumerate(widths):
- if header[i] == 'ispkg':
- row[i] = row[i].center(w)
- else:
- row[i] = row[i].ljust(w)
- modlines.append(' '.join(row).rstrip())
-
- print(f'# Updating {os.path.relpath(MANIFEST)}')
- with open(MANIFEST, 'w', encoding="utf-8") as outfile:
- lines = (l + '\n' for l in modlines)
- outfile.writelines(lines)
-
-
def regen_frozen(modules):
headerlines = []
parentdir = os.path.dirname(FROZEN_FILE)
@@ -760,10 +720,7 @@ def main():
# Regen build-related files.
regen_makefile(modules)
regen_pcbuild(modules)
-
- # Regen files dependent of frozen file details.
regen_frozen(modules)
- regen_manifest(modules)
if __name__ == '__main__':