http://www.ncl.ucar.edu/Download/windows_linux_subsystem.shtml
Install or updated to Windows 10
In order to use the Linux Bash Shell, you must upgrade to Windows 10, and you must have a 64-bit system. See the next section for more details.
首先升级至Win1064位系统,只有win10支持64位的NCL(当然linux和MacOS都支持), 然后安装win10自带的Linux Bash Shell
Enable and run the Linux Bash shell
Once you have Windows 10 installed, you need to enable the Linux Bash shell and then run it.
We found this useful article on howtogeek.com. Be sure to read through the section on how to run the bash.exe file, as you will need to do this before reading the next section.
howtogeek这个网址给了如何在win10下安装Linux Bash shell,但是中文的不好使,找不到feature这个选项,所以请参考下面微软官方网页。
https://docs.microsoft.com/en-us/windows/wsl/install-win10
百度经验
https://jingyan.baidu.com/article/aa6a2c14e347010d4c19c48f.html
Install additional packages
Before you can run NCL, you need to install some additional packages that NCL depends on. Using Linux makes this easy, because you can use the “apt-get” command to install the required packages.
From the Linux bash window that you opened earlier, type the following commands to install the required packages. You can put multiple packages on one line:
sudo apt-get install csh libfontconfig gfortran libgfortran3
sudo apt-get install libxrender-dev libx11-dev libxrender1
sudo apt-get install libssh2-1 libgomp1
sudo apt-get install firefox imagemagick
Note that the firefox and imagemagick packages are not required, but useful. Imagemagick gives you the powerful “convert” command for converting and post-processing graphical images.
The above installations can take awhile, so make sure to do this when you’re not in a hurry.
Install and run Xming
If you need to use the X11 window option in NCL Graphics, then you will need to install and run an X server. If you are not sure, then we recommend following these instructions anyway.
We found an article in PC World that recommends using the Xming package as an X server. Be sure to read the instructions about setting the DISPLAY environment variable before reading the next section.
Download NCL
Now you are ready to download NCL:
Open a browser window from the Linux shell (using the above instructions from PC World).
Go to the Climate Data Gateway web site.
Navigate your way to the NCL Version 6.4.0 OPeNDAP enabled or non OPeNDAP enabled page.
Download the binary for the 64-bit version of NCL compiled under Debian 7.11:
ncl_ncarg-6.4.0-Debian7.11_64bit_gnu472.tar.gz
or
ncl_ncarg-6.4.0-Debian7.11_64bit_nodap_gnu472.tar.gz
Install NCL
Once you have the *.tar.gz file, decide where you want to install NCL. If you are new to UNIX and don’t know where you want to put it, then we recommend installing NCL in the directory like “/usr/local/ncl-6.4.0”. We’ll use this path in the example below, and will assume that you saved the file to the directory “~/Downloads”.
From the Linux bash shell window that you started earlier, type the following commands:
mkdir /usr/local/ncl-6.4.0
tar -zxf ~/Downloads/ncl_ncarg-6.4.0-Debian7.11_64bit_gnu472.tar.gz -C /usr/local/ncl-6.4.0
You can remove the ncl_ncarg-6.4.0-Debian7.11_64bit_gnu472.tar.gz file once the above commands are done.
Set your environment to run NCL
Every user of NCL needs to set their environment before they can use NCL. You can do this by opening the file “~/.profile” or “~/.bashrc” with a UNIX editor (vim, nedit, emacs, etc) and adding the lines:
export NCARG_ROOT=/usr/local/ncl-6.4.0
export PATH=
NCARGROOT/bin:
N
C
A
R
G
R
O
O
T
/
b
i
n
:
PATH
Please note that you must use a UNIX editor to change this file. If you are unfamiliar with UNIX editors, we recommend that you use nedit, which you can install via “sudo apt-get install nedit”.
Set DISPLAY environment variable
In order to run any X applications, including running NCL to display graphics to your screen, you may need to set the DISPLAY enviroment variable, as described in the earlier Xming instructions. You can set this variable in the same ~/.profile or ~/.bashrce that you used for setting NCARG_ROOT.
export DISPLAY=:0
You should now be ready to tes