From: jcgruenhage <jcgruenhage@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: [PR PATCH] rustup: update to 1.25.0.
Date: Tue, 12 Jul 2022 08:39:15 +0200 [thread overview]
Message-ID: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-38015@inbox.vuxu.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 1224 bytes --]
There is a new pull request by jcgruenhage against master on the void-packages repository
https://github.com/jcgruenhage/void-packages rustup-1.25.0_1
https://github.com/void-linux/void-packages/pull/38015
rustup: update to 1.25.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
<!--
#### New package
- This new package conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- aarch64-musl
- armv7l
- armv6l-musl
-->
A patch file from https://github.com/void-linux/void-packages/pull/38015.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-rustup-1.25.0_1-38015.patch --]
[-- Type: text/x-diff, Size: 4198 bytes --]
From 3c417b041a2daef76bc1acd6fb54408dcf5331b7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jan=20Christian=20Gr=C3=BCnhage?=
<jan.christian@gruenhage.xyz>
Date: Tue, 12 Jul 2022 08:38:23 +0200
Subject: [PATCH] rustup: update to 1.25.0.
---
...Symlink-rustup-instead-of-copying-it.patch | 45 +++++++++++++++++++
.../rustup/patches/dont-copy-rustup-bin.patch | 15 -------
srcpkgs/rustup/template | 4 +-
3 files changed, 47 insertions(+), 17 deletions(-)
create mode 100644 srcpkgs/rustup/patches/0001-Symlink-rustup-instead-of-copying-it.patch
delete mode 100644 srcpkgs/rustup/patches/dont-copy-rustup-bin.patch
diff --git a/srcpkgs/rustup/patches/0001-Symlink-rustup-instead-of-copying-it.patch b/srcpkgs/rustup/patches/0001-Symlink-rustup-instead-of-copying-it.patch
new file mode 100644
index 000000000000..7f57e6fe0f1c
--- /dev/null
+++ b/srcpkgs/rustup/patches/0001-Symlink-rustup-instead-of-copying-it.patch
@@ -0,0 +1,45 @@
+From e512f8222fddecf23552ed490f71cc3c444abc53 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Jan=20Christian=20Gr=C3=BCnhage?=
+ <jan.christian@gruenhage.xyz>
+Date: Tue, 12 Jul 2022 08:16:08 +0200
+Subject: [PATCH] Symlink rustup instead of copying it
+
+To make sure that we can update rustup using xbps, we need to symlink
+rustup into $CARGO_HOME/bin instead of copying it.
+
+Upstream doesn't want the patch as it is right now.
+---
+ src/cli/self_update.rs | 3 +--
+ src/utils/utils.rs | 2 +-
+ 2 files changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/src/cli/self_update.rs b/src/cli/self_update.rs
+index a4c00d57..82a4d67a 100644
+--- a/src/cli/self_update.rs
++++ b/src/cli/self_update.rs
+@@ -729,8 +729,7 @@ fn install_bins() -> Result<()> {
+ if rustup_path.exists() {
+ utils::remove_file("rustup-bin", &rustup_path)?;
+ }
+- utils::copy_file(&this_exe_path, &rustup_path)?;
+- utils::make_executable(&rustup_path)?;
++ utils::symlink_file(&this_exe_path, &rustup_path)?;
+ install_proxies()
+ }
+
+diff --git a/src/utils/utils.rs b/src/utils/utils.rs
+index 0362372b..9e5a5fe2 100644
+--- a/src/utils/utils.rs
++++ b/src/utils/utils.rs
+@@ -306,7 +306,7 @@ pub fn hardlink_file(src: &Path, dest: &Path) -> Result<()> {
+ }
+
+ #[cfg(unix)]
+-fn symlink_file(src: &Path, dest: &Path) -> Result<()> {
++pub(crate) fn symlink_file(src: &Path, dest: &Path) -> Result<()> {
+ std::os::unix::fs::symlink(src, dest).with_context(|| RustupError::LinkingFile {
+ src: PathBuf::from(src),
+ dest: PathBuf::from(dest),
+--
+2.37.0
+
diff --git a/srcpkgs/rustup/patches/dont-copy-rustup-bin.patch b/srcpkgs/rustup/patches/dont-copy-rustup-bin.patch
deleted file mode 100644
index d8289b90d691..000000000000
--- a/srcpkgs/rustup/patches/dont-copy-rustup-bin.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream: No, not upstreamable like this
-Reason: We want the rustup binary in $CARGO_HOME/bin to be of the
-same version as the one we distribute in this rustup package.
---- a/src/cli/self_update.rs 2019-05-27 16:17:21.432715136 +0200
-+++ b/src/cli/self_update.rs 2019-05-27 16:18:56.537718683 +0200
-@@ -619,8 +619,7 @@
- if rustup_path.exists() {
- utils::remove_file("rustup-bin", &rustup_path)?;
- }
-- utils::copy_file(&this_exe_path, &rustup_path)?;
-- utils::make_executable(&rustup_path)?;
-+ utils::symlink_file(&this_exe_path, &rustup_path)?;
- install_proxies()
- }
-
diff --git a/srcpkgs/rustup/template b/srcpkgs/rustup/template
index b55cbe09d868..a47f77e39d57 100644
--- a/srcpkgs/rustup/template
+++ b/srcpkgs/rustup/template
@@ -1,6 +1,6 @@
# Template file for 'rustup'
pkgname=rustup
-version=1.24.3
+version=1.25.0
revision=1
# rustup doesn't recognize this target
archs="~armv*-musl"
@@ -15,7 +15,7 @@ maintainer="Jan Christian Grünhage <jan.christian@gruenhage.xyz>"
license="Apache-2.0, MIT"
homepage="https://www.rustup.rs"
distfiles="https://github.com/rust-lang/${pkgname}/archive/${version}.tar.gz"
-checksum=24a8cede4ccbbf45ab7b8de141d92f47d1881bb546b3b9180d5a51dc0622d0f6
+checksum=a6d4701fb0c6030fdcf3e9828ccf880e78cef293749573e33714b5645a74191b
case "$XBPS_TARGET_MACHINE" in
x86_64*|i686*|arm*|aarch64*)
next reply other threads:[~2022-07-12 6:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-12 6:39 jcgruenhage [this message]
2022-07-12 22:14 ` tjkirch
2022-07-13 18:28 ` [PR PATCH] [Updated] " jcgruenhage
2022-07-15 5:27 ` [PR PATCH] [Merged]: " classabbyamp
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-38015@inbox.vuxu.org \
--to=jcgruenhage@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).