]> git.pld-linux.org Git - packages/cflowd.git/blame - cflowd.spec
- add djp patch which is needed by flowscan
[packages/cflowd.git] / cflowd.spec
CommitLineData
fb20d4d2 1Summary: Traffic Flow Analysis Tool
a3b05e6e 2Name: cflowd
fb20d4d2
AM
3Version: 2.1.b1
4Release: 1
5Epoch: 0
a3b05e6e 6License: GPL
fb20d4d2 7Obsoletes: cflowd0-devel
a3b05e6e 8Group: Applications/Networking
fb20d4d2
AM
9Source0: ftp://ftp.caida.org/pub/cflowd/%{name}-2-1-b1.tar.gz
10# Source0-md5: 6f0543390e9d46c4274f6b12b6517f62
11Source1: %{name}.init
12Patch0: %{name}-yywrap.patch
a464b626
AM
13# http://net.doit.wisc.edu/~plonka/cflowd/cflowd-2-1-b1-djp.patch
14Patch1: http://net.doit.wisc.edu/~plonka/cflowd/cflowd-djp.patch
a3b05e6e 15BuildRequires: arts++-devel
fb20d4d2
AM
16BuildRequires: flex
17BuildRequires: bison
18BuildRequires: perl-base
a3b05e6e
AM
19URL: http://www.caida.org/tools/measurement/cflowd/
20BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21
fb20d4d2
AM
22%define _sysconfdir /etc/%{name}
23
a3b05e6e 24%description
fb20d4d2
AM
25cflowd is a flow analysis tool currently used for analyzing Cisco's
26NetFlow enabled switching method. The current release (described
27below) includes the collections, storage, and basic analysis modules
28for cflowd and for arts++ libraries. This analysis package permits
29data collection and analysis by ISPs and network engineers in support
30of capacity planning, trends analysis, and characterization of
31workloads in a network service provider environment. Other areas where
32cflowd may prove useful include usage tracking for Web hosting,
33accounting and billing, network planning and analysis, network
34monitoring, developing user profiles, data warehousing and mining, as
35well as security-related investigations.
36
37%package libs
38Summary: cflowd libraries
39Group: Libraries
40
41%description libs
42cflowd libraries.
43
44%package devel
45Summary: Header files and develpment documentation for cflowd
46Group: Development/Libraries
47Requires: %{name}-libs = %{epoch}:%{version}
48
49%description devel
50Header files and develpment documentation for cflowd.
51
52%package static
53Summary: Static cflowd libraries
54Group: Development/Libraries
55Requires: %{name} = %{epoch}:%{version}
56
57%description static
58Static cflowd libraries.
a3b05e6e
AM
59
60%prep
61%setup -q -n %{name}-2-1-b1
fb20d4d2 62%patch0 -p1
a464b626 63%patch1 -p0
a3b05e6e
AM
64
65%build
fb20d4d2
AM
66chmod u+w *.m4 configure
67%{__libtoolize}
68%{__aclocal}
69%{__autoconf}
70%configure \
71 --enable-shared
72
73perl -pi -e 's#libtool#libtool --tag=CXX#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile*
74perl -pi -e 's#/usr/local/arts/include/#%{_includedir}/arts++/#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile*
75
76%{__make} \
77 ARTSPPINC="-I%{_includedir}/arts++" \
78 ARTSCLASSINC="-I%{_includedir}/arts++" \
79 CC="%{__cc}" \
80 CXX="%{__cxx}"
a3b05e6e
AM
81
82%install
83rm -rf $RPM_BUILD_ROOT
fb20d4d2
AM
84install -d $RPM_BUILD_ROOT{/etc/rc.d/init.d,/var/lib/cflowd}
85
86perl -pi -e 's#/usr/include#\$\(includedir\)/%{name}#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile* */*/*/*/Makefile*
87perl -pi -e 's#\$\(includedir\)/%{name}/arts\+\+#/usr/include/arts\+\+#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile* */*/*/*/Makefile*
88perl -pi -e 's#/usr/lib#\$\(libdir\)#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile* */*/*/*/Makefile*
89perl -pi -e 's#/usr/bin#\$\(bindir\)#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile* */*/*/*/Makefile*
90perl -pi -e 's#/usr/sbin#\$\(sbindir\)#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile* */*/*/*/Makefile*
91perl -pi -e 's#/usr/share/man#\$\(mandir\)#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile* */*/*/*/Makefile*
92perl -pi -e 's#/etc/%{name}#\$\(sysconfdir\)#g' Makefile* */Makefile* */*/Makefile* */*/*/Makefile* */*/*/*/Makefile*
a3b05e6e 93
fb20d4d2 94%{makeinstall}
a3b05e6e 95
fb20d4d2
AM
96install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
97
98cp -f $RPM_BUILD_ROOT%{_sysconfdir}/cfdcollect.conf.example $RPM_BUILD_ROOT%{_sysconfdir}/cfdcollect.conf
99cp -f $RPM_BUILD_ROOT%{_sysconfdir}/cflowd.conf.example $RPM_BUILD_ROOT%{_sysconfdir}/cflowd.conf
a3b05e6e
AM
100
101%clean
102rm -rf $RPM_BUILD_ROOT
103
fb20d4d2
AM
104%post
105/sbin/chkconfig --add %{name}
106if [ -f /var/lock/subsys/%{name} ]; then
107 /etc/rc.d/init.d/%{name} restart 1>&2
108else
109 echo "Run \"/etc/rc.d/init.d/%{name} start\" to start %{name} service."
110fi
111
112%preun
113if [ "$1" = "0" ]; then
114 if [ -f /var/lock/subsys/%{name} ]; then
115 /etc/rc.d/init.d/%{name} stop 1>&2
116 fi
117 /sbin/chkconfig --del %{name}
118fi
119
120%post libs -p /sbin/ldconfig
121%postun libs -p /sbin/ldconfig
122
a3b05e6e
AM
123%files
124%defattr(644,root,root,755)
fb20d4d2
AM
125%doc ChangeLog README doc/configuration/{*.html,*.gif}
126%attr(754,root,root) /etc/rc.d/init.d/%{name}
a3b05e6e 127%attr(755,root,root) %{_bindir}/*
fb20d4d2
AM
128%attr(755,root,root) %{_sbindir}/*
129%{_mandir}/man?/*
130%attr(750,root,root) %dir %{_sysconfdir}
131%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.conf
132%attr(750,root,root) /var/lib/%{name}
133
134%files libs
135%defattr(644,root,root,755)
136%attr(755,root,root) %{_libdir}/lib*.so.*
137
138%files devel
139%defattr(644,root,root,755)
140%{_includedir}/%{name}
141%attr(755,root,root) %{_libdir}/lib*.so
142%{_libdir}/lib*.la
143
144%files static
145%defattr(644,root,root,755)
146%{_libdir}/lib*.a
This page took 0.068703 seconds and 4 git commands to generate.