# $Id: root.in 13165 2006-07-05 19:14:09Z bernhard $

# Makefile for languages/befunge

# Setup of some commands
PARROT     = ../../parrot
PERL       = @perl@
RM_F       = @rm_f@

default: all

help :
	@echo ""
	@echo "Following targets are available for the user:"
	@echo ""
	@echo "  build:             Create befunge.pbc"
	@echo "                     This is the default."
	@echo ""
	@echo "  test:              run the test suite,"
	@echo ""
	@echo "  clean:             clean up temporary files"
	@echo ""
	@echo "  realclean:         clean up generated files"
	@echo ""
	@echo "  help:              print this help message"


all: build

test: build
	cd .. && $(PERL) befunge/t/harness

build: befunge.pasm debug.pasm flow.pasm io.pasm load.pasm maths.pasm stack.pasm
	$(PARROT) -o befunge.pbc befunge.pasm

clean:
	$(RM_F) core \
    "*.pbc" \
    "*~"

realclean: clean
	$(RM_RF) Makefile
