ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
From: "Earlopain (Earlopain _) via ruby-core" <ruby-core@ml.ruby-lang.org>
To: ruby-core@ml.ruby-lang.org
Cc: "Earlopain (Earlopain _)" <noreply@ruby-lang.org>
Subject: [ruby-core:120053] [Ruby master Bug#20506] YJIT build error on aarch64 with Rust 1.78.0
Date: Fri, 29 Nov 2024 08:38:03 +0000 (UTC)	[thread overview]
Message-ID: <redmine.journal-110788.20241129083802.6346@ruby-lang.org> (raw)
In-Reply-To: <redmine.issue-20506.20240524151538.6346@ruby-lang.org>

Issue #20506 has been updated by Earlopain (Earlopain _).


I tested with the recent 1.84 beta and it seems resolved with that version.

----------------------------------------
Bug #20506: YJIT build error on aarch64 with Rust 1.78.0
https://bugs.ruby-lang.org/issues/20506#change-110788

* Author: schneems (Richard Schneeman)
* Status: Third Party's Issue
* Assignee: yjit
* Backport: 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN
----------------------------------------
I was unable to compile Ruby 3.4.0-preview1 on Ubuntu 24.04 via Github Actions. As the logs are not retained indefinitely here's a link to the compilation failure: https://gist.github.com/schneems/bc6bdd6fba08ff6bfdd1bce8d76c457d

The relevant errors seem to be in linking yjit:

```
touch yjit/target/release/libyjit.a
partial linking yjit/target/release/libyjit.a into yjit/target/release/libyjit.o
linking miniruby
/usr/bin/ld: yjit/target/release/libyjit.o: in function `__multc3':
/cargo/registry/src/index.crates.io-6f17d22bba15001f/compiler_builtins-0.1.108/./lib/builtins/multc3.c:33:(.text.__multc3+0x30c): undefined reference to `__builtin_copysignq'
/usr/bin/ld: /cargo/registry/src/index.crates.io-6f17d22bba15001f/compiler_builtins-0.1.108/./lib/builtins/multc3.c:34:(.text.__multc3+0x394): undefined reference to `__builtin_copysignq'
/usr/bin/ld: /cargo/registry/src/index.crates.io-6f17d22bba15001f/compiler_builtins-0.1.108/./lib/builtins/multc3.c:42:(.text.__multc3+0x7f4): undefined reference to `__builtin_copysignq'
/usr/bin/ld: /cargo/registry/src/index.crates.io-6f17d22bba15001f/compiler_builtins-0.1.108/./lib/builtins/multc3.c:43:(.text.__multc3+0x864): undefined reference to `__builtin_copysignq'
/usr/bin/ld: /cargo/registry/src/index.crates.io-6f17d22bba15001f/compiler_builtins-0.1.108/./lib/builtins/multc3.c:47:(.text.__multc3+0x8c4): undefined reference to `__builtin_copysignq'
/usr/bin/ld: yjit/target/release/libyjit.o:/cargo/registry/src/index.crates.io-6f17d22bba15001f/compiler_builtins-0.1.108/./lib/builtins/multc3.c:38: more undefined references to `__builtin_copysignq' follow
collect2: error: ld returned 1 exit status
make: *** [Makefile:298: miniruby] Error 1
/tmp/lib/build_script.rb:118:in `pipe': Command failed debugflags="-g" ./configure --disable-install-doc --prefix /tmp/d20240524-1-bdq0bj/prefix --enable-load-relative --enable-shared --enable-yjit && make -j16 && make install (RuntimeError)
	from /tmp/lib/build_script.rb:158:in `block in build'
	from /tmp/lib/build_script.rb:152:in `chdir'
	from /tmp/lib/build_script.rb:152:in `build'
	from /tmp/lib/build_script.rb:65:in `block in run_build_script'
	from /usr/lib/ruby/3.2.0/tmpdir.rb:94:in `mktmpdir'
	from /tmp/lib/build_script.rb:61:in `run_build_script'
	from /tmp/build.rb:8:in `<main>'
```

Here's the GHA link: https://github.com/heroku/docker-heroku-ruby-builder/actions/runs/9225538149/job/25383247191. This is the Dockerfile for Ubuntu 24.04 https://github.com/heroku/docker-heroku-ruby-builder/blob/73bdda974811717baccc05ea3e23f607817fbc8a/dockerfiles/Dockerfile.heroku-24.

I'm able to reproduce the failure locally:

```
$ git clone https://github.com/heroku/docker-heroku-ruby-builder
$ cd docker-heroku-ruby-builder
$ export DOCKER_DEFAULT_PLATFORM=linux/arm64
$ bin/activate_docker heroku-24
$ bin/build_ruby heroku-24 3.4.0-preview1
# Fails
```

Full output https://gist.github.com/schneems/cfa21847228d48e6bbe27463deae6745. 

I'm also seeing failures when using `ruby-install` on my mac (ARM), the error message is different so I'm not sure if it's the same problem or unrelated: https://gist.github.com/schneems/12af87e967126c7bfa319645b00015b3



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/

      parent reply	other threads:[~2024-11-29  8:38 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-24 15:15 [ruby-core:118003] [Ruby master Bug#20506] Failure compiling Ruby 3.4.0-preview1 on aarch64 on a mac and linux (Ubuntu 24.04) schneems (Richard Schneeman) via ruby-core
2024-05-24 17:02 ` [ruby-core:118005] " k0kubun (Takashi Kokubun) via ruby-core
2024-05-24 18:46 ` [ruby-core:118006] " eileencodes (Eileen Uchitelle) via ruby-core
2024-05-25 18:23 ` [ruby-core:118018] " alanwu (Alan Wu) via ruby-core
2024-05-27  3:50 ` [ruby-core:118026] " schneems (Richard Schneeman) via ruby-core
2024-06-10 17:39 ` [ruby-core:118276] [Ruby master Bug#20506] YJIT build error on aarch64 with Rust 1.78.0 alanwu (Alan Wu) via ruby-core
2024-11-03 10:36 ` [ruby-core:119692] " Earlopain (A S) via ruby-core
2024-11-03 15:05 ` [ruby-core:119693] " alanwu (Alan Wu) via ruby-core
2024-11-03 15:49 ` [ruby-core:119694] " Earlopain (A S) via ruby-core
2024-11-03 23:28 ` [ruby-core:119696] " alanwu (Alan Wu) via ruby-core
2024-11-04 12:12 ` [ruby-core:119700] " Earlopain (A S) via ruby-core
2024-11-29  8:38 ` Earlopain (Earlopain _) via ruby-core [this message]

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=redmine.journal-110788.20241129083802.6346@ruby-lang.org \
    --to=ruby-core@ml.ruby-lang.org \
    --cc=noreply@ruby-lang.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).