2014-12-07 04:41:09 +00:00
|
|
|
require "formula"
|
2010-09-20 20:02:55 +00:00
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Afflib < Formula
|
2014-12-07 04:41:09 +00:00
|
|
|
homepage "https://github.com/sshock/AFFLIBv3"
|
|
|
|
url "https://github.com/sshock/AFFLIBv3/archive/v3.7.6.tar.gz"
|
|
|
|
sha1 "2793532fb048b145a60f5a2e951e3922bb4e9c96"
|
2010-09-20 20:02:55 +00:00
|
|
|
|
2014-07-03 12:32:20 +00:00
|
|
|
bottle do
|
2014-12-07 04:53:40 +00:00
|
|
|
cellar :any
|
|
|
|
sha1 "d6147493de42ab17c383c63502ced1c04e3789c2" => :mavericks
|
|
|
|
sha1 "93a0873ab6ce491714623a1a140128252b76b775" => :mountain_lion
|
2014-07-03 12:32:20 +00:00
|
|
|
end
|
|
|
|
|
2014-06-01 01:15:09 +00:00
|
|
|
depends_on "autoconf" => :build
|
|
|
|
depends_on "automake" => :build
|
|
|
|
depends_on "libtool" => :build
|
|
|
|
depends_on "expat" => :optional
|
2014-09-10 05:35:52 +00:00
|
|
|
depends_on :osxfuse => :optional
|
2014-12-07 04:41:09 +00:00
|
|
|
depends_on "openssl"
|
2014-01-08 15:21:27 +00:00
|
|
|
|
2014-03-18 03:44:46 +00:00
|
|
|
# This patch fixes a bug reported upstream over there
|
|
|
|
# https://github.com/simsong/AFFLIBv3/issues/4
|
|
|
|
patch :DATA
|
2010-09-20 20:02:55 +00:00
|
|
|
|
|
|
|
def install
|
2014-06-01 01:15:09 +00:00
|
|
|
system "./bootstrap.sh"
|
2014-01-08 15:21:27 +00:00
|
|
|
|
|
|
|
args = ["--disable-dependency-tracking", "--prefix=#{prefix}"]
|
|
|
|
|
2014-03-01 21:52:25 +00:00
|
|
|
if build.with? "osxfuse"
|
2014-12-07 04:41:09 +00:00
|
|
|
ENV["CPPFLAGS"] = "-I#{Formula["osxfuse"].include}/osxfuse"
|
2014-01-08 15:21:27 +00:00
|
|
|
args << "--enable-fuse"
|
|
|
|
end
|
|
|
|
|
|
|
|
system "./configure", *args
|
2010-09-20 20:02:55 +00:00
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
end
|
2014-01-08 15:21:27 +00:00
|
|
|
|
|
|
|
__END__
|
|
|
|
diff --git a/bootstrap.sh b/bootstrap.sh
|
|
|
|
index 3a7af59..7510933 100755
|
|
|
|
--- a/bootstrap.sh
|
|
|
|
+++ b/bootstrap.sh
|
|
|
|
@@ -6,7 +6,7 @@
|
|
|
|
echo Bootstrap script to create configure script using autoconf
|
|
|
|
echo
|
|
|
|
# use the installed ones first, not matter what the path says.
|
|
|
|
-export PATH=/usr/bin:/usr/sbin:/bin:$PATH
|
|
|
|
+#export PATH=/usr/bin:/usr/sbin:/bin:$PATH
|
|
|
|
touch NEWS README AUTHORS ChangeLog stamp-h
|
|
|
|
aclocal
|
|
|
|
LIBTOOLIZE=glibtoolize
|
|
|
|
diff --git a/configure.ac b/configure.ac
|
2014-12-07 04:41:09 +00:00
|
|
|
index 940353b..c530f2e 100644
|
2014-01-08 15:21:27 +00:00
|
|
|
--- a/configure.ac
|
|
|
|
+++ b/configure.ac
|
2014-12-07 04:41:09 +00:00
|
|
|
@@ -241,10 +241,6 @@ AC_ARG_ENABLE(fuse,
|
2014-01-08 15:21:27 +00:00
|
|
|
if test "x${enable_fuse}" = "xyes" ; then
|
|
|
|
AC_MSG_NOTICE([FUSE requested])
|
|
|
|
CPPFLAGS="-D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=26 $CPPFLAGS"
|
|
|
|
- if test `uname -s` = Darwin ; then
|
|
|
|
- AC_MSG_NOTICE([FUSE IS NOT SUPPORTED ON MACOS])
|
|
|
|
- enable_fuse=no
|
|
|
|
- fi
|
|
|
|
AC_CHECK_HEADER([fuse.h],,
|
|
|
|
AC_MSG_NOTICE([fuse.h not found; Disabling FUSE support.])
|
|
|
|
enable_fuse=no)
|
2014-12-07 04:41:09 +00:00
|
|
|
@@ -255,7 +251,7 @@ AFFUSE_BIN=
|
2014-01-08 15:21:27 +00:00
|
|
|
if test "${enable_fuse}" = "yes"; then
|
|
|
|
AC_DEFINE([USE_FUSE],1,[Use FUSE to mount AFF images])
|
|
|
|
AFFUSE_BIN='affuse$(EXEEXT)'
|
|
|
|
- FUSE_LIBS=-lfuse
|
|
|
|
+ FUSE_LIBS=-losxfuse
|
|
|
|
fi
|
|
|
|
AC_SUBST(AFFUSE_BIN)
|
|
|
|
AM_PROG_CC_C_O dnl for affuse
|