]> git.pld-linux.org Git - packages/dnf.git/blame - dnf.spec
up to 0.6.3
[packages/dnf.git] / dnf.spec
CommitLineData
feb41732
ER
1# TODO
2# - bash-completion subpackage
3# - make -DSYSTEMD_DIR actually to work
70e5df64
ER
4%define gitrev a7e0aa1
5%define hawkey_version 0.5.2
6%define librepo_version 1.7.5
feb41732 7%define libcomps_version 0.1.6
70e5df64
ER
8%define rpm_version 5.4.0
9
feb41732
ER
10Summary: Package manager forked from Yum, using libsolv as a dependency resolver
11Name: dnf
70e5df64 12Version: 0.6.3
38fbb761 13Release: 0.5
feb41732
ER
14Group: Base
15# For a breakdown of the licensing, see PACKAGE-LICENSING
38fbb761 16License: GPL v2+ and GPL v2 and GPL
70e5df64
ER
17#Source0: http://rpm-software-management.fedorapeople.org/%{name}-%{gitrev}.tar.xz
18Source0: http://pkgs.fedoraproject.org/repo/pkgs/dnf/%{name}-%{gitrev}.tar.xz/82ff495e445ddc56e70dc91750a421ac/dnf-%{gitrev}.tar.xz
19# Source0-md5: 82ff495e445ddc56e70dc91750a421ac
38fbb761 20Patch0: rpm5.patch
70e5df64 21URL: https://github.com/rpm-software-management/dnf
feb41732
ER
22BuildRequires: cmake
23BuildRequires: gettext
24BuildRequires: python
25BuildRequires: python-Sphinx
26#BuildRequires: python-bugzilla
27BuildRequires: python-hawkey >= %{hawkey_version}
28BuildRequires: python-iniparse
29BuildRequires: python-libcomps >= %{libcomps_version}
30BuildRequires: python-librepo >= %{librepo_version}
31BuildRequires: python-nose
70e5df64
ER
32BuildRequires: python-pygpgme
33BuildRequires: python-rpm >= %{rpm_version}
feb41732
ER
34BuildRequires: rpmbuild(macros) >= 1.647
35BuildRequires: sed >= 4.0
36BuildRequires: sphinx-pdg
37BuildRequires: systemd-devel
38Requires(post,preun,postun): systemd-units >= 38
39Requires: deltarpm
40Requires: python-hawkey >= %{hawkey_version}
41Requires: python-iniparse
42Requires: python-libcomps >= %{libcomps_version}
43Requires: python-librepo >= %{librepo_version}
70e5df64
ER
44Requires: python-pygpgme
45Requires: python-rpm >= %{rpm_version}
46#Requires: rpm-plugin-systemd-inhibit
feb41732
ER
47Requires: systemd-units >= 0.38
48BuildArch: noarch
49BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
50
51%description
52Package manager forked from Yum, using libsolv as a dependency
53resolver.
54
70e5df64
ER
55%package automatic
56Summary: Alternative CLI to "dnf upgrade" suitable for automatic, regular execution
57Group: Base
58Requires: %{name} = %{version}-%{release}
59Requires(post): systemd
60Requires(preun): systemd
61Requires(postun): systemd
62
63%description automatic
64Alternative CLI to "dnf upgrade" suitable for automatic, regular
65execution.
66
feb41732
ER
67%prep
68%setup -q -n %{name}
38fbb761 69%patch0 -p1
feb41732
ER
70
71# the -D doesn't work
72%{__sed} -i -e '/SYSTEMD_DIR/ s#/usr/lib/systemd/system#%{systemdunitdir}#' CMakeLists.txt
73
74%build
75%cmake \
70e5df64 76 -DPYTHON_DESIRED=2 \
feb41732
ER
77 -DSYSTEMD_DIR=%{systemdunitdir} \
78 .
79
80%{__make}
81%{__make} doc-man
82
83%if %{with tests}
84%{__make} ARGS="-V" test
85%endif
86
87%install
88rm -rf $RPM_BUILD_ROOT
89%{__make} install \
90 DESTDIR=$RPM_BUILD_ROOT
91
92%py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
93%py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
94%py_postclean
95
feb41732
ER
96%find_lang %{name}
97
70e5df64
ER
98install -d $RPM_BUILD_ROOT{%{_sysconfdir}/%{name}/plugins,%{py_sitescriptdir}/dnf-plugins,%{_localstatedir}/log}
99touch $RPM_BUILD_ROOT%{_localstatedir}/log/%{name}{,-rpm,-plugin}.log
feb41732
ER
100
101%clean
102rm -rf $RPM_BUILD_ROOT
103
104%post
105%systemd_post dnf-makecache.timer
106
107%preun
108%systemd_preun dnf-makecache.timer
109
110%postun
111%systemd_reload
112
70e5df64
ER
113%post automatic
114%systemd_post dnf-automatic.timer
115
116%preun automatic
117%systemd_preun dnf-automatic.timer
118
119%postun automatic
120%systemd_reload
121
feb41732
ER
122%files -f %{name}.lang
123%defattr(644,root,root,755)
124%doc AUTHORS README.rst COPYING PACKAGE-LICENSING
125%attr(755,root,root) %{_bindir}/dnf
126%dir %{_sysconfdir}/%{name}
70e5df64
ER
127%dir %{_sysconfdir}/%{name}/plugins
128%dir %{_sysconfdir}/%{name}/protected.d
feb41732 129%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/dnf.conf
70e5df64 130%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/protected.d/dnf.conf
feb41732
ER
131%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/libreport/events.d/collect_dnf.conf
132%config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name}
133%{_mandir}/man8/dnf.8*
134%{_mandir}/man8/dnf.conf.8*
135%{systemdunitdir}/dnf-makecache.service
136%{systemdunitdir}/dnf-makecache.timer
137%{py_sitescriptdir}/dnf
70e5df64 138%exclude %{py_sitescriptdir}/dnf/automatic
feb41732
ER
139
140%ghost %{_localstatedir}/log/%{name}.log
70e5df64
ER
141%ghost %{_localstatedir}/log/%{name}-rpm.log
142%ghost %{_localstatedir}/log/%{name}-plugin.log
feb41732 143/etc/bash_completion.d/dnf-completion.bash
70e5df64
ER
144
145%files automatic
146%defattr(644,root,root,755)
147%attr(755,root,root) %{_bindir}/dnf-automatic
148%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/automatic.conf
149%{_mandir}/man8/dnf.automatic.8*
150%{systemdunitdir}/dnf-automatic.service
151%{systemdunitdir}/dnf-automatic.timer
152%{py_sitescriptdir}/dnf/automatic
This page took 0.0804 seconds and 4 git commands to generate.