Python3. fails to install if archivers/lzmalib is installed. The error is _lzma extension can't be found (conflict with Python's plist). If I remove lzmalib from system, _lzma extension will be built and installed.
How to reproduce:
* check if you have no python35 in system
* install *archivers/lzmalib*
* try to install lang/python35
My options for lang/python35 are:
===> The following configuration options are available for python35-3.5.1_2:
DEBUG=off: Build with debugging support
IPV6=on: IPv6 protocol support
LIBFFI=on: Use libffi from ports instead of bundled version
NLS=on: Enable gettext support for the locale module
PYMALLOC=on: Enable specialized mallocs
THREADS=on: Threading support
TSC=on: Enable processor timestamp counter profiling
====> Hash Algorithm (PEP-456): you can only select none or one of them
FNV=off: Modified Fowler-Noll-Vo Algorithm
SIPHASH=on: SipHash24 Algorithm
===> Use 'make config' to modify these settings
It seems to be old bug, but I haven't found it.
I think this is because you can find liblzma in /usr/lib and in /usr/local/lib and the latest doesn't want to be compiled with Python
over to python maintainers
lzmalib is only need by two ports: /archivers/p5-Compress-Raw-Lzma and databases/tokyocabinet. Both have OPTIONS to change.
I want to install and use databases/tokyocabinet with LZMA support and it doesn't accept lzmalib from base. and Python doesn't accept lzmalib from ports. deadlock?
it seems to work if you add to the lang/python35/Makefile
LIB_DEPENDS= liblzma.so.1:archivers/lzmalib \
and create a new pkg-plist with make makeplist or genplist.
I provide no diff, cause I am not sure if the "new" pkg-plist is ok.
Note: I have only compiled it with python35. Not really tested. This could only be a workaround for the moment.
find /usr/ports/lang/python34/work/stage/* -type f|grep lzma
the difference is:
It seems it is only mispelled in pkg-plist. Compare it with python35 pkg-plist (has _lzma_failed.so)
correct a typo:
the difference is:
It looks it tries to link the /usr/local/lib/liblzma.so instead of /usr/lib/liblzma.so.
and liblzma.so from the port archives/lzmalib doesn't have "lzma_properties_size".
The first "-L/usr/local/lib" in the "cc -shared" comes from Mk/readline.mk,
it make the linker to search this directory before the default directories.
building '_lzma' extension
cc -fPIC -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -O -pipe -fno-strict-aliasing -Werror=declaration-after-statement -I./Include -I. -IInclude -I/usr/local/include -I/usr/ports/lang/python35/work/Python-3.5.2/Include -I/usr/ports/lang/python35/work/Python-3.5.2 -c /usr/ports/lang/python35/work/Python-3.5.2/Modules/_lzmamodule.c -o build/temp.freebsd-12.0-CURRENT-arm-3.5/usr/ports/lang/python35/work/Python-3.5.2/Modules/_lzmamodule.o
cc -shared -lpthread -Wl,-rpath=/usr/lib:/usr/local/lib -L/usr/local/lib -lpthread -Wl,-rpath=/usr/lib:/usr/local/lib -L/usr/local/lib -O -pipe -fno-strict-aliasing -I/usr/local/include -I/usr/local/include build/temp.freebsd-12.0-CURRENT-arm-3.5/usr/ports/lang/python35/work/Python-3.5.2/Modules/_lzmamodule.o -L. -L/usr/local/lib -llzma -lpython3.5m -o build/lib.freebsd-12.0-CURRENT-arm-3.5/_lzma.so
*** WARNING: renaming "_lzma" since importing it failed: build/lib.freebsd-12.0-CURRENT-arm-3.5/_lzma.so: Undefined symbol "lzma_properties_size"
Created attachment 174374 [details]
The port archives/lzmalibs provides /usr/local/lib/liblzma.so.1
and the base has /usr/lib/liblzma.so.5.
If there exists a /usr/local/lib/liblzma.so.1. then pass the "-l:liblzma.so.5"
to make it link the library in the base.
Created attachment 174375 [details]
disable compiling _lzma in lang/python35 and move it to a separate port.
there would be no USES= readline in that port and no version number of
the base liblzma.so in the patch.
Just my thoughts, not proposing these workarounds as the fix.
(In reply to Fukang Chen from comment #9)
See also https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=217244
Any news here?
removed expired python34 from subject.
*** Bug 243817 has been marked as a duplicate of this bug. ***
*** Bug 249042 has been marked as a duplicate of this bug. ***
Python 2.x doesn't provide an lzma module (vbia dbaio)