Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't install gem under Ruby 2.1.7 #295

Closed
mentiflectax opened this issue Jan 28, 2016 · 2 comments
Closed

Can't install gem under Ruby 2.1.7 #295

mentiflectax opened this issue Jan 28, 2016 · 2 comments

Comments

@mentiflectax
Copy link

When I run gem install thin under Ruby 2.1.7 (ruby 2.1.7p400 (2015-08-18 revision 51632) [i386-mingw32]), I get following errors.

D:\dev\derek\50web>gem install thin
Building native extensions.  This could take a while...
ERROR:  Error installing thin:
        ERROR: Failed to build gem native extension.

    C:/Ruby21/bin/ruby.exe extconf.rb
checking for main() in -lssleay32... no
checking for main() in -lssleay32... no
checking for main() in -lssleay32... no
checking for main() in -lssleay32... no
checking for rb_trap_immediate in ruby.h,rubysig.h... no
checking for rb_thread_blocking_region()... yes
checking for ruby/thread.h... yes
checking for rb_thread_call_without_gvl() in ruby/thread.h... yes
checking for inotify_init() in sys/inotify.h... no
checking for __NR_inotify_init in sys/syscall.h... no
checking for writev() in sys/uio.h... no
checking for rb_thread_fd_select()... yes
checking for rb_fdset_t in ruby/intern.h... yes
checking for pipe2() in unistd.h... no
checking for accept4() in sys/socket.h... no
checking for SOCK_CLOEXEC in sys/socket.h... no
checking for rb_wait_for_single_fd()... yes
checking for rb_enable_interrupt()... no
checking for rb_time_new()... yes
checking for windows.h... yes
checking for winsock.h... yes
checking for main() in -lkernel32... yes
checking for main() in -lrpcrt4... yes
checking for main() in -lgdi32... yes
checking for clock_gettime()... yes
checking for CLOCK_MONOTONIC_RAW in time.h... no
checking for CLOCK_MONOTONIC in time.h... yes
CXXFLAGS=$(cxxflags) -Wall -Wextra -Wno-deprecated-declarations -Wno-ignored-qua
lifiers -Wno-unused-result -Wno-address
creating Makefile

make "DESTDIR=" clean

make "DESTDIR="
generating rubyeventmachine-i386-mingw32.def
compiling binder.cpp
compiling cmain.cpp
cmain.cpp: In function 'int evma_send_file_data_to_connection(uintptr_t, const c
har*)':
cmain.cpp:802:20: error: 'fstat' was not declared in this scope
  if (fstat (Fd, &st)) {
                    ^
make: *** [cmain.o] Error 1

make failed, exit code 2

Gem files will remain installed in C:/Ruby21/lib/ruby/gems/2.1.0/gems/eventmachi
ne-1.0.9.1 for inspection.
Results logged to C:/Ruby21/lib/ruby/gems/2.1.0/extensions/x86-mingw32/2.1.0/eve
ntmachine-1.0.9.1/gem_make.out

D:\dev\derek\50web>

C:/Ruby21/lib/ruby/gems/2.1.0/extensions/x86-mingw32/2.1.0/eventmachine-1.0.9.1/gem_make.out:

C:/Ruby21/bin/ruby.exe extconf.rb
checking for main() in -lssleay32... no
checking for main() in -lssleay32... no
checking for main() in -lssleay32... no
checking for main() in -lssleay32... no
checking for rb_trap_immediate in ruby.h,rubysig.h... no
checking for rb_thread_blocking_region()... yes
checking for ruby/thread.h... yes
checking for rb_thread_call_without_gvl() in ruby/thread.h... yes
checking for inotify_init() in sys/inotify.h... no
checking for __NR_inotify_init in sys/syscall.h... no
checking for writev() in sys/uio.h... no
checking for rb_thread_fd_select()... yes
checking for rb_fdset_t in ruby/intern.h... yes
checking for pipe2() in unistd.h... no
checking for accept4() in sys/socket.h... no
checking for SOCK_CLOEXEC in sys/socket.h... no
checking for rb_wait_for_single_fd()... yes
checking for rb_enable_interrupt()... no
checking for rb_time_new()... yes
checking for windows.h... yes
checking for winsock.h... yes
checking for main() in -lkernel32... yes
checking for main() in -lrpcrt4... yes
checking for main() in -lgdi32... yes
checking for clock_gettime()... yes
checking for CLOCK_MONOTONIC_RAW in time.h... no
checking for CLOCK_MONOTONIC in time.h... yes
CXXFLAGS=$(cxxflags) -Wall -Wextra -Wno-deprecated-declarations -Wno-ignored-qualifiers -Wno-unused-result -Wno-address
creating Makefile

make "DESTDIR=" clean

make "DESTDIR="
generating rubyeventmachine-i386-mingw32.def
compiling binder.cpp
compiling cmain.cpp
cmain.cpp: In function 'int evma_send_file_data_to_connection(uintptr_t, const char*)':
cmain.cpp:802:20: error: 'fstat' was not declared in this scope
  if (fstat (Fd, &st)) {
                    ^
make: *** [cmain.o] Error 1

make failed, exit code 2
@mentiflectax
Copy link
Author

You can StackOverflow reputation points by answering a question about this issue there - http://stackoverflow.com/questions/35069733/how-can-i-work-around-installation-error-of-thin-gem .

@mentiflectax
Copy link
Author

I fixed the error by installing DevKit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants