]> git.pld-linux.org Git - packages/net-snmp.git/blame - net-snmp.spec
- rel 5
[packages/net-snmp.git] / net-snmp.spec
CommitLineData
127848ee 1# TODO: python-netsnmp links with libnetsnmp.so.* installed on builder
ad841d97
JB
2#
3# Conditional build:
4%bcond_without autodeps # don't BR packages only for deps resolving
5#
ea774f60
AF
6%include /usr/lib/rpm/macros.perl
7Summary: A collection of SNMP protocol tools
7d4e48ba
ER
8Summary(es.UTF-8): Agente SNMP de la UCD
9Summary(pl.UTF-8): Kolekcja narzędzi do obsługi protokołu SNMP
10Summary(pt_BR.UTF-8): Agente SNMP da UCD
11Summary(ru.UTF-8): Набор утилит для протокола SNMP от UC-Davis
12Summary(uk.UTF-8): Набір утиліт для протоколу SNMP від UC-Davis
ea774f60 13Name: net-snmp
ee18f99a 14Version: 5.4
27b5f5a2 15Release: 5
ea774f60
AF
16License: BSD-like
17Group: Networking/Daemons
18Source0: http://dl.sourceforge.net/net-snmp/%{name}-%{version}.tar.gz
ee18f99a 19# Source0-md5: 46d893281056ff476e597659cb91574d
ea774f60 20Source1: %{name}d.init
6810e918 21Source2: %{name}d.conf
ea774f60
AF
22Source3: %{name}d.sysconfig
23Source4: %{name}trapd.init
6810e918 24Source5: %{name}trapd.conf
ea774f60 25Source6: %{name}trapd.sysconfig
ee18f99a 26Source7: ucd-ipchains.tar.gz
6789d157 27# Source7-md5: 29949f1008f1a04d6efefd5b3ea607da
ee18f99a
AM
28Patch0: %{name}-acfix.patch
29Patch1: %{name}-rpm-implicit-libs.patch
30Patch2: %{name}-config-noflags.patch
31Patch3: %{name}-dlopen-fix.patch
32Patch4: %{name}-manpage.patch
33Patch5: %{name}-link.patch
34Patch6: %{name}-llinterfaces.patch
35Patch7: %{name}-kernel_headers.patch
36Patch8: %{name}-rpmpath.patch
f42492ff 37Patch9: %{name}-snmpksm.patch
a5fe3234 38Patch10: %{name}-python.patch
b0b507b1 39Patch11: %{name}-python-includes.patch
ea774f60
AF
40URL: http://www.net-snmp.org/
41BuildRequires: autoconf >= 2.57-3
42BuildRequires: automake
e43a09d3 43BuildRequires: elfutils-devel
1eb1198f 44BuildRequires: krb5-devel
ea774f60
AF
45BuildRequires: libtool >= 1.4
46BuildRequires: libwrap-devel
6e818aed 47BuildRequires: lm_sensors-devel
2e25f11c 48BuildRequires: openssl-devel >= 0.9.7d
ad841d97
JB
49%{?with_autodeps:BuildRequires: perl-Term-ReadKey}
50BuildRequires: perl-devel >= 1:5.8.0
a5fe3234 51BuildRequires: python-devel >= 1:2.5
c2ceb56d 52BuildRequires: python-setuptools
ea774f60
AF
53BuildRequires: rpm-devel >= 4.0
54BuildRequires: rpm-perlprov >= 3.0.3-16
e65e8dc4 55BuildRequires: rpmbuild(macros) >= 1.176
fa43c632 56BuildRequires: rpmbuild(macros) >= 1.268
ea774f60 57Requires(post,preun): /sbin/chkconfig
b0389a15 58Requires: %{name}-libs = %{version}-%{release}
ea774f60 59Requires: /usr/bin/setsid
b0389a15 60Requires: rc-scripts >= 0.2.0
ea774f60 61Provides: snmpd
ea774f60
AF
62Obsoletes: cmu-snmp
63Obsoletes: snmpd
e93f5ac2 64Obsoletes: ucd-snmp
fa43c632 65BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
ea774f60 66
ea774f60 67%define logfile /var/log/snmpd.log
39bab6f6 68%define filterout_ld -Wl,--as-needed
ea774f60
AF
69
70%description
71SNMP (Simple Network Management Protocol) is a protocol used for
531ca0ff 72network management (hence the name). The net-snmp project includes
ea774f60
AF
73various SNMP tools: an extensible agent, an SNMP library, tools for
74requesting or setting information from SNMP agents, tools for
75generating and handling SNMP traps, a version of the netstat command
76which uses SNMP, and a Tk/Perl mib browser. This package contains the
77snmpd daemon, documentation, etc.
78
b1738c7c
JR
79%description -l es.UTF-8
80Este paquete se deriva de la implementación del Protocolo Simple de
81Gestión de Redes versión 2 (SNMPv2) de la Universidad Carnegie Mellon.
82Útil para administrar redes y hacer contabilidad.
83
84%description -l pl.UTF-8
85SNMP (Simple Network Management Protocol) jest protokołem używanym do
86zarządzania sieciami. Pakiet zawiera narzędzia: rozbudowywalnego
87agenta, bibliotekę SNMP, narzędzia do odpytywania oraz ustawiania
88informacji poprzez agentów SNMP, narzędzia do generowania i obsługi
89pułapek SNMP, wersję komendy netstat używającą SNMP, przeglądarkę mib
90w Tk/Perl, demona, dokumentację itp.
91
92%description -l pt_BR.UTF-8
93Este pacote é derivado da implementação do Protocolo Simples de
94Gerenciamento de Redes versão 2 (SNMPv2) da Universidade Carnegie
95Mellon. Útil para gerenciar redes e fazer contabilidade.
96
97%description -l ru.UTF-8
98SNMP (Simple Network Management Protocol) - это протокол, используемый
99для управления сетью (отсюда и название). Проект net-snmp включает
100разнообразные SNMP-утилиты: расширяемый агент, библиотека SNMP,
101утилиты для запроса или установки информации от SNMP-агентов, утилиты
102для генерации и обработки SNMP-трапов, версия команды netstat,
103использующей SNMP, и mib-браузер на Tk/Perl. Этот пакет содержит
104демоны snmpd и snmptrapd, документацию и т.д.
105
106%description -l uk.UTF-8
107SNMP (Simple Network Management Protocol) - це протокол, який
108використовують для керування мережею (звідси і назва). Проект net-snmp
109містить різноманітні SNMP-утиліти: розширюваний агент, бібліотека
110SNMP, утиліти для запросу та встановлення інформації від NMP-агентів,
111утиліти для генерації та обробки SNMP-трапів, версія команди netstat,
112яка використовує SNMP, та mib-браузер на Tk/Perl. Цей пакет містить
113демони snmpd та snmptrapd, документацію і т.і.
ea774f60
AF
114
115%package libs
e93f5ac2 116Summary: NET SNMP libraries
7d4e48ba 117Summary(pl.UTF-8): Biblioteki SNMP
ea774f60 118Group: Libraries
9274a72b 119Requires: %{name}-mibs = %{version}-%{release}
5ae1bff8 120Obsoletes: net-snmp-compat-libs
60e7e283 121Obsoletes: ucd-snmp-libs
ea774f60
AF
122
123%description libs
e93f5ac2 124NET SNMP libraries.
ea774f60 125
b1738c7c 126%description libs -l pl.UTF-8
ea774f60
AF
127Biblioteki SNMP.
128
ea774f60 129%package devel
531ca0ff 130Summary: The development environment for the net-snmp project
7d4e48ba
ER
131Summary(es.UTF-8): Archivos de inclusión y bibliotecas para desarrollo en el SNMP de la UCD
132Summary(pl.UTF-8): Pliki dla programistów używających bibliotek net-snmp
133Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas para desenvolvimento no SNMP da UCD
134Summary(ru.UTF-8): Среда разработки для проекта UCD-SNMP
135Summary(uk.UTF-8): Середовище розробки для проекту UCD-SNMP
ea774f60 136Group: Development/Libraries
9274a72b 137Requires: %{name}-libs = %{version}-%{release}
e43a09d3 138Requires: elfutils-devel
b0389a15 139Requires: libwrap-devel
0fa7de09 140Requires: lm_sensors-devel
8d251b9e 141Requires: openssl-devel >= 0.9.7c
b6eea507 142Requires: rpm-devel
60e7e283 143Obsoletes: ucd-snmp-devel
ea774f60
AF
144
145%description devel
146The ucd-snmp-devel package contains the development libraries and
531ca0ff 147header files for use with the net-snmp project's network management
ea774f60
AF
148tools.
149
b1738c7c
JR
150%description devel -l es.UTF-8
151Estas son las bibliotecas y archivos de inclusión para desarrollo con
152el SNMP de la UCD. Con este paquete es posible la creación de
153programas para uso en la gestión de redes.
ea774f60 154
b1738c7c
JR
155%description devel -l pl.UTF-8
156Pakiet zawiera pliki nagłówkowe i biblioteki potrzebne do rozwoju
157aplikacji używających protokołu SNMP.
ea774f60 158
b1738c7c
JR
159%description devel -l pt_BR.UTF-8
160Estas são as bibliotecas e arquivos de inclusão para desenvolvimento
161com o SNMP da UCD. Com este pacote é possível a criação de programas
ea774f60
AF
162para uso no gerenciamento de redes.
163
b1738c7c
JR
164%description devel -l ru.UTF-8
165Пакет ucd-snmp-devel содержит библиотеки разработчика и хедера для
166использования с утилитами управления сетью проекта net-snmp.
ea774f60 167
b1738c7c
JR
168%description devel -l uk.UTF-8
169Пакет ucd-snmp-devel містить бібліотеки програміста та хедери для
170використання з утилітами керування мережею проекту net-snmp.
ea774f60
AF
171
172%package static
531ca0ff 173Summary: Static net-snmp libraries
7d4e48ba
ER
174Summary(pl.UTF-8): Statyczne biblioteki net-snmp
175Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com ucd-snmp
176Summary(ru.UTF-8): Статические библиотеки для проекта net-snmp
177Summary(uk.UTF-8): Статичні бібліотеки для проекту net-snmp
ea774f60 178Group: Development/Libraries
9274a72b 179Requires: %{name}-devel = %{version}-%{release}
60e7e283 180Obsoletes: ucd-snmp-static
ea774f60
AF
181
182%description static
531ca0ff 183Static net-snmp libraries.
ea774f60 184
b1738c7c 185%description static -l pl.UTF-8
531ca0ff 186Statyczne biblioteki net-snmp.
ea774f60 187
b1738c7c
JR
188%description static -l pt_BR.UTF-8
189Bibliotecas estáticas para desenvolvimento com net-snmp.
531ca0ff 190
e93f5ac2
AF
191%package compat-devel
192Summary: The development environment for the UCD-SNMP project
7d4e48ba
ER
193Summary(es.UTF-8): Archivos de inclusión y bibliotecas para desarrollo en el SNMP de la UCD
194Summary(pl.UTF-8): Pliki dla programistów używających bibliotek UCD-SNMP
195Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas para desenvolvimento no SNMP da UCD
196Summary(ru.UTF-8): Среда разработки для проекта UCD-SNMP
197Summary(uk.UTF-8): Середовище розробки для проекту UCD-SNMP
e93f5ac2 198Group: Development/Libraries
9274a72b
JB
199Requires: %{name}-libs = %{version}-%{release}
200Requires: openssl-devel >= 0.9.7d
e93f5ac2
AF
201Obsoletes: cmu-snmp-devel
202Obsoletes: ucd-snmp-devel
203
204%description compat-devel
205The ucd-snmp-devel package contains the development libraries and
206header files for use with the UCD-SNMP project's network management
207tools.
208
b1738c7c
JR
209%description compat-devel -l es.UTF-8
210Estas son las bibliotecas y archivos de inclusión para desarrollo con
211el SNMP de la UCD. Con este paquete es posible la creación de
212programas para uso en la gestión de redes.
e93f5ac2 213
b1738c7c
JR
214%description compat-devel -l pl.UTF-8
215Pakiet zawiera pliki nagłówkowe i biblioteki potrzebne do rozwoju
216aplikacji używających protokołu SNMP.
e93f5ac2 217
b1738c7c
JR
218%description compat-devel -l pt_BR.UTF-8
219Estas são as bibliotecas e arquivos de inclusão para desenvolvimento
220com o SNMP da UCD. Com este pacote é possível a criação de programas
e93f5ac2
AF
221para uso no gerenciamento de redes.
222
b1738c7c
JR
223%description compat-devel -l ru.UTF-8
224Пакет ucd-snmp-devel содержит библиотеки разработчика и хедера для
225использования с утилитами управления сетью проекта UCD-SNMP.
e93f5ac2 226
b1738c7c
JR
227%description compat-devel -l uk.UTF-8
228Пакет ucd-snmp-devel містить бібліотеки програміста та хедери для
229використання з утилітами керування мережею проекту UCD-SNMP.
e93f5ac2
AF
230
231%package compat-static
232Summary: Static UCD-SNMP libraries
7d4e48ba
ER
233Summary(pl.UTF-8): Statyczne biblioteki UCD-SNMP
234Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com ucd-snmp
235Summary(ru.UTF-8): Статические библиотеки для проекта UCD-SNMP
236Summary(uk.UTF-8): Статичні бібліотеки для проекту UCD-SNMP
e93f5ac2 237Group: Development/Libraries
9274a72b 238Requires: %{name}-compat-devel = %{version}-%{release}
e93f5ac2
AF
239Obsoletes: ucd-snmp-static
240
241%description compat-static
242Static UCD-SNMP libraries.
243
b1738c7c 244%description compat-static -l pl.UTF-8
531ca0ff 245Statyczne biblioteki UCD-SNMP.
e93f5ac2 246
b1738c7c
JR
247%description compat-static -l pt_BR.UTF-8
248Bibliotecas estáticas para desenvolvimento com ucd-snmp.
531ca0ff
JB
249
250%package mibs
251Summary: MIB database
7d4e48ba 252Summary(pl.UTF-8): Baza danych MIB
531ca0ff 253Group: Applications/System
9274a72b 254Conflicts: ucd-snmp-libs
531ca0ff
JB
255
256%description mibs
257MIB database.
258
b1738c7c 259%description mibs -l pl.UTF-8
531ca0ff
JB
260Baza danych MIB.
261
262%package snmptrapd
263Summary: SNMP trap daemon
7d4e48ba 264Summary(pl.UTF-8): Demon obsługujący pułapki SNMP
531ca0ff 265Group: Applications/System
531ca0ff 266Requires(post,preun): /sbin/chkconfig
b0389a15
ER
267Requires: %{name} = %{version}-%{release}
268Requires: rc-scripts >= 0.2.0
531ca0ff
JB
269Obsoletes: cmu-snmp-utils
270Obsoletes: ucd-snmp-snmptrapd
271
272%description snmptrapd
273The ucd-snmp-snmptrapd package contains snmp trap daemon.
274
b1738c7c
JR
275%description snmptrapd -l pl.UTF-8
276Pakiet zawiera demon obsługujący pułapki SNMP.
531ca0ff
JB
277
278%package utils
279Summary: Network management utilities using SNMP, from the NET-SNMP project
7d4e48ba
ER
280Summary(es.UTF-8): Utilitarios del SNMP de la UCD
281Summary(pl.UTF-8): Narzędzia używające protokołu SNMP
282Summary(pt_BR.UTF-8): Utilitários do SNMP da UCD
283Summary(ru.UTF-8): Утилиты управления сетью по SNMP из проекта NET-SNMP
284Summary(uk.UTF-8): Утиліти керування мережею по SNMP з проекту NET-SNMP
531ca0ff 285Group: Applications/System
9274a72b 286Requires: %{name}-libs = %{version}-%{release}
531ca0ff
JB
287Obsoletes: cmu-snmp-utils
288Obsoletes: ucd-snmp-utils
289
290%description utils
291This package contains various utilities for managing your network
292using the SNMP protocol.
293
b1738c7c 294%description utils -l es.UTF-8
531ca0ff
JB
295Varios utilitarios para uso con el SNMP de la UCD. Contiene
296utilitarios como: snmpwalk, snmptest y otros.
297
b1738c7c
JR
298%description utils -l pl.UTF-8
299Różnego rodzaju narzędzia do zarządzania siecią przy użyciu protokołu
531ca0ff
JB
300SNMP.
301
b1738c7c
JR
302%description utils -l pt_BR.UTF-8
303Vários utilitários para uso com o SNMP da UCD. Contém utilitários
531ca0ff
JB
304como: snmpwalk, snmptest e outros.
305
b1738c7c
JR
306%description utils -l ru.UTF-8
307Пакет ucd-snmp-utils содержит разнообразные утилиты для использования
308в проекте управления сетью net-snmp.
531ca0ff 309
b1738c7c
JR
310%description utils -l uk.UTF-8
311Пакет ucd-snmp-utils містить різноманітні утиліти для використання в
312проекті керування мережею net-snmp.
531ca0ff
JB
313
314%package -n perl-SNMP
315Summary: SNMP and NetSNMP::* Perl modules
7d4e48ba 316Summary(pl.UTF-8): Moduły Perla SNMP oraz NetSNMP::*
531ca0ff 317Group: Development/Languages/Perl
9274a72b
JB
318Requires: %{name}-libs = %{version}-%{release}
319Conflicts: ucd-snmp-utils-perl
531ca0ff
JB
320
321%description -n perl-SNMP
322SNMP and NetSNMP::* Perl modules - Perl interface to net-snmp.
323
b1738c7c
JR
324%description -n perl-SNMP -l pl.UTF-8
325Moduły Perla SNMP oraz NetSNMP::* - perlowy interfejs do net-snmp.
531ca0ff
JB
326
327%package utils-perl
328Summary: Perl utilities for network management using SNMP
7d4e48ba 329Summary(pl.UTF-8): Perlowe narzędzia używające protokołu SNMP
531ca0ff 330Group: Applications/System
9274a72b 331Requires: perl-SNMP = %{version}-%{release}
531ca0ff
JB
332Obsoletes: cmu-snmp-utils
333Obsoletes: ucd-snmp-utils-perl
334
335%description utils-perl
336This package contains various Perl utilities for managing your network
337using the SNMP protocol.
338
b1738c7c
JR
339%description utils-perl -l pl.UTF-8
340Perlowe narzędzia do zarządzania siecią przy użyciu protokołu SNMP.
e93f5ac2
AF
341
342%package snmpconf
531ca0ff 343Summary: snmpconf - creating and modifying SNMP configuration files
7d4e48ba 344Summary(pl.UTF-8): snmpconf - tworzenie i modyfikowanie plików konfiguracyjnych SNMP
e93f5ac2 345Group: Applications/System
9274a72b
JB
346Requires: %{name} = %{version}-%{release}
347Requires: perl-SNMP = %{version}-%{release}
e93f5ac2
AF
348
349%description snmpconf
531ca0ff
JB
350snmpconf is a simple Perl script that walks you through setting up a
351configuration file step by step. It should be fairly straight forward
352to use.
353
b1738c7c
JR
354%description snmpconf -l pl.UTF-8
355snmpconf to prosty skrypt Perla pozwalający na tworzenie pliku
356konfiguracyjnego krok po kroku. Powinien być w miarę prosty w użyciu.
e93f5ac2
AF
357
358%package tkmib
2ffae1a4 359Summary: MIB browser in Tk
7d4e48ba 360Summary(pl.UTF-8): Przeglądarka MIB-ów w Tk
e93f5ac2 361Group: Applications/System
9274a72b 362Requires: perl-SNMP = %{version}-%{release}
531ca0ff 363Requires: perl-Tk
e93f5ac2
AF
364
365%description tkmib
2ffae1a4 366MIB browser in Tk.
531ca0ff 367
b1738c7c
JR
368%description tkmib -l pl.UTF-8
369Przeglądarka MIB-ów w Tk.
e93f5ac2 370
a5fe3234
JB
371%package -n python-netsnmp
372Summary: Python netsnmp extension module
7d4e48ba 373Summary(pl.UTF-8): Moduł rozszerzenia netsnmp dla Pythona
a5fe3234
JB
374Group: Libraries/Python
375Requires: %{name}-libs = %{version}-%{release}
376
377%description -n python-netsnmp
378The 'netsnmp' Python extension module provides a full featured,
379tri-lingual SNMP (SNMPv3, SNMPv2c, SNMPv1) client API.
380
b1738c7c
JR
381%description -n python-netsnmp -l pl.UTF-8
382Moduł rozszerzenia netsnmp dla Pythona udostępnia pełne API klienckie
383SNMP dla trzech wersji tego protokołu (SNMPv3, SNMPv2c, SNMPv1).
a5fe3234 384
ea774f60 385%prep
797d6879 386%setup -q -a7
ea774f60
AF
387%patch0 -p1
388%patch1 -p1
389%patch2 -p1
390%patch3 -p1
531ca0ff 391%patch4 -p1
edf6eebd
JB
392%patch5 -p1
393%patch6 -p1
8a2022cc 394%patch7 -p1
9274a72b 395%patch8 -p1
f42492ff 396%patch9 -p1
a5fe3234 397%patch10 -p1
b0b507b1 398%patch11 -p1
ea774f60
AF
399
400%build
401%{__libtoolize}
402%{__aclocal}
ea774f60 403%{__autoconf}
564bc1fe 404%{__autoheader}
ea774f60 405%configure \
27b5f5a2
JR
406 --disable-debugging \
407 --enable-as-needed \
f42492ff 408 --with-cflags="%{rpmcflags} -I/usr/include/et" \
ea774f60 409 --with-ldflags="%{rpmldflags}" \
c74e79f9
JB
410 --with-defaults \
411 --with-default-snmp-version=3 \
27b5f5a2
JR
412 --with-krb5=%{_prefix} \
413 --with-openssl=%{_prefix} \
414 --with-libwrap=%{_prefix} \
c74e79f9 415 --with-logfile="%{logfile}" \
27b5f5a2
JR
416 --with-zlib=%{_prefix} \
417 --with-bzip2=%{_prefix} \
c74e79f9 418 --with-perl-modules \
c74e79f9 419 --with-python-modules \
27b5f5a2
JR
420 --with-mib-modules="host agentx smux mibII/mta_sendmail \
421%ifarch %{ix86} %{x8664}
422 ucd-snmp/lmSensors \
423%endif
424 disman/event disman/schedule ucd-snmp/diskio \
425 target misc/ipfwacc" \
c74e79f9 426 --with-security-modules="ksm" \
ea774f60 427 --with-sys-contact="root@localhost" \
c74e79f9
JB
428 --with-sys-location="Unknown" \
429 --with-transports="UDP UDPIPv6 TCP TCPIPv6 Unix Callback " \
27b5f5a2
JR
430 --with-persistent-directory="/var/lib/net-snmp" \
431 --enable-ucd-snmp-compatibility \
432 --enable-ipv6
2d4ec541 433
f889f3fa
ER
434# build this subdir first. it's causing STRANGE compile failures # otherwise (for me at least). glen
435%{__make} -C agent/mibgroup
ea774f60
AF
436%{__make}
437
531ca0ff 438cd perl
531ca0ff 439
531ca0ff 440%{__perl} Makefile.PL \
2b15ac96 441 -NET-SNMP-IN-SOURCE=true \
531ca0ff 442 INSTALLDIRS=vendor \
2b15ac96 443 OPTIMIZE="%{rpmcflags}" \
531ca0ff 444 </dev/null
2b15ac96 445
531ca0ff
JB
446# avoid rpaths generated by MakeMaker
447perl -pi -e 's@LD_RUN_PATH="\$\(LD_RUN_PATH\)" @@' */Makefile */*/Makefile
448
d59f5301
JK
449%{__make} \
450 LDFLAGS="%{rpmldflags}"
ea774f60
AF
451
452%install
453rm -rf $RPM_BUILD_ROOT
fa43c632 454install -d $RPM_BUILD_ROOT{/etc/{rc.d/init.d,sysconfig,snmp},/var/log}
ea774f60 455
6789d157 456%{__make} install \
543e900e 457 DESTDIR=$RPM_BUILD_ROOT
ea774f60 458
6810e918
AF
459install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmpd.conf
460:> $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmpd.local.conf
6e818aed 461:> $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmp.conf
e93f5ac2 462:> $RPM_BUILD_ROOT%{logfile}
ea774f60 463
60e7e283 464install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/snmpd
6810e918 465install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmpd.conf
60e7e283 466install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/snmpd
ea774f60 467
60e7e283 468install %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/snmptrapd
6810e918 469install %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/snmp/snmptrapd.conf
60e7e283 470install %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/snmptrapd
ea774f60
AF
471
472#install agent/mibgroup/ipfwchains/IPFWCHAINS-MIB.txt \
473# $RPM_BUILD_ROOT%{_datadir}/snmp/mibs
474
531ca0ff
JB
475cd perl
476%{__make} install \
477 DESTDIR=$RPM_BUILD_ROOT
9274a72b 478
531ca0ff
JB
479install -d $RPM_BUILD_ROOT%{_examplesdir}/perl-SNMP-%{version}
480install SNMP/examples/*.pl $RPM_BUILD_ROOT%{_examplesdir}/perl-SNMP-%{version}
b572d007 481cd ..
ea774f60 482
9274a72b
JB
483# IP-Filter (non-Linux)
484rm -f $RPM_BUILD_ROOT%{_bindir}/ipf-mod.pl
485
ea774f60
AF
486%clean
487rm -rf $RPM_BUILD_ROOT
488
e93f5ac2 489%post
ea774f60
AF
490touch %{logfile}
491chmod 640 %{logfile}
fa43c632
ER
492/sbin/chkconfig --add snmpd
493%service snmpd restart "snmpd daemon"
ea774f60 494
60e7e283
AF
495%preun
496if [ "$1" = "0" ]; then
fa43c632 497 %service snmpd stop
60e7e283
AF
498 /sbin/chkconfig --del snmpd
499fi
ea774f60
AF
500
501%post libs -p /sbin/ldconfig
502%postun libs -p /sbin/ldconfig
503
5b201584
JB
504%triggerpostun -- ucd-snmp
505/sbin/chkconfig --add snmpd
506
e93f5ac2 507%post snmptrapd
ea774f60
AF
508touch %{logfile}
509chmod 640 %{logfile}
fa43c632
ER
510/sbin/chkconfig --add snmptrapd
511%service snmptrapd restart "snmp trap daemon"
ea774f60 512
60e7e283
AF
513%preun snmptrapd
514if [ "$1" = "0" ]; then
fa43c632 515 %service snmptrapd stop
60e7e283
AF
516 /sbin/chkconfig --del snmptrapd
517fi
ea774f60 518
605b587c 519%triggerpostun snmptrapd -- ucd-snmp-snmptrapd
5b201584
JB
520/sbin/chkconfig --add snmptrapd
521
ea774f60
AF
522%files
523%defattr(644,root,root,755)
524%doc README local
525%doc ChangeLog EXAMPLE.conf.def EXAMPLE.conf
526%doc FAQ NEWS PORTING README.snmpv3 TODO AGENT.txt
527
60e7e283 528%attr(754,root,root) /etc/rc.d/init.d/snmpd
9e8f34e2 529%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/snmpd
ea774f60 530
9e8f34e2
JB
531%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmpd.conf
532%attr(640,root,root) %config(missingok,noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmpd.local.conf
ea774f60
AF
533
534%attr(755,root,root) %{_sbindir}/snmpd
535
ea774f60 536%{_mandir}/man5/snmpd.conf.5*
a23e7817
JB
537%{_mandir}/man5/snmpd.examples.5*
538%{_mandir}/man5/snmpd.internal.5*
ea774f60 539%{_mandir}/man5/variables.5*
531ca0ff 540%{_mandir}/man8/snmpd.8*
ea774f60 541
e93f5ac2 542%attr(640,root,root) %ghost %{logfile}
ea774f60
AF
543
544%files libs
545%defattr(644,root,root,755)
e043d0db 546%dir %{_sysconfdir}/snmp
60e7e283 547%attr(755,root,root) %{_libdir}/libnet*.so.*.*
ea774f60 548
531ca0ff
JB
549%files devel
550%defattr(644,root,root,755)
551%attr(755,root,root) %{_bindir}/mib2c
f2ba5e16 552%attr(755,root,root) %{_bindir}/mib2c-update
531ca0ff
JB
553%attr(755,root,root) %{_bindir}/net-snmp-config
554%attr(755,root,root) %{_libdir}/libnet*[a-z].so
555%{_libdir}/libnet*.la
556%{_includedir}/net-snmp
557%{_datadir}/snmp/mib2c*
558%{_mandir}/man1/mib2c.1*
a5fe3234
JB
559%{_mandir}/man1/mib2c-update.1*
560%{_mandir}/man1/net-snmp-config.1*
bdee8ff5 561%{_mandir}/man3/[!NS]*
f2ba5e16 562%{_mandir}/man5/mib2c.conf.5*
531ca0ff
JB
563
564%files static
565%defattr(644,root,root,755)
566%{_libdir}/libnet*.a
567
531ca0ff
JB
568%files compat-devel
569%defattr(644,root,root,755)
570%attr(755,root,root) %{_libdir}/libsnmp.so
571%{_libdir}/libsnmp.la
572%{_includedir}/ucd-snmp
573
574%files compat-static
575%defattr(644,root,root,755)
576%{_libdir}/libsnmp.a
577
60e7e283
AF
578%files mibs
579%defattr(644,root,root,755)
ee807caf 580%dir %{_datadir}/snmp
ea774f60
AF
581%{_datadir}/snmp/mibs
582
531ca0ff 583%files snmptrapd
60e7e283 584%defattr(644,root,root,755)
531ca0ff
JB
585%attr(755,root,root) %{_sbindir}/snmptrapd
586%attr(754,root,root) /etc/rc.d/init.d/snmptrapd
9e8f34e2
JB
587%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/snmptrapd
588%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmptrapd.conf
f2ba5e16 589%attr(755,root,root) %{_datadir}/snmp/snmp_perl_trapd.pl
531ca0ff
JB
590%{_mandir}/man5/snmptrapd.conf.5*
591%{_mandir}/man8/snmptrapd.8*
60e7e283 592
ea774f60
AF
593%files utils
594%defattr(644,root,root,755)
595%attr(755,root,root) %{_bindir}/encode_keychange
596%attr(755,root,root) %{_bindir}/snmpbulkget
597%attr(755,root,root) %{_bindir}/snmpbulkwalk
598%attr(755,root,root) %{_bindir}/snmpdelta
6789d157 599%attr(755,root,root) %{_bindir}/snmpdf
ea774f60
AF
600%attr(755,root,root) %{_bindir}/snmpget
601%attr(755,root,root) %{_bindir}/snmpgetnext
6789d157 602%attr(755,root,root) %{_bindir}/snmpinform
ea774f60
AF
603%attr(755,root,root) %{_bindir}/snmpnetstat
604%attr(755,root,root) %{_bindir}/snmpset
605%attr(755,root,root) %{_bindir}/snmpstatus
606%attr(755,root,root) %{_bindir}/snmptable
607%attr(755,root,root) %{_bindir}/snmptest
608%attr(755,root,root) %{_bindir}/snmptranslate
609%attr(755,root,root) %{_bindir}/snmptrap
610%attr(755,root,root) %{_bindir}/snmpusm
ea774f60 611%attr(755,root,root) %{_bindir}/snmpvacm
6789d157 612%attr(755,root,root) %{_bindir}/snmpwalk
a5fe3234 613%{_mandir}/man1/encode_keychange.1*
ea774f60
AF
614%{_mandir}/man1/snmpbulkget.1*
615%{_mandir}/man1/snmpbulkwalk.1*
616%{_mandir}/man1/snmpcmd.1*
617%{_mandir}/man1/snmpdelta.1*
6789d157 618%{_mandir}/man1/snmpdf.1*
ea774f60
AF
619%{_mandir}/man1/snmpget.1*
620%{_mandir}/man1/snmpgetnext.1*
6789d157 621%{_mandir}/man1/snmpinform.1*
ea774f60
AF
622%{_mandir}/man1/snmpnetstat.1*
623%{_mandir}/man1/snmpset.1*
624%{_mandir}/man1/snmpstatus.1*
625%{_mandir}/man1/snmptable.1*
626%{_mandir}/man1/snmptest.1*
627%{_mandir}/man1/snmptranslate.1*
628%{_mandir}/man1/snmptrap.1*
629%{_mandir}/man1/snmpusm.1*
6789d157 630%{_mandir}/man1/snmpvacm.1*
ea774f60 631%{_mandir}/man1/snmpwalk.1*
ea774f60
AF
632%{_mandir}/man5/snmp.conf.5*
633%{_mandir}/man5/snmp_config.5*
634
7bb0c439 635%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snmp/snmp.conf
6e818aed 636
531ca0ff 637%files -n perl-SNMP
c4deead5 638%defattr(644,root,root,755)
531ca0ff
JB
639%doc perl/SNMP/{BUG,README,TODO} perl/SNMP/examples
640%{perl_vendorarch}/SNMP.pm
641%{perl_vendorarch}/NetSNMP
642%dir %{perl_vendorarch}/auto/SNMP
643%{perl_vendorarch}/auto/SNMP/autosplit.ix
644%{perl_vendorarch}/auto/SNMP/SNMP.bs
645%attr(755,root,root) %{perl_vendorarch}/auto/SNMP/SNMP.so
646%dir %{perl_vendorarch}/auto/NetSNMP
647%dir %{perl_vendorarch}/auto/NetSNMP/*
648%{perl_vendorarch}/auto/NetSNMP/*/autosplit.ix
649%{perl_vendorarch}/auto/NetSNMP/*/*.bs
650%attr(755,root,root) %{perl_vendorarch}/auto/NetSNMP/*/*.so
651%dir %{perl_vendorarch}/auto/NetSNMP/agent/default_store
652%{perl_vendorarch}/auto/NetSNMP/agent/default_store/autosplit.ix
653%{perl_vendorarch}/auto/NetSNMP/agent/default_store/default_store.bs
654%attr(755,root,root) %{perl_vendorarch}/auto/NetSNMP/agent/default_store/default_store.so
655%{_mandir}/man3/NetSNMP::*.3*
656%{_mandir}/man3/SNMP.3*
657%{_examplesdir}/perl-SNMP-%{version}
658
ea774f60
AF
659%files utils-perl
660%defattr(644,root,root,755)
6789d157 661%attr(755,root,root) %{_bindir}/fixproc
60e7e283 662%attr(755,root,root) %{_bindir}/snmpcheck
6810e918 663%attr(755,root,root) %{_bindir}/traptoemail
a5fe3234
JB
664%{_mandir}/man1/fixproc.1*
665%{_mandir}/man1/traptoemail.1*
531ca0ff
JB
666
667%files snmpconf
4ec38672 668%defattr(644,root,root,755)
531ca0ff 669%attr(755,root,root) %{_bindir}/snmpconf
60e7e283
AF
670%{_mandir}/man1/snmpconf.1*
671%{_datadir}/snmp/snmpconf-data
e93f5ac2 672
e93f5ac2
AF
673%files tkmib
674%defattr(644,root,root,755)
4ec38672 675%attr(755,root,root) %{_bindir}/tkmib
a5fe3234
JB
676%{_mandir}/man1/tkmib.1*
677
678%files -n python-netsnmp
679%defattr(644,root,root,755)
680%dir %{py_sitedir}/netsnmp
681%attr(755,root,root) %{py_sitedir}/netsnmp/*.so
682%{py_sitedir}/netsnmp/*.py[co]
683%{py_sitedir}/netsnmp_python-*.egg-info
This page took 0.161606 seconds and 4 git commands to generate.