ifndef BOOST_DIR
BOOST_DIR = c:/Boost/include/boost-1_32
endif

SUBDIRS  = toppers toppers/itron toppers/itron/jsp toppers/itron/fdmp cfg chk
WORKDIRS := $(addprefix work/, $(SUBDIRS))

all: $(WORKDIRS)

doc:
	doxygen

$(WORKDIRS)::
	make BOOST_DIR="$(BOOST_DIR)" -C $@

convert: directories $(SUBDIRS)

directories:
	if test -d work ; then :; else \
		mkdir work ; \
	fi
	for subdir in $(WORKDIRS) ; do \
		if test -d $$subdir ; then :; else \
			mkdir $$subdir ; \
		fi ; \
	done \

$(SUBDIRS)::
	make BOOST_DIR="$(BOOST_DIR)" -C $@ convert

