]> git.pld-linux.org Git - packages/libdigidocpp.git/blob - libdigidocpp.spec
- updated to 3.13.2
[packages/libdigidocpp.git] / libdigidocpp.spec
1 #
2 # Conditional build:
3 %bcond_without  perl            # Perl module
4 %bcond_without  php             # PHP module
5 %bcond_without  python          # Python module
6 %bcond_with     bindings        # build bindings (currently only C#/Win32 and Java/Android supported)
7
8 %if %{without bindings}
9 %undefine       with_perl
10 %undefine       with_php
11 %undefine       with_python
12 %endif
13
14 Summary:        Library for creating and validating BDoc and DDoc containers
15 Summary(pl.UTF-8):      Biblioteka do tworzenia i sprawdzania poprawności kontenerów BDoc i DDoc
16 Name:           libdigidocpp
17 Version:        3.13.2
18 Release:        1
19 License:        LGPL v2.1+
20 Group:          Libraries
21 Source0:        https://github.com/open-eid/libdigidocpp/releases/download/v%{version}/%{name}-%{version}.tar.gz
22 # Source0-md5:  bc7b44fa9ff66669169337f330112ed4
23 Patch0:         %{name}-link.patch
24 URL:            https://github.com/open-eid/libdigidocpp
25 # for tests
26 BuildRequires:  boost-devel
27 BuildRequires:  cmake >= 3.0
28 BuildRequires:  doxygen
29 BuildRequires:  libdigidoc-devel >= 3.9
30 BuildRequires:  libstdc++-devel
31 BuildRequires:  minizip-devel
32 BuildRequires:  openssl-devel >= 1.0.1
33 BuildRequires:  pkgconfig
34 BuildRequires:  rpmbuild(macros) >= 1.583
35 BuildRequires:  xerces-c-devel
36 BuildRequires:  xml-security-c-devel
37 BuildRequires:  xsd >= 4.0
38 BuildRequires:  xxd
39 BuildRequires:  zlib-devel
40 %if %{with perl} || %{with php} || %{with python}
41 BuildRequires:  swig
42 %endif
43 %if %{with perl}
44 BuildRequires:  perl-devel
45 %endif
46 %if %{with php}
47 BuildRequires:  php-devel >= 4:5.0.4
48 %endif
49 %if %{with python}
50 BuildRequires:  python-devel
51 %endif
52 Requires:       libdigidoc >= 3.9
53 Requires:       opensc
54 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
55
56 # std::{__once_call,__once_callable} non-function symbols
57 %define         skip_post_check_so      libdigidocpp.so.*
58
59 %description
60 libdigidocpp is a C++ library for reading, validating, and creating
61 BDoc and DDoc containers. These file formats are widespread in Estonia
62 where they are used for storing legally binding digital signatures.
63
64 %description -l pl.UTF-8
65 libdigidocpp to biblioteka C++ do odczytu, sprawdzania poprawności i
66 tworzenia kontenerów BDoc i DDoc. Te formaty plików są
67 rozpowszechnione w Estonii, gdzie służą do przechowywania umocowanych
68 prawnie podpisów cyfrowych.
69
70 %package devel
71 Summary:        Development files for libdigidocpp library
72 Summary(pl.UTF-8):      Pliki programistyczne biblioteki libdigidocpp
73 Group:          Development/Libraries
74 Requires:       %{name} = %{version}-%{release}
75 Requires:       libstdc++-devel
76
77 %description devel
78 This package contains the header files for developing applications
79 that use libdigidocpp library.
80
81 %description devel -l pl.UTF-8
82 Ten pakiet zawiera pliki nagłówkowe do tworzenia aplikacji
83 wykorzystujących bibliotekę libdigidocpp.
84
85 %package apidocs
86 Summary:        API documentation for libdigidocpp library
87 Summary(pl.UTF-8):      Dokumentacja API biblioteki libdigidocpp
88 Group:          Documentation
89
90 %description apidocs
91 API documentation for libdigidocpp library.
92
93 %description apidocs -l pl.UTF-8
94 Dokumentacja API biblioteki libdigidocpp.
95
96 %package -n perl-digidoc
97 Summary:        Perl bindings for libdigidocpp library
98 Summary(pl.UTF-8):      Wiązania Perla do biblioteki libdigidocpp
99 Group:          Development/Languages/Perl
100 Requires:       %{name} = %{version}-%{release}
101 Provides:       %{name}-perl = %{version}-%{release}
102 Obsoletes:      libdigidocpp-perl < 0.3.0-1
103
104 %description -n perl-digidoc
105 Perl bindings for libdigidocpp library.
106
107 %description -n perl-digidoc -l pl.UTF-8
108 Wiązania Perla do biblioteki libdigidocpp.
109
110 %package -n php-digidoc
111 Summary:        PHP bindings for libdigidocpp library
112 Summary(pl.UTF-8):      Wiązania PHP do biblioteki libdigidocpp
113 Group:          Development/Languages/PHP
114 Requires:       %{name} = %{version}-%{release}
115 %{?requires_php_extension}
116 Provides:       %{name}-php = %{version}-%{release}
117 Obsoletes:      libdigidocpp-php < 0.3.0-1
118
119 %description -n php-digidoc
120 PHP bindings for libdigidocpp library.
121
122 %description -n php-digidoc -l pl.UTF-8
123 Wiązania PHP do biblioteki libdigidocpp.
124
125 %package -n python-digidoc
126 Summary:        Python bindings for libdigidocpp library
127 Summary(pl.UTF-8):      Wiązania Pythona do biblioteki libdigidocpp
128 Group:          Development/Languages/Python
129 Requires:       %{name} = %{version}-%{release}
130 Provides:       %{name}-python = %{version}-%{release}
131 Obsoletes:      libdigidocpp-python < 0.3.0-1
132
133 %description -n python-digidoc
134 Python bindings for libdigidocpp library.
135
136 %description -n python-digidoc -l pl.UTF-8
137 Wiązania Pythona do biblioteki libdigidocpp.
138
139 %prep
140 %setup -q
141 %patch0 -p1
142
143 # Remove bundled copy of minizip
144 %{__rm} -r src/minizip
145
146 %build
147 install -d build
148 cd build
149 %cmake .. \
150         -DCMAKE_INSTALL_DOCDIR=%{_docdir}/%{name}
151
152 %{__make}
153
154 %install
155 rm -rf $RPM_BUILD_ROOT
156
157 %{__make} -C build install \
158         DESTDIR=$RPM_BUILD_ROOT
159
160 # packaged as %doc
161 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
162
163 %clean
164 rm -rf $RPM_BUILD_ROOT
165
166 %post   -p /sbin/ldconfig
167 %postun -p /sbin/ldconfig
168
169 %files
170 %defattr(644,root,root,755)
171 %doc AUTHORS COPYING README.md RELEASE-NOTES.md
172 %dir %{_sysconfdir}/digidocpp
173 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/digidocpp/digidocpp.conf
174 # XXX ?
175 %{_sysconfdir}/digidocpp/878252.p12
176 %{_sysconfdir}/digidocpp/schema
177 %attr(755,root,root) %{_libdir}/libdigidocpp.so.*.*.*
178 %ghost %attr(755,root,root) %{_libdir}/libdigidocpp.so.1
179 %attr(755,root,root) %{_bindir}/digidoc-tool
180 %{_mandir}/man1/digidoc-tool.1*
181
182 %files devel
183 %defattr(644,root,root,755)
184 %attr(755,root,root) %{_libdir}/libdigidocpp.so
185 %{_includedir}/digidocpp
186 %{_pkgconfigdir}/libdigidocpp.pc
187
188 %files apidocs
189 %defattr(644,root,root,755)
190 %doc build/doc/*
191
192 %if %{with perl}
193 %files -n perl-digidoc
194 %defattr(644,root,root,755)
195 %{perl_vendorarch}/*
196 %{perl_vendorlib}/*
197 %endif
198
199 %if %{with php}
200 %files -n php-digidoc
201 %defattr(644,root,root,755)
202 %{php_extensiondir}/*
203 %{php_data_dir}/*
204 %{_sysconfdir}/php.d/digidoc.ini
205 %endif
206
207 %if %{with python}
208 %files -n python-digidoc
209 %defattr(644,root,root,755)
210 %{py_sitedir}/*
211 %endif
This page took 0.070583 seconds and 3 git commands to generate.