]> git.pld-linux.org Git - packages/hdf-eos5.git/blob - hdf-eos5-types.patch
- added support for hid_t longer than long (i.e. int64_t on ILP32)
[packages/hdf-eos5.git] / hdf-eos5-types.patch
1 --- hdfeos5/gctp/src/gctp.c.orig        2019-12-09 16:33:53.493125031 +0100
2 +++ hdfeos5/gctp/src/gctp.c     2019-12-09 16:33:57.559769667 +0100
3 @@ -45,8 +45,8 @@
4  static long outdat[MAXPROJ + 1];       /* output dataum array          */
5  static long outzn[MAXPROJ + 1];                /* output zone array            */
6  static double pdout[MAXPROJ + 1][15];  /* output projection parm array */
7 -static long (*for_trans[MAXPROJ + 1])();/* forward function pointer array*/
8 -static long (*inv_trans[MAXPROJ + 1])();/* inverse function pointer array*/
9 +static int (*for_trans[MAXPROJ + 1])();/* forward function pointer array*/
10 +static int (*inv_trans[MAXPROJ + 1])();/* inverse function pointer array*/
11  
12                         /* Table of unit codes as specified by state
13                            laws as of 2/1/92 for NAD 1983 State Plane
14 @@ -56,6 +56,13 @@
15  static long NADUT[134] = {1, 5, 1, 1, 5, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 2, 2,
16                           1, 1, 5, 2, 1, 2, 5, 1, 2, 2, 2, 1, 1, 1, 5, 2, 1, 5,
17                           2, 2, 5, 2, 1, 1, 5, 2, 2, 1, 2, 1, 2, 2, 1, 2, 2, 2};
18 +
19 +int init(long ipr, long jpr, char *efile, char *pfile);
20 +long untfz(long inunit, long outunit, double *factor);
21 +void close_file(void);
22 +int inv_init(int insys, int inzone, double *inparm, int indatum, char *fn27, char *fn83, int *iflg, int (*inv_trans[])(double, double, double*, double*));
23 +int for_init(int outsys, int outzone, double *outparm, int outdatum, char *fn27, char *fn83, int *iflg, int (*for_trans[])(double, double, double *, double *));
24 +
25  /*
26  static long NAD83[134] = {101,102,5010,5300,201,202,203,301,302,401,402,403,
27                  404,405,406,0000,501,502,503,600,700,901,902,903,1001,1002,
28 @@ -69,7 +76,7 @@
29                  4502,4601,4602,4701,4702,4801,4802,4803,4901,4902,4903,4904,
30                  5001,5002,5003,5004,5005,5006,5007,5008,5009,5200,0000,5400};
31  */
32 -gctp(incoor,insys,inzone,inparm,inunit,indatum,ipr,efile,jpr,pfile,outcoor,
33 +int gctp(incoor,insys,inzone,inparm,inunit,indatum,ipr,efile,jpr,pfile,outcoor,
34       outsys,outzone,outparm,outunit,outdatum,fn27,fn83,iflg)
35  
36  double *incoor;                /* input coordinates                            */
37 @@ -258,10 +258,10 @@
38           dummy[0] = inparm[0];
39           dummy[1] = inparm[1];
40           }
41 -      inv_init((int)*insys,(int)*inzone,dummy,(int)*indatum,fn27,fn83,&iflgval,(int *)inv_trans);
42 +      inv_init((int)*insys,(int)*inzone,dummy,(int)*indatum,fn27,fn83,&iflgval,inv_trans);
43        }
44     else
45 -     inv_init((int)*insys,(int)*inzone,inparm,(int)*indatum,fn27,fn83,&iflgval,(int *)inv_trans);
46 +     inv_init((int)*insys,(int)*inzone,inparm,(int)*indatum,fn27,fn83,&iflgval,inv_trans);
47     *iflg=(long)iflgval;
48  
49     if ((int)*iflg != 0)
50 @@ -320,10 +320,10 @@
51          dummy[0] = outparm[0];
52          dummy[1] = outparm[1];
53          }
54 -      for_init((int)*outsys,(int)*outzone,dummy,(int)*outdatum,fn27,fn83,&iflgval,(int *)for_trans);
55 +      for_init((int)*outsys,(int)*outzone,dummy,(int)*outdatum,fn27,fn83,&iflgval,for_trans);
56        }
57     else
58 -     for_init((int)*outsys,(int)*outzone,outparm,(int)*outdatum,fn27,fn83,&iflgval,(int *)for_trans);
59 +     for_init((int)*outsys,(int)*outzone,outparm,(int)*outdatum,fn27,fn83,&iflgval,for_trans);
60  
61     *iflg=(long)iflgval;
62  
63 --- hdfeos5/gctp/src/br_gctp.c.orig     2006-12-07 16:52:24.000000000 +0100
64 +++ hdfeos5/gctp/src/br_gctp.c  2019-12-09 16:37:52.638496136 +0100
65 @@ -1,7 +1,10 @@
66 +#include <stddef.h>
67  
68  #ifdef unix
69  /*  Fortran bridge routine for the UNIX */
70  
71 +int gctp(double *incoor, long *insys, long *inzone, double *inparm, long *inunit, long *indatum, long *ipr, char *efile, long *jpr, char *pfile, double *outcoor, long *outsys, long *outzone, double *outparm, long *outunit, long *outdatum, char fn27[], char fn83[], long *iflg);
72 +
73  void gctp_(incoor,insys,inzone,inparm,inunit,indatum,ipr,efile,jpr,pfile,
74                 outcoor, outsys,outzone,outparm,outunit,fn27,fn83,iflg)
75  
76 @@ -20,11 +22,13 @@
77  long *outzone;
78  double *outparm;
79  long *outunit;
80 +char fn27[];
81 +char fn83[];
82  long *iflg;
83  
84  {
85  gctp(incoor,insys,inzone,inparm,inunit,indatum,ipr,efile,jpr,pfile,outcoor,
86 -     outsys,outzone,outparm,outunit,fn27,fn83,iflg);
87 +     outsys,outzone,outparm,outunit,NULL /* FIXME */,fn27,fn83,iflg);
88  
89  return;
90  }
91 --- hdfeos5/src/EHapi.c.orig    2017-11-13 17:02:41.000000000 +0100
92 +++ hdfeos5/src/EHapi.c 2019-12-10 05:33:39.956327678 +0100
93 @@ -2222,7 +2222,7 @@
94    if (fid < HE5_EHIDOFFSET || fid > HE5_NEOSHDF + HE5_EHIDOFFSET)
95      {
96           status = FAIL;
97 -         sprintf(errbuf,"Invalid file ID: %d. ID should range from %d to  %d .\n", fid, HE5_EHIDOFFSET, HE5_NEOSHDF + HE5_EHIDOFFSET);
98 +         sprintf(errbuf,"Invalid file ID: %"PRId64". ID should range from %d to  %d .\n", fid, HE5_EHIDOFFSET, HE5_NEOSHDF + HE5_EHIDOFFSET);
99           H5Epush(__FILE__, "HE5_EHchkfid", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf); 
100           HE5_EHprint(errbuf, __FILE__, __LINE__); 
101      } 
102 @@ -2234,7 +2234,7 @@
103           if( HE5_HeosTable[ fid0 ].active == 0) 
104          {
105                   status = FAIL;
106 -                 sprintf(errbuf,"HE5_EHchkid: File ID %d not active (%s).\n",fid, name);
107 +                 sprintf(errbuf,"HE5_EHchkid: File ID %"PRId64" not active (%s).\n",fid, name);
108                   H5Epush(__FILE__, "HE5_EHchkfid", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf); 
109                   HE5_EHprint(errbuf, __FILE__, __LINE__); 
110          }
111 @@ -8615,7 +8615,7 @@
112    else
113      {
114        status = FAIL;
115 -      sprintf(errbuf,"Invalid file ID: %d . ID should range from %d to %d . \n", fid, HE5_EHIDOFFSET, HE5_NEOSHDF + HE5_EHIDOFFSET);
116 +      sprintf(errbuf,"Invalid file ID: %"PRId64" . ID should range from %d to %d . \n", fid, HE5_EHIDOFFSET, HE5_NEOSHDF + HE5_EHIDOFFSET);
117        H5Epush(__FILE__,  "HE5_EHclose", __LINE__, H5E_FILE, H5E_BADFILE, errbuf); 
118        HE5_EHprint(errbuf, __FILE__, __LINE__);
119      }
120 @@ -12023,7 +12023,7 @@
121    if( HE5_HeosTable[ fid0 ].active == 0) 
122      {
123        status = FAIL;
124 -      sprintf(errbuf,"HE5_EHwritemeta: File ID %d not active \n",fid);
125 +      sprintf(errbuf,"HE5_EHwritemeta: File ID %"PRId64" not active \n",fid);
126        H5Epush(__FILE__, "HE5_EHwritemeta", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf); 
127        HE5_EHprint(errbuf, __FILE__, __LINE__); 
128      }
129 @@ -12295,7 +12295,7 @@
130    if( HE5_HeosTable[ fid0 ].active == 0) 
131      {
132        status = FAIL;
133 -      sprintf(errbuf,"HE5_EHreadmeta: File ID %d not active \n",fid);
134 +      sprintf(errbuf,"HE5_EHreadmeta: File ID %"PRId64" not active \n",fid);
135        H5Epush(__FILE__, "HE5_EHreadmeta", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf); 
136        HE5_EHprint(errbuf, __FILE__, __LINE__); 
137      }
138 @@ -12605,7 +12605,7 @@
139    if( HE5_HeosTable[ fid0 ].active == 0) 
140      {
141        status = FAIL;
142 -      sprintf(errbuf,"HE5_EHreadmeta: File ID %d not active \n",fid);
143 +      sprintf(errbuf,"HE5_EHreadmeta: File ID %"PRId64" not active \n",fid);
144        H5Epush(__FILE__, "HE5_EHreadmeta", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf); 
145        HE5_EHprint(errbuf, __FILE__, __LINE__); 
146      }
147 --- hdfeos5/src/GDapi.c.orig    2017-11-13 17:02:42.000000000 +0100
148 +++ hdfeos5/src/GDapi.c 2019-12-10 05:32:50.266596870 +0100
149 @@ -7847,6 +7847,10 @@
150  
151  
152  
153 +herr_t
154 +HE5_GDsetdimscale2(hid_t gridID, char *fieldname, char *dimname,
155 +                  char *dimscalename, const hsize_t dimsize, 
156 +                  hid_t numbertype_in, void * data);
157  
158  
159  /*----------------------------------------------------------------------------|
160 @@ -17274,7 +17278,7 @@
161    if (regionID < 0 || regionID >= HE5_NGRIDREGN)
162      {
163        status = FAIL;
164 -      sprintf(errbuf, "Invalid Region ID: %d.\n", regionID);
165 +      sprintf(errbuf, "Invalid Region ID: %"PRId64".\n", regionID);
166        H5Epush(__FILE__, "HE5_GDregioninfo", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
167        HE5_EHprint(errbuf, __FILE__, __LINE__);
168        free(errbuf);
169 @@ -17289,7 +17293,7 @@
170    if (HE5_GDXRegion[regionID] == 0)
171      {
172        status = FAIL;
173 -      sprintf(errbuf, "Inactive Region ID: %d.\n", regionID);
174 +      sprintf(errbuf, "Inactive Region ID: %"PRId64".\n", regionID);
175        H5Epush(__FILE__, "HE5_GDregioninfo", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
176        HE5_EHprint(errbuf, __FILE__, __LINE__);
177        free(errbuf);
178 @@ -17792,7 +17796,7 @@
179    if (regionID < 0 || regionID >= HE5_NGRIDREGN)
180      {
181        status = FAIL;
182 -      sprintf(errbuf, "Invalid Region id: %d.\n", regionID);
183 +      sprintf(errbuf, "Invalid Region id: %"PRId64".\n", regionID);
184        H5Epush(__FILE__, "HE5_GDextractregion", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
185        HE5_EHprint(errbuf, __FILE__, __LINE__);
186        free(errbuf);
187 @@ -17806,7 +17810,7 @@
188    if (HE5_GDXRegion[regionID] == 0)
189      {
190        status = FAIL;
191 -      sprintf(errbuf, "Inactive Region ID: %d.\n", regionID);
192 +      sprintf(errbuf, "Inactive Region ID: %"PRId64".\n", regionID);
193        H5Epush(__FILE__,  "HE5_GDextractregion", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
194        HE5_EHprint(errbuf, __FILE__, __LINE__);
195        free(errbuf);
196 --- hdfeos5/src/PTapi.c.orig    2017-11-13 17:02:43.000000000 +0100
197 +++ hdfeos5/src/PTapi.c 2019-12-10 16:35:37.164494445 +0100
198 @@ -821,7 +821,7 @@
199               status = HE5_PTgetlevelname_fromSM(pointID, i, LevelName);
200               if ( status == FAIL )
201                 {
202 -                 sprintf(errbuf, "Failed to get LevelName for the Level_%d.",i) ;
203 +                 sprintf(errbuf, "Failed to get LevelName for the Level_%"PRId64".",i) ;
204                   H5Epush(__FILE__, "HE5_PTattach", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
205                   HE5_EHprint(errbuf, __FILE__, __LINE__);
206                           
207 @@ -1188,7 +1188,7 @@
208    nlevels = HE5_PTnlevels(pointID);
209    if (nlevels == 0)
210      {
211 -      sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
212 +      sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
213        H5Epush(__FILE__, "HE5_PTnrecs", __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
214        HE5_EHprint(errbuf, __FILE__, __LINE__);
215        return(0);
216 @@ -1197,7 +1197,7 @@
217      {
218        /* Report error if level # to large */
219        /* -------------------------------- */
220 -      sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
221 +      sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
222        H5Epush(__FILE__, "HE5_PTnrecs", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
223        HE5_EHprint(errbuf, __FILE__, __LINE__);
224        return(0);
225 @@ -1655,7 +1655,7 @@
226    if (nlevels == 0)
227      {
228        status = FAIL;
229 -      sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
230 +      sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
231        H5Epush(__FILE__, "HE5_PTnfields", __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
232        HE5_EHprint(errbuf, __FILE__, __LINE__);
233        return(status);
234 @@ -1665,7 +1665,7 @@
235        /* Report error if level # too large */
236        /* --------------------------------- */
237        status = FAIL;
238 -      sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
239 +      sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
240        H5Epush(__FILE__, "HE5_PTnfields", __LINE__, H5E_ARGS, H5E_BADRANGE, errbuf);
241        HE5_EHprint(errbuf, __FILE__, __LINE__);
242        return(status);
243 @@ -1844,7 +1844,7 @@
244        if (nlevels == 0)
245         {
246           status = FAIL;
247 -         sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
248 +         sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
249           H5Epush(__FILE__, "HE5_PTgetlevelname", __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
250           HE5_EHprint(errbuf, __FILE__, __LINE__);
251              
252 @@ -1854,7 +1854,7 @@
253           /* Report error if level # to large */
254           /* -------------------------------- */
255           status = FAIL;
256 -         sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
257 +         sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
258           H5Epush(__FILE__, "HE5_PTgetlevelname", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
259           HE5_EHprint(errbuf, __FILE__, __LINE__);
260         }
261 @@ -3049,7 +3049,7 @@
262    if (nlevels == 0)
263      {
264        status = FAIL;
265 -      sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
266 +      sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
267        H5Epush(__FILE__, "HE5_PTwritelevel",   __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
268        HE5_EHprint(errbuf, __FILE__, __LINE__);
269        return(status);
270 @@ -3059,7 +3059,7 @@
271        /* Report error if level # to large */
272        /* -------------------------------- */
273        status = FAIL;
274 -      sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
275 +      sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
276        H5Epush(__FILE__, "HE5_PTwritelevel", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
277        HE5_EHprint(errbuf, __FILE__, __LINE__);
278        return(status);
279 @@ -3488,7 +3488,7 @@
280    nlevels = HE5_PTnlevels(pointID);
281    if (nlevels == 0)
282      {
283 -      sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
284 +      sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
285        H5Epush(__FILE__, "HE5_PTlevelinfo", __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
286        HE5_EHprint(errbuf, __FILE__, __LINE__);
287        return(FAIL);
288 @@ -3497,7 +3497,7 @@
289      {
290        /* Report error if level # to large */
291        /* -------------------------------- */
292 -      sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
293 +      sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
294        H5Epush(__FILE__, "HE5_PTlevelinfo", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
295        HE5_EHprint(errbuf, __FILE__, __LINE__);
296        return(FAIL);
297 @@ -3915,7 +3915,7 @@
298    if (nlevels == 0)
299      {
300        status = FAIL;
301 -      sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
302 +      sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
303        H5Epush(__FILE__, "HE5_PTreadlevel", __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
304        HE5_EHprint(errbuf, __FILE__, __LINE__);
305        return(status);
306 @@ -3925,7 +3925,7 @@
307        /* Report error if level # to large */
308        /* -------------------------------- */
309        status = FAIL;
310 -      sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
311 +      sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
312        H5Epush(__FILE__, "HE5_PTreadlevel", __LINE__, H5E_FILE, H5E_SEEKERROR, errbuf);
313        HE5_EHprint(errbuf, __FILE__, __LINE__);
314        return(status);
315 @@ -9099,7 +9099,7 @@
316    if (nlevels == 0)
317      {
318        status = FAIL;
319 -      sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
320 +      sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
321        H5Epush(__FILE__, "HE5_PTreadlevel_f", __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
322        HE5_EHprint(errbuf, __FILE__, __LINE__);
323        return(status);
324 @@ -9109,7 +9109,7 @@
325        /* Report error if level # to large */
326        /* -------------------------------- */
327        status = FAIL;
328 -      sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
329 +      sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
330        H5Epush(__FILE__, "HE5_PTreadlevel_f", __LINE__, H5E_FILE, H5E_SEEKERROR, errbuf);
331        HE5_EHprint(errbuf, __FILE__, __LINE__);
332        return(status);
333 @@ -9513,7 +9513,7 @@
334    if (nlevels == 0)
335      {
336        status = FAIL;
337 -      sprintf(errbuf, "No Levels Defined for point ID: %d\n", pointID);
338 +      sprintf(errbuf, "No Levels Defined for point ID: %"PRId64"\n", pointID);
339        H5Epush(__FILE__, "HE5_PTwritelevel_f", __LINE__, H5E_BTREE, H5E_NOTFOUND, errbuf);
340        HE5_EHprint(errbuf, __FILE__, __LINE__);
341        return(status);
342 @@ -9523,7 +9523,7 @@
343        /* Report error if level # to large */
344        /* -------------------------------- */
345        status = FAIL;
346 -      sprintf(errbuf, "Only %d levels Defined for point ID: %d\n", nlevels, pointID);
347 +      sprintf(errbuf, "Only %d levels Defined for point ID: %"PRId64"\n", nlevels, pointID);
348        H5Epush(__FILE__, "HE5_PTwritelevel_f", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
349        HE5_EHprint(errbuf, __FILE__, __LINE__);
350        return(status);
351 --- hdfeos5/src/SWapi.c.orig    2019-12-10 16:45:34.831256606 +0100
352 +++ hdfeos5/src/SWapi.c 2019-12-10 16:45:38.444570365 +0100
353 @@ -2020,6 +2020,9 @@
354    return(status);
355  }
356  
357 +herr_t
358 +HE5_SWsetdimscale2(hid_t swathID, char *fieldname, char *dimname, char *dimscalename,
359 +                 const hsize_t dimsize, hid_t numbertype_in, void * data);
360  
361  /*----------------------------------------------------------------------------|
362  |  BEGIN_PROLOG                                                               |
363 @@ -13361,7 +13364,7 @@
364  
365                       if ((HE5_SWXRegion[k]->nRegions) > HE5_MAXNREGIONS)
366                         {
367 -                         sprintf(errbuf, "HE5_SWXRegion[%d]->nRegions exceeded HE5_MAXNREGIONS = %d.\n", k, HE5_MAXNREGIONS);
368 +                         sprintf(errbuf, "HE5_SWXRegion[%"PRId64"]->nRegions exceeded HE5_MAXNREGIONS = %d.\n", k, HE5_MAXNREGIONS);
369                           H5Epush(__FILE__, "HE5_SWdefboxregion", __LINE__, H5E_ARGS, H5E_BADRANGE, errbuf);
370                           HE5_EHprint(errbuf, __FILE__, __LINE__);
371                           if (lonArr != NULL) free(lonArr);
372 @@ -14685,7 +14688,7 @@
373        if (regionID < 0 || regionID >= HE5_NSWATHREGN)
374          {
375           status = FAIL;
376 -         sprintf(errbuf, "Invalid Region ID: %d.\n", regionID);
377 +         sprintf(errbuf, "Invalid Region ID: %"PRId64".\n", regionID);
378           H5Epush(__FILE__, "HE5_SWextractregion", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
379           HE5_EHprint(errbuf, __FILE__, __LINE__);
380          }
381 @@ -14698,7 +14701,7 @@
382        if (HE5_SWXRegion[regionID] == 0)
383          {
384           status = FAIL;
385 -         sprintf(errbuf, "Inactive Region ID: %d.\n", regionID);
386 +         sprintf(errbuf, "Inactive Region ID: %"PRId64".\n", regionID);
387           H5Epush(__FILE__, "HE5_SWextractregion", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
388           HE5_EHprint(errbuf, __FILE__, __LINE__);
389          }
390 @@ -16253,7 +16256,7 @@
391        if (regionID < 0 || regionID >= HE5_NSWATHREGN)
392          {
393           status = FAIL;
394 -         sprintf(errbuf, "Invalid Region id: %d.\n", regionID);
395 +         sprintf(errbuf, "Invalid Region id: %"PRId64".\n", regionID);
396           H5Epush(__FILE__, "HE5_SWregioninfo", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
397           HE5_EHprint(errbuf, __FILE__, __LINE__);
398          }
399 @@ -16266,7 +16269,7 @@
400        if (HE5_SWXRegion[regionID] == 0)
401          {
402           status = FAIL;
403 -         sprintf(errbuf,"Inactive Region ID: %d.\n", regionID);
404 +         sprintf(errbuf,"Inactive Region ID: %"PRId64".\n", regionID);
405           H5Epush(__FILE__, "HE5_SWregioninfo", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
406           HE5_EHprint(errbuf, __FILE__, __LINE__);
407          }
408 @@ -16733,7 +16736,7 @@
409        if (regionID < 0 || regionID >= HE5_NSWATHREGN)
410          {
411           status = FAIL;
412 -         sprintf(errbuf, "Invalid Region ID: %d.\n", regionID);
413 +         sprintf(errbuf, "Invalid Region ID: %"PRId64".\n", regionID);
414           H5Epush(__FILE__, "HE5_SWupdatescene", __LINE__, H5E_ARGS, H5E_BADRANGE, errbuf); 
415           HE5_EHprint(errbuf, __FILE__, __LINE__);
416          }
417 @@ -16746,7 +16749,7 @@
418        if (HE5_SWXRegion[regionID] == 0)
419          {
420           status = FAIL;
421 -         sprintf(errbuf, "Inactive Region ID: %d.\n", regionID);
422 +         sprintf(errbuf, "Inactive Region ID: %"PRId64".\n", regionID);
423           H5Epush(__FILE__, "HE5_SWupdatescene", __LINE__, H5E_ARGS, H5E_BADRANGE, errbuf);
424           HE5_EHprint(errbuf, __FILE__, __LINE__);
425          }
426 @@ -16775,7 +16778,7 @@
427                   free(HE5_SWXRegion[regionID]);
428                   HE5_SWXRegion[regionID] = 0;
429                   status = FAIL;
430 -                 sprintf(errbuf, "Inactive Region ID: %d.\n", regionID);
431 +                 sprintf(errbuf, "Inactive Region ID: %"PRId64".\n", regionID);
432                   H5Epush(__FILE__, "HE5_SWupdatescene", __LINE__, H5E_ARGS, H5E_BADRANGE, errbuf);
433                   HE5_EHprint(errbuf, __FILE__, __LINE__);
434                   break;
435 @@ -16894,7 +16897,7 @@
436        if (regionID < 0 || regionID >= HE5_NSWATHREGN)
437          {
438           status = FAIL;
439 -         sprintf(errbuf,"Invalid Region id: %d.\n", regionID);
440 +         sprintf(errbuf,"Invalid Region id: %"PRId64".\n", regionID);
441           H5Epush(__FILE__, "HE5_SWupdateidxmap", __LINE__, H5E_ARGS, H5E_BADRANGE, errbuf); 
442           HE5_EHprint(errbuf, __FILE__, __LINE__);
443          }
444 @@ -16907,7 +16910,7 @@
445        if (HE5_SWXRegion[regionID] == 0)
446          {
447           status = FAIL;
448 -         sprintf(errbuf, "Inactive Region ID: %d.\n", regionID);
449 +         sprintf(errbuf, "Inactive Region ID: %"PRId64".\n", regionID);
450           H5Epush(__FILE__, "HE5_SWupdateidxmap", __LINE__, H5E_FILE, H5E_BADRANGE, errbuf );
451           HE5_EHprint(errbuf, __FILE__, __LINE__);
452          }
453 @@ -23662,7 +23665,7 @@
454    if (regionID < 0 || regionID >= HE5_NSWATHREGN)
455      {
456        status = FAIL;
457 -      sprintf(errbuf, "Invalid Region ID: %d.\n", regionID);
458 +      sprintf(errbuf, "Invalid Region ID: %"PRId64".\n", regionID);
459        H5Epush(__FILE__, "HE5_SWindexinfo", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
460        HE5_EHprint(errbuf, __FILE__, __LINE__);
461        return(status);
462 @@ -23673,7 +23676,7 @@
463    if (HE5_SWXRegion[regionID] == 0)
464      {
465        status = FAIL;
466 -      sprintf(errbuf, "Inactive Region ID: %d.\n", regionID);
467 +      sprintf(errbuf, "Inactive Region ID: %"PRId64".\n", regionID);
468        H5Epush(__FILE__, "HE5_SWindexinfo", __LINE__, H5E_ARGS, H5E_BADVALUE, errbuf);
469        HE5_EHprint(errbuf, __FILE__, __LINE__);
470        return(status);
471 --- hdfeos5/src/ZAapi.c.orig    2017-11-13 17:02:46.000000000 +0100
472 +++ hdfeos5/src/ZAapi.c 2019-12-10 16:46:27.564304260 +0100
473 @@ -1275,6 +1275,9 @@
474    return(status);
475  }
476  
477 +herr_t
478 +HE5_ZAsetdimscale2(hid_t zaID, char *fieldname, char *dimname, char *dimscalename,
479 +                 const hsize_t dimsize, hid_t numbertype_in, void * data);
480  
481  /*----------------------------------------------------------------------------|
482  |  BEGIN_PROLOG                                                               |
483 --- hdfeos5/samples/he5_gd_datainfo.c.orig      2001-07-11 00:11:08.000000000 +0200
484 +++ hdfeos5/samples/he5_gd_datainfo.c   2019-12-10 16:47:13.027391299 +0100
485 @@ -26,10 +26,10 @@
486    size_t       size       = 0;
487  
488    fid = HE5_GDopen(FILENAME, H5F_ACC_RDONLY);
489 -  printf("File ID returned by HE5_GDopen() :         %d \n", fid);
490 +  printf("File ID returned by HE5_GDopen() :         %"PRId64" \n", fid);
491      
492    GDid = HE5_GDattach(fid, OBJECT);
493 -  printf("Grid ID returned by HE5_GDattach() :       %d \n", GDid);
494 +  printf("Grid ID returned by HE5_GDattach() :       %"PRId64" \n", GDid);
495  
496    fieldgroup = HE5_HDFE_DATAGROUP;
497    status = HE5_GDinqdatatype(GDid, FIELDNAME, NULL, fieldgroup, &datatype, &classid, &order, &size);
498 --- hdfeos5/samples/he5_gd_defunlimfld.c.orig   2014-01-14 18:00:21.000000000 +0100
499 +++ hdfeos5/samples/he5_gd_defunlimfld.c        2019-12-10 16:48:23.313677192 +0100
500 @@ -49,7 +49,7 @@
501    if (gdfid != FAIL)
502      {
503           GDid1 = HE5_GDattach(gdfid, "UTMGrid");
504 -         printf("Grid ID returned by HE5_GDattach(,\"UTMGrid\"):      %d\n", GDid1);
505 +         printf("Grid ID returned by HE5_GDattach(,\"UTMGrid\"):      %"PRId64"\n", GDid1);
506         
507           /* Define appendable field "Vegetation"  */
508           tilerank    = 2;
509 @@ -67,7 +67,7 @@
510           printf("Status returned by HE5_GDdeffield(\"Vegetation\"):   %d\n", status);
511         
512           GDid2 = HE5_GDattach(gdfid, "PolarGrid");
513 -         printf("Grid ID returned by HE5_GDattach(\"PolarGrid\"):     %d\n", GDid2);
514 +         printf("Grid ID returned by HE5_GDattach(\"PolarGrid\"):     %"PRId64"\n", GDid2);
515  
516           status = HE5_GDdeffield(GDid2, "Temperature", "YDim,XDim", NULL, H5T_NATIVE_FLOAT, 0);
517           printf("Status returned by HE5_GDdeffield(\"Temperature\"):  %d\n", status);
518 --- hdfeos5/samples/he5_gd_setup.c.orig 2001-07-11 00:13:46.000000000 +0200
519 +++ hdfeos5/samples/he5_gd_setup.c      2019-12-10 16:49:04.463454265 +0100
520 @@ -64,7 +64,7 @@
521    ydim = 200;
522      
523    GDid   = HE5_GDcreate(gdfid, "UTMGrid", xdim, ydim, uplft, lowrgt);
524 -  printf("Grid ID returned by HE5_GDcreate :                    %d \n", GDid);
525 +  printf("Grid ID returned by HE5_GDcreate :                    %"PRId64" \n", GDid);
526  
527    status = HE5_GDdefproj(GDid, HE5_GCTP_UTM, zonecode, spherecode, projparm);
528    printf("status returned by HE5_GDdefproj(...\"HE5_GCTP_UTM\"...) :  %d \n", status);
529 @@ -108,7 +108,7 @@
530    ydim = 100;
531  
532    GDid2  = HE5_GDcreate(gdfid, "PolarGrid", xdim, ydim, NULL, NULL);
533 -  printf("Grid ID returned by HE5_GDcreate() :                  %d \n", GDid2);
534 +  printf("Grid ID returned by HE5_GDcreate() :                  %"PRId64" \n", GDid2);
535  
536    status = HE5_GDdefproj(GDid2, HE5_GCTP_PS, dummy, spherecode, projparm);
537    printf("status returned by HE5_GDdefproj(...\"HE5_GCTP_PS\"...) :   %d \n", status);
538 @@ -137,7 +137,7 @@
539    lowrgt[1] = HE5_EHconvAng(20., HE5_HDFE_DEG_DMS);
540      
541    GDid3  = HE5_GDcreate(gdfid, "GEOGrid", xdim, ydim, uplft, lowrgt);
542 -  printf("Grid ID returned by HE5_GDcreate() :                  %d \n", GDid3);
543 +  printf("Grid ID returned by HE5_GDcreate() :                  %"PRId64" \n", GDid3);
544  
545    status = HE5_GDdefproj(GDid3, HE5_GCTP_GEO, dummy, dummy, NULL);
546    printf("status returned by HE5_GDdefproj(...\"HE5_GCTP_GEO\"...) :  %d \n", status);
547 --- hdfeos5/samples/he5_gd_subset.c.orig        2003-02-12 20:30:50.000000000 +0100
548 +++ hdfeos5/samples/he5_gd_subset.c     2019-12-10 16:49:21.156697163 +0100
549 @@ -53,7 +53,7 @@
550                   cornerlon[1] = 90.;  cornerlat[1] = 0.;
551  
552                   regionID = HE5_GDdefboxregion(GDid, cornerlon, cornerlat);
553 -                 printf("Region ID returned by HE5_GDdefboxregion() :    %d \n", regionID);
554 +                 printf("Region ID returned by HE5_GDdefboxregion() :    %"PRId64" \n", regionID);
555  
556                   ntype = (hid_t *)calloc(1, sizeof(hid_t));    
557                   status = HE5_GDregioninfo(GDid, regionID, "Temperature", ntype,&rank, dims, &size, upleft, lowright);
558 --- hdfeos5/samples/he5_pt_datainfo.c.orig      2001-07-11 00:16:30.000000000 +0200
559 +++ hdfeos5/samples/he5_pt_datainfo.c   2019-12-10 16:49:46.643225757 +0100
560 @@ -26,10 +26,10 @@
561    size_t       size     = 0;
562  
563    fid = HE5_PTopen(FILENAME, H5F_ACC_RDONLY);
564 -  printf("File ID returned by HE5_PTopen() :        %d \n", fid);
565 +  printf("File ID returned by HE5_PTopen() :        %"PRId64" \n", fid);
566      
567    PTid = HE5_PTattach(fid, OBJECT);
568 -  printf("Point ID returned by HE5_PTattach() :     %d \n", PTid);
569 +  printf("Point ID returned by HE5_PTattach() :     %"PRId64" \n", PTid);
570  
571    fieldgroup = HE5_HDFE_DATAGROUP;
572    status = HE5_PTinqdatatype(PTid, "Observations", NULL, fieldgroup, &datatype, &classid, &order, &size);
573 --- hdfeos5/samples/he5_pt_definelevels.c.orig  2001-07-11 00:16:43.000000000 +0200
574 +++ hdfeos5/samples/he5_pt_definelevels.c       2019-12-10 16:50:03.936465405 +0100
575 @@ -378,7 +378,7 @@
576         }
577    else 
578      {
579 -         printf("File ID returned by HE5_PTopen() : %d \n", ptfid);
580 +         printf("File ID returned by HE5_PTopen() : %"PRId64" \n", ptfid);
581      }
582    
583    return 0;
584 --- hdfeos5/samples/he5_pt_readattrs.c.orig     2003-03-06 20:47:27.000000000 +0100
585 +++ hdfeos5/samples/he5_pt_readattrs.c  2019-12-10 16:50:59.759496319 +0100
586 @@ -29,10 +29,10 @@
587    /* Open the HDF-EOS file, "Point.h5" */
588    /* --------------------------------- */
589    ptfid = HE5_PTopen("Point.h5", H5F_ACC_RDONLY);
590 -  printf("File ID returned by HE5_PTopen() :       %d \n", ptfid);
591 +  printf("File ID returned by HE5_PTopen() :       %"PRId64" \n", ptfid);
592  
593    PTid = HE5_PTattach(ptfid, "FixedBuoy Point");
594 -  printf("Point ID returned by HE5_PTattach() :    %d \n", PTid);
595 +  printf("Point ID returned by HE5_PTattach() :    %"PRId64" \n", PTid);
596  
597    nt = (hid_t *)calloc(1, sizeof(hid_t));
598  
599 --- hdfeos5/samples/he5_pt_readdata.c.orig      2001-07-11 00:17:10.000000000 +0200
600 +++ hdfeos5/samples/he5_pt_readdata.c   2019-12-10 16:51:49.905891319 +0100
601 @@ -46,12 +46,12 @@
602    /* Open the HDF-EOS file, "Point.h5" */
603    /* --------------------------------- */
604    ptfid = HE5_PTopen("Point.h5", H5F_ACC_RDONLY);
605 -  printf("File ID returned by HE5_PTopen() :           %d \n", ptfid);
606 +  printf("File ID returned by HE5_PTopen() :           %"PRId64" \n", ptfid);
607  
608    /* Read Simple Point */
609    /* ----------------- */
610    PTid = HE5_PTattach(ptfid, "Simple Point");
611 -  printf("Point ID returned by HE5_PTattach() :        %d \n", PTid);
612 +  printf("Point ID returned by HE5_PTattach() :        %"PRId64" \n", PTid);
613  
614    /* Get level information */
615    /* --------------------- */
616 @@ -64,7 +64,7 @@
617         {
618           printf("Field name:                  %s \n", level.fieldname[i]);
619           printf("Field rank:                  %d \n", level.rank[i]);
620 -         printf("Field type ID:               %d \n", level.dtype[i]);
621 +         printf("Field type ID:               %"PRId64" \n", level.dtype[i]);
622           for (j = 0; j < level.rank[i]; j++)
623                 printf("Field dims:                  %d \n", (int)level.dims[i][j]);
624           printf("Field class:                 %d \n", level.dclass[i]);
625 @@ -170,7 +170,7 @@
626    printf("Status returned by HE5_PTdetach() :          %d \n", status);
627      
628    PTid = HE5_PTattach(ptfid, "FixedBuoy Point");
629 -  printf("Point ID returned by HE5_PTattach() :        %d \n", PTid);
630 +  printf("Point ID returned by HE5_PTattach() :        %"PRId64" \n", PTid);
631  
632    /* Read Fixed Buoy Point Attributes */
633    /* -------------------------------- */
634 --- hdfeos5/samples/he5_pt_writeattrs.c.orig    2001-07-11 00:17:49.000000000 +0200
635 +++ hdfeos5/samples/he5_pt_writeattrs.c 2019-12-10 16:52:30.835669584 +0100
636 @@ -27,12 +27,12 @@
637    /* Open the HDF-EOS file, "Point.h5" */
638    /* --------------------------------- */
639    ptfid = HE5_PTopen("Point.h5", H5F_ACC_RDWR);
640 -  printf("File ID returned by HE5_PTopen() :         %d \n", ptfid);
641 +  printf("File ID returned by HE5_PTopen() :         %"PRId64" \n", ptfid);
642  
643    /* Write attribute to "Fixed Buoy Point" */
644    /* ------------------------------------- */
645    PTid = HE5_PTattach(ptfid, "FixedBuoy Point");
646 -  printf("Point ID returned by HE5_PTattach() :      %d \n", PTid);
647 +  printf("Point ID returned by HE5_PTattach() :      %"PRId64" \n", PTid);
648  
649    count[0] = 1;
650    status = HE5_PTwriteattr(PTid, "GlobalAttribute_int", H5T_NATIVE_INT, count, &attr);
651 @@ -51,7 +51,7 @@
652    /* Write attributes to "Floating Buoy Point" */
653    /* ----------------------------------------- */
654    PTid = HE5_PTattach(ptfid, "FloatBuoy Point");
655 -  printf("Point ID returned by HE5_PTattach() :      %d \n", PTid);
656 +  printf("Point ID returned by HE5_PTattach() :      %"PRId64" \n", PTid);
657  
658    count[0] = 1;    
659    status = HE5_PTwriteattr(PTid, "GlobalAttribute_float", H5T_NATIVE_FLOAT, count, &flt);
660 --- hdfeos5/samples/he5_sw_datainfo.c.orig      2003-12-01 20:24:51.000000000 +0100
661 +++ hdfeos5/samples/he5_sw_datainfo.c   2019-12-10 16:57:35.334019975 +0100
662 @@ -31,12 +31,12 @@
663    /* Open the HDF-EOS swath file */
664    /* --------------------------- */
665    fid = HE5_SWopen(FILENAME, H5F_ACC_RDONLY);
666 -  printf("File ID returned by HE5_SWopen() :         %d \n", fid);
667 +  printf("File ID returned by HE5_SWopen() :         %"PRId64" \n", fid);
668      
669    /* Attach to the "Swath1" swath */
670    /* ---------------------------- */
671    SWid = HE5_SWattach(fid, OBJECT);
672 -  printf("Swath ID returned by HE5_SWattach() :      %d \n", SWid);
673 +  printf("Swath ID returned by HE5_SWattach() :      %"PRId64" \n", SWid);
674  
675    /* Inquire data type information for the "Spectra" field */
676    /* ----------------------------------------------------- */
677 @@ -45,7 +45,7 @@
678    printf("Status returned by HE5_SWinqdatatype() :   %d \n", status);
679    if (status != FAIL)
680         {
681 -         printf("\tdatatype:    %d \n", datatype);
682 +         printf("\tdatatype:    %"PRId64" \n", datatype);
683           printf("\tclass ID:    %d \n", classid);
684           printf("\torder:       %d \n", order);
685           printf("\tsize:        %d \n", (int)size);        
686 @@ -58,7 +58,7 @@
687    printf("Status returned by HE5_SWinqdatatype() :   %d \n", status);
688    if (status != FAIL)
689         {
690 -         printf("\tdatatype:    %d \n", datatype);
691 +         printf("\tdatatype:    %"PRId64" \n", datatype);
692           printf("\tclass ID:    %d \n", classid);
693           printf("\torder:       %d \n", order);
694           printf("\tsize:        %d \n", (int)size);        
695 @@ -70,7 +70,7 @@
696    printf("Status returned by HE5_EHinqglbdatatype() :  %d \n", status);
697    if (status != FAIL)
698          {
699 -          printf("\tdatatype:    %d \n", datatype);
700 +          printf("\tdatatype:    %"PRId64" \n", datatype);
701            printf("\tclass ID:    %d \n", classid);
702            printf("\torder:       %d \n", order);
703            printf("\tsize:        %d \n", (int)size);
704 @@ -80,7 +80,7 @@
705    printf("Status returned by HE5_EHinqglbdatatype()->GLOBAL_DOUBLE_ATTR_1  :  %d \n", status);
706    if (status != FAIL)
707          {
708 -          printf("\tdatatype:    %d \n", datatype);
709 +          printf("\tdatatype:    %"PRId64" \n", datatype);
710            printf("\tclass ID:    %d \n", classid);
711            printf("\torder:       %d \n", order);
712            printf("\tsize:        %d \n", (int)size);
713 @@ -92,7 +92,7 @@
714    printf("Status returned by HE5_SWinqdatatype() :   %d \n", status);
715    if (status != FAIL)
716         {
717 -         printf("\tdatatype:    %d \n", datatype);
718 +         printf("\tdatatype:    %"PRId64" \n", datatype);
719           printf("\tclass ID:    %d \n", classid);
720           printf("\torder:       %d \n", order);
721           printf("\tsize:        %d \n", (int)size);        
722 @@ -102,7 +102,7 @@
723    printf("Status returned by HE5_SWinqdatatype()->GLOBAL_CHAR_ATTR_11 :   %d \n", status);
724    if (status != FAIL)
725          {
726 -          printf("\tdatatype:    %d \n", datatype);
727 +          printf("\tdatatype:    %"PRId64" \n", datatype);
728            printf("\tclass ID:    %d \n", classid);
729            printf("\torder:       %d \n", order);
730            printf("\tsize:        %d \n", (int)size);
731 @@ -112,7 +112,7 @@
732    printf("Status returned by HE5_SWinqdatatype()->GLOBAL_CHAR_ATTR :   %d \n", status);
733    if (status != FAIL)
734          {
735 -          printf("\tdatatype:    %d \n", datatype);
736 +          printf("\tdatatype:    %"PRId64" \n", datatype);
737            printf("\tclass ID:    %d \n", classid);
738            printf("\torder:       %d \n", order);
739            printf("\tsize:        %d \n", (int)size);
740 @@ -123,7 +123,7 @@
741    printf("Status returned by HE5_SWinqdatatype() :   %d \n", status);
742    if (status != FAIL)
743         {
744 -         printf("\tdatatype:    %d \n", datatype);
745 +         printf("\tdatatype:    %"PRId64" \n", datatype);
746           printf("\tclass ID:    %d \n", classid);
747           printf("\torder:       %d \n", order);
748           printf("\tsize:        %d \n", (int)size);        
749 @@ -134,7 +134,7 @@
750    printf("Status returned by HE5_SWinqdatatype() :   %d \n", status);
751    if (status != FAIL)
752         {
753 -         printf("\tdatatype:    %d \n", datatype);
754 +         printf("\tdatatype:    %"PRId64" \n", datatype);
755           printf("\tclass ID:    %d \n", classid);
756           printf("\torder:       %d \n", order);
757           printf("\tsize:        %d \n", (int)size);        
758 @@ -145,7 +145,7 @@
759    printf("Status returned by HE5_SWinqdatatype() :   %d \n", status);
760    if (status != FAIL)
761         {
762 -         printf("\tdatatype:    %d \n", datatype);
763 +         printf("\tdatatype:    %"PRId64" \n", datatype);
764           printf("\tclass ID:    %d \n", classid);
765           printf("\torder:       %d \n", order);
766           printf("\tsize:        %d \n", (int)size);        
767 --- hdfeos5/samples/he5_sw_info.c.orig  2004-01-20 20:17:54.000000000 +0100
768 +++ hdfeos5/samples/he5_sw_info.c       2019-12-10 17:01:28.582756358 +0100
769 @@ -110,7 +110,7 @@
770  
771                   printf("geo fields: %s\n", fieldlist);
772                   for (i = 0; i < nflds; i++)
773 -                       printf("Rank:  %d   Data type:  %d\n", rank[i], ntype[i]);
774 +                       printf("Rank:  %d   Data type:  %"PRId64"\n", rank[i], ntype[i]);
775  
776                   free(rank);
777                   free(fieldlist);
778 @@ -124,7 +124,7 @@
779  
780                   printf("data fields: %s\n", fieldlist);
781                   for (i = 0; i < nflds; i++)
782 -                       printf("Rank:  %d   Data type:  %d\n", rank[i], ntype[i]);
783 +                       printf("Rank:  %d   Data type:  %"PRId64"\n", rank[i], ntype[i]);
784  
785                   free(rank);
786                   free(fieldlist);
787 @@ -158,14 +158,14 @@
788                   /* ----------------------------- */
789                   status = HE5_SWfieldinfo(SWid, "Longitude", &rk, dim, &dtype, dimlist, NULL);
790                   printf("Longitude Rank: %d\n", rk);
791 -                 printf("Longitude NumberType: %d\n", dtype);
792 +                 printf("Longitude NumberType: %"PRId64"\n", dtype);
793                   printf("Longitude Dimension List: %s\n", dimlist);        
794                   for (i = 0; i < rk; i++)
795                         printf("Dimension %d: %lu\n",i+1,(unsigned long)dim[i]);
796  
797                    status = HE5_SWfieldinfo(SWid, "Test_string", &rk1, dim1, &dtype_char, dimlist1, NULL);
798                    printf("Test_string Rank: %d\n", rk1);
799 -                  printf("Test_string NumberType: %d\n", dtype_char);
800 +                  printf("Test_string NumberType: %"PRId64"\n", dtype_char);
801                    printf("Test_string Dimension List: %s\n", dimlist1);
802                    for (i = 0; i < rk1; i++)
803                          printf("Dimension %d: %lu\n",i+1,(unsigned long)dim1[i]);
804 @@ -175,17 +175,17 @@
805                   /* -------------------------------- */
806                   printf("Global Attribute:\n");
807                   status = HE5_SWattrinfo(SWid,"GlobalAttribute",&dtype1, &nelem);
808 -                 printf("\t\t Data type:          %d\n", dtype1);
809 +                 printf("\t\t Data type:          %"PRId64"\n", dtype1);
810                   printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);    
811   
812                    nelem = 0;
813                    status = HE5_SWattrinfo(SWid,"GLOBAL_CHAR_ATTR",&dtype1, &nelem);
814 -                  printf("\t\t Data type:          %d\n", dtype1);
815 +                  printf("\t\t Data type:          %"PRId64"\n", dtype1);
816                    printf("\t\t The size of string: %lu \n", (unsigned long)nelem);
817  
818                    nelem = 0;
819                    status = HE5_SWattrinfo(SWid,"GLOBAL_DOUBLE_ATTR",&dtype1, &nelem);
820 -                  printf("\t\t Data type:          %d\n", dtype1);
821 +                  printf("\t\t Data type:          %"PRId64"\n", dtype1);
822                    printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);
823  
824                   nelem = 0;
825 @@ -194,7 +194,7 @@
826                   /* ------------------------------- */
827                   printf("Group Attribute:\n");
828                   status = HE5_SWgrpattrinfo(SWid,"GroupAttribute",&dtype1,&nelem);
829 -                 printf("\t\t Data type:          %d\n", dtype1);
830 +                 printf("\t\t Data type:          %"PRId64"\n", dtype1);
831                   printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);    
832  
833                   nelem = 777;
834 @@ -203,17 +203,17 @@
835                   /* ------------------------------- */
836                   printf("Local Attribute:\n");
837                   status = HE5_SWlocattrinfo(SWid,"Density", "LocalAttribute_1",&dtype1,&nelem);
838 -                 printf("\t\t Data type:          %d\n", dtype1);
839 +                 printf("\t\t Data type:          %"PRId64"\n", dtype1);
840                   printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);    
841  
842                   printf("Local Attribute:\n");
843                   status = HE5_SWlocattrinfo(SWid,"Longitude", "LocalAttribute_2",&dtype1,&nelem);
844 -                 printf("\t\t Data type:          %d\n", dtype1);
845 +                 printf("\t\t Data type:          %"PRId64"\n", dtype1);
846                   printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);    
847  
848                    nelem = 0;
849                    status = HE5_SWlocattrinfo(SWid,"Time", "LOCAL_CHAR_ATTR",&dtype1,&nelem);
850 -                  printf("\t\t Data type:          %d\n", dtype1);
851 +                  printf("\t\t Data type:          %"PRId64"\n", dtype1);
852                    printf("\t\t The size of string: %lu \n", (unsigned long)nelem);
853  
854                   /* Inquire Global Attributes */
855 --- hdfeos5/samples/he5_sw_setup.c.orig 2003-02-12 20:32:10.000000000 +0100
856 +++ hdfeos5/samples/he5_sw_setup.c      2019-12-10 17:51:25.706519547 +0100
857 @@ -27,12 +27,12 @@
858    /* Open a new HDF-EOS swath file, "Swath.h5" */
859    /* ----------------------------------------- */
860    swfid = HE5_SWopen("Swath.h5", H5F_ACC_TRUNC);
861 -  printf("File ID returned by HE5_SWopen():       %d \n", swfid);
862 +  printf("File ID returned by HE5_SWopen():       %"PRId64" \n", swfid);
863  
864    /* Create the swath, "Swath1", within the file */
865    /* ------------------------------------------- */
866    SWid = HE5_SWcreate(swfid, "Swath1");
867 -  printf("Swath ID returned by HE5_SWcreate():    %d \n", SWid);
868 +  printf("Swath ID returned by HE5_SWcreate():    %"PRId64" \n", SWid);
869  
870    /* Define dimensions and specify their sizes */
871    /* ----------------------------------------- */
872 --- hdfeos5/samples/he5_sw_subset.c.orig        2003-02-12 20:32:29.000000000 +0100
873 +++ hdfeos5/samples/he5_sw_subset.c     2019-12-10 17:51:57.159682484 +0100
874 @@ -49,7 +49,7 @@
875  
876                   regionID = HE5_SWdefboxregion(SWid, cornerlon, cornerlat, HE5_HDFE_MIDPOINT);
877                   printf("\n");
878 -                 printf("Region ID returned by HE5_SWdefboxregion()  :          %d \n", regionID);
879 +                 printf("Region ID returned by HE5_SWdefboxregion()  :          %"PRId64" \n", regionID);
880             
881                   ntype = (hid_t *)calloc(1, sizeof(hid_t) );
882  
883 @@ -78,7 +78,7 @@
884  
885                   periodID = HE5_SWdeftimeperiod(SWid, start_time, stop_time, HE5_HDFE_MIDPOINT);
886                   printf("\n");
887 -                 printf("Period ID returned by HE5_SWdeftimeperiod() :          %d \n",  periodID);
888 +                 printf("Period ID returned by HE5_SWdeftimeperiod() :          %"PRId64" \n",  periodID);
889             
890                   status = HE5_SWperiodinfo(SWid, periodID, "Time", ntype, &rank, dims, &size);
891                   printf("Status returned by HE5_SWperiodinfo() :                %d \n",  status);
892 --- hdfeos5/samples/he5_za_datainfo.c.orig      2003-06-03 20:09:03.000000000 +0200
893 +++ hdfeos5/samples/he5_za_datainfo.c   2019-12-10 17:57:51.877760812 +0100
894 @@ -31,12 +31,12 @@
895    /* Open the HDF-EOS ZA file */
896    /* ------------------------ */
897    fid = HE5_ZAopen(FILENAME, H5F_ACC_RDONLY);
898 -  printf("File ID returned by HE5_ZAopen() :         %d \n", fid);
899 +  printf("File ID returned by HE5_ZAopen() :         %"PRId64" \n", fid);
900      
901    /* Attach to the "ZA1" za */
902    /* ---------------------- */
903    ZAid = HE5_ZAattach(fid, OBJECT);
904 -  printf("ZA ID returned by HE5_ZAattach() :      %d \n", ZAid);
905 +  printf("ZA ID returned by HE5_ZAattach() :      %"PRId64" \n", ZAid);
906  
907    /* Inquire data type information for the "Spectra" field */
908    /* ----------------------------------------------------- */
909 @@ -45,7 +45,7 @@
910    printf("Status returned by HE5_ZAinqdatatype() :   %d \n", status);
911    if (status != FAIL)
912         {
913 -         printf("\tdatatype:    %d \n", datatype);
914 +         printf("\tdatatype:    %"PRId64" \n", datatype);
915           printf("\tclass ID:    %d \n", classid);
916           printf("\torder:       %d \n", order);
917           printf("\tsize:        %d \n", (int)size);        
918 @@ -58,7 +58,7 @@
919    printf("Status returned by HE5_ZAinqdatatype() :   %d \n", status);
920    if (status != FAIL)
921         {
922 -         printf("\tdatatype:    %d \n", datatype);
923 +         printf("\tdatatype:    %"PRId64" \n", datatype);
924           printf("\tclass ID:    %d \n", classid);
925           printf("\torder:       %d \n", order);
926           printf("\tsize:        %d \n", (int)size);        
927 @@ -69,7 +69,7 @@
928    printf("Status returned by HE5_ZAinqdatatype() :   %d \n", status);
929    if (status != FAIL)
930         {
931 -         printf("\tdatatype:    %d \n", datatype);
932 +         printf("\tdatatype:    %"PRId64" \n", datatype);
933           printf("\tclass ID:    %d \n", classid);
934           printf("\torder:       %d \n", order);
935           printf("\tsize:        %d \n", (int)size);        
936 @@ -80,7 +80,7 @@
937    printf("Status returned by HE5_ZAinqdatatype() :   %d \n", status);
938    if (status != FAIL)
939         {
940 -         printf("\tdatatype:    %d \n", datatype);
941 +         printf("\tdatatype:    %"PRId64" \n", datatype);
942           printf("\tclass ID:    %d \n", classid);
943           printf("\torder:       %d \n", order);
944           printf("\tsize:        %d \n", (int)size);        
945 --- hdfeos5/samples/he5_za_info.c.orig  2004-01-20 20:18:40.000000000 +0100
946 +++ hdfeos5/samples/he5_za_info.c       2019-12-10 17:58:44.894140264 +0100
947 @@ -72,7 +72,7 @@
948  
949                   printf("data fields: %s\n", fieldlist);
950                   for (i = 0; i < nflds; i++)
951 -                       printf("Rank:  %d   Data type:  %d\n", rank[i], ntype[i]);
952 +                       printf("Rank:  %d   Data type:  %"PRId64"\n", rank[i], ntype[i]);
953  
954                   free(rank);
955                   free(fieldlist);
956 @@ -89,7 +89,7 @@
957                   /* -------------------------------- */
958                   printf("Global Attribute:\n");
959                   status = HE5_ZAattrinfo(ZAid,"GlobalAttribute",&dtype, &nelem);
960 -                 printf("\t\t Data type:          %d\n", dtype);
961 +                 printf("\t\t Data type:          %"PRId64"\n", dtype);
962                   printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);    
963  
964                   nelem = 0;
965 @@ -98,7 +98,7 @@
966                   /* ------------------------------- */
967                   printf("Group Attribute:\n");
968                   status = HE5_ZAgrpattrinfo(ZAid,"GroupAttribute",&dtype,&nelem);
969 -                 printf("\t\t Data type:          %d\n", dtype);
970 +                 printf("\t\t Data type:          %"PRId64"\n", dtype);
971                   printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);    
972  
973                   nelem = 777;
974 @@ -107,7 +107,7 @@
975                   /* ------------------------------- */
976                   printf("Local Attribute:\n");
977                   status = HE5_ZAlocattrinfo(ZAid,"Density", "LocalAttribute",&dtype,&nelem);
978 -                 printf("\t\t Data type:          %d\n", dtype);
979 +                 printf("\t\t Data type:          %"PRId64"\n", dtype);
980                   printf("\t\t Number of elements: %lu \n", (unsigned long)nelem);    
981  
982  
983 --- hdfeos5/samples/he5_za_setup.c.orig 2003-06-03 20:10:23.000000000 +0200
984 +++ hdfeos5/samples/he5_za_setup.c      2019-12-10 17:59:06.717355371 +0100
985 @@ -24,12 +24,12 @@
986    /* Open a new HDF-EOS za file, "ZA.he5" */
987    /* ----------------------------------- */
988    zafid = HE5_ZAopen("ZA.he5", H5F_ACC_TRUNC);
989 -  printf("File ID returned by HE5_ZAopen():       %d \n", zafid);
990 +  printf("File ID returned by HE5_ZAopen():       %"PRId64" \n", zafid);
991    
992    /* Create the ZA, "ZA1", within the file */
993    /* ------------------------------------- */
994    ZAid = HE5_ZAcreate(zafid, "ZA1");
995 -  printf("ZA ID returned by HE5_ZAcreate():    %d \n", ZAid);
996 +  printf("ZA ID returned by HE5_ZAcreate():    %"PRId64" \n", ZAid);
997  
998    /* Define dimensions and specify their sizes */
999    /* ----------------------------------------- */
1000 --- hdfeos5/include/HE5_HdfEosDef.h.orig        2017-03-27 20:15:22.000000000 +0200
1001 +++ hdfeos5/include/HE5_HdfEosDef.h     2019-12-11 16:02:29.100529098 +0100
1002 @@ -549,6 +549,10 @@
1003  hid_t                HE5_EHint2hid(int invalue);
1004  hid_t                HE5_EHlong2hid(long invalue);
1005  int                  HE5_EHlong2int(long invalue);
1006 +int                  HE5_EHllong2int(long long invalue);
1007 +long                 HE5_EHllong2long(long long invalue);
1008 +long long            HE5_EHint2llong(int invalue);
1009 +long long            HE5_EHlong2llong(long invalue);
1010  
1011  hsize_t              HE5_EHhid2hsize(hid_t invalue);
1012  hsize_t              HE5_EHint2hsize(int invalue);
1013 @@ -557,6 +561,8 @@
1014  long                 HE5_EHhsize2long(hsize_t invalue);
1015  int                  HE5_EHhsize2int(hsize_t invalue);
1016  hssize_t             HE5_EHhsize2hssize(hsize_t invalue);
1017 +long long            HE5_EHhsize2llong(hsize_t invalue);
1018 +hsize_t              HE5_EHllong2hsize(long long invalue);
1019  
1020  hssize_t             HE5_EHhid2hssize(hid_t invalue);
1021  hssize_t             HE5_EHint2hssize(int invalue);
1022 @@ -565,6 +571,8 @@
1023  long                 HE5_EHhssize2long(hssize_t invalue);
1024  int                  HE5_EHhssize2int(hssize_t invalue);
1025  hsize_t              HE5_EHhssize2hsize(hssize_t invalue);
1026 +long long            HE5_EHhssize2llong(hssize_t invalue);
1027 +hssize_t             HE5_EHllong2hssize(long long invalue);
1028  
1029  unsigned LONGLONG    HE5_EHint2ullong(int invalue);
1030  long                 HE5_EHullong2long(unsigned LONGLONG invalue);
1031 --- hdfeos5/src/EHapi.c.orig    2019-12-11 15:44:35.239680034 +0100
1032 +++ hdfeos5/src/EHapi.c 2019-12-11 16:00:43.981098579 +0100
1033 @@ -324,6 +324,8 @@
1034         outvalue = HE5_EHint2long(invalue);
1035    else if (sizeof(hid_t) == sizeof(long))
1036         outvalue = invalue;
1037 +  else if (sizeof(hid_t) == sizeof(long long))
1038 +       outvalue = HE5_EHllong2long(invalue);
1039    
1040    return(outvalue);
1041  }
1042 @@ -410,6 +410,8 @@
1043         outvalue = invalue;
1044    else if (sizeof(hid_t) == sizeof(long))
1045         outvalue = HE5_EHlong2int(invalue);
1046 +  else if (sizeof(hid_t) == sizeof(long long))
1047 +       outvalue = HE5_EHllong2int(invalue);
1048    
1049    return(outvalue);
1050  }
1051 @@ -447,6 +449,8 @@
1052         outvalue = invalue;
1053    else if (sizeof(hid_t) == sizeof(long))
1054         outvalue = HE5_EHint2long(invalue);
1055 +  else if (sizeof(hid_t) == sizeof(long long))
1056 +       outvalue = HE5_EHint2llong(invalue);
1057    
1058    return(outvalue);
1059  }
1060 @@ -485,6 +489,8 @@
1061         outvalue = HE5_EHlong2int(invalue);
1062    else if (sizeof(hid_t) == sizeof(long))
1063         outvalue = invalue;
1064 +  else if (sizeof(hid_t) == sizeof(long long))
1065 +       outvalue = HE5_EHlong2llong(invalue);
1066    
1067    return(outvalue);
1068  }
1069 @@ -542,6 +548,79 @@
1070    return(outvalue);
1071  }
1072  
1073 +int
1074 +HE5_EHllong2int(long long invalue)
1075 +{
1076 +  herr_t    status   = FAIL;
1077 +  long      outvalue = FAIL;
1078 +
1079 +  status = H5Tconvert(H5T_NATIVE_LLONG, H5T_NATIVE_INT, 1, &invalue, NULL, H5P_DEFAULT);
1080 +  if (status == FAIL)
1081 +       {
1082 +         H5Epush(__FILE__, "HE5_EHllong2int", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"long long\" to \"int\" data type.");
1083 +         return(status);
1084 +       }
1085 +
1086 +  memmove(&outvalue,&invalue,sizeof(int));
1087 +  return(outvalue);
1088 +}
1089 +
1090 +long
1091 +HE5_EHllong2long(long long invalue)
1092 +{
1093 +  herr_t    status   = FAIL;
1094 +  long      outvalue = FAIL;
1095 +
1096 +  status = H5Tconvert(H5T_NATIVE_LLONG, H5T_NATIVE_LONG, 1, &invalue, NULL, H5P_DEFAULT);
1097 +  if (status == FAIL)
1098 +       {
1099 +         H5Epush(__FILE__, "HE5_EHllong2long", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"long long\" to \"long\" data type.");
1100 +         return(status);
1101 +       }
1102 +
1103 +  memmove(&outvalue,&invalue,sizeof(long));
1104 +  return(outvalue);
1105 +}
1106 +
1107 +long long
1108 +HE5_EHint2llong(int invalue)
1109 +{
1110 +  herr_t    status   = FAIL;
1111 +  long long outvalue = FAIL;
1112 +  long long buf      = FAIL;
1113 +
1114 +  memmove(&buf,&invalue,sizeof(int));
1115 +
1116 +  status = H5Tconvert(H5T_NATIVE_INT, H5T_NATIVE_LLONG, 1, &buf, NULL, H5P_DEFAULT);
1117 +  if (status == FAIL)
1118 +       {
1119 +         H5Epush(__FILE__, "HE5_EHint2llong", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"int\" to \"long long\" data type.");
1120 +         return(status);
1121 +       }
1122 +
1123 +  memmove(&outvalue,&buf,sizeof(long long));
1124 +  return(outvalue);
1125 +}
1126 +
1127 +long long
1128 +HE5_EHlong2llong(long invalue)
1129 +{
1130 +  herr_t    status   = FAIL;
1131 +  long long outvalue = FAIL;
1132 +  long long buf      = FAIL;
1133 +
1134 +  memmove(&buf,&invalue,sizeof(long));
1135 +
1136 +  status = H5Tconvert(H5T_NATIVE_LONG, H5T_NATIVE_LLONG, 1, &buf, NULL, H5P_DEFAULT);
1137 +  if (status == FAIL)
1138 +       {
1139 +         H5Epush(__FILE__, "HE5_EHlong2llong", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"long\" to \"long long\" data type.");
1140 +         return(status);
1141 +       }
1142 +
1143 +  memmove(&outvalue,&buf,sizeof(long long));
1144 +  return(outvalue);
1145 +}
1146  
1147  /*----------------------------------------------------------------------------|
1148  |  BEGIN_PROLOG                                                               |
1149 @@ -576,6 +655,8 @@
1150         outvalue = HE5_EHint2hsize(invalue);
1151    else if (sizeof(hid_t) == sizeof(long) )
1152         outvalue = HE5_EHlong2hsize(invalue);
1153 +  else if (sizeof(hid_t) == sizeof(long long))
1154 +       outvalue = HE5_EHllong2hsize(invalue);
1155  
1156    return(outvalue);  
1157  }
1158 @@ -728,6 +809,8 @@
1159         outvalue = HE5_EHhsize2int(invalue);
1160    else if (sizeof(hid_t) == sizeof(long) )
1161         outvalue = HE5_EHhsize2long(invalue);
1162 +  else if (sizeof(hid_t) == sizeof(long long))
1163 +        outvalue = HE5_EHhsize2llong(invalue);
1164  
1165    return(outvalue);
1166  }
1167 @@ -843,6 +926,55 @@
1168    return(outvalue);
1169  }
1170  
1171 +hsize_t
1172 +HE5_EHllong2hsize(long long invalue)
1173 +{
1174 +
1175 +  herr_t   status       = FAIL;
1176 +  void     *buf         = NULL;
1177 +  hsize_t  outvalue     = 0;
1178 +  size_t   maxsize      = 0;
1179 +
1180 +  maxsize = MAX(H5Tget_size(H5T_NATIVE_LLONG),H5Tget_size(H5T_NATIVE_HSIZE));
1181 +  buf = calloc(1,maxsize);
1182 +  memmove(buf,&invalue,sizeof(long long));
1183 +
1184 +  status = H5Tconvert(H5T_NATIVE_LLONG, H5T_NATIVE_HSIZE, 1, buf, NULL, H5P_DEFAULT);
1185 +  if (status == FAIL)
1186 +       {
1187 +         H5Epush(__FILE__, "HE5_EHllong2hsize", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"long long\" to \"hsize_t\" data type.");
1188 +         return(status);
1189 +       }
1190 +
1191 +  memmove(&outvalue,buf,H5Tget_size(H5T_NATIVE_HSIZE));
1192 +  free(buf);
1193 +  return(outvalue);
1194 +}
1195 +
1196 +long long
1197 +HE5_EHhsize2llong(hsize_t invalue)
1198 +{
1199 +  herr_t   status       = FAIL;
1200 +  void     *buf         = NULL;
1201 +  long long outvalue    = FAIL;
1202 +  size_t   maxsize      = 0;
1203 +
1204 +  maxsize = MAX(H5Tget_size(H5T_NATIVE_LLONG),H5Tget_size(H5T_NATIVE_HSIZE));
1205 +  buf = calloc(1,maxsize);
1206 +  memmove(buf,&invalue,H5Tget_size(H5T_NATIVE_HSIZE));
1207 +
1208 +  status = H5Tconvert(H5T_NATIVE_HSIZE, H5T_NATIVE_LLONG, 1, buf, NULL, H5P_DEFAULT);
1209 +  if (status == FAIL)
1210 +       {
1211 +         H5Epush(__FILE__, "HE5_EHhsize2llong", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"hsize_t\" to \"long long\" data type.");
1212 +         return(status);
1213 +       }
1214 +
1215 +  memmove(&outvalue,buf,H5Tget_size(H5T_NATIVE_LLONG));
1216 +  free(buf);
1217 +  return(outvalue);
1218 +}
1219 +
1220  /*----------------------------------------------------------------------------|
1221  |  BEGIN_PROLOG                                                               |
1222  |                                                                             |
1223 @@ -877,6 +1009,8 @@
1224         outvalue = HE5_EHint2hssize(invalue);
1225    else if (sizeof(hid_t) == sizeof(long) )
1226         outvalue = HE5_EHlong2hssize(invalue);
1227 +  else if (sizeof(hid_t) == sizeof(long long))
1228 +       outvalue = HE5_EHllong2hssize(invalue);
1229  
1230    return(outvalue);
1231  }
1232 @@ -1027,6 +1161,8 @@
1233         outvalue = HE5_EHhssize2int(invalue);
1234    else if (sizeof(hid_t) == sizeof(long) )
1235         outvalue = HE5_EHhssize2long(invalue);
1236 +  else if (sizeof(hid_t) == sizeof(long long))
1237 +        outvalue = HE5_EHhssize2llong(invalue);
1238    
1239    return(outvalue);  
1240  }
1241 @@ -1142,6 +1278,55 @@
1242    return(outvalue);
1243  }
1244  
1245 +hssize_t
1246 +HE5_EHllong2hssize(long long invalue)
1247 +{
1248 +
1249 +  herr_t   status      = FAIL;
1250 +  void     *buf        = NULL;
1251 +  hssize_t outvalue    = FAIL;
1252 +  size_t   maxsize     = 0;
1253 +
1254 +  maxsize = MAX(sizeof(long long),H5Tget_size(H5T_NATIVE_HSSIZE));
1255 +  buf = calloc(1,maxsize);
1256 +  memmove(buf,&invalue,sizeof(long long));
1257 +
1258 +  status = H5Tconvert(H5T_NATIVE_LLONG, H5T_NATIVE_HSSIZE, 1, buf, NULL, H5P_DEFAULT);
1259 +  if (status == FAIL)
1260 +       {
1261 +         H5Epush(__FILE__, "HE5_EHllong2hssize", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"long long\" to \"hssize_t\" data type.");
1262 +         return(status);
1263 +       }
1264 +
1265 +  memmove(&outvalue,buf,H5Tget_size(H5T_NATIVE_HSSIZE));
1266 +  free(buf);
1267 +  return(outvalue);
1268 +}
1269 +
1270 +long long
1271 +HE5_EHhssize2llong(hssize_t invalue)
1272 +{
1273 +  herr_t   status       = FAIL;
1274 +  void     *buf         = NULL;
1275 +  long long outvalue    = FAIL;
1276 +  size_t   maxsize      = 0;
1277 +
1278 +  maxsize = MAX(H5Tget_size(H5T_NATIVE_LLONG),H5Tget_size(H5T_NATIVE_HSSIZE));
1279 +  buf = calloc(1,maxsize);
1280 +  memmove(buf,&invalue,H5Tget_size(H5T_NATIVE_HSSIZE));
1281 +
1282 +  status = H5Tconvert(H5T_NATIVE_HSSIZE, H5T_NATIVE_LLONG, 1, buf, NULL, H5P_DEFAULT);
1283 +  if (status == FAIL)
1284 +       {
1285 +         H5Epush(__FILE__, "HE5_EHhssize2llong", __LINE__, H5E_FUNC, H5E_CANTINIT, "Cannot convert \"hssize_t\" to \"long long\" data type.");
1286 +         return(status);
1287 +       }
1288 +
1289 +  memmove(&outvalue,buf,H5Tget_size(H5T_NATIVE_LLONG));
1290 +  free(buf);
1291 +  return(outvalue);
1292 +}
1293 +
1294  /*----------------------------------------------------------------------------|
1295  |  BEGIN_PROLOG                                                               |
1296  |                                                                             |
This page took 0.150869 seconds and 3 git commands to generate.