~ubuntu-branches/ubuntu/natty/ntop/natty

« back to all changes in this revision

Viewing changes to ntop/Makefile.mingw

  • Committer: Bazaar Package Importer
  • Author(s): Ola Lundqvist
  • Date: 2005-01-30 21:59:13 UTC
  • mfrom: (2.1.1 warty)
  • Revision ID: james.westby@ubuntu.com-20050130215913-xc3ke963bw49b3k4
Tags: 2:3.0-5
* Updated README.Debian file so users will understand what to do at
  install, closes: #291794, #287802.
* Updated ntop init script to give better output.
* Also changed log directory from /var/lib/ntop to /var/log/ntop,
  closes: #252352.
* Quoted the interface list to allow whitespace, closes: #267248.
* Added a couple of logcheck ignores, closes: #269321, #269319.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Generated automatically from Makefile.in by configure.
2
 
#
3
 
#  Copyright (C) 1998-99  Luca Deri <deri@unipi.it>
4
 
#                         Stefano Suin <stefano@unipi.it>
5
 
#                         (Stefano contributed to version 1.0)
6
 
#
7
 
#                      Centro SERRA, University of Pisa
8
 
#                      http://www-serra.unipi.it/
9
 
#
10
 
#
11
 
#  Copyright (c) 1994, 1996, 1997
12
 
#       The Regents of the University of California.  All rights reserved.
13
 
#
14
 
#  Redistribution and use in source and binary forms, with or without
15
 
#  modification, are permitted provided that: (1) source code distributions
16
 
#  retain the above copyright notice and this paragraph in its entirety, (2)
17
 
#  distributions including binary code include the above copyright notice and
18
 
#  this paragraph in its entirety in the documentation or other materials
19
 
#  provided with the distribution, and (3) all advertising materials mentioning
20
 
#  features or use of this software display the following acknowledgement:
21
 
#  ``This product includes software developed by the University of California,
22
 
#  Lawrence Berkeley Laboratory and its contributors.'' Neither the name of
23
 
#  the University nor the names of its contributors may be used to endorse
24
 
#  or promote products derived from this software without specific prior
25
 
#  written permission.
26
 
#  THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
27
 
#  WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
28
 
#  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
29
 
#
30
 
 
31
 
#
32
 
# Various configurable paths (remember to edit Makefile.in, not Makefile)
33
 
#
34
 
 
35
 
# Top level hierarchy
36
 
prefix = /
37
 
exec_prefix = ${prefix}
38
 
# Pathname of directory to install the binary
39
 
BINDEST = ${exec_prefix}/sbin
40
 
# Pathname of directory to install the man page
41
 
MANDEST = ${prefix}/man
42
 
VERSION=1.1
43
 
OSNAME=win2k
44
 
 
45
 
INC_GDBM=-Ic:/scott/include
46
 
INC_WPDPACK=-Ic:/scott/src/wpdpack/include
47
 
INC_GDCHART=-I../gdchart0.94c
48
 
 
49
 
LIB_GDBM=-Lc:/scott/lib
50
 
LIB_WPDPACK=-Lc:/scott/src/wpdpack/lib
51
 
 
52
 
LDIRS = $(LIB_WPDPACK) \
53
 
        $(LIB_GDBM) \
54
 
        -L../gdchart0.94c \
55
 
        -L../gdchart0.94c/zlib-1.1.3 \
56
 
        -L../gdchart0.94c/gd-1.8.3 \
57
 
        -L../gdchart0.94c/gd-1.8.3/libpng-1.0.8
58
 
 
59
 
#
60
 
# You shouldn't need to edit anything below here.
61
 
#
62
 
 
63
 
CC = gcc
64
 
PROG = ntop
65
 
CCOPT =  -O
66
 
INCLS = -I. $(INC_GDBM) $(INC_WPDPACK) $(INC_WPDPACK)/NET $(INC_GDCHART)
67
 
DEFS =  -DHAVE_FCNTL_H=1 -DHAVE_PCAP_H=1 -DHAVE_STDARG_H=1
68
 
 
69
 
# Standard CFLAGS
70
 
CFLAGS = $(CCOPT) $(DEFS) $(INCLS)
71
 
 
72
 
# Standard LDFLAGS
73
 
LDFLAGS =  $(LDIRS) 
74
 
 
75
 
# Standard LIBS
76
 
LIBS = -lgdbm -lwpcap -lgdchart -lgd -lpng -lz -lwsock32
77
 
 
78
 
 
79
 
INSTALL = /usr/bin/install -c -o root -g wheel
80
 
 
81
 
# Explicitly define compilation rule since SunOS 4's make doesn't like gcc.
82
 
# Also, gcc does not remove the .o before forking 'as', which can be a
83
 
# problem if you don't own the file but can write to the directory.
84
 
.c.o:
85
 
        @rm -f $@
86
 
        $(CC) $(CFLAGS) -o $@ -c $<
87
 
 
88
 
CSRC =  ntop.c pbuf.c util.c http.c vendor.c report.c qsort.c \
89
 
        globals-core.c globals-report.c address.c admin.c \
90
 
        dataFormat.c emitter.c event.c graph.c hash.c \
91
 
        initialize.c leaks.c logger.c main.c ntop_win32.c \
92
 
        reportUtils.c traffic.c plugin.c webInterface.c term.c \
93
 
        netflow.c sql.c rules.c plugins/icmpPlugin.c \
94
 
        plugins/lastSeenPlugin.c plugins/nfsPlugin.c \
95
 
        plugins/rmonPlugin.c plugins/wapPlugin.c regex.c
96
 
GENSRC = version.c
97
 
 
98
 
SRC =   $(CSRC) $(GENSRC)
99
 
 
100
 
# We would like to say "OBJ = $(SRC:.c=.o)" but Ultrix's make cannot
101
 
# hack the extra indirection
102
 
OBJ =   $(CSRC:.c=.o) $(GENSRC:.c=.o) #@LIBOBJS@
103
 
HDR =   interface.h machdep.h
104
 
 
105
 
CLEANFILES = $(PROG) $(OBJ) $(GENSRC)
106
 
 
107
 
all: $(PROG)
108
 
 
109
 
$(PROG): $(OBJ)
110
 
        @rm -f $@
111
 
        $(CC) $(CCOPT) $(LDFLAGS) -o $@ $(OBJ) $(LIBS)
112
 
 
113
 
version.o: version.c
114
 
version.c:
115
 
        -rm $@
116
 
        echo "char version[] = \"$(VERSION)\";" > $@
117
 
        echo "char osName[]  = \"$(OSNAME)\";" >> $@
118
 
        echo "char author[]  = \"Luca Deri <deri@unipi.it>\";" >> $@
119
 
 
120
 
ntop.c: ntop.h
121
 
pbuf.c: ntop.h
122
 
util.c: ntop.h
123
 
http.c: ntop.h
124
 
report.c: ntop.h
125
 
 
126
 
install:
127
 
        $(INSTALL) -m 6550 $(PROG) $(DESTDIR)$(BINDEST)/$(PROG)
128
 
 
129
 
install-man:
130
 
        $(INSTALL) -m 444 $(PROG).8 $(DESTDIR)$(MANDEST)/man8/$(PROG).8
131
 
 
132
 
clean:
133
 
        rm -f $(CLEANFILES) 
134
 
 
135
 
distclean:
136
 
        rm -f $(CLEANFILES) core Makefile config.cache config.log config.status *~ #*
137
 
 
138
 
depend: $(GENSRC)
139
 
        ./mkdep -c $(CC) $(DEFS) $(INCLS) $(SRC)
140
 
 
141
 
ntop.html: ntop.8
142
 
        @echo " " > ntop.tmp
143
 
        @groff -mandoc -Tascii ntop.8 >> ntop.tmp
144
 
        @cat ntop.tmp | man2html > ntop.html
145
 
        @rm -f ntop.tmp
146
 
 
147
 
make-rpm: ntop ntop.html
148
 
        echo "Only root can do this. Wait please...."
149
 
        cp ntop packages/rpm/sbin
150
 
        cp -r ntop.html html/* packages/rpm/etc/ntop/html
151
 
        chown -R root.sys packages/rpm
152
 
        cp -pr CHANGES COPYING FAQ FILES INSTALL README TO_DO VERSION ntop.html /usr/src/redhat/BUILD
153
 
        chmod goux packages/rpm/sbin/ntop
154
 
        chmod us packages/rpm/sbin/ntop
155
 
        cp ntop.8 packages/rpm/usr/man/man8
156
 
        rpm -bb packages/rpm/ntop-$(VERSION)-1.spec
157
 
        mv /usr/src/redhat/RPMS/$(MACHTYPE)/ntop-$(VERSION)-1.$(MACHTYPE).rpm packages
158
 
        rm packages/rpm/sbin/ntop
159
 
        rm packages/rpm/usr/man/man8/ntop.8
160
 
 
161
 
make-suse: ntop ntop.html
162
 
        echo "Only root can do this. Wait please...."
163
 
        cp ntop packages/rpm/sbin
164
 
        cp -r ntop.html html/* packages/rpm/etc/ntop/html
165
 
        chown -R root.sys packages/rpm
166
 
        cp -pr CHANGES COPYING FAQ FILES INSTALL README TO_DO VERSION ntop.html /usr/src/packages/BUILD
167
 
        chmod goux packages/rpm/sbin/ntop
168
 
        chmod us packages/rpm/sbin/ntop
169
 
        cp ntop.8 packages/rpm/usr/man/man8
170
 
        rpm -bb packages/rpm/ntop-$(VERSION)-1.spec
171
 
        mv /usr/src/packages/RPMS/$(HOSTTYPE)/ntop-$(VERSION)-1.suse-$(HOSTTYPE).rpm packages
172
 
        rm packages/rpm/sbin/ntop
173
 
        rm packages/rpm/usr/man/man8/ntop.8
174
 
 
175
 
make-deb: ntop ntop.html
176
 
        echo "Only root can do this. Wait please...."
177
 
        cp ntop packages/debian/sbin
178
 
        cp -r ntop.html html/* packages/debian/etc/ntop/html
179
 
        chown root.sys packages/debian/sbin/ntop
180
 
        chmod goux packages/debian/sbin/ntop
181
 
        chmod us packages/debian/sbin/ntop
182
 
        cp ntop.8 packages/debian/usr/man/man8
183
 
        gzip packages/debian/usr/man/man8/ntop.8
184
 
        dpkg-deb -b packages/debian packages/ntop-$(VERSION)-$(OSNAME).deb
185
 
        rm packages/debian/sbin/ntop
186
 
        rm packages/debian/usr/man/man8/ntop.8.gz
187
 
 
188
 
make-generic: ntop ntop.html
189
 
        cp ntop packages/generic/sbin
190
 
        cp -r ntop.html html/* packages/generic/etc/ntop/html
191
 
        chown root.sys packages/generic/sbin/ntop
192
 
        chmod goux packages/generic/sbin/ntop
193
 
        chmod us packages/generic/sbin/ntop
194
 
        cp ntop.8 packages/generic/usr/man/man8
195
 
        gzip packages/generic/usr/man/man8/ntop.8
196
 
        cd packages/generic; tar cvf - . > ../ntop-$(VERSION)-$(OSNAME).tar
197
 
        compress packages/ntop-$(VERSION)-$(OSNAME).tar
198
 
        rm packages/generic/sbin/ntop
199
 
        rm packages/generic/usr/man/man8/ntop.8.gz
200
 
        rm packages/generic/etc/ntop/html/*
201
 
 
202
 
make-slack: ntop ntop.html
203
 
        echo "Only root can do this. Wait please...."
204
 
        cp ntop packages/slackware/sbin
205
 
        cp -r ntop.html html/* packages/slackware/etc/ntop/html
206
 
        chown root.sys packages/slackware/sbin/ntop
207
 
        chmod goux packages/slackware/sbin/ntop
208
 
        chmod us packages/slackware/sbin/ntop
209
 
        cp ntop.8 packages/slackware/usr/man/man8
210
 
        gzip packages/slackware/usr/man/man8/ntop.8
211
 
        cd packages/slackware; tar cvfz - . > ../ntop-$(VERSION)-slackware.tgz
212
 
        mv packages/ntop-$(VERSION)-slackware.tgz packages/slackware
213
 
        rm packages/slackware/sbin/ntop
214
 
        rm packages/slackware/usr/man/man8/ntop.8.gz
215
 
        rm packages/slackware/etc/ntop/html/*
216
 
        echo "The package file is under packages/slackware: have fun!"
217
 
 
218
 
 
219
 
make-bsd: ntop ntop.html
220
 
        echo "Only root can do this. Wait please...."
221
 
        cp ntop packages/freebsd/sbin
222
 
        cp -r ntop.html html/* packages/freebsd/etc/ntop/html
223
 
        chown root.sys packages/freebsd/sbin/ntop
224
 
        chmod goux packages/freebsd/sbin/ntop
225
 
        chmod us packages/freebsd/sbin/ntop
226
 
        cp ntop.8 packages/freebsd/usr/man/man8
227
 
        gzip packages/freebsd/usr/man/man8/ntop.8
228
 
        cd packages/freebsd; tar cvfz - . > ../ntop-$(VERSION)-freebsd.tgz
229
 
        mv packages/ntop-$(VERSION)-freebsd.tgz packages/freebsd
230
 
        rm packages/freebsd/sbin/ntop
231
 
        rm packages/freebsd/usr/man/man8/ntop.8.gz
232
 
        rm packages/freebsd/etc/ntop/html/*
233
 
        echo "The package file is under packages/freebsd: have fun!"
234
 
 
235
 
 
236
 
make-solaris: ntop ntop.html
237
 
        echo "Only root can do this. Wait please...."
238
 
        /bin/rm -rf /opt/ntop
239
 
        /bin/rm -rf /var/spool/ntop
240
 
        mkdir -p /opt/ntop/bin
241
 
        mkdir -p /opt/ntop/man/man8
242
 
        mkdir -p /opt/ntop/etc/ntop/html
243
 
        cp ntop /opt/ntop/bin
244
 
        cp -r ntop.html html/* /opt/ntop/etc/ntop/html
245
 
        chown -R bin /opt/ntop
246
 
        chgrp -R bin /opt/ntop
247
 
        chmod goux /opt/ntop/bin/ntop
248
 
        chmod us /opt/ntop/bin/ntop
249
 
        cp ntop.8 /opt/ntop/man/man8
250
 
        cd /opt/ntop; find . -print | pkgproto > prototype
251
 
        echo "i pkginfo=/opt/ntop/pkginfo" >> prototype
252
 
        cat /opt/ntop/prototype >> prototype
253
 
        mv prototype /opt/ntop/prototype
254
 
        cp packages/solaris/ntop/pkginfo /opt/ntop
255
 
        cd /opt/ntop; pkgmk -o -r `pwd`
256
 
        cd /var/spool/pkg; pkgtrans -o -s `pwd` /tmp/ntop-$(VERSION)-solaris.$(MACHTYPE)
257
 
        cd /tmp; gzip ntop-$(VERSION)-solaris.$(MACHTYPE)
258
 
        /bin/rm -rf /opt/ntop
259
 
        /bin/rm -rf /var/spool/ntop
260
 
        echo "The package file is in /tmp/ntop-$(VERSION)-solaris.$(MACHTYPE).gz: have fun!"