Installing PnetCDF
Procedure
- Use PuTTY to log in to the server as the root user.
- Decompress the PnetCDF installation package.
tar -zxvf pnetcdf-1.11.2.tar.gz
- Go to the directory generated after the decompression.
cd pnetcdf-1.11.2
- Perform the configuration.
CC=mpicc FC=mpifort CXX=mpicxx CFLAGS="$optflags -fPIC" FFLAGS="$optflags -fPIC" FCFLAGS="$optflags -fPIC" LD="$ldflags" ./configure --build=aarch64-linux --prefix=/path/to/PNETCDF --enable-shared --enable-static --enable-fortran --enable-large-file-test

- Perform the installation.
make -j$threads

make install

- Verify the installation.
ls /path/to/PNETCDF/bin ls /path/to/PNETCDF/lib

- Load the environment variables.
export PATH=/path/to/PNETCDF/bin:$PATH export LD_LIBRARY_PATH=/path/to/PNETCDF/lib:$LD_LIBRARY_PATH
Parent topic: Configuring the Compilation Environment