mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-08 06:48:28 +00:00
lang/rust-nightly: Update to 1.53.0.20210323
- Sync patches with lang/rust
- Add the rust-nightly update script
Changes: 45b3c28518...5d04957a4b
This commit is contained in:
parent
318761fb18
commit
ea774b2080
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=569013
lang/rust-nightly
@ -1,7 +1,8 @@
|
||||
# Created by: Jean-Sébastien Pédron <dumbbell@FreeBSD.org>
|
||||
# $FreeBSD$
|
||||
|
||||
PORTVERSION= 1.50.0.${NIGHTLY_DATE:C,-,,g}
|
||||
# Run update.sh to update to the latest nightly
|
||||
PORTVERSION= 1.53.0.${NIGHTLY_DATE:C,-,,g}
|
||||
# Always set PORTREVISION explicitly as otherwise it is inherited from lang/rust
|
||||
PORTREVISION= 0
|
||||
PKGNAMESUFFIX= -nightly
|
||||
@ -16,13 +17,8 @@ MASTERDIR= ${.CURDIR}/../rust
|
||||
PATCHDIR= ${.CURDIR}/files
|
||||
DISTINFO_FILE= ${.CURDIR}/distinfo
|
||||
|
||||
# Get latest from top level 'date' key in
|
||||
# https://static.rust-lang.org/dist/channel-rust-nightly.toml
|
||||
NIGHTLY_DATE= 2021-03-05
|
||||
|
||||
# See WRKSRC/src/stage0.txt for this date
|
||||
BOOTSTRAPS_DATE= 2021-02-14
|
||||
RUST_BOOTSTRAP_VERSION= beta
|
||||
CARGO_BOOTSTRAP_VERSION= beta
|
||||
NIGHTLY_DATE= 2021-03-23
|
||||
BOOTSTRAPS_DATE= 2021-02-14
|
||||
RUST_BOOTSTRAP_VERSION= beta
|
||||
|
||||
.include "${MASTERDIR}/Makefile"
|
||||
|
@ -1,6 +1,6 @@
|
||||
TIMESTAMP = 1614940829
|
||||
SHA256 (rust/2021-03-05/rustc-nightly-src.tar.xz) = 53a31c16c0b119fddcace0aa7d57e107a8e21b40d4d04b976ddcb363f0273fce
|
||||
SIZE (rust/2021-03-05/rustc-nightly-src.tar.xz) = 114645532
|
||||
TIMESTAMP = 1616475173
|
||||
SHA256 (rust/2021-03-23/rustc-nightly-src.tar.xz) = ad47a8bef68e6d130e0477e16c0cab89e4f2e447f16578fc7243bac095a5ea56
|
||||
SIZE (rust/2021-03-23/rustc-nightly-src.tar.xz) = 115047736
|
||||
SHA256 (rust/2021-02-14/rustc-beta-x86_64-unknown-freebsd.tar.xz) = 1eb1f1508887449de36aa0dc75e549b8185d7d0bd4f86d503adda09295397fb7
|
||||
SIZE (rust/2021-02-14/rustc-beta-x86_64-unknown-freebsd.tar.xz) = 79211584
|
||||
SHA256 (rust/2021-02-14/rust-std-beta-x86_64-unknown-freebsd.tar.xz) = f366210bf594eda2b3a6547aff7fb0f32cde99e1a0ec427d2a05a430cc9795b2
|
||||
|
12
lang/rust-nightly/files/patch-backtrace
Normal file
12
lang/rust-nightly/files/patch-backtrace
Normal file
@ -0,0 +1,12 @@
|
||||
https://github.com/rust-lang/rust/issues/78184
|
||||
|
||||
--- library/backtrace/src/symbolize/gimli.rs.orig 2021-02-10 17:36:59 UTC
|
||||
+++ library/backtrace/src/symbolize/gimli.rs
|
||||
@@ -361,6 +361,7 @@ cfg_if::cfg_if! {
|
||||
} else if #[cfg(any(
|
||||
target_os = "linux",
|
||||
target_os = "fuchsia",
|
||||
+ target_os = "freebsd",
|
||||
))] {
|
||||
// Other Unix (e.g. Linux) platforms use ELF as an object file format
|
||||
// and typically implement an API called `dl_iterate_phdr` to load
|
17
lang/rust-nightly/files/patch-src_bootstrap_install.rs
Normal file
17
lang/rust-nightly/files/patch-src_bootstrap_install.rs
Normal file
@ -0,0 +1,17 @@
|
||||
Only install docs for the host target
|
||||
|
||||
It otherwise wastes significant time (there are a lot of individual
|
||||
files) and stages host docs, wasm docs, which unstages the host
|
||||
docs first.
|
||||
|
||||
--- src/bootstrap/install.rs.orig 2021-03-22 17:05:25 UTC
|
||||
+++ src/bootstrap/install.rs
|
||||
@@ -133,7 +133,7 @@ macro_rules! install {
|
||||
}
|
||||
|
||||
install!((self, builder, _config),
|
||||
- Docs, "src/doc", _config.docs, only_hosts: false, {
|
||||
+ Docs, "src/doc", _config.docs, only_hosts: true, {
|
||||
let tarball = builder.ensure(dist::Docs { host: self.target }).expect("missing docs");
|
||||
install_sh(builder, "docs", self.compiler.stage, Some(self.target), &tarball);
|
||||
};
|
37
lang/rust-nightly/update.sh
Normal file
37
lang/rust-nightly/update.sh
Normal file
@ -0,0 +1,37 @@
|
||||
#!/bin/sh
|
||||
# Requires: pkg install portfmt
|
||||
# Run in lang/rust-nightly
|
||||
set -eu
|
||||
|
||||
get_commit() {
|
||||
awk '
|
||||
$1 == "[pkg.rustc]" { pkg_rustc = 1 }
|
||||
pkg_rustc && $1 == "git_commit_hash" {
|
||||
print substr($3, 2, 10)
|
||||
exit
|
||||
}'
|
||||
}
|
||||
|
||||
prev_date=$(portedit get '^NIGHTLY_DATE$' .)
|
||||
prev_commit=$(fetch -qo - https://static.rust-lang.org/dist/${prev_date}/channel-rust-nightly.toml | get_commit)
|
||||
fetch -qo /tmp/channel-rust-nightly.toml https://static.rust-lang.org/dist/channel-rust-nightly.toml
|
||||
</tmp/channel-rust-nightly.toml awk '
|
||||
$1 == "[pkg.rustc]" { pkg_rustc = 1 }
|
||||
date == "" && $1 == "date" { date = substr($3, 2, length($3) - 2) }
|
||||
date && pkg_rustc && $1 == "version" {
|
||||
version = substr($3, 2, length($3) - length("-nightly") - 1)
|
||||
printf("PORTVERSION=%s.${NIGHTLY_DATE:C,-,,g}\nPORTREVISION=0\nNIGHTLY_DATE=%s\n", version, date)
|
||||
exit
|
||||
}' | portedit merge -i .
|
||||
new_commit=$(</tmp/channel-rust-nightly.toml get_commit)
|
||||
rm /tmp/channel-rust-nightly.toml
|
||||
|
||||
fetch -qo - https://raw.githubusercontent.com/rust-lang/rust/${new_commit}/src/stage0.txt | awk '
|
||||
$1 == "date:" { date = $2 }
|
||||
$1 == "rustc:" { rustc = $2 }
|
||||
END { printf("BOOTSTRAPS_DATE=%s\nRUST_BOOTSTRAP_VERSION=%s\n", date, rustc) }' | portedit merge -i .
|
||||
|
||||
make makesum
|
||||
echo "lang/rust-nightly: Update to $(make -V PORTVERSION)
|
||||
|
||||
Changes: https://github.com/rust-lang/rust/compare/${prev_commit}...${new_commit}" >rust-nightly.msg
|
Loading…
Reference in New Issue
Block a user