bpo-30638: Add clinic to `make regen-all` (GH-5671)

Also, use PYTHON_FOR_REGEN for clinic and blake2s_impl.c rather than PYTHON_FOR_BUILD, and update .travis.yml to make use of the change.
This commit is contained in:
Zachary Ware 2018-02-17 17:58:57 -06:00 committed by GitHub
parent 17ab8f0e8e
commit d6ff8a7037
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 9 deletions

View File

@ -111,8 +111,7 @@ before_script:
fi fi
openssl version openssl version
./configure --with-pydebug ./configure --with-pydebug
make -j4 make -j4 regen-all
make -j4 regen-all clinic
changes=`git status --porcelain` changes=`git status --porcelain`
if ! test -z "$changes" if ! test -z "$changes"
then then
@ -120,6 +119,7 @@ before_script:
echo "$changes" echo "$changes"
exit 1 exit 1
fi fi
make -j4
make pythoninfo make pythoninfo
script: script:

View File

@ -560,10 +560,9 @@ coverage-report: regen-grammar regen-importlib
$(MAKE) coverage-lcov $(MAKE) coverage-lcov
# Run "Argument Clinic" over all source files # Run "Argument Clinic" over all source files
# (depends on python having already been built)
.PHONY=clinic .PHONY=clinic
clinic: check-clean-src $(BUILDPYTHON) $(srcdir)/Modules/_blake2/blake2s_impl.c clinic: check-clean-src $(srcdir)/Modules/_blake2/blake2s_impl.c
$(RUNSHARED) $(PYTHON_FOR_BUILD) $(srcdir)/Tools/clinic/clinic.py --make --srcdir $(srcdir) $(PYTHON_FOR_REGEN) $(srcdir)/Tools/clinic/clinic.py --make --srcdir $(srcdir)
# Build the interpreter # Build the interpreter
$(BUILDPYTHON): Programs/python.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY) $(BUILDPYTHON): Programs/python.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY)
@ -593,9 +592,9 @@ Modules/_math.o: Modules/_math.c Modules/_math.h
$(CC) -c $(CCSHARED) $(PY_CORE_CFLAGS) -o $@ $< $(CC) -c $(CCSHARED) $(PY_CORE_CFLAGS) -o $@ $<
# blake2s is auto-generated from blake2b # blake2s is auto-generated from blake2b
$(srcdir)/Modules/_blake2/blake2s_impl.c: $(BUILDPYTHON) $(srcdir)/Modules/_blake2/blake2b_impl.c $(srcdir)/Modules/_blake2/blake2b2s.py $(srcdir)/Modules/_blake2/blake2s_impl.c: $(srcdir)/Modules/_blake2/blake2b_impl.c $(srcdir)/Modules/_blake2/blake2b2s.py
$(RUNSHARED) $(PYTHON_FOR_BUILD) $(srcdir)/Modules/_blake2/blake2b2s.py $(PYTHON_FOR_REGEN) $(srcdir)/Modules/_blake2/blake2b2s.py
$(RUNSHARED) $(PYTHON_FOR_BUILD) $(srcdir)/Tools/clinic/clinic.py -f $@ $(PYTHON_FOR_REGEN) $(srcdir)/Tools/clinic/clinic.py -f $@
# Build the shared modules # Build the shared modules
# Under GNU make, MAKEFLAGS are sorted and normalized; the 's' for # Under GNU make, MAKEFLAGS are sorted and normalized; the 's' for
@ -733,7 +732,8 @@ regen-importlib: Programs/_freeze_importlib
############################################################################ ############################################################################
# Regenerate all generated files # Regenerate all generated files
regen-all: regen-opcode regen-opcode-targets regen-typeslots regen-grammar regen-ast regen-importlib regen-all: regen-opcode regen-opcode-targets regen-typeslots regen-grammar \
regen-ast regen-importlib clinic
############################################################################ ############################################################################
# Special rules for object files # Special rules for object files