2 # - bash-completion subpackage
3 # - make -DSYSTEMD_DIR actually to work: https://github.com/rpm-software-management/dnf/pull/213
6 %bcond_without tests # build without tests
9 %define hawkey_ver 0.5.2
10 %define librepo_ver 1.7.5
11 %define libcomps_ver 0.1.6
14 Summary: Package manager forked from Yum, using libsolv as a dependency resolver
15 Summary(pl.UTF-8): Zarządca pakietów wywodzący się z Yuma, wykorzystujący libsolv do rozwiązywania zależności
20 # For a breakdown of the licensing, see PACKAGE-LICENSING
21 License: GPL v2+ and GPL v2 and GPL
22 #Source0: http://rpm-software-management.fedorapeople.org/%{name}-%{gitrev}.tar.xz
23 Source0: http://pkgs.fedoraproject.org/repo/pkgs/dnf/%{name}-%{gitrev}.tar.xz/82ff495e445ddc56e70dc91750a421ac/dnf-%{gitrev}.tar.xz
24 # Source0-md5: 82ff495e445ddc56e70dc91750a421ac
26 URL: https://github.com/rpm-software-management/dnf
28 BuildRequires: gettext
29 BuildRequires: gettext-tools
31 BuildRequires: python-Sphinx
32 #BuildRequires: python-bugzilla
33 BuildRequires: python-hawkey >= %{hawkey_ver}
34 BuildRequires: python-iniparse
35 BuildRequires: python-libcomps >= %{libcomps_ver}
36 BuildRequires: python-librepo >= %{librepo_ver}
37 BuildRequires: python-nose
38 BuildRequires: python-pygpgme
39 BuildRequires: python-rpm >= %{rpm_ver}
40 BuildRequires: rpm-pythonprov
41 BuildRequires: rpmbuild(macros) >= 1.647
42 BuildRequires: sed >= 4.0
43 BuildRequires: sphinx-pdg
44 BuildRequires: systemd-devel
46 BuildRequires: python-hawkey-test >= %{hawkey_ver}
47 BuildRequires: python-pyliblzma
49 Requires(post,preun,postun): systemd-units >= 38
51 Requires: python-hawkey >= %{hawkey_ver}
52 Requires: python-iniparse
53 Requires: python-libcomps >= %{libcomps_ver}
54 Requires: python-librepo >= %{librepo_ver}
55 Requires: python-pygpgme
56 Requires: python-rpm >= %{rpm_ver}
57 #Requires: rpm-plugin-systemd-inhibit
58 Requires: systemd-units >= 0.38
60 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
63 Package manager forked from Yum, using libsolv as a dependency
66 %description -l pl.UTF-8
67 Zarządca pakietów wywodzący się z Yuma, wykorzystujący libsolv do
68 rozwiązywania zależności.
71 Summary: Alternative CLI to "dnf upgrade" suitable for automatic, regular execution
72 Summary(pl.UTF-8): Alternatywny interfejs do "dnf upgrade" nadający się do automatycznego wywoływania
74 Requires(post): systemd
75 Requires(preun): systemd
76 Requires(postun): systemd
77 Requires: %{name} = %{version}-%{release}
79 %description automatic
80 Alternative CLI to "dnf upgrade" suitable for automatic, regular
83 %description automatic -l pl.UTF-8
84 Alternatywny interfejs linii poleceń do "dnf upgrade", nadający się do
85 automatycznego, regularnego wywoływania.
92 %{__sed} -i -e '/SYSTEMD_DIR/ s#/usr/lib/systemd/system#%{systemdunitdir}#' CMakeLists.txt
96 -DCMAKE_CXX_COMPILER_WORKS=1 -DCMAKE_CXX_COMPILER="%{__cc}" \
98 -DSYSTEMD_DIR=%{systemdunitdir} \
105 %{__make} test ARGS="-V"
109 rm -rf $RPM_BUILD_ROOT
111 DESTDIR=$RPM_BUILD_ROOT
113 %py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
114 %py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
119 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/%{name}/plugins,%{py_sitescriptdir}/dnf-plugins,%{_localstatedir}/log}
120 touch $RPM_BUILD_ROOT%{_localstatedir}/log/%{name}{,-rpm,-plugin}.log
123 rm -rf $RPM_BUILD_ROOT
126 %systemd_post dnf-makecache.timer
129 %systemd_preun dnf-makecache.timer
135 %systemd_post dnf-automatic.timer
138 %systemd_preun dnf-automatic.timer
143 %files -f %{name}.lang
144 %defattr(644,root,root,755)
145 %doc AUTHORS README.rst COPYING PACKAGE-LICENSING
146 %attr(755,root,root) %{_bindir}/dnf
147 %dir %{_sysconfdir}/%{name}
148 %dir %{_sysconfdir}/%{name}/plugins
149 %dir %{_sysconfdir}/%{name}/protected.d
150 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/dnf.conf
151 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/protected.d/dnf.conf
152 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/libreport/events.d/collect_dnf.conf
153 %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name}
154 %{_mandir}/man8/dnf.8*
155 %{_mandir}/man8/dnf.conf.8*
156 %{systemdunitdir}/dnf-makecache.service
157 %{systemdunitdir}/dnf-makecache.timer
158 %{py_sitescriptdir}/dnf
159 %exclude %{py_sitescriptdir}/dnf/automatic
161 %ghost %{_localstatedir}/log/%{name}.log
162 %ghost %{_localstatedir}/log/%{name}-rpm.log
163 %ghost %{_localstatedir}/log/%{name}-plugin.log
164 /etc/bash_completion.d/dnf-completion.bash
167 %defattr(644,root,root,755)
168 %attr(755,root,root) %{_bindir}/dnf-automatic
169 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/automatic.conf
170 %{_mandir}/man8/dnf.automatic.8*
171 %{systemdunitdir}/dnf-automatic.service
172 %{systemdunitdir}/dnf-automatic.timer
173 %{py_sitescriptdir}/dnf/automatic