On Fri, Dec 04, 2020 at 02:38:54PM +0100, Matthias Klose wrote: > On 12/4/20 9:07 AM, Kito Cheng via Gcc-patches wrote: > > Committed, thanks :) > > > > On Thu, Dec 3, 2020 at 8:51 AM Jim Wilson <j...@sifive.com> wrote: > >> > >> On Tue, Dec 1, 2020 at 12:13 AM Kito Cheng <kito.ch...@sifive.com> wrote: > >>> > >>> - We would like to canonicalize the arch string for --with-arch for > >>> easier handling multilib, so split canonicalization part to a stand > >>> along script to shared the logic. > >>> > >>> gcc/ChangeLog: > >>> > >>> * config/riscv/multilib-generator (arch_canonicalize): Move > >>> code to arch-canonicalize, and call that script to canonicalize > >>> arch > >>> string. > >>> (canonical_order): Move code to arch-canonicalize. > >>> (LONG_EXT_PREFIXES): Ditto. > >>> (IMPLIED_EXT): Ditto. > >>> * config/riscv/arch-canonicalize: New. > >>> * config.gcc (riscv*-*-*): Canonicalize --with-arch. > >> > >> > >> Looks OK to me. > > that breaks the bootstrap if python is not available. The python command might > not be available, so please check for python3, python, or python2. > > And it adds an unconditional build dependency on python for building the riscv > targets.
Yeah, doing it in awk or shell might be better. We do use python for various things, but generally try not to require it for build and make check, e.g. some contrib/ scripts used during build and make check have shell variants etc. Jakub