Project

General

Profile

Actions

Bug #13509

closed

Ruby 2.4.1 Fails to Compile on Raspberry Pi 3, Raspbian

Added by martin_vahi (Martin Vahi) almost 7 years ago. Updated almost 7 years ago.

Status:
Third Party's Issue
Assignee:
-
Target version:
-
[ruby-core:80866]

Description

The console session:

mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ uname -a
Linux acstorage3334 4.4.50-v7+ #970 SMP Mon Feb 20 19:18:29 GMT 2017 armv7l GNU/Linux
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ echo $CC
gcc
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ echo $XX

mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ which gcc
/usr/bin/gcc
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ which g++
/usr/bin/g++
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabihf/4.9/lto-wrapper
Target: arm-linux-gnueabihf
Configured with: ../src/configure -v --with-pkgversion='Raspbian 4.9.2-10' --with-bugurl=file:///usr/share/doc/gcc-4.9/README.Bugs --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.9 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.9 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libitm --disable-libquadmath --enable-plugin --with-system-zlib --disable-browser-plugin --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.9-armhf/jre --enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.9-armhf --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.9-armhf --with-arch-directory=arm --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-objc-gc --enable-multiarch --disable-sjlj-exceptions --with-arch=armv6 --with-fpu=vfp --with-float=hard --enable-checking=release --build=arm-linux-gnueabihf --host=arm-linux-gnueabihf --target=arm-linux-gnueabihf
Thread model: posix
gcc version 4.9.2 (Raspbian 4.9.2-10) 
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ g++ -v
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabihf/4.9/lto-wrapper
Target: arm-linux-gnueabihf
Configured with: ../src/configure -v --with-pkgversion='Raspbian 4.9.2-10' --with-bugurl=file:///usr/share/doc/gcc-4.9/README.Bugs --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.9 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.9 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libitm --disable-libquadmath --enable-plugin --with-system-zlib --disable-browser-plugin --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.9-armhf/jre --enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.9-armhf --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.9-armhf --with-arch-directory=arm --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-objc-gc --enable-multiarch --disable-sjlj-exceptions --with-arch=armv6 --with-fpu=vfp --with-float=hard --enable-checking=release --build=arm-linux-gnueabihf --host=arm-linux-gnueabihf --target=arm-linux-gnueabihf
Thread model: posix
gcc version 4.9.2 (Raspbian 4.9.2-10) 
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ ./configure --prefix=/home/mmmv_applications_set_01/applications/Ruby/v_2_4_1  --with-jemalloc --enable-multiarch --enable-shared
checking for ruby... /usr/bin/ruby
config.guess already exists
config.sub already exists
checking build system type... armv7l-unknown-linux-gnueabihf
checking host system type... armv7l-unknown-linux-gnueabihf
checking target system type... armv7l-unknown-linux-gnueabihf
checking whether the C compiler works... *** Error in `gcc': double free or corruption (top): 0x00a15620 ***
no
configure: error: in `/home/mmmv_applications_set_01/applications/Ruby/originals/kompil/ruby-2.4.1':
configure: error: C compiler cannot create executables
See `config.log' for more details
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ which ruby
/usr/bin/ruby
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ ruby --version
ruby 2.1.5p273 (2014-11-13) [arm-linux-gnueabihf]
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $ date
Wed Apr 26 08:35:21 EEST 2017
mmmv_applications_set_01@acstorage3334:~/applications/Ruby/originals/kompil/ruby-2.4.1 $



Files

2017_04_26_BUG_Ruby_v_2_4_1_Fails_2_Compile_on_Raspberry_Pi_3.txt (4.68 KB) 2017_04_26_BUG_Ruby_v_2_4_1_Fails_2_Compile_on_Raspberry_Pi_3.txt Console session martin_vahi (Martin Vahi), 04/26/2017 05:44 AM
config.log (12.2 KB) config.log Failing configure step log martin_vahi (Martin Vahi), 04/26/2017 05:49 AM
2017_04_26_BUG_Ruby_v_2_4_1_Fails_2_Compile_on_Raspberry_Pi_3_LLVM_session.txt (39.7 KB) 2017_04_26_BUG_Ruby_v_2_4_1_Fails_2_Compile_on_Raspberry_Pi_3_LLVM_session.txt LLVM session martin_vahi (Martin Vahi), 04/26/2017 05:59 AM
config.log.with_LLVM.txt (1.1 MB) config.log.with_LLVM.txt martin_vahi (Martin Vahi), 04/26/2017 06:02 AM

Updated by martin_vahi (Martin Vahi) almost 7 years ago

If the CXX=="clang++" and CC=="clang", then the configure step completes.

Updated by shyouhei (Shyouhei Urabe) almost 7 years ago

  • Status changed from Open to Third Party's Issue

configure: error: C compiler cannot create executables

It's your compiler who's dying. Report this to Raspbian.

Updated by martin_vahi (Martin Vahi) almost 7 years ago

shyouhei (Shyouhei Urabe) wrote:

configure: error: C compiler cannot create executables

It's your compiler who's dying. Report this to Raspbian.

Does that also apply to the LLVM based session that
does not have such an error message?

Updated by martin_vahi (Martin Vahi) almost 7 years ago

It does seem to be able to compile with
GCC, if the CFLAGS=="" and

./configure --prefix=/home/mmmv_applications_set_01/applications/Ruby/v_2_4_1 --enable-shared --enable-load-relative --enable-multiarch --disable-install-doc --disable-install-rdoc

Previously
CFLAGS==" -mtune=native -ftree-vectorize "

Updated by martin_vahi (Martin Vahi) almost 7 years ago

  • Status changed from Third Party's Issue to Closed

It seems that the problem was the CFLAGS value

-mtune=native

which also caused the build of other applications to fail.
I'll try to report it to Raspbian.

I'm sorry for making this noise here.

Actions #8

Updated by usa (Usaku NAKAMURA) almost 7 years ago

  • Status changed from Closed to Third Party's Issue
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0