Cannot install Watir on Jruby 9.1.12.0 - Windows 7 - windows

I am trying to install gems from a local gem repository into Jruby 9.1.12.0 and I am getting stuck on Watir which is pretty much the first one I tried.
I am running on Windows 7 with JDK 1.8.0_131
I get the following:
Error installing watir:
ERROR: Failed to build gem native extension
it looks as though the rest of the error message is complaining about ffi-1.9.18 I am afraid I can't post the exact error message as it is inside a VM that is not internet enabled.
update: full error message:
C:\Ruby\gem>jruby -S gem install watir
Building native extensions. This could take a while...
C:/jruby-9.1.12.0/lib/ruby/stdlib/rubygems/ext/ext_conf_builder.rb:58: warning: Tempfile#unlink or delete called on open file
; ignoring
ERROR: Error installing watir:
ERROR: Failed to build gem native extension.
current directory: C:/jruby-9.1.12.0/lib/ruby/gems/shared/gems/ffi-1.9.18/ext/ffi_c
C:/jruby-9.1.12.0/bin/jruby.exe -r ./siteconf20170718-2540-6mqxiv.rb extconf.rb
current directory: C:/jruby-9.1.12.0/lib/ruby/gems/shared/gems/ffi-1.9.18/ext/ffi_c
make "DESTDIR=" clean
'make' is not recognized as an internal or external command,
operable program or batch file.
current directory: C:/jruby-9.1.12.0/lib/ruby/gems/shared/gems/ffi-1.9.18/ext/ffi_c
make "DESTDIR="
'make' is not recognized as an internal or external command,
operable program or batch file.
make failed, exit code 1
Gem files will remain installed in C:/jruby-9.1.12.0/lib/ruby/gems/shared/gems/ffi-1.9.18 for inspection.
Results logged to C:/jruby-9.1.12.0/lib/ruby/gems/shared/extensions/universal- java-1.8/2.3.0/ffi-1.9.18/gem_make.out

I got this working now. It was obvious from the error message that 'Make' was not being located correctly. I added the correct directory to the path and Watir was installed correctly.

Related

During Openssl build: How to fix "fatal error: apps/app_rand.d: no such file or directory, compilation terminated"

I am attempting to update openssl to 1.1.1 on centos 7 in order to start building OpenLDAP.
After pulling the openssl installation package and unzipping it in /usr/local/src/ I ran ./config --prefix=/usr/local/ssl --openssldir=/usr/local/ssl shared zlib. This command successfully configured openssl.
I then ran the make command to build openssl and got the following error:
cc1: fatal error: apps/app_rand.d: no such file or directory
compilation terminated
make(1): *** (apps/app.rand.o) Error 1
make(1): Leaving directory '/usr/local/src/openssl-1.1.1d'
make: *** (all) Error 2
The apps directory was created and does exist, but the app_rand.d file is not present inside of the apps directory.
I have downloaded all dependencies (i believe)
I am decent in linux, I have my rhcsa, but am not familiar with manually building software libraries like openssl. I have tried to do some research online but have not come up with any solutions. Any advice would be very much appreciated!

Flutter ios Build not working on MacOS Big Sur 11.0 Beta

On MacOS BigSur Beta, I am trying to generate the build of iOS, but that is always giving me the following error.
I tried re-installing flutter, sitching to beta, dev or master and use of Xcode beta as well but nothing worked.
help me if anyone faced same issue and resolve that.
ERROR: Error installing cocoapods:
ERROR: Failed to build gem native extension.
current directory: /Library/Ruby/Gems/2.6.0/gems/json-2.3.1/ext/json/ext/generator
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby -I /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0 -r ./siteconf20200926-66152-11vu3z5.rb extconf.rb
creating Makefile
current directory: /Library/Ruby/Gems/2.6.0/gems/json-2.3.1/ext/json/ext/generator
make "DESTDIR=" clean
current directory: /Library/Ruby/Gems/2.6.0/gems/json-2.3.1/ext/json/ext/generator
make "DESTDIR="
compiling generator.c
In file included from generator.c:1:
In file included from ./../fbuffer/fbuffer.h:5:
In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/include/ruby-2.6.0/ruby.h:33:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/include/ruby-2.6.0/ruby/ruby.h:24:10: fatal error: 'ruby/config.h' file not found
#include "ruby/config.h"
^~~~~~~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/include/ruby-2.6.0/ruby/ruby.h:24:10: note: did not find header 'config.h' in framework 'ruby' (loaded from '/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks')
1 error generated.
make: *** [generator.o] Error 1
make failed, exit code 2
Gem files will remain installed in /Library/Ruby/Gems/2.6.0/gems/json-2.3.1 for inspection.
Results logged to /Library/Ruby/Gems/2.6.0/extensions/universal-darwin-20/2.6.0/json-2.3.1/gem_make.out
Let's try installing old version cocoapods.
Uninstall cocoapods
install old version cocoapods (e.g. 1.8.0)sudo gem install cocoapods --version '=1.8.0' -n /usr/local/bin
flutter clean
pub get
run your project (iOS simulator)
I resolved the error using this procedure.

Installing Nokogiri with a modified Makefile

When I try to create a new rails project on my PowerPC Mac OS X with ruby-2.4.2 and rails-5.1, it started to download and install various gems and during the build step of nokogiri-1.10 I got
cc1: error: unrecognized command line option "-Wno-array-bounds"
during the compilation of libxml2.9.9. I modified the
~/.chefdk/gem/ruby/2.1.0/gems/nokogiri-1.10.1/ext/nokogiri/tmp/powerpc-apple-darwin9.8.0/ports/libxml2/2.9.9/libxml2-2.9.9/Makefile
to comment out the error causing -Wno-array-bounds option and remade the project but it gave the same error again. I guess it's reverting back the original Makefile. How can I install nokogiri with a modified Makefile?

Error while installing Alien::XGBoost library

I'm unable to install the Alien::XGBoost library using the default installation of Strawberry Perl on Windows 10. I'm using the 64-bit version of Strawberry Perl.
When installing Alien::XGBoost, I receive an error on line 49 in the Alien/Build/CommandSequence.pm file as shown below.
gmake[1]: Leaving directory 'C:/STRAWB~1/cpan/build/Alien-XGBoost-0.04-1/_alien/build_wYwS'
Alien::Build::CommandSequence> + md "C:/STRAWB~1/cpan/build/Alien-XGBoost-0.04-1/blib/lib/auto/share/dist/Alien-XGBoost/dynamic"
Alien::Build::CommandSequence> + md "C:/STRAWB~1/cpan/build/Alien-XGBoost-0.04-1/blib/lib/auto/share/dist/Alien-XGBoost/bin"
Alien::Build::CommandSequence> + copy xgboost.exe C:/STRAWB~1/cpan/build/Alien-XGBoost-0.04-1/blib/lib/auto/share/dist/Alien-XGBoost/bin/
The syntax of the command is incorrect.
external command failed at C:/Strawberry/perl/site/lib/Alien/Build/CommandSequence.pm line 49.
gmake: *** [Makefile:2881: _alien/mm/build] Error 2
PABLROD/Alien-XGBoost-0.04.tar.gz
C:\STRAWB~1\c\bin\gmake.exe -- NOT OK
Stopping: 'install' failed for 'Alien::XGBoost'.
The author of the library just confirmed it was a bug. His statement is below. I installed the previous version and it worked perfectly.
Thanks for reporting this!!
It's a bug! I forgot to quote the path.
As you can see both md commands have the path double quoted (""), but not the copy command.
I'm working to fix it and also I'm going to get travis and appveyor integrations to avoid this in the future.
This weekend this will be fixed. Meanwhile please install the previous version:
cpanm PABLROD/Alien-XGBoost-0.03.tar.gz

Issues installing libxml gem for ruby on windows

There are a few threads on questions similar to this, but none have proven effective. I attempted asking on the github page with no luck either.
When I attempt the standard command:
gem install libxml-ruby
I receive an error where the installer cannot find libxml2.dll. I found a stackoverflow thread with a similar issue and followed a user's guidelines here on where to grab the missing libraries and where to include them.
If I add arguments to the install command to point at the directories with the missing libraries using the following:
gem install libxml-ruby -- with-xml2-include=C:\Ruby200\include\libxml2 --with-iconv-include=C:\Ruby200\include
I now get an error where the installer can’t find a “iconv.h” header which is in my C:\Ruby200\include directory.
C:\Users\gonz102>gem install libxml-ruby -- with-xml2-include=C:/Ruby200/include
/libxml2 --with-iconv-include=C:/Ruby200/include
Temporarily enhancing PATH to include DevKit...
Building native extensions with: 'with-xml2-include=C:/Ruby200/include/libxml2 -
-with-iconv-include=C:/Ruby200/include'
This could take a while...
ERROR: Error installing libxml-ruby:
ERROR: Failed to build gem native extension.
C:/Ruby200/bin/ruby.exe extconf.rb with-xml2-include=C:/Ruby200/include/libx
ml2 --with-iconv-include=C:/Ruby200/include
checking for libxml/xmlversion.h in /opt/include/libxml2,/opt/local/include/libx
ml2,/usr/local/include/libxml2,/usr/include/libxml2... yes
checking for xmlParseDoc() in -lxml2... yes
checking for rb_io_bufwrite() in ruby/io.h... yes
creating extconf.h
creating Makefile
make "DESTDIR="
compiling libxml.c
In file included from C:/Ruby200/include/libxml2/libxml/parser.h:810:0,
from ruby_libxml.h:7,
from libxml.c:1:
C:/Ruby200/include/libxml2/libxml/encoding.h:28:19: fatal error: iconv.h: No suc
h file or directory
compilation terminated.
make: *** [libxml.o] Error 1
Gem files will remain installed in C:/Ruby200/lib/ruby/gems/2.0.0/gems/libxml-ru
by-2.9.0 for inspection.
Results logged to C:/Ruby200/lib/ruby/gems/2.0.0/gems/libxml-ruby-2.9.0/ext/libx
ml/gem_make.out
If anyone has any suggestions on what to investigate next or possible solutions I'd greatly appreciate it. I've been stumped on this for over a long while, coming back to it whenever I run into a project with libxml and would gladly take any advice.
Many thanks.
I was unsuccessful with installing libxml version 2.9.0 but 2.7.0 worked just fine. I should specify I'm running windows 7 and Ruby 2.0 32 bit. Here is what I had to do:
-I followed Wik's response here, grabbing all the missing libraries from them mingw64. Admittedly, I'm not sure if I needed all of them, but I sort of took a shotgun approach here.
Added the following to my system path:
Ruby200\lib\ruby\gems\2.0.0\gems\libxml-ruby-2.7.0-x86-mingw32\lib\libs
Executed the following in command line:
gem install libxml-ruby -v2.7.0 -- with-xml2-include:=C/Ruby200/include/libxml2 --with-iconv-include:=C:/Ruby200/include
After that, I the gem, at long last, installed and was actually usable.

Resources