복붙노트

[RUBY-ON-RAILS] 번들 / 업데이트를 설치하십시오 libv8 (therubyracer) 설치 (기본 확장자) 실패

RUBY-ON-RAILS

번들 / 업데이트를 설치하십시오 libv8 (therubyracer) 설치 (기본 확장자) 실패

나는 최근에 libv8 (therubyracer에 대한 요구 사항)에 설치 문제에 내 보석 번들 그러나 달렸다을 업데이트하고 싶었 :

Installing libv8 (3.3.10.3) with native extensions /usr/local/rvm/rubies/ruby-1.9.3-head/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:552:in `rescue in block in build_extensions': ERROR: Failed
 to build gem native extension. (Gem::Installer::ExtensionBuildError)

        /usr/local/rvm/rubies/ruby-1.9.3-head/bin/ruby extconf.rb 
Checking for Python...*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers.  Check the mkmf.log file for more
details.  You may need configuration options.

나는 therubyracer GitHub의 사이트에서 문제의 보고서를 발견하고 그것을하고 다시 설치 libv8를 제거하기 위해 제안, 그러나 이것은 내 우분투 11.04 시스템에서 작업을하지 않습니다. 모든 아이디어를 - 혹은 내가 잠시 동안 이전 버전과 붙어 무엇입니까?

해결법

  1. ==============================

    1.잠시 동안 그 일을 시도해보십시오

    잠시 동안 그 일을 시도해보십시오

    gem 'therubyracer'
    gem 'libv8', '3.16.14.3'
    

    도움이 될 것입니다.

    또한 새로운 들러와 함께 더 나은 : 보석 설치 들러 --pre

  2. ==============================

    2.나는 나의 좋은 오래된 우분투 10.04 (64)에 유사한 문제가 있었다

    나는 나의 좋은 오래된 우분투 10.04 (64)에 유사한 문제가 있었다

    내가 프로젝트를 업데이트 한 후 Gemfile 그 보석을했다

      gem 'libv8', '~> 3.11.8'
      gem "therubyracer", '>= 0.11.0beta1', :require => 'v8'
    

    내가 달릴 때 '설치 번들'나는 오류가 발생했습니다

    Installing therubyracer (0.11.0beta1) with native extensions 
    Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
    
            /home/sseletskyy/.rvm/rubies/ruby-1.9.3-p194/bin/ruby extconf.rb 
    checking for main() in -lpthread... yes
    creating Makefile
    
    make
    compiling array.cc
    compiling script.cc
    compiling object.cc
    compiling constants.cc
    compiling signature.cc
    compiling value.cc
    compiling locker.cc
    compiling init.cc
    compiling heap.cc
    compiling date.cc
    compiling message.cc
    compiling accessor.cc
    compiling context.cc
    compiling exception.cc
    compiling backref.cc
    compiling trycatch.cc
    compiling gc.cc
    compiling handles.cc
    compiling stack.cc
    compiling template.cc
    compiling function.cc
    compiling primitive.cc
    compiling rr.cc
    compiling v8.cc
    compiling invocation.cc
    compiling string.cc
    compiling external.cc
    compiling constraints.cc
    linking shared-object v8/init.so
    /home/sseletskyy/.rvm/gems/ruby-1.9.3-p194/gems/libv8-3.11.8.2-x86_64-linux/vendor/v8/out/x64.release/obj.target/tools/gyp/libv8_base.a: could not read symbols: No such file or directory
    collect2: ld returned 1 exit status
    make: *** [init.so] Error 1
    
    
    Gem files will remain installed in /home/sseletskyy/.rvm/gems/ruby-1.9.3-p194/gems/therubyracer-0.11.0beta1 for inspection.
    Results logged to /home/sseletskyy/.rvm/gems/ruby-1.9.3-p194/gems/therubyracer-0.11.0beta1/ext/v8/gem_make.out
    An error occured while installing therubyracer (0.11.0beta1), and Bundler cannot continue.
    Make sure that `gem install therubyracer -v '0.11.0beta1'` succeeds before bundling.
    

    여기에 그 블록 신속하게 해결하기 위해 나를 위해 일한 단계의 목록은

  3. ==============================

    3.우분투 11.04

    우분투 11.04

    gem "therubyracer", '0.11.1'
    gem 'libv8'
    

    위의 모든 단계를 내 문제를 해결 :)

  4. ==============================

    4.나는 최근에 같은 문제로 실행했습니다. 여기에 가이드 '레일 시작하기'를 RoR.org에서 도움이되는 정보의 비트가 :

    나는 최근에 같은 문제로 실행했습니다. 여기에 가이드 '레일 시작하기'를 RoR.org에서 도움이되는 정보의 비트가 :

    (아마도이 ​​최신 버전으로, 지금까지하지만 그 읽을하지 않았다) 나는 다른 곳에서 읽은는 therubyracer 보석 용 Windows 지원은 '3.3.10.4'버전이없는 것 같다 무엇을 기준으로합니다. 나는 파이썬 2.7을 설치하고 컴파일하지만 여전히 환경 설정 과정에서 나중에 오류가 발생할 수있어.

    그래서이 내려 온다. 여기 therubyracer 문서를 확인하십시오. 'therubyracer은'(이 기능을 제공합니다 :

    당신이 절대적으로 이러한 기능이 필요한 경우 당신은 * nix에서 스크립트로 전환하고, 개발 / 생산 환경 Windows를 드롭한다. 그렇지 않으면 당신은 내가 무슨 짓을 할 수 있으며, 'therubyracer'나 (내 Gemfile에서 제거) 'libv8'설치하지 않도록 선택합니다. 난 그냥 두 보석을 무시 그래서 나는, 내가 함께이 문제가 발생하고있어 사이트와 자바 스크립트에 의존하지 않고 모두 잘 보인다 (지금까지).

    이 필요로하는 다른 사람을 도움이되기를 바랍니다!

  5. ==============================

    5.우분투 12.04

    우분투 12.04

    gem 'libv8', '3.11.8.3'
    gem 'therubyracer', '0.11.0beta5'
    

    therubyracer 내 문제를 해결 위의 버전을 지정.

    누군가가 위의 제안 또한, 나는 최신 들러를 사용 :

    gem install bundler --pre
    
  6. ==============================

    6.당신의 Gemfile에 루비 참조하십시오

    당신의 Gemfile에 루비 참조하십시오

    gem 'therubyracer', :platform => :ruby
    

    다음 번들 업데이트를 실행.

  7. ==============================

    7.이 터미널 명령을 사용하면 우분투 16.04에 나를 위해 그것을 고정

    이 터미널 명령을 사용하면 우분투 16.04에 나를 위해 그것을 고정

    sudo apt-get install g++
    sudo apt-get install build-essential
    
  8. from https://stackoverflow.com/questions/8126465/bundle-install-update-libv8-therubyracer-installation-fails-with-native-ex by cc-by-sa and MIT license