2013-09-23 61 views
1

我試圖在使用sudo -u git -H bundle install --deployment --without development test postgres aws libv8的Ubuntu PowerPC(mac mini)上安裝GitLab,但在libv8(3.11.8.17)上安裝失敗。輸出如下所示。在PPC上安裝GitLab在libv8(3.11.8.17)上失敗,架構錯誤?

我對Ruby是全新的,但我想它是試圖從二進制文件安裝不同的架構?我如何從源代碼安裝?任何幫助感謝!

捆紮機版本1.3.5

寶石版本 2.0.3

紅寶石版本2.0.0p247(2013年6月27日)[PowerPC的Linux的]

UNAME Linux的ubumini 3.2。 0-53-PowerPC的SMP#81,Ubuntu的SMP週四8月22日21時09分31秒UTC 2013 PPC PPC PPC的GNU/Linux

Installing libv8 (3.11.8.17) 
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. 

    /usr/local/bin/ruby extconf.rb 
creating Makefile 
Compiling v8 for ia32 
Using python 2.7.3 
Using compiler: /usr/bin/g++ 
In file included from ../src/allocation.h:31:0, 
       from ../src/allocation.cc:28: 
../src/globals.h:90:2: error: #error Host architecture was not detected as supported by v8 
../src/globals.h:113:2: error: #error Target architecture ia32 is only supported on ia32 host 
make[1]: *** [/home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/vendor/v8/out/ia32.release/obj.target/preparser_lib/src/allocation.o] Error 1 
make: *** [ia32.release] Error 2 
/home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/ext/libv8/location.rb:36:in `block in verify_installation!': libv8 did not install properly, expected binary v8 archive '/home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/vendor/v8/out/ia32.release/obj.target/tools/gyp/libv8_base.a'to exist, but it was not found (Libv8::Location::Vendor::ArchiveNotFound) 
    from /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/ext/libv8/location.rb:35:in `each' 
    from /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/ext/libv8/location.rb:35:in `verify_installation!' 
    from /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/ext/libv8/location.rb:26:in `install!' 
    from extconf.rb:7:in `<main>' 
GYP_GENERATORS=make \ 
    build/gyp/gyp --generator-output="out" build/all.gyp \ 
        -Ibuild/standalone.gypi --depth=. \ 
        -Dv8_target_arch=ia32 \ 
        -S.ia32 -Dv8_can_use_vfp_instructions=true 
make[1]: Entering directory `/home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/vendor/v8/out' 
    CXX(target) /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/vendor/v8/out/ia32.release/obj.target/preparser_lib/src/allocation.o 
make[1]: Leaving directory `/home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/vendor/v8/out' 


Gem files will remain installed in /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17 for inspection. 
Results logged to /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/libv8-3.11.8.17/ext/libv8/gem_make.out 
An error occurred while installing libv8 (3.11.8.17), and Bundler cannot continue. 
Make sure that `gem install libv8 -v '3.11.8.17'` succeeds before bundling. 
+0

自從舊版本3.11(https://github.com/cowboyd/libv8/pull/85:now 3.16.x) – VonC

+0

以來,我嘗試安裝最新的'gem install libv8',它似乎應用了很多修復程序默認爲3.16.14.3版本,相同的結果... – HighTML

+0

也,我認爲你的鏈接提到ARM修復,而不是PPC – HighTML

回答

2

的V8編譯器只用於後端x86,AMD64和ARM。

+0

好的,謝謝Jörg,看起來我必須改變架構:( – HighTML

2

看到https://github.com/cowboyd/libv8/tree/3.11#bring-your-own-v8

用這個命令安裝libv8:

gem install libv8 -- --with-system-v8 

請注意,如果你打算運行自己的V8,您必須安裝V8和標題(libv8-dev的發現Debian發行版)。

+0

在PowerPC架構上做這項工作?Jörg的回答說P8不支持V8編譯器。 – HighTML

2

您可以在另一臺機器上預編譯您的資產,並將公共/資產文件夾scp到您的gitlab power-pc機器。

您必須下載gitlab並在您的開發機器上進行快速設置。這就是我所做的。

# on my development machine 
git clone https://github.com/gitlabhq/gitlabhq.git gitlab 
cd gitlab 
git checkout 6-3-stable 

cp config/gitlab.yml.example config/gitlab.yml 
cp config/unicorn.rb.example config/unicorn.rb 
cp config/database.yml.postgresql config/database.yml 

# edit and set db 
nano config/database.yml 

# https://github.com/CiTroNaK/Installation-guide-for-GitLab-on-OS-X 
brew install icu4c libxml2 
gem install charlock_holmes --version '0.6.9.4' 
bundle install --deployment --without development test mysql aws 

bundle exec rake db:create RAILS_ENV=production 
bundle exec rake assets:precompile RAILS_ENV=production 

scp -r ~/gitlab-project-path/public/assets [email protected]:/home/ubuntu/ 

ssh [email protected] 

# on my remote machine 
sudo rm -rf /home/git/gitlab/public/assets 
sudo mv assets /home/git/gitlab/public 
sudo service gitlab restart 

希望這會有所幫助!

相關問題