Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#56652 closed defect (fixed)

MacVim @8.1.snapshot147 +huge+python27+ruby19: build fails on python symbols not found

Reported by: gthb (Gunnlaugur Thor Briem) Owned by: raimue (Rainer Müller)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port: MacVim vim

Description

Upgrading MacVim fails (also after port clean MacVim), with a message about Python symbols not found:

:info:build ccache /usr/bin/clang -c -I. -Iproto -DHAVE_CONFIG_H -DFEAT_GUI_MACVIM -Wall -Wno-unknown-pragmas -pipe  -I/opt/local/include -DMACOS_X -DMACOS_X_DARWIN  -pipe -Os -arch x86_64 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1        version.c -o objects/version.o
:info:build   ccache /usr/bin/clang   -L. -L/opt/local/lib -Wl,-headerpad_max_install_names   -L/opt/local/lib  -L. -L/opt/local/lib -Wl,-headerpad_max_install_names   -L/opt/local/lib  -L/opt/local/lib -Wl,-headerpad_max_install_names -arch x86_64 	-o Vim objects/arabic.o objects/beval.o objects/buffer.o objects/blowfish.o objects/crypt.o objects/crypt_zip.o objects/dict.o objects/diff.o objects/digraph.o objects/edit.o objects/eval.o objects/evalfunc.o objects/ex_cmds.o objects/ex_cmds2.o objects/ex_docmd.o objects/ex_eval.o objects/ex_getln.o objects/farsi.o objects/fileio.o objects/fold.o objects/getchar.o objects/hardcopy.o objects/hashtab.o  objects/if_cscope.o objects/if_xcmdsrv.o objects/list.o objects/mark.o objects/memline.o objects/menu.o objects/misc1.o objects/misc2.o objects/move.o objects/mbyte.o objects/normal.o objects/ops.o objects/option.o objects/os_unix.o objects/pathdef.o objects/popupmnu.o objects/pty.o objects/quickfix.o objects/regexp.o objects/screen.o objects/search.o objects/sha256.o objects/spell.o objects/spellfile.o objects/syntax.o objects/tag.o objects/term.o objects/terminal.o objects/ui.o objects/undo.o objects/userfunc.o objects/version.o objects/window.o objects/gui.o objects/gui_beval.o objects/gui_macvim.o objects/MMBackend.o objects/MacVim.o objects/term_encoding.o objects/term_keyboard.o objects/term_mouse.o objects/term_parser.o objects/term_pen.o objects/term_screen.o objects/term_state.o objects/term_unicode.o objects/term_vterm.o    objects/if_python.o   objects/if_ruby.o objects/os_macosx.o objects/os_mac_conv.o  objects/netbeans.o objects/channel.o  objects/charset.o objects/json.o objects/main.o objects/memfile.o objects/message.o -framework Cocoa -framework Carbon       -lm  -lncurses -liconv -lintl -framework AppKit    -F/opt/local/Library/Frameworks -framework Python   -lruby.1.9.1 -lpthread -ldl -lobjc -L/opt/local/lib    
:info:build Undefined symbols for architecture x86_64:
:info:build   "_PyInt_AsLong", referenced from:
:info:build       _NumberToLong in if_python.o
:info:build       __ConvertFromPyObject in if_python.o
:info:build       _ListItem in if_python.o
:info:build       _ListAssItem in if_python.o
:info:build   "_PyInt_FromLong", referenced from:
:info:build       _DoPyCommand in if_python.o
:info:build       _run_do in if_python.o
:info:build       _OutputGetattr in if_python.o
:info:build       _DictionaryGetattr in if_python.o
:info:build       _ListGetattr in if_python.o
:info:build       _OptionsItem in if_python.o
:info:build   "_PyString_AsString", referenced from:
:info:build       _LineToString in if_python.o
:info:build   "_PyString_AsStringAndSize", referenced from:
:info:build       _StringToLine in if_python.o
:info:build       _StringToChars in if_python.o
:info:build       __ConvertFromPyObject in if_python.o
:info:build   "_PyString_FromFormat", referenced from:
:info:build       _BufferRepr in if_python.o
:info:build       _WindowRepr in if_python.o
:info:build       _TabPageRepr in if_python.o
:info:build       _RangeRepr in if_python.o
:info:build   "_PyString_FromString", referenced from:
:info:build       _DoPyCommand in if_python.o
:info:build       _OutputGetattr in if_python.o
:info:build       _BufferGetattr in if_python.o
:info:build       _FunctionRepr in if_python.o
:info:build       _FunctionGetattr in if_python.o
:info:build       _add_string in if_python.o
:info:build       _ConvertToPyObject in if_python.o
:info:build       ...
:info:build   "_PyString_FromStringAndSize", referenced from:
:info:build       _LineToString in if_python.o
:info:build   "_PyUnicodeUCS2_AsEncodedString", referenced from:
:info:build       _StringToLine in if_python.o
:info:build       _StringToChars in if_python.o
:info:build       __ConvertFromPyObject in if_python.o
:info:build   "_Py_FindMethod", referenced from:
:info:build       _OutputGetattr in if_python.o
:info:build       _BufferGetattr in if_python.o
:info:build       _WindowGetattr in if_python.o
:info:build       _TabPageGetattr in if_python.o
:info:build       _RangeGetattr in if_python.o
:info:build       _CurrentGetattr in if_python.o
:info:build       _DictionaryGetattr in if_python.o
:info:build       ...
:info:build   "_Py_InitModule4_64", referenced from:
:info:build       _DoPyCommand in if_python.o
:info:build   "__Py_ZeroStruct", referenced from:
:info:build       _BufferGetattr in if_python.o
:info:build       _WindowGetattr in if_python.o
:info:build       _TabPageGetattr in if_python.o
:info:build       _FunctionGetattr in if_python.o
:info:build       _AlwaysFalse in if_python.o
:info:build       __DictionaryItem in if_python.o
:info:build       _ConvertToPyObject in if_python.o
:info:build       ...
:info:build ld: symbol(s) not found for architecture x86_64
:info:build clang: error: linker command failed with exit code 1 (use -v to see invocation)
:info:build make[1]: *** [Vim] Error 1

Full main.log attached.

Attachments (1)

main.log (73.4 KB) - added by gthb (Gunnlaugur Thor Briem) 6 years ago.
main.log from the failing build

Download all attachments as: .zip

Change History (6)

Changed 6 years ago by gthb (Gunnlaugur Thor Briem)

Attachment: main.log added

main.log from the failing build

comment:1 Changed 6 years ago by gthb (Gunnlaugur Thor Briem)

Port: MacVim added

comment:2 Changed 6 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: raimue@… removed
Owner: set to raimue
Status: newassigned

comment:3 Changed 6 years ago by raimue (Rainer Müller)

Resolution: fixed
Status: assignedclosed

In 17330f3b45df09e81bda100c99f91a1393a27a39/macports-ports (master):

vim, MacVim: Do not link with -framework Python

Using -framework for linking is not correct, as MacPorts provides
multiple versions of Python. This would always pick up the 'port select'
version and not the one request by variants. Restore parts of the patch
for python that were errorneously removed in 00f3dc13b8 and 0dbff7850a.

Incrementing the revision as this change means that the ports might have
linked against the wrong version of python, for example against the
macOS system framework instead of a version provided by MacPorts.

Closes: #56652

comment:4 Changed 6 years ago by raimue (Rainer Müller)

Port: vim added

Thank you for the report. Indeed, there was a problem with the way the python framework was linked. This should be fixed now in MacVim @8.1.snapshot147_1, please try the upgrade again after running sudo port selfupdate and checking that you already got the updated Portfile with port info MacVim.

comment:5 Changed 6 years ago by gthb (Gunnlaugur Thor Briem)

Yep, that did it!

Note: See TracTickets for help on using tickets.