The normal thing to do is to build a package in a local directory, and then use sudo to do the make install into a system directory.
But this does not work with NCEPLIBS. The cmake invocation fails in this case because I don't have permissions at the time cmake is run.
This seems to be so that the files setenv_nceplibs.* (sh and csh) can be installed. Instead, this files should be installed by make install.
-- Creating shell scripts to set environment variables for using NCEPLIBS
CMake Error: Could not open file for write in copy operation /usr/local/NCEPLIBS/bin/setenv_nceplibs.csh.tmp
CMake Error: : System Error: No such file or directory
CMake Error at CMakeLists.txt:139 (configure_file):
configure_file Problem configuring file
CMake Error: Could not open file for write in copy operation /usr/local/NCEPLIBS/bin/setenv_nceplibs.sh.tmp
CMake Error: : System Error: No such file or directory
CMake Error at CMakeLists.txt:140 (configure_file):
configure_file Problem configuring file
-- Configuring incomplete, errors occurred!
See also "/home/ed/NCEPLIBS/build/CMakeFiles/CMakeOutput.log".
See also "/home/ed/NCEPLIBS/build/CMakeFiles/CMakeError.log".
The normal thing to do is to build a package in a local directory, and then use sudo to do the make install into a system directory.
But this does not work with NCEPLIBS. The cmake invocation fails in this case because I don't have permissions at the time cmake is run.
This seems to be so that the files setenv_nceplibs.* (sh and csh) can be installed. Instead, this files should be installed by make install.