##
##  This is an example Makefile to build the program 'h4toh5example.c'
##

##
## set these paths to the correct location of HDF5, libh4toh5 and HDF4. 
##
## User should specific SYSLIBS, please refer h4toh5lib user's guide on how to set
## SYSLIBS on different platforms.


HDF4_INSTALL = /usr/local/hdf
HDF5_INSTALL = /usr/local/hdf5
H4TOH5_INSTALL = /usr/local/h4toh5

DEFS =                                                                                                       
CFLAGS = $(DEFS) -I$(H4TOH5_INSTALL)/include -I$(HDF4_INSTALL)/include -I$(HDF5_INSTALL)/include 

LIBS= $(H4TOH5_INSTALL)/lib/libh4toh5.a $(HDF4_INSTALL)/lib/libmfhdf.a $(HDF4_INSTALL)/lib/libdf.a $(HDF4_INSTALL)/lib/libjpeg.a $(HDF5_INSTALL)/lib/libhdf5.a $(HDF4_INSTALL)/lib/libz.a

h4toh5example: h4toh5example.o
	$(CC) -o h4toh5example h4toh5example.o $(LIBS) $(SYSLIBS)

h4toh5example.o:  h4toh5example.c
	$(CC) $(CFLAGS) -c h4toh5example.c
