
Installing NCL from a precompiled binary
This document explains how to download and install NCL using binaries hosted on the Climate Data Gateway website. This website provides NCL binaries for MacOS, Linux, and Windows running Cygwin.
There are three main steps:
If you've read over this document and still have problems, then please send email to ncl-install@ucar.edu (you need to subscribe first). Read our posting guidelines first.
For Linux and MacOS systems, you have the choice of installing from OPeNDAP-enabled precompiled binaries or not. We recommend the non-OPenDAP binaries, if you don't need this functionality.
Please read these special notes if you have a system running Linux, Windows, or MacOSX.
Download the appropriate NCL binary from the CDG
All of the available NCL binaries are on the Climate Data Gateway website. Here's the the direct link to NCL the NCL V6.6.2 binaries
Systems Supported
- Linux (i686, x86_64), gcc/gfortran v4.4.x or later (see Linux notes)
- MacOSX (Intel, 32 and 64 bit) (see MacOSX notes)
- Windows 10 under Linux Bash shell (see Windows 10 Linux Bash shell notes)
- Windows under 32-bit Cygwin Unix emulator (see Cygwin notes)
Detailed instructions:
- Go to www.earthsystemgrid.org
- Click on "NCL: NCAR Command Language" (near the bottom of the page).
- Click on "NCL Version 6.6.2" (or the version you're interested in).
- Click on whether you want an OPeNDAP binary, a non-OPeNDAP binary, or source code. If you don't know what OPeNDAP is, then you probably don't need it.
- Click on "Download Options".
- Click on the name of the file you want to download, and it should automatically download to your machine.
Extract files from gzipped tar file
The precompiled binary that you download will either be a compressed tar file (xxxxtar.gz) or a tar file (xxxx.tar) if your system automatically uncompressed it when you downloaded it.
mkdir /usr/local/ncl-6.6.2 tar -zxf ~/Downloads/ncl_ncarg-6.6.2-MacOS_10.13_64bit_gnu730.tar.gz -C /usr/local/ncl-6.6.2
Note: if the compressed tar file is not in a directory called "~/Downloads", then you will need to adjust this path accordingly.
Once this step is finished, you can remove the "~/Downloads/ncl_ncarg-6.6.2-MacOS-10.13_64bit_gcc730.tar.gz" file:
rm ~/Downloads/ncl_ncarg-6.6.2-MacOS_10.13_64bit_gnu730.tar.gz
To install NCL/NCARG, you need to do the following steps:
- Extract the file where you want the software to be installed.
- Set the NCARG_ROOT and PATH environment variables to point to where the software was installed.
- Set the DISPLAY environment variable to indicate where to display graphics (this step likely not needed)
- Put a ".hluresfile" file in your home directory.
- Test your NCL/NCARG installation.
Other notes:
- Special instructions if you have an
OPeNDAP-enabled version of NCL.
- Problem with libgfortran.so.x? Missing a "libgomp" library?
Not sure which binary to download?
See special notes for Linux, MacOSX or Windows/Cygwin systems. - Description of available binaries
Extract the file where you want the software to be installed
Test your NCL/NCARG installation
For the commands below to work, you must have csh installed on
your system. In most cases, csh is on your system by default. If it
is not, and you are on a Linux system, you can try installing it with:
sudo apt-get install cshor
yum install tcsh(tcsh is an enhanced and compatible version of csh.) If you are on Cygwin, see the instructions on the Cygwin page for installing csh. |
You can quickly test if NCL is installed properly by typing:
ng4ex xy01n -cleanThe ng4ex command will copy an NCL script called xy01n.ncl into your current working directory, and run ncl on it. An X11 window should pop up with an XY plot. Click on this plot with your left mouse button to advance (and thus close) the frame.
You can similarly test NCAR Graphics. If you only plan to use NCL, it is not important that this command is successful.
ncargex cpex08 -clean
Special instructions if you have an OPeNDAP-enabled version of NCL
NetCDF Version 4.1.x now comes with OPeNDAP support built into it, which makes building an OPeNDAP-enabled version of NCL much easier. As a result, the precompiled NCL binaries all have OPeNDAP support built in.
We also provide non-OPeNDAP enabled binaries for some LINUX and MacOS systems in case you have problems with the OPeNDAP versions.
If you run "ncl" and get error messages about missing libxxx.so files, please see these Linux, MacOSX, or Cygwin notes. You can also try downloading a non-OPenDAP enabled binary.