]> git.pld-linux.org Git - packages/createrepo_c.git/blame - createrepo_c.spec
- typos
[packages/createrepo_c.git] / createrepo_c.spec
CommitLineData
eb85e3be
JB
1# TODO: tests fail (rpm.org vs rpm5 compat problems?)
2#
3# Conditional build:
807f0e8d 4%bcond_without python3 # CPython 3.x module
16c66ee9 5%bcond_with tests # make tests
7ab42891 6
eb85e3be
JB
7Summary: Creates a common metadata repository
8Summary(pl.UTF-8): Tworzenie wspólnego repozytorium metadanych
9Name: createrepo_c
807f0e8d 10Version: 0.10.0
7ab42891 11Release: 1
eb85e3be
JB
12License: GPL v2+
13Group: Applications/System
807f0e8d
JB
14#Source0Download: https://github.com/rpm-software-management/createrepo_c/releases
15Source0: https://github.com/rpm-software-management/createrepo_c/archive/%{version}/%{name}-%{version}.tar.gz
16# Source0-md5: 2e14b3e5d289875b894000ab1e54f1ec
eb85e3be 17Patch0: %{name}-rpm5.patch
16c66ee9 18Patch1: %{name}-python.patch
807f0e8d 19Patch2: %{name}-include.patch
bd7532a4 20Patch3: %{name}-bashcompdir.patch
807f0e8d 21URL: https://github.com/rpm-software-management/createrepo_c
eb85e3be
JB
22BuildRequires: bzip2-devel
23BuildRequires: check-devel
24BuildRequires: cmake >= 2.6
25BuildRequires: curl-devel
26BuildRequires: doxygen
27BuildRequires: expat-devel
28BuildRequires: glib2-devel >= 1:2.22.0
29BuildRequires: libmagic-devel
30BuildRequires: libxml2-devel >= 2
31BuildRequires: openssl-devel
32BuildRequires: python-devel >= 2
33%{?with_tests:BuildRequires: python-nose}
807f0e8d
JB
34%if %{with python3}
35BuildRequires: python3-devel >= 1:3.2
36%{?with_tests:BuildRequires: python3-nose}
37%endif
eb85e3be
JB
38BuildRequires: rpm-devel >= 5
39BuildRequires: rpm-pythonprov
7fe79feb 40BuildRequires: rpmbuild(macros) >= 1.673
16c66ee9 41BuildRequires: sphinx-pdg-2
eb85e3be 42BuildRequires: sqlite3-devel >= 3
eb85e3be
JB
43BuildRequires: xz-devel
44BuildRequires: zlib-devel
45Requires: %{name}-libs = %{version}-%{release}
46BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
47
48%description
49C implementation of Createrepo. This utility will generate a common
50metadata repository from a directory of RPM packages.
51
52%description -l pl.UTF-8
53Implementacja w C programu Createrepo. To narzędzie generuje wspólne
54repozytorium metadanych z katalogu pakietów RPM.
55
56%package libs
57Summary: Library for repodata manipulation
58Summary(pl.UTF-8): Biblioteka do operacji na danych repozytorium
59Group: Libraries
60Requires: glib2 >= 1:2.22.0
61
62%description libs
63This package contains the createrepo_c library for applications to
64easy manipulate with a repodata.
65
66%description libs -l pl.UTF-8
67Ten pakiet zawiera bibliotekę createrepo_c, pozwalającą aplikacjom na
68łatwe operowanie na danych repozytorium (repodata).
69
70%package devel
71Summary: Header files for createrepo_c library
72Summary(pl.UTF-8): Pliki nagłówkowe biblioteki createrepo_c
73Group: Development/Libraries
74Requires: %{name}-libs = %{version}-%{release}
75Requires: bzip2-devel
76Requires: curl-devel
77Requires: expat-devel
78Requires: glib2-devel >= 1:2.22.0
79Requires: libmagic-devel
80Requires: libxml2-devel >= 2
81Requires: rpm-devel >= 5
82Requires: sqlite3-devel >= 3
83Requires: xz-devel
84Requires: zlib-devel
85
86%description devel
87This package contains the createrepo_c C header files. These
88development files are for easy manipulation with a repodata.
89
90%description devel -l pl.UTF-8
7ab42891
ER
91Ten pakiet zawiera pliki nagłówkowe C biblioteki createrepo_c. Mają na
92celu łatwe operowanie na danych repozytorium (repodata).
eb85e3be
JB
93
94%package apidocs
95Summary: API documentation for createrepo_c library
96Summary(pl.UTF-8): Dokumentacja API biblioteki createrepo_c
97Group: Documentation
98
99%description apidocs
100API documentation for createrepo_c library.
101
102%description apidocs -l pl.UTF-8
103Dokumentacja API biblioteki createrepo_c.
104
105%package -n python-createrepo_c
807f0e8d
JB
106Summary: Python 2 bindings for the createrepo_c library
107Summary(pl.UTF-8): Wiązania Pythona 2 do biblioteki createrepo_c
eb85e3be
JB
108Group: Development/Languages/Python
109Requires: %{name}-libs = %{version}-%{release}
110
111%description -n python-createrepo_c
807f0e8d 112Python 2 bindings for the createrepo_c library.
eb85e3be
JB
113
114%description -n python-createrepo_c -l pl.UTF-8
807f0e8d
JB
115Wiązania Pythona 2 do biblioteki createrepo_c.
116
117%package -n python3-createrepo_c
118Summary: Python 3 bindings for the createrepo_c library
119Summary(pl.UTF-8): Wiązania Pythona 3 do biblioteki createrepo_c
120Group: Development/Languages/Python
121Requires: %{name}-libs = %{version}-%{release}
122
123%description -n python3-createrepo_c
124Python 3 bindings for the createrepo_c library.
125
126%description -n python3-createrepo_c -l pl.UTF-8
127Wiązania Pythona 3 do biblioteki createrepo_c.
eb85e3be
JB
128
129%package -n bash-completion-createrepo_c
130Summary: Bash completion for createrepo_c commands
131Summary(pl.UTF-8): Bashowe uzupełnianie dla poleceń createrepo_c
132Group: Applications/Shells
133Requires: %{name} = %{version}-%{release}
bd7532a4 134Requires: bash-completion >= 2.0
eb85e3be
JB
135
136%description -n bash-completion-createrepo_c
137Bash completion for createrepo_c commands (createrepo_c, mergerepo_c,
138modifyrepo_c).
139
140%description -n bash-completion-createrepo_c -l pl.UTF-8
141Bashowe uzupełnianie dla poleceń createrepo_c (createrepo_c,
142mergerepo_c, modifyrepo_c).
143
144%prep
807f0e8d 145%setup -q
eb85e3be 146%patch0 -p1
16c66ee9 147%patch1 -p1
807f0e8d 148%patch2 -p1
7fe79feb 149%patch3 -p1
eb85e3be
JB
150
151%build
807f0e8d
JB
152install -d build %{?with_python3:build-py3}
153
154cd build
bd7532a4 155%cmake .. \
7fe79feb 156 -DBASHCOMP_DIR=%{bash_compdir}
16c66ee9 157
eb85e3be
JB
158%{__make}
159%{__make} doc
160
161%if %{with tests}
162%{__make} tests
163%{__make} test \
164 ARGS="-V"
165%endif
807f0e8d
JB
166cd ..
167
168%if %{with python3}
169cd build-py3
170%cmake .. \
7fe79feb 171 -DBASHCOMP_DIR=%{bash_compdir} \
807f0e8d
JB
172 -DPYTHON_DESIRED=3
173
174%{__make}
175
176%if %{with tests}
177%{__make} tests
178%{__make} test \
179 ARGS="-V"
180%endif
181cd ..
182%endif
eb85e3be
JB
183
184%install
185rm -rf $RPM_BUILD_ROOT
186
807f0e8d
JB
187%if %{with python3}
188%{__make} -C build-py3 install \
189 DESTDIR=$RPM_BUILD_ROOT
190%py3_comp $RPM_BUILD_ROOT%{py3_sitedir}/createrepo_c
191%py3_ocomp $RPM_BUILD_ROOT%{py3_sitedir}/createrepo_c
192%endif
193
194%{__make} -C build install \
eb85e3be
JB
195 DESTDIR=$RPM_BUILD_ROOT
196
197%py_comp $RPM_BUILD_ROOT%{py_sitedir}/createrepo_c
198%py_ocomp $RPM_BUILD_ROOT%{py_sitedir}/createrepo_c
199%py_postclean
200
201%clean
202rm -rf $RPM_BUILD_ROOT
203
204%post libs -p /sbin/ldconfig
205%postun libs -p /sbin/ldconfig
206
207%files
208%defattr(644,root,root,755)
209%attr(755,root,root) %{_bindir}/createrepo_c
210%attr(755,root,root) %{_bindir}/mergerepo_c
211%attr(755,root,root) %{_bindir}/modifyrepo_c
807f0e8d 212%attr(755,root,root) %{_bindir}/sqliterepo_c
eb85e3be
JB
213%{_mandir}/man8/createrepo_c.8*
214%{_mandir}/man8/mergerepo_c.8*
7ab42891 215%{_mandir}/man8/modifyrepo_c.8*
807f0e8d 216%{_mandir}/man8/sqliterepo_c.8*
eb85e3be
JB
217
218%files libs
219%defattr(644,root,root,755)
220%doc AUTHORS README.md
221%attr(755,root,root) %{_libdir}/libcreaterepo_c.so.*.*.*
222%attr(755,root,root) %ghost %{_libdir}/libcreaterepo_c.so.0
223
224%files devel
225%defattr(644,root,root,755)
226%attr(755,root,root) %{_libdir}/libcreaterepo_c.so
227%{_pkgconfigdir}/createrepo_c.pc
228%{_includedir}/createrepo_c
229
230%files apidocs
231%defattr(644,root,root,755)
807f0e8d 232%doc build/doc/html
eb85e3be
JB
233
234%files -n python-createrepo_c
235%defattr(644,root,root,755)
236%dir %{py_sitedir}/createrepo_c
807f0e8d 237%attr(755,root,root) %{py_sitedir}/createrepo_c/_createrepo_c.so
eb85e3be
JB
238%{py_sitedir}/createrepo_c/__init__.py[co]
239
807f0e8d
JB
240%if %{with python3}
241%files -n python3-createrepo_c
242%defattr(644,root,root,755)
243%dir %{py3_sitedir}/createrepo_c
244%attr(755,root,root) %{py3_sitedir}/createrepo_c/_createrepo_c.so
245%{py3_sitedir}/createrepo_c/__init__.py
246%{py3_sitedir}/createrepo_c/__pycache__
247%endif
248
eb85e3be
JB
249%files -n bash-completion-createrepo_c
250%defattr(644,root,root,755)
bd7532a4
JB
251%{bash_compdir}/createrepo_c
252%{bash_compdir}/mergerepo_c
253%{bash_compdir}/modifyrepo_c
254%{bash_compdir}/sqliterepo_c
This page took 0.12501 seconds and 4 git commands to generate.