Brew Install Rtorrent not Working I am unable to brew build rtorrent. Could someone tell me what I need to do to get this to work?

Things I have done -

brew doctor
brew update
brew upgrade --all


Error -

ld: symbol(s) not found for architecture x86_64
collect2: error: ld returned 1 exit status
make[3]: *** [rtorrent] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
==&gt; Formula
Path: /usr/local/Library/Formula/rtorrent.rb
==&gt; Configuration
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 45bc689b2a1af15c798fa01481b38da062e47e3f
Last commit: 53 minutes ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: 8-core 64-bit haswell
OS X: 10.10.3-x86_64
Xcode: 6.3.2
CLT: 6.3.2.0.1.1431401888
Clang: 6.1 build 602
X11: 2.7.7 =&gt; /opt/X11
System Ruby: 2.0.0-p481
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby
Java: 1.8.0_40
==&gt; ENV
HOMEBREW_CC: gcc-5
HOMEBREW_CXX: g++-5
MAKEFLAGS: -j8
CMAKE_PREFIX_PATH: /usr/local/opt/openssl:/usr/local
CMAKE_INCLUDE_PATH: /usr/include/libxml2:/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers
CMAKE_LIBRARY_PATH: /System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries
PKG_CONFIG_PATH: /usr/local/opt/openssl/lib/pkgconfig:/usr/local/opt/libtorrent/lib/pkgconfig
PKG_CONFIG_LIBDIR: /usr/lib/pkgconfig:/usr/local/Library/ENV/pkgconfig/10.10
ACLOCAL_PATH: /usr/local/share/aclocal
PATH: /usr/local/Library/ENV/4.3:/usr/local/opt/pkg-config/bin:/usr/local/opt/openssl/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/opt/gcc/bin

Logs:
     /Users/aaron/Library/Logs/Homebrew/rtorrent/01.configure
     /Users/aaron/Library/Logs/Homebrew/rtorrent/01.configure.cc
     /Users/aaron/Library/Logs/Homebrew/rtorrent/02.make
     /Users/aaron/Library/Logs/Homebrew/rtorrent/02.make.cc
     /Users/aaron/Library/Logs/Homebrew/rtorrent/config.log
I am facing the same issue. I believe it is caused by the newly added gcc v5.1.0 package.

Rolling back to gcc v4.9.2 solved the installation issue with rtorrent v0.9.4 package. You can rollback to gcc v4.9.2 two different methods based on the current state of your homebrew installation. 

Method A

If you have not performed brew cleanup after brew upgrade --all then you can simply switch to older version of gcc by running brew switch gcc 4.9.2. For further information read this answer.

Method B

Unfortunately if you have a habit of running brew cleanup after brew upgrade --all (like me ;-(), follow the steps mentioned below to install gcc v4.9.2 package.

brew uninstall gcc
brew tap homebrew/versions
brew install gcc49


Final Step

Install rtorrent by running the below mentioned command in your teminal.

brew install rtorrent