2 # - make noarch -n mibs-net-snmp package (need separate .spec then)
3 # - FHS: #define NETSNMP_AGENTX_SOCKET "/var/agentx/master"
6 %bcond_without rpm # RPM support
7 %bcond_without kerberos5 # Kerberos support
8 %bcond_without lm_sensors # LM sensors support
9 %bcond_without perl # Perl modules and utils
10 %bcond_without python # Python (3.x) modules
11 %bcond_without python2 # Python 2.x modules
12 %bcond_without static_libs # static library
14 %ifnarch %{ix86} %{x8664} x32
15 %undefine with_lm_sensors
19 Summary: A collection of SNMP protocol tools
20 Summary(es.UTF-8): Agente SNMP de la UCD
21 Summary(pl.UTF-8): Kolekcja narzędzi do obsługi protokołu SNMP
22 Summary(pt_BR.UTF-8): Agente SNMP da UCD
23 Summary(ru.UTF-8): Набор утилит для протокола SNMP от UC-Davis
24 Summary(uk.UTF-8): Набір утиліт для протоколу SNMP від UC-Davis
29 Group: Networking/Daemons
30 Source0: http://downloads.sourceforge.net/net-snmp/%{name}-%{version}.tar.gz
31 # Source0-md5: 382da80138897f294299badf9c62c699
32 Source1: %{name}d.init
33 Source2: %{name}d.conf
34 Source3: %{name}d.sysconfig
35 Source4: %{name}trapd.init
36 Source5: %{name}trapd.conf
37 Source6: %{name}trapd.sysconfig
38 Source7: ucd-ipchains.tar.gz
39 # Source7-md5: 29949f1008f1a04d6efefd5b3ea607da
40 Source9: snmpd.logrotate
41 Patch0: %{name}-acfix.patch
42 Patch1: %{name}-rpm-implicit-libs.patch
43 Patch2: %{name}-config-noflags.patch
44 Patch3: %{name}-manpage.patch
45 Patch4: %{name}-link.patch
46 Patch6: %{name}-kernel_headers.patch
47 Patch7: %{name}-rpmpath.patch
48 Patch8: %{name}-python.patch
49 Patch9: %{name}-lvalue.patch
50 Patch10: %{name}-defaultconfig.patch
51 Patch11: %{name}-use-rpm-hrmib.patch
52 Patch12: %{name}-TCP_STATS_CACHE_TIMEOUT.patch
53 Patch13: %{name}-logging.patch
54 Patch14: %{name}-Remove-U64-typedef.patch
55 Patch15: 1314610.patch
56 URL: http://www.net-snmp.org/
57 BuildRequires: autoconf >= 2.63
58 BuildRequires: automake
59 BuildRequires: elfutils-devel
60 %{?with_kerberos5:BuildRequires: heimdal-devel}
61 BuildRequires: libnl-devel >= 1:3.2
62 BuildRequires: libpcap-devel
63 BuildRequires: libssh2-devel
64 BuildRequires: libtool >= 1.4
65 BuildRequires: libwrap-devel
66 %{?with_lm_sensors:BuildRequires: lm_sensors-devel >= 3.0.1}
67 BuildRequires: ncurses-devel
68 BuildRequires: openssl-devel >= 0.9.7d
69 BuildRequires: pciutils-devel
70 BuildRequires: pcre-devel
71 BuildRequires: perl-devel >= 1:5.8.0
72 BuildRequires: pkgconfig >= 1:0.9.0
75 BuildRequires: python-devel >= 1:2.5
76 BuildRequires: python-modules >= 1:2.5
77 BuildRequires: python-setuptools
79 BuildRequires: python3-devel >= 1:3.2
80 BuildRequires: python3-modules >= 1:3.2
81 BuildRequires: python3-setuptools
82 BuildRequires: rpm-pythonprov
86 BuildRequires: rpm-perlprov >= 3.0.3-16
88 BuildRequires: rpmbuild(macros) >= 1.527
89 Requires(post,preun): /sbin/chkconfig
90 Requires: %{name}-agent-libs = %{version}-%{release}
91 Requires: %{name}-libs = %{version}-%{release}
92 Requires: /usr/bin/setsid
93 Requires: mibs-%{name} = %{version}-%{release}
94 Requires: rc-scripts >= 0.4.3.0
99 Conflicts: pciutils < 3.1.7-5
100 Conflicts: rpm < 4.4.9-43.11
101 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
103 # linking libraries is ugly in this package
104 %define no_install_post_check_so 1
106 %define logfile /var/log/snmpd.log
109 SNMP (Simple Network Management Protocol) is a protocol used for
110 network management (hence the name). The net-snmp project includes
111 various SNMP tools: an extensible agent, an SNMP library, tools for
112 requesting or setting information from SNMP agents, tools for
113 generating and handling SNMP traps, a version of the netstat command
114 which uses SNMP, and a Tk/Perl mib browser. This package contains the
115 snmpd daemon, documentation, etc.
117 %description -l es.UTF-8
118 Este paquete se deriva de la implementación del Protocolo Simple de
119 Gestión de Redes versión 2 (SNMPv2) de la Universidad Carnegie Mellon.
120 Útil para administrar redes y hacer contabilidad.
122 %description -l pl.UTF-8
123 SNMP (Simple Network Management Protocol) jest protokołem używanym do
124 zarządzania sieciami. Pakiet zawiera narzędzia: rozbudowywalnego
125 agenta, bibliotekę SNMP, narzędzia do odpytywania oraz ustawiania
126 informacji poprzez agentów SNMP, narzędzia do generowania i obsługi
127 pułapek SNMP, wersję komendy netstat używającą SNMP, przeglądarkę mib
128 w Tk/Perl, demona, dokumentację itp.
130 %description -l pt_BR.UTF-8
131 Este pacote é derivado da implementação do Protocolo Simples de
132 Gerenciamento de Redes versão 2 (SNMPv2) da Universidade Carnegie
133 Mellon. Útil para gerenciar redes e fazer contabilidade.
135 %description -l ru.UTF-8
136 SNMP (Simple Network Management Protocol) - это протокол, используемый
137 для управления сетью (отсюда и название). Проект net-snmp включает
138 разнообразные SNMP-утилиты: расширяемый агент, библиотека SNMP,
139 утилиты для запроса или установки информации от SNMP-агентов, утилиты
140 для генерации и обработки SNMP-трапов, версия команды netstat,
141 использующей SNMP, и mib-браузер на Tk/Perl. Этот пакет содержит
142 демоны snmpd и snmptrapd, документацию и т.д.
144 %description -l uk.UTF-8
145 SNMP (Simple Network Management Protocol) - це протокол, який
146 використовують для керування мережею (звідси і назва). Проект net-snmp
147 містить різноманітні SNMP-утиліти: розширюваний агент, бібліотека
148 SNMP, утиліти для запросу та встановлення інформації від NMP-агентів,
149 утиліти для генерації та обробки SNMP-трапів, версія команди netstat,
150 яка використовує SNMP, та mib-браузер на Tk/Perl. Цей пакет містить
151 демони snmpd та snmptrapd, документацію і т.і.
154 Summary: NET SNMP libraries
155 Summary(pl.UTF-8): Biblioteki SNMP
157 Suggests: mibs-%{name}
158 Obsoletes: net-snmp-compat-libs
159 Obsoletes: ucd-snmp-libs
164 %description libs -l pl.UTF-8
168 Summary: The NET-SNMP runtime agent libraries
169 Summary(pl.UTF-8): Biblioteki uruchomieniowe agenta NET-SNMP
171 Requires: %{name}-libs = %{version}-%{release}
173 %description agent-libs
174 The net-snmp-agent-libs package contains the runtime agent libraries
175 for shared binaries and applications.
177 %description agent-libs -l pl.UTF-8
178 Ten pakiet zawiera biblioteki uruchomieniowe agenta SNMP.
181 Summary: The development environment for the net-snmp project
182 Summary(es.UTF-8): Archivos de inclusión y bibliotecas para desarrollo en el SNMP de la UCD
183 Summary(pl.UTF-8): Pliki dla programistów używających bibliotek net-snmp
184 Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas para desenvolvimento no SNMP da UCD
185 Summary(ru.UTF-8): Среда разработки для проекта NET-SNMP
186 Summary(uk.UTF-8): Середовище розробки для проекту NET-SNMP
187 Group: Development/Libraries
188 Requires: %{name}-agent-libs = %{version}-%{release}
189 Requires: %{name}-libs = %{version}-%{release}
190 Requires: elfutils-devel
191 %{?with_kerberos5:Requires: heimdal-devel}
192 Requires: libnl-devel >= 1:3.2
193 Requires: libwrap-devel
194 %{?with_lm_sensors:Requires: lm_sensors-devel >= 3.0.1}
195 Requires: openssl-devel >= 0.9.7c
196 Requires: pciutils-devel
197 Obsoletes: ucd-snmp-devel
200 The ucd-snmp-devel package contains the development libraries and
201 header files for use with the net-snmp project's network management
204 %description devel -l es.UTF-8
205 Estas son las bibliotecas y archivos de inclusión para desarrollo con
206 el SNMP de la UCD. Con este paquete es posible la creación de
207 programas para uso en la gestión de redes.
209 %description devel -l pl.UTF-8
210 Pakiet zawiera pliki nagłówkowe i biblioteki potrzebne do rozwoju
211 aplikacji używających protokołu SNMP.
213 %description devel -l pt_BR.UTF-8
214 Estas são as bibliotecas e arquivos de inclusão para desenvolvimento
215 com o SNMP da UCD. Com este pacote é possível a criação de programas
216 para uso no gerenciamento de redes.
218 %description devel -l ru.UTF-8
219 Пакет ucd-snmp-devel содержит библиотеки разработчика и хедера для
220 использования с утилитами управления сетью проекта net-snmp.
222 %description devel -l uk.UTF-8
223 Пакет ucd-snmp-devel містить бібліотеки програміста та хедери для
224 використання з утилітами керування мережею проекту net-snmp.
227 Summary: Static net-snmp libraries
228 Summary(pl.UTF-8): Statyczne biblioteki net-snmp
229 Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com ucd-snmp
230 Summary(ru.UTF-8): Статические библиотеки для проекта net-snmp
231 Summary(uk.UTF-8): Статичні бібліотеки для проекту net-snmp
232 Group: Development/Libraries
233 Requires: %{name}-devel = %{version}-%{release}
234 Obsoletes: ucd-snmp-static
237 Static net-snmp libraries.
239 %description static -l pl.UTF-8
240 Statyczne biblioteki net-snmp.
242 %description static -l pt_BR.UTF-8
243 Bibliotecas estáticas para desenvolvimento com net-snmp.
245 %package compat-devel
246 Summary: The development environment for the NET-SNMP project
247 Summary(es.UTF-8): Archivos de inclusión y bibliotecas para desarrollo en el SNMP de la UCD
248 Summary(pl.UTF-8): Pliki dla programistów używających bibliotek NET-SNMP
249 Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas para desenvolvimento no SNMP da UCD
250 Summary(ru.UTF-8): Среда разработки для проекта NET-SNMP
251 Summary(uk.UTF-8): Середовище розробки для проекту NET-SNMP
252 Group: Development/Libraries
253 Requires: %{name}-devel = %{version}-%{release}
254 Requires: openssl-devel >= 0.9.7d
255 Obsoletes: cmu-snmp-devel
256 Obsoletes: ucd-snmp-devel
258 %description compat-devel
259 The ucd-snmp-devel package contains the development libraries and
260 header files for use with the NET-SNMP project's network management
263 %description compat-devel -l es.UTF-8
264 Estas son las bibliotecas y archivos de inclusión para desarrollo con
265 el SNMP de la UCD. Con este paquete es posible la creación de
266 programas para uso en la gestión de redes.
268 %description compat-devel -l pl.UTF-8
269 Pakiet zawiera pliki nagłówkowe i biblioteki potrzebne do rozwoju
270 aplikacji używających protokołu SNMP.
272 %description compat-devel -l pt_BR.UTF-8
273 Estas são as bibliotecas e arquivos de inclusão para desenvolvimento
274 com o SNMP da UCD. Com este pacote é possível a criação de programas
275 para uso no gerenciamento de redes.
277 %description compat-devel -l ru.UTF-8
278 Пакет ucd-snmp-devel содержит библиотеки разработчика и хедера для
279 использования с утилитами управления сетью проекта NET-SNMP.
281 %description compat-devel -l uk.UTF-8
282 Пакет ucd-snmp-devel містить бібліотеки програміста та хедери для
283 використання з утилітами керування мережею проекту NET-SNMP.
285 %package compat-static
286 Summary: Static NET-SNMP libraries
287 Summary(pl.UTF-8): Statyczne biblioteki NET-SNMP
288 Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com ucd-snmp
289 Summary(ru.UTF-8): Статические библиотеки для проекта NET-SNMP
290 Summary(uk.UTF-8): Статичні бібліотеки для проекту NET-SNMP
291 Group: Development/Libraries
292 Requires: %{name}-compat-devel = %{version}-%{release}
293 Obsoletes: ucd-snmp-static
295 %description compat-static
296 Static NET-SNMP libraries.
298 %description compat-static -l pl.UTF-8
299 Statyczne biblioteki NET-SNMP.
301 %description compat-static -l pt_BR.UTF-8
302 Bibliotecas estáticas para desenvolvimento com ucd-snmp.
304 %package -n mibs-net-snmp
305 Summary: Net-SNMP provided MIBs
306 Summary(pl.UTF-8): Baza danych MIB
307 Group: Applications/System
309 Obsoletes: net-snmp-mibs
310 Conflicts: ucd-snmp-libs
311 %if "%{_rpmversion}" >= "5"
315 %description -n mibs-net-snmp
316 Net-SNMP provided MIBs (Management Information Base).
318 %description -n mibs-net-snmp -l pl.UTF-8
322 Summary: SNMP trap daemon
323 Summary(pl.UTF-8): Demon obsługujący pułapki SNMP
324 Group: Applications/System
325 Requires(post,preun): /sbin/chkconfig
326 Requires: %{name} = %{version}-%{release}
327 Requires: rc-scripts >= 0.2.0
328 Obsoletes: cmu-snmp-utils
329 Obsoletes: ucd-snmp-snmptrapd
331 %description snmptrapd
332 The ucd-snmp-snmptrapd package contains snmp trap daemon.
334 %description snmptrapd -l pl.UTF-8
335 Pakiet zawiera demon obsługujący pułapki SNMP.
338 Summary: Network management utilities using SNMP, from the NET-SNMP project
339 Summary(es.UTF-8): Utilitarios del SNMP de la UCD
340 Summary(pl.UTF-8): Narzędzia używające protokołu SNMP
341 Summary(pt_BR.UTF-8): Utilitários do SNMP da UCD
342 Summary(ru.UTF-8): Утилиты управления сетью по SNMP из проекта NET-SNMP
343 Summary(uk.UTF-8): Утиліти керування мережею по SNMP з проекту NET-SNMP
344 Group: Applications/System
345 Requires: %{name}-libs = %{version}-%{release}
346 Requires: %{name}-agent-libs = %{version}-%{release}
347 Suggests: mibs-%{name} = %{version}-%{release}
348 Obsoletes: cmu-snmp-utils
349 Obsoletes: ucd-snmp-utils
352 This package contains various utilities for managing your network
353 using the SNMP protocol.
355 %description utils -l es.UTF-8
356 Varios utilitarios para uso con el SNMP de la UCD. Contiene
357 utilitarios como: snmpwalk, snmptest y otros.
359 %description utils -l pl.UTF-8
360 Różnego rodzaju narzędzia do zarządzania siecią przy użyciu protokołu
363 %description utils -l pt_BR.UTF-8
364 Vários utilitários para uso com o SNMP da UCD. Contém utilitários
365 como: snmpwalk, snmptest e outros.
367 %description utils -l ru.UTF-8
368 Пакет ucd-snmp-utils содержит разнообразные утилиты для использования
369 в проекте управления сетью net-snmp.
371 %description utils -l uk.UTF-8
372 Пакет ucd-snmp-utils містить різноманітні утиліти для використання в
373 проекті керування мережею net-snmp.
375 %package -n perl-SNMP
376 Summary: SNMP and NetSNMP::* Perl modules
377 Summary(pl.UTF-8): Moduły Perla SNMP oraz NetSNMP::*
378 Group: Development/Languages/Perl
379 Requires: %{name}-agent-libs = %{version}-%{release}
380 Requires: %{name}-libs = %{version}-%{release}
381 Conflicts: ucd-snmp-utils-perl
383 %description -n perl-SNMP
384 SNMP and NetSNMP::* Perl modules - Perl interface to net-snmp.
386 %description -n perl-SNMP -l pl.UTF-8
387 Moduły Perla SNMP oraz NetSNMP::* - perlowy interfejs do net-snmp.
390 Summary: Perl utilities for network management using SNMP
391 Summary(pl.UTF-8): Perlowe narzędzia używające protokołu SNMP
392 Group: Applications/System
393 Requires: perl-SNMP = %{version}-%{release}
394 Obsoletes: cmu-snmp-utils
395 Obsoletes: ucd-snmp-utils-perl
397 %description utils-perl
398 This package contains various Perl utilities for managing your network
399 using the SNMP protocol.
401 %description utils-perl -l pl.UTF-8
402 Perlowe narzędzia do zarządzania siecią przy użyciu protokołu SNMP.
405 Summary: snmpconf - creating and modifying SNMP configuration files
406 Summary(pl.UTF-8): snmpconf - tworzenie i modyfikowanie plików konfiguracyjnych SNMP
407 Group: Applications/System
408 Requires: %{name} = %{version}-%{release}
409 Requires: perl-SNMP = %{version}-%{release}
411 %description snmpconf
412 snmpconf is a simple Perl script that walks you through setting up a
413 configuration file step by step. It should be fairly straight forward
416 %description snmpconf -l pl.UTF-8
417 snmpconf to prosty skrypt Perla pozwalający na tworzenie pliku
418 konfiguracyjnego krok po kroku. Powinien być w miarę prosty w użyciu.
421 Summary: MIB browser in Tk
422 Summary(pl.UTF-8): Przeglądarka MIB-ów w Tk
423 Group: Applications/System
424 Requires: perl-SNMP = %{version}-%{release}
430 %description tkmib -l pl.UTF-8
431 Przeglądarka MIB-ów w Tk.
433 %package -n python-netsnmp
434 Summary: Python 2 netsnmp extension module
435 Summary(pl.UTF-8): Moduł rozszerzenia netsnmp dla Pythona 2
436 Group: Libraries/Python
437 Requires: %{name}-libs = %{version}-%{release}
439 %description -n python-netsnmp
440 The 'netsnmp' Python extension module provides a full featured,
441 tri-lingual SNMP (SNMPv3, SNMPv2c, SNMPv1) client API.
443 %description -n python-netsnmp -l pl.UTF-8
444 Moduł rozszerzenia netsnmp dla Pythona udostępnia pełne API klienckie
445 SNMP dla trzech wersji tego protokołu (SNMPv3, SNMPv2c, SNMPv1).
447 %package -n python3-netsnmp
448 Summary: Python 3 netsnmp extension module
449 Summary(pl.UTF-8): Moduł rozszerzenia netsnmp dla Pythona 3
450 Group: Libraries/Python
451 Requires: %{name}-libs = %{version}-%{release}
453 %description -n python3-netsnmp
454 The 'netsnmp' Python extension module provides a full featured,
455 tri-lingual SNMP (SNMPv3, SNMPv2c, SNMPv1) client API.
457 %description -n python3-netsnmp -l pl.UTF-8
458 Moduł rozszerzenia netsnmp dla Pythona udostępnia pełne API klienckie
459 SNMP dla trzech wersji tego protokołu (SNMPv3, SNMPv2c, SNMPv1).
478 %{__sed} -E -i -e '1s,#!\s*/usr/bin/env\s+perl(\s|$),#!%{__perl}\1,' \
479 perl/SNMP/examples/pingmib.pl
490 disman/event disman/schedule \
496 %if %{with lm_sensors}
497 MIBS="$MIBS ucd-snmp/lmsensorsMib"
500 # ksm must be first in --with-security-modules
501 # usm is always enabled
503 ac_cv_path_DPKG_QUERY_PATH= \
505 %{__disable static_libs static} \
506 --with-cflags="%{rpmcflags} %{rpmcppflags} -I/usr/include/et" \
507 --with-ldflags="%{rpmldflags}" \
509 --with-default-snmp-version=3 \
510 %{__with_without kerberos5 krb5} \
513 --with-logfile=%{logfile} \
517 %{__with_without perl perl-modules} \
518 %{__with_without python python-modules} \
519 --enable-local-smux \
520 --with-mibdirs='$HOME/.snmp/mibs:/usr/share/mibs' \
521 --with-mib-modules="$MIBS" \
522 --with-security-modules="%{?with_kerberos5:ksm }tsm" \
523 --with-sys-contact="root@localhost" \
524 --with-sys-location="Unknown" \
525 --with-transports="UDP UDPIPv6 TCP TCPIPv6 Unix Callback Alias DTLSUDP TLSTCP SSH" \
526 --with-persistent-directory="/var/lib/net-snmp" \
527 --enable-ucd-snmp-compatibility \
529 %{!?debug:--disable-debugging} \
530 %{__with_without rpm}
537 %{__perl} -I. Makefile.PL \
538 -NET-SNMP-CONFIG="${TOPDIR}/net-snmp-config" \
539 -NET-SNMP-IN-SOURCE=true \
541 OPTIMIZE="%{rpmcflags} %{rpmcppflags}" \
544 # avoid rpaths generated by MakeMaker
545 %{__perl} -pi -e 's@LD_RUN_PATH="\$\(LD_RUN_PATH\)" @@' */Makefile */*/Makefile
548 LDFLAGS="%{rpmldflags} -L${TOPDIR}/snmplib/.libs/ -L${TOPDIR}/agent/.libs/"
559 rm -rf $RPM_BUILD_ROOT
560 install -d $RPM_BUILD_ROOT{/etc/{rc.d/init.d,logrotate.d,sysconfig,snmp},/var/log,/var/lib/net-snmp,%{_libdir}/snmp/dlmod}
562 %{__make} -j1 install \
563 mibdir=%{_datadir}/mibs \
564 DESTDIR=$RPM_BUILD_ROOT
566 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmpd.conf
567 :> $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmpd.local.conf
568 :> $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmp.conf
569 :> $RPM_BUILD_ROOT%{logfile}
571 install -p %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/snmpd
572 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmpd.conf
573 cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/snmpd
575 install -p %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/snmptrapd
576 cp -p %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmptrapd.conf
577 cp -p %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/snmptrapd
579 cp -p %{SOURCE9} $RPM_BUILD_ROOT/etc/logrotate.d/snmpd
582 %{__make} -j1 install \
583 DESTDIR=$RPM_BUILD_ROOT
585 install -d $RPM_BUILD_ROOT%{_examplesdir}/perl-SNMP-%{version}
586 install -p SNMP/examples/*.pl $RPM_BUILD_ROOT%{_examplesdir}/perl-SNMP-%{version}
589 # IP-Filter (non-Linux)
590 %{__rm} $RPM_BUILD_ROOT%{_bindir}/ipf-mod.pl
592 %{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/Bundle/MakefileSubs.pm
593 rm -f $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod
594 rm -f $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Bundle/NetSNMP/.packlist
596 %if %{with static_libs}
597 # hack: convert DynaLoader.a inside .a file to .o, as strip(1) would otherwise say invalid argument
598 for a in $RPM_BUILD_ROOT%{_libdir}/libnet*.a; do
601 if [ -f DynaLoader.a ]; then
603 ar cr $a DynaLoader.o
605 # remove second file too
610 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libsnmp.a
614 %{__rm} -r $RPM_BUILD_ROOT%{py3_sitedir}/netsnmp/tests
623 %{__rm} -r $RPM_BUILD_ROOT%{py_sitedir}/netsnmp/tests
624 %{__rm} $RPM_BUILD_ROOT%{py_sitedir}/netsnmp/*.py
628 rm -rf $RPM_BUILD_ROOT
633 /sbin/chkconfig --add snmpd
634 %service snmpd restart "snmpd daemon"
637 if [ "$1" = "0" ]; then
639 /sbin/chkconfig --del snmpd
642 %post libs -p /sbin/ldconfig
643 %postun libs -p /sbin/ldconfig
645 %post agent-libs -p /sbin/ldconfig
646 %postun agent-libs -p /sbin/ldconfig
648 %triggerpostun -- ucd-snmp
649 /sbin/chkconfig --add snmpd
654 /sbin/chkconfig --add snmptrapd
655 %service snmptrapd restart "snmp trap daemon"
658 if [ "$1" = "0" ]; then
659 %service snmptrapd stop
660 /sbin/chkconfig --del snmptrapd
663 %triggerpostun snmptrapd -- ucd-snmp-snmptrapd
664 /sbin/chkconfig --add snmptrapd
667 %defattr(644,root,root,755)
668 %doc AGENT.txt CHANGES COPYING ChangeLog EXAMPLE.conf{,.def} FAQ NEWS README{,.agent-mibs,.agentx,.snmpv3,.sql,.thread} TODO local
670 %attr(754,root,root) /etc/rc.d/init.d/snmpd
671 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/snmpd
672 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/snmpd
674 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmpd.conf
675 %attr(640,root,root) %config(missingok,noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmpd.local.conf
677 %attr(755,root,root) %{_sbindir}/snmpd
678 %attr(755,root,root) %{_bindir}/net-snmp-create-v3-user
679 %attr(755,root,root) %{_bindir}/sshtosnmp
681 %dir %{_libdir}/snmp/dlmod
682 %attr(755,root,root) %{_datadir}/snmp/snmp_perl.pl
683 %{_mandir}/man1/net-snmp-create-v3-user.1*
684 %{_mandir}/man5/snmpd.conf.5*
685 %{_mandir}/man5/snmpd.examples.5*
686 %{_mandir}/man5/snmpd.internal.5*
687 %{_mandir}/man5/variables.5*
688 %{_mandir}/man8/snmpd.8*
690 %dir %attr(700,root,root) /var/lib/net-snmp
692 %attr(640,root,root) %ghost %{logfile}
695 %defattr(644,root,root,755)
696 %attr(755,root,root) %{_libdir}/libnetsnmp.so.*.*.*
697 %attr(755,root,root) %ghost %{_libdir}/libnetsnmp.so.%{so_version}
698 %dir %{_sysconfdir}/snmp
699 %dir %{_datadir}/snmp
702 %defattr(644,root,root,755)
703 %attr(755,root,root) %{_libdir}/libnetsnmpagent.so.*.*.*
704 %attr(755,root,root) %ghost %{_libdir}/libnetsnmpagent.so.%{so_version}
705 %attr(755,root,root) %{_libdir}/libnetsnmphelpers.so.*.*.*
706 %attr(755,root,root) %ghost %{_libdir}/libnetsnmphelpers.so.%{so_version}
707 %attr(755,root,root) %{_libdir}/libnetsnmpmibs.so.*.*.*
708 %attr(755,root,root) %ghost %{_libdir}/libnetsnmpmibs.so.%{so_version}
709 %attr(755,root,root) %{_libdir}/libnetsnmptrapd.so.*.*.*
710 %attr(755,root,root) %ghost %{_libdir}/libnetsnmptrapd.so.%{so_version}
713 %defattr(644,root,root,755)
714 %attr(755,root,root) %{_bindir}/mib2c
715 %attr(755,root,root) %{_bindir}/mib2c-update
716 %attr(755,root,root) %{_bindir}/net-snmp-config
717 %attr(755,root,root) %{_libdir}/libnetsnmp.so
718 %attr(755,root,root) %{_libdir}/libnetsnmpagent.so
719 %attr(755,root,root) %{_libdir}/libnetsnmphelpers.so
720 %attr(755,root,root) %{_libdir}/libnetsnmpmibs.so
721 %attr(755,root,root) %{_libdir}/libnetsnmptrapd.so
722 %{_libdir}/libnetsnmp.la
723 %{_libdir}/libnetsnmpagent.la
724 %{_libdir}/libnetsnmphelpers.la
725 %{_libdir}/libnetsnmpmibs.la
726 %{_libdir}/libnetsnmptrapd.la
727 %{_includedir}/net-snmp
728 %{_pkgconfigdir}/netsnmp.pc
729 %{_pkgconfigdir}/netsnmp-agent.pc
730 %{_datadir}/snmp/mib2c*
731 %{_mandir}/man1/mib2c.1*
732 %{_mandir}/man1/mib2c-update.1*
733 %{_mandir}/man1/net-snmp-config.1*
734 %{_mandir}/man3/[!NS]*
735 %{_mandir}/man5/mib2c.conf.5*
737 %if %{with static_libs}
739 %defattr(644,root,root,755)
740 %{_libdir}/libnetsnmp.a
741 %{_libdir}/libnetsnmpagent.a
742 %{_libdir}/libnetsnmphelpers.a
743 %{_libdir}/libnetsnmpmibs.a
744 %{_libdir}/libnetsnmptrapd.a
748 %defattr(644,root,root,755)
749 %attr(755,root,root) %{_libdir}/libsnmp.so
750 %{_libdir}/libsnmp.la
751 %{_includedir}/ucd-snmp
753 %if %{with static_libs}
755 %defattr(644,root,root,755)
759 %files -n mibs-net-snmp
760 %defattr(644,root,root,755)
761 %{_datadir}/mibs/*.txt
764 %defattr(644,root,root,755)
765 %attr(755,root,root) %{_sbindir}/snmptrapd
766 %attr(754,root,root) /etc/rc.d/init.d/snmptrapd
767 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/snmptrapd
768 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmptrapd.conf
770 %attr(755,root,root) %{_datadir}/snmp/snmp_perl_trapd.pl
772 %{_mandir}/man5/snmptrapd.conf.5*
773 %{_mandir}/man8/snmptrapd.8*
776 %defattr(644,root,root,755)
777 %attr(755,root,root) %{_bindir}/agentxtrap
778 %attr(755,root,root) %{_bindir}/encode_keychange
779 %attr(755,root,root) %{_bindir}/snmpbulkget
780 %attr(755,root,root) %{_bindir}/snmpbulkwalk
781 %attr(755,root,root) %{_bindir}/snmpdelta
782 %attr(755,root,root) %{_bindir}/snmpdf
783 %attr(755,root,root) %{_bindir}/snmpget
784 %attr(755,root,root) %{_bindir}/snmpgetnext
785 %attr(755,root,root) %{_bindir}/snmpinform
786 %attr(755,root,root) %{_bindir}/snmpnetstat
787 %attr(755,root,root) %{_bindir}/snmppcap
788 %attr(755,root,root) %{_bindir}/snmpping
789 %attr(755,root,root) %{_bindir}/snmpps
790 %attr(755,root,root) %{_bindir}/snmpset
791 %attr(755,root,root) %{_bindir}/snmpstatus
792 %attr(755,root,root) %{_bindir}/snmptable
793 %attr(755,root,root) %{_bindir}/snmptest
794 %attr(755,root,root) %{_bindir}/snmptls
795 %attr(755,root,root) %{_bindir}/snmptop
796 %attr(755,root,root) %{_bindir}/snmptranslate
797 %attr(755,root,root) %{_bindir}/snmptrap
798 %attr(755,root,root) %{_bindir}/snmpusm
799 %attr(755,root,root) %{_bindir}/snmpvacm
800 %attr(755,root,root) %{_bindir}/snmpwalk
801 %{_mandir}/man1/agentxtrap.1*
802 %{_mandir}/man1/encode_keychange.1*
803 %{_mandir}/man1/snmpbulkget.1*
804 %{_mandir}/man1/snmpbulkwalk.1*
805 %{_mandir}/man1/snmpcmd.1*
806 %{_mandir}/man1/snmpdelta.1*
807 %{_mandir}/man1/snmpdf.1*
808 %{_mandir}/man1/snmpget.1*
809 %{_mandir}/man1/snmpgetnext.1*
810 %{_mandir}/man1/snmpinform.1*
811 %{_mandir}/man1/snmpnetstat.1*
812 %{_mandir}/man1/snmpps.1*
813 %{_mandir}/man1/snmpset.1*
814 %{_mandir}/man1/snmpstatus.1*
815 %{_mandir}/man1/snmptable.1*
816 %{_mandir}/man1/snmptest.1*
817 %{_mandir}/man1/snmptop.1*
818 %{_mandir}/man1/snmptranslate.1*
819 %{_mandir}/man1/snmptrap.1*
820 %{_mandir}/man1/snmpusm.1*
821 %{_mandir}/man1/snmpvacm.1*
822 %{_mandir}/man1/snmpwalk.1*
823 %{_mandir}/man5/snmp.conf.5*
824 %{_mandir}/man5/snmp_config.5*
826 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmp.conf
830 %defattr(644,root,root,755)
831 %doc perl/SNMP/{BUG,README,TODO} perl/SNMP/examples
832 %{perl_vendorarch}/SNMP.pm
833 %{perl_vendorarch}/NetSNMP
834 %dir %{perl_vendorarch}/auto/SNMP
835 %{perl_vendorarch}/auto/SNMP/autosplit.ix
836 %attr(755,root,root) %{perl_vendorarch}/auto/SNMP/SNMP.so
837 %dir %{perl_vendorarch}/auto/NetSNMP
838 %dir %{perl_vendorarch}/auto/NetSNMP/*
839 %{perl_vendorarch}/auto/NetSNMP/*/autosplit.ix
840 %attr(755,root,root) %{perl_vendorarch}/auto/NetSNMP/*/*.so
841 %dir %{perl_vendorarch}/auto/NetSNMP/agent/default_store
842 %{perl_vendorarch}/auto/NetSNMP/agent/default_store/autosplit.ix
843 %attr(755,root,root) %{perl_vendorarch}/auto/NetSNMP/agent/default_store/default_store.so
844 %{_mandir}/man3/NetSNMP::*.3*
845 %{_mandir}/man3/SNMP.3*
846 %{_examplesdir}/perl-SNMP-%{version}
849 %defattr(644,root,root,755)
850 %attr(755,root,root) %{_bindir}/checkbandwidth
851 %attr(755,root,root) %{_bindir}/fixproc
852 %attr(755,root,root) %{_bindir}/net-snmp-cert
853 %attr(755,root,root) %{_bindir}/snmp-bridge-mib
854 %attr(755,root,root) %{_bindir}/snmpcheck
855 %attr(755,root,root) %{_bindir}/traptoemail
856 %{_mandir}/man1/fixproc.1*
857 %{_mandir}/man1/snmp-bridge-mib.1*
858 %{_mandir}/man1/traptoemail.1*
862 %defattr(644,root,root,755)
863 %attr(755,root,root) %{_bindir}/snmpconf
864 %{_mandir}/man1/snmpconf.1*
865 %{_datadir}/snmp/snmpconf-data
869 %defattr(644,root,root,755)
870 %attr(755,root,root) %{_bindir}/tkmib
871 %{_mandir}/man1/tkmib.1*
875 %files -n python-netsnmp
876 %defattr(644,root,root,755)
877 %dir %{py_sitedir}/netsnmp
878 %attr(755,root,root) %{py_sitedir}/netsnmp/client_intf.so
879 %{py_sitedir}/netsnmp/*.py[co]
880 %{py_sitedir}/netsnmp_python-*.egg-info
884 %files -n python3-netsnmp
885 %defattr(644,root,root,755)
886 %dir %{py3_sitedir}/netsnmp
887 %attr(755,root,root) %{py3_sitedir}/netsnmp/client_intf.cpython-*.so
888 %{py3_sitedir}/netsnmp/*.py
889 %{py3_sitedir}/netsnmp/__pycache__
890 %{py3_sitedir}/netsnmp_python-*.egg-info