Open smaudet opened 7 months ago
Maybe crate inwelling failed to get its job done. It’s quite annoying. Would you please run cargo clean -p clib
then cargo build
to see if it compiles?
After cargo clean -p clib
, I did:
cargo build
Compiling clib v0.2.4
Compiling tcl v0.1.9
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_IsSafe
in crate clib
--> /home/smaudet/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:629:19
|
629 | clib::Tcl_IsSafe( self.as_ptr() ) != 0
| ^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_MakeSafe
in crate clib
--> /home/smaudet/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:653:19
|
653 | clib::Tcl_MakeSafe( self.as_ptr() ).code_to_result( self )
| ^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_CreateSlave
in crate clib
--> /home/smaudet/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:678:54
|
678 | Ok( Interpreter( Interp::from_raw( clib::Tcl_CreateSlave(
| ^^^^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_GetSlave
in crate clib
--> /home/smaudet/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:707:33
|
707 | Interp::from_raw( clib::Tcl_GetSlave(
| ^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_GetMaster
in crate clib
--> /home/smaudet/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:731:33
|
731 | Interp::from_raw( clib::Tcl_GetMaster(
| ^^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_ExposeCommand
in crate clib
--> /home/smaudet/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:757:19
|
757 | clib::Tcl_ExposeCommand(
| ^^^^^^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_HideCommand
in crate clib
--> /home/smaudet/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:788:19
|
788 | clib::Tcl_HideCommand(
| ^^^^^^^^^^^^^^^ not found in clib
For more information about this error, try rustc --explain E0425
.
error: could not compile tcl
(lib) due to 7 previous errors
I'm thinking whatever clib does is not enough. It seems to be causing problems, maybe there is something else to replace it with?
Hello same problem for me.
$ cargo version
cargo 1.77.0 (3fe68eabf 2024-02-29)
$ cargo clean -p clib
Removed 21 files, 37.4MiB total
$ cargo build
Compiling clib v0.2.4
Compiling tcl v0.1.9
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_IsSafe
in crate clib
--> /home/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:629:19
|
629 | clib::Tcl_IsSafe( self.as_ptr() ) != 0
| ^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_MakeSafe
in crate clib
--> /home/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:653:19
|
653 | clib::Tcl_MakeSafe( self.as_ptr() ).code_to_result( self )
| ^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_CreateSlave
in crate clib
--> /home/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:678:54
|
678 | Ok( Interpreter( Interp::from_raw( clib::Tcl_CreateSlave(
| ^^^^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_GetSlave
in crate clib
--> /home/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:707:33
|
707 | Interp::from_raw( clib::Tcl_GetSlave(
| ^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_GetMaster
in crate clib
--> /home/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:731:33
|
731 | Interp::from_raw( clib::Tcl_GetMaster(
| ^^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_ExposeCommand
in crate clib
--> /home/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:757:19
|
757 | clib::Tcl_ExposeCommand(
| ^^^^^^^^^^^^^^^^^ not found in clib
error[E0425]: cannot find function, tuple struct or tuple variant Tcl_HideCommand
in crate clib
--> /home/myuser/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tcl-0.1.9/src/interp.rs:788:19
|
788 | clib::Tcl_HideCommand(
| ^^^^^^^^^^^^^^^ not found in clib
For more information about this error, try rustc --explain E0425
.
error: could not compile tcl
(lib) due to 7 previous errors
I’m quite busy in past several weeks. Recently I will try to update clib to see if new version will fix your problems.
With Ubuntu 22.04 I needed to install tcl-dev and tk-dev:
sudo apt install tcl-dev tk-dev
This is similar to troubles I have on a Mac.
It appears that older Tcl/Tk libraries don't have Tcl_IsSafe and similar, so it's not showing up in clib, which is preventing this package from building. For Linux, I think @pgarpgar has the right fix. On the Mac, I'm still fighting with this -- Mac ships with ancient Tcl/Tk, and every step of the build toolchain seems to opt for that instead of a current version that I've compiled. System libraries on the Mac are locked down, so I can't easily replace the old stuff. :-/
Does not work out of the box:
Cargo version: 1.76.0 rust version: 1.76.0
Cargo.toml:
tk_ui.rs: