Makefile.am.in 1.79 KB
Newer Older
1 2 3 4
## Process this file with make_am to produce Makefile.am
SUBDIRS: lib include
CVS_HEADERS: cvs_headers
BODY:
Niels Möller's avatar
Niels Möller committed
5 6

AUTOMAKE_OPTIONS = foreign
7 8 9 10 11 12 13 14 15
SUBDIRS = lib include

# To remake all Makefile.am-files, run
#
# 	./used_headers . $(SUBDIRS) | ./make_am
#
# You should run this after recompiling, but before making a dist, as
# it uses dependency information to figure out which header files
# should be included in th dist. How to tell this to make?
Niels Möller's avatar
Niels Möller committed
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30

bin_PROGRAMS = lsh lshd

# Don't use BUILT_SOURCES, as all these files are #included, and can't be
# compiled or dependency checked independently.

generated_sources = atoms_defines.h atoms_gperf.c atoms_table.c

common_sources = alist.c atoms.c bignum.c channel.c \
	charset.c connection.c crypto.c \
	debug.c disconnect.c encrypt.c format.c getopt.c io.c keyexchange.c \
	packet_ignore.c pad.c parse.c publickey_crypto.c \
	randomness.c \
	read_data.c read_line.c read_packet.c service.c \
	translate_signal.c unpad.c \
31
	werror.c write_buffer.c xalloc.c 
Niels Möller's avatar
Niels Möller committed
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50

lsh_SOURCES = $(common_sources) lsh.c client.c client_keyexchange.c \
	client_password.c client_userauth.c

lshd_SOURCES = $(common_sources) lshd.c reaper.c server.c server_keyexchange.c \
	server_password.c server_userauth.c

atoms_defines.h: atoms.in process_atoms
	bash process_atoms header <atoms.in >atoms_defines.h

atoms_gperf.c: atoms.in process_atoms Makefile
	bash process_atoms gperf <atoms.in \
             | gperf -t -c -l -k1,7,$$ -N gperf_atom >atoms_gperf.c

atoms_table.c: atoms.in process_atoms
	bash process_atoms table <atoms.in >atoms_table.c

LDADD = @LIBOBJS@ lib/libsymmetric.a

51 52 53 54 55 56 57
lsh_DEPENDENCIES = @LIBOBJS@ symmetric
lshd_DEPENDENCIES = @LIBOBJS@ symmetric

.PHONY: symmetric
symmetric:
	(cd lib && $(MAKE) libsymmetric.a)

58 59
EXTRA_DIST = atoms.in process_atoms $(generated_sources) HACKING \
	$(cvs_headers)
Niels Möller's avatar
Niels Möller committed
60