Skip to content

Commit 17a313a

Browse files
committed
xx-cargo: fix vendor for pkg-config and clang
1 parent 3d00d09 commit 17a313a

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

base/xx-cargo

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ if [ -n "$rustup" ] || [ ! -f /etc/alpine-release ]; then
5858
fi
5959

6060
if [ ! -f "$done_file" ]; then
61-
xx-clang --setup-target-triple
61+
XX_VENDOR=$vendor xx-clang --setup-target-triple
6262
if [ ! -d "$(rustc --print sysroot)/lib/rustlib/$(xx-info)" ]; then
6363
if [ -n "$rustup" ]; then
6464
execSilent rustup target add "$(xx-info)"
@@ -73,11 +73,11 @@ if [ ! -f "$done_file" ]; then
7373
touch "$done_file"
7474
fi
7575

76-
export "CARGO_TARGET_$(xx-info | tr '[:lower:]' '[:upper:]' | tr - _)_LINKER=$(xx-info)-clang"
76+
export "CARGO_TARGET_$(xx-info | tr '[:lower:]' '[:upper:]' | tr - _)_LINKER=$(XX_VENDOR=$vendor xx-info)-clang"
7777
if [ -n "$XX_RUSTFLAGS" ]; then
7878
export "CARGO_TARGET_$(xx-info | tr '[:lower:]' '[:upper:]' | tr - _)_RUSTFLAGS=$XX_RUSTFLAGS"
7979
fi
80-
export "CC_$(xx-info | tr - _)=$(xx-info)-clang"
80+
export "CC_$(xx-info | tr - _)=$(XX_VENDOR=$vendor xx-info)-clang"
8181

8282
if which "qemu-$(RISCV64_TARGET_ARCH='' ARM_TARGET_ARCH='' xx-info march)" >/dev/null 2>&1; then
8383
export "CARGO_TARGET_$(xx-info | tr '[:lower:]' '[:upper:]' | tr - _)_RUNNER=qemu-$(RISCV64_TARGET_ARCH='' ARM_TARGET_ARCH='' xx-info march)"
@@ -88,8 +88,8 @@ if which "qemu-$(RISCV64_TARGET_ARCH='' ARM_TARGET_ARCH='' xx-info march)" >/dev
8888
fi
8989
fi
9090

91-
if command -v "$(xx-info)-pkg-config" >/dev/null 2>/dev/null; then
92-
export "PKG_CONFIG=$(xx-info)-pkg-config"
91+
if command -v "$(XX_VENDOR=$vendor xx-info)-pkg-config" >/dev/null 2>/dev/null; then
92+
export "PKG_CONFIG=$(XX_VENDOR=$vendor xx-info)-pkg-config"
9393
fi
9494

9595
if [ -n "$printtarget" ]; then

0 commit comments

Comments
 (0)