Skip to content

Commit

Permalink
Revert previous target-dir change
Browse files Browse the repository at this point in the history
This doesn't actually work without some seriously hacky workarounds. A
proper solution involves placing everything in one cargo workspace. That
won't be practical until custom profiles are available (since the
native library/binary require panic=unwind and the rel requires
panic=abort) (see rust-lang/cargo#6988 for progress on that)
  • Loading branch information
aprilwade committed Nov 23, 2020
1 parent f322163 commit 97447f2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 0 additions & 3 deletions compile_to_ppc/.cargo/config
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
[build]
target-dir = "../target"

[target.powerpc-unknown-linux-gnu]
rustflags = ["-C", "relocation-model=static", "-C", "target-cpu=750"]
3 changes: 2 additions & 1 deletion generated/rel_files/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ fn invoke_cargo(ppc_manifest: &Path, package: &str)
.arg("-C")
.arg("target-cpu=750")
.env("RUSTC_BOOTSTRAP", "1")
.env("CARGO_TARGET_DIR", "../../target")
.env("CARGO_TARGET_DIR", "../../compile_to_ppc/target")
.output()
.expect("Failed to compile ppc crate");
if !output.status.success() {
Expand All @@ -49,6 +49,7 @@ fn main()
let ppc_manifest = ppc_dir.join("Cargo.toml");
let target_dir = ppc_dir
.join("..")
.join("compile_to_ppc")
.join("target")
.join("powerpc-unknown-linux-gnu")
.join("release");
Expand Down

0 comments on commit 97447f2

Please sign in to comment.