Bug 232795 - lang/python37: incorrect -L argument order makes python37 build fail in presence of (older) python37
Summary: lang/python37: incorrect -L argument order makes python37 build fail in prese...
Status: Closed DUPLICATE of bug 232510
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: freebsd-python (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-29 21:02 UTC by Dmitry Marakasov
Modified: 2018-10-30 02:25 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (python)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry Marakasov freebsd_committer freebsd_triage 2018-10-29 21:02:26 UTC
Python37 can't be upgraded from 3.7.0 to 3.7.1, because build fails:

--- Programs/_testembed ---
cc -pthread  -L/usr/local/lib  -fstack-protector  -Wl,--export-dynamic -o Programs/_testembed Programs/_testembed.o -L. -lpython3.7m -ldl  -lutil   -lm                                                                                                     
Programs/_testembed.o: In function `test_init_from_config':
_testembed.c:(.text+0xd28): undefined reference to `_Py_InitializeFromConfig'
Programs/_testembed.o: In function `test_init_dev_mode':
_testembed.c:(.text+0xe0f): undefined reference to `_Py_InitializeFromConfig'
Programs/_testembed.o: In function `test_init_isolated':
_testembed.c:(.text+0xeb3): undefined reference to `_Py_InitializeFromConfig'
cc: error: linker command failed with exit code 1 (use -v to see invocation)

This is caused by -L/usr/local/lib present in the linker invocation before -L., so libraries from systemwide installed python (previous version) are picked up. I've solved this by remivong /usr/local/lib/libpython*, but the port should be fixed.
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2018-10-30 02:25:48 UTC

*** This bug has been marked as a duplicate of bug 232510 ***