0
votes

Comment puis-je installer correctement bootsnap sur Windows

J'essaie d'installer Ruby sur des rails avec un installateur de rails. Lorsque j'utilise "Rails Nouveau blog" pour que mes pieds soient mouillés sur démarrer la page Web, je continue à obtenir une erreur de construction pour construire une extension native. J'ai aussi des problèmes similaires installant SQLite3. Les mêmes problèmes apparaissent également sur mon ordinateur portable. (Les deux fenêtres)

jusqu'à présent, j'ai essayé de télécharger cette procédure à suivre ( https://github.com / Shopify / Bootsnap / Problèmes / 134 ), mais soyez coincé quand il me dit de faire le script. J'ai essayé d'exécuter le script donné en IRB, car il a dit à la fois par ligne et copier la pâte. J'ai aussi essayé gem installer bootsnap code> et GEM Installez Bundler --force code>. J'ai également essayé de télécharger différentes versions de Ruby séparément du programme d'installation de Rails pour les deux 2.5 et 2.6. P>

Installing bootsnap 1.4.4 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bootsnap-1.4.4/ext/bootsnap
C:/RailsInstaller/Ruby2.3.3/bin/ruby.exe -I
C:/RailsInstaller/Ruby2.3.3/lib/ruby/site_ruby/2.3.0 -r
./siteconf20190425-5616-1pnzlwm.rb extconf.rb
creating Makefile

current directory:
C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bootsnap-1.4.4/ext/bootsnap
make "DESTDIR=" clean

current directory:
C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bootsnap-1.4.4/ext/bootsnap
make "DESTDIR="
generating bootsnap-i386-mingw32.def
compiling bootsnap.c
bootsnap.c: In function 'bs_cache_path':
bootsnap.c:245:3: warning: unknown conversion type character 'l' in format
[-Wformat]
bootsnap.c:245:3: warning: too many arguments for format [-Wformat-extra-args]
bootsnap.c: In function 'bs_rb_fetch':
bootsnap.c:286:3: warning: ISO C90 forbids mixed declarations and code
[-Wdeclaration-after-statement]
bootsnap.c: In function 'fetch_cached_data':
bootsnap.c:412:3: warning: comparison is always false due to limited range of
data type [-Wtype-limits]
bootsnap.c: In function 'atomic_write_cache_file':
bootsnap.c:484:3: warning: implicit declaration of function 'mkstemp'
[-Wimplicit-function-declaration]
bootsnap.c: In function 'bs_rb_fetch':
bootsnap.c:632:13: warning: 'output_data' may be used uninitialized in this
function [-Wmaybe-uninitialized]
bootsnap.c:603:9: note: 'output_data' was declared here
linking shared-object bootsnap/bootsnap.so
bootsnap.o: In function `atomic_write_cache_file':
C:\RailsInstaller\Ruby2.3.3\lib\ruby\gems\2.3.0\gems\bootsnap-1.4.4\ext\bootsnap/bootsnap.c:484:
undefined reference to `mkstemp'
collect2.exe: error: ld returned 1 exit status
make: *** [bootsnap.so] Error 1

make failed, exit code 2

Gem files will remain installed in
C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bootsnap-1.4.4 for
inspection.
Results logged to
C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/extensions/x86-mingw32/2.3.0/bootsnap-1.4.4/gem_make.out

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

In Gemfile:
  bootsnap


0 commentaires

3 Réponses :


0
votes

Ceci pour SQLite.

gem 'sqlite3', git: "https://github.com/larskanis/sqlite3-ruby", branch: "add-gemspec"


0 commentaires

1
votes

J'ai eu le même bundle installer le problème à l'aide de Rails 5.2.3, Ruby 2.3. Trouvé un article récent d'AngelofDovie qui a travaillé pour moi: Changez le gemme Bootsnap dans votre gemfile vers xxx

Obtenir une erreur (sortie code 2) pour BOOTSNAP, ne permettant pas de configurer Rails Server .

toujours à la recherche de "pourquoi"


0 commentaires

0
votes

Je le résolvez en utilisant ceci en utilisant ceci: xxx

source: https://stackoverflow.com / A / 56275766/534600


0 commentaires