title: ncap2: error while loading shared libraries: libnetcdf.so.7: cannot open shared object file: No such file or directory
body: <p>I tried to install nco in a remote server (RHEL 7.8) and I am not the root which means I can't use the sudo or yum in the terminal. Then I followed the instructions on the main page on nco (<a href="http://nco.sourceforge.net/src/" rel="nofollow noreferrer">http://nco.sourceforge.net/src/</a>) in which it is said pre-built way is recommended. So I used conda method. But when I used <code>conda install -c conda-forge nco</code>, the speed is too low. And finally I was told solving the environment is not successful. After that I searched the nco in conda, in <a href="https://anaconda.org/conda-forge/nco" rel="nofollow noreferrer">https://anaconda.org/conda-forge/nco</a> I was told that <code>conda install -c conda-forge/label/broken nco</code> would be ok. Yes the installation is completed. But when I want to use the command <code>ncap2</code>, I was told that</p>
  <pre><code>ncap2: error while loading shared libraries: libnetcdf.so.7: cannot open shared object file: No such file or directory
  </code></pre>
  <p>I checked my <code>LD_LIBRARY_PATH</code>, but I couldn't find the link towards libnetcdf.so.7. I used <code>find</code> command in order to find where the libnetcdf.so.7 is, but as you know I was operating on a server, so most access is denied. Here is my <code>~/.bashrc</code>:</p>
  <pre><code>export PATH=&quot;/home/xushan/anaconda3/bin:$PATH&quot;
  export PATH=&quot;$PATH:/home/xushan/openmpi/bin&quot;
  #export PATH= &quot;$HOME/openmpi/bin:$PATH&quot;
  export LD_LIBRARY_PATH=&quot;$LD_LIBRARY_PATH:/home/xushan/openmpi/lib&quot;
  export VER_MPI=&quot;NOMPI&quot;
  export LD_LIBRARY_PATH=&quot;$LD_LIBRARY_PATH:/home/xushan/SURFEX_v8_1_public/open_SURFEX_V8_1/src/LIB&quot;
  #export VER_USER=&quot;FORC&quot;
  export PATH=&quot;/home/xushan/anaconda3/bin/ncdump:$PATH&quot;
  export LD_LIBRARY_PATH=&quot;$LD_LIBRARY_PATH:/home/xushan/anaconda3/lib&quot;
  </code></pre>
  <p>One thing it is weird is that when I <code>ls</code> to <code>/usr/local/lib</code>, there is nothing....
  So is there any way to help me to complete the installation? I tried the following commands suggested in <a href="http://nco.sourceforge.net/src/" rel="nofollow noreferrer">http://nco.sourceforge.net/src/</a>:</p>
  <pre><code>wget https://github.com/nco/nco/archive/4.9.4.tar.gz
  tar xvzf 4.9.4.tar.gz
  cd nco-4.9.4
  ./configure --prefix=/usr/local
  make
  sudo make install
  export PATH=/usr/local/bin\:${PATH}
  export LD_LIBRARY_PATH=/usr/local/lib\:${LD_LIBRARY_PATH}
  </code></pre>
  <p>but when I run <code>./configure --prefix=/usr/local</code>, I was told that</p>
  <pre><code>checking for /opt/local/include/netcdf.h... no
  checking for /opt/local/lib/libnetcdf.a... no
  checking netcdf.h usability... no
  checking netcdf.h presence... no
  checking for netcdf.h... no
  configure: error: in `/home/xushan/nco-4.6.3':
  configure: error: cannot find netCDF header
  See `config.log' for more details
  </code></pre>
  <p>So is there anyone who can help me? thanks a lot! (Question is that I cannot find where the  libnetcdf.so.7 is......I am a beginner for compiling something on remote server....especially soda and yum are banned for common users....)</p>