Wednesday, December 28, 2016

Install tmux on OS X without Homebrew (Scrap)

from: https://gist.github.com/shrayasr/8714601

# Create a directory
mkdir ~/tmux-install
cd ~/tmux-install

# Get the files
curl -OL http://downloads.sourceforge.net/tmux/tmux-1.5.tar.gz
curl -OL http://downloads.sourceforge.net/project/levent/libevent/libevent-2.0/libevent-2.0.16-stable.tar.gz

# Extract them 
tar xzf tmux-1.5.tar.gz
tar xzf libevent-2.0.16-stable.tar.gz

# Compile libevent
cd libevent-2.0.16-stable
./configure --prefix=/opt
make
sudo make install

# Compile tmux
cd ../tmux-1.5
LDFLAGS="-L/opt/lib" CPPFLAGS="-I/opt/include" LIBS="-lresolv" ./configure --prefix=/opt
make
sudo make install

# Link it
ln -s /opt/bin/tmux /usr/bin/tmux