ifeq "$(ROOTDIR)" ""
	export ROOTDIR=$(shell while true; do if [ -f BaseVar.mk ]; then pwd;exit; else cd ..;fi;done;)
endif

include $(ROOTDIR)/.config
include $(ROOTDIR)/BaseVar.mk

SRCDIR=$(CURDIR)/crypt

all: build

build: $(SRCDIR)
	make -C $(SRCDIR)

clean:
	cd $(SRCDIR); \
	make clean
distclean:
	cd $(SRCDIR); \
	make distclean

install:
	cp $(SRCDIR)/aes_crypt $(FSROOT)/usr/bin/aes_crypt
	$(STRIP) $(FSROOT)/usr/bin/aes_crypt
