From: Anthony Liguori <aliguori@us.ibm.com>
To: Vadim Evard <v.e.evard@gmail.com>
Cc: qemu-devel@nongnu.org, Stefan Hajnoczi <stefanha@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 3/3 v2] configure: try pkg-config for curses
Date: Tue, 15 Jan 2013 17:39:50 -0600 [thread overview]
Message-ID: <87y5fuhv7d.fsf@codemonkey.ws> (raw)
In-Reply-To: <50F5E785.6060304@gmail.com>
Vadim Evard <v.e.evard@gmail.com> writes:
> Static linkikng against ncurses may require explicit -ltinfo.
> In case -lcurses and -lncurses both didn't work give pkg-config a
> chance.
>
> Fixes #1094786 for me.
>
> Signed-off-by: Vadim Evard <v.e.evard@gmail.com>
> Signed-off-by: Stefan Hajnoczi<stefanha@redhat.com>
The original patch is already in master so you'll need to send an
incremental one.
Regards,
Anthony Liguori
> ---
> configure | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/configure b/configure
> index c908f66..477c4e0 100755
> --- a/configure
> +++ b/configure
> @@ -2039,7 +2039,7 @@ fi
> if test "$mingw32" = "yes" ; then
> curses_list="-lpdcurses"
> else
> - curses_list="-lncurses -lcurses"
> + curses_list="-lncurses:-lcurses:$($pkg_config --libs ncurses 2>/dev/null)"
> fi
>
> if test "$curses" != "no" ; then
> @@ -2052,13 +2052,16 @@ int main(void) {
> return s != 0;
> }
> EOF
> + IFS=:
> for curses_lib in $curses_list; do
> + unset IFS
> if compile_prog "" "$curses_lib" ; then
> curses_found=yes
> libs_softmmu="$curses_lib $libs_softmmu"
> break
> fi
> done
> + unset IFS
> if test "$curses_found" = "yes" ; then
> curses=yes
> else
> --
> 1.7.10.4
>
>
>
> On 16.01.2013 02:57, Anthony Liguori wrote:
>> Stefan Hajnoczi<stefanha@redhat.com> writes:
>>
>>> From: Vadim Evard<v.e.evard@gmail.com>
>>>
>>> Static linkikng against ncurses may require explicit -ltinfo.
>>> In case -lcurses and -lncurses both didn't work give pkg-config a
>>> chance.
>>>
>>> Fixes #1094786 for me.
>>>
>>> Signed-off-by: Vadim Evard<v.e.evard@gmail.com>
>>> Signed-off-by: Stefan Hajnoczi<stefanha@redhat.com>
>>> ---
>>> configure | 5 ++++-
>>> 1 file changed, 4 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/configure b/configure
>>> index c908f66..40473a9 100755
>>> --- a/configure
>>> +++ b/configure
>>> @@ -2039,7 +2039,7 @@ fi
>>> if test "$mingw32" = "yes" ; then
>>> curses_list="-lpdcurses"
>>> else
>>> - curses_list="-lncurses -lcurses"
>>> + curses_list="-lncurses:-lcurses:$($pkg_config --libs ncurses)"
>>
>> Please fix this as a follow up but this is sloppy.
>>
>> pkg-config spews stuff to stderr when a package isn't found so this ends
>> up outputting junk in the configure if ncurses isn't found.
>>
>> Regards,
>>
>> Anthony Liguori
>>
>>> fi
>>>
>>> if test "$curses" != "no" ; then
>>> @@ -2052,13 +2052,16 @@ int main(void) {
>>> return s != 0;
>>> }
>>> EOF
>>> + IFS=:
>>> for curses_lib in $curses_list; do
>>> + unset IFS
>>> if compile_prog "" "$curses_lib" ; then
>>> curses_found=yes
>>> libs_softmmu="$curses_lib $libs_softmmu"
>>> break
>>> fi
>>> done
>>> + unset IFS
>>> if test "$curses_found" = "yes" ; then
>>> curses=yes
>>> else
>>> --
>>> 1.8.0.2
>>
next prev parent reply other threads:[~2013-01-15 23:40 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-15 17:13 [Qemu-devel] [PULL 0/3] Trivial patches for 12 to 15 January 2013 Stefan Hajnoczi
2013-01-15 17:13 ` [Qemu-devel] [PATCH 1/3] Add libcacard/trace/generated-tracers.c to .gitignore Stefan Hajnoczi
2013-01-15 17:13 ` [Qemu-devel] [PATCH 2/3] qom: Make object_resolve_path_component() path argument const Stefan Hajnoczi
2013-01-15 17:13 ` [Qemu-devel] [PATCH 3/3] configure: try pkg-config for curses Stefan Hajnoczi
2013-01-15 22:57 ` Anthony Liguori
2013-01-15 23:34 ` [Qemu-devel] [PATCH 3/3 v2] " Vadim Evard
2013-01-15 23:39 ` Anthony Liguori [this message]
2013-01-16 1:18 ` [Qemu-devel] [PULL 0/3] Trivial patches for 12 to 15 January 2013 Anthony Liguori
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=87y5fuhv7d.fsf@codemonkey.ws \
--to=aliguori@us.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
--cc=v.e.evard@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;
as well as URLs for NNTP newsgroup(s).