Try using `dynlib` as desrbiced in <https://nim-lang.org/docs/manual.html#foreign-function-interface-dynlib-pragma-for-import>.
It should look like this : proc Tcl_Eval(interp: pTcl_Interp, script: cstring): int {.cdecl, importc:"Tcl_Eval", dynlib:"libtcl(|8.5|8.4|8.3).so.(1|0)".} Run