bad1c3c
%global with_debug 1
b38ade2
b38ade2
%if 0%{?with_debug}
b38ade2
%global _find_debuginfo_dwz_opts %{nil}
b38ade2
%global _dwz_low_mem_die_limit 0
b38ade2
%else
b38ade2
%global debug_package %{nil}
b38ade2
%endif
b38ade2
Packit 41788b0
%if %{defined rhel}
32fb4fc
%bcond_with docs
32fb4fc
%else
32fb4fc
%bcond_without docs
32fb4fc
%endif
32fb4fc
a163023
Name: conmon
Packit 41788b0
%if %{defined rhel}
Packit 41788b0
Epoch: 3
Packit 41788b0
%else
b38ade2
Epoch: 2
Packit 41788b0
%endif
Packit 41788b0
Version: 2.1.12
a7071e1
License: Apache-2.0
58c1acf
Release: %autorelease
b38ade2
Summary: OCI container runtime monitor
e9d68b4
URL: https://github.com/containers/%{name}
07afe23
# Tarball fetched from upstream
9d499cd
Source0: %{url}/archive/v%{version}.tar.gz
32fb4fc
%if %{with docs}
e4ca608
ExclusiveArch: %{golang_arches_future}
e9d68b4
BuildRequires: go-md2man
32fb4fc
%endif
e9d68b4
BuildRequires: gcc
e9d68b4
BuildRequires: git-core
b38ade2
BuildRequires: glib2-devel
10d89c6
BuildRequires: libseccomp-devel
0b0604a
BuildRequires: systemd-devel
0b0604a
BuildRequires: systemd-libs
3e19a2c
BuildRequires: make
8a9ef8f
Requires: glib2
0b0604a
Requires: systemd-libs
10d89c6
Requires: libseccomp
b38ade2
b38ade2
%description
b38ade2
%{summary}.
b38ade2
b38ade2
%prep
9d499cd
%autosetup -Sgit %{name}-%{version}
cf03e2d
sed -i 's/install.bin: bin\/conmon/install.bin:/' Makefile
cf03e2d
sed -i 's/install.crio: bin\/conmon/install.crio:/' Makefile
b38ade2
b38ade2
%build
80bd2df
%{__make} DEBUGFLAG="-g" bin/conmon
32fb4fc
32fb4fc
%if %{with docs}
cf03e2d
%{__make} GOMD2MAN=go-md2man -C docs
32fb4fc
%endif
b38ade2
b38ade2
%install
cf03e2d
%{__make} PREFIX=%{buildroot}%{_prefix} install.bin install.crio
32fb4fc
32fb4fc
%if %{with docs}
cf03e2d
%{__make} PREFIX=%{buildroot}%{_prefix} -C docs install
32fb4fc
%endif
b38ade2
b38ade2
#define license tag if not already defined
b38ade2
%{!?_licensedir:%global license %doc}
b38ade2
b38ade2
%files
b38ade2
%license LICENSE
b38ade2
%doc README.md
b38ade2
%{_bindir}/%{name}
3128119
%{_libexecdir}/crio/%{name}
909404b
%dir %{_libexecdir}/crio
32fb4fc
32fb4fc
%if %{with docs}
dc93fcb
%{_mandir}/man8/%{name}.8.gz
32fb4fc
%endif
b38ade2
b38ade2
%changelog
58c1acf
%autochangelog