Windows上的Puma安装错误 [英] Puma installation error on windows

查看:158
本文介绍了Windows上的Puma安装错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Windows机器上安装puma gem。我收到以下错误。通过几个论坛,但徒劳无功。

I am trying to install puma gem on Windows machine. I am getting the following error. Went through a couple of forums but in vain.

C:/railsInstaller/Ruby2.0.0/bin/ruby.exe extconf.rb 
creating Makefile

make
generating puma_http11-i386-mingw32.def
compiling http11_parser.c
ext/http11/http11_parser.rl: In function 'puma_parser_execute':
ext/http11/http11_parser.rl:111:3: warning: comparison between signed and unsigned integer expressions
compiling io_buffer.c
io_buffer.c: In function 'buf_to_str':
io_buffer.c:119:3: warning: pointer targets in passing argument 1 of 'rb_str_new' differ in signedness
c:/RailsInstaller/Ruby2.0.0/include/ruby-2.0.0/ruby/intern.h:668:7: note: expected 'const char *' but argument is of type 'uint8_t *'
compiling mini_ssl.c
In file included from mini_ssl.c:3:0:
c:/RailsInstaller/Ruby2.0.0/include/ruby-2.0.0/ruby/backward/rubyio.h:2:2: warning: #warning use "ruby/io.h" instead of "rubyio.h"
mini_ssl.c:4:25: fatal error: openssl/bio.h: No such file or directory
compilation terminated.
make: *** [mini_ssl.o] Error 1

我尝试安装在 https://github.com/puma/puma/issues/202上提到的openSSL头文件包和库,链接不起作用。

I have tried to install openSSL Headers packages and libraries as mentioned on https://github.com/puma/puma/issues/202 , the links don't work.

推荐答案

我运行 bundle update bundle install 之前解决了这个问题。

I ran bundle update before bundle install and that solved the issue for me.

我不确定那个是唯一有帮助的,因为我之前手动更新了puma,使用以下步骤:

I'm not sure if that was the only thing that helped, as I manually updated puma before that, using these steps:


  1. 检查了Ruby正在使用哪个版本的openssl运行 ruby​​ -v -ropenssl -eputs OpenSSL :: OPENSSL_VERSION


  2. 下载正确的openssl版本< a href =http://packages.openknapsack.org/openssl/openssl-1.0.0o-x86-windows.tar.lzma> http://packages.openknapsack.org/openssl/openssl-1.0.0o-x86 -windows.tar.lzma
    (从https://github.com/hicknhack-software/rails-disco/wiki/Installing-puma-on-windows并根据#1的输出进行编辑)。 使用 http://提取openssl www.7-zip.org 到C:\RailsInstaller\openssl

  3. gem install puma - --with-opt-dir = C:/ RailsInstaller / openssl

  1. Checked which version of openssl Ruby is using by running ruby -v -ropenssl -e "puts OpenSSL::OPENSSL_VERSION"
  2. Downloaded the right openssl version from http://packages.openknapsack.org/openssl/openssl-1.0.0o-x86-windows.tar.lzma (got the link from https://github.com/hicknhack-software/rails-disco/wiki/Installing-puma-on-windows and edited it based on the output of #1).
  3. Extracted openssl using http://www.7-zip.org to C:\RailsInstaller\openssl
  4. gem install puma -- --with-opt-dir=C:/RailsInstaller/openssl

这篇关于Windows上的Puma安装错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆