This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Problem linking to readline lib on x86(64) Solaris
Type: behavior Stage: resolved
Components: Build Versions: Python 2.6
process
Status: closed Resolution: duplicate
Dependencies: Superseder: readline configuration for shared libs w/o curses dependencies
View: 1204
Assigned To: Nosy List: ajaksu2, belopolsky, jcea, loewis, rpetrov
Priority: low Keywords:

Created on 2007-03-07 22:07 by belopolsky, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (6)
msg31465 - (view) Author: Alexander Belopolsky (belopolsky) * (Python committer) Date: 2007-03-07 22:07
Configuring with 

./configure --with-gcc="gcc -m64 -L/usr/sfw/lib/64 -R/usr/sfw/lib/64" 

where 64bit libreadline is found in /usr/sfw/lib/64, configure script fails to realize that readline lib is present.

I was able to fix the problem by editing config script manually as follows:

$ diff configure~ configure
20744c20744
< if test "$ac_cv_have_readline_readline" = no
---
> if test "$ac_cv_lib_readline_readline" = no
20747c20747
< echo "$as_me:$LINENO: checking for readline in -ltermcap" >&5
---
> echo "$as_me:$LINENO: checking for readline in -lreadline -ltermcap" >&5
20753c20753
< LIBS="-ltermcap  $LIBS"
---
> LIBS="-lreadline -ltermcap  $LIBS"


A proper fix would be to change configure.in, but I don't know enough about autoconf to submit a proper patch.
msg31466 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2007-03-08 22:18
The right solution in this case is to edit Modules/Setup
msg31467 - (view) Author: Alexander Belopolsky (belopolsky) * (Python committer) Date: 2007-03-08 22:25
Can you explain how to edit Module/Setup to solve this problem?

Note that the problem that I see comes before modules are built. In fact it comes even before make.

In any case, I think the check for $ac_cv_have_readline_readline" = no instead of "$ac_cv_lib_readline_readline" = no looks like a typo in configure.in.  And looking for readline in libtermcap does not look like sound logic either.
msg84677 - (view) Author: Daniel Diniz (ajaksu2) * (Python triager) Date: 2009-03-30 22:08
The "ac_cv_have_readline" check isn't present in trunk. I'll close this
unless someone voices opposition.
msg84740 - (view) Author: Alexander Belopolsky (belopolsky) * (Python committer) Date: 2009-03-31 01:37
I don't have a Solaris box to test at the moment, but I believe the
following commit fixed this issue:

------------------------------------------------------------------------
r66283 | gregory.p.smith | 2008-09-07 01:15:18 -0400 (Sun, 07 Sep
2008) | 5 lines

- Issue #1204: The configure script now tests for additional libraries
  that may be required when linking against readline.  This fixes issues
  with x86_64 builds on some platforms (at least a few Linux flavors as
  well as OpenBSD/amd64).

------------------------------------------------------------------------

If it is the case, this issue should be closed as a duplicate of #1204.
msg122240 - (view) Author: Roumen Petrov (rpetrov) * Date: 2010-11-23 19:40
Hmm why you dont use LDFLAGS ?
It is well documented what to expect during configuration and build phase.
History
Date User Action Args
2022-04-11 14:56:23adminsetgithub: 44680
2011-03-17 12:52:32jceasetnosy: + jcea
2010-11-23 19:40:04rpetrovsetnosy: + rpetrov
messages: + msg122240
2010-11-22 23:59:52eric.araujosetsuperseder: documentation for new SSL module -> readline configuration for shared libs w/o curses dependencies
2009-05-12 17:07:48ajaksu2setstatus: pending -> closed
resolution: duplicate
superseder: documentation for new SSL module
stage: test needed -> resolved
2009-03-31 01:37:10belopolskysetmessages: + msg84740
2009-03-30 22:08:47ajaksu2setstatus: open -> pending
priority: normal -> low
type: behavior

components: + Build, - None
versions: + Python 2.6
nosy: + ajaksu2

messages: + msg84677
stage: test needed
2007-03-07 22:07:56belopolskycreate