Linker Error on CrossCompiling Modules on tcl V8.6.10 in libtclstub8.6.a
Closed / Fixed0d72c165defb6d9a78db6572930730106daa692aCreated 7 years agoUpdated 7 years ago
Descriptionplain2020-01-02 13:44:58
I try to crosscompile tcl V8.6.10 on Linux with osxcross.
Compiling works fine, but in the libtclstub8.6.a there is now an reference
to TclIsSpaceProc, so.
If i now compile an extension, the linking fails as libtclstub8.6.a has an
undefinded reference for TclIsSpaceProc:
o64-clang -DSTATIC_BUILD=1 -DMAC_OSX_TCL=1 -D__APPLE__ -shared -pipe -O2 -fomit-frame-pointer -Wall -fPIC -o libtreectrl2.4.3.so qebind.o tkTreeColumn.o tkTreeCtrl.o tkTreeDisplay.o tkTreeDrag.o tkTreeElem.o tkTreeHeader.o tkTreeItem.o tkTreeMarquee.o tkTreeNotify.o tkTreeStyle.o tkTreeTheme.o tkTreeUtils.o tkMacOSXTree.o -framework Cocoa -framework Carbon -L/home/michael/entwicklung/tclexecomp/maccross/build/tcl8.6.10/unix -ltclstub8.6 -L/home/michael/entwicklung/tclexecomp/maccross/build/tk8.6.10/unix -ltkstub8.6
Undefined symbols for architecture x86_64:
"_TclIsSpaceProc", referenced from:
_strtoul in libtclstub8.6.a(strtoul.o)
ld: symbol(s) not found for architecture x86_64
clang-9: error: linker command failed with exit code 1 (use -v to see invocation)
After changeing the file "compat/strtoul.c" to the version of V8.6.9, compilation works
as expected.
Here is the only change:
pc1@~/entwicklung/tclexecomp/src/tcl/tcl8.6.10.new# diff compat/strtoul.c ../../../maccross/build/tcl8.6.9/compat/strtoul.c
77c77
< while (TclIsSpaceProc(*p)) {
---
> while (isspace(UCHAR(*p))) {
Best regards
Michael
jan.nijtmansplain2020-01-05 19:41:39
Dup of [https://core.tcl-lang.org/tk/info/abd4abedd2]. Already fixed.
Log in (anonymous is fine) to add a comment.