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

corrosion_import_crate: issue with PROFILE argument in combination with CRATES #495

Closed
Felix-El opened this issue Apr 2, 2024 · 0 comments · Fixed by #496
Closed

corrosion_import_crate: issue with PROFILE argument in combination with CRATES #495

Felix-El opened this issue Apr 2, 2024 · 0 comments · Fixed by #496

Comments

@Felix-El
Copy link
Contributor

Felix-El commented Apr 2, 2024

I'm trying to invoke import like so:

corrosion_import_crate(MANIFEST_PATH ${CMAKE_CURRENT_BINARY_DIR}/git/Cargo.toml
  PROFILE release
  CRATES my-crate
)

however I get:

`corrosion_import_crate()` was called with the `CRATES` parameter set to `my-cratePROFILErelease`.
Corrosion will only attempt to import packages matching names from this list.

It looks like the issue is with passing PROFILE argument to _generator_add_cargo_targets which does not seem to take such argument:

_generator_add_cargo_targets(
MANIFEST_PATH
"${COR_MANIFEST_PATH}"
IMPORTED_CRATES
imported_crates
${crate_allowlist}
${crate_types}
${cargo_profile}
${no_linker_override}
)

With the forwarding removed it seems to work. Is it the right thing to do?

@jschwe jschwe changed the title corrosion_import_crate: issue with PROFILE argument corrosion_import_crate: issue with PROFILE argument in combination with CRATES Apr 3, 2024
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 a pull request may close this issue.

1 participant