Bug #10008
closedconftest crashed: installing mri 2.1.2: EXC_BAD_ACCESS (SIGABRT)
Description
crash dump: https://gist.github.com/jaredbeck/be73c376b860d8d6eed9
cd ~/.rbenv
git log --oneline | head -n1
# 13a474c Get rid of explicit exit in fish branch of `rbenv-init`
cd plugins/ruby-build/
git log --oneline | head -n1
# c819790 ruby-build 20140702
but .. the install finished!
rbenv global 2.1.2
ruby --version
# ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-darwin13.0]
echo "puts '<3 ruby'" | ruby
# <3 ruby
Using xcode 5.1.1
Files
Updated by nobu (Nobuyoshi Nakada) about 10 years ago
Which conftest
?
Some conftest
s are expected to segfault.
Updated by nobu (Nobuyoshi Nakada) about 10 years ago
- Status changed from Open to Feedback
- Priority changed from Normal to 3
Updated by hsbt (Hiroshi SHIBATA) about 10 years ago
Is conftest part of debugger gem?
Updated by jaredbeck (Jared Beck) about 10 years ago
Steps to reproduce:
- rbenv uninstall 2.1.2
- rbenv install 2.1.2
Crash dump:
https://gist.github.com/jaredbeck/127e61aa73a16c614b6d
ruby_build log:
https://gist.github.com/jaredbeck/3f6de8e3e432a51ae707
versions:
gcc version 4.2.1 (Apple Inc. build 5666) (dot 3)
rbenv: 13a474c
ruby-build: c819790 ruby-build 20140702
Updated by jaredbeck (Jared Beck) about 10 years ago
Simpler steps to reproduce:
- Download ruby 2.1.2 source
- ./configure
So, I don't think this has anything to do with ruby-build :)
Updated by jaredbeck (Jared Beck) about 10 years ago
Which conftest?
I think conftest is defined in the configure
script. For me, it's around line 20376, which looks like:
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Furthermore, line 20389 defines a sigsegv
function.
void sigsegv(int signum, siginfo_t *info, void *ctx){
This sigsegv
function can be seen on line 3 of the "Dispatch queue" from the crash dump:
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libsystem_kernel.dylib 0x00007fff8b3f7866 __pthread_kill + 10
1 libsystem_pthread.dylib 0x00007fff8f8df35c pthread_kill + 92
2 libsystem_c.dylib 0x00007fff9000ab1a abort + 125
3 conftest 0x000000010c2dee55 sigsegv + 37
4 libsystem_platform.dylib 0x00007fff8cfdd5aa _sigtramp + 26
5 ??? 000000000000000000 0 + 0
6 libdyld.dylib 0x00007fff8efa35fd start + 1
Finally, it may be relevant that my ./configure
output reports "broken backtrace":
checking for broken backtrace... yes
I hope that helps!
Updated by jaredbeck (Jared Beck) about 10 years ago
If I replace the whole test for "broken backtrace" with a hardcoded value, then I can run ./configure
without a crash.
See my proof of concept patch (attached) which can be compared to tag v2_1_2 in git.
Updated by nobu (Nobuyoshi Nakada) about 10 years ago
- Status changed from Feedback to Rejected
It makes no sense.
Updated by nobu (Nobuyoshi Nakada) about 10 years ago
- Status changed from Rejected to Open
- Backport changed from 2.0.0: UNKNOWN, 2.1: UNKNOWN to 2.0.0: DONTNEED, 2.1: REQUIRED
Updated by nobu (Nobuyoshi Nakada) about 10 years ago
- Status changed from Open to Closed
- % Done changed from 0 to 100
Applied in changeset r46796.
configure.in: exit with failure
- configure.in (rb_cv_broken_backtrace): exit with failure
normally, no needs to abort. [ruby-core:63678] [Bug #10008]
Updated by nagachika (Tomoyuki Chikanaga) almost 10 years ago
- Backport changed from 2.0.0: DONTNEED, 2.1: REQUIRED to 2.0.0: DONTNEED, 2.1: DONE
Backported into ruby_2_1
branch at r47418.