質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
Ruby

Rubyはプログラミング言語のひとつで、オープンソース、オブジェクト指向のプログラミング開発に対応しています。

Ruby on Rails

Ruby on Railsは、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

Q&A

2回答

1137閲覧

Ruby on Rails の環境構築がうまくいかない。

hoge_nakatani

総合スコア63

Ruby

Rubyはプログラミング言語のひとつで、オープンソース、オブジェクト指向のプログラミング開発に対応しています。

Ruby on Rails

Ruby on Railsは、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

0グッド

0クリップ

投稿2019/06/23 06:48

https://prog-8.com/docs/rails-env-win
上記サイトにてRuby on Rails の環境構築を行ってます。
「sqlite3のgemをインストールします」までは順調にいったのですが
「gem install sqlite3 -v 1.3.13 --platform=ruby」というコードを打つと下記のような表示になりました。
これはどうすれば解決するのでしょうか?

Fetching: sqlite3-1.3.13.gem (100%) Temporarily enhancing PATH for MSYS/MINGW... Building native extensions. This could take a while... ERROR: Error installing sqlite3: ERROR: Failed to build gem native extension. current directory: C:/Ruby24/lib/ruby/gems/2.4.0/gems/sqlite3-1.3.13/ext/sqlite3 C:/Ruby24/bin/ruby.exe -r ./siteconf20190623-10868-bta5xh.rb extconf.rb checking for sqlite3.h... *** 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. Provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=C:/Ruby24/bin/$(RUBY_BASE_NAME) --with-sqlite3-config --without-sqlite3-config --with-pkg-config --without-pkg-config --with-sqlite3-dir --without-sqlite3-dir --with-sqlite3-include --without-sqlite3-include=${sqlite3-dir}/include --with-sqlite3-lib --without-sqlite3-lib=${sqlite3-dir}/lib C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:457:in `try_do': The compiler failed to generate an executable file. (RuntimeError) You have to install development tools first. from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:588:in `try_cpp' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:1149:in `block in find_header' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:946:in `block in checking_for' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:351:in `block (2 levels) in postpone' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:321:in `open' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:351:in `block in postpone' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:321:in `open' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:347:in `postpone' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:945:in `checking_for' from C:/Ruby24/lib/ruby/2.4.0/mkmf.rb:1148:in `find_header' from extconf.rb:50:in `<main>' To see why this extension failed to compile, please check the mkmf.log which can be found here: C:/Ruby24/lib/ruby/gems/2.4.0/extensions/x86-mingw32/2.4.0/sqlite3-1.3.13/mkmf.log extconf failed, exit code 1

また、上記エラーの状態でRails sを行うと下記のようになりました。

Could not find sqlite3-1.3.13-x86-mingw32 in any of the sources Run `bundle install` to install missing gems.

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答2

0

環境構築は解決して次の問題 CSS に移った様にみえます。
いまのタイトルでは「その辺りはわかるが環境構築は苦手」という人が見てくれないので、この問題は t_kusakabe さんの回答で解決として、別の質問を作ることをお薦めします。

新しい質問では layout と そこで読み込み指定しているFILEが判るようにするのが良いです。

投稿2019/06/23 20:02

winterboum

総合スコア23329

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

0

sqlliteはinstall済みですかね????
まだでしたら一度installしてみてから実行するといいかもしれないです。

https://qiita.com/tabizou/items/af8687201961e4d6b8a4

投稿2019/06/23 10:49

t_kusakabe74

総合スコア549

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

hoge_nakatani

2019/06/23 11:03

ありがとうございます! ただ、次はcssが適応されなくなりました。 原因としては何があがるのでしょうか??
t_kusakabe74

2019/06/23 11:06

環境はdevelopmentでしょうか??? rails sした時のlogを追記で貼ってもらえると何か分かるかもしれません! https://www.sejuku.net/blog/64731 railsのcss周りは上記の仕組みでできているので参考してもらうのもいいかもです!
hoge_nakatani

2019/06/23 11:11

=> Booting Puma => Rails 5.0.7.2 application starting in development on http://localhost:3000 => Run `rails server -h` for more startup options *** SIGUSR2 not implemented, signal based restart unavailable! *** SIGUSR1 not implemented, signal based restart unavailable! *** SIGHUP not implemented, signal based logs reopening unavailable! Puma starting in single mode... * Version 3.12.1 (ruby 2.4.6-p354), codename: Llamas in Pajamas * Min threads: 5, max threads: 5 * Environment: development * Listening on tcp://localhost:3000 Use Ctrl-C to stop Started GET "/" for ::1 at 2019-06-23 20:05:26 +0900 Processing by Rails::WelcomeController#index as HTML Parameters: {"internal"=>true} Rendering C:/Ruby24/lib/ruby/gems/2.4.0/gems/railties-5.0.7.2/lib/rails/templates/rails/welcome/index.html.erb Rendered C:/Ruby24/lib/ruby/gems/2.4.0/gems/railties-5.0.7.2/lib/rails/templates/rails/welcome/index.html.erb (5.0ms) Completed 200 OK in 90ms (Views: 46.1ms | ActiveRecord: 0.0ms) 上記になります! 今行ってる作業はプロゲートで色付けをしてます。 home.scssに以下のコードを貼り付けてください。と指示があり、その通りにcssをマークアップしたのですが全く反応がないです。
t_kusakabe74

2019/06/23 11:35

`.top-main` の中に記述していくと思うのですが、 そのまま `background-image: url("");` としていませんか? `url("")` のなかには画像の名前を入れる必要があります。
hoge_nakatani

2019/06/23 12:10

画像にはリンクを貼ってます 画像だけでなく色も反映されないんです。申し訳ありません、情報が足りないですよね。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだベストアンサーが選ばれていません

会員登録して回答してみよう

アカウントをお持ちの方は

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問