# DO NOT EDIT THIS FILE
# Generated by Parrot::Configure::Step from languages/TAP/config/makefiles/root.in


# commands
LN_S   = @lns@
PERL   = @perl@
RM_F   = @rm_f@
PARROT = ../../parrot@exe@


# directories
PGE_DIR  = ../../compilers/pge
TGE_DIR  = ../../compilers/tge


# files
SOURCES = \
	TAP.pir \
	src/TAP_grammar.pir \
	src/main.pir


# directives
.SUFFIXES: .pir .pbc .tg .pg


# targets
all: TAP.pbc


$(PARROT):
	@echo "You must first configure and build parrot. See ../../README"
	@$(PERL) -e "exit 1"


TAP.pbc: $(PARROT) $(PGE_DIR)/pgc.pir $(SOURCES)
	$(PARROT) --output=$@ TAP.pir

.pg.pir:
	$(PARROT) $(PGE_DIR)/pgc.pir --output=$@ $<

.tg.pir:
	$(PARROT) $(TGE_DIR)/tgc.pir --output=$@ $<

.pir.pbc:
	$(PARROT) -o $@ $<


# This is a listing of all targets, that are meant to be called by users
help:
	@echo ""
	@echo "Following targets are available for the user:"
	@echo ""
	@echo "  all:               TAP.pbc"
	@echo "                     This is the default."
#	@echo "Testing:"
#	@echo "  test:              Run the test suite."
#	@echo "  testclean:         Clean up test results."
#	@echo ""
	@echo "Cleaning:"
	@echo "  clean:             Basic cleaning up."
	@echo "  realclean:         Removes also files generated by 'Configure.pl'"
	@echo "  distclean:         Removes also anything built, in theory"
	@echo ""
	@echo "Misc:"
	@echo "  help:              Print this help message."
	@echo ""

#test: all
#	$(PERL) t/harness

## this target has nothing to do
#testclean:

CLEANUPS = \
	TAP.pbc \
	src/TAP_grammar.pir

clean:
	$(RM_F) $(CLEANUPS)

realclean: clean
	$(RM_F) Makefile

distclean: realclean
