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

where .cargo/config.toml should be located #96

Open
8 tasks
uncomfyhalomacro opened this issue Aug 18, 2024 · 0 comments
Open
8 tasks

where .cargo/config.toml should be located #96

uncomfyhalomacro opened this issue Aug 18, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@uncomfyhalomacro
Copy link
Collaborator

uncomfyhalomacro commented Aug 18, 2024

Based on my observation obs-service-cargo will generate .cargo/config.toml at the root of the project directory. This comes with some caveats that we have to do that --manifest-path=<path-to-Cargo.toml> as an additional flag on the specfile. This is not ideal.

So based on https://doc.rust-lang.org/cargo/reference/config.html#hierarchical-structure, I should

  • If it's a workspace configuration, use the workspace Cargo.toml's location as the location for the .cargo/config.toml
  • Otherwise, we should put .cargo/config.toml for each location of the Cargo.toml for each crate found or used.

Relevant openSUSE package: monorepo-like Rust package such as python-tokenizers

Additionally, vendor seems to not extract at the exact path. Is this caused by the change when we merged a PR that modifies mtime in the tarball for reproducible builds

I remembered i designed this in a way where if it is extracted, they're extracted in the correct path... (i might be wrong so imma investigate this lol)

TODO

  • Investigate Fix #64: Make tarballs reproducible #78
    • Fix pathing. (Investigate and add findings)
    • Fix extracting. (Investigate and add findings)
  • Add tests
    • Monorepo packages e.g. python-tokenizers
    • Workspaces e.g. wezterm, zellij
@uncomfyhalomacro uncomfyhalomacro self-assigned this Aug 18, 2024
@uncomfyhalomacro uncomfyhalomacro added the bug Something isn't working label Aug 18, 2024
@uncomfyhalomacro uncomfyhalomacro mentioned this issue Aug 19, 2024
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant