summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Lagerwall <rosslagerwall@gmail.com>2012-03-11 17:21:07 (GMT)
committerRoss Lagerwall <rosslagerwall@gmail.com>2012-03-11 17:21:07 (GMT)
commit6c52c5755fb63e50364f66fd98b8096c236ae633 (patch)
tree3ea4dbc46e7a4c2304b1d34a6abe950d51c3f2e9
parentb4a92376f86f1a4fefac22230864d9e11f8e405f (diff)
downloadcpython-6c52c5755fb63e50364f66fd98b8096c236ae633.zip
cpython-6c52c5755fb63e50364f66fd98b8096c236ae633.tar.gz
cpython-6c52c5755fb63e50364f66fd98b8096c236ae633.tar.bz2
Modify patchcheck.py to check for changes to configure.in.
It now reports if configure and pyconfig.h.in weren't regenerated but configure.in was changed.
-rwxr-xr-xTools/scripts/patchcheck.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/Tools/scripts/patchcheck.py b/Tools/scripts/patchcheck.py
index 380574a..0ca712a 100755
--- a/Tools/scripts/patchcheck.py
+++ b/Tools/scripts/patchcheck.py
@@ -132,6 +132,21 @@ def reported_news(file_paths):
"""Check if Misc/NEWS has been changed."""
return 'Misc/NEWS' in file_paths
+@status("configure regenerated", modal=True, info=str)
+def regenerated_configure(file_paths):
+ """Check if configure has been regenerated."""
+ if 'configure.in' in file_paths:
+ return "yes" if 'configure' in file_paths else "no"
+ else:
+ return "not needed"
+
+@status("pyconfig.h.in regenerated", modal=True, info=str)
+def regenerated_pyconfig_h_in(file_paths):
+ """Check if pyconfig.h.in has been regenerated."""
+ if 'configure.in' in file_paths:
+ return "yes" if 'pyconfig.h.in' in file_paths else "no"
+ else:
+ return "not needed"
def main():
file_paths = changed_files()
@@ -151,6 +166,10 @@ def main():
credit_given(special_files)
# Misc/NEWS changed.
reported_news(special_files)
+ # Regenerated configure, if necessary.
+ regenerated_configure(file_paths)
+ # Regenerated pyconfig.h.in, if necessary.
+ regenerated_pyconfig_h_in(file_paths)
# Test suite run and passed.
if python_files or c_files: