Skip to content

Commit d186bc0

Browse files
authored
igvm_c/Makefile: fix path for cross compilation (#92)
When cross-compiling with `CARGO_BUILD_TARGET`, the build output path changes to include the target triple (e.g., `target/<triple>/release/`). This leads to compilation errors as `TARGET_PATH` does not take that into account. Update `TARGET_PATH` to include the target triple if set. Signed-off-by: Luigi Leonardi <leonardi@redhat.com>
1 parent 2ad2b2c commit d186bc0

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

igvm_c/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ IGVM_DIR := $(API_DIR)/..
99
TARGET_DIR ?= target_c
1010

1111
ifdef RELEASE
12-
TARGET_PATH="$(IGVM_DIR)/$(TARGET_DIR)/release"
12+
TARGET_PATH="$(IGVM_DIR)/$(TARGET_DIR)/$(CARGO_BUILD_TARGET)/release"
1313
else
14-
TARGET_PATH="$(IGVM_DIR)/$(TARGET_DIR)/debug"
14+
TARGET_PATH="$(IGVM_DIR)/$(TARGET_DIR)/$(CARGO_BUILD_TARGET)/debug"
1515
endif
1616

1717
PREFIX ?= /usr

0 commit comments

Comments
 (0)