]> git.pld-linux.org Git - packages/createrepo_c.git/blob - createrepo_c.spec
up to 1.1.0
[packages/createrepo_c.git] / createrepo_c.spec
1 # TODO: tests fail (rpm.org vs rpm5 compat problems?)
2 #
3 # Conditional build:
4 %bcond_with     tests   # make tests
5
6 %define         gitrev  7ef96a6
7 Summary:        Creates a common metadata repository
8 Summary(pl.UTF-8):      Tworzenie wspólnego repozytorium metadanych
9 Name:           createrepo_c
10 Version:        0.4.0
11 Release:        1
12 License:        GPL v2+
13 Group:          Applications/System
14 # git clone https://github.com/Tojaj/createrepo_c
15 Source0:        http://pkgs.fedoraproject.org/repo/pkgs/createrepo_c/%{name}-%{gitrev}.tar.xz/606d117677ab85e5a9ec15896db644c2/createrepo_c-%{gitrev}.tar.xz
16 # Source0-md5:  606d117677ab85e5a9ec15896db644c2
17 Patch0:         %{name}-rpm5.patch
18 Patch1:         %{name}-python.patch
19 URL:            https://github.com/Tojaj/createrepo_c
20 BuildRequires:  bzip2-devel
21 BuildRequires:  check-devel
22 BuildRequires:  cmake >= 2.6
23 BuildRequires:  curl-devel
24 BuildRequires:  doxygen
25 BuildRequires:  expat-devel
26 BuildRequires:  glib2-devel >= 1:2.22.0
27 BuildRequires:  libmagic-devel
28 BuildRequires:  libxml2-devel >= 2
29 BuildRequires:  openssl-devel
30 BuildRequires:  python-devel >= 2
31 %{?with_tests:BuildRequires:    python-nose}
32 BuildRequires:  rpm-devel >= 5
33 BuildRequires:  rpm-pythonprov
34 BuildRequires:  rpmbuild(macros) >= 1.219
35 BuildRequires:  sphinx-pdg-2
36 BuildRequires:  sqlite3-devel >= 3
37 BuildRequires:  tar >= 1:1.22
38 BuildRequires:  xz
39 BuildRequires:  xz-devel
40 BuildRequires:  zlib-devel
41 Requires:       %{name}-libs = %{version}-%{release}
42 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44 %description
45 C implementation of Createrepo. This utility will generate a common
46 metadata repository from a directory of RPM packages.
47
48 %description -l pl.UTF-8
49 Implementacja w C programu Createrepo. To narzędzie generuje wspólne
50 repozytorium metadanych z katalogu pakietów RPM.
51
52 %package libs
53 Summary:        Library for repodata manipulation
54 Summary(pl.UTF-8):      Biblioteka do operacji na danych repozytorium
55 Group:          Libraries
56 Requires:       glib2 >= 1:2.22.0
57
58 %description libs
59 This package contains the createrepo_c library for applications to
60 easy manipulate with a repodata.
61
62 %description libs -l pl.UTF-8
63 Ten pakiet zawiera bibliotekę createrepo_c, pozwalającą aplikacjom na
64 łatwe operowanie na danych repozytorium (repodata).
65
66 %package devel
67 Summary:        Header files for createrepo_c library
68 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki createrepo_c
69 Group:          Development/Libraries
70 Requires:       %{name}-libs = %{version}-%{release}
71 Requires:       bzip2-devel
72 Requires:       curl-devel
73 Requires:       expat-devel
74 Requires:       glib2-devel >= 1:2.22.0
75 Requires:       libmagic-devel
76 Requires:       libxml2-devel >= 2
77 Requires:       rpm-devel >= 5
78 Requires:       sqlite3-devel >= 3
79 Requires:       xz-devel
80 Requires:       zlib-devel
81
82 %description devel
83 This package contains the createrepo_c C header files. These
84 development files are for easy manipulation with a repodata.
85
86 %description devel -l pl.UTF-8
87 Ten pakiet zawiera pliki nagłówkowe C biblioteki createrepo_c. Mają na
88 celu łatwe operowanie na danych repozytorium (repodata).
89
90 %package apidocs
91 Summary:        API documentation for createrepo_c library
92 Summary(pl.UTF-8):      Dokumentacja API biblioteki createrepo_c
93 Group:          Documentation
94
95 %description apidocs
96 API documentation for createrepo_c library.
97
98 %description apidocs -l pl.UTF-8
99 Dokumentacja API biblioteki createrepo_c.
100
101 %package -n python-createrepo_c
102 Summary:        Python bindings for the createrepo_c library
103 Summary(pl.UTF-8):      Wiązania Pythona do biblioteki createrepo_c
104 Group:          Development/Languages/Python
105 Requires:       %{name}-libs = %{version}-%{release}
106
107 %description -n python-createrepo_c
108 Python bindings for the createrepo_c library.
109
110 %description -n python-createrepo_c -l pl.UTF-8
111 Wiązania Pythona do biblioteki createrepo_c.
112
113 %package -n bash-completion-createrepo_c
114 Summary:        Bash completion for createrepo_c commands
115 Summary(pl.UTF-8):      Bashowe uzupełnianie dla poleceń createrepo_c
116 Group:          Applications/Shells
117 Requires:       %{name} = %{version}-%{release}
118 Requires:       bash-completion
119
120 %description -n bash-completion-createrepo_c
121 Bash completion for createrepo_c commands (createrepo_c, mergerepo_c,
122 modifyrepo_c).
123
124 %description -n bash-completion-createrepo_c -l pl.UTF-8
125 Bashowe uzupełnianie dla poleceń createrepo_c (createrepo_c,
126 mergerepo_c, modifyrepo_c).
127
128 %prep
129 %setup -q -n %{name}
130 %patch0 -p1
131 %patch1 -p1
132
133 %build
134 %cmake .
135
136 %{__make}
137 %{__make} doc
138
139 %if %{with tests}
140 %{__make} tests
141 %{__make} test \
142         ARGS="-V"
143 %endif
144
145 %install
146 rm -rf $RPM_BUILD_ROOT
147
148 %{__make} install \
149         DESTDIR=$RPM_BUILD_ROOT
150
151 %py_comp $RPM_BUILD_ROOT%{py_sitedir}/createrepo_c
152 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}/createrepo_c
153 %py_postclean
154
155 %clean
156 rm -rf $RPM_BUILD_ROOT
157
158 %post   libs -p /sbin/ldconfig
159 %postun libs -p /sbin/ldconfig
160
161 %files
162 %defattr(644,root,root,755)
163 %attr(755,root,root) %{_bindir}/createrepo_c
164 %attr(755,root,root) %{_bindir}/mergerepo_c
165 %attr(755,root,root) %{_bindir}/modifyrepo_c
166 %{_mandir}/man8/createrepo_c.8*
167 %{_mandir}/man8/mergerepo_c.8*
168 %{_mandir}/man8/modifyrepo_c.8*
169
170 %files libs
171 %defattr(644,root,root,755)
172 %doc AUTHORS README.md
173 %attr(755,root,root) %{_libdir}/libcreaterepo_c.so.*.*.*
174 %attr(755,root,root) %ghost %{_libdir}/libcreaterepo_c.so.0
175
176 %files devel
177 %defattr(644,root,root,755)
178 %attr(755,root,root) %{_libdir}/libcreaterepo_c.so
179 %{_pkgconfigdir}/createrepo_c.pc
180 %{_includedir}/createrepo_c
181
182 %files apidocs
183 %defattr(644,root,root,755)
184 %doc doc/html
185
186 %files -n python-createrepo_c
187 %defattr(644,root,root,755)
188 %dir %{py_sitedir}/createrepo_c
189 %attr(755,root,root) %{py_sitedir}/createrepo_c/_createrepo_cmodule.so
190 %{py_sitedir}/createrepo_c/__init__.py[co]
191
192 %files -n bash-completion-createrepo_c
193 %defattr(644,root,root,755)
194 /etc/bash_completion.d/createrepo_c.bash
This page took 0.217921 seconds and 3 git commands to generate.