python36: compilation problem with readline.so

ArnTA

New Member


Messages: 9

After upgrading from FreeBSD 10.3 to 11.2, I am rebuilding ports. There is a problem to compile python36 which is needed by several ports.
It is about readline. The readline-8.0.0 package is installed.
Below message related during "make install" of the port.
It seems many persons met the same problem with python27. But I don't find or understand the resolution.
Code:
cc -shared -lpthread -L/usr/local/lib -fstack-protector-strong -lpthread -L/usr/local/lib -fstack-protector-strong -O2 -pipe -fsta
ck-protector-strong -fno-strict-aliasing -I/usr/local/include -I/usr/local/include build/temp.freebsd-11.2-RELEASE-p10-amd64-3.6/u
sr/ports/lang/python36/work/Python-3.6.8/Modules/readline.o -L/usr/lib/termcap -L. -L/usr/local/lib -lreadline -lpython3.6m -o bui
ld/lib.freebsd-11.2-RELEASE-p10-amd64-3.6/readline.so^M

*** WARNING: renaming "readline" since importing it failed: build/lib.freebsd-11.2-RELEASE-p10-amd64-3.6/readline.so: Undefined symbol "rl_callback_sigcleanup"
...
Following modules built successfully but were removed because they could not be imported:
readline
...
copying build/lib.freebsd-11.2-RELEASE-p10-amd64-3.6/readline_failed.so -> /usr/ports/lang/python36/work/stage/usr/local/lib/python3.6/lib-dynload
...
===>  Checking if python36 is already installed^M
actual-package-depends: dependency on /lib/libreadline.so.8 not registered (normal if it belongs to base)
===>   Registering installation for python36-3.6.8_2
pkg-static: Unable to access file /usr/ports/lang/python36/work/stage/usr/local/lib/python3.6/lib-dynload/readline.so:No such file
or directory^M
*** Error code 74
Does anyone have any suggestions? Thank you.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 9,332
Messages: 33,894

Is there a particular reason why you need ports? This might be a good opportunity to switch to using packages.
 
OP
A

ArnTA

New Member


Messages: 9

I have some ports, I dont remember exactly how many, with special options.
In this case,I have installed python36 package, OK.
But when when I install the dependent ports as bind911 with portmaster, it reinstall python36 with the port.
I notice package use readline-7.x.x as port want readline-8.0.0
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 9,332
Messages: 33,894

Note that /lib/libreadline.so.8 is part of the base OS, not a package.

I notice package use readline-7.x.x as port want readline-8.0.0
Switch to the latest packages. The devel/readline port was updated to 8.0 after the quarterly branch was made.
 
OP
A

ArnTA

New Member


Messages: 9

Note that /lib/libreadline.so.8 is part of the base OS, not a package.
Thank you for the hint. I not sure to understand why python36 depends on readline-8.0.0 and need the base OS /lib/libreadline.so.8, but it doesn't matter.
About my issue, I see that I have 2 libreadline.so.
Code:
# ll /lib/libreadline*
-r--r--r--  1 root  wheel  248800 Jan  1  2009 /lib/libreadline.so.7
-r--r--r--  1 root  wheel  273064 Aug 29  2016 /lib/libreadline.so.8
And on a similar server I update to 11.2 six month ago there is only /lib/libreadline.so.7. So after moving away libreadline.so.8, python36 is compliling and I can reinstall all the ports and achieve update to 11.2.

Strangely, on the last freebsd-update installof the update process I have the message:
Code:
Installing updates...rm: ///lib/libreadline.so.8: No such file or directory
 

mstrofbass

New Member

Reaction score: 3
Messages: 10

Just a heads up: I ran into this same issue when trying to upgrade from like 10.2 to 12.1, but it occurred with python37. I couldn't figure out which port was needing it (so I could remove the port and switch to the pkg version) or how to get it to use a binary install of python37. Thanks to this thread (which I passed over previously), I also moved /lib/libreadline.so.8 out of the lib folder and it worked.

This may be obvious to other people, but to clarify anyways, in my case I didn't have /lib/libreadline.so.7 so the problem does not appear to depend on its presence.
 

Sectordan

New Member


Messages: 1

Just a heads up: I ran into this same issue when trying to upgrade from like 10.2 to 12.1, but it occurred with python37. I couldn't figure out which port was needing it (so I could remove the port and switch to the pkg version) or how to get it to use a binary install of python37. Thanks to this thread (which I passed over previously), I also moved /lib/libreadline.so.8 out of the lib folder and it worked.

This may be obvious to other people, but to clarify anyways, in my case I didn't have /lib/libreadline.so.7 so the problem does not appear to depend on its presence.
FreeBSD **** 11.4-RELEASE-p4 FreeBSD 11.4-RELEASE-p4 #0 r366664
pkg-static: Unable to access file /usr/ports/lang/python37/work/stage/usr/local/lib/python3.7/lib-dynload/readline.so:No such file or directory

Thank's you save my time.
 
Top