无法启动服务器

时间:2020-04-22 04:55:16

标签: ruby-on-rails ruby vagrant

我试图在流浪汉上启动Rails服务器,但不能。 错误消息在这里。

Could not find gem 'sqlite3 (~> 1.4.0)' in any of the gem sources listed in your Gemfile.
Run `bundle install` to install missing gems.

我做了bundle install,但是...

An error occurred while installing sassc (2.3.0), and Bundler cannot
continue.
Make sure that `gem install sassc -v '2.3.0' --source 'https://rubygems.org/'`
succeeds before bundling.

然后我做了

$ gem install sassc -v'2.3.0'--source'https://rubygems.org/'

消息是

Building native extensions. This could take a while...
ERROR:  Error installing sassc:
    ERROR: Failed to build gem native extension.

    current directory: /home/vagrant/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/sassc-2.3.0/ext
/home/vagrant/.rbenv/versions/2.7.1/bin/ruby -I /home/vagrant/.rbenv/versions/2.7.1/lib/ruby/2.7.0 -r ./siteconf20200422-11227-g7m1en.rb extconf.rb
creating Makefile

current directory: /home/vagrant/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/sassc-2.3.0/ext
make "DESTDIR=" clean

current directory: /home/vagrant/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/sassc-2.3.0/ext
make "DESTDIR="
compiling ./libsass/src/ast.cpp
cc1plus: error: unrecognized command line option "-std=c++11"
make: *** [ast.o] Error 1

make failed, exit code 2

Gem files will remain installed in /home/vagrant/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/sassc-2.3.0 for inspection.
Results logged to /home/vagrant/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/extensions/x86_64-linux/2.7.0/sassc-2.3.0/gem_make.out

然后我做了“ $ rails server -b 192.168.33.10 -d”

但是

Could not find gem 'sqlite3 (~> 1.4.0)' in any of the gem sources listed in your Gemfile.
Run `bundle install` to install missing gems.

结果是相同的...

接下来我该怎么办?

0 个答案:

没有答案