Opened 2 years ago

Closed 2 years ago

#64728 closed defect (fixed)

rust @1.58.1_1 fails to destroot on MacOS 10.15 on x86_64

Reported by: Gandoon (Erik Hedlund) Owned by: g5pw (Aljaž Srebrnič)
Priority: Normal Milestone:
Component: ports Version: 2.7.1
Keywords: Cc: herbygillot (Herby Gillot)
Port: rust

Description

This is a weird one. @1.58.1_0 built just fine some time ago, yet this revision bump fails. At a first glance it does not seem to be a direct duplicate of neither #64686 nor #63702, but it may very well be. The former seems to fail during destroot, but it seems to be at a different point (and it is an older version, rust @1.56.0_2, on a different architecture). The latter fails already during the build phase, so it also seems to be something different.

In my case the build phase finishes successfully, but the destroot phase fails with complaints about symbols not found for x86_64. A few snippets are presented here, and the full log is attached.

:info:destroot    Compiling rls v1.41.0 (/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1-src/src/tools/rls)

. . .

:info:destroot error: linking with `/usr/bin/clang` failed: exit status: 1
:info:destroot   |
:info:destroot   = note: "/usr/bin/clang" "-m64" "-arch" "x86_64" . . .

. . .

:info:destroot                 ...
:info:destroot           ld: symbol(s) not found for architecture x86_64
:info:destroot           clang: error: linker command failed with exit code 1 (use -v to see invocation)
:info:destroot
:info:destroot Did not run successfully: exit status: 1

. . .

:info:destroot -------------
:info:destroot error: could not compile `rls` due to previous error
:info:destroot Caused by:
:info:destroot   process didn't exit successfully: `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rust
c-1.58.1-src/build/bootstrap/debug/rustc --crate-name rls . . .

The final error message is as follows:

:info:destroot thread 'main' panicked at 'Unable to build RLS', src/bootstrap/dist.rs:45:9
:info:destroot stack backtrace:
:info:destroot    0: rust_begin_unwind
:info:destroot              at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panicking.rs:517:5
:info:destroot    1: core::panicking::panic_fmt
:info:destroot              at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/panicking.rs:100:14
:info:destroot    2: bootstrap::dist::missing_tool
:info:destroot              at ./src/bootstrap/dist.rs:45:9
:info:destroot    3: <bootstrap::dist::Rls as bootstrap::builder::Step>::run::{{closure}}
:info:destroot              at ./src/bootstrap/dist.rs:1047:17
:info:destroot    4: core::option::Option<T>::or_else
:info:destroot              at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/option.rs:1149:21
:info:destroot    5: <bootstrap::dist::Rls as bootstrap::builder::Step>::run
:info:destroot              at ./src/bootstrap/dist.rs:1044:19
:info:destroot    6: bootstrap::builder::Builder::ensure
:info:destroot              at ./src/bootstrap/builder.rs:1593:23
:info:destroot    7: <bootstrap::install::Rls as bootstrap::builder::Step>::run
:info:destroot              at ./src/bootstrap/install.rs:163:32
:info:destroot    8: bootstrap::builder::Builder::ensure
:info:destroot              at ./src/bootstrap/builder.rs:1593:23
:info:destroot    9: <bootstrap::install::Rls as bootstrap::builder::Step>::make_run
:info:destroot              at ./src/bootstrap/install.rs:127:17
:info:destroot   10: bootstrap::builder::StepDescription::maybe_run
:info:destroot              at ./src/bootstrap/builder.rs:175:13
:info:destroot   11: bootstrap::builder::StepDescription::run
:info:destroot              at ./src/bootstrap/builder.rs:211:25
:info:destroot   12: bootstrap::builder::Builder::run_step_descriptions
:info:destroot              at ./src/bootstrap/builder.rs:620:9
:info:destroot   13: bootstrap::builder::Builder::execute_cli
:info:destroot              at ./src/bootstrap/builder.rs:600:9
:info:destroot   14: bootstrap::Build::build
:info:destroot              at ./src/bootstrap/lib.rs:623:13
:info:destroot   15: bootstrap::main
:info:destroot              at ./src/bootstrap/bin/main.rs:33:5
:info:destroot   16: core::ops::function::FnOnce::call_once
:info:destroot              at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/ops/function.rs:227:5
:info:destroot note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
:info:destroot Traceback (most recent call last):
:info:destroot   File "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1-src/src/bootstrap/bo
otstrap.py", line 1283, in <module>
:info:destroot     main()
:info:destroot   File "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1-src/src/bootstrap/bo
otstrap.py", line 1266, in main
:info:destroot     bootstrap(help_triggered)
:info:destroot   File "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1-src/src/bootstrap/bo
otstrap.py", line 1252, in bootstrap
:info:destroot     run(args, env=env, verbose=build.verbose, is_bootstrap=True)
:info:destroot   File "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1-src/src/bootstrap/bo
otstrap.py", line 144, in run
:info:destroot     raise RuntimeError(err)
:info:destroot RuntimeError: failed to run: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1
-src/build/bootstrap/debug/bootstrap install -v
:info:destroot make: *** [install] Error 1
:info:destroot make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1-src
'
:info:destroot Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/rustc-1.58.1-src" &&
 /usr/bin/make -w install VERBOSE=1 DESTDIR=/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/work/destroot
:info:destroot Exit code: 2
:error:destroot Failed to destroot rust: command execution failed
:debug:destroot Error code: CHILDSTATUS 54561 2
:debug:destroot Backtrace: command execution failed
:debug:destroot     while executing
:debug:destroot "system {*}$notty {*}$callback {*}$nice $fullcmdstring"
:debug:destroot     invoked from within
:debug:destroot "command_exec -callback portprogress::target_progress_callback destroot"
:debug:destroot     (procedure "portdestroot::destroot_main" line 2)
:debug:destroot     invoked from within
:debug:destroot "$procedure $targetname"
:error:destroot See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_rust/rust/main.log for details.

Since this is a fairly involved build that takes close to three hours to complete, in addition to that the work directory fills 13 GB at the point when it fails, so I would rather not port -v clean it multiple times while trying to troubleshoot this. Does anyone know of a way to solve this issue that would not require a full rebuild in order to to destroot and install this?

Attachments (1)

Rust-MacOS_10.15-main.log.xz (343.5 KB) - added by Gandoon (Erik Hedlund) 2 years ago.
logfile of the failed destroot

Download all attachments as: .zip

Change History (5)

Changed 2 years ago by Gandoon (Erik Hedlund)

logfile of the failed destroot

comment:1 Changed 2 years ago by Gandoon (Erik Hedlund)

Summary: rust @1.58.1_1 fails to destroot on MacOS 10.15rust @1.58.1_1 fails to destroot on MacOS 10.15 on x86_64

comment:2 Changed 2 years ago by jmroot (Joshua Root)

Cc: herbygillot added
Owner: set to g5pw
Status: newassigned

comment:3 Changed 2 years ago by herbygillot (Herby Gillot)

Prospective fix updating to newest Rust release here: https://github.com/macports/macports-ports/pull/14126

comment:4 Changed 2 years ago by herbygillot (Herby Gillot)

Resolution: fixed
Status: assignedclosed

In a07f2a4ee8fdf4a5050ceb812dcb659283037c80/macports-ports (master):

rust: update to 1.59.0

  • use Python 3.10
  • add lbzip2 as build dependency

Fixes: #64686
Fixes: #64728

Note: See TracTickets for help on using tickets.