[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 1.0] configure: tighten pie toolchain support te
From: |
Gerd Hoffmann |
Subject: |
Re: [Qemu-devel] [PATCH 1.0] configure: tighten pie toolchain support test for tls variables |
Date: |
Tue, 22 Nov 2011 14:26:19 +0100 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.24) Gecko/20111104 Red Hat/3.1.16-2.el6_1 Thunderbird/3.1.16 |
On 11/22/11 13:32, Avi Kivity wrote:
> Some toolchains don't support pie properly when tls variables are
> in use. Disallow pie when such toolchains are detected.
>
> Signed-off-by: Avi Kivity <address@hidden>
> ---
> configure | 5 ++++-
> 1 files changed, 4 insertions(+), 1 deletions(-)
>
> diff --git a/configure b/configure
> index 75e1f10..7e6c640 100755
> --- a/configure
> +++ b/configure
> @@ -1120,7 +1120,10 @@ fi
>
> if test "$pie" != "no" ; then
> cat > $TMPC << EOF
> -int main(void) { return 0; }
> +
> +static __thread tls_var;
> +
> +int main(void) { return tls_var; }
> EOF
> if compile_prog "-fPIE -DPIE" "-pie"; then
> QEMU_CFLAGS="-fPIE -DPIE $QEMU_CFLAGS"
Survived testbuild.
thanks,
Gerd