[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [Nbd] [PATCH] build: Fix build with older gcc



On 12/19/2016 04:15 PM, Eric Blake wrote:
> gcc 4.4.7 (hello RHEL 6) complains about redefinition of typedefs,
> as in:
> 
> gcc -std=gnu99 -DHAVE_CONFIG_H -I.  -DSYSCONFDIR='"/usr/local/etc"'  -g -O2  -g -O2 -MT nbd_client-buffer.o -MD -MP -MF .deps/nbd_client-buffer.Tpo -c -o nbd_client-buffer.o `test -f 'buffer.c' || echo './'`buffer.c
> buffer.c:39: error: redefinition of typedef ‘buffer_t’
> buffer.h:31: note: previous declaration of ‘buffer_t’ was here
> 
> The .c file only has to declare the struct being typedef'd, not
> repeat the typedef declaration.
> 
> Signed-off-by: Eric Blake <eblake@...696...>
> ---
>  buffer.c        | 4 ++--
>  crypto-gnutls.c | 4 ++--
>  2 files changed, 4 insertions(+), 4 deletions(-)

With this patch, I was able to run 'make check' on my RHEL 6 machine,
with its older gnutls-devel-2.12.23-17.el6.x86_64.  There were two test
failures, both related to the recent STARTTLS additions, but I don't
have enough time or tls experience to try and debug them today. It may
just be a bug in the testsuite, not prepared to handle the difference
between older and modern gnutls.

./tls
TLS handshake failed: A TLS packet with unexpected length was received.

** (process:23575): WARNING **: Could not open socket: Could not read
size: Connection reset by peer

** (process:23575): WARNING **: Could not read size: Connection reset by
peer

** (process:23575): WARNING **: Could not run test: Could not read size:
Connection reset by peer
FAIL: tls
./tlshuge
TLS handshake failed: A TLS packet with unexpected length was received.

** (process:23615): WARNING **: Could not open socket: Could not read
size: Resource temporarily unavailable

** (process:23615): WARNING **: Could not read size: Resource
temporarily unavailable

** (process:23615): WARNING **: Could not run test: Could not read size:
Resource temporarily unavailable
FAIL: tlshuge
./tlswrongcert
TLS handshake failed: A TLS packet with unexpected length was received.

** (process:23645): WARNING **: Could not open socket: Could not read
size: Resource temporarily unavailable

** (process:23645): WARNING **: Could not run test: Could not read size:
Resource temporarily unavailable
XFAIL: tlswrongcert


-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


Reply to: