<div dir="ltr"><div class="gmail_default" style="font-size:small">Dave,</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Jeremy is right about the Ubuntu installation: it puts things in /usr/bin, /usr/lib and /usr/share. The /usr/share directory is where the 'ncarg' directory gets installed.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">So, in order for NCL to work, you have to set two environment variables:</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">NCARG_ROOT=/usr</div><div class="gmail_default" style="font-size:small">NCARG_NCARG=/usr/share/ncarg</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">This is necessary because by default, NCL looks in $NCARG_ROOT/lib/ncarg to find things like font tables and map databases. When you set NCARG_NCARG, NCL will look in that first.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">However, as you saw, the load commands will still not work, because they are effectively looking in /usr/lib/ncarg/..., which doesn't exist with the Ubuntu install.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">To fix, you need to change the load commands to replace "lib" with "share"</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_extra" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">load "$NCARG_ROOT/<div class="gmail_default" style="font-size:small;display:inline">share</div>/ncarg/<wbr>nclscripts/csm/gsn_code.ncl" </div><div class="gmail_extra" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">load "$NCARG_ROOT/<div class="gmail_default" style="font-size:small;display:inline">share</div>/ncarg/<wbr>nclscripts/csm/gsn_csm.ncl" </div><div class="gmail_extra" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">load "$NCARG_ROOT/<div class="gmail_default" style="font-size:small;display:inline">share</div>/ncarg/<wbr>nclscripts/csm/contributed.<wbr>ncl" </div><div class="gmail_default" style="font-size:small"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div class="gmail_default" style="font-size:small"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">or this would also work:</span></div><div class="gmail_default" style="font-size:small"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div class="gmail_default"><span style="text-align:start;text-indent:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px">load "$NCARG_NCARG/nclscripts/csm/gsn_code.ncl" </div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px">load "$NCARG_NCARG/nclscripts/csm/gsn_csm.ncl" </div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px">load "$NCARG_NCARG/nclscripts/csm/contributed.ncl" </div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px"><br></div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px">HOWEVER, I don't really like either of these solutions. If you need to share scripts with users on other systems, they may not have the same set up as you and then they will need to go in and fix the modified load commands to be what they originally were.</div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px"><br></div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px">I suggest upgrading to NCL V6.4.0 as Kevin suggested, and then you can put NCL wherever you want, preferably under a single root directory like "/usr/local/lib/ncl-6.4.0". Then, you only need to set NCARG_ROOT and the scripts should work without modifications. (Also, in V6.4.0, those three scripts and some others are loaded by default, so technically, you won't need to load them at all.)</div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px"><br></div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px">For the next release (NCL V6.5.0), we've added even more scripts to the "automatically loaded by NCL" list. For more information, see:</div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px"><br></div><div class="gmail_default"><a href="http://www.ncl.ucar.edu/future_release.shtml#PreloadedScripts6.5.0">http://www.ncl.ucar.edu/future_release.shtml#PreloadedScripts6.5.0</a><br></div><div class="gmail_default"><br></div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px"><br></div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px">--Mary</div><div class="gmail_default" style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-transform:none;white-space:normal;word-spacing:0px"><br></div></span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Feb 16, 2018 at 5:07 PM, JeremyWinick via ncl-install <span dir="ltr"><<a href="mailto:ncl-install@ucar.edu" target="_blank">ncl-install@ucar.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div text="#000000" bgcolor="#FFFFFF">
<p>I think the Ubuntu install from the repository puts the binary in
/usr/bin and most other stuff in /usr/share/ncarg. So if you set
NCAR's suggested paths it won't work or find things.</p>
<p>Jeremy<br>
</p><div><div class="h5">
<br>
<div class="m_-2019512935851521746moz-cite-prefix">On 02/16/2018 03:36 PM, Dave Burns via
ncl-install wrote:<br>
</div>
</div></div><blockquote type="cite"><div><div class="h5">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_extra">Hello.</div>
<div class="gmail_extra">Executing ncl on a newly installed
ubuntu box and an old ncl file that used to work generates
this error:</div>
<div class="gmail_extra">>fatal:Could not open
($NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_code.ncl)</div>
<div class="gmail_extra">>fatal:error at line 2 in file
proj1.ncl</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra">That's odd, because NCARG_ROOT is
defined and that file is openable and has permissive
permissions for all users:</div>
<div class="gmail_extra">>user@host:~/Downloads/1200/<wbr>0214$
echo $NCARG_ROOT</div>
<div class="gmail_extra">/usr</div>
<div class="gmail_extra"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">>user@host</span>:~/Downloads/1200/<wbr>0214$
ls -la $NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_code.ncl</div>
<div class="gmail_extra">-rwxr-xr-x 1 root root 490093 Jan 28
2016 /usr/lib/ncarg/nclscripts/csm/<wbr>gsn_code.ncl</div>
<div class="gmail_extra">><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">user@host</span>:~/Downloads/1200/<wbr>0214$
head $NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_code.ncl</div>
<div class="gmail_extra">;</div>
<div class="gmail_extra">; $Id: gsn_code.ncl,v 1.238.4.3
2010-05-06 17:13:26 haley Exp $</div>
<div class="gmail_extra">;;;;;</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra">So I am confused. The only way "could
not open" would make sense was if ncl was opening the file
for write access, which still doesn't make sense.</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra">Here are the first lines from the ncl
file:</div>
<div class="gmail_extra">
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra">load
"$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_code.ncl" ;
These four libraries are automatically</div>
<div class="gmail_extra">load
"$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_csm.ncl" ;
loaded from NCL V6.4.0 onward.</div>
<div class="gmail_extra">load
"$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/contributed.<wbr>ncl" ;
No need for user to explicitly load.</div>
<div><br>
</div>
<div><br>
</div>
<div>How do I fix this?</div>
<div>thanks,</div>
<div>Dave</div>
</div>
</div>
</div>
<br>
<fieldset class="m_-2019512935851521746mimeAttachmentHeader"></fieldset>
<br>
</div></div><span class=""><pre>______________________________<wbr>_________________
ncl-install mailing list
List instructions, subscriber options, unsubscribe:
<a class="m_-2019512935851521746moz-txt-link-freetext" href="http://mailman.ucar.edu/mailman/listinfo/ncl-install" target="_blank">http://mailman.ucar.edu/<wbr>mailman/listinfo/ncl-install</a>
</pre>
</span></blockquote>
<br>
</div>
<br>______________________________<wbr>_________________<br>
ncl-install mailing list<br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-install" rel="noreferrer" target="_blank">http://mailman.ucar.edu/<wbr>mailman/listinfo/ncl-install</a><br>
<br></blockquote></div><br></div>