1 |
%define major 0 |
2 |
%define libname %mklibname pwdb %{major} |
3 |
|
4 |
Summary: The password database library |
5 |
Name: pwdb |
6 |
Version: 0.62 |
7 |
Release: %mkrel 11 |
8 |
License: GPL |
9 |
Group: System/Libraries |
10 |
Source: %{name}-%{version}.tar.bz2 |
11 |
Patch0: %{name}-0.62-includes.patch |
12 |
BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot |
13 |
|
14 |
%description |
15 |
The pwdb package contains libpwdb, the password database library. |
16 |
Libpwdb is a library which implements a generic user information |
17 |
database. Libpwdb was specifically designed to work with Linux's PAM |
18 |
(Pluggable Authentication Modules). Libpwdb allows configurable |
19 |
access to and management of security tools like /etc/passwd, |
20 |
/etc/shadow and network authentication systems including NIS and |
21 |
Radius. |
22 |
|
23 |
%package conf |
24 |
Summary: The password database library config |
25 |
Group: System/Base |
26 |
|
27 |
%description conf |
28 |
Configuration package for the libpwdb, the password database library. |
29 |
|
30 |
%package -n %{libname} |
31 |
Summary: The password database library |
32 |
Group: System/Libraries |
33 |
Requires: %{name}-conf |
34 |
Provides: pwdb = %{version}-%{release} |
35 |
Obsoletes: pwdb |
36 |
|
37 |
%description -n %{libname} |
38 |
The pwdb package contains libpwdb, the password database library. |
39 |
Libpwdb is a library which implements a generic user information |
40 |
database. Libpwdb was specifically designed to work with Linux's PAM |
41 |
(Pluggable Authentication Modules). Libpwdb allows configurable |
42 |
access to and management of security tools like /etc/passwd, |
43 |
/etc/shadow and network authentication systems including NIS and |
44 |
Radius. |
45 |
|
46 |
%package -n %{libname}-devel |
47 |
Summary: The pwdb include files and link library |
48 |
Group: Development/C |
49 |
Requires: %{libname} = %{version}-%{release} |
50 |
Provides: pwdb-devel = %{version}-%{release} |
51 |
Conflicts: pwdb-devel <= 0.61 |
52 |
|
53 |
%description -n %{libname}-devel |
54 |
The development header / link library for pwdb. |
55 |
|
56 |
%package -n %{libname}-static-devel |
57 |
Summary: The pwdb static library |
58 |
Group: Development/C |
59 |
Requires: %{libname}-devel = %{version}-%{release} |
60 |
Provides: pwdb-static-devel = %{version}-%{release} |
61 |
|
62 |
%description -n %{libname}-static-devel |
63 |
The static development library for pwdb. |
64 |
|
65 |
%prep |
66 |
|
67 |
%setup -q |
68 |
%patch0 -p1 -b .includes |
69 |
|
70 |
rm default.defs |
71 |
ln -s defs/redhat.defs default.defs |
72 |
# checking out of the CVS sometimes preserves the setgid bit on |
73 |
# directories... |
74 |
chmod -R g-s . |
75 |
|
76 |
%build |
77 |
%make |
78 |
|
79 |
%install |
80 |
[ "%{buildroot}" != "/" ] && rm -rf %{buildroot} |
81 |
|
82 |
mkdir -p %{buildroot}/{%{_lib},%{_sysconfdir},%{_includedir}/pwdb} |
83 |
|
84 |
make INCLUDED=%{buildroot}%{_includedir}/pwdb \ |
85 |
LIBDIR=%{buildroot}/%{_lib} \ |
86 |
LDCONFIG=":" \ |
87 |
install |
88 |
|
89 |
install conf/pwdb.conf %{buildroot}%{_sysconfdir}/pwdb.conf |
90 |
|
91 |
ln -sf lib%{name}.so.%{version} %{buildroot}/%{_lib}/lib%{name}.so.%{major} |
92 |
|
93 |
%if %mdkversion < 200900 |
94 |
%post -n %{libname} -p /sbin/ldconfig |
95 |
%endif |
96 |
|
97 |
%if %mdkversion < 200900 |
98 |
%postun -n %{libname} -p /sbin/ldconfig |
99 |
%endif |
100 |
|
101 |
%clean |
102 |
[ "%{buildroot}" != "/" ] && rm -rf %{buildroot} |
103 |
|
104 |
%files conf |
105 |
%defattr(644,root,root,755) |
106 |
%doc Copyright doc/pwdb.txt doc/html |
107 |
%config(noreplace) %{_sysconfdir}/pwdb.conf |
108 |
|
109 |
%files -n %{libname} |
110 |
%defattr(644,root,root,755) |
111 |
%attr(755,root,root) /%{_lib}/libpwdb.so.%{major}* |
112 |
|
113 |
%files -n %{libname}-devel |
114 |
%defattr(644,root,root,755) |
115 |
/%{_lib}/libpwdb.so |
116 |
%{_includedir}/pwdb |
117 |
|
118 |
%files -n %{libname}-static-devel |
119 |
%defattr(644,root,root,755) |
120 |
/%{_lib}/libpwdb.a |
121 |
|
122 |
|
123 |
|
124 |
|