Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
28384 Discussions

help building NetCDF3.6.3 with ifort (parallel_studio_xe_2019.4.070)

sheaffer__patti
Beginner
2,027 Views

Can anyone help me trouble-shot?  My understanding was that I only needed ifort since it works with gcc, etc. 
Configure seems to find everything necessary, but during make, it has trouble with "cfortran.h" - which confuses me. 
I can easily make with gcc/gfortran, but my calling program will be compiled with ifort, so I need to build NetCDF with ifort.
(I was able to build OpenMPI3 with ifort/gcc.)

linux-68t00:/usr/local/netcdf-3.6.3 # gcc --version
gcc (SUSE Linux) 6.4.1 20180626 [gcc-6-branch revision 262132]
Copyright (C) 2017 Free Software Foundation, Inc.

linux-68t00:/usr/local/netcdf-3.6.3 # export F90=/home/patti/intel/bin/ifort
linux-68t00:/usr/local/netcdf-3.6.3 # export F77=/home/patti/intel/bin/ifort
linux-68t00:/usr/local/netcdf-3.6.3 # export FC=/home/patti/intel/bin/ifort
linux-68t00:/usr/local/netcdf-3.6.3 # ./configure --prefix /usr/local/netcdf363-ifort

configure: loading site script /usr/share/site/x86_64-unknown-linux-gnu
configure: netCDF 3.6.3
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
configure: checking user options
checking whether CXX is set to ''... no
checking whether FC is set to ''... no
checking whether F90 is set to ''... no
checking whether this is a netCDF-4.x build... no
checking whether netCDF extra tests should be run (developers only)... no
checking whether documentation is to be installed... no
checking whether Fortran compiler(s) should be tested during configure... yes
checking whether configure should try to set compiler flags... yes
checking whether FFIO will be used... no
checking whether to skip C++, F77, or F90 APIs if compiler is broken... yes
checking whether only the C library is desired... no
checking whether examples should be built... yes
checking whether F77 API is desired... yes
checking whether F90 API is desired... yes
checking whether fortran type sizes should be checked... yes
checking whether C API is desired... yes
checking where to get netCDF C-only library for separate fortran libraries... 
checking whether CXX API is desired... yes
checking whether v2 netCDF API should be built... yes
checking whether the ncgen/ncdump should be built... yes
checking whether large file (> 2GB) tests should be run... no
checking whether benchmaks should be run (experimental)... no
checking whether extreme numbers should be used in tests... yes
checking where to put large temp files if large file tests are run... .
checking whether a win32 DLL is desired... no
checking whether separate fortran libs are desired... no
configure: finding C compiler
checking for xlc... no
checking for cc... cc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... 
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of cc... gcc3
checking whether cc understands -c and -o together... yes
checking for an ANSI C-conforming const... yes
configure: finding Fortran compiler (will not be used if Fortran API is not desired)
checking whether we are using the GNU Fortran compiler... no
checking whether /home/patti/intel/bin/ifort accepts -g... yes
checking whether we are using the GNU Fortran 77 compiler... no
checking whether /home/patti/intel/bin/ifort accepts -g... yes
configure: setting up Fortran 90
checking for Fortran flag to compile .f90 files... none
checking fortran 90 modules inclusion flag... -I
checking if Fortran compiler can handle Fortran-90... yes
configure: finding C++ compiler (will not be used if C++ API is not desired)
checking for cl... no
checking for KCC... no
checking for CC... no
checking for cxx... no
checking for cc++... no
checking for xlC... no
checking for aCC... no
checking for c++... c++
checking whether we are using the GNU C++ compiler... yes
checking whether c++ accepts -g... yes
checking dependency style of c++... gcc3
configure: setting up libtool
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for fgrep... /bin/grep -F
checking for ld used by cc... /usr/x86_64-suse-linux/bin/ld
checking if the linker (/usr/x86_64-suse-linux/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking for /usr/x86_64-suse-linux/bin/ld option to reload object files... -r
checking how to recognize dependent libraries... pass_all
checking for ar... ar
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from cc object... ok
checking how to run the C preprocessor... cc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking whether we are using the GNU C++ compiler... (cached) yes
checking whether c++ accepts -g... (cached) yes
checking dependency style of c++... (cached) gcc3
checking how to run the C++ preprocessor... c++ -E
checking whether we are using the GNU Fortran 77 compiler... (cached) no
checking whether /home/patti/intel/bin/ifort accepts -g... (cached) yes
checking whether we are using the GNU Fortran compiler... (cached) no
checking whether /home/patti/intel/bin/ifort accepts -g... (cached) yes
checking for objdir... .libs
checking if cc supports -fno-rtti -fno-exceptions... no
checking for cc option to produce PIC... -fPIC -DPIC
checking if cc PIC flag -fPIC -DPIC works... yes
checking if cc static flag -static works... no
checking if cc supports -c -o file.o... yes
checking if cc supports -c -o file.o... (cached) yes
checking whether the cc linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for ld used by c++... /usr/x86_64-suse-linux/bin/ld -m elf_x86_64
checking if the linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) is GNU ld... yes
checking whether the c++ linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) supports shared libraries... yes
checking for c++ option to produce PIC... -fPIC -DPIC
checking if c++ PIC flag -fPIC -DPIC works... yes
checking if c++ static flag -static works... no
checking if c++ supports -c -o file.o... yes
checking if c++ supports -c -o file.o... (cached) yes
checking whether the c++ linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for /home/patti/intel/bin/ifort option to produce PIC... -KPIC
checking if /home/patti/intel/bin/ifort PIC flag -KPIC works... no
checking if /home/patti/intel/bin/ifort static flag -static works... no
checking if /home/patti/intel/bin/ifort supports -c -o file.o... yes
checking if /home/patti/intel/bin/ifort supports -c -o file.o... (cached) yes
checking whether the /home/patti/intel/bin/ifort linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for /home/patti/intel/bin/ifort option to produce PIC... -KPIC
checking if /home/patti/intel/bin/ifort PIC flag -KPIC works... no
checking if /home/patti/intel/bin/ifort static flag -static works... no
checking if /home/patti/intel/bin/ifort supports -c -o file.o... yes
checking if /home/patti/intel/bin/ifort supports -c -o file.o... (cached) yes
checking whether the /home/patti/intel/bin/ifort linker (/usr/x86_64-suse-linux/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
configure: finding other utilities
checking for a BSD-compatible install... /usr/bin/install -c
configure: trying to set fortran flags for this platform
configure: trying to set flags for this platform
checking if _HPUX_SOURCE should be set... no
checking if Solaris -Xa option is needed... CFLAGS=-g -O2
configure: trying to set fortran 90 flags for this platform
checking if we need to add to FFLAGS for ifort compiler... FFLAGS=-g
checking if we need to set _LARGE_FILES despite results of previous tests... _LARGE_FILES=
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no
configure: displaying some results
checking CPPFLAGS... 
checking CC CFLAGS... cc -g -O2
checking type cc... cc is /usr/bin/cc
checking CXX... c++
checking CXXFLAGS... -g -O2
checking type c++... c++ is /usr/bin/c++
checking FC... /home/patti/intel/bin/ifort
checking FFLAGS... -g
checking type /home/patti/intel/bin/ifort... /home/patti/intel/bin/ifort is /home/patti/intel/bin/ifort
checking F90... /home/patti/intel/bin/ifort
checking F90FLAGS... 
checking type /home/patti/intel/bin/ifort... /home/patti/intel/bin/ifort is /home/patti/intel/bin/ifort
checking AR... ar
checking AR_FLAGS... cru
checking type ar... ar is /usr/bin/ar
checking NM... /usr/bin/nm -B
checking NMFLAGS... 
checking for /usr/bin/nm... /usr/bin/nm -B
checking nm flags... 
checking for C-equivalent to Fortran routine "SUB"... sub_
checking for Fortran "byte"... yes
checking for Fortran "integer*2"... yes
checking if Fortran "byte" is C "signed char"... yes
checking if Fortran "byte" is C "short"... no
checking if Fortran "byte" is C "int"... no
checking if Fortran "byte" is C "long"... no
checking if Fortran "integer*2" is C "short"... yes
checking if Fortran "integer*2" is C "int"... no
checking if Fortran "integer*2" is C "long"... no
checking if Fortran "integer" is C "int"... yes
checking if Fortran "real" is C "float"... yes
checking if Fortran "doubleprecision" is C "double"... yes
checking for Fortran-equivalent to netCDF "byte"... byte
checking for Fortran-equivalent to netCDF "short"... integer*2
checking if Fortran 90 compiler capitalizes .mod filenames... no
configure: checking types, headers, and functions
checking for stdlib.h... (cached) yes
checking for sys/types.h... (cached) yes
checking for stdbool.h that conforms to C99... yes
checking for _Bool... yes
checking for strlcat... no
checking for strerror... yes
checking for working alloca.h... yes
checking for alloca... yes
checking whether isnan is declared... yes
checking whether isinf is declared... yes
checking whether isfinite is declared... yes
checking whether signbit is declared... yes
checking for struct stat.st_blksize... yes
checking for IEEE floating point format... yes
checking for size_t... yes
checking for off_t... yes
checking for ssize_t... yes
checking for ptrdiff_t... yes
checking for uchar... no
checking whether char is unsigned... no
checking whether byte ordering is bigendian... no
checking size of short... 2
checking size of int... 4
checking size of long... 8
checking size of float... 4
checking size of double... 8
checking size of off_t... 8
checking size of size_t... 8
checking for manual-page index command... 
checking what to call the output of the ftpbin target... binary-netcdf-3.6.3_nc3_/home/patti/intel/bin/ifort_/home/patti/intel/bin/ifort_c++.tar /home/patti/intel/bin/ifort c++
checking binary distribution directory... /home/ftp/pub/binary/dummy_system
checking for gawk... (cached) gawk
checking for flex... flex
checking lex output file root... lex.yy
checking lex library... -lfl
checking whether yytext is a pointer... yes
checking whether ln -s works... yes
checking whether make sets $(MAKE)... (cached) yes
configure: generating header files and makefiles
configure: creating ./config.status
config.status: creating Makefile
config.status: creating man/Makefile
config.status: creating man4/Makefile
config.status: creating fortran/Makefile
config.status: creating libsrc/Makefile
config.status: creating libsrc4/Makefile
config.status: creating nctest/Makefile
config.status: creating nc_test4/Makefile
config.status: creating nc_test/Makefile
config.status: creating ncdump/Makefile
config.status: creating ncgen/Makefile
config.status: creating nf_test/Makefile
config.status: creating cxx/Makefile
config.status: creating cxx4/Makefile
config.status: creating f90/Makefile
config.status: creating examples/Makefile
config.status: creating examples/C/Makefile
config.status: creating examples/CDL/Makefile
config.status: creating examples/CXX/Makefile
config.status: creating examples/CXX4/Makefile
config.status: creating examples/F90/Makefile
config.status: creating examples/F77/Makefile
config.status: creating win32/Makefile
config.status: creating win32/NET/Makefile
config.status: creating win32/NET/libsrc/Makefile
config.status: creating win32/NET/ncdump/Makefile
config.status: creating win32/NET/ncgen/Makefile
config.status: creating win32/NET/examples/Makefile
config.status: creating win32/NET/nctest/Makefile
config.status: creating win32/NET/nc_test/Makefile
config.status: creating config.h
config.status: creating fortran/nfconfig1.inc
config.status: executing depfiles commands
config.status: executing libtool commands

linux-68t00:/usr/local/netcdf-3.6.3 # make

make  all-recursive
make[1]: Entering directory '/usr/local/netcdf-3.6.3'
Making all in f90
make[2]: Entering directory '/usr/local/netcdf-3.6.3/f90'
/bin/sh ../libtool   --mode=compile /home/patti/intel/bin/ifort -I../libsrc -I.  -g -c -o typeSizes.lo typeSizes.f90
libtool: compile:  /home/patti/intel/bin/ifort -I../libsrc -I. -g -c typeSizes.f90 -o typeSizes.o
/bin/sh ../libtool   --mode=compile /home/patti/intel/bin/ifort -I../libsrc -I.  -g -c -o netcdf.lo netcdf.f90
libtool: compile:  /home/patti/intel/bin/ifort -I../libsrc -I. -g -c netcdf.f90 -o netcdf.o
/bin/sh ../libtool   --mode=link /home/patti/intel/bin/ifort -I../libsrc -I.  -g   -o libnetcdff90.la  typeSizes.lo  netcdf.lo  
libtool: link: ar cru .libs/libnetcdff90.a  typeSizes.o netcdf.o
libtool: link: ranlib .libs/libnetcdff90.a
libtool: link: ( cd ".libs" && rm -f "libnetcdff90.la" && ln -s "../libnetcdff90.la" "libnetcdff90.la" )
make[2]: Leaving directory '/usr/local/netcdf-3.6.3/f90'
Making all in fortran
make[2]: Entering directory '/usr/local/netcdf-3.6.3/fortran'
echo '!     NetCDF-3.' > netcdf.inc
cat ../fortran/netcdf3.inc >> netcdf.inc
echo >> netcdf.inc
echo '!     NetCDF-2.' >> netcdf.inc
cat ../fortran/netcdf2.inc >> netcdf.inc
make  all-am
make[3]: Entering directory '/usr/local/netcdf-3.6.3/fortran'
depbase=`echo fort-attio.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool --tag=CC   --mode=compile cc -DHAVE_CONFIG_H -I. -I..     -I../libsrc    -g -O2 -MT fort-attio.lo -MD -MP -MF $depbase.Tpo -c -o fort-attio.lo fort-attio.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  cc -DHAVE_CONFIG_H -I. -I.. -I../libsrc -g -O2 -MT fort-attio.lo -MD -MP -MF .deps/fort-attio.Tpo -c fort-attio.c -o fort-attio.o
In file included from ncfortran.h:12:0,
                 from fort-attio.c:7:
cfortran.h:138:3: error: #error "cfortran.h:  Can't find your environment among:    - MIPS cc and f77 2.0. (e.g. Silicon Graphics, DECstations, ...)         - IBM AIX XL C and FORTRAN Compiler/6000 Version 01.01.0000.0000         - VAX   VMS CC 3.1 and FORTRAN 5.4.                                      - Alpha VMS DEC C 1.3 and DEC FORTRAN 6.0.                               - Alpha OSF DEC C and DEC Fortran for OSF/1 AXP Version 1.2              - Apollo DomainOS 10.2 (sys5.3) with f77 10.7 and cc 6.7.                - CRAY                                                                   - NEC SX-4 SUPER-UX                                                      - CONVEX                                                                 - Sun                                                                    - PowerStation Fortran with Visual C++                                   - HP9000s300/s700/s800 Latest test with: HP-UX A.08.07 A 9000/730        - LynxOS: cc or gcc with f2c.                                            - VAXUltrix: vcc,cc or gcc with f2c. gcc or cc with f77.                 -            f77 with vcc works; but missing link magic for f77 I/O.     -            NO fort. None of gcc, cc or vcc generate required names.    - f2c    : Use #define    f2cFortran, or cc -Df2cFortran                 - NAG f90: Use #define NAGf90Fortran, or cc -DNAGf90Fortran              - Absoft UNIX F77: Use #define AbsoftUNIXFortran or cc -DAbsoftUNIXFortran     - Absoft Pro Fortran: Use #define AbsoftProFortran     - Portland Group Fortran: Use #define pgiFortran     - PathScale Fortran: Use #define PATHSCALE_COMPILER"
  #error "cfortran.h:  Can't find your environment among:\
   ^~~~~
make[3]: *** [Makefile:426: fort-attio.lo] Error 1
make[3]: Leaving directory '/usr/local/netcdf-3.6.3/fortran'
make[2]: *** [Makefile:298: all] Error 2
make[2]: Leaving directory '/usr/local/netcdf-3.6.3/fortran'
make[1]: *** [Makefile:362: all-recursive] Error 1
make[1]: Leaving directory '/usr/local/netcdf-3.6.3'
make: *** [Makefile:292: all] Error 2

 

0 Kudos
1 Solution
Juergen_R_R
Valued Contributor I
2,027 Views

Did you try to set

export CPPFLAGS=-Df2cFortran

or

setenv CPPFLAGS -Df2cFortran

?

View solution in original post

0 Kudos
6 Replies
Juergen_R_R
Valued Contributor I
2,028 Views

Did you try to set

export CPPFLAGS=-Df2cFortran

or

setenv CPPFLAGS -Df2cFortran

?

0 Kudos
sheaffer__patti
Beginner
2,006 Views

I dont' think I saw that anywhere on web searches, but thank you very much - it seems to have worked!

Michelle

EDIT:  Oops, my bad - this only partially fixed the problem.  It got most of the way through make check successfully after adding that flag, then threw some errors that prevented the make from finishing.

0 Kudos
mecej4
Honored Contributor III
1,989 Views

Patti,

There have been a number of posts over the years regarding building/using NETCDF with Intel Fortran. You can search for "NETCDF" in these forums, but I am afraid that some of the links in the earlier posts no longer work because of the major changes to the forum software this month.

See https://software.intel.com/en-us/comment/1816799# , for example. The version of NETCDF discussed there is not the one that you mentioned, and some entry point are left unfilled, but if what is there works for you, that may be enough for now.

0 Kudos
JohnNichols
Valued Contributor III
1,980 Views

Version 4.5.3 of the netCDF-Fortran library is now available.

Why would a group as diverse as this group not make the connection to Intel Fortran, they know it very well - for them it would be a trivial step, for someone else it can be days of pain.  

It is not that difficult DISLIN matches to every Fortran compiler and one guy wrote that code. 

0 Kudos
sheaffer__patti
Beginner
1,934 Views

Thank you mece - there didn't seem to be anything in that thread that I'm technically skilled enough to use.  I didn't think ifortran would have such 'gotchas' as it's been around and heavily used for a LONG time.  I guess I'll keep looking for a while but since there aren't any solutions on the intel forum, I will likely have to go back to gfortran.  I know in some applications, ifortran can result in tens of % speed-up on intel chips - but this netcdf is a real wall.

Is there a way to get gfortran-compiled netcdf libraries to work in a program compiled with ifortran?  Just a thought of a newbie...  

0 Kudos
sheaffer__patti
Beginner
1,932 Views

That fixed the "make" problem, but during "make check" it threw an error. 
Maybe "make check" is an unimportant step I can ignore??  Probably not, or else netcdf would be easy to build with ifortran - but threads on this forum indicate it is not easy...

Here's the exact spot - it passes a LOT of tests, then goes on and on with an error...

<...>

*** Testing ncgen and ncdump for UTF8 support...
*** creating classic offset file with utf8 characters...
*** dump and compare utf8 output...
*** creating 64-bit offset file with utf8 characters...
*** (64 bit) dump and compare utf8 output...
*** dumping tst_utf8.nc to tst_utf8.cdl...
*** comparing tst_utf8.cdl with tst8.cdl...
*** All utf8 tests of ncgen and ncdump passed!
PASS: run_utf8_tests.sh
==================
All 8 tests passed
==================
make[3]: Leaving directory '/usr/local/netcdf-3.6.3/ncdump'
make[2]: Leaving directory '/usr/local/netcdf-3.6.3/ncdump'
make[1]: Leaving directory '/usr/local/netcdf-3.6.3/ncdump'
Making check in nf_test
make[1]: Entering directory '/usr/local/netcdf-3.6.3/nf_test'
make  nf_test tst_f77_v2     ftest tst_f90
make[2]: Entering directory '/usr/local/netcdf-3.6.3/nf_test'
/opt/intel/bin/ifort -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran -I../fortran      -I../libsrc -I../fortran  -I../f90 -g -c -o test_get.o test_get.F
/opt/intel/bin/ifort -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran -I../fortran      -I../libsrc -I../fortran  -I../f90 -g -c -o test_put.o test_put.F
/opt/intel/bin/ifort -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran -I../fortran      -I../libsrc -I../fortran  -I../f90 -g -c -o nf_error.o nf_error.F
/opt/intel/bin/ifort -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran -I../fortran      -I../libsrc -I../fortran  -I../f90 -g -c -o nf_test.o nf_test.F
/opt/intel/bin/ifort -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran -I../fortran      -I../libsrc -I../fortran  -I../f90 -g -c -o test_read.o test_read.F
/opt/intel/bin/ifort -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran -I../fortran      -I../libsrc -I../fortran  -I../f90 -g -c -o test_write.o test_write.F
/opt/intel/bin/ifort -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran -I../fortran      -I../libsrc -I../fortran  -I../f90 -g -c -o util.o util.F
depbase=`echo fortlib.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
cc -DHAVE_CONFIG_H -I. -I.. -I../fortran   -Df2cFortran  -g -O2 -MT fortlib.o -MD -MP -MF $depbase.Tpo -c -o fortlib.o fortlib.c &&\
mv -f $depbase.Tpo $depbase.Po
/bin/sh ../libtool --tag=F77   --mode=link /opt/intel/bin/ifort -I../fortran      -I../libsrc -I../fortran  -I../f90 -g        -o nf_test test_get.o test_put.o nf_error.o nf_test.o test_read.o test_write.o util.o fortlib.o      ../libsrc/libnetcdf.la   
libtool: link: /opt/intel/bin/ifort -I../fortran -I../libsrc -I../fortran -I../f90 -g -o nf_test test_get.o test_put.o nf_error.o nf_test.o test_read.o test_write.o util.o fortlib.o  ../libsrc/.libs/libnetcdf.a
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: test_get.o: in function `test_nf_get_var1_text_':
/usr/local/netcdf-3.6.3/nf_test/test_get.F:25: undefined reference to `nf_open_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:34: undefined reference to `nf_get_var1_text_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:37: undefined reference to `nf_get_var1_text_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:43: undefined reference to `nf_get_var1_text_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:60: undefined reference to `nf_get_var1_text_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:93: undefined reference to `nf_close_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: test_get.o: in function `test_nf_get_var1_int1_':
/usr/local/netcdf-3.6.3/nf_test/test_get.F:116: undefined reference to `nf_open_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:125: undefined reference to `nf_get_var1_int1_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:128: undefined reference to `nf_get_var1_int1_'
/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/test_get.F:134: undefined reference to `nf_get_var1_int1_'

<...>

/usr/lib64/gcc/x86_64-suse-linux/7/../../../../x86_64-suse-linux/bin/ld: /usr/local/netcdf-3.6.3/nf_test/util.F:1361: undefined reference to `max_double_'
make[2]: *** [Makefile:611: nf_test] Error 1
make[2]: Leaving directory '/usr/local/netcdf-3.6.3/nf_test'
make[1]: *** [Makefile:845: check-am] Error 2
make[1]: Leaving directory '/usr/local/netcdf-3.6.3/nf_test'
make: *** [Makefile:362: check-recursive] Error 1



0 Kudos
Reply