From: Joel Brobecker <brobecker@adacore.com>
To: Thiago Jung Bauermann <thiago.bauermann@linaro.org>
Cc: gdb-patches ml <gdb-patches@sourceware.org>
Subject: Re: [RFA] Define Elf32_auxv_t and Elf64_auxv_t if not available.
Date: Tue, 27 Mar 2012 15:21:00 -0000 [thread overview]
Message-ID: <20120327152058.GF2701@adacore.com> (raw)
In-Reply-To: <1332787763.30339.10.camel@hactar>
> 2012-03-26 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
>
> * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
> are available.
> * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
> [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
(you'll need to mention the fact that configure and config.in need
to be regenerated)
I am not very familiar with this area, so I am hoping someone else
might provide feedback as well.
I only have a minor question. Other than that, I don't see a problem
with the patch...
> diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac
> index e6e9162..6b98dc0 100644
> --- a/gdb/gdbserver/configure.ac
> +++ b/gdb/gdbserver/configure.ac
> @@ -163,9 +163,10 @@ fi
>
> AC_CHECK_DECLS([strerror, perror, memmem, vasprintf, vsnprintf])
>
> -AC_CHECK_TYPES(socklen_t, [], [],
> +AC_CHECK_TYPES([socklen_t, Elf32_auxv_t, Elf64_auxv_t], [], [],
> [#include <sys/types.h>
> #include <sys/socket.h>
> +#include <elf.h>
> ])
I wonder if we shouldn't be using two separate checks here. Seems
unlikely to be a problem in practice, but we're looking for for
a type is <sys/types.h> + <sys/socket.h>, and then looking for another
collection of types in <elf.h>. We know we're most likely not going
to get any "cross-polination" finding socklen_t in <elf.h>, but if
this sort of thing were to happen, we would be in a situation where
the configure check finds the type, but the code (which presumably
might only include types.h and sockets.h) does not, leading to a build
error.
(let's wait for more feedback before we make any change - someone
might disagree)
--
Joel
next prev parent reply other threads:[~2012-03-27 15:21 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-26 18:49 Thiago Jung Bauermann
2012-03-27 15:21 ` Joel Brobecker [this message]
2012-03-28 0:12 ` Thiago Jung Bauermann
2012-03-29 16:03 ` Pedro Alves
2012-03-30 20:26 ` Thiago Jung Bauermann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120327152058.GF2701@adacore.com \
--to=brobecker@adacore.com \
--cc=gdb-patches@sourceware.org \
--cc=thiago.bauermann@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox