@@ -1,7 +1,6 @@
|
||||
inherit rust-vars
|
||||
# add crate fetch support
|
||||
inherit crate-fetch
|
||||
inherit rust-triples
|
||||
inherit rust-common
|
||||
|
||||
# the binary we will use
|
||||
CARGO = "cargo"
|
||||
|
||||
@@ -1,4 +1,14 @@
|
||||
# Responseible for taking Yocto triples and converting it to Rust triples
|
||||
# Common variables used by all Rust builds
|
||||
export rustlibdir = "${libdir}/rust"
|
||||
FILES_${PN} += "${rustlibdir}/*.so"
|
||||
FILES_${PN}-dev += "${rustlibdir}/*.rlib"
|
||||
FILES_${PN}-dbg += "${rustlibdir}/.debug"
|
||||
|
||||
RUSTLIB = "-L ${STAGING_LIBDIR}/rust"
|
||||
RUSTFLAGS += "-C rpath -C crate_hash=${BB_TASKHASH} ${RUSTLIB}"
|
||||
RUSTLIB_DEP ?= "libstd-rs"
|
||||
|
||||
# Responsible for taking Yocto triples and converting it to Rust triples
|
||||
|
||||
def rust_base_triple(d, thing):
|
||||
'''
|
||||
@@ -1,15 +0,0 @@
|
||||
# Rust installer isn't very nice and drops a bunch of junk in our filesystem,
|
||||
# clean it up after the install.
|
||||
|
||||
rust_installer_do_install () {
|
||||
rm ${D}/${libdir}/rustlib/install.log
|
||||
rm ${D}/${libdir}/rustlib/rust-installer-version
|
||||
rm ${D}/${libdir}/rustlib/uninstall.sh
|
||||
rm ${D}/${libdir}/rustlib/components
|
||||
}
|
||||
|
||||
do_install_append () {
|
||||
rust_installer_do_install
|
||||
}
|
||||
|
||||
EXPORT_FUNCTIONS rust_installer_do_install
|
||||
@@ -1,8 +0,0 @@
|
||||
export rustlibdir = "${libdir}/rust"
|
||||
FILES_${PN} += "${rustlibdir}/*.so"
|
||||
FILES_${PN}-dev += "${rustlibdir}/*.rlib"
|
||||
FILES_${PN}-dbg += "${rustlibdir}/.debug"
|
||||
|
||||
RUSTLIB = "-L ${STAGING_LIBDIR}/rust"
|
||||
RUSTFLAGS += "-C rpath -C crate_hash=${BB_TASKHASH} ${RUSTLIB}"
|
||||
RUSTLIB_DEP ?= "libstd-rs"
|
||||
@@ -1,5 +1,4 @@
|
||||
inherit rust-vars
|
||||
inherit rust-triples
|
||||
inherit rust-common
|
||||
|
||||
RUSTC = "rustc"
|
||||
|
||||
@@ -38,8 +37,6 @@ HOST_CFLAGS ?= "${CFLAGS}"
|
||||
HOST_CXXFLAGS ?= "${CXXFLAGS}"
|
||||
HOST_CPPFLAGS ?= "${CPPFLAGS}"
|
||||
|
||||
EXTRA_OECONF_remove = "--disable-static"
|
||||
|
||||
rustlib_suffix="${TUNE_ARCH}${TARGET_VENDOR}-${TARGET_OS}/rustlib/${HOST_SYS}/lib"
|
||||
# Native sysroot standard library path
|
||||
rustlib_src="${prefix}/lib/${rustlib_suffix}"
|
||||
|
||||
+1
-1
@@ -180,7 +180,7 @@ class Crate(Wget):
|
||||
save_cwd = os.getcwd()
|
||||
os.chdir(rootdir)
|
||||
|
||||
pn = d.getVar('PN', True)
|
||||
pn = d.getVar('BPN', True)
|
||||
if pn == ud.parm.get('name'):
|
||||
cmd = "tar -xz --no-same-owner -f %s" % thefile
|
||||
else:
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
inherit cargo
|
||||
inherit patch
|
||||
inherit rust-installer
|
||||
|
||||
SUMMARY = "Cargo downloads your Rust project's dependencies and builds your project"
|
||||
HOMEPAGE = "http://crates.io"
|
||||
@@ -54,7 +53,7 @@ do_compile () {
|
||||
}
|
||||
|
||||
do_install () {
|
||||
oe_runmake DESTDIR="${D}" install
|
||||
oe_runmake prepare-image-${TARGET_SYS} IMGDIR_${TARGET_SYS}="${D}${prefix}"
|
||||
}
|
||||
|
||||
BBCLASSEXTEND = "native"
|
||||
|
||||
@@ -5,7 +5,6 @@ SRC_URI += " \
|
||||
git://github.com/rust-lang/cargo.git;protocol=https;name=cargo \
|
||||
file://0001-disable-cargo-snapshot-fetch.patch \
|
||||
file://0001-Never-update-the-registry-index.patch \
|
||||
git://github.com/rust-lang/rust-installer.git;protocol=https;name=rust-installer;destsuffix=${S}/src/rust-installer \
|
||||
crate://crates.io/advapi32-sys/0.1.2 \
|
||||
crate://crates.io/bufstream/0.1.1 \
|
||||
crate://crates.io/crossbeam/0.2.8 \
|
||||
@@ -60,8 +59,6 @@ SRC_URI += " \
|
||||
# https://static.rust-lang.org/dist/channel-rust-1.10.0.toml
|
||||
SRCREV_cargo = "259324cd8f9bb6e1068a3a2b77685e90fda3e3b6"
|
||||
|
||||
SRCREV_rust-installer = "c37d3747da75c280237dc2d6b925078e69555499"
|
||||
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
LIC_FILES_CHKSUM ="\
|
||||
|
||||
@@ -3,7 +3,6 @@ require cargo.inc
|
||||
|
||||
SRC_URI += " \
|
||||
git://github.com/rust-lang/cargo.git;protocol=https;name=cargo \
|
||||
git://github.com/rust-lang/rust-installer.git;protocol=https;name=rust-installer;destsuffix=${S}/src/rust-installer \
|
||||
crate://crates.io/advapi32-sys/0.2.0 \
|
||||
crate://crates.io/aho-corasick/0.5.2 \
|
||||
crate://crates.io/bitflags/0.1.1 \
|
||||
@@ -78,8 +77,6 @@ SRC_URI += " \
|
||||
# https://static.rust-lang.org/dist/channel-rust-1.12.1.toml
|
||||
SRCREV_cargo = "109cb7c33d426044d141457049bd0fffaca1327c"
|
||||
|
||||
SRCREV_rust-installer = "c37d3747da75c280237dc2d6b925078e69555499"
|
||||
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
LIC_FILES_CHKSUM ="\
|
||||
|
||||
@@ -341,6 +341,9 @@ do_rust_arch_fixup[dirs] += "${S}/mk/cfg"
|
||||
# prevent the rust-installer scripts from calling ldconfig
|
||||
export CFG_DISABLE_LDCONFIG="notempty"
|
||||
|
||||
# rust's configure doesn't recognize --disable-static, so remove it.
|
||||
DISABLE_STATIC = ""
|
||||
|
||||
do_configure () {
|
||||
# FIXME: target_prefix vs prefix, see cross.bbclass
|
||||
|
||||
@@ -403,6 +406,12 @@ rust_do_install () {
|
||||
# Remove any files directly installed into libdir to avoid
|
||||
# conflicts between cross and native
|
||||
rm -f ${D}${libdir}/lib*.so
|
||||
|
||||
# cleanup after rust-installer since we don't need these bits
|
||||
rm ${D}/${libdir}/rustlib/install.log
|
||||
rm ${D}/${libdir}/rustlib/rust-installer-version
|
||||
rm ${D}/${libdir}/rustlib/uninstall.sh
|
||||
rm ${D}/${libdir}/rustlib/components
|
||||
}
|
||||
|
||||
do_install () {
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
inherit rust-installer
|
||||
require rust.inc
|
||||
require rust-source-${PV}.inc
|
||||
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
inherit rust-installer
|
||||
require rust.inc
|
||||
require rust-source-${PV}.inc
|
||||
|
||||
|
||||
Reference in New Issue
Block a user