2010-06-02 21:44:16 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Libimobiledevice < Formula
|
2010-06-02 21:44:16 +00:00
|
|
|
homepage 'http://www.libimobiledevice.org/'
|
2012-01-25 23:10:26 +00:00
|
|
|
url 'http://www.libimobiledevice.org/downloads/libimobiledevice-1.1.1.tar.bz2'
|
2011-05-12 12:53:43 +00:00
|
|
|
md5 'cdc13037e822d9ac2e109536701d153a'
|
2010-06-02 21:44:16 +00:00
|
|
|
|
2012-01-25 23:10:26 +00:00
|
|
|
head 'http://cgit.sukimashita.com/libimobiledevice.git', :using => :git
|
|
|
|
|
2010-09-19 17:21:57 +00:00
|
|
|
depends_on 'pkg-config' => :build
|
2010-06-02 21:44:16 +00:00
|
|
|
depends_on 'libtasn1'
|
2011-05-12 12:53:43 +00:00
|
|
|
depends_on 'glib'
|
2010-06-02 21:44:16 +00:00
|
|
|
depends_on 'libplist'
|
2011-05-12 12:53:43 +00:00
|
|
|
depends_on 'usbmuxd'
|
2010-06-02 21:44:16 +00:00
|
|
|
depends_on 'gnutls'
|
|
|
|
|
2012-02-27 03:44:55 +00:00
|
|
|
if MacOS.xcode_version >= "4.3" and ARGV.build_head?
|
2012-02-28 17:31:20 +00:00
|
|
|
depends_on 'libtool' => :build
|
|
|
|
depends_on 'autoconf' => :build
|
2012-02-27 03:44:55 +00:00
|
|
|
end
|
|
|
|
|
2010-06-02 21:44:16 +00:00
|
|
|
def install
|
2012-01-25 23:10:26 +00:00
|
|
|
if ARGV.build_head?
|
|
|
|
# fix the m4 problem with the missing pkg.m4
|
2012-02-27 03:44:55 +00:00
|
|
|
ENV['LIBTOOLIZE'] = "glibtoolize"
|
|
|
|
ENV['ACLOCAL'] = "aclocal -I m4 -I #{HOMEBREW_PREFIX}/share/aclocal"
|
2012-01-25 23:10:26 +00:00
|
|
|
ENV.prepend "CFLAGS", "-I#{HOMEBREW_PREFIX}/include"
|
|
|
|
|
|
|
|
system "autoreconf -ivf"
|
|
|
|
end
|
|
|
|
|
|
|
|
ENV.append_to_cflags "-std=gnu89" if ENV.compiler == :clang
|
|
|
|
|
2011-05-12 12:53:43 +00:00
|
|
|
system "./configure", "--disable-dependency-tracking",
|
|
|
|
"--prefix=#{prefix}",
|
|
|
|
"--without-swig"
|
2010-06-02 21:44:16 +00:00
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
end
|