Remove V2 code if V2 API not being built

Remove test code that uses the version 2 API if the version 2 API code is not being activated in the build.

This was originally proposed in #656 with a better fix in #755 which was removed.
This commit is contained in:
Greg Sjaardema 2018-01-31 09:00:17 -07:00 committed by GitHub
parent 070df7c583
commit 63b700c40c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -559,6 +559,7 @@ main(int argc, char **argv)
}
SUMMARIZE_ERR;
#ifndef NO_NETCDF_2
#define VAR_DIMS2 2
printf("*** testing 2D array of NC_FLOAT with v2 API...");
{
@ -584,6 +585,7 @@ main(int argc, char **argv)
ncclose(ncid);
}
SUMMARIZE_ERR;
#endif
#define NDIMS 3
#define NNAMES 4