File tree Expand file tree Collapse file tree 1 file changed +44
-0
lines changed Expand file tree Collapse file tree 1 file changed +44
-0
lines changed Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ # This requires one command-line option, the installation path
4+ if [ " x$1 " = x ] ; then
5+ echo " Usage: $0 /pnetcdf/install/path"
6+ exit 1
7+ fi
8+
9+ installation_path=$1
10+
11+ # check if pnetcdf_version exists in the install folder
12+ if [ ! -x $installation_path /bin/pnetcdf_version ]; then
13+ echo " Error: pnetcdf_version not found in $installation_path /bin"
14+ exit 1
15+ fi
16+
17+ # check if pnetcdf.pc exists in the install folder
18+ if [ ! -f $installation_path /lib/pkgconfig/pnetcdf.pc ]; then
19+ echo " Error: pnetcdf.pc not found in $installation_path /lib/pkgconfig"
20+ exit 1
21+ fi
22+
23+ # check if pnetcdf-config exists in the install folder
24+ if [ ! -x $installation_path /bin/pnetcdf-config ]; then
25+ echo " Error: pnetcdf-config not found in $installation_path /bin"
26+ exit 1
27+ else
28+ # check if --prefix is correctly reflecting the install path
29+ prefixdir=` $installation_path /bin/pnetcdf-config --prefix`
30+ if [ $prefixdir != $installation_path ] ; then
31+ echo " Error: expecting '$installation_path ' from 'pnetcdf-config --prefix' but got $prefixdir "
32+ fi
33+ # check if --libdir is correctly reflecting the install path
34+ libdir=` $installation_path /bin/pnetcdf-config --libdir`
35+ if [ $libdir != $installation_path /lib ] ; then
36+ echo " Error: expecting '$installation_path /lib' from 'pnetcdf-config --libdir' but got $libdir "
37+ fi
38+ # check if --includedir is correctly reflecting the install path
39+ incdir=` $installation_path /bin/pnetcdf-config --includedir`
40+ if [ $incdir != $installation_path /include ] ; then
41+ echo " Error: expecting '$installation_path /include' from 'pnetcdf-config --includedir' but got $incdir "
42+ fi
43+ fi
44+
You can’t perform that action at this time.
0 commit comments