bin_PROGRAMS = ppstamp pstamprequest locateimages pstampdump

noinst_HEADERS = \
	ppstamp.h  \
        pstampErrorCodes.h

ppstamp_CPPFLAGS = $(PSLIB_CFLAGS) $(PSMODULE_CFLAGS) 
pstamprequest_CPPFLAGS = $(PSLIB_CFLAGS) $(PSMODULE_CFLAGS) 
locateimages_CPPFLAGS = $(PSLIB_CFLAGS) $(PSMODULE_CFLAGS)
pstampdump_CPPFLAGS = $(PSLIB_CFLAGS) $(PSMODULE_CFLAGS)

# $(PSASTRO_CFLAGS) $(PPSTATS_CFLAGS) $(ppstamp_CFLAGS)

ppstamp_LDFLAGS = $(PSLIB_LIBS) $(PSMODULE_LIBS) 
pstamprequest_LDFLAGS = $(PSLIB_LIBS) $(PSMODULE_LIBS) 
locateimages_LDFLAGS = $(PSLIB_LIBS) $(PSMODULE_LIBS) 
pstampdump_LDFLAGS = $(PSLIB_LIBS) $(PSMODULE_LIBS)

ppstamp_SOURCES = \
	ppstamp.c \
	ppstampArguments.c \
	ppstampCleanup.c \
        pstampErrorCodes.c \
	ppstampMakeStamp.c \
	ppstampMosaic.c \
	ppstampOptions.c \
	ppstampParseCamera.c \
        ppstampRegion.c \
	ppstampVersion.c \
	pstampGetROI.c

pstamprequest_SOURCES = \
	pstamprequest.c \
	pstampGetROI.c \
	ppstampOptions.c

locateimages_SOURCES = \
	locateimages.c

pstampdump_SOURCES = \
        pstampdump.c


clean-local:
	-rm -f TAGS

# Tags for emacs
tags:
	etags `find . -name \*.[ch] -print`

### Error codes.
BUILT_SOURCES = pstampErrorCodes.h pstampErrorCodes.c
CLEANFILES = pstampErrorCodes.h pstampErrorCodes.c

pstampErrorCodes.h : pstampErrorCodes.dat pstampErrorCodes.h.in
	$(ERRORCODES) --data=pstampErrorCodes.dat --outdir=. pstampErrorCodes.h

pstampErrorCodes.c : pstampErrorCodes.dat pstampErrorCodes.c.in pstampErrorCodes.h
	$(ERRORCODES) --data=pstampErrorCodes.dat --outdir=. pstampErrorCodes.c
