-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.in
115 lines (91 loc) · 3.25 KB
/
Makefile.in
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
109
110
111
112
113
114
115
# $Id$
PROGVER=@PROGVER@
prefix=@prefix@
exec_prefix=@exec_prefix@
bindir=@bindir@
sbindir=@sbindir@
libdir=@libdir@
libexecdir=@libexecdir@
datadir=@datadir@
mandir=@mandir@
sysconfdir=@sysconfdir@
srcdir=@srcdir@
top_srcdir=@top_srcdir@
localstatedir=@localstatedir@
includedir=@includedir@
PIDFILEDIR=@PIDPATH@
PATHFLAGS=-DSYSCONFDIR="\"$(sysconfdir)\"" -DPIDFILEDIR="\"$(PIDFILEDIR)\""
PROGFLAGS=-DPROGVER="\"$(PROGVER)\""
VPATH=@srcdir@
CC=@CC@
LDFLAGS=@LDFLAGS@
CFLAGS=@CFLAGS@
CPPFLAGS=-I$(srcdir) @CPPFLAGS@ $(PATHFLAGS) $(PROGFLAGS) @DEFS@
LIBS=@LIBS@
EXEEXT=@EXEEXT@
INSTALL=@INSTALL@
RANLIB=@RANLIB@
HEADER_DIR=$(includedir)/flowd
# Bison doesn't work
YACC=@YACC@
TARGETS=flowd flowd-reader
all: $(TARGETS)
LIBFLOWD_OBJS= atomicio.o addr.o store.o store-v2.o crc32.o \
strlcpy.o strlcat.o
LIBFLOWD_HEADERS= flowd-config.h flowd-common.h addr.h crc32.h \
store.h store-v2.h flowd-pytypes.h
FLOWD_OBJS= flowd.o privsep_fdpass.o privsep.o filter.o \
parse.o log.o daemon.o peer.o \
closefrom.o setproctitle.o
FLOWD_READER_OBJS= flowd-reader.o parse.o log.o filter.o
libflowd.a: $(LIBFLOWD_HEADERS) $(LIBFLOWD_OBJS)
$(AR) rv $@ $(LIBFLOWD_OBJS)
$(RANLIB) $@
parse.c: $(top_srcdir)/parse.y
$(YACC) $(top_srcdir)/parse.y
mv y.tab.c parse.c
rm -f y.tab.h
flowd: $(LIBFLOWD_HEADERS) $(FLOWD_OBJS) libflowd.a
$(CC) $(LDFLAGS) -L. -o $@ $(FLOWD_OBJS) -lflowd $(LIBS)
flowd-reader: $(LIBFLOWD_HEADERS) $(FLOWD_READER_OBJS) libflowd.a
$(CC) $(LDFLAGS) -L. -o $@ $(FLOWD_READER_OBJS) libflowd.a $(LIBS)
clean:
rm -f $(TARGETS) *.o core *.core y.tab.* parse.c libflowd.a
realclean: clean
-(cd Flowd-perl && test -f Makefile && make distclean)
rm -rf autom4te.cache Makefile config.log config.status
rm -f flowd.8 flowd-reader.8 flowd.conf.5
rm -f *.pyc *.pyo
rm -rf build
distclean: realclean
rm -f flowd-config.h* flowd-pytypes.h configure
strip:
strip $(TARGETS)
install-man:
$(srcdir)/mkinstalldirs $(DESTDIR)$(mandir)/man5
$(srcdir)/mkinstalldirs $(DESTDIR)$(mandir)/man8
$(INSTALL) -m 0644 flowd.8 $(DESTDIR)$(mandir)/man8/flowd.8
$(INSTALL) -m 0644 flowd.conf.5 $(DESTDIR)$(mandir)/man5/flowd.conf.5
$(INSTALL) -m 0644 flowd-reader.8 $(DESTDIR)$(mandir)/man8/flowd-reader.8
install-bin: $(TARGETS)
$(srcdir)/mkinstalldirs $(DESTDIR)$(sbindir)
$(srcdir)/mkinstalldirs $(DESTDIR)$(bindir)
$(INSTALL) -m 0755 -s flowd $(DESTDIR)$(sbindir)/flowd
$(INSTALL) -m 0755 -s flowd-reader $(DESTDIR)$(bindir)/flowd-reader
install-conf: flowd.conf
$(srcdir)/mkinstalldirs $(DESTDIR)$(sysconfdir)
test -f $(DESTDIR)$(sysconfdir)/flowd.conf || \
$(INSTALL) -m 0600 flowd.conf $(DESTDIR)$(sysconfdir)
install-lib: libflowd.a
$(srcdir)/mkinstalldirs $(DESTDIR)$(libdir)
$(INSTALL) -m 0644 libflowd.a $(DESTDIR)$(libdir)
install-includes: $(LIBFLOWD_HEADERS)
$(srcdir)/mkinstalldirs $(DESTDIR)$(HEADER_DIR)
$(INSTALL) -m 0644 addr.h $(DESTDIR)$(HEADER_DIR)
$(INSTALL) -m 0644 store.h $(DESTDIR)$(HEADER_DIR)
$(INSTALL) -m 0644 store-v2.h $(DESTDIR)$(HEADER_DIR)
$(INSTALL) -m 0644 crc32.h $(DESTDIR)$(HEADER_DIR)
$(INSTALL) -m 0644 flowd-pytypes.h $(DESTDIR)$(HEADER_DIR)
$(INSTALL) -m 0644 flowd-config.h $(DESTDIR)$(HEADER_DIR)
$(INSTALL) -m 0644 flowd-common.h $(DESTDIR)$(HEADER_DIR)
install: install-bin install-man install-conf install-lib install-includes