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

rustup toolchain add stable, fails with Illegal Instruction 4, MacOs El Capitan, 10.11.6 #3264

Closed
aeveltstra opened this issue Mar 12, 2023 · 2 comments
Labels

Comments

@aeveltstra
Copy link

Problem

Attempting to install rust. Using latest stable release of rustup.sh downloaded from https://rustup.org/.

Initial installation of default profile fails to install rust-doc. Attempted installation of minimal profile succeeded. Default stable toolchain installed, rustc is available. When attempting to use rustc to build the cryptography library for python, its build tools say they can't find rustc.

Now I checked to make sure rustc existed with
$ which rustc

and it said:
$ /Users/admin/.cargo/bin/rustc

So it both does and does not exist.

Steps

I try and install rustc, despite it already existing:
$ rustup component add rustc

And it says:
$ Missing manifest in toolchain 'stable-x86_64-apple-darwin'

So I remove the toolchain and try to add it again:
$ rustup toolchain add stable

And it says:
$ info: installing component 'rust-std'
$ 2.9 MiB / 28.4 MiB ( 10 %) 0 B/s in 1s ETA: UnknownIllegal instruction: 4

Possible Solution(s)

No clue. Make something that works for MacOs El Capitan?

Notes

No response

Rustup version

rustup 1.25.2 (fae52a197 2023-02-01)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: syncing channel updates for 'stable-x86_64-apple-darwin'
info: latest update on 2023-03-09, rust version 1.68.0 (2c8cc3432 2023-03-06)
info: downloading component 'rustc'
info: downloading component 'cargo'
info: downloading component 'rust-std'
info: downloading component 'rust-docs'
info: downloading component 'rustfmt'
info: downloading component 'clippy'
info: removing previous version of component 'rustc'
warning: during uninstall component rustc was not found
info: removing previous version of component 'cargo'
warning: during uninstall component cargo was not found
info: removing previous version of component 'rust-std'
warning: during uninstall component rust-std was not found
info: removing previous version of component 'rust-docs'
warning: during uninstall component rust-docs was not found
info: removing previous version of component 'rustfmt'
warning: during uninstall component rustfmt was not found
info: removing previous version of component 'clippy'
warning: during uninstall component clippy was not found
info: installing component 'rustc'
Illegal instruction: 4

Installed toolchains

Default host: x86_64-apple-darwin
rustup home:  /Users/admin/.rustup

info: syncing channel updates for 'stable-x86_64-apple-darwin'
info: latest update on 2023-03-09, rust version 1.68.0 (2c8cc3432 2023-03-06)
stable-x86_64-apple-darwin (default)
(rustc does not exist)
@aeveltstra aeveltstra added the bug label Mar 12, 2023
@rbtcollins
Copy link
Contributor

We aim to support x86_64-apple-darwin 64-bit macOS (10.7+, Lion+) so Capitan should be supported.

Googling tells me that illegal instruction errors on Mac are common when a program is compiled on a newer version without explicitly asking for compatibility with older versions. https://stackoverflow.com/questions/14268887/what-is-the-illegal-instruction-4-error-and-why-does-mmacosx-version-min-10

So we need a patch to our build rules to configure that correctly.

@rami3l
Copy link
Member

rami3l commented Jul 10, 2024

I'm closing this as outdated now, since #3710 has set the minimally supported macOS version to v10.12. At the moment of writing, this is coherent with the OS requirements listed in https://doc.rust-lang.org/nightly/rustc/platform-support.html.

@rami3l rami3l closed this as not planned Won't fix, can't repro, duplicate, stale Jul 10, 2024
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

3 participants