@@ -7,8 +7,8 @@ LIC_FILES_CHKSUM = "file://LICENSE.TXT;md5=27b14ab4ce08d04c3a9a5f0ed7997362"
|
||||
SRC_URI = "\
|
||||
https://static.rust-lang.org/dist/rustc-${PV}-src.tar.gz;name=rust \
|
||||
"
|
||||
SRC_URI[rust.md5sum] = "a48fef30353fc9daa70b484b690ce5db"
|
||||
SRC_URI[rust.sha256sum] = "a4015aacf4f6d8a8239253c4da46e7abaa8584f8214d1828d2ff0a8f56176869"
|
||||
|
||||
require rust-source-${PV}.inc
|
||||
|
||||
S = "${WORKDIR}/rustc-${PV}/src/compiler-rt"
|
||||
|
||||
|
||||
@@ -7,8 +7,8 @@ LIC_FILES_CHKSUM ="file://COPYRIGHT;md5=43e1f1fb9c0ee3af66693d8c4fecafa8"
|
||||
SRC_URI = "\
|
||||
https://static.rust-lang.org/dist/rustc-${PV}-src.tar.gz;name=rust \
|
||||
"
|
||||
SRC_URI[rust.md5sum] = "a48fef30353fc9daa70b484b690ce5db"
|
||||
SRC_URI[rust.sha256sum] = "a4015aacf4f6d8a8239253c4da46e7abaa8584f8214d1828d2ff0a8f56176869"
|
||||
|
||||
require rust-source-${PV}.inc
|
||||
|
||||
S = "${WORKDIR}/rustc-${PV}"
|
||||
|
||||
@@ -19,7 +19,7 @@ SRC_URI += "\
|
||||
crate-index://crates.io/${CARGO_INDEX_COMMIT} \
|
||||
"
|
||||
|
||||
DEPENDS += "compiler-rt"
|
||||
DEPENDS += "compiler-rt (=${PV})"
|
||||
|
||||
RUSTLIB_DEP = ""
|
||||
inherit cargo
|
||||
@@ -32,7 +32,7 @@ S = "${WORKDIR}/rustc-${PV}"
|
||||
do_compile_prepend () {
|
||||
cd ${S}/src/rustc/std_shim
|
||||
export CARGO_TARGET_DIR="${B}"
|
||||
export RUSTC_BOOTSTRAP_KEY="e8edd0fd"
|
||||
export RUSTC_BOOTSTRAP_KEY="${RS_KEY}"
|
||||
}
|
||||
|
||||
do_install () {
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
require rust.inc
|
||||
inherit cross
|
||||
|
||||
SRC_URI[rust.md5sum] = "a48fef30353fc9daa70b484b690ce5db"
|
||||
SRC_URI[rust.sha256sum] = "a4015aacf4f6d8a8239253c4da46e7abaa8584f8214d1828d2ff0a8f56176869"
|
||||
require rust-source-${PV}.inc
|
||||
|
||||
# Otherwise we'll depend on what we provide
|
||||
INHIBIT_DEFAULT_RUST_DEPS = "1"
|
||||
|
||||
@@ -1,4 +1,2 @@
|
||||
require rust-llvm.inc
|
||||
|
||||
SRC_URI[rust.md5sum] = "a48fef30353fc9daa70b484b690ce5db"
|
||||
SRC_URI[rust.sha256sum] = "a4015aacf4f6d8a8239253c4da46e7abaa8584f8214d1828d2ff0a8f56176869"
|
||||
require rust-source-${PV}.inc
|
||||
|
||||
@@ -1,13 +1,17 @@
|
||||
# Specifics for Rust 1.10.0
|
||||
|
||||
## snapshot info taken from rust/src/stage0.txt
|
||||
## TODO: find a way to add additional SRC_URIs based on the contents of an
|
||||
## earlier SRC_URI.
|
||||
RS_DATE = "2016-05-24"
|
||||
RS_VERSION = "1.9.0"
|
||||
RS_ARCH = "x86_64-unknown-linux-gnu"
|
||||
RS_KEY = "e8edd0fd"
|
||||
|
||||
RUST_SNAPSHOT = "rustc-${RS_VERSION}-${RS_ARCH}.tar.gz"
|
||||
RUST_SNAPSHOT_URI = "https://static.rust-lang.org/dist/${RS_DATE}/${RUST_SNAPSHOT}"
|
||||
RUST_SNAPSHOT = "rustc-${RS_VERSION}-${RUST_HOST_SYS}"
|
||||
|
||||
# These are x86_64-unknown-linux-gnu hashes, how can we add more?
|
||||
SRC_URI[rust-snapshot.md5sum] = "f1cf6d2fe15e4be18a08259f1540a4ae"
|
||||
SRC_URI[rust-snapshot.sha256sum] = "d0704d10237c66c3efafa6f7e5570c59a1d3fe5c6d99487540f90ebb37cd84c4"
|
||||
|
||||
SRC_URI[rust.md5sum] = "a48fef30353fc9daa70b484b690ce5db"
|
||||
SRC_URI[rust.sha256sum] = "a4015aacf4f6d8a8239253c4da46e7abaa8584f8214d1828d2ff0a8f56176869"
|
||||
|
||||
@@ -5,28 +5,16 @@ LICENSE = "MIT | Apache-2.0"
|
||||
LIC_FILES_CHKSUM ="file://COPYRIGHT;md5=43e1f1fb9c0ee3af66693d8c4fecafa8"
|
||||
|
||||
inherit rust
|
||||
require rust-snapshot-2016-05-24.inc
|
||||
|
||||
SRC_URI = "\
|
||||
https://static.rust-lang.org/dist/rustc-${PV}-src.tar.gz;name=rust \
|
||||
https://static.rust-lang.org/dist/${RUST_SNAPSHOT}.tar.gz;name=rust-snapshot \
|
||||
"
|
||||
|
||||
S = "${WORKDIR}/rustc-${PV}"
|
||||
|
||||
DEPENDS += "file-native"
|
||||
|
||||
PACKAGECONFIG ??= ""
|
||||
|
||||
# Controls whether we use the local rust to build.
|
||||
# By default, we use the rust-snapshot. In some cases (non-supported host
|
||||
# systems) this may not be possible. In other cases, it might be desirable
|
||||
# to have rust-cross built using rust-native.
|
||||
PACKAGECONFIG[local-rust] = ""
|
||||
|
||||
FETCH_STAGE0 = "${@bb.utils.contains('PACKAGECONFIG', 'local-rust', 'false', 'true', d)}"
|
||||
|
||||
SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'local-rust', '', '${RUST_SNAPSHOT_URI};unpack=0;name=rust-snapshot', d)}"
|
||||
|
||||
# We generate local targets, and need to be able to locate them
|
||||
export RUST_TARGET_PATH="${WORKDIR}/targets/"
|
||||
|
||||
@@ -394,18 +382,7 @@ do_configure () {
|
||||
# where we're reinstalling the compiler. May want to try for a real
|
||||
# path based on bitbake vars
|
||||
# Also will be wrong when relative libdir and/or bindir aren't 'bin' and 'lib'.
|
||||
local_rust_root=/not/set/do/not/use
|
||||
if ${FETCH_STAGE0}; then
|
||||
mkdir -p dl
|
||||
tar -xf ${WORKDIR}/${RUST_SNAPSHOT} -C dl
|
||||
./dl/rustc-${RS_VERSION}-${RS_ARCH}/install.sh --prefix=$PWD/dl
|
||||
local_rust_root="$PWD/dl"
|
||||
elif which rustc >/dev/null 2>&1; then
|
||||
local_rustc=$(which rustc)
|
||||
if [ -n "$local_rustc" ]; then
|
||||
local_rust_root=$(dirname $(dirname $local_rustc))
|
||||
fi
|
||||
fi
|
||||
local_rust_root="$PWD/dl"
|
||||
|
||||
# - rpath is required otherwise rustc fails to resolve symbols
|
||||
# - submodule management is done by bitbake's fetching
|
||||
@@ -432,7 +409,8 @@ do_configure () {
|
||||
"--libdir=${libdir}" \
|
||||
"--bindir=${bindir}" \
|
||||
"--platform-cfg=${WORKDIR}/mk-cfg/" \
|
||||
"--enable-local-rust --local-rust-root=$local_rust_root" \
|
||||
"--enable-local-rust" \
|
||||
"--local-rust-root=${WORKDIR}/${RUST_SNAPSHOT}/rustc" \
|
||||
${EXTRA_OECONF}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,25 +1,23 @@
|
||||
inherit rust-installer
|
||||
require rust.inc
|
||||
require rust-source-${PV}.inc
|
||||
|
||||
SRC_URI += " \
|
||||
file://rust/0001-Add-config-for-musl-based-arm-builds.patch \
|
||||
file://rust/0002-Target-add-default-target.json-path-libdir-rust-targ.patch \
|
||||
file://rust/0003-mk-for-stage0-use-RUSTFLAGS-to-override-target-libs-.patch \
|
||||
file://rust/0004-mk-add-missing-CFG_LIBDIR_RELATIVE.patch \
|
||||
file://rust/0005-configure-support-bindir-and-extend-libdir-to-non-bl.patch \
|
||||
file://rust/0006-std-thread_local-workaround-for-NULL-__dso_handle.patch \
|
||||
file://rust/0007-mk-install-use-disable-rewrite-paths.patch \
|
||||
file://rust/0008-Allow-overriding-crate_hash-with-C-crate_hash.patch \
|
||||
file://rust/0009-mk-platform.mk-pass-C-crate_hash-to-builds.patch \
|
||||
file://rust/0010-mk-allow-changing-the-platform-configuration-source-.patch \
|
||||
file://rust/0011-Get-rid-of-the-.note-interpretation-of-rustc-dylib-m.patch \
|
||||
file://rust-installer/0001-add-option-to-disable-rewriting-of-install-paths.patch;patchdir=src/rust-installer \
|
||||
file://rust-${PV}/0001-Add-config-for-musl-based-arm-builds.patch \
|
||||
file://rust-${PV}/0002-Target-add-default-target.json-path-libdir-rust-targ.patch \
|
||||
file://rust-${PV}/0003-mk-for-stage0-use-RUSTFLAGS-to-override-target-libs-.patch \
|
||||
file://rust-${PV}/0004-mk-add-missing-CFG_LIBDIR_RELATIVE.patch \
|
||||
file://rust-${PV}/0005-configure-support-bindir-and-extend-libdir-to-non-bl.patch \
|
||||
file://rust-${PV}/0006-std-thread_local-workaround-for-NULL-__dso_handle.patch \
|
||||
file://rust-${PV}/0007-mk-install-use-disable-rewrite-paths.patch \
|
||||
file://rust-${PV}/0008-Allow-overriding-crate_hash-with-C-crate_hash.patch \
|
||||
file://rust-${PV}/0009-mk-platform.mk-pass-C-crate_hash-to-builds.patch \
|
||||
file://rust-${PV}/0010-mk-allow-changing-the-platform-configuration-source-.patch \
|
||||
file://rust-${PV}/0011-Get-rid-of-the-.note-interpretation-of-rustc-dylib-m.patch \
|
||||
file://rust-installer-${PV}/0001-add-option-to-disable-rewriting-of-install-paths.patch;patchdir=src/rust-installer \
|
||||
"
|
||||
|
||||
SRC_URI[rust.md5sum] = "a48fef30353fc9daa70b484b690ce5db"
|
||||
SRC_URI[rust.sha256sum] = "a4015aacf4f6d8a8239253c4da46e7abaa8584f8214d1828d2ff0a8f56176869"
|
||||
|
||||
DEPENDS += "rust-llvm"
|
||||
DEPENDS += "rust-llvm (=${PV})"
|
||||
|
||||
# Otherwise we'll depend on what we provide
|
||||
INHIBIT_DEFAULT_RUST_DEPS_class-native = "1"
|
||||
|
||||
Reference in New Issue
Block a user