<div dir="ltr"><div class="gmail_default">Kyle and all,</div><div class="gmail_default"><br></div><div class="gmail_default">I was able to successfully build NCL under MacOS 10.11 (El Capitan), using version 5.3 of gcc/gfortran. </div><div class="gmail_default"><br></div><div class="gmail_default"><div class="gmail_default"><div class="gmail_default"><div class="gmail_default">To try the new NCL,<span style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,0)"> first retrieve the compressed tar file I just created:</span><br></div></div></div><div class="gmail_default"><div><p class=""><span class=""><font face="monospace, monospace">   wget ftp.ucar.edu:/pub/scd/haley/ncl_ncarg-6.3.0.MacOS_10.11_64bit_gcc530.tar.gz</font></span></p></div><div><font color="#000000"><div style="font-family:arial,helvetica,sans-serif">Once you have the file, you need to uncompress and untar it wherever you want the software to reside. For example, if the *.gz file resides in <i style="font-family:monospace,monospace">/path/to/gzfile/, </i><span style="font-family:monospace,monospace">and</span> you want the software in /usr/local/ncl-6.3.0-test:</div></font><font color="#000000"><div style="font-family:arial,helvetica,sans-serif"><br></div><div><font face="monospace, monospace">   mkdir /usr/local/ncl-6.3.0-test</font></div><div><span style="font-family:monospace,monospace">   cd /usr/local/ncl-6.3.0-test</span><br style="font-family:monospace,monospace"><font face="monospace, monospace">   gunzip <i>/path/to/</i></font><i style="font-family:monospace,monospace">gzfile</i><font face="monospace, monospace"><i>/</i><span style="color:rgb(34,34,34)">ncl_ncarg-6.3.0.MacOS_10.11_64bit_gcc530</span>.tar.gz</font></div><div><font face="monospace, monospace">   tar -xvf </font><i style="font-family:monospace,monospace">/path/to/</i><i style="font-family:monospace,monospace">gzfile</i><i style="font-family:monospace,monospace">/</i><span style="font-family:monospace,monospace;color:rgb(34,34,34)">ncl_ncarg-6.3.0.MacOS_10.11_64bit_gcc530</span><span style="font-family:monospace,monospace">.tar</span></div></font><font color="#000000"><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">You can then remove the file <i style="font-family:monospace,monospace">/path/to/</i><i style="font-family:monospace,monospace">gzfile</i><i style="font-family:monospace,monospace">/</i><span style="color:rgb(34,34,34);font-family:arial,sans-serif">ncl_ncarg-6.3.0.MacOS_10.11_64bit_gcc530</span>.tar or save it somewhere.</div></font><font color="#000000"><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">You also need to setenv NCARG_ROOT to the parent directory (<span style="font-family:monospace,monospace">/usr/local/ncl-6.3.0-test</span> in this case), and make sure $NCARG_ROOT/bin (/usr/local/bin in this case) is on your search path.</div><div style="font-family:arial,helvetica,sans-serif"><br></div><div><font face="monospace, monospace">setenv NCARG_ROOT /usr/local/ncl-6.3.0-test</font></div><div><font face="monospace, monospace">setenv PATH $NCARG_ROOT/bin:$PATH</font></div><div style="font-family:arial,helvetica,sans-serif"><span style="font-family:monospace,monospace"><br></span></div><div style="font-family:arial,helvetica,sans-serif"><span style="font-family:monospace,monospace">or</span></div><div style="font-family:arial,helvetica,sans-serif"><span style="font-family:monospace,monospace"><br></span></div><div style="font-family:arial,helvetica,sans-serif"><div style="font-family:arial,sans-serif"><font face="monospace, monospace">export NCARG_ROOT=/usr/local/ncl-6.3.0-test</font></div><div style="font-family:arial,sans-serif"><font face="monospace, monospace">export PATH=$NCARG_ROOT/bin:$PATH</font></div></div></font><font color="#000000"><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">Try a couple of quick tests to make sure the binary is working properly:</div><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">which ncl</div><div style="font-family:arial,helvetica,sans-serif">ncl -V</div><div style="font-family:arial,helvetica,sans-serif">ng4ex gsun02n -clean</div><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">The last test should cause an X11 window with a graphic to pop up.  You&#39;ll need to click on this window with your left mouse button to cycle through the rest of the plots.</div><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">If the tests don&#39;t work, then please keep reading, as y<span style="font-family:arial,sans-serif;color:rgb(34,34,34)">ou may also need to install &quot;xcode&quot; for MacOS, and version 5.3 of gcc/gfortran.  These versions provide you with the quadmath and gomp libraries, as well as a few others.</span></div></font></div></div></div><div class="gmail_default"><br></div><div class="gmail_default"><b>XCODE</b></div><div class="gmail_default"><b><br></b></div><div class="gmail_default">To get xcode, go to:</div><div class="gmail_default"><br></div><div class="gmail_default"><a href="https://developer.apple.com/xcode/">https://developer.apple.com/xcode/<br></a></div><div class="gmail_default"><br></div><div class="gmail_default">and click on &quot;download&quot;. You will need an Apple ID to get it. The software is free.</div><div class="gmail_default"><br></div><div class="gmail_default">You may also need to install the MacOS command line tools:</div><div class="gmail_default"><br></div><div class="gmail_default"><font face="monospace, monospace"><span style="color:rgb(0,0,0)">xcode-select --install</span><br></font></div><div class="gmail_default"><br></div><div class="gmail_default"><b>GCC/GFORTRAN V5.3</b><br></div><div class="gmail_default"><br></div><div class="gmail_default">To install V5.3 of gcc/gfortran, go to:<br></div><div class="gmail_default"><br></div><div class="gmail_default"><div class="gmail_default"><a href="http://hpc.sourceforge.net/">http://hpc.sourceforge.net/</a><br></div><div class="gmail_default"><br></div><div class="gmail_default">and download the gcc-5.3-bin.tar.gz file mentioned in this line:</div><div class="gmail_default"><br></div><div class="gmail_default"><font face="monospace, monospace"><span style="color:rgb(0,0,0)"><a href="http://prdownloads.sourceforge.net/hpc/gcc-5.3-bin.tar.gz?download" style="color:rgb(0,0,102);text-decoration:none;font-weight:bolder">gcc-5.3-bin.tar.gz</a>, <a href="http://prdownloads.sourceforge.net/hpc/gfortran-5.3-bin.tar.gz?download" style="color:rgb(0,0,102);text-decoration:none;font-weight:bolder">gfortran-5.3-bin.tar.gz</a> (gfortran only), updated Dec 2015 (El Capitan).</span><br></font></div><div class="gmail_default"><span style="color:rgb(0,0,0)"><font face="arial, helvetica, sans-serif"><br></font></span></div><div class="gmail_default"><span style="color:rgb(0,0,0)"><font face="arial, helvetica, sans-serif">Extract the files by typing:</font></span></div><div class="gmail_default"><span style="color:rgb(0,0,0)"><font face="monospace, monospace"><br></font></span></div><div class="gmail_default"><span style="color:rgb(0,0,0)"><font face="monospace, monospace">  cd /</font></span></div><div class="gmail_default"><span style="color:rgb(0,0,0)"><font face="monospace, monospace">  sudo tar -zxf ~/Downloads/gcc-5.3-bin.tar.gz</font></span></div><div class="gmail_default"><div class="gmail_default"><br></div><div class="gmail_default"><span style="color:rgb(0,0,0)"><font face="arial, helvetica, sans-serif">It is *very* important that you do the &quot;cd /&quot; part first, because the files are tarred up relative to the root (&quot;/&quot;) directory.</font></span></div><div class="gmail_default"><span style="color:rgb(0,0,0)"><font face="arial, helvetica, sans-serif"><br></font></span></div><div class="gmail_default"><font face="arial, helvetica, sans-serif"><span style="color:rgb(0,0,0)">Once this is done, you can remove the </span><span style="color:rgb(0,0,0)">gcc-5.3-bin.tar.gz file</span><span style="color:rgb(0,0,0)">.</span></font></div><div class="gmail_default"><br></div></div></div><div class="gmail_default" style=""><div><font color="#000000"><div style="font-family:arial,helvetica,sans-serif">I will be out-of-touch the rest of the week. If there are issues with this NCL, please email them to ncl-install. I might be able to get to them later today.  Otherwise it may have to wait until next week.</div><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">Happy Holidays All,</div><div style="font-family:arial,helvetica,sans-serif"><br></div><div style="font-family:arial,helvetica,sans-serif">--Mary</div></font></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Dec 17, 2015 at 7:40 AM, Kyle Griffin <span dir="ltr">&lt;<a href="mailto:ksgriffin2@wisc.edu" target="_blank">ksgriffin2@wisc.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Mary,<div><br></div><div>No, I haven&#39;t built from source yet. I&#39;m going to try first with the standard packages I can get/have from MacPorts - it seems like everything is there, if you include the g2clib within GDAL. It also seems that GDAL made a major update back in September and not sure if any of your fixes/alterations to g2clib would&#39;ve snuck in there or been fixed otherwise.</div><div><br></div><div>(text above written yesterday)</div><div><br></div><div>Build finished after I left work yesterday, successfully. Interestingly, the source tarball I downloaded seems to be quite old! It contains NCL 6.1.0-beta, a version that was outdated before I even purchased the computer. The executables are all dated 24 May 2012, which appears to be consistent with when such a build may have been released.</div><div><br></div><div>Regardless, I ran the example - gsun01n.ncl, and it immediately segfaults. I think this has to do with me not being able to easily get some of the X11 development libraries for Mac, which is more on me than anything. Changing the wks_type to png immediately allowed the script to run successfully. Other libraries I didn&#39;t/couldn&#39;t get via port include HDF-EOS5 and the patched g2clib. All other external software was included and built based only on the MacPorts versions available.</div><div><br></div><div>Still not sure how the source code contains 6.1.0-beta when downloaded from <a href="https://www.earthsystemgrid.org/dataset/ncl.630.2.html" target="_blank">https://www.earthsystemgrid.org/dataset/ncl.630.2.html</a> (I can confirm the file size matches the one listed for 6.3.0 source). But regardless, build from scratch seems to work well on 10.11 when the appropriate paths are provided in the Q&amp;A section of the config.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div><br></div><div>Kyle</div></font></span></div><div class="gmail_extra"><span class=""><br clear="all"><div><div><div dir="ltr"><div><div dir="ltr">----------------------------------------<div>Kyle S. Griffin</div><div>Department of Atmospheric and Oceanic Sciences</div><div>University of Wisconsin - Madison</div><div>Room 1407</div><div>1225 W Dayton St, Madison, WI 53706</div><div>Email: <a href="mailto:ksgriffin2@wisc.edu" target="_blank">ksgriffin2@wisc.edu</a></div></div></div></div></div></div>
<br></span><div><div class="h5"><div class="gmail_quote">On Wed, Dec 16, 2015 at 12:38 PM, Mary Haley <span dir="ltr">&lt;<a href="mailto:haley@ucar.edu" target="_blank">haley@ucar.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hi Kyle,</div><div><br></div><div>We try to remove as many of these shared library dependencies as possible, and we&#39;ve been able to get by with this situation with previous versions of MacOS.</div><div><br></div><div>It doesn&#39;t surprise me that Apple has changed things up a bit, and unfortunately, I don&#39;t have a 10.11 system to test on yet.  I have to be careful about upgrading right away because this usually breaks my ability to run VPN from home, which is critical for work.</div><div><br></div><div>I&#39;m going to see if it&#39;s safe for me to upgrade to 10.11, and then I&#39;ll give the NCL build a try. </div><div><br></div><div>I do appreciate you offering to be a guinea pig.  Have you actually tried building NCL from source code?</div><span><font color="#888888"><div><br></div><div>--Mary</div><div><br></div></font></span></div><div class="gmail_extra"><br><div class="gmail_quote"><span>On Mon, Dec 14, 2015 at 9:37 AM, Kyle Griffin <span dir="ltr">&lt;<a href="mailto:ksgriffin2@wisc.edu" target="_blank">ksgriffin2@wisc.edu</a>&gt;</span> wrote:<br></span><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr">Hi all,<div><br></div><div>I wanted to highlight the result of a bit of research I&#39;ve had to do after upgrading a Mac from 10.9 to 10.11 - specifically, that DYLD_LIBRARY_PATH and DYLD_FALLBACK_LIBRARY_PATH are no longer supported by default in OS X. While they can be set, this setting is not recognized in any automated (cron) calls to scripts. Here&#39;s on example output, where I print the contents of both environmental variables before attempting to run an NCL script. One environmental variable is set in .profile (manually sourced at start of the script) and one is set within the script itself. Both are ignored. </div><div><br></div><div><p>/opt/local/lib/gcc49:/opt/local/lib/gcc</p><p>/opt/local/lib/gcc49:/opt/local/lib/gcc</p><p>dyld: Library not loaded: /usr/local/lib/libquadmath.0.dylib</p><p>  Referenced from: /Users/ksgriffin2/ncl6.3.0.1010/bin/ncl</p><p>  Reason: image not found</p></div><div><br></div><div>The dyld:... error was originally missing libgfortran.3.dylib, but I manually created a link in /usr/local/lib to the version in /opt/local/lib/gcc49 try and tackle this problem. It appears that linking libgfortran.3.dylib, libquadmath.0.dylib, and libgomp.1.dylib does the trick to allow NCL to function as a workaround, but could be problematic long-term I would guess? The binary in use here is the Mac 10.10/gcc4.9.2 binary.<br></div><div><br></div><div>Apple now claims that any software relying on this should, essentially, not rely on these techniques any more or place them all in /usr/local/ (I&#39;m using MacPorts, putting things /opt/local/) [see under last heading on the page]:</div><div><a href="https://developer.apple.com/library/mac/documentation/Security/Conceptual/System_Integrity_Protection_Guide/FileSystemProtections/FileSystemProtections.html#//apple_ref/doc/uid/TP40016462-CH2-DontLinkElementID_2" target="_blank">https://developer.apple.com/library/mac/documentation/Security/Conceptual/System_Integrity_Protection_Guide/FileSystemProtections/FileSystemProtections.html#//apple_ref/doc/uid/TP40016462-CH2-DontLinkElementID_2</a><br></div><div><br></div><div>This can, in theory, be fixed by accessing the system recovery and disabling the new &quot;System Integrity Protection&quot; feature that eliminates these issues, but I feel that is not an appropriate fix for this problem. For testing purposes, the simple process of disabling SIP is presented at the bottom of this article: <a href="http://www.macworld.com/article/2986118/security/how-to-modify-system-integrity-protection-in-el-capitan.html" target="_blank">http://www.macworld.com/article/2986118/security/how-to-modify-system-integrity-protection-in-el-capitan.html</a></div><div><br></div><div>I should note the NCL appears to work fine from the command line, although I have to test it in depth.</div><div><br></div><div>So it appears going forward that significant changes may need to be made to the NCL binaries for OS X in order for them to be functional at all. I&#39;ll be happy to serve as a guinea pig for fixes if a 10.11 system isn&#39;t available for testing...</div><div><br></div><div><br></div><div>Kyle</div><div><div><div dir="ltr"><div><div dir="ltr">----------------------------------------<div>Kyle S. Griffin</div><div>Department of Atmospheric and Oceanic Sciences</div><div>University of Wisconsin - Madison</div><div>Room 1407</div><div>1225 W Dayton St, Madison, WI 53706</div><div>Email: <a href="mailto:ksgriffin2@wisc.edu" target="_blank">ksgriffin2@wisc.edu</a></div></div></div></div></div></div>
</div>
<br></div></div><span>_______________________________________________<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/mailman/listinfo/ncl-install</a><br>
<br></span></blockquote></div><br></div>
</blockquote></div><br></div></div></div>
</blockquote></div><br></div></div>