Skip to content

Instantly share code, notes, and snippets.

@Roman2K Roman2K/nls_m4.patch
Last active Oct 2, 2016

What would you like to do?
diff --git a/m4/nls.m4 b/m4/nls.m4
new file mode 100644
index 0000000..7967cc2
--- /dev/null
+++ b/m4/nls.m4
@@ -0,0 +1,31 @@
+# nls.m4 serial 3 (gettext-0.15)
+dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc.
+dnl This file is free software; the Free Software Foundation
+dnl gives unlimited permission to copy and/or distribute it,
+dnl with or without modifications, as long as this notice is preserved.
+dnl This file can can be used in projects which are not available under
+dnl the GNU General Public License or the GNU Library General Public
+dnl License but which still want to provide support for the GNU gettext
+dnl functionality.
+dnl Please note that the actual code of the GNU gettext library is covered
+dnl by the GNU Library General Public License, and the rest of the GNU
+dnl gettext package package is covered by the GNU General Public License.
+dnl They are *not* in the public domain.
+dnl Authors:
+dnl Ulrich Drepper <>, 1995-2000.
+dnl Bruno Haible <>, 2000-2003.
+ AC_MSG_CHECKING([whether NLS is requested])
+ dnl Default is enabled NLS
+ [ --disable-nls do not use Native Language Support],
+ USE_NLS=$enableval, USE_NLS=yes)
class Transmission < Formula
desc "Lightweight BitTorrent client"
homepage ""
url ""
sha256 "3a8d045c306ad9acb7bf81126939b9594553a388482efa0ec1bfb67b22acd35f"
bottle do
sha256 "0886b0d5825c557540222b50bd7ce30feb2bd48f6d14db5ec7b15ac2451088d6" => :sierra
sha256 "68af47554f408d92d04cbf86239a3d973cf7b4e9f0d254e127f5ead36074987a" => :el_capitan
sha256 "2071f4bb87d9d5e7cf6885caa8cf8605d81b108a097259113ba295a3c1f90bb7" => :yosemite
sha256 "9fb74d440426bbdf82d06dcd01e53db625cabfce0c4c85b15aec298007df6fd3" => :mavericks
head do
url ""
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
patch do
url ""
sha256 "46f539381ee4cb7313b3dc3cbf9aa2c45770c7213177a81dae15880278367dc0"
option "with-nls", "Build with native language support"
depends_on "pkg-config" => :build
depends_on "curl" if MacOS.version <= :leopard
depends_on "libevent"
if build.with? "nls"
depends_on "intltool" => :build
depends_on "gettext"
def install
system "sh", "" if build.head?
system "intltoolize" if build.with? "nls"
ENV.append "LDFLAGS", "-framework Foundation -prebind"
ENV.append "LDFLAGS", "-liconv"
args = %W[--disable-dependency-tracking
args << "--disable-nls" if build.without? "nls"
system "./configure", *args
system "make", "install"
def caveats; <<-EOS.undent
This formula only installs the command line utilities. can be downloaded directly from the website:
Alternatively, install with Homebrew-Cask:
brew cask install transmission
plist_options :manual => "transmission-daemon --foreground"
def plist; <<-EOS.undent
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "">
<plist version="1.0">
test do
system "#{bin}/transmission-create", "-o", "#{testpath}/test.mp3.torrent", test_fixtures("test.mp3")
assert_match /^magnet:/, shell_output("#{bin}/transmission-show -m #{testpath}/test.mp3.torrent")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.