From: Pedro Alves <palves@redhat.com>
To: Luca Pizzamiglio <luca.pizzamiglio@gmail.com>
Cc: gdb-patches@sourceware.org
Subject: Re: wrong bfd recognized
Date: Tue, 07 Feb 2012 20:15:00 -0000 [thread overview]
Message-ID: <4F318648.8@redhat.com> (raw)
In-Reply-To: <CAB88xy91dt7mOT4wjkaDCvDmj03LjZ_BAV7xTGsaeWe0ZdDe7Q@mail.gmail.com>
On 12/13/2011 03:13 PM, Luca Pizzamiglio wrote:
> +++ gdb/configure.ac 2011-12-13 15:34:08.559285673 +0100
> @@ -1854,7 +1854,7 @@
> OLD_LDFLAGS=$LDFLAGS
> OLD_LIBS=$LIBS
> CFLAGS="$CFLAGS -I${srcdir}/../include -I../bfd -I${srcdir}/../bfd"
> -LDFLAGS="$LDFLAGS -L../bfd -L../libiberty"
> +LDFLAGS="-L../bfd -L../libiberty $LDFLAGS"
If you set LDFLAGS to -L/foo/lib , you presumably also set
CFLAGS to -I/foo/include . In that case, after the patch, if there's a libbfd
in /foo/, you'll run the test with gdb's bfd, but compile it against e.g., the
bfd.h from /foo/include. You may not see this happen with /usr/local/include
because gcc usually ignores -I/usr/local/include as being a duplicate of a
system header path.
IOW, it'd make sense to also do:
- CFLAGS="$CFLAGS -I${srcdir}/../include -I../bfd -I${srcdir}/../bfd"
+ CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
--
Pedro Alves
next prev parent reply other threads:[~2012-02-07 20:15 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-13 15:29 Luca Pizzamiglio
2011-12-20 14:58 ` Tom Tromey
2011-12-21 12:24 ` Luca Pizzamiglio
2011-12-21 18:50 ` Tom Tromey
2011-12-29 12:18 ` Luca Pizzamiglio
2011-12-29 19:02 ` Joel Brobecker
2012-01-02 10:04 ` Luca Pizzamiglio
2012-02-06 19:33 ` Tom Tromey
2012-02-07 16:25 ` Luca Pizzamiglio
2012-02-07 20:15 ` Pedro Alves [this message]
2012-02-10 13:55 ` Pedro Alves
2012-02-10 13:59 ` Luca Pizzamiglio
2012-02-10 14:02 ` Pedro Alves
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=4F318648.8@redhat.com \
--to=palves@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=luca.pizzamiglio@gmail.com \
/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