aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile.am
blob: 2dbea3020affa6bb0d5b73075c1a466756d309e9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
# Makefile for fetchmail

SUBDIRS=		intl m4 po

AM_CFLAGS=		@CEFLAGS@
AM_CPPFLAGS=		@CPFLAGS@ -I$(top_srcdir)/intl -I$(top_builddir)/intl
AM_LDFLAGS=		@LDEFLAGS@
ACLOCAL_AMFLAGS=	-I m4 -I .
AM_YFLAGS=		-d
BUILT_SOURCES=		rcfile_y.h

bin_PROGRAMS=		fetchmail
dist_bin_SCRIPTS=	fetchmailconf
dist_noinst_SCRIPTS=	html2txt.sh specgen.sh
dist_man1_MANS=		fetchmail.man

# for gettext (used by fetchmail.c, NOT by GNU gettext)
localedir=		$(datadir)/locale
DEFS=			@DEFS@ -DLOCALEDIR=\"$(localedir)\"

noinst_LIBRARIES=	libfm.a
libfm_a_SOURCES=	xmalloc.c base64.c rfc822.c report.c rfc2047e.c
libfm_a_LIBADD=		$(EXTRAOBJ)
libfm_a_DEPENDENCIES=	$(EXTRAOBJ)
LDADD	=		libfm.a @LIBINTL@ $(LIBOBJS)
DEPENDENCIES=		libfm.a $(LIBOBJS)

check_PROGRAMS=

if NEED_TRIO
noinst_LIBRARIES+=	libtrio.a
libtrio_a_SOURCES=	trio/triostr.c trio/trio.c trio/trionan.c \
			trio/trio.h trio/triop.h trio/triodef.h \
			trio/trionan.h trio/triostr.h
check_PROGRAMS+=	regression
regression_SOURCES=	trio/regression.c
LDADD +=		libtrio.a -lm
TESTS=			regression
endif

fetchmail_SOURCES=	fetchmail.h getopt.h \
		i18n.h kerberos.h md5.h mx.h netrc.h ntlm.h \
		smbbyteorder.h smbdes.h smbmd4.h smbencrypt.h smtp.h \
		socket.h tunable.h \
		socket.c getpass.c pop2.c pop3.c imap.c etrn.c \
		odmr.c fetchmail.c env.c idle.c options.c daemon.c \
		driver.c transact.c sink.c smtp.c \
		uid.c mxget.c md5ify.c cram.c kerberos.c gssapi.c \
		opie.c rpa.c interface.c netrc.c \
		unmime.c conf.c checkalias.c smbdes.c smbencrypt.c \
		smbmd4.c smbutil.c ipv6-connect.c lock.c \
		rcfile_l.l rcfile_y.y ucs/norm_charmap.c

check_PROGRAMS +=	rfc822 unmime netrc rfc2047e

rfc2047e_CFLAGS=	-DTEST

rfc822_CFLAGS=	-DMAIN

unmime_SOURCES=	unmime.c
unmime_CFLAGS=	-DSTANDALONE -DHAVE_CONFIG_H -I$(builddir)

netrc_SOURCES=	netrc.c xmalloc.c report.c
netrc_CFLAGS=	-DSTANDALONE -DHAVE_CONFIG_H -I$(builddir)

# For some losing Unix makes.
SHELL = /bin/sh
@SET_MAKE@

fetchmail.spec: Makefile.in specgen.sh
	$(srcdir)/specgen.sh $(VERSION) >fetchmail.spec

DISTDOCS=	FAQ FEATURES NOTES fetchmail-man.html fetchmail-FAQ.html \
		design-notes.html todo.html fetchmail-features.html \
		README.SSL README.NTLM

# extra directories to ship
distdirs = rh-config contrib beos

EXTRA_DIST= $(DISTDOCS) fetchmail.spec $(distdirs) ucs/README.svn \
	    trio/CHANGES trio/README

FAQ: fetchmail-FAQ.html
	AWK=$(AWK) $(SHELL) $(srcdir)/html2txt.sh $(srcdir)/fetchmail-FAQ.html >$@ || { rm -f $@ ; exit 1 ; }

FEATURES: fetchmail-features.html
	AWK=$(AWK) $(SHELL) $(srcdir)/html2txt.sh $(srcdir)/fetchmail-features.html >$@ || { rm -f $@ ; exit 1 ; }

NOTES: design-notes.html
	AWK=$(AWK) $(SHELL) $(srcdir)/html2txt.sh $(srcdir)/design-notes.html >$@ || { rm -f $@ ; exit 1 ; }

TODO: todo.html
	AWK=$(AWK) $(SHELL) $(srcdir)/html2txt.sh $(srcdir)/todo.html >$@ || { rm -f $@ ; exit 1 ; }

# man2html no longer chokes and dies on this man page,
# but manServer.pl does a much better job. 
fetchmail-man.html: fetchmail.man
	env - PATH=$$PATH $(srcdir)/dist-tools/manServer.pl fetchmail.man >$@ \
	|| { rm -f $@ ; exit 1 ; }

dist-hook:
	cd $(distdir) && find $(distdirs) intl po -name .svn -type d -prune -exec rm -rf '{}' ';'
	cd $(distdir) && find $(distdirs) intl po -name '*~' -exec rm -f '{}' ';'

# The following sets edit modes for GNU EMACS.
# Local Variables:
# compile-command:"configure"
# End: