All of lore.kernel.org
 help / color / mirror / Atom feed
From: Olaf Hering <olaf@aepfle.de>
To: Ian Jackson <Ian.Jackson@eu.citrix.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: Re: [PATCH] use ncurses-config to find all curses related libs
Date: Thu, 24 Nov 2011 20:15:02 +0100	[thread overview]
Message-ID: <20111124191502.GA25881@aepfle.de> (raw)
In-Reply-To: <20174.37522.349763.828592@mariner.uk.xensource.com>

On Thu, Nov 24, Ian Jackson wrote:

> Olaf Hering writes ("Re: [Xen-devel] [PATCH] use ncurses-config to find all curses related libs"):
> > On Thu, Nov 24, Ian Jackson wrote:
> > > Olaf Hering writes ("[Xen-devel] [PATCH] use ncurses-config to find all curses related libs"):
> > > > -CURSES_LIBS = -lncurses
> > > > +CURSES_LIBS = $(shell if ! ncurses5-config --libs 2>/dev/null ; then ncurses-config --libs ; fi)
> > > 
> > > In the case where ncurses5-config is not provided, this will fail.
> 
> Sorry, I wasn't sufficiently clear.  The case that fails is if neither
> ncurses5-config nor ncurses-config is provided.  The default should be
> to use -lncurses as before.

I see. Another if construct, or a check_ncurses script which looks for
ncurses5-config or ncurses-config. After some digging in old SuSE
releases, ncurses5-config appeared in 11.0 (2008), SLES10 does not have
it yes . So blindly relying on -config scripts will likely break
building on old distributions.

This should work:

if ! ncurses5-config --libs 2>/dev/null;then if ! ncurses-config --libs ; then echo '-lncurses' ; fi ; fi

Olaf

  reply	other threads:[~2011-11-24 19:15 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-22 11:35 [PATCH] use ncurses-config to find all curses related libs Olaf Hering
2011-11-24 18:38 ` Ian Jackson
2011-11-24 18:49   ` Olaf Hering
2011-11-24 18:53     ` Ian Jackson
2011-11-24 19:15       ` Olaf Hering [this message]
2011-11-24 19:20         ` Ian Jackson
2011-11-24 19:37           ` Olaf Hering
2011-11-29 12:50 ` [PATCH v2] " Olaf Hering

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=20111124191502.GA25881@aepfle.de \
    --to=olaf@aepfle.de \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=xen-devel@lists.xensource.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.