[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] net: add mmsghdr struct check for L2TPV3
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] [PATCH] net: add mmsghdr struct check for L2TPV3 |
Date: |
Tue, 1 Jul 2014 13:41:50 +0100 |
On 1 July 2014 13:23, <address@hidden> wrote:
> From: Gonglei <address@hidden>
>
> because mmsghdr struct is introduced on Linux kernel 3.3+.
> add check for mmsghdr, it only gets built on hosts that
> support mmsghdr.
> +l2tpv3="yes"
> pixman=""
> sdl=""
> sdlabi="1.2"
> @@ -1712,6 +1713,21 @@ else
> fi
>
> ##########################################
> +# L2TPV3 probe
> +
> +if test "$l2tpv3" != "no" ; then
When can this "if" ever be false? There's no command line
to enable/disable, so you might as well just always run
the compile_prog test and set l2tpv3 to yes or no here
(and then you don't need the initialization above).
> + cat > $TMPC << EOF
> +#include <sys/socket.h>
> +int main(void) { return sizeof(struct mmsghdr); }
> +EOF
> + if compile_prog "" "" ; then
> + l2tpv3=yes
> + else
> + l2tpv3=no
> + fi
> +fi
thanks
-- PMM