diff options
author | Baptiste Daroussin <bapt@FreeBSD.org> | 2022-08-25 16:30:04 +0200 |
---|---|---|
committer | Baptiste Daroussin <bapt@FreeBSD.org> | 2022-08-25 16:49:50 +0200 |
commit | b9b250f91299716bc4a7a6b7b8db2284c57f16ca (patch) | |
tree | e0011b148402850bfba2f57b181c15037cb1dc29 /lang/rust/files | |
parent | security/aws-c-cal: Adopt/Update to 0.5.19 (diff) |
rust: bring back update to 1.63
Revert back the revert of the update of rust and related commits
This revert was drive by beside validation by portmgr via exp-run
and not respectful of the etiquette we have between committers
This reverts commit 8ecb1f8141144c1603eb4026122d2e60eeaccd64.
This reverts commit 04d257baa182926cff158f32cf459e560426add0.
This reverts commit 2757c63bd0e6d01f9f0657fe03bb3a7b49adcae2.
This reverts commit 75f4713de5e3fbd1c6a0cb572e08121814a4072e.
This reverts commit e88e592111c86fdd1c0ac8717dbef9342e15e27c.
This reverts commit 783c056d7d681d66e2c5c59251c275d65274028e.
With hat: portmgr
Diffstat (limited to 'lang/rust/files')
-rw-r--r-- | lang/rust/files/no-hardlinks/patch-src_bootstrap_lib.rs | 31 |
1 files changed, 23 insertions, 8 deletions
diff --git a/lang/rust/files/no-hardlinks/patch-src_bootstrap_lib.rs b/lang/rust/files/no-hardlinks/patch-src_bootstrap_lib.rs index 081c2056ad2c..03a24563bf05 100644 --- a/lang/rust/files/no-hardlinks/patch-src_bootstrap_lib.rs +++ b/lang/rust/files/no-hardlinks/patch-src_bootstrap_lib.rs @@ -15,14 +15,29 @@ links during the build, so let's try that. --- src/bootstrap/lib.rs.orig 2020-07-23 20:16:43 UTC +++ src/bootstrap/lib.rs -@@ -1173,10 +1173,6 @@ impl Build { - if metadata.file_type().is_symlink() { - let link = t!(fs::read_link(src)); - t!(symlink_file(link, dst)); -- } else if let Ok(()) = fs::hard_link(src, dst) { +@@ -1450,19 +1450,13 @@ impl Build { + return; + } + } +- if let Ok(()) = fs::hard_link(&src, dst) { - // Attempt to "easy copy" by creating a hard link - // (symlinks don't work on windows), but if that fails - // just fall back to a slow `copy` operation. - } else { - if let Err(e) = fs::copy(src, dst) { - panic!("failed to copy `{}` to `{}`: {}", src.display(), dst.display(), e) +- } else { +- if let Err(e) = fs::copy(&src, dst) { +- panic!("failed to copy `{}` to `{}`: {}", src.display(), dst.display(), e) +- } +- t!(fs::set_permissions(dst, metadata.permissions())); +- let atime = FileTime::from_last_access_time(&metadata); +- let mtime = FileTime::from_last_modification_time(&metadata); +- t!(filetime::set_file_times(dst, atime, mtime)); ++ if let Err(e) = fs::copy(&src, dst) { ++ panic!("failed to copy `{}` to `{}`: {}", src.display(), dst.display(), e) + } ++ t!(fs::set_permissions(dst, metadata.permissions())); ++ let atime = FileTime::from_last_access_time(&metadata); ++ let mtime = FileTime::from_last_modification_time(&metadata); ++ t!(filetime::set_file_times(dst, atime, mtime)); + } + + /// Copies the `src` directory recursively to `dst`. Both are assumed to exist |