prefix=@prefix@
exec_prefix=@exec_prefix@
LOGDIR=@localstatedir@
CFGDIR=@sysconfdir@
BINDIR=@bindir@
CGIDIR=@sbindir@
HTMLDIR=@datarootdir@

INSTALL=@INSTALL@
INSTALL_OPTS=@INSTALL_OPTS@

install: installdirs
	@files=`find src -mindepth 1 -type f ! -name "*.in" -and ! -name "Makefile" -and ! -wholename "src/build/*"`; \
	for file in $$files; do \
		$(INSTALL) -m 644 $(INSTALL_OPTS) "$$file" $(DESTDIR)$(prefix)/lib/agavi/"$$file"; \
	done

installdirs:
	$(INSTALL) -m 755 $(INSTALL_OPTS) -d $(DESTDIR)$(prefix)/lib/agavi/
	@dirs=`find src -mindepth 1 -type d`; \
	for dir in $$dirs; do \
		$(INSTALL) -m 755 $(INSTALL_OPTS) -d $(DESTDIR)$(prefix)/lib/agavi/"$$dir"; \
	done
