commit: b5ca7847bf596798afcfecf73730593288e1fe43
Author: orbea <orbea <AT> riseup <DOT> net>
AuthorDate: Tue Nov 26 16:30:53 2024 +0000
Commit: orbea <orbea <AT> riseup <DOT> net>
CommitDate: Tue Nov 26 16:30:53 2024 +0000
URL: https://gitweb.gentoo.org/repo/proj/libressl.git/commit/?id=b5ca7847
dev-lang/rust: sync ::gentoo
Signed-off-by: orbea <orbea <AT> riseup.net>
dev-lang/rust/rust-1.71.1-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
dev-lang/rust/rust-1.74.1-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
dev-lang/rust/rust-1.75.0-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
dev-lang/rust/rust-1.77.1-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
dev-lang/rust/rust-1.79.0-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
dev-lang/rust/rust-1.80.1-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
dev-lang/rust/rust-1.81.0-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
dev-lang/rust/rust-1.82.0-r100.ebuild | 37 +++++++++++++++++++++++++++++++++++
8 files changed, 296 insertions(+)
diff --git a/dev-lang/rust/rust-1.71.1-r100.ebuild
b/dev-lang/rust/rust-1.71.1-r100.ebuild
index 5777155..19af311 100644
--- a/dev-lang/rust/rust-1.71.1-r100.ebuild
+++ b/dev-lang/rust/rust-1.71.1-r100.ebuild
@@ -638,7 +638,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then
diff --git a/dev-lang/rust/rust-1.74.1-r100.ebuild
b/dev-lang/rust/rust-1.74.1-r100.ebuild
index 5e2a4e0..7041c7e 100644
--- a/dev-lang/rust/rust-1.74.1-r100.ebuild
+++ b/dev-lang/rust/rust-1.74.1-r100.ebuild
@@ -666,7 +666,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then
diff --git a/dev-lang/rust/rust-1.75.0-r100.ebuild
b/dev-lang/rust/rust-1.75.0-r100.ebuild
index f793cfa..946ddb9 100644
--- a/dev-lang/rust/rust-1.75.0-r100.ebuild
+++ b/dev-lang/rust/rust-1.75.0-r100.ebuild
@@ -668,7 +668,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then
diff --git a/dev-lang/rust/rust-1.77.1-r100.ebuild
b/dev-lang/rust/rust-1.77.1-r100.ebuild
index 269493b..e42c510 100644
--- a/dev-lang/rust/rust-1.77.1-r100.ebuild
+++ b/dev-lang/rust/rust-1.77.1-r100.ebuild
@@ -668,7 +668,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then
diff --git a/dev-lang/rust/rust-1.79.0-r100.ebuild
b/dev-lang/rust/rust-1.79.0-r100.ebuild
index 243266f..94d0dfb 100644
--- a/dev-lang/rust/rust-1.79.0-r100.ebuild
+++ b/dev-lang/rust/rust-1.79.0-r100.ebuild
@@ -671,7 +671,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then
diff --git a/dev-lang/rust/rust-1.80.1-r100.ebuild
b/dev-lang/rust/rust-1.80.1-r100.ebuild
index 061eb7d..438ac18 100644
--- a/dev-lang/rust/rust-1.80.1-r100.ebuild
+++ b/dev-lang/rust/rust-1.80.1-r100.ebuild
@@ -668,7 +668,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then
diff --git a/dev-lang/rust/rust-1.81.0-r100.ebuild
b/dev-lang/rust/rust-1.81.0-r100.ebuild
index 19d6557..572442c 100644
--- a/dev-lang/rust/rust-1.81.0-r100.ebuild
+++ b/dev-lang/rust/rust-1.81.0-r100.ebuild
@@ -672,7 +672,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then
diff --git a/dev-lang/rust/rust-1.82.0-r100.ebuild
b/dev-lang/rust/rust-1.82.0-r100.ebuild
index f8cae41..b4c7c34 100644
--- a/dev-lang/rust/rust-1.82.0-r100.ebuild
+++ b/dev-lang/rust/rust-1.82.0-r100.ebuild
@@ -679,7 +679,44 @@ src_install() {
fi
}
+pkg_preinst() {
+ # 943308 and friends; basically --keep-going can forget to unmerge old
rust
+ # but the soft blocker allows us to install conflicting files.
+ # This results in duplicated .{rlib,so} files which confuses rustc and
results in
+ # the need for manual intervention.
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # we need to find all .{rlib,so} files in the old rust lib
directory
+ # and store them in an array for later use
+ readarray -d '' old_rust_libs < <(
+ find "${EROOT}/usr/lib/rust/${PV}/lib/rustlib" \
+ -type f \( -name '*.rlib' -o -name '*.so' \) -print0)
+ export old_rust_libs
+ if [[ ${#old_rust_libs[@]} -gt 0 ]]; then
+ einfo "Found old .rlib and .so files in the old rust
lib directory"
+ else
+ die "Found no old .rlib and .so files but old rust
version is installed. Bailing!"
+ fi
+ fi
+}
+
pkg_postinst() {
+
+ if has_version -b "dev-lang/rust:stable/$(ver_cut 1-2)"; then
+ # Be _extra_ careful here as we're removing files from the live
filesystem
+ local f
+ for f in "${old_rust_libs[@]}"; do
+ [[ -f ${f} ]] || die "old_rust_libs array contains
non-existent file"
+ local base_name="${f%-*}"
+ local ext="${f##*.}"
+ local matching_files=("${base_name}"-*.${ext})
+ if [[ ${#matching_files[@]} -ne 2 ]]; then
+ die "Expected exactly two files matching
${base_name}-\*.rlib, but found ${#matching_files[@]}"
+ fi
+ einfo "Removing old .rlib file ${f}"
+ rm "${f}" || die
+ done
+ fi
+
eselect rust update
if has_version dev-debug/gdb || has_version dev-debug/lldb; then