This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
>To: address@hidden >From: Jim Long <address@hidden> >Subject: install help >Organization: . >Keywords: 199811240116.SAA06217 Jim, > I though I had to change the environment variables in the > macros.make.def file, do I do it instead in .cshrc? Yes, I am a newbie.... Sorry I wasn't clearer about this. You don't make any changes to any files. You just make sure the necessary environment variables are set in your environment before you run the configure script again. The INSTALL file doesn't give detailed instructions for how to set environment variables. How you set an environment variable on a Unix system depends on which shell you are using. You can usually tell which shell you are using by invoking the command "echo $SHELL". If you are using a shell such as "csh" or "tcsh" to interact with the system, environment variables are set with the "setenv" command, for example: % setenv CC /opt/SUNWspro/bin/c89 % setenv CPPFLAGS "" % setenv CFLAGS "-O" % setenv FC /opt/SUNWspro/bin/f77 % setenv FFLAGS "-O -erroff=WDECL_LOCAL_NOTUSED" % setenv CXX /opt/SUNWspro/bin/CC If you are using ksh, sh, or bash, use the "export" statement instead to set environment variables, for example: $ export CC=/opt/SUNWspro/bin/c89 $ export CPPFLAGS= $ export CFLAGS=-O $ export FC=/opt/SUNWspro/bin/f77 $ export FFLAGS="-O -erroff=WDECL_LOCAL_NOTUSED" $ export CXX=/opt/SUNWspro/bin/CC In either case, after setting the environment variables you want, you should start over with building netcdf, such as the following: % make distclean # don't worry if this produces an error message % rm config.cache # necessary if you have run the configure script here before % ./configure # run the script, maybe use --prefix=wherever to tell # where it will be installed, as described in INSTALL % make all % make test % make install --Russ _____________________________________________________________________ Russ Rew UCAR Unidata Program address@hidden http://www.unidata.ucar.edu