Rust 1.51 broken on macOS 11.2.3 Apple M1

Ryan Schmidt ryandesign at macports.org
Wed Apr 7 11:34:59 UTC 2021


On Apr 7, 2021, at 06:17, Eric wrote:

> on sunday during "port update outdated" rust was going to be installed as a dependency in order to update youtube-dl. 
> 
> I'm running macOS 11.2.3 on an Apple M1 Chip with macports 2.6.4 installed and all updates/upgrades installed. The package that got fetched for building rust is:
> rust-1.51.0_1.darwin_20.arm64.tbz2

rust-1.51.0_1.darwin_20.arm64.tbz2 was the package MacPorts *attempted* to download. That attempt failed, because we have not produced any such package. (We do not have an Apple Silicon build machine at the moment, although we used to and hopefully will again soon.) Because the package download failed, MacPorts built from source on your system.


> This package builds just fine but breaks during the staging into destroot process.
> 
> I did a sudo port clean rust (and a port clean rust), tried to install only rust, but the error remains. It occurs in the rls module but its origin seems to be during "compiling openssl-sys v0.9.58" . This compiling starts to fail when the following message occurs:
> 
> :info:destroot   = note: Undefined symbols for architecture arm64: 

> Could it be that openssl-sys (https://github.com/sfackler/rust-openssl/tree/master/openssl-sys) doesn't compile on arm64 yet or not in the context of building rust 1.51.0 on arm64?

No idea yet. We did successfully produce an arm64 package for the previous version of rust, 1.50.0. Probably best to file a ticket with the full compressed log.


> I found this issue https://trac.macports.org/ticket/62252 but I'm not quite sure if my problem is related to it and if I should reopen it or file a new one. 

I don't see any similarity between that ticket (which was a build failure on Yosemite due to the inclusion of the legacysupport portgroup in the port, which was resolved by removing that inclusion) and your issue (undefined symbols on Big Sur on Apple Silicon).


> It seems as more and more of my outdated ports rely on rust, so I hope that this gets fixed soon. 

libheif was recently changed to include a dependency on the optional library rav1l which depends indirectly on rust, so now anything you use that depends eventually on libheif, such as youtube-dl, requires rust.

Rust is ... extremely annoying for how long it takes to build and for the limited range of macOS versions it supports and the frequency with which new versions introduce build problems. I wish people would not use this programming language. Unfortunately some developers do, and to offer their software in MacPorts we have to have rust.



More information about the macports-users mailing list