Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error[E0425]: cannot find value term in this scope #115

Closed
yurivict opened this issue Jul 3, 2023 · 7 comments
Closed

error[E0425]: cannot find value term in this scope #115

yurivict opened this issue Jul 3, 2023 · 7 comments
Labels

Comments

@yurivict
Copy link

yurivict commented Jul 3, 2023

Build fails:

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:286:9
    |
286 |         term.c_iflag |= libc::IUTF8;
    |         ^^^^ not found in this scope

error[E0425]: cannot find value `IUTF8` in crate `libc`
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:286:31
    |
286 |         term.c_iflag |= libc::IUTF8;
    |                               ^^^^^ not found in `libc`

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:290:5
    |
290 |     term.c_cc[libc::VEOF] = 4;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:291:5
    |
291 |     term.c_cc[libc::VEOL] = 255;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:292:5
    |
292 |     term.c_cc[libc::VEOL2] = 255;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:293:5
    |
293 |     term.c_cc[libc::VERASE] = 0x7f;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:294:5
    |
294 |     term.c_cc[libc::VWERASE] = 23;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:295:5
    |
295 |     term.c_cc[libc::VKILL] = 21;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:296:5
    |
296 |     term.c_cc[libc::VREPRINT] = 18;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:297:5
    |
297 |     term.c_cc[libc::VINTR] = 3;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:298:5
    |
298 |     term.c_cc[libc::VQUIT] = 0x1c;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:299:5
    |
299 |     term.c_cc[libc::VSUSP] = 26;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:300:5
    |
300 |     term.c_cc[libc::VSTART] = 17;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:301:5
    |
301 |     term.c_cc[libc::VSTOP] = 19;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:302:5
    |
302 |     term.c_cc[libc::VLNEXT] = 22;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:303:5
    |
303 |     term.c_cc[libc::VDISCARD] = 15;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:304:5
    |
304 |     term.c_cc[libc::VMIN] = 1;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:305:5
    |
305 |     term.c_cc[libc::VTIME] = 0;
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `term` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:313:5
    |
313 |     term
    |     ^^^^ not found in this scope

error[E0425]: cannot find value `TIOCSWINSZ` in this scope
   --> /usr/ports/x11/rio/work/rio-0.0.8/cargo-crates/teletypewriter-2.0.1/src/unix/mod.rs:413:44
    |
413 |         match unsafe { libc::ioctl(**self, TIOCSWINSZ, &winsize as *const _) } {
    |                                            ^^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |

The "teletypewriter" crate has this repository set as source.

Version: 0.0.8
rust-1.70.0
FreeBSD 13.2

@raphamorim
Copy link
Owner

raphamorim commented Jul 3, 2023

Thanks for bringing it up @yurivict

Rio doesn't support FreeBSD (yet) and that's part of the reason. I think shouldn't be much work to add the support, mostly of work is missing is regarding update the teletypewriter to support FreeBSD.

I have updated the main, would mind try again (with local teletypewriter)?

@yurivict
Copy link
Author

yurivict commented Jul 3, 2023

I have updated the main, would mind try again (with local teletypewriter)?

I don't know how to compile it with local teletypewriter. Cargo.lock requires external teletypewriter.

@raphamorim
Copy link
Owner

Gotcha! updated in the main to point for local teletypewriter, just a pull should be enough to use the changes.

@yurivict
Copy link
Author

yurivict commented Jul 3, 2023

Now it fails like this:

error[E0425]: cannot find value `IUTF8` in crate `libc`
   --> teletypewriter/src/unix/mod.rs:288:31
    |
288 |         term.c_iflag |= libc::IUTF8;
    |                               ^^^^^ not found in `libc`

error[E0560]: struct `termios` has no field named `c_line`
   --> teletypewriter/src/unix/mod.rs:265:9
    |
265 |         c_line: 0,
    |         ^^^^^^ `termios` does not have this field
    |
    = note: available fields are: `c_iflag`, `c_oflag`, `c_cflag`, `c_lflag`, `c_cc` ... and 2 others

Some errors have detailed explanations: E0425, E0560.
For more information about an error, try `rustc --explain E0425`.
error: could not compile `teletypewriter` (lib) due to 2 previous errors

raphamorim added a commit that referenced this issue Jul 3, 2023
@raphamorim
Copy link
Owner

Updated @yurivict (if doesn't work maybe I can try to setup and test in a FreeBSD)

@yurivict
Copy link
Author

yurivict commented Jul 3, 2023

It works now.
Thank you for your help, and for your positive attitude!

Yuri

@yurivict yurivict closed this as completed Jul 3, 2023
@raphamorim
Copy link
Owner

That's great, thanks @yurivict !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants