]> git.pld-linux.org Git - packages/mbedtls.git/blame - mbedtls.spec
- added config-dtls-srtp patch (enable MBEDTLS_SSL_DTLS_SRTP feature for linphone...
[packages/mbedtls.git] / mbedtls.spec
CommitLineData
875e57b3
JB
1#
2# Conditional build:
3%bcond_with zlib # zlib compression support (may reduce security, see CRIME)
4#
a3f8074d
JB
5Summary: Light-weight cryptographic and SSL/TLS library
6Summary(pl.UTF-8): Lekka biblioteka kryptograficzna oraz SSL/TLS
7Name: mbedtls
59cd7fbe 8Version: 2.26.0
543346bc 9Release: 2
a3f8074d
JB
10License: GPL v2+
11Group: Libraries
9874b67a
JB
12#Source0Download: https://github.com/ARMmbed/mbedtls/releases
13Source0: https://github.com/ARMmbed/mbedtls/archive/v%{version}/%{name}-%{version}.tar.gz
59cd7fbe 14# Source0-md5: 5f66a6278d469b1cca5e035786ae9ea8
543346bc 15Patch0: %{name}-config-dtls-srtp.patch
9874b67a 16URL: https://www.trustedfirmware.org/projects/mbed-tls/
59cd7fbe 17BuildRequires: cmake >= 2.8.12
a3f8074d 18BuildRequires: doxygen
9874b67a 19BuildRequires: rpm-build >= 4.6
a3f8074d 20BuildRequires: rpmbuild(macros) >= 1.605
875e57b3 21%{?with_zlib:BuildRequires: zlib-devel}
a3f8074d
JB
22BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
9735fbf4
JB
24# some false positives for format-truncation(?)
25# for stringop-overflow see library/ssl_tls.c /stringop-overflow (workaround no longer works with gcc 11)
645d2dc1 26# maybe-uninitialized fails in tests/suites/test_suite_ssl.function only on i686 builder(???)
07b0e160 27%define specflags -Wno-error=format-truncation -Wno-error=stringop-overflow -Wno-error=maybe-uninitialized
59cd7fbe 28
a3f8074d
JB
29%description
30mbedTLS is a light-weight open source cryptographic and SSL/TLS
31library written in C. mbedTLS makes it easy for developers to include
32cryptographic and SSL/TLS capabilities in their (embedded)
33applications with as little hassle as possible.
34
35%description -l pl.UTF-8
36mbedTLS to lekka, mająca otwarte źródła biblioteka kryptograficzna
37oraz SSL/TLS napisana w C. mbedTLS ułatwia programistom dołączanie
38funkcji kryptograficznych i SSL/TLS do swoich (wbudowanych) aplikacji
39przy jak najmniejszym narzucie.
40
41%package devel
42Summary: Development files for mbedTLS
43Summary(pl.UTF-8): Pliki programistyczne biblioteki mbedTLS
44Group: Development/Libraries
45Requires: %{name} = %{version}-%{release}
a3f8074d
JB
46
47%description devel
48This package contains the header files for developing applications
49that use mbedTLS.
50
51%description devel -l pl.UTF-8
52Ten pakiet zawiera pliki nagłówkowe do tworzenia aplikacji
53wykorzystujących bibliotekę mbedTLS.
54
55%package static
56Summary: Static mbedTLS library
57Summary(pl.UTF-8): Statyczna biblioteka mbedTLS
58Group: Development/Libraries
59Requires: %{name}-devel = %{version}-%{release}
60
61%description static
62Static mbedTLS library.
63
64%description static -l pl.UTF-8
65Statyczna biblioteka mbedTLS.
66
875e57b3
JB
67%package apidocs
68Summary: API documentation for mbedTLS library
69Summary(pl.UTF-8): Dokumentacja API biblioteki mbedTLS
70Group: Documentation
9874b67a 71BuildArch: noarch
875e57b3
JB
72
73%description apidocs
74API documentation for mbedTLS library.
75
76%description apidocs -l pl.UTF-8
77Dokumentacja API biblioteki mbedTLS.
78
a3f8074d
JB
79%prep
80%setup -q
543346bc 81%patch0 -p1
a3f8074d
JB
82
83%build
84install -d build
85cd build
86%cmake .. \
87 -DLIB_INSTALL_DIR:PATH=%{_libdir} \
875e57b3
JB
88 %{?with_zlib:-DENABLE_ZLIB_SUPPORT=ON} \
89 -DUSE_SHARED_MBEDTLS_LIBRARY=ON
a3f8074d
JB
90
91%{__make}
92%{__make} apidoc
93
94%if %{with tests}
95# Tests are not stable on 64-bit
96ctest --output-on-failure
97%endif
98
99%install
100rm -rf $RPM_BUILD_ROOT
101
102%{__make} -C build install \
103 DESTDIR=$RPM_BUILD_ROOT
104
105install -d $RPM_BUILD_ROOT%{_libdir}
106mv $RPM_BUILD_ROOT%{_bindir} $RPM_BUILD_ROOT%{_libdir}/%{name}
107
108%clean
109rm -rf $RPM_BUILD_ROOT
110
111%post -p /sbin/ldconfig
112%postun -p /sbin/ldconfig
113
114%files
115%defattr(644,root,root,755)
95cbb035 116%doc ChangeLog LICENSE README.md
64c8d752 117%attr(755,root,root) %{_libdir}/libmbedcrypto.so.*.*.*
59cd7fbe 118%attr(755,root,root) %ghost %{_libdir}/libmbedcrypto.so.6
a3f8074d 119%attr(755,root,root) %{_libdir}/libmbedtls.so.*.*.*
59cd7fbe 120%attr(755,root,root) %ghost %{_libdir}/libmbedtls.so.13
64c8d752 121%attr(755,root,root) %{_libdir}/libmbedx509.so.*.*.*
59cd7fbe 122%attr(755,root,root) %ghost %{_libdir}/libmbedx509.so.1
a3f8074d
JB
123%dir %{_libdir}/%{name}
124%attr(755,root,root) %{_libdir}/%{name}/aescrypt2
125%attr(755,root,root) %{_libdir}/%{name}/benchmark
126%attr(755,root,root) %{_libdir}/%{name}/cert_app
127%attr(755,root,root) %{_libdir}/%{name}/cert_req
128%attr(755,root,root) %{_libdir}/%{name}/cert_write
129%attr(755,root,root) %{_libdir}/%{name}/crl_app
130%attr(755,root,root) %{_libdir}/%{name}/crypt_and_hash
59cd7fbe 131%attr(755,root,root) %{_libdir}/%{name}/crypto_examples
a3f8074d
JB
132%attr(755,root,root) %{_libdir}/%{name}/dh_client
133%attr(755,root,root) %{_libdir}/%{name}/dh_genprime
134%attr(755,root,root) %{_libdir}/%{name}/dh_server
64c8d752
JB
135%attr(755,root,root) %{_libdir}/%{name}/dtls_client
136%attr(755,root,root) %{_libdir}/%{name}/dtls_server
59cd7fbe
JB
137%attr(755,root,root) %{_libdir}/%{name}/ecdh_curve25519
138%attr(755,root,root) %{_libdir}/%{name}/ecdsa
a3f8074d
JB
139%attr(755,root,root) %{_libdir}/%{name}/gen_entropy
140%attr(755,root,root) %{_libdir}/%{name}/gen_key
141%attr(755,root,root) %{_libdir}/%{name}/gen_random_ctr_drbg
142%attr(755,root,root) %{_libdir}/%{name}/gen_random_havege
143%attr(755,root,root) %{_libdir}/%{name}/generic_sum
144%attr(755,root,root) %{_libdir}/%{name}/hello
145%attr(755,root,root) %{_libdir}/%{name}/key_app
59cd7fbe
JB
146%attr(755,root,root) %{_libdir}/%{name}/key_app_writer
147%attr(755,root,root) %{_libdir}/%{name}/key_ladder_demo
148%attr(755,root,root) %{_libdir}/%{name}/key_ladder_demo.sh
bf36c92e 149%attr(755,root,root) %{_libdir}/%{name}/mini_client
a3f8074d 150%attr(755,root,root) %{_libdir}/%{name}/mpi_demo
a3f8074d
JB
151%attr(755,root,root) %{_libdir}/%{name}/pem2der
152%attr(755,root,root) %{_libdir}/%{name}/pk_decrypt
153%attr(755,root,root) %{_libdir}/%{name}/pk_encrypt
154%attr(755,root,root) %{_libdir}/%{name}/pk_sign
155%attr(755,root,root) %{_libdir}/%{name}/pk_verify
59cd7fbe 156%attr(755,root,root) %{_libdir}/%{name}/psa_constant_names
628fc698 157%attr(755,root,root) %{_libdir}/%{name}/query_compile_time_config
a3f8074d
JB
158%attr(755,root,root) %{_libdir}/%{name}/req_app
159%attr(755,root,root) %{_libdir}/%{name}/rsa_decrypt
160%attr(755,root,root) %{_libdir}/%{name}/rsa_encrypt
161%attr(755,root,root) %{_libdir}/%{name}/rsa_genkey
162%attr(755,root,root) %{_libdir}/%{name}/rsa_sign
59cd7fbe 163%attr(755,root,root) %{_libdir}/%{name}/rsa_sign_pss
a3f8074d 164%attr(755,root,root) %{_libdir}/%{name}/rsa_verify
59cd7fbe 165%attr(755,root,root) %{_libdir}/%{name}/rsa_verify_pss
a3f8074d 166%attr(755,root,root) %{_libdir}/%{name}/selftest
a3f8074d
JB
167%attr(755,root,root) %{_libdir}/%{name}/ssl_client1
168%attr(755,root,root) %{_libdir}/%{name}/ssl_client2
59cd7fbe 169%attr(755,root,root) %{_libdir}/%{name}/ssl_context_info
a3f8074d
JB
170%attr(755,root,root) %{_libdir}/%{name}/ssl_fork_server
171%attr(755,root,root) %{_libdir}/%{name}/ssl_mail_client
172%attr(755,root,root) %{_libdir}/%{name}/ssl_pthread_server
173%attr(755,root,root) %{_libdir}/%{name}/ssl_server
9874b67a 174%attr(755,root,root) %{_libdir}/%{name}/ssl_server2
a3f8074d 175%attr(755,root,root) %{_libdir}/%{name}/strerror
64c8d752 176%attr(755,root,root) %{_libdir}/%{name}/udp_proxy
59cd7fbe 177%attr(755,root,root) %{_libdir}/%{name}/zeroize
a3f8074d
JB
178
179%files devel
180%defattr(644,root,root,755)
64c8d752 181%attr(755,root,root) %{_libdir}/libmbedcrypto.so
a3f8074d 182%attr(755,root,root) %{_libdir}/libmbedtls.so
64c8d752
JB
183%attr(755,root,root) %{_libdir}/libmbedx509.so
184%{_includedir}/mbedtls
59cd7fbe 185%{_includedir}/psa
a3f8074d
JB
186
187%files static
188%defattr(644,root,root,755)
95cbb035 189%{_libdir}/libmbedcrypto.a
a3f8074d 190%{_libdir}/libmbedtls.a
64c8d752 191%{_libdir}/libmbedx509.a
875e57b3
JB
192
193%files apidocs
194%defattr(644,root,root,755)
195%doc apidoc/*
This page took 0.735847 seconds and 4 git commands to generate.