# -*-Makefile-*-
# title	 specific top level makefile for StepMake

# subdir level:
#
depth = .
#

# descent order into subdirectories:
#
ifeq ($(PACKAGE),STEPMAKE)
SUBDIRS = bin make stepmake 
else
SUBDIRS = stepmake
endif
#

# list of distribution files:
#
SCRIPTS = configure aclocal.m4
README_FILES = CHANGES README TODO
README_TXT_FILES = AUTHORS.txt INSTALL.txt
EXTRA_DIST_FILES = $(IN_FILES) VERSION $(README_FILES)  $(SCRIPTS) INSTALL.texi
NON_ESSENTIAL_DIST_FILES = $(README_TXT_FILES)
#

# bootstrap stepmake:
#
STEPMAKE_TEMPLATES=toplevel texinfo
include $(depth)/make/stepmake.make 
#

# 2nd: THIS IS NO MISTAKE
# this makes lilypond's make dist descent into stepmake
# should check if we can remove the above
# descent order into subdirectories:
#
ifeq ($(PACKAGE),STEPMAKE)
SUBDIRS = bin make stepmake 
else
SUBDIRS = stepmake
endif
#

#urg urg
stepmake/aclocal.m4:
	-$(LN) aclocal.m4 $@

ifeq ($(PACKAGE),STEPMAKE)
INSTALLATION_DIR=$(datadir)
INSTALLATION_FILES=$(DIST_FILES) $(NON_ESSENTIAL_DIST_FILES) GNUmakefile config.make config.status
include $(stepdir)/install-targets.make
endif

localclean:
	rm -f bin/*.pyc
	rm -f stepmake/stepmake stepmake/bin stepmake/aclocal.m4
