# I/O API Installation (v3.2) Issues

**URL:** <https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406>\
**Category:** I/O API\
**Created:** [November 12, 2018, 3:11pm UTC](https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406 "2018-11-12T15:11:54Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![skunwar](https://avatars.discourse-cdn.com/v4/letter/s/9f8e36/32.png) [@skunwar](https://forum.cmascenter.org/u/skunwar)\
**Post date:** [November 12, 2018, 3:11pm UTC](https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406/1 "2018-11-12T15:11:54Z")

</div>

Some of the tools of I/O API like wrftom3 are available beginning version 3.2, so I wanted to install v3.2, but had the following 3 errors types when trying to compile using Intel 17.2 compiler and netCDF4.1.3 library:

1. /home/ioapi/modatts3.F90(47): error #7013: This module file was not generated by any release of this compiler. [MODNCFIO]  
USE MODNCFIO

2. /home/ioapi/modatts3.F90(2054): error #6404: This name does not have  
a type, and must have an explicit type. [NF\_GLOBAL]  
IERR = NF\_INQ\_ATTID( CDFID3( FNUM ), NF\_GLOBAL, ‘CMAQVERS’, ATTNUM )

3. compilation aborted for /home/ioapi/modatts3.F90 (code 1)  
make: \*\*\* [modatts3.mod] Error 1

What could be the cause of these errors? v3.1 installed fine with the same Intel compiler and netCDF library.

---

<div class="post-metadata">

**Author:** ![cjcoats](https://avatars.discourse-cdn.com/v4/letter/c/ac8455/32.png) [@cjcoats](https://forum.cmascenter.org/u/cjcoats)\
**Post date:** [November 12, 2018, 3:33pm UTC](https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406/2 "2018-11-12T15:33:58Z")

</div>

This seems to be a botched-installation problem. There exists a “foreign” modncfio.mod which the compiler can’t deal with.

First, make sure that there are no object nor module files in the source directory:

```
cd ioapi/; rm *.mod *.o

```

Then clean up the previous installation (from the “ioapi” source-directory):

```
make clean

```

And finally re-build (from the “ioapi” source-directory):

```
make
```

---

<div class="post-metadata">

**Author:** ![skunwar](https://avatars.discourse-cdn.com/v4/letter/s/9f8e36/32.png) [@skunwar](https://forum.cmascenter.org/u/skunwar)\
**Post date:** [November 12, 2018, 8:36pm UTC](https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406/3 "2018-11-12T20:36:07Z")

</div>

Thanks! I removed all .mod and .o files under ioapi/ directory, and ‘make’ happened smoothly in ioapi/

Now, I am giving ‘make’ command under ioapi/m3tools/ and got this error:

/home/ioapi/Linux2\_x86\_64ifort/libnetcdf.a(libnetcdf4\_la-nc4file.o): In function `nc4_create_file': /home/mcip_cmaq_intel_libs/netcdf-4.1.3/libsrc4/nc4file.c:233: undefined reference to`H5P\_CLS\_FILE\_ACCESS\_ID\_g’  
/home/mcip\_cmaq\_intel\_libs/netcdf-4.1.3/libsrc4/nc4file.c:276: undefined reference to `H5P_CLS_FILE_CREATE_ID_g' /home/ioapi/Linux2_x86_64ifort/libnetcdf.a(libnetcdf4_la-nc4file.o): In function`nc4\_open\_file’:  
/home/mcip\_cmaq\_intel\_libs/netcdf-4.1.3/libsrc4/nc4file.c:1978: undefined reference to `H5P_CLS_FILE_ACCESS_ID_g' /home/ioapi/Linux2_x86_64ifort/libnetcdf.a(libnetcdf4_la-nc4hdf.o): In function`write\_dim’:  
/home/mcip\_cmaq\_intel\_libs/netcdf-4.1.3/libsrc4/nc4hdf.c:2157: undefined reference to `H5P_CLS_DATASET_CREATE_ID_g' /home/ioapi/Linux2_x86_64ifort/libnetcdf.a(libnetcdf4_la-nc4hdf.o): In function`var\_create\_dataset’:  
/home/mcip\_cmaq\_intel\_libs/netcdf-4.1.3/libsrc4/nc4hdf.c:1262: undefined reference to `H5P_CLS_DATASET_CREATE_ID_g' /home/mcip_cmaq_intel_libs/netcdf-4.1.3/libsrc4/nc4hdf.c:1267: undefined reference to`H5P\_CLS\_DATASET\_ACCESS\_ID\_g’  
/home/ioapi/Linux2\_x86\_64ifort/libnetcdf.a(libnetcdf4\_la-nc4hdf.o): In function `create_group': /home/mcip_cmaq_intel_libs/netcdf-4.1.3/libsrc4/nc4hdf.c:1850: undefined reference to`H5P\_CLS\_GROUP\_CREATE\_ID\_g’  
/home/ioapi/Linux2\_x86\_64ifort/libnetcdf.a(libnetcdf4\_la-nc4hdf.o): In function `nc4_put_vara': /home/mcip_cmaq_intel_libs/netcdf-4.1.3/libsrc4/nc4hdf.c:683: undefined reference to`H5P\_CLS\_DATASET\_XFER\_ID\_g’  
/home/ioapi/Linux2\_x86\_64ifort/libnetcdf.a(libnetcdf4\_la-nc4hdf.o): In function `nc4_get_vara': /home/mcip_cmaq_intel_libs/netcdf-4.1.3/libsrc4/nc4hdf.c:1013: undefined reference to`H5P\_CLS\_DATASET\_XFER\_ID\_g’  
/home/ioapi/Linux2\_x86\_64ifort/libnetcdf.a(libnetcdf4\_la-nc4var.o): In function `nc4_reopen_dataset': /home/mcip_cmaq_intel_libs/netcdf-4.1.3/libsrc4/nc4var.c:52: undefined reference to`H5P\_CLS\_DATASET\_ACCESS\_ID\_g’  
make: \*\*\* [airs2m3] Error 1

---

<div class="post-metadata">

**Author:** ![cjcoats](https://avatars.discourse-cdn.com/v4/letter/c/ac8455/32.png) [@cjcoats](https://forum.cmascenter.org/u/cjcoats)\
**Post date:** [November 12, 2018, 8:59pm UTC](https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406/4 "2018-11-12T20:59:00Z")

</div>

See [Availability/Download of the BAMS/Models-3 I/O&nbsp;API](https://cjcoats.github.io/ioapi/AVAIL.html#ncf4)

NetCDF Version 4.x have lots of additional build options, that will require a complex set of additional libraries in Makefiles **and all other model-building systems**. It is recommended that you disable these options by adding the command-line flags below to your netCDF configure command:

> ` --disable-netcdf4 --disable-dap

or (depending upon netCDF version; don’t you _love_ consistency and compatibility !?? )

> ` --disable-netcdf-4 --disable-dap `

---

<div class="post-metadata">

**Author:** ![skunwar](https://avatars.discourse-cdn.com/v4/letter/s/9f8e36/32.png) [@skunwar](https://forum.cmascenter.org/u/skunwar)\
**Post date:** [November 13, 2018, 4:50pm UTC](https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406/5 "2018-11-13T16:50:36Z")

</div>

Using **–disable-netcdf-4** did the trick. It turned out I only had the --disable-dap option used during netCDF configure. Thanks!

---

<div class="post-metadata">

**Author:** ![Uranus007](https://avatars.discourse-cdn.com/v4/letter/u/3e96dc/32.png) [@Uranus007](https://forum.cmascenter.org/u/Uranus007)\
**Post date:** [December 11, 2018, 5:28am UTC](https://forum.cmascenter.org/t/i-o-api-installation-v3-2-issues/406/6 "2018-12-11T05:28:13Z")

</div>

Your have to link the lib when you build ioapi. Many functions are in the link file, like .o .so etc…  
You can try to add netcdf lib path in m3tools Makefile at line LIBS after you’ve install the zlib hdf5 curl lib.Like:  
LIBS = -L/usr/local/netcdf4.6.2/lib   
Hope this will help you.
