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

gem install failure under MSYS2, confuses MSYS with Linux/Cygwin? #324

Closed
Jodocus opened this issue Apr 4, 2017 · 2 comments
Closed

gem install failure under MSYS2, confuses MSYS with Linux/Cygwin? #324

Jodocus opened this issue Apr 4, 2017 · 2 comments

Comments

@Jodocus
Copy link

Jodocus commented Apr 4, 2017

When trying to install the json gem via gem install json, I get

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

current directory: /home/<...>/.gem/ruby/2.3.0/gems/json-2.0.3/ext/json/ext/generator/usr/bin/ruby.exe -r ./siteconf20170404-3632-18oxo5w.rb extconf.rb
creating Makefile

current directory: /home/<...>/.gem/ruby/2.3.0/gems/json-2.0.3/ext/json/ext/generator
make "DESTDIR=" clean
rm -f
rm -f generator.so  *.o  *.bak mkmf.log .*.time

current directory: /home/<...>/.gem/ruby/2.3.0/gems/json-2.0.3/ext/json/ext/generator
make "DESTDIR="
gcc -I. -I/usr/include/ruby-2.3.0/x86_64-msys -I/usr/include/ruby-2.3.0/ruby/backward -I/usr/include/ruby-2.3.0 -I. -DJSON_GENERATOR -D_FORTIFY_SOURCE=2    -march=x86-64 -mtune=generic -O2 -pipe -fno-strict-aliasing   -o generator.o -c generator.c
In file included from C:/util/msys64/usr/include/ruby-2.3.0/ruby/ruby.h:36:0,
             from C:/util/msys64/usr/include/ruby-2.3.0/ruby.h:33,
             from ../fbuffer/fbuffer.h:5,
             from generator.c:1:
C:/util/msys64/usr/include/ruby-2.3.0/ruby/defines.h:61:25: fatal error: sys/select.h: No such file or directory
 # include <sys/select.h>
                     ^
compilation terminated.
make: *** [Makefile:239: generator.o] Fehler 1

make failed, exit code 2

Gem files will remain installed in /home/<...>/.gem/ruby/2.3.0/gems/json-2.0.3 for inspection.
Results logged to /home/<...>/.gem/ruby/2.3.0/extensions/x86_64-msys/2.3.0/json-2.0.3/gem_make.out

There is no <sys/select.h> on Windows/MSYS2. What can I do about it?

@MSP-Greg
Copy link
Contributor

@Jodocus

The gem will install with RubyInstaller2 (or similar) builds. Appveyor results here.

I believe the ragel package needs to be installed.

@hsbt
Copy link
Collaborator

hsbt commented Dec 1, 2023

I could install json-2.6.3 with RubyInstaller2 + devkit.

@hsbt hsbt closed this as not planned Won't fix, can't repro, duplicate, stale Dec 1, 2023
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

3 participants