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

Compilation error due to proc-macro not supported #1177

Closed
nitnelave opened this issue Sep 10, 2022 · 1 comment
Closed

Compilation error due to proc-macro not supported #1177

nitnelave opened this issue Sep 10, 2022 · 1 comment

Comments

@nitnelave
Copy link

🐛 Bug description

cargo install wasm-pack
    Updating crates.io index
[...]
  Downloaded filetime v0.2.17
error: failed to compile `wasm-pack v0.10.3`, intermediate artifacts can be found at `/tmp/cargo-install8SJwiv`

Caused by:
  cannot produce proc-macro for `failure_derive v0.1.8` as the target `x86_64-unknown-linux-gnu` does not support these crate types

👟 Steps to reproduce

It can be reproduced in Github actions with the following script:

jobs:
  build:
    runs-on: ubuntu-latest
    container:
      image: rust:1.62
      env:
        CARGO_TERM_COLOR: always
        RUSTFLAGS: -Ctarget-feature=+crt-static
    steps:
      - name: install wasm-pack with cargo
        run: cargo install wasm-pack

🌍 Your environment

wasm-pack version: 0.10.3
rustc version: 1.62
container: ubuntu, x86_64

@nitnelave
Copy link
Author

Ah, I found rust-lang/rust#78210, so it seems it's related to the RUSTFLAGS. It works if I remove the env variable (which was only intended for my own code anyway).

Closing this.

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

1 participant