diff --git a/.cargo/config b/.cargo/config index cc387d31..7c62c97b 100644 --- a/.cargo/config +++ b/.cargo/config @@ -1,3 +1,3 @@ [target.x86_64-unknown-redox] -linker = "x86_64-elf-redox-gcc" +linker = "x86_64-unknown-redox-gcc" rustflags = [] diff --git a/config.sh b/config.sh index ad8d6307..a07130ed 100755 --- a/config.sh +++ b/config.sh @@ -4,13 +4,12 @@ set -e # Configuration ARCH=x86_64 export TARGET=$ARCH-unknown-redox -HOST=$ARCH-elf-redox -RUST_HOST=$ARCH-unknown-redox +HOST=$TARGET # Automatic variables ROOT="$(cd `dirname "$0"` && pwd)" REPO="$ROOT/repo/$TARGET" -export CC="x86_64-elf-redox-gcc" +export CC="$HOST-gcc" export XARGO_HOME="$ROOT/xargo" if [[ "$OSTYPE" == "darwin"* ]]; then diff --git a/recipes/rust/recipe.sh b/recipes/rust/recipe.sh index e10d0749..389d5bd9 100644 --- a/recipes/rust/recipe.sh +++ b/recipes/rust/recipe.sh @@ -54,10 +54,10 @@ function recipe_clean { function recipe_stage { binpath="$1/bin" - libpath="$1/lib/rustlib/${RUST_HOST}/lib" + libpath="$1/lib/rustlib/${TARGET}/lib" mkdir -p "$binpath" "$libpath" - cp -fv "build/${RUST_HOST}/stage2/bin/rustc" "$binpath" + cp -fv "build/${TARGET}/stage2/bin/rustc" "$binpath" ${HOST}-strip "$binpath/rustc" - cp -fv $(find build/${RUST_HOST}/stage2/lib/rustlib/${RUST_HOST}/lib/ -type f | grep -v librustc) "$libpath" + cp -fv $(find build/${TARGET}/stage2/lib/rustlib/${TARGET}/lib/ -type f | grep -v librustc) "$libpath" skip=1 }