]> git.pld-linux.org Git - packages/lsvpd.git/blob - lsvpd.spec
- standard service restart and stop (if it's bad idea leave note)
[packages/lsvpd.git] / lsvpd.spec
1 Summary:        VPD/hardware inventory utilities for Linux
2 Summary(pl):    Narzêdzia do inwentaryzacji VPD/sprzêtu dla Linuksa
3 Name:           lsvpd
4 Version:        0.14.1
5 Release:        1
6 License:        GPL
7 Group:          Applications/System
8 Source0:        http://dl.sourceforge.net/linux-diag/%{name}-%{version}.tar.gz
9 # Source0-md5:  f310891ca548358e778d7009ba0c0976
10 URL:            http://linux-diag.sourceforge.net/Lsvpd.html
11 BuildRequires:  perl-base
12 BuildRequires:  rpmbuild(macros) >= 1.268
13 BuildRequires:  sed >= 4.0
14 BuildRequires:  sg3_utils-devel >= 1.01
15 BuildRequires:  sysfsutils-devel >= 1.3.0-3
16 Requires(post,preun):   /sbin/chkconfig
17 Requires:       /bin/bash
18 Requires:       /bin/sed
19 Requires:       /bin/sh
20 Requires:       sg3_utils >= 1.01
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %description
24 The lsvpd package contains both the lsvpd, lscfg and lsmcode commands.
25 These commands, along with a boot-time scanning script called
26 update-device-tree, constitute a simple hardware inventory system. The
27 lsvpd command provides Vital Product Data (VPD) about hardware
28 components to higher-level serviceability tools. The lscfg command
29 provides a more human-readable format of the VPD, as well as some
30 system-specific information. lsmcode lists microcode and firmware
31 levels.
32
33 %description -l pl
34 Pakiet lsvpd zawiera polecenia lsvpd, lscfg i lsmcode. Tworz± one,
35 wraz z uruchamianym przy starcie systemu skryptem update-device-tree,
36 prosty system inwentaryzacji sprzêtu. Polecenie lsvpd dostarcza VPD
37 (Vital Product Data) o podzespo³ach sprzêtowych dla narzêdzi wy¿szego
38 poziomu. Polecenie lscfg dostarcza bardziej czyteln± dla cz³owieka
39 postaæ VPD oraz trochê informacji specyficznych dla systemu. lsmcode
40 wypisuje poziomy mikrokodu i firmware'u.
41
42 %prep
43 %setup -q
44 sed -i -e "s,#!/bin/sh,#!/bin/bash," scripts/lsvpd.in
45
46 %build
47 %{__make} \
48         CC="%{__cc}" \
49         CFLAGS="%{rpmcflags} -Wall -I../lib" \
50         LDLIBS="-lsysfs -lsgutils"
51
52 %install
53 rm -rf $RPM_BUILD_ROOT
54
55 %{__make} install \
56         DESTDIR=$RPM_BUILD_ROOT
57
58 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
59 install debian/init.d $RPM_BUILD_ROOT/etc/rc.d/init.d/lsvpd
60 # don't install this right now.  It can crash systems.
61 rm -f $RPM_BUILD_ROOT/lib/lsvpd/pci_vpd_rom_grab
62
63 install -d $RPM_BUILD_ROOT/etc/cron.daily
64 install scripts/lsvpd.cron.daily $RPM_BUILD_ROOT/etc/cron.daily/lsvpd
65
66 ln -sf /usr/bin/find $RPM_BUILD_ROOT/lib/lsvpd/find
67
68 %clean
69 rm -rf $RPM_BUILD_ROOT
70
71 %post
72 /sbin/chkconfig --add lsvpd
73 %service lsvpd restart
74
75 %preun
76 if [ "$1" = "0" ] ; then
77         %service lsvpd stop
78         /sbin/chkconfig --del lsvpd
79 fi
80
81 %files
82 %defattr(644,root,root,755)
83 %doc NEWS README TODO docs/*.html
84 %attr(755,root,root) /sbin/lsvpd
85 %attr(755,root,root) /sbin/lscfg
86 %attr(755,root,root) /sbin/lsmcode
87 %attr(755,root,root) /sbin/lsvio
88 %attr(755,root,root) /sbin/update-lsvpd-db
89 %dir /lib/lsvpd
90 /lib/lsvpd/common.d
91 /lib/lsvpd/common-post.d
92 /lib/lsvpd/debug.bash
93 /lib/lsvpd/ide_mf.map
94 /lib/lsvpd/lscfg.d
95 /lib/lsvpd/lsmcode.d
96 /lib/lsvpd/lsvio.d
97 /lib/lsvpd/lsvpd-functions.bash
98 /lib/lsvpd/lsvpd.d
99 /lib/lsvpd/pci.ids
100 /lib/lsvpd/query.d
101 /lib/lsvpd/scan.d
102 /lib/lsvpd/scsivpd.conf
103 %attr(755,root,root) /lib/lsvpd/adapter_pci_map
104 %attr(755,root,root) /lib/lsvpd/device_handler
105 %attr(755,root,root) /lib/lsvpd/ibm_vpd_render
106 %attr(755,root,root) /lib/lsvpd/lsvpd_test
107 %attr(755,root,root) /lib/lsvpd/pci_lookup
108 %attr(755,root,root) /lib/lsvpd/pci_vpd_cap_grab
109 %attr(755,root,root) /lib/lsvpd/tdump
110 %attr(755,root,root) /lib/lsvpd/tidy_lsvpd_dbs
111 %attr(755,root,root) /lib/lsvpd/tidy_subdirs
112 %attr(755,root,root) /lib/lsvpd/update-vpd.hotplug
113 %attr(755,root,root) /lib/lsvpd/vpd-name-crosslink.hotplug
114 %attr(754,root,root) /etc/rc.d/init.d/lsvpd
115 %attr(755,root,root) /etc/cron.daily/lsvpd
116 %{_mandir}/man8/*
This page took 0.054362 seconds and 4 git commands to generate.