Description of problem: Building newt 0.52.14 fails with tcl 8.6.0 with the message "error: ‘Tcl_Interp’ has no member named ‘result’" and other similar errors. Version-Release number of selected component (if applicable): 0.52.14 How reproducible: Always Steps to Reproduce: 1. Install Tcl 8.6 2. Try to build newt 0.52.14 against Tcl 8.6 Actual results: error: ‘Tcl_Interp’ has no member named ‘result’ Expected results: Successful build. Additional info: Workaround: add "-DUSE_INTERP_RESULT" to CPPFLAGS. Solution: stop using fields inside Tcl_Interp; they are deprecated and the above workaround will be removed in a future version of Tcl. MacPorts bug report: https://trac.macports.org/ticket/37725 Your issue tracker required me to fill in the Version field, so I left it at its default, although I have no idea what version of Redhat Linux, if any, contains this version of newt; I do not use Redhat Linux.
Thanks for the report. In git, the CPPFLAGS now have -DUSE_INTERP_RESULT when building with tcl support. Patches removing the use of the result field are welcome.
Created attachment 1610645 [details] Patch to make whiptcl.c work with Tcl 8.6 Replaced interp->result calls with updated Tcl functions
Created attachment 1610646 [details] Patch for newt.spec to include whiptcl.so Enables Tcl support for newt
Created attachment 1610649 [details] Tcl script to test whiptcl functionality in Newt
Thanks for the patch. I'm getting different warnings like: whiptcl.c:141:10: warning: passing argument 1 of ‘sprintf’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] whiptcl.c:149:27: warning: passing argument 2 of ‘Tcl_SetObjResult’ from incompatible pointer type [-Wincompatible-pointer-types] I'm not familiar with the API and I'm not sure if it would be ok to just cast the arguments. If you have a different patch, please submit it on https://pagure.io/newt.
It's OK to ignore those warnings. I built the newt, newt-devel, python2-newt and python3-newt packages for Fedora 30 from the newt SRPM using that patch and the Tcl functionality worked fine.