# Automatically Generated Makefile by EDE.
# For use with: make
# Relative File Name: cedet/srecode/Makefile
#
# DO NOT MODIFY THIS FILE OR YOUR CHANGES MAY BE LOST.
# EDE is the Emacs Development Environment.
# http://cedet.sourceforge.net/ede.shtml
#
LOADPATH= ../ ../ ../../../ 
require=$(foreach r,$(1),(require (quote $(r))))
EMACSFLAGS=-batch --no-site-file --eval '(setq debug-on-error t)' -l "../../../cedet-remove-builtin.el"
EMACS=@echo "    > $@";emacs
AUTOGENFLAGS=-L ../ --eval '(progn (require (quote cedet-compat)) (require (quote mode-local)))'

top=../../
ede_FILES=Project.ede Makefile

LOADDEFS=loaddefs.el
LOADDIRS=.
lang_SEMANTIC_GRAMMAR=srt.wy
lang_SEMANTIC_GRAMMAR_EL=srt-wy.el
srecode_LISP=mode.el compile.el insert.el semantic.el template.el dictionary.el args.el table.el filters.el find.el ctxt.el getset.el cpp.el expandproto.el el.el srt.el texi.el map.el extract.el java.el fields.el android.el document.el m3.el srt-mode.el
VERSION=1.1beta
DISTDIR=$(top)cedet-topdir-$(VERSION)/cedet/srecode



all: lang srecode

.PHONY: clean-autoloads
clean-autoloads: 
	rm -f $(LOADDEFS)

.PHONY: autoloads
autoloads: 
	$(EMACS) $(EMACSFLAGS) $(AUTOGENFLAGS) $(addprefix -L ,$(LOADPATH)) --eval '(progn $(call require, $(PRELOADS)) (setq generated-autoload-file "$(abspath $(LOADDEFS))"))' -f batch-update-autoloads $(abspath $(LOADDIRS))


%-wy.el: %.wy
	$(EMACS) $(EMACSFLAGS) $(addprefix -L ,$(LOADPATH)) --eval '(progn $(call require,$(PRELOADS)))' -f semantic-grammar-batch-build-packages $^

.PHONY: lang
lang: $(addsuffix -wy.elc, $(basename $(lang_SEMANTIC_GRAMMAR)))
lang: PRELOADS=cedet-compat cedet-devel-load semantic/grammar semantic/bovine/grammar semantic/wisent/grammar

lang: EMACSFLAGS+= --eval '(setq max-specpdl-size 1500 max-lisp-eval-depth 700 cedet-minimum-setup t)'
%.elc: %.el
	$(EMACS) $(EMACSFLAGS) $(addprefix -L ,$(LOADPATH)) --eval '(progn $(call require, $(PRELOADS)))' -f batch-byte-compile $^

.PHONY: srecode
srecode: $(addsuffix c, $(srecode_LISP))
srecode: PRELOADS=cedet-compat

tags: 


clean:
	rm -f *-by.el *-wy.el *.elc

.PHONY: dist

dist: autoloads $(lang_SEMANTIC_GRAMMAR_EL)
	mkdir $(DISTDIR)
	cp loaddefs.el $(lang_SEMANTIC_GRAMMAR) $(lang_SEMANTIC_GRAMMAR_EL) $(srecode_LISP) $(ede_FILES) $(DISTDIR)

Makefile: Project.ede
	@echo Makefile is out of date!  It needs to be regenerated by EDE.
	@echo If you have not modified Project.ede, you can use 'touch' to update the Makefile time stamp.
	@false



# End of Makefile
