diff options
| author | Misty De Meo | 2013-03-10 19:34:39 -0500 |
|---|---|---|
| committer | Misty De Meo | 2013-06-08 19:10:40 -0500 |
| commit | 4e0366d7bd5e80a6d399454f165c8ed05aedd1e2 (patch) | |
| tree | 28dbae320b30d1de8b47dbe9de84458e466cd436 | |
| parent | 2f3b109750bc93fa07124846a8c36c63aef7128b (diff) | |
| download | homebrew-4e0366d7bd5e80a6d399454f165c8ed05aedd1e2.tar.bz2 | |
libunwind-headers 35.1
| -rw-r--r-- | Library/Formula/libunwind-headers.rb | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/Library/Formula/libunwind-headers.rb b/Library/Formula/libunwind-headers.rb new file mode 100644 index 000000000..04c4f107d --- /dev/null +++ b/Library/Formula/libunwind-headers.rb @@ -0,0 +1,28 @@ +require 'formula' + +class LibunwindHeaders < Formula + homepage 'http://opensource.apple.com/' + url 'http://opensource.apple.com/tarballs/libunwind/libunwind-35.1.tar.gz' + sha1 '86908428aaa0ae6cec5038dc6eeb8b64dbb6cd63' + + keg_only :provided_by_osx, + "This package includes official development headers not installed by Apple." + + def install + inreplace "include/libunwind.h", "__MAC_10_6", "__MAC_NA" if MacOS.version < :snow_leopard + + if MacOS.version < :leopard + inreplace "include/libunwind.h", /__OSX_AVAILABLE_STARTING\(__MAC_NA,.*\)/, + "__attribute__((unavailable))" + + %w[include/libunwind.h include/unwind.h src/AddressSpace.hpp + src/InternalMacros.h].each do |header| + inreplace header, "Availability.h", "AvailabilityMacros.h" + end + end + + include.install Dir['include/*'] + (include/'libunwind').install Dir['src/*.h*'] + (include/'libunwind/libunwind_priv.h').unlink + end +end |
