85 lines
2.5 KiB
Ruby
85 lines
2.5 KiB
Ruby
class Pidgin < Formula
|
|
desc "Multi-protocol chat client"
|
|
homepage "https://pidgin.im/"
|
|
url "https://downloads.sourceforge.net/project/pidgin/Pidgin/2.10.12/pidgin-2.10.12.tar.bz2"
|
|
sha256 "2c7523f0fefe89749c03b2b738ab9f7bd186da435be4762f1487eee31e77ffdd"
|
|
|
|
bottle do
|
|
sha256 "f7ac5aa4dc2c9e2ea50e6c5b4e9ca654fa8080427410a7b85d217a1ebd039546" => :el_capitan
|
|
sha256 "0dd17a65d1e4935dce7676be0d38736cc1a00509f9d9abfffbc4b1b6252f0b8e" => :yosemite
|
|
sha256 "3a0d9de34f0b38996da8c17875251172a5bf49891c671cb768e5125b65af0eef" => :mavericks
|
|
end
|
|
|
|
option "with-perl", "Build Pidgin with Perl support"
|
|
option "without-gui", "Build only Finch, the command-line client"
|
|
|
|
deprecated_option "perl" => "with-perl"
|
|
deprecated_option "without-GUI" => "without-gui"
|
|
|
|
depends_on "pkg-config" => :build
|
|
depends_on "intltool" => :build
|
|
depends_on "gettext"
|
|
depends_on "gsasl" => :optional
|
|
depends_on "gnutls"
|
|
depends_on "libgcrypt"
|
|
depends_on "libidn"
|
|
depends_on "glib"
|
|
|
|
if build.with? "gui"
|
|
depends_on "gtk+"
|
|
depends_on "cairo"
|
|
depends_on "pango"
|
|
depends_on "libotr"
|
|
end
|
|
|
|
# Finch has an equal port called purple-otr but it is a NIGHTMARE to compile
|
|
# If you want to fix this and create a PR on Homebrew please do so.
|
|
resource "pidgin-otr" do
|
|
url "https://otr.cypherpunks.ca/pidgin-otr-4.0.1.tar.gz"
|
|
sha256 "1b781f48c27bcc9de3136c0674810df23f7d6b44c727dbf4dfb24067909bf30a"
|
|
end
|
|
|
|
def install
|
|
args = %W[
|
|
--disable-debug
|
|
--disable-dependency-tracking
|
|
--prefix=#{prefix}
|
|
--disable-avahi
|
|
--disable-doxygen
|
|
--enable-gnutls=yes
|
|
--disable-dbus
|
|
--disable-gevolution
|
|
--disable-gstreamer
|
|
--disable-gstreamer-interfaces
|
|
--disable-gtkspell
|
|
--disable-meanwhile
|
|
--disable-vv
|
|
--without-x
|
|
]
|
|
|
|
args << "--disable-perl" if build.without? "perl"
|
|
args << "--enable-cyrus-sasl" if build.with? "gsasl"
|
|
|
|
args << "--with-tclconfig=#{MacOS.sdk_path}/usr/lib"
|
|
args << "--with-tkconfig=#{MacOS.sdk_path}/usr/lib"
|
|
if build.without? "gui"
|
|
args << "--disable-gtkui"
|
|
end
|
|
|
|
system "./configure", *args
|
|
system "make", "install"
|
|
|
|
if build.with? "gui"
|
|
resource("pidgin-otr").stage do
|
|
ENV.prepend "CFLAGS", "-I#{Formula["libotr"].opt_include}"
|
|
ENV.append_path "PKG_CONFIG_PATH", "#{lib}/pkgconfig"
|
|
system "./configure", "--prefix=#{prefix}", "--mandir=#{man}"
|
|
system "make", "install"
|
|
end
|
|
end
|
|
end
|
|
|
|
test do
|
|
system "#{bin}/finch", "--version"
|
|
end
|
|
end
|