AUTOMAKE_OPTIONS = foreign

if LIBMP_HACK
SUBDIRS = libsrp libkrypto base telnet ftp
else
SUBDIRS = libsrp libkrypto base telnet ftp
endif

DIST_SUBDIRS = libsrp libkrypto base telnet ftp

EXTRA_DIST = README README.NIS ChangeLog

dist-hook:
	tar cf - include | (cd $(distdir); tar xpf -)
	tar cf - lib | (cd $(distdir); tar xpf -)
	(cd $(distdir); mkdir gmp-2.0.2 cryptolib_1.1 freelip rsaref; touch gmp-2.0.2/.empty cryptolib_1.1/.empty freelip/.empty rsaref/.empty; ln -s gmp-2.0.2 libmp; ln -s cryptolib_1.1/cryptolib cryptolib)
	tar cf - docs | (cd $(distdir); tar xpf -)
	tar cf - java | (cd $(distdir); tar xpf -)
	tar cf - inst | (cd $(distdir); tar xpf -)
