- todo about trash in /etc/openssl/certs
[packages/ca-certificates.git] / ca-certificates.spec
CommitLineData
53f3b59a
ER
1# TODO
2# - cleanup dead links from /etc/openssl/certs after -update uninstall
8bb152c1 3Summary: Common CA Certificates PEM files
500a6231 4Summary(pl.UTF-8): Pliki PEM popularnych certyfikatów CA
8bb152c1 5Name: ca-certificates
5352fc69 6Version: 20080809
850133d0 7Release: 4
ed111db5 8License: distributable
8bb152c1 9Group: Libraries
8bb152c1 10Source0: ftp://ftp.debian.org/debian/pool/main/c/ca-certificates/%{name}_%{version}.tar.gz
5352fc69 11# Source0-md5: c155f5059006b94ad0aea7018161ab37
6c894e75 12Source1: https://www.verisign.com/support/thawte-roots.zip
ed111db5
JR
13# Source1-md5: a3709cc0279ef3fca4f86ea775066b18
14Source2: http://www.certum.pl/keys/CA.pem
15# Source2-md5: 35610177afc9c64e70f1ce62c1885496
16Source3: http://www.certum.pl/keys/level1.pem
17# Source3-md5: ba2d2e234ef9cfd2e6e5f810c964862e
18Source4: http://www.certum.pl/keys/level2.pem
19# Source4-md5: d06578a04e8cb23071f3870430ea0cf0
20Source5: http://www.certum.pl/keys/level3.pem
21# Source5-md5: 47b67c63a52236576fc0d1150327c962
22Source6: http://www.certum.pl/keys/level4.pem
23# Source6-md5: f1f8a65d177745311a1e99f029ae5d71
24Source7: http://www.certum.pl/keys/vs.pem
25# Source7-md5: 8da19ffc48c5dcc2868b1aa55f1d5983
26Source8: http://www.certum.pl/keys/na.pem
27# Source8-md5: ba571cb35e7672ff7ae95132ac1bfec4
28Source9: http://www.certum.pl/keys/tsa.pem
29# Source9-md5: 1a7b3faf8ed00f4d80297de74862e102
30Source10: http://www.certum.pl/keys/class1.pem
31# Source10-md5: 058436b132ea2df6972821f546104a16
32Source11: http://www.certum.pl/keys/class2.pem
33# Source11-md5: 5caf7fe99b1fc6e63c40b3d081711d1b
34Source12: http://www.certum.pl/keys/class3.pem
35# Source12-md5: 07bc97e21da092ba53535c7379e1b58b
36Source13: http://www.certum.pl/keys/class4.pem
37# Source13-md5: 99ef61d509539af89f1c025b67245965
4619b3d9 38Patch0: %{name}-undebianize.patch
ed111db5 39Patch1: %{name}-more-certs.patch
c7360e68 40Patch2: %{name}-etc-certs.patch
302ace1c 41Patch3: %{name}-c_rehash.sh.patch
500a6231 42URL: http://www.cacert.org/
ed111db5
JR
43BuildRequires: ruby
44BuildRequires: unzip
8bb152c1 45Requires: mktemp
4c4c2875 46Requires: rpm-whiteout >= 1.7
ed111db5 47Obsoletes: certificates
5352fc69 48BuildArch: noarch
8bb152c1
ER
49BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
50
850133d0
ER
51%define certsdir /etc/certs
52
8bb152c1 53%description
500a6231
JB
54Common CA Certificates PEM files.
55
56%description -l pl.UTF-8
57Pliki PEM popularnych certyfikatów CA.
8bb152c1 58
302ace1c
JR
59%package update
60Summary: Script for updating CA Certificates database
61Summary(pl.UTF-8): Skrypt do odświeżania bazy certyfikatów CA
62Group: Libraries
6c894e75 63Requires: %{name} = %{version}-%{release}
302ace1c
JR
64Requires: openssl-tools >= 0.9.8i-3
65
66%description update
67Script and data for updating CA Certificates database.
68
6c894e75 69%description update -l pl.UTF-8
302ace1c
JR
70Skrypt i dane do odświeżania bazy certyfikatów CA.
71
8bb152c1 72%prep
5352fc69 73%setup -q -n %{name}
ed111db5
JR
74%patch0 -p1
75%patch1 -p1
c7360e68 76%patch2 -p1
302ace1c 77%patch3 -p1
ed111db5 78
ebf0e82f
ER
79%{__unzip} -qq %{SOURCE1} '*_b64.txt' -d thawte
80for a in thawte/{,*/}*.txt; do
81 mv "$a" "${a%_b64.txt}.crt"
ed111db5
JR
82done
83
84install -d certum
85install %{SOURCE2} certum
86install %{SOURCE3} certum
87install %{SOURCE4} certum
88install %{SOURCE5} certum
89install %{SOURCE6} certum
90install %{SOURCE7} certum
91install %{SOURCE8} certum
92install %{SOURCE9} certum
93install %{SOURCE10} certum
94install %{SOURCE11} certum
95install %{SOURCE12} certum
96install %{SOURCE13} certum
ebf0e82f
ER
97for a in certum/*.pem; do
98 mv "$a" "${a%.pem}.crt"
ed111db5
JR
99done
100
101%build
102%{__make}
103
104# We have those and more in specific dirs
105rm mozilla/{Thawte,thawte,Certum}*.crt
8bb152c1
ER
106
107%install
108rm -rf $RPM_BUILD_ROOT
850133d0 109install -d $RPM_BUILD_ROOT{%{_datadir}/%{name},%{_sbindir},%{certsdir}}
8bb152c1
ER
110
111%{__make} install \
112 DESTDIR=$RPM_BUILD_ROOT
113
114(
115cd $RPM_BUILD_ROOT%{_datadir}/ca-certificates
116find . -name '*.crt' | sort | cut -b3-
117) > $RPM_BUILD_ROOT%{_sysconfdir}/ca-certificates.conf
118
302ace1c
JR
119(
120cd $RPM_BUILD_ROOT%{_datadir}/ca-certificates
121find . -name '*.crt' -print0 | xargs -0 cat
850133d0 122) > $RPM_BUILD_ROOT%{certsdir}/ca-certificates.crt
8bb152c1
ER
123
124%clean
125rm -rf $RPM_BUILD_ROOT
126
302ace1c 127%post update
8bb152c1
ER
128%{_sbindir}/update-ca-certificates || :
129
130%files
131%defattr(644,root,root,755)
850133d0 132%config(noreplace) %verify(not md5 mtime size) %{certsdir}/ca-certificates.crt
302ace1c
JR
133
134%files update
135%defattr(644,root,root,755)
8bb152c1 136%attr(755,root,root) %{_sbindir}/update-ca-certificates
302ace1c 137%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ca-certificates.conf
8bb152c1 138%{_datadir}/ca-certificates
This page took 0.152993 seconds and 4 git commands to generate.