- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在尝试在我的计算机上安装 Rails 4.2.0,但在安装 Nokogiri 时遇到问题。我按照“bundle install stopped at Nokogiri ”的第一个答案中的步骤进行操作,但是当我运行 brew install nokogiri
时,我得到以下信息:
Activating libxslt 1.1.28 (from /Users/dseibert/.rvm/rubies/ruby-2.2.0/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.6.2/ports/x86_64-apple-darwin14.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
--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/dseibert/.rvm/rubies/ruby-2.2.0/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/dseibert/.rvm/rubies/ruby-2.2.0/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.6.2 for inspection.
Results logged to /Users/dseibert/.rvm/rubies/ruby-2.2.0/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-14/2.2.0/nokogiri-1.6.6.2/gem_make.out
brew install libxml2
, 我得到
Warning: libxml2-2.9.2 already installed
.
Successfully installed nokogiri-1.6.6.2
.但是当我跑
sudo gem install rails
,我又回到了上面的错误。
最佳答案
尝试这个
gem install nokogiri -- --use-system-libraries=true --with-xml2-include=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include/libxml2/
关于ruby-on-rails - 在升级到 Rails 4.2.0 时由于 libxml2 在 Mac OS X Yosemite v.10.10.1 上安装 Nokogiri 出现问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28258450/
我已经下载了草莓 PERL 并在 Winxp sp3 上使用 CGI Perl Apache 编写了一个应用程序。我使用的库之一(由其他人编写)使用 XML::LibXML。当我加载页面时,它给出内部
libxml 在 libxml.h 中使用以下代码行,但它不与 libxml 捆绑在一起。 #include "config.h" 我正在尝试在 Swift 中使用 XMPPFramework for
我知道这个问题经常出现,但我查看了所有其他答案,但没有一个与我相关。 我正在尝试从源代码编译神经成像软件 FSL(我必须这样做,我的 Linux 发行版不支持它)。我已按照所有说明进行操作 liste
当我运行 cyrus-imapd-2.4.17-caldav-beta9 时出现以下错误: In file included from httpd.c:68:0: httpd.h:48:25: fat
我熟悉 XML,已经将它用于一些简单的用途。但是,我被要求创建一个自定义解决方案(必须使用 Perl)来向 AuthorizeNet 的网关提交付款。 AuthNet 不提供对 Perl 的支持,所以
我有一个示例 Perl 脚本,我试图根据模式加载和验证文件,它们询问各种节点。 #!/usr/bin/env perl use strict; use warnings; use XML::LibXM
我有我正在迭代的非常大的 XML 文档。 XML 主要使用属性而不是节点值。我可能需要在文件中找到许多节点来拼凑一组信息。它们通过不同的 ref 标签值联系在一起。目前,每次我需要定位其中一个节点以从
我正在使用 XML::LibXML,我想添加一条注释,使注释位于标签之外。甚至可以把它放在标签外面吗?我试过 appendChild,insertBefore |之后,没有区别... jun
我正在使用 XML::LibXML,我想添加一条注释,使注释位于标签之外。甚至可以把它放在标签外面吗?我试过 appendChild,insertBefore |之后,没有区别... jun
我正在尝试使用 ISO-8859-1 中的 libxml2 编写 XML 文件。但从文档看来,对于我创建的每个文本节点,我都必须转换为 UTF-8,这是 libxml 的内部编码。然后,当调用 xml
我正在尝试用 C++ 解析 XML 文档。我没有与文档关联的任何形式的元数据。由于我是 XML 的新手,所以我想了解解析此 xml 的最佳方法。我正在使用 libxml2 来实现这一点。 我目前正在做
使用 libxml2 两天后我就遇到了一个问题,这让我很烦。 基本上,我使用套接字通过网络发送一个 xml 缓冲区。当我在服务器上收到它并尝试解析它时,它说: parser error : Input
我正在使用 libxml 的 HTML 解析器来创建 html 文档的 dom 树。 libxml 将每个节点的文本内容作为一个整体字符串(节点)给出,但我的要求是进一步拆分每个文本节点的空格并创建尽
我已经开始在 C 中使用 libxml,并且正在使用 xmlXPathEvalExpression 函数来计算 XPath。 我的 XML 文件实际上代表一个表,每个子节点代表该表中的一行,其属性是对
我有一个可以通过终端运行的源文件 gcc source.c -I/usr/include/libxml2 -lxml2 -o output 但是当我 #include 包含 libxml 源文件的源文
这里似乎有些奇怪。 在下面的示例中,我通过 XPath 查询 ( //book/isbn/text() ) 访问文本节点。 text()有必要强制XML::LibXML允许我使用 XML::LibXM
我有一个 XML 文件,如下 示例.xml test 以下代码未找到 id 标记值: use XML::LibXML; my $filename = 'example.xml'; my
我正在与 XML::LibXML 一起工作在 Perl 中。 假设我有两个 $element由不同(不透明)XPath 查询获得的引用。 (如何)我可以确定,如果两个$element (节点)refs
我有一个问题,我肯定可以使用一些帮助。首先,要温柔。我是 perl 和 LibXML 的新手。我一直在解析文档并将元素放入一个数组中,然后将其写入电子表格列。在测试过程中发现一些节点有多个同名的子节点
在我的一生中,我无法找出正确的代码来访问我的 XML 文件中的注释行。我是否使用 findnodes , find , getElementByTagName (怀疑)。 我是否正确假设这些评论行是可
我是一名优秀的程序员,十分优秀!