[OE-core] [PATCH 2/4] python3: remove redundant patch

Khem Raj raj.khem at gmail.com
Mon Sep 10 17:35:44 UTC 2018


Thanks for the clarification. It seems to be fine then
On Mon, Sep 10, 2018 at 9:24 AM Burton, Ross <ross.burton at intel.com> wrote:
>
> Line-by-line breakdown of the patch:
>
> > diff --git a/Makefile.pre.in b/Makefile.pre.in
> > index 144c1f8629..f252ac2417 100644
> > --- a/Makefile.pre.in
> > +++ b/Makefile.pre.in
> > @@ -223,6 +223,7 @@ LIBOBJS= @LIBOBJS@
> >  PYTHON= python$(EXE)
> >  BUILDPYTHON= python$(BUILDEXE)
> > +HOSTPYTHON=    $(BUILDPYTHON)
>
> New variable added.
>
> >  PGEN= Parser/pgen$(EXE)
> > +HOSTPGEN= $(PGEN)$(EXE)
>
> New variable added.  My removal simple sets PGEN=/path/to/pgen-native instead.
>
> >  run_profile_task:
> >   : # FIXME: can't run for a cross build
> > - $(LLVM_PROF_FILE) $(RUNSHARED) ./$(BUILDPYTHON) $(PROFILE_TASK) || true
> > + $(LLVM_PROF_FILE) $(RUNSHARED) $(HOSTPYTHON) $(PROFILE_TASK) || true
>
> We never use run_profile_task.
>
> > @@ -772,7 +774,7 @@ regen-grammar: $(PGEN)
> >   # Regenerate Include/graminit.h and Python/graminit.c
> >   # from Grammar/Grammar using pgen
> >   @$(MKDIR_P) Include
> > - $(PGEN) $(srcdir)/Grammar/Grammar \
> > + $(HOSTPGEN) $(srcdir)/Grammar/Grammar \
>
> As my patch changes PGEN directly, this is redundant.
>
> > -TESTPYTHON= $(RUNSHARED) ./$(BUILDPYTHON) $(TESTPYTHONOPTS)
> > +TESTPYTHON= $(RUNSHARED) $(HOSTPYTHON) $(TESTPYTHONOPTS)
>
> TESTPYTHON is only used by the following targets:
> - coverage-report
> - test
> - testall
> - testuniversal
> - quicktest
>
> We don't invoke any of those during a build.
>
> >  TESTRUNNER= $(TESTPYTHON) $(srcdir)/Tools/scripts/run_tests.py
> >  TESTTIMEOUT= 3600
> > @@ -1470,7 +1472,7 @@ frameworkinstallstructure: $(LDLIBRARY)
> >   fi; \
> >   done
> >   $(LN) -fsn include/python$(LDVERSION) $(DESTDIR)$(prefix)/Headers
> > - sed 's/%VERSION%/'"`$(RUNSHARED) ./$(BUILDPYTHON) -c 'import platform; print(platform.python_version())'`"'/g' < $(RESSRCDIR)/Info.plist > $(DESTDIR)$(prefix)/Resources/Info.plist
> > + sed 's/%VERSION%/'"`$(RUNSHARED) $(HOSTPYTHON) -c 'import platform; print(platform.python_version())'`"'/g' < $(RESSRCDIR)/Info.plist > $(DESTDIR)$(prefix)/Resources/Info.plist
>
> This is MacOS-specific.
>
> >  # Run reindent on the library
> >  reindent:
> > - ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib
> > + $(HOSTPYTHON) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib
>
> We never invoke reindent (as this is for maintainers).
>
> > @@ -1678,7 +1680,7 @@ funny:
> >  # Perform some verification checks on any modified files.
> >  patchcheck: @DEF_MAKE_RULE@
> > - $(RUNSHARED) ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
> > + $(RUNSHARED) $(HOSTPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
> >  # Dependencies
>
> We never invoke patchcheck (as this is for maintainers).
>
> Ross



More information about the Openembedded-core mailing list