RVM + Ruby 1.9.3 + MacPorts Typhoeus Missing>捆绑安装卡在FFI

时间:2014-02-05 02:49:01

标签: ruby wordpress rvm macports

我在MacCorts的OSC Mavericks上有Ruby版本管理器RVM。我试图更新在ruby上运行的WPScan。我正在尝试更新:

ruby​​ wpscan.rb --update 当我遇到这个错误: 在这台机器上可用的宝石中找不到宝石'typhoeus(> = 0.6.3)红宝石'。 我之前有过这个错误。所以运行捆绑安装。然后我遇到了其他错误:

sudo bundle install
Fetching gem metadata from https://rubygems.org/.........
Fetching gem metadata from https://rubygems.org/..
Installing ffi (1.9.3) with native extensions 
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.

        /Users/jasper/.rvm/rubies/ruby-1.9.3-p362/bin/ruby extconf.rb 
checking for ffi_call() in -lffi... yes
-----------------cut ----------------
checking for ffi_prep_cif_var()... yes
creating extconf.h
creating Makefile

make
compiling AbstractMemory.c
compiling ArrayType.c
compiling Buffer.c
compiling Call.c
Call.c:303:5: warning: implicit declaration of function 'rb_thread_call_without_gvl' is invalid in C99 [-Wimplicit-function-declaration]
    rbffi_thread_blocking_region(call_blocking_function, data, (void *) -1, NULL);
    ^
./Thread.h:78:39: note: expanded from macro 'rbffi_thread_blocking_region'
# define rbffi_thread_blocking_region rb_thread_call_without_gvl
                                      ^
1 warning generated.
compiling ClosurePool.c
compiling DataConverter.c
compiling DynamicLibrary.c
compiling ffi.c
compiling Function.c
Function.c:479:33: warning: incompatible pointer types passing 'VALUE (void *)' to parameter of type 'void *(*)(void *)' [-Wincompatible-pointer-types]
        rb_thread_call_with_gvl(callback_with_gvl, &cb);
                                ^~~~~~~~~~~~~~~~~
Function.c:102:46: note: passing argument to parameter 'func' here
extern void *rb_thread_call_with_gvl(void *(*func)(void *), void *data1);
                                             ^
Function.c:563:9: warning: implicit declaration of function 'rb_thread_call_without_gvl' is invalid in C99 [-Wimplicit-function-declaration]
        rb_thread_call_without_gvl(async_cb_wait, &w, async_cb_stop, &w);
        ^
Function.c:738:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
3 warnings generated.
compiling FunctionInfo.c
compiling LastError.c
compiling LongDouble.c
compiling MappedType.c
compiling MemoryPointer.c
compiling MethodHandle.c
compiling Platform.c
compiling Pointer.c
compiling Struct.c
compiling StructByReference.c
compiling StructByValue.c
compiling StructLayout.c
compiling Thread.c
compiling Type.c
compiling Types.c
compiling Variadic.c
linking shared-object ffi_c.bundle

make install
make: /opt/local/bin/gmkdir: No such file or directory
make: [/Users/jasper/.rvm/rubies/ruby-1.9.3-p362/lib/ruby/gems/1.9.1/gems/ffi-1.9.3/lib/ffi_c.bundle] Error 1 (ignored)
/opt/local/bin/ginstall -c -m 0755 ffi_c.bundle /Users/jasper/.rvm/rubies/ruby-1.9.3-p362/lib/ruby/gems/1.9.1/gems/ffi-1.9.3/lib
make: /opt/local/bin/ginstall: No such file or directory
make: *** [/Users/jasper/.rvm/rubies/ruby-1.9.3-p362/lib/ruby/gems/1.9.1/gems/ffi-1.9.3/lib/ffi_c.bundle] Error 1


Gem files will remain installed in /Users/jasper/.rvm/rubies/ruby-1.9.3-p362/lib/ruby/gems/1.9.1/gems/ffi-1.9.3 for inspection.
Results logged to /Users/jasper/.rvm/rubies/ruby-1.9.3-p362/lib/ruby/gems/1.9.1/gems/ffi-1.9.3/ext/ffi_c/gem_make.out
An error occurred while installing ffi (1.9.3), and Bundler cannot continue.
Make sure that `gem install ffi -v '1.9.3'` succeeds before bundling.

我有/ opt / local / bin / gmdir。我自己添加了它,但错误仍然存​​在,然后有一些警告和其他目录似乎不存在的错误。脚本为什么不创建它们?任何简单的方法可以解决这些错误,以便我可以运行我最喜欢的WP扫描仪吗?

NB我认为RVM可以在没有MacPorts的情况下工作......但它正在寻找MacPorts中的目录。

1 个答案:

答案 0 :(得分:0)

gmkdir是GNU Core Utilities的一部分。

您可以使用命令sudo port install coreutils安装它们。