Skip to content

remove build.rs, use CARGO_MANIFEST_DIR env directly #22

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lblasc
Copy link

@lblasc lblasc commented May 14, 2025

CARGO_MANIFEST_DIR path can vary when crate is compiled and later used in crates like rust-headless-chrome.

This resolves issue I'm having with nix, most likely bazel will have the same issue:

thread 'main' panicked at src/compile.rs:1273:50:
called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }
stack backtrace:
   0: rust_begin_unwind
   1: aws_lc_0_28_0_aes_gcm_decrypt_avx512
             at /build/aws-lc-sys-0.28.0/aws-lc/generated-src/linux-x86_64/crypto/fipsmodule/aesni-gcm-avx512.S:20266:0
   2: aws_lc_0_28_0_aes_gcm_decrypt_avx512
             at /build/aws-lc-sys-0.28.0/aws-lc/generated-src/linux-x86_64/crypto/fipsmodule/aesni-gcm-avx512.S:20698:0
   3: aws_lc_0_28_0_aes_gcm_decrypt_avx512
             at /build/aws-lc-sys-0.28.0/aws-lc/generated-src/linux-x86_64/crypto/fipsmodule/aesni-gcm-avx512.S:58398:0
   4: aws_lc_0_28_0_aes_gcm_decrypt_avx512
             at /build/aws-lc-sys-0.28.0/aws-lc/generated-src/linux-x86_64/crypto/fipsmodule/aesni-gcm-avx512.S:58510:0
   5: aws_lc_0_28_0_aes_gcm_decrypt_avx512
             at /build/aws-lc-sys-0.28.0/aws-lc/generated-src/linux-x86_64/crypto/fipsmodule/aesni-gcm-avx512.S:22940:0
   6: build_script_build::main
             at ./build.rs:4:5
   7: core::ops::function::FnOnce::call_once
             at /build/rustc-1.86.0-src/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

@lblasc lblasc force-pushed the remove-build-rs-upstream branch from 774ab72 to 1ec93f7 Compare May 14, 2025 07:09
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

Successfully merging this pull request may close these issues.

1 participant