classification
Title: missing symbols in curses and readline modules on android
Type: behavior Stage:
Components: Cross-Build Versions: Python 3.6
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: Nosy List: Alex.Willmer, Chi Hsuan Yen, Roman.Evstifeev, skrah, xdegaye
Priority: normal Keywords: patch

Created on 2016-04-26 13:01 by xdegaye, last changed 2016-04-28 08:01 by xdegaye. This issue is now closed.

Files
File name Uploaded Description Edit
curses_readline.patch xdegaye, 2016-04-26 13:01 review
Messages (5)
msg264274 - (view) Author: Xavier de Gaye (xdegaye) * (Python committer) Date: 2016-04-26 13:01
The android loader complains when shared libraries are not linked against their needed libraries (see also issue #21668).  When ncurses is cross-compiled as a shared library, the curses and readline modules must be linked with libtinfow.so.

The attached patch is a quick hack: setup.py spawns readelf to get the list of needed libraries, but this fails as the readelf path name is wrong (it is not the absolute path) and so cannot be used as is for a correct patch.
msg264319 - (view) Author: Chi Hsuan Yen (Chi Hsuan Yen) * Date: 2016-04-26 17:08
Things may be different if ncurses is built with --without-termlib or --enable-widec is not specified. I wasn't hit by this bug as my ncurses is built with --without-termlib.
msg264327 - (view) Author: Stefan Krah (skrah) * (Python committer) Date: 2016-04-26 21:03
Do you need libtinfow? It seems that it's not supported in setup.py,
and getting even libtinfo support into some Linux distributions took
quite a while.
msg264329 - (view) Author: Stefan Krah (skrah) * (Python committer) Date: 2016-04-26 21:06
IOW, on Linux tinfo should work fine in combination with ncursesw.
msg264422 - (view) Author: Xavier de Gaye (xdegaye) * (Python committer) Date: 2016-04-28 08:01
Thanks Chi Hsuan Yen and Stefan. Indeed the --with-termlib configure option documentation states: "When building the ncurses library, organize this as two parts:  the curses library (libncurses) and the low-level terminfo library (libtinfo)". Using --without-termlib prevents that split.

My previous comment about readelf is wrong, the gcc cross-compiler is in the $PATH directory search path, as well as readelf.

Closing this issue as not a bug.
History
Date User Action Args
2016-04-28 08:01:03xdegayesetstatus: open -> closed
resolution: not a bug
messages: + msg264422
2016-04-26 21:06:24skrahsetmessages: + msg264329
2016-04-26 21:03:37skrahsetnosy: + skrah
messages: + msg264327
2016-04-26 17:08:42Chi Hsuan Yensetnosy: + Chi Hsuan Yen
messages: + msg264319
2016-04-26 16:26:40Roman.Evstifeevsetnosy: + Roman.Evstifeev
2016-04-26 16:04:41zach.warelinkissue26865 dependencies
2016-04-26 13:01:37xdegayecreate