It turns out, getting Nmap 6 to run on BackTrack 5 R2 is actually quite simple. Follow the steps below and prepare to bask in the newness of Nmap 6.
Linux Security Cookbook by Barrett, Daniel J./ Silverman, Richard E./ (Google Affiliate Ad)
First, you need to get rid of the included Nmap which is version 5.61. Simply run this command:
apt-get -y autoremove nmap
This command should only take a few seconds to complete. Next, grab the Nmap 6 source using this command:
The source tarball is about 22 MB so it should (hopefully) download pretty quickly. After you have the source, you need to extract it. You can do that with this command:
tar zxvf nmap-6.00.tgz
Finally, these commands will compile and install Nmap 6. If you are unfamiliar with Linux, these are standard commands for installing software from source code.
Depending on your hardware, these commands make need a few minutes to complete. To check that Nmap is installed, run:
Nmap version 6.00 ( http://nmap.org )
Compiled with: nmap-liblua-5.1.3 nmap-libpcre-7.6 libpcap-1.0.0 nmap-libdnet-1.12 ipv6
Compiled without: openssl
Now, Nmap 6 is installed. Check out the announcement here, http://nmap.org/6. You may also want to check out my previous post on Nmap NSE scripts, http://www.marshalgraham.com/2012/05/getting-started-with-nse-nmap-scripting.html.
One thing to note regarding this installation method. During the first step, the BackTrack maintained Nmap package is removed. This means that apt-get will no longer be able to update Nmap. When a new Nmap version is released, you will need to repeat this procedure to upgrade to the current version.
Edit: If you want to restore the BackTrack maintained Nmap, you can. Go back to the nmap-6.00 directory and run make uninstall. Next run apt-get -y install nmap to reinstall the packaged version of Nmap.