summaryrefslogtreecommitdiff
path: root/netavark.spec
blob: bf59f2cc77a59d412e8ceab50a2fdaca98dfd302 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
# For automatic rebuilds in COPR

# The following tag is to get correct syntax highlighting for this file in vim text editor
# vim: syntax=spec

%global with_debug 0

%if 0%{?with_debug}
%global _find_debuginfo_dwz_opts %{nil}
%global _dwz_low_mem_die_limit 0
%else
%global debug_package %{nil}
%endif

# git_dir_name returns repository name derived from remote Git repository URL
Name:       netavark

Epoch: 101

# git_dir_version returns version based on commit and tag history of the Git project
Version:    0.0.git.855.dbdeb9a7

# This can be useful later for adding downstream patches
Release:    1%{?dist}

# Basic description of the package
Summary: OCI network stack

# License. We assume GPLv2+ here.
License:   ASL 2.0 and BSD and MIT

# Home page of the project. Can also point to the public Git repository page.
URL:        https://github.com/containers/netavark

# Detailed information about the source Git repository and the source commit
# for the created rpm package
VCS:        git+https://github.com/containers/netavark#dbdeb9a7969e5398a8431a192a278986e4e1ae36:

# git_dir_pack macro places the repository content (the source files) into a tarball
# and returns its filename. The tarball will be used to build the rpm.
Source:     netavark-dbdeb9a7.tar.gz

BuildRequires: make
BuildRequires: cargo
BuildRequires: git-core
BuildRequires: golang-github-cpuguy83-md2man
Recommends: aardvark-dns
Provides: container-network-stack
ExclusiveArch:  %{rust_arches}

%global _description %{expand:
OCI network stack.}

%description %{_description}

# The following four sections already describe the rpm build process itself.
# prep will extract the tarball defined as Source above and descend into it.
%prep
#%setup -T -b 0 -q -n netavark
%autosetup -Sgit -T -b 0 -n %{name}

# This will invoke `make` command in the directory with the extracted sources.
%build
%{__make} build
pushd docs
go-md2man -in %{name}.1.md -out %{name}.1
popd

# This will copy the files generated by the `make` command above into
# the installable rpm package.
%install
%{__make} DESTDIR=%{buildroot} PREFIX=%{_prefix} install

# This lists all the files that are included in the rpm package and that
# are going to be installed into target system where the rpm is installed.
%files
%license LICENSE
%dir %{_libexecdir}/podman
%{_libexecdir}/podman/%{name}
%{_mandir}/man1/%{name}.1*

# Finally, changes from the latest release of your application are generated from
# your project's Git history. It will be empty until you make first annotated Git tag.
%changelog