- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
我不知道如何在我的电脑上安装 rails。
我有 MacOS X El Capitan。我一直在四处寻找答案并尝试不同的方法,但无法让它发挥作用:
Miguels-MacBook-Pro-3:~ Miguel$ sudo gem install rails
Password:
Building native extensions. This could take a while...
ERROR: Error installing rails:
ERROR: Failed to build gem native extension.
/Users/Miguel/.rbenv/versions/2.2.3/bin/ruby -r ./siteconf20160109-19466-eulg4w.rb extconf.rb
checking if the C compiler accepts ... yes
checking if the C compiler accepts -Wno-error=unused-command-line-argument-hard-error-in-future... no
Building nokogiri using packaged libraries.
Using mini_portile version 2.0.0
checking for iconv.h... yes
checking for gzdopen() in -lz... yes
checking for iconv... yes
************************************************************************
IMPORTANT NOTICE:
Building Nokogiri with a packaged version of libxml2-2.9.2
with the following patches applied:
- 0001-Revert-Missing-initialization-for-the-catalog-module.patch
- 0002-Fix-missing-entities-after-CVE-2014-3660-fix.patch
- 0003-Stop-parsing-on-entities-boundaries-errors.patch
- 0004-Cleanup-conditional-section-error-handling.patch
- 0005-CVE-2015-1819-Enforce-the-reader-to-run-in-constant-.patch
- 0006-Another-variation-of-overflow-in-Conditional-section.patch
- 0007-Fix-an-error-in-previous-Conditional-section-patch.patch
- 0008-CVE-2015-8035-Fix-XZ-compression-support-loop.patch
- 0009-Updated-config.guess.patch
- 0010-Fix-parsering-short-unclosed-comment-uninitialized-access.patch
- 0011-Avoid-extra-processing-of-MarkupDecl-when-EOF.patch
- 0012-Avoid-processing-entities-after-encoding-conversion-.patch
- 0013-CVE-2015-7497-Avoid-an-heap-buffer-overflow-in-xmlDi.patch
- 0014-CVE-2015-5312-Another-entity-expansion-issue.patch
- 0015-Add-xmlHaltParser-to-stop-the-parser.patch
- 0016-Detect-incoherency-on-GROW.patch
- 0017-CVE-2015-7500-Fix-memory-access-error-due-to-incorre.patch
- 0018-CVE-2015-8242-Buffer-overead-with-HTML-parser-in-pus.patch
Team Nokogiri will keep on doing their best to provide security
updates in a timely manner, but if this is a concern for you and want
to use the system library instead; abort this installation process and
reinstall nokogiri as follows:
gem install nokogiri -- --use-system-libraries
[--with-xml2-config=/path/to/xml2-config]
[--with-xslt-config=/path/to/xslt-config]
If you are using Bundler, tell it to use the option:
bundle config build.nokogiri --use-system-libraries
bundle install
Note, however, that nokogiri is not fully compatible with arbitrary
versions of libxml2 provided by OS/package vendors.
************************************************************************
Extracting libxml2-2.9.2.tar.gz into tmp/x86_64-apple-darwin15.0.0/ports/libxml2/2.9.2... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0001-Revert-Missing-initialization-for-the-catalog-module.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0002-Fix-missing-entities-after-CVE-2014-3660-fix.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0003-Stop-parsing-on-entities-boundaries-errors.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0004-Cleanup-conditional-section-error-handling.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0005-CVE-2015-1819-Enforce-the-reader-to-run-in-constant-.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0006-Another-variation-of-overflow-in-Conditional-section.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0007-Fix-an-error-in-previous-Conditional-section-patch.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0008-CVE-2015-8035-Fix-XZ-compression-support-loop.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0009-Updated-config.guess.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0010-Fix-parsering-short-unclosed-comment-uninitialized-access.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0011-Avoid-extra-processing-of-MarkupDecl-when-EOF.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0012-Avoid-processing-entities-after-encoding-conversion-.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0013-CVE-2015-7497-Avoid-an-heap-buffer-overflow-in-xmlDi.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0014-CVE-2015-5312-Another-entity-expansion-issue.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0015-Add-xmlHaltParser-to-stop-the-parser.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0016-Detect-incoherency-on-GROW.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0017-CVE-2015-7500-Fix-memory-access-error-due-to-incorre.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxml2/0018-CVE-2015-8242-Buffer-overead-with-HTML-parser-in-pus.patch... OK
Running 'configure' for libxml2 2.9.2... OK
Running 'compile' for libxml2 2.9.2... OK
Running 'install' for libxml2 2.9.2... OK
Activating libxml2 2.9.2 (from /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/ports/x86_64-apple-darwin15.0.0/libxml2/2.9.2)...
************************************************************************
IMPORTANT NOTICE:
Building Nokogiri with a packaged version of libxslt-1.1.28
with the following patches applied:
- 0001-Adding-doc-update-related-to-1.1.28.patch
- 0002-Fix-a-couple-of-places-where-f-printf-parameters-wer.patch
- 0003-Initialize-pseudo-random-number-generator-with-curre.patch
- 0004-EXSLT-function-str-replace-is-broken-as-is.patch
- 0006-Fix-str-padding-to-work-with-UTF-8-strings.patch
- 0007-Separate-function-for-predicate-matching-in-patterns.patch
- 0008-Fix-direct-pattern-matching.patch
- 0009-Fix-certain-patterns-with-predicates.patch
- 0010-Fix-handling-of-UTF-8-strings-in-EXSLT-crypto-module.patch
- 0013-Memory-leak-in-xsltCompileIdKeyPattern-error-path.patch
- 0014-Fix-for-bug-436589.patch
- 0015-Fix-mkdir-for-mingw.patch
- 0016-Fix-for-type-confusion-in-preprocessing-attributes.patch
- 0017-Updated-config.guess.patch
Team Nokogiri will keep on doing their best to provide security
updates in a timely manner, but if this is a concern for you and want
to use the system library instead; abort this installation process and
reinstall nokogiri as follows:
gem install nokogiri -- --use-system-libraries
[--with-xml2-config=/path/to/xml2-config]
[--with-xslt-config=/path/to/xslt-config]
If you are using Bundler, tell it to use the option:
bundle config build.nokogiri --use-system-libraries
bundle install
************************************************************************
Extracting libxslt-1.1.28.tar.gz into tmp/x86_64-apple-darwin15.0.0/ports/libxslt/1.1.28... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0001-Adding-doc-update-related-to-1.1.28.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0002-Fix-a-couple-of-places-where-f-printf-parameters-wer.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0003-Initialize-pseudo-random-number-generator-with-curre.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0004-EXSLT-function-str-replace-is-broken-as-is.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0006-Fix-str-padding-to-work-with-UTF-8-strings.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0007-Separate-function-for-predicate-matching-in-patterns.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0008-Fix-direct-pattern-matching.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0009-Fix-certain-patterns-with-predicates.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0010-Fix-handling-of-UTF-8-strings-in-EXSLT-crypto-module.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0013-Memory-leak-in-xsltCompileIdKeyPattern-error-path.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0014-Fix-for-bug-436589.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0015-Fix-mkdir-for-mingw.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0016-Fix-for-type-confusion-in-preprocessing-attributes.patch... OK
Running git apply with /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/patches/libxslt/0017-Updated-config.guess.patch... OK
Running 'configure' for libxslt 1.1.28... OK
Running 'compile' for libxslt 1.1.28... OK
Running 'install' for libxslt 1.1.28... OK
Activating libxslt 1.1.28 (from /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1/ports/x86_64-apple-darwin15.0.0/libxslt/1.1.28)...
checking for main() in -llzma... yes
checking for xmlParseDoc() in libxml/parser.h... no
checking for xmlParseDoc() in -lxml2... no
checking for xmlParseDoc() in -llibxml2... no
-----
libxml2 is missing. Please locate mkmf.log to investigate how it is failing.
-----
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/Users/Miguel/.rbenv/versions/2.2.3/bin/$(RUBY_BASE_NAME)
--help
--clean
--use-system-libraries
--enable-static
--disable-static
--with-zlib-dir
--without-zlib-dir
--with-zlib-include
--without-zlib-include=${zlib-dir}/include
--with-zlib-lib
--without-zlib-lib=${zlib-dir}/lib
--enable-cross-build
--disable-cross-build
--with-xml2lib
--without-xml2lib
--with-libxml2lib
--without-libxml2lib
extconf failed, exit code 1
Gem files will remain installed in /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.7.1 for inspection.
Results logged to /Users/Miguel/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-15/2.2.0-static/nokogiri-1.6.7.1/gem_make.out
最佳答案
首先安装必要的库:
$ brew install libxml2 libxslt libiconv
其次,安装nokogiri:
$ sudo gem install nokogiri -- --use-system-libraries --with-xml2-include=/usr/include/libxml2 --with-xml2-lib=/usr/lib
关于ruby-on-rails - 尝试在 mac os x El Capitan 上安装 Rails,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34694911/
更新到 Xcode 12.2 后,由于与 Apple Silicon 相关的链接错误,我的项目开始无法编译。我似乎已经修复了大部分问题,但是一个构建静态链接框架的子项目给我带来了问题。然而,具有明显相
我有一台旧的 MacBook Pro,我在其中制作了两个应用程序并提交到应用程序商店。所以基本上签名身份在该机器的钥匙串(keychain)中。在 Mavericks 升级后,我不得不从那台计算机转移
我正在 MAC OSX 10.6 上编写一个示例应用程序,其 gcc 版本为 4.2。我正在使用 gcc 4.2 版编译应用程序。它在同一台机器上工作正常,但在 MAC OSX 10.5 (gcc 4
这是我的简单 mac 地址生成器: private String randomMACAddress(){ Random rand = new Random(); byte[] macA
我一直在寻找一种将十进制 MAC 地址转换为十六进制地址的方法。 例如 170.187.204.0.17.34至AA:BB:CC:00:11:22 . 致Convert HEX to Decimal
我想使用 UISceneSession 的委托(delegate)方法当用户将注意力从应用程序(窗口)移开,然后又回到应用程序(窗口)时,生命周期有助于通知我的 Mac Catalyst 应用程序。
我在签署 Mac 应用程序安装程序时遇到问题,我计划在 Mac 应用商店之外分发该应用程序。我正在使用开发人员安装程序证书来签署应用程序,但它给出了一些错误。下面是我用来签署应用程序的命令。 prod
Mac Catalyst 允许调整窗口大小,有没有办法为 Mac Catalyst 应用程序提供最小窗口大小? 最佳答案 只需将以下代码块添加到您的 application:didFinishLaun
这是一个非常理论性的问题,但对我来说很安静,即我如何进行下一步。 我正在开发一个SwiftUI MacOS应用程序,用户可以在其中上传自己的文件。元数据将存储在CoreData中,而我将文件手动存储在
滑动删除在 maccatalyst 中不起作用。相同的代码在 iPad 上运行良好。 在 maccatalyst 中未调用 UITableview trailingSwipeActionsConfig
我有两台 Mac,在进行 iPad 开发时,如果可以让另一台 Mac 启动模拟器并在构建完成后加载应用程序,我很感兴趣。 如果 iPad 应用程序在一台 Mac 屏幕和 Xcode 的模拟器中运行,所
我有一个用 objective-c 开发的 mac 应用程序。cpp 中还有另一个命令行中间应用程序,它是 native 主机应用程序,用于接收来自 chrome 扩展的消息。每当中间应用程序从扩展程
是否可以使用来自 Comodo 或 Thawte 的代码签名证书来签署应用程序并通过 Gatekeeper,或者我需要为此目的拥有 Mac 开发者订阅? 最佳答案 您必须是 Mac Developer
我正在使用 C++ 和 OpenGL/SDL 编写一个游戏,使用 Visual Studio 作为我的 IDE。我没有 Mac,甚至对这个平台都不熟悉。但我还是想发布给 Mac 用户。 我有三个问题。
我想将 MAC 地址 00163e2fbab7(存储为字符串)转换为其字符串表示形式 00:16:3e:2f:ba:b7。最简单的方法是什么? 最佳答案 使用一种完全迂回的方法来利用现有的一次将两个十
无法连接到Mac上的MySQL工作台。我收到以下错误:无法连接,服务器可能未运行。无法连接到‘127.0.0.1’上的MySQL服务器(61)如有帮助,将不胜感激。。谢谢!
我已经搜索了很长时间,似乎无法找到这个问题的答案。在 SO 上只找到两个问题/答案,但他们仍然没有回答这个问题 ( https://stackoverflow.com/search?q=netcore
我们在 Docker for Mac 中有一个 LoadBalancer 真是太酷了。 我对创建的端口有疑问: apiVersion: v1 kind: Service metadata: nam
我有一个我一直在从事的小型开源 OSX 项目,我想在 App Store 之外分发。 随着即将发布的 Mountain Lion,我想提供一个证书,以减少安装过程中的痛苦。 使用 App Store,
我的一台 Mac 没有互联网连接。我需要使用 docker pull。我的想法是,我将在我的一台具有互联网连接的 Mac 中使用 docker pull,然后将其复制到我没有互联网连接的 Mac。如何
我是一名优秀的程序员,十分优秀!