diff options
| author | Steven Peters | 2013-08-23 17:27:20 -0700 |
|---|---|---|
| committer | Xiyue Deng | 2013-09-01 02:55:44 -0700 |
| commit | e75bf07601c685958a871444bbbd919998debce7 (patch) | |
| tree | a802d214b3066b6def2d1a8305082685917fdb84 /Library/Formula | |
| parent | de5532166370563255accea15c0901cc25d0cfa1 (diff) | |
| download | homebrew-e75bf07601c685958a871444bbbd919998debce7.tar.bz2 | |
tinyxml: 2.6.2 with debian patches and CMakeLists.txt
This formula will build a patched version of tinyxml 2.6.2
using the patches from debian. I've summarized the debian
patches in comments in the formula. Here's a link to the
debian patch management page:
http://patch-tracker.debian.org/package/tinyxml/2.6.2-2
I've also added a patch with a CMakeLists.txt that builds
a shared library and provides an install target.
Closes #22100.
Signed-off-by: Xiyue Deng <manphiz@gmail.com>
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/tinyxml.rb | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/Library/Formula/tinyxml.rb b/Library/Formula/tinyxml.rb new file mode 100644 index 000000000..b2ba7dc85 --- /dev/null +++ b/Library/Formula/tinyxml.rb @@ -0,0 +1,31 @@ +require 'formula' + +class Tinyxml < Formula + homepage 'http://www.grinninglizard.com/tinyxml/' + url 'http://downloads.sourceforge.net/project/tinyxml/tinyxml/2.6.2/tinyxml_2_6_2.tar.gz' + sha1 'cba3f50dd657cb1434674a03b21394df9913d764' + + option :universal + + depends_on 'cmake' => :build + + def patches + # The first two patches are taken from the debian packaging of tinyxml. + # The first patch enforces use of stl strings, rather than a custom string type. + # The second patch is a fix for incorrect encoding of elements with special characters + # originally posted at http://sourceforge.net/p/tinyxml/patches/51/ + # The third patch adds a CMakeLists.txt file to build a shared library and provide an install target + # submitted upstream as https://sourceforge.net/p/tinyxml/patches/66/ + [ + 'http://patch-tracker.debian.org/patch/series/dl/tinyxml/2.6.2-2/enforce-use-stl.patch', + 'http://patch-tracker.debian.org/patch/series/dl/tinyxml/2.6.2-2/entity-encoding.patch', + 'https://gist.github.com/scpeters/6325123/raw/cfb079be67997cb19a1aee60449714a1dedefed5/tinyxml_CMakeLists.patch', + ] + end + + def install + ENV.universal_binary if build.universal? + system "cmake", *std_cmake_args + system "make", "install" + end +end |
