OSX Mavericks : How to install Command line tools without xCode
xCode & Mavericks
Hope you have upgraded your OSX to Mavericks, if not then do it right now because it’s simple awesome and most important it’s free.
I assume that you have already upgraded to Mavericks and you are enjoying great features of OSX Mavericks. In the older versions of the OSX, it was very easy to install command line tools with xCode. You just need to goto xCode->Preference->Downloads->Component and click on ‘install’ on ‘Command Line Tools‘
The Command Line Tool package gives terminal users many commonly used tools, utilities, and compilers, including make, GCC, clang, perl, svn, git, size, strip, strings, libtool, cpp, what, and many other useful commands that are usually found in default linux installations.
However, this is not a case in the OSX Mavericks, You will see nothing there if you have upgraded from Mountain Lion. You will see something like this.
There wasn’t any option to update/install ‘command line tool’. So I tried to install all these tools by using command, but NO LUCK !
$ brew install autoconf automake libtool pkg-config apple-gcc42 libyaml readline libxml2 libxslt libksba openssl sqlite
I discovered this issue while installing ‘bundler’ with rubygems, then after some time, I found there is a simple solution to this complicated problem.
You just need to bring up i-Term or Terminal and type
You will then have an option to ‘Get xCode‘ or install tools without xCode. You should click on ‘Install‘
You need to ‘Agree’ with T&C’s and carry on with installtion:
At this point, you may need to connect macbook to power source and wait till installation finishes. It won’t take more than 2-3 minute. Once it is finished then you can test that all your tools are installed from command line.
Play with your unix command like tools like gcc, git, svn, rebase, make, ld, otool, nm etc etc.
Where we installed ?
Command line tools are installed at following PATH. [Remember /Library is root not the user /Library. ]
Let’s navigate to that directory and see all the tools installed
$cd /Library/Developer/CommandLineTools/usr/bin $ ls
Now you will see, all the tools installed at that location. My i-Term looks like this.
You have now got all the command line tools without xCode. if you get message “Can’t install the software because it is not currently available from the Software Update server” then you probably have xCode installed.
Have fun with command line tools on OSX Mavericks. !!