2014-09-12 05:44:56 +08:00
|
|
|
/*
|
|
|
|
Copyright 20014, UCAR/Unidata
|
|
|
|
See COPYRIGHT file for copying and redistribution conditions.
|
|
|
|
|
|
|
|
This is part of netCDF.
|
|
|
|
|
|
|
|
This program checks to see that netcdf_meta.h exists and is
|
|
|
|
properly formatted.
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
2015-08-16 06:26:35 +08:00
|
|
|
#include <stdio.h> /* printf() */
|
2014-09-12 05:44:56 +08:00
|
|
|
#include <config.h>
|
2014-12-28 11:42:01 +08:00
|
|
|
#include <stdlib.h>
|
|
|
|
#include <stdio.h>
|
2014-09-12 05:44:56 +08:00
|
|
|
#include <netcdf.h>
|
2018-01-26 05:32:38 +08:00
|
|
|
|
2018-01-30 02:27:15 +08:00
|
|
|
#if defined(NC_HAVE_META_H)
|
2014-09-12 05:44:56 +08:00
|
|
|
#include <netcdf_meta.h>
|
2018-01-26 05:32:38 +08:00
|
|
|
#endif
|
2014-09-12 05:44:56 +08:00
|
|
|
|
|
|
|
int main(int argc, char **argv) {
|
|
|
|
|
|
|
|
/* If netcdf_meta.h is damaged, this file will
|
|
|
|
just flat-out fail to compile, also resulting
|
|
|
|
in an error.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef NETCDF_META_H
|
2018-01-26 13:21:51 +08:00
|
|
|
#ifndef NC_HAVE_META_H
|
|
|
|
printf("Error! NC_HAVE_META_H not defined. Check netcdf.h.\n");
|
2018-01-26 05:32:38 +08:00
|
|
|
#else
|
2014-09-12 05:44:56 +08:00
|
|
|
printf("Error! NETCDF_META_H not defined. Check netcdf_meta.h.\n");
|
2018-01-26 05:32:38 +08:00
|
|
|
#endif
|
2014-09-12 05:44:56 +08:00
|
|
|
return -1;
|
|
|
|
#else
|
|
|
|
printf("Success! NETCDF_META_H defined.\n");
|
|
|
|
return 0;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
}
|