diff options
| author | Efraim Flashner <efraim@flashner.co.il> | 2024-01-16 20:45:57 +0200 |
|---|---|---|
| committer | Efraim Flashner <efraim@flashner.co.il> | 2024-02-20 13:57:42 +0200 |
| commit | aa4f4811c60ec8925aa724a9abfc737815a5ff0f (patch) | |
| tree | 83014a24d774248720748cd06afb67b0fd413cbc /gnu/packages/rust.scm | |
| parent | 930bba14588898bd3c0035ec37a9004ca2028a37 (diff) | |
gnu: rust-1.64: Fix building on powerpc64le-linux.
* gnu/packages/rust.scm (rust-1.64)[source]: Adjust snippet to fix
building rustix on all architectures.
Change-Id: Iaa1f1b0ac70b36b6ac8a46e6789ce14d057fde08
Diffstat (limited to 'gnu/packages/rust.scm')
| -rw-r--r-- | gnu/packages/rust.scm | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/gnu/packages/rust.scm b/gnu/packages/rust.scm index 432f5cf9568..b7ceca6be7e 100644 --- a/gnu/packages/rust.scm +++ b/gnu/packages/rust.scm | |||
| @@ -657,6 +657,27 @@ safety and thread safety guarantees.") | |||
| 657 | (source | 657 | (source |
| 658 | (origin | 658 | (origin |
| 659 | (inherit (package-source base-rust)) | 659 | (inherit (package-source base-rust)) |
| 660 | (snippet | ||
| 661 | '(begin | ||
| 662 | (for-each delete-file-recursively | ||
| 663 | '("src/llvm-project" | ||
| 664 | "vendor/openssl-src/openssl" | ||
| 665 | "vendor/tikv-jemalloc-sys/jemalloc")) | ||
| 666 | ;; ERROR: could not find native static library | ||
| 667 | ;; `rustix_outline_powerpc64`, perhaps an -L flag is missing? | ||
| 668 | ;; Adjust rustix to always build with cc. | ||
| 669 | (substitute* "src/bootstrap/Cargo.lock" | ||
| 670 | (("\"errno\",") "\"cc\",\n \"errno\",")) | ||
| 671 | ;; Add a dependency on the the 'cc' feature of rustix. | ||
| 672 | (substitute* "vendor/fd-lock/Cargo.toml" | ||
| 673 | (("\"fs\"") "\"fs\", \"cc\"")) | ||
| 674 | ;; Remove vendored dynamically linked libraries. | ||
| 675 | ;; find . -not -type d -executable -exec file {} \+ | grep ELF | ||
| 676 | (delete-file "vendor/vte/vim10m_match") | ||
| 677 | (delete-file "vendor/vte/vim10m_table") | ||
| 678 | ;; Also remove the bundled (mostly Windows) libraries. | ||
| 679 | (for-each delete-file | ||
| 680 | (find-files "vendor" "\\.(a|dll|exe|lib)$")))) | ||
| 660 | (patches (search-patches "rust-1.64-fix-riscv64-bootstrap.patch")) | 681 | (patches (search-patches "rust-1.64-fix-riscv64-bootstrap.patch")) |
| 661 | (patch-flags '("-p1" "--reverse")))) | 682 | (patch-flags '("-p1" "--reverse")))) |
| 662 | (arguments | 683 | (arguments |
