-
-
Notifications
You must be signed in to change notification settings - Fork 14.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mpdcron: fix build by correcting a C function conflict in
nokogiri
`nokogiri` defines a C function called `canonicalize` which conflicts with another function defined in glibc. Upstream has fixed this issue [1], but in a much newer version. And because the affected file has changed since the merged patch [2], it isn't directly applicable to the old gem version `mpdcron` depends on. [1]: sparklemotion/nokogiri#2105 [2]: sparklemotion/nokogiri@7a74cdb (cherry picked from commit 37517db)
- Loading branch information
1 parent
f74804e
commit a8c199b
Showing
2 changed files
with
35 additions
and
0 deletions.
There are no files selected for viewing
22 changes: 22 additions & 0 deletions
22
pkgs/tools/audio/mpdcron/fix-canonicalize-conflict-with-glibc.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
diff --git a/ext/nokogiri/xml_document.c b/ext/nokogiri/xml_document.c | ||
index 1d2119c8..c1c87713 100644 | ||
--- a/ext/nokogiri/xml_document.c | ||
+++ b/ext/nokogiri/xml_document.c | ||
@@ -492,7 +492,7 @@ static int block_caller(void * ctx, xmlNodePtr _node, xmlNodePtr _parent) | ||
* The block must return a non-nil, non-false value if the +obj+ passed in | ||
* should be included in the canonicalized document. | ||
*/ | ||
-static VALUE canonicalize(int argc, VALUE* argv, VALUE self) | ||
+static VALUE nokogiri_xml_document_canonicalize(int argc, VALUE* argv, VALUE self) | ||
{ | ||
VALUE mode; | ||
VALUE incl_ns; | ||
@@ -573,7 +573,7 @@ void init_xml_document() | ||
rb_define_method(klass, "encoding", encoding, 0); | ||
rb_define_method(klass, "encoding=", set_encoding, 1); | ||
rb_define_method(klass, "version", version, 0); | ||
- rb_define_method(klass, "canonicalize", canonicalize, -1); | ||
+ rb_define_method(klass, "nokogiri_xml_document_canonicalize", canonicalize, -1); | ||
rb_define_method(klass, "dup", duplicate_document, -1); | ||
rb_define_method(klass, "url", url, 0); | ||
rb_define_method(klass, "create_entity", create_entity, -1); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters