]>
Commit | Line | Data |
---|---|---|
37a8c0b7 AM |
1 | Summary: Crypt Library for DES, MD5, and Blowfish |
2 | Name: libxcrypt | |
3 | Version: 3.0.2 | |
4 | Release: 1 | |
5 | License: LGPL v2+, Public Domain, Freeware | |
6 | Group: Libraries | |
7 | Source0: ftp://ftp.suse.com/pub/people/kukuk/libxcrypt/%{name}-%{version}.tar.bz2 | |
8 | # Source0-md5: 56cf4285086f26649b8792b53fe8b00f | |
9 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
10 | ||
f0e142fd | 11 | %undefine __cxx |
12 | ||
37a8c0b7 AM |
13 | %description |
14 | Libxcrypt is a replacement for libcrypt, which comes with the GNU C | |
15 | Library. It supports DES crypt, MD5, and passwords with blowfish | |
16 | encryption. | |
17 | ||
18 | %package devel | |
19 | Summary: Header files and develpment documentation for libxcrypt | |
20 | Group: Development/Libraries | |
21 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
22 | ||
23 | %description devel | |
24 | This package contains the header files to develop software using | |
25 | libxcrypt. | |
26 | ||
27 | %package static | |
28 | Summary: Static libxcrypt library | |
29 | Group: Development/Libraries | |
30 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} | |
31 | ||
32 | %description static | |
33 | This package contains the static library used for development. | |
34 | ||
35 | %prep | |
36 | %setup -q | |
37 | ||
38 | %build | |
39 | %configure \ | |
40 | --libdir=/%{_lib} | |
41 | %{__make} | |
42 | ||
43 | %install | |
44 | rm -rf $RPM_BUILD_ROOT | |
45 | install -d $RPM_BUILD_ROOT%{_libdir} | |
46 | ||
47 | %{__make} install \ | |
48 | DESTDIR=$RPM_BUILD_ROOT | |
49 | ||
50 | mv $RPM_BUILD_ROOT/%{_lib}/lib*.{l,}a $RPM_BUILD_ROOT%{_libdir} | |
429af81c AM |
51 | sed -i -e 's#/%{_lib}#%{_libdir}#g' $RPM_BUILD_ROOT%{_libdir}/*.la |
52 | ||
37a8c0b7 AM |
53 | for lib in $RPM_BUILD_ROOT/%{_lib}/lib*.so.*; do |
54 | lib=$(echo $lib | sed -e "s#$RPM_BUILD_ROOT##g") | |
55 | slib=$(basename $lib | sed -e 's#\.so\..*#.so#g') | |
56 | ln -sf $lib $RPM_BUILD_ROOT%{_libdir}/$slib | |
57 | done | |
58 | ||
59 | %clean | |
60 | rm -rf $RPM_BUILD_ROOT | |
61 | ||
62 | %post -p /sbin/ldconfig | |
63 | %postun -p /sbin/ldconfig | |
64 | ||
65 | %files | |
66 | %defattr(644,root,root,755) | |
67 | %doc ChangeLog NEWS README* | |
68 | %attr(755,root,root) /%{_lib}/libxcrypt.so.* | |
69 | %dir /%{_lib}/xcrypt | |
70 | %attr(755,root,root) /%{_lib}/xcrypt/libxcrypt*.so* | |
71 | ||
72 | %files devel | |
73 | %defattr(644,root,root,755) | |
74 | %attr(755,root,root) %{_libdir}/libxcrypt.so | |
75 | %{_includedir}/xcrypt.h | |
76 | %{_libdir}/*.la | |
77 | ||
78 | %files static | |
79 | %defattr(644,root,root,755) | |
80 | %{_libdir}/libxcrypt.a |