Insourced push() into send.
[mmh] / sbr / Makefile.in
1 #
2 # Makefile for sbr subdirectory
3 #
4
5 SHELL = /bin/sh
6
7 top_srcdir = @top_srcdir@
8 srcdir     = @srcdir@
9 VPATH      = @srcdir@
10
11 prefix      = @prefix@
12 exec_prefix = @exec_prefix@
13 bindir      = @bindir@
14 libdir      = @libdir@
15 etcdir      = @sysconfdir@
16
17 CC       = @CC@
18 CFLAGS   = @CFLAGS@
19 DEFS     = @DEFS@
20 INCLUDES = -I.. -I. -I$(top_srcdir) @CPPFLAGS@
21
22 LEX    = @LEX@
23 AWK    = @AWK@
24 LORDER = @LORDER@
25 TSORT  = @TSORT@
26 RANLIB = @RANLIB@
27 LIBTOOL = @LIBTOOL@
28 GNU_LIBTOOL = @GNU_LIBTOOL@
29 LINT    = @LINT@
30 LINTFLAGS = @LINTFLAGS@
31
32 LIBOBJS = @LIBOBJS@
33
34 COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CFLAGS)
35
36
37
38 .SUFFIXES:
39 .SUFFIXES: .c .o
40
41 .c.o:
42         $(COMPILE) $<
43
44 # this header file is parsed to generate signal messages (sigmsg.h)
45 SIGNAL_H = @SIGNAL_H@
46
47 # source for library functions
48 SRCS = addrsbr.c ambigsw.c atooi.c brkstring.c  \
49         check_charset.c closefds.c concat.c context_del.c  \
50         context_find.c context_foil.c context_read.c  \
51         context_replace.c context_save.c \
52         copyip.c cpydata.c cpydgst.c crawl_folders.c  \
53         discard.c done.c dtime.c dtimep.c  \
54         error.c ext_hook.c fdcompare.c folder_addmsg.c folder_delmsgs.c  \
55         folder_free.c folder_pack.c folder_read.c  \
56         folder_realloc.c gans.c getans.c getanswer.c  \
57         getarguments.c getcpy.c getpass.c  \
58         fmt_addr.c fmt_compile.c fmt_new.c fmt_rfc2047.c  \
59         fmt_scan.c lock_file.c m_atoi.c m_backup.c  \
60         m_convert.c m_draft.c m_getfld.c m_gmprot.c  \
61         m_name.c \
62         makedir.c mts.c norm_charmap.c  \
63         path.c peekc.c pidwait.c pidstatus.c  \
64         print_help.c print_sw.c print_version.c \
65         putenv.c refile.c mhbasename.c  \
66         readconfig.c ruserpass.c seq_add.c seq_bits.c  \
67         seq_del.c seq_getnum.c seq_list.c seq_nameok.c  \
68         seq_print.c seq_read.c seq_save.c seq_setcur.c  \
69         seq_setprev.c seq_setunseen.c signals.c  \
70         smatch.c snprintb.c strcasecmp.c  \
71         strindex.c trimcpy.c uprf.c vfgets.c fmt_def.c  \
72         m_msgdef.c mf.c utils.c m_mktemp.c
73
74 # source for compatibility functions
75 COMPAT = snprintf.c strdup.c
76
77 OBJS =  $(SRCS:.c=.o) $(LIBOBJS)
78
79 # auxiliary files
80 AUX = Makefile.in sigmsg.awk dtimep.lex
81
82 # all files in this directory included in the distribution
83 DIST = $(SRCS) $(COMPAT) $(AUX)
84
85 # ========= DEPENDENCIES FOR BUILDING ==========
86
87 # default target
88 all: libmh.a
89
90 sigmsg.h: sigmsg.awk
91         $(AWK) -f $(srcdir)/sigmsg.awk $(SIGNAL_H) > $@
92
93 lint: sigmsg.h
94         $(LINT) $(LINTFLAGS) $(INCLUDES) $(DEFS) $(SRCS)
95
96 # Note that not all lexes support -o (it is not POSIX); also
97 # some lexes will only accept '-n -t', not '-nt'.
98 # Also, not all makes accept $< in non-pattern rules,
99 # hence the explicit filenames here.
100 dtimep.c: dtimep.lex
101         $(LEX) -n -t $(srcdir)/dtimep.lex > dtimep.c
102
103 pidstatus.o: sigmsg.h
104
105 libmh.a: $(OBJS)
106         rm -f $@
107         if test x$(LIBTOOL) != x -a x$(GNU_LIBTOOL) = x ; then \
108           $(LIBTOOL) -static -c -o libmh.a $(OBJS) ; \
109         else \
110           ar cr libmh.a `$(LORDER) $(OBJS) | $(TSORT) 2>/dev/null`  ; \
111           $(RANLIB) libmh.a  ; \
112         fi
113
114 install:
115
116 uninstall:
117
118 # ========== DEPENDENCIES FOR CLEANUP ==========
119
120 mostlyclean:
121         rm -f *.o *~
122
123 clean: mostlyclean
124         rm -f libmh.a sigmsg.h dtimep.c
125
126 distclean: clean
127         rm -f Makefile
128
129 realclean: distclean
130
131 superclean: realclean
132
133 # ========== DEPENDENCIES FOR MAINTENANCE ==========
134
135 subdir = sbr
136
137 Makefile: Makefile.in ../config.status
138         cd .. && ./config.status $(subdir)/$@
139
140 distdir = ../`cat ../distname`/$(subdir)
141 mmhdist: $(DIST)
142         @echo "Copying distribution files in $(subdir)"
143         @for file in $(DIST); do \
144           cp -p $(srcdir)/$$file $(distdir); \
145         done
146