Skip to contentSkip to conversation

ncurses: generate libtermcap

PATCH New Pascal Mazon 1 participant 1 message May 20, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ncurses: generate libtermcap

Hello,

I haven't had a feedback to my last answer on the subject of libtermcap within the ncurses package, therefore I'd like to address the issue again.

Indeed, I would prefer to have a solution upstream, rather than keeping a local patch.

Thank you,

Date: Mon, 27 Apr 2015 10:11:07 +0200
From: Pascal Mazon <[email protected]>
To: Thomas Petazzoni <[email protected]>
Cc: buildroot at buildroot.org
Subject: Re: [Buildroot] [PATCH 1/1] ncurses: generate libtermcap
Message-ID: <[email protected]>
Content-Type: text/plain; charset=windows-1252; format=flowed

Quoted 4 lines · Thomas Petazzoni

Dear Pascal Mazon,

Quoted 1 line · Pascal Mazon

There is no libtermcap package in buildroot, but ncurses implements

termcap

Quoted 1 line
Quoted 1 line

natively. Furthermore, ncurses already provides the termcap.h header

file.

Quoted 2 lines
Quoted 2 lines

With this patch, we fix an issue encountered with some external

toolchains

Quoted 1 line
Quoted 1 line

that include a libtermcap.a (typically the GNU libtermcap version)

in their

Quoted 3 lines
Quoted 1 line

sysroot folder.

Which external toolchains are in this situation?

I encountered this with a Cavium OCTEON toolchain.

Quoted 10 lines
Quoted 7 lines

Bash, for instance, would be linking with this libtermcap while using headers from ncurses.

In order to be consistent, let's make sure there is only the ncurses' termcap library. To that effect, we:
- remove any libtermcap.* in the staging dir,

I think this should probably not be done by the ncurses package, but as a post-install hook of the external toolchain.

But in that case, would it still be possible not to delete libtermcap.a if ncurses is not selected (to still be able to link against it)?

I put this patch in the ncurses package, as the issue arises only when it is enabled, and it is intimately associated with ncurses selection. I've been thinking that as ncurses provides libtermcap and it is the implementation of choice, it ought to be done there.

I've looked on Debian, the termcap.h and libtermcap.so are provided in the libncurses-dev package itself, too.

Quoted 3 lines

Thomas

-- Pascal Mazon www.6wind.com

Signature · 2 lines
Pascal Mazon
www.6wind.com