Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 922545

Summary: ERROR: dev-lang/ruby-3.2.2-r5::gentoo_prefix failed (configure phase)
Product: Gentoo/Alt Reporter: Askar Bektassov <askar.bektassov>
Component: Prefix SupportAssignee: Gentoo Prefix <prefix>
Status: RESOLVED FIXED    
Severity: normal CC: askar.bektassov
Priority: Normal    
Version: unspecified   
Hardware: ARM64   
OS: OS X   
URL: https://github.com/rbenv/ruby-build/issues/1080
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: emerge --info
build.log
config.log

Description Askar Bektassov 2024-01-20 15:15:24 UTC
configuration fails when testing LDFLAGS.

Reproducible: Always

Steps to Reproduce:
emerge "=dev-lang/ruby-3.2.2-r5" -pv
Actual Results:  
configure: error: something wrong with LDFLAGS="-Wl,-dead_strip_dylibs"

Expected Results:  
successful emerge

By default, LDFLAGS="-Wl,-dead_strip_dylibs". Tried an empty LDFLAGS="", or appending -ld_classic or -ld64, without success.

More detail available in config.log.

configure:9880: checking whether LDFLAGS is valid
configure:9900: arm64-apple-darwin21-cc -o conftest -O2 -pipe -fno-strict-aliasing   -Wl,-dead_strip_dylibs conftest.c  >&5
ld: warning: duplicate -rpath '/Users/askarbektassov/Gentoo/usr/lib/gcc/arm64-apple-darwin21/13' ignored
ld: warning: duplicate -rpath '/Users/askarbektassov/Gentoo/usr/lib' ignored
ld: warning: ignoring duplicate libraries: '-lgcc'
configure:9900: $? = 0
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define HAVE_STDIO_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_WCHAR_H 1
| #define STDC_HEADERS 1
| #define _ALL_SOURCE 1
| #define _DARWIN_C_SOURCE 1
| #define _GNU_SOURCE 1
| #define _HPUX_ALT_XOPEN_SOCKET_API 1
| #define _NETBSD_SOURCE 1
| #define _OPENBSD_SOURCE 1
| #define _POSIX_PTHREAD_SEMANTICS 1
| #define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1
| #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
| #define __STDC_WANT_IEC_60559_DFP_EXT__ 1
| #define __STDC_WANT_IEC_60559_EXT__ 1
| #define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1
| #define __STDC_WANT_IEC_60559_TYPES_EXT__ 1
| #define __STDC_WANT_LIB_EXT2__ 1
| #define __STDC_WANT_MATH_SPEC_FUNCS__ 1
| #define _TANDEM_SOURCE 1
| #define __EXTENSIONS__ 1
| /* end confdefs.h.  */
|
| int
| main (void)
| {
|
|   ;
|   return 0;
| }
configure:9907: result: no
configure:9909: error: something wrong with LDFLAGS="-Wl,-dead_strip_dylibs"
Comment 1 Askar Bektassov 2024-01-20 15:15:56 UTC
Created attachment 882691 [details]
emerge --info
Comment 2 Askar Bektassov 2024-01-20 15:16:09 UTC
Created attachment 882692 [details]
build.log
Comment 3 Askar Bektassov 2024-01-20 15:16:23 UTC
Created attachment 882693 [details]
config.log
Comment 4 Fabian Groffen gentoo-dev 2024-01-21 14:40:14 UTC
The problem is ruby forces werror checking, which means the warning emitted are treated as failure, even though the linking succeed just fine.
Comment 5 Fabian Groffen gentoo-dev 2024-02-18 19:46:15 UTC
without the error checking ruby still fails to compile
Comment 6 Askar Bektassov 2024-06-03 20:37:48 UTC
As a follow-up, I installed ruby-3.2.4 without issues. Suggest closing this.
Comment 7 Fabian Groffen gentoo-dev 2024-06-04 08:54:50 UTC
yes, I implemented duplicate reduction in the linker wrapper, forgot to close this, thanks!