Skip to content

target/cxxbridge/ not created when CARGO_TARGET_DIR is set #1680

@pantos9000

Description

@pantos9000

Hi,

I was able to reproduce this with the demo in the latest version, as well as the current main branch.

  • cd into the demo folder
  • cargo build works (../target/cxxbridge/ exists)
  • cargo build --target-dir foo works (./foo/cxxbridge/ exists)
  • CARGO_TARGET_DIR=bar cargo build does not work (./bar/ exists, but ./bar/cxxbridge/ does not)

This is easy to work around with the --target-dir parameter, but the env var is nicer for creating an environment where all cargo commands use the same target dir. The parameter is easy to forget.

BTW, awesome crate! Thanks for creating it!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions