[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 03/43] configure: add support for --cross-cc-
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] [PATCH v2 03/43] configure: add support for --cross-cc-FOO |
Date: |
Thu, 19 Apr 2018 16:41:16 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 |
On 04/19/2018 08:58 AM, Alex Bennée wrote:
> This allows us to specify cross compilers for our guests. This is
> useful for building test images/programs. Currently we re-run the
> compile test for each target. I couldn't think of a way to cache the
> value for a given arch without getting messier configure code.
>
> The cross compiler for the guest is visible to each target as
> CROSS_CC_GUEST in config-target.mak.
>
> Signed-off-by: Alex Bennée <address@hidden>
> ---
> configure | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 50 insertions(+)
>
> @@ -483,6 +490,11 @@ for opt do
> ;;
> --disable-debug-info) debug_info="no"
> ;;
> + --cross-cc-*[!a-zA-Z0-9_0]=*) error_exit "Passed bad --cross-cc-FOO option"
Not quite right; it looks like you intended to have a trailing - instead
of 0; and if you are trying to filter out bad characters, then you need
* on both sides of the [!...] list:
--cross-cc-*[!a-zA-Z0-9_-]*=*)
otherwise you are only filtering out bad characters immediately before
the first =. There's also the question of whether I can spell both
'--cross-cc-FOO=BAR' as one argument and '--cross-cc-FOO BAR' as two
arguments; this is filtering out only the one-argument case.
> + ;;
> + --cross-cc-*) cc_arch=${opt#--cross-cc-}
> + eval "cross_cc_${cc_arch}=\$optarg"
> + ;;
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
signature.asc
Description: OpenPGP digital signature
- [Qemu-devel] [PATCH v2 00/43] fix building of tests/tcg, Alex Bennée, 2018/04/19
- [Qemu-devel] [PATCH v2 06/43] configure: set cross_cc_FOO for host compiler, Alex Bennée, 2018/04/19
- [Qemu-devel] [PATCH v2 01/43] docker: add "probe" command for configure, Alex Bennée, 2018/04/19
- [Qemu-devel] [PATCH v2 05/43] configure: allow user to specify --cross-cc-cflags-foo=, Alex Bennée, 2018/04/19
- [Qemu-devel] [PATCH v2 10/43] docker: allow "cc" command to run in user context, Alex Bennée, 2018/04/19
- [Qemu-devel] [PATCH v2 14/43] tests/tcg/multiarch: enable additional linux-test tests, Alex Bennée, 2018/04/19
- [Qemu-devel] [PATCH v2 08/43] docker: Add "cc" subcommand, Alex Bennée, 2018/04/19
- [Qemu-devel] [PATCH v2 09/43] docker: extend "cc" command to accept compiler, Alex Bennée, 2018/04/19