[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-readline] Linking Shared libreadline with(out) TERMCAP_LIB
From: |
Chet Ramey |
Subject: |
Re: [Bug-readline] Linking Shared libreadline with(out) TERMCAP_LIB |
Date: |
Mon, 13 May 2019 11:59:51 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 |
On 4/30/19 12:52 PM, Dmitrii Pasechnik wrote:
>> I'm skeptical of this reasoning, but let's see the patches and see how
>> it goes.
>
> Few questions first:
Let's start by stipulating that you should establish what your goals are.
Do you want something that can be used by readline itself to determine
where the curses/termcap/ncurses library is so it can be used when creating
the shared readline library? If so, you should probably rewrite the entire
thing.
>
> 1) Can TERMCAP_DEP be removed? It is not used anywhere in readline
> source, as far as I can tell.
If you're doing a rewrite that won't be used in bash, yes. Bash uses that
variable. The existing macro is part of the bash autoconf framework and
contains things that only bash uses.
>
> 2) Would a rewrite of BASH_CHECK_LIB_TERMCAP using AC_SEARCH_LIBS be
> acceptable?
Yes.
> 3) What is the reason of hard-coding SHLIB_LIBS='-lncurses' on
> OSX/Darwin? Can we let configure to figure it out (it will be in TERMCAP_LIB)?
Because apple ships it and it can be guaranteed to be there. If you want
to have configure do it as well, go ahead and add it.
>
> 4) "./lib/termcap/libtermcap.a" is something never built by readline,
> although TERMCAP_LIB is being assigned this value sometimes, and there
> is a check whether TERMCAP_LIB equals this seemingly random value.
> Was it meant to be a sub-module?
This macro is part of bash, and bash builds that target. It's the GNU
standalone termcap library, used as a last-ditch effort to link with
the included readline library.
>
> 5) it's not possible to build examples if configure was run with
> "--disable-static" - indeed, examples always expect TERMCAP_LIB to be a
> static library. This appears to be a bug.
Come on. The examples need to link against a static libreadline.a and
libhistory.a -- it's right there in the Makefile. It's perfectly fine to
have the following assignments, which I do in a RHEL build environment
READLINE_LIB = ../libreadline.a
HISTORY_LIB = ../libhistory.a
TERMCAP_LIB = -ltermcap
This doesn't have anything to do with TERMCAP_LIB.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU address@hidden http://tiswww.cwru.edu/~chet/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [Bug-readline] Linking Shared libreadline with(out) TERMCAP_LIB,
Chet Ramey <=