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

[PTX] error: the option Z is only accepted on the nightly compiler #5

Closed
rustyx opened this issue Nov 30, 2020 · 5 comments
Closed

Comments

@rustyx
Copy link

rustyx commented Nov 30, 2020

Getting the following error when running cargo install --path .

error: the option Z is only accepted on the nightly compiler

Full log:

error: failed to compile `tor-v3-vanity v0.1.0 (/home/user/tor-v3-vanity)`, intermediate artifacts can be found at `/home/user/tor-v3-vanity/target`

Caused by:
  failed to run custom build command for `tor-v3-vanity v0.1.0 (/home/user/tor-v3-vanity)`

Caused by:
  process didn't exit successfully: `/home/user/tor-v3-vanity/target/release/build/tor-v3-vanity-ffe1e29dcc00d7f6/build-script-build` (exit code: 1)
  --- stdout
  cargo:rustc-link-search=native=/usr/local/cuda/lib64/

  --- stderr
  [PTX] Unable to build a PTX crate!
  [PTX] warning: unused manifest key: build
  [PTX]  Downloading crates ...
  [PTX]   Downloaded syn v1.0.36
  [PTX]   Downloaded proc-macro2 v1.0.19
  [PTX]   Downloaded ed25519-compact v0.1.6
  [PTX]    Compiling proc-macro2 v1.0.19
  [PTX]    Compiling unicode-xid v0.2.1
  [PTX]    Compiling syn v1.0.36
  [PTX]    Compiling byteorder v1.3.4
  [PTX]    Compiling ed25519-compact v0.1.6
  [PTX]    Compiling rustacuda_core v0.1.2
  [PTX]    Compiling quote v1.0.7
  [PTX]    Compiling rustacuda_derive v0.1.2
  [PTX]    Compiling tor-v3-vanity-core v0.1.0 (/home/user/tor-v3-vanity/core)
  [PTX] error: the option `Z` is only accepted on the nightly compiler
  [PTX]
  [PTX] error: could not compile `tor-v3-vanity-core`
  [PTX]
@dr-bonez
Copy link
Owner

dr-bonez commented Dec 4, 2020

I am unable to reproduce. What version of rust are you running? On what system?

@rustyx
Copy link
Author

rustyx commented Dec 4, 2020

rustc 1.48.0 (7eac88abb 2020-11-16) on Debian 10 x86_64

@dr-bonez
Copy link
Owner

dr-bonez commented Dec 6, 2020

My mistake, it seems I had rustup set to nightly on my nvidia box. It seems that ptx builder requires nightly for now. Go ahead and run cargo +nightly install --path .
I'll update the docs.

@rustyx
Copy link
Author

rustyx commented Dec 6, 2020

Thanks, I already figured I had to switch to the nightly rust version.

@rustyx rustyx closed this as completed Dec 6, 2020
@kvtb
Copy link

kvtb commented Feb 7, 2022

It seems that the current nightly (1.60-nightly since rust-lang/cargo#10258) ignores CARGO_BUILD_PIPELINING=false

// Workaround for "crate required to be available in rlib format" bug
std::env::set_var("CARGO_BUILD_PIPELINING", "false");

So we need

  1. nightly to avoid "the option Z is only accepted on the nightly compiler"
  2. quite old compiler which accepts CARGO_BUILD_PIPELINING=false.

It is sort of a deadlock: a year-old Rust-nightly is required to build the project.

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

No branches or pull requests

3 participants