安装葫芦,引起的Andr​​oid OS X上小牛错误小牛、葫芦、错误、oid

2023-09-06 10:09:39 作者:再見小時候

大家好/ Ruby专家那里,

Hi guys/rubyists out there,

我需要一些帮助,试图安装葫芦-的Andr​​oid。安装RVM,家庭冲泡后,当我安装葫芦我得到一个奇怪的错误:

I need some help with trying to install Calabash-Android. After installing rvm, home-brew, when I install Calabash i get a strange error:

sudo gem install calabash-android
Building native extensions.  This could take a while...
ERROR:  Error installing calabash-android:
ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby extconf.rb
checking for main() in -lc... yes
creating Makefile

make "DESTDIR="
compiling gherkin_lexer_ar.c
ragel/i18n/ar.c.rl:440:1: warning: control may reach end of non-void function [-    Wreturn-type]
}
^
ext/gherkin_lexer_ar/gherkin_lexer_ar.c:864:18: warning: unused variable     'lexer_en_main' [-Wunused-const-variable]
static const int lexer_en_main = 1;
             ^
2 warnings generated.
linking shared-object gherkin_lexer_ar.bundle
clang: error: unknown argument: '-multiply_definedsuppress' [-Wunused-command-line-    argument-hard-error-in-future]
clang: note: this will be a hard error (cannot be downgraded to a warning) in the future
make: *** [gherkin_lexer_ar.bundle] Error 1


Gem files will remain installed in /Library/Ruby/Gems/2.0.0/gems/gherkin-2.12.2 for   inspection.
Results logged to /Library/Ruby/Gems/2.0.0/gems/gherkin-        2.12.2/ext/gherkin_lexer_ar/gem_make.out
doronkatz@Dorons-MacBook-Air ~ $ mkdir ~/android
doronkatz@Dorons-MacBook-Air ~ $ mkdir ~/android
mkdir: /Users/doronkatz/android: File exists

doronkatz @ Dorons-的MacBook空中〜$ sudo的创业板安装葫芦,机器人 密码: 构建本机扩展。这可能需要一段时间... 错误:错误安装葫芦,机器人:     错误:打造宝石原生扩展失败

doronkatz@Dorons-MacBook-Air ~ $ sudo gem install calabash-android Password: Building native extensions. This could take a while... ERROR: Error installing calabash-android: ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby extconf.rb

检查的main()在-lc ...是的 创建的Makefile

checking for main() in -lc... yes creating Makefile

make "DESTDIR="

编译gherkin_lexer_ar.c     ragel /国际化/ ar.c.rl:440:1:警告:控制​​可能达到非void函数[-Wreturn型]的结束     }     ^     EXT / gherkin_lexer_ar / gherkin_lexer_ar.c:864:18:警告:未使用的变量lexer_en_main[-Wunused const的变量]     静态const int的lexer_en_main = 1;                  ^     2警告产生。    链接共享对象gherkin_lexer_ar.bundle     铿锵:错误:未知的说法:-multiply_definedsup preSS'[-Wunused-命令线 - 参数 - 硬错误的,将来]     铿锵:注意:这将是一个严重的错误(不能被降级为警告)在未来     令: * 的[gherkin_lexer_ar.bundle]错误1

compiling gherkin_lexer_ar.c ragel/i18n/ar.c.rl:440:1: warning: control may reach end of non-void function [-Wreturn-type] } ^ ext/gherkin_lexer_ar/gherkin_lexer_ar.c:864:18: warning: unused variable 'lexer_en_main' [-Wunused-const-variable] static const int lexer_en_main = 1; ^ 2 warnings generated. linking shared-object gherkin_lexer_ar.bundle clang: error: unknown argument: '-multiply_definedsuppress' [-Wunused-command-line- argument-hard-error-in-future] clang: note: this will be a hard error (cannot be downgraded to a warning) in the future make: * [gherkin_lexer_ar.bundle] Error 1

 Gem files will remain installed in /Library/Ruby/Gems/2.0.0/gems/gherkin-2.12.2 for inspection.
Results logged to /Library/Ruby/Gems/2.0.0/gems/gherkin-   2.12.2/ext/gherkin_lexer_ar/gem_make.out

不知道是什么错误意味着,我已经安装了X code工具特立独行也是如此。任何想法了吗?

Not sure what the error means, I have installed Xcode tools for mavericks as well. Any thoughts out there?

推荐答案

我有同样的问题,我只是找到了一个解决方案。

I had the same problem and I just found out a solution for this.

我发现了一个相关的问题就在这里:

I found one related problem here:

HTTP:/ /techespanto.word$p$pss.com/2013/03/29/upgrade-ruby-version-on-mac-osx/

和它提示我升级我的机器上的红宝石版本。在该链接前两个命令不工作,所以我离开你这里就是我所做的:

and it suggested I had to upgrade the ruby version on my machine. The first two commands in that link are not working, so I leave you here what I did:

与安装的命令行工具适用于Mac:

Install the command line tools for mac with:

xcode-select --install

在你的Mac上安装自制软件:

Install homebrew in your mac with:

ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"

安装RVM有:

Install rvm with:

\curl -L https://get.rvm.io | bash -s stable --rails --autolibs=enable

列出了最新的Ruby版本,:

List the latest ruby versions with:

rvm list known

通过安装最新版本的Ruby:

Install the latest ruby version with:

rvm install ruby-<version>

(对我来说是红宝石2.1头

而这一切。希望它能为你的!

And that's all. Hope it works for you as well!

 
精彩推荐
图片推荐