I was installing the gems with which Metasploit operates, and in the bcrypt library I got this error:
Fetching bcrypt 3.1.13
Installing bcrypt 3.1.13 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
current directory:
/data/data/com.termux/files/usr/lib/ruby/gems/2.6.0/gems/bcrypt-3.1.13/ext/mri
/data/data/com.termux/files/usr/bin/ruby -I
/data/data/com.termux/files/usr/lib/ruby/2.6.0 -r ./siteconf20190627-18317-12zh00w.rb
extconf.rb
creating Makefile
current directory:
/data/data/com.termux/files/usr/lib/ruby/gems/2.6.0/gems/bcrypt-3.1.13/ext/mri
make "DESTDIR=" clean
current directory:
/data/data/com.termux/files/usr/lib/ruby/gems/2.6.0/gems/bcrypt-3.1.13/ext/mri
make "DESTDIR="
compiling bcrypt_ext.c
compiling crypt_blowfish.c
arm-linux-androideabi-clang -D__SKIP_GNU -I/data/data/com.termux/files/usr/include
-c -o x86.o x86.S
x86.S:202:29: error: expected '%<type>' or "<type>"
.section .note.GNU-stack,"",@progbits
^
make: *** [<builtin>: x86.o] Error 1
make failed, exit code 2
Gem files will remain installed in
/data/data/com.termux/files/usr/lib/ruby/gems/2.6.0/gems/bcrypt-3.1.13 for inspection.
Results logged to
/data/data/com.termux/files/usr/lib/ruby/gems/2.6.0/extensions/arm-linux/2.6.0/bcrypt-3.1.13/gem_make.out
An error occurred while installing bcrypt (3.1.13), and Bundler cannot
continue.
Make sure that `gem install bcrypt -v '3.1.13' --source 'https://rubygems.org/'`
succeeds before bundling.
In Gemfile:
metasploit-framework was resolved to 5.0.33, which depends on
bcrypt
I already tried with gem install bcrypt -v 3.1.13
and installing ruby-dev, rvm, json, build-essential, but nothing. They have already asked this same question, but the answers are not my solution. Thanks for answering. Best regards.