[前][次][番号順一覧][スレッド一覧]

ruby-changes:72150

From: Jun <ko1@a...>
Date: Mon, 13 Jun 2022 19:12:45 +0900 (JST)
Subject: [ruby-changes:72150] a80f5c5365 (master): Enable "make annocheck" on platforms other than Linux.

https://git.ruby-lang.org/ruby.git/commit/?id=a80f5c5365

From a80f5c536598157da83f8de8f328d03207801c43 Mon Sep 17 00:00:00 2001
From: Jun Aruga <jaruga@r...>
Date: Wed, 18 May 2022 14:24:18 +0200
Subject: Enable "make annocheck" on platforms other than Linux.

The annocheck supports ELF format binaries compiled for any OS and for any
architecture. It can work in not only Linux but also FreeBSD and Solaris.
It is designed to be independent of the host OS and the architecture.

Even in Mac, as the binaries are Mach-O foramt, the annocheck fails correctly
with the message.

e.g. Test binaries compiled for Mac OSX 10.13.6 (target_os: darwin17) in Fedora 35.

```
$ cat /etc/fedora-release
Fedora release 35 (Thirty Five)

$ file ruby
ruby: Mach-O 64-bit x86_64 executable, flags:<NOUNDEFS|DYLDLINK|TWOLEVEL|WEAK_DEFINES|BINDS_TO_WEAK|PIE>

$ annocheck ruby
annocheck: Version 10.66.
annocheck: Warning: ruby: is not an ELF format file.
```

See <https://sourceware.org/bugzilla/show_bug.cgi?id=29173> for details.
---
 common.mk | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/common.mk b/common.mk
index cd190952d9..db4a283602 100644
--- a/common.mk
+++ b/common.mk
@@ -1447,10 +1447,11 @@ yes-test-bundler-parallel: yes-test-bundler-prepare https://github.com/ruby/ruby/blob/trunk/common.mk#L1447
 		$(PARALLELRSPECOPTS) $(srcdir)/spec/bundler/$(BUNDLER_SPECS)
 no-test-bundler-parallel:
 
-test-annocheck: $(target_os)-test-annocheck
-linux-test-annocheck: $(PROGRAM)
+# The annocheck supports ELF format binaries compiled for any OS and for any
+# architecture. It is designed to be independent of the host OS and the
+# architecture. The test-annocheck.sh requires docker or podman.
+test-annocheck: $(PROGRAM)
 	$(tooldir)/test-annocheck.sh $(PROGRAM)
-$(target_os)-test-annocheck: PHONY
 
 GEM = up
 sync-default-gems:
-- 
cgit v1.2.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]