diff --git a/aardvark-dns.spec b/aardvark-dns.spec index 6f2bbc4..18944b9 100644 --- a/aardvark-dns.spec +++ b/aardvark-dns.spec @@ -1,21 +1,51 @@ -# debuginfo doesn't work yet -%global debug_package %{nil} +# trust-dns-{client,server} not available +# using vendored deps + +%global with_debug 1 + +%if 0%{?with_debug} +%global _find_debuginfo_dwz_opts %{nil} +%global _dwz_low_mem_die_limit 0 +%else +%global debug_package %{nil} +%endif -Epoch: 2 Name: aardvark-dns +%if %{defined copr_username} +Epoch: 102 +%else +Epoch: 2 +%endif +# DO NOT TOUCH the Version string! +# The TRUE source of this specfile is: +# https://github.com/containers/podman/blob/main/rpm/podman.spec +# If that's what you're reading, Version must be 0, and will be updated by Packit for +# copr and koji builds. +# If you're reading this on dist-git, the version is automatically filled in by Packit. Version: 1.13.1 -License: ASL 2.0 and BSD and MIT +# The `AND` needs to be uppercase in the License for SPDX compatibility +License: Apache-2.0 AND MIT AND Zlib Release: 1%{?dist} -ExclusiveArch: %{rust_arches} +%if %{defined golang_arches_future} +ExclusiveArch: %{golang_arches_future} +%else +ExclusiveArch: aarch64 ppc64le s390x x86_64 +%endif Summary: Authoritative DNS server for A/AAAA container records -URL: https://github.com/containers/aardvark-dns +URL: https://github.com/containers/%{name} +# Tarballs fetched from upstream's release page Source0: %{url}/archive/v%{version}.tar.gz Source1: %{url}/releases/download/v%{version}/%{name}-v%{version}-vendor.tar.gz BuildRequires: cargo BuildRequires: git-core BuildRequires: make +%if %{defined rhel} +# rust-toolset requires the `local` repo enabled on non-koji ELN build environments +BuildRequires: rust-toolset +%else +BuildRequires: rust-packaging BuildRequires: rust-srpm-macros -Conflicts: netavark < %{epoch}:%{version} +%endif %description %{summary} @@ -24,109 +54,40 @@ Forwards other request to configured resolvers. Read more about configuration in `src/backend/mod.rs`. %prep -%autosetup -Sgit +%autosetup -Sgit %{name}-%{version} +# Following steps are only required on environments like koji which have no +# network access and thus depend on the vendored tarball. Copr pulls +# dependencies directly from the network. +%if !%{defined copr_username} tar fx %{SOURCE1} -mkdir -p .cargo - -cat >.cargo/config << EOF -[source.crates-io] -replace-with = "vendored-sources" - -[source.vendored-sources] -directory = "vendor" - -[net] -offline = true -EOF +%if 0%{?fedora} || 0%{?rhel} >= 10 +%cargo_prep -v vendor +%else +%cargo_prep -V 1 +%endif +%endif %build -%{__make} build +%{__make} CARGO="%{__cargo}" build +%if (0%{?fedora} || 0%{?rhel} >= 10) && !%{defined copr_username} +%cargo_license_summary +%{cargo_license} > LICENSE.dependencies +%cargo_vendor_manifest +%endif %install %{__make} DESTDIR=%{buildroot} PREFIX=%{_prefix} install %files %license LICENSE +%if (0%{?fedora} || 0%{?rhel} >= 10) && !%{defined copr_username} +%license LICENSE.dependencies +%license cargo-vendor.txt +%endif %dir %{_libexecdir}/podman %{_libexecdir}/podman/%{name} %changelog -* Wed Nov 27 2024 Jindrich Novy - 2:1.13.1-1 +* Wed Nov 13 2024 Jindrich Novy - 2:1.13.1-1 - update to https://github.com/containers/aardvark-dns/releases/tag/v1.13.1 - Related: RHEL-60277 - -* Wed Oct 30 2024 Jindrich Novy - 2:1.13.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.13.0 -- Resolves: RHEL-57695 - -* Wed Sep 04 2024 Jindrich Novy - 2:1.12.2-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.12.2 -- Related: RHEL-27608 - -* Mon Aug 05 2024 Jindrich Novy - 2:1.12.1-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.12.1 -- Related: RHEL-27608 - -* Mon Jun 03 2024 Jindrich Novy - 2:1.11.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.11.0 -- Related: RHEL-27608 - -* Mon Apr 08 2024 Lokesh Mandvekar - 2:1.10.0-2 -- rebuild for gating tests -- Related: RHEL-31950 - -* Wed Jan 24 2024 Jindrich Novy - 2:1.10.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.10.0 -- Related: RHEL-2112 - -* Wed Dec 06 2023 Lokesh Mandvekar - 2:1.9.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.9.0 -- Related: Jira:RHEL-2112 - -* Fri Sep 29 2023 Jindrich Novy - 2:1.8.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.8.0 -- Related: Jira:RHEL-2112 - -* Fri Jul 07 2023 Jindrich Novy - 2:1.7.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.7.0 -- Related: #2176063 - -* Wed Apr 12 2023 Jindrich Novy - 2:1.6.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.6.0 -- Related: #2176063 - -* Fri Feb 03 2023 Jindrich Novy - 2:1.5.0-2 -- build always offline -- Related: #2124478 - -* Fri Feb 03 2023 Jindrich Novy - 2:1.5.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.5.0 -- Related: #2124478 - -* Thu Dec 08 2022 Jindrich Novy - 2:1.4.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.4.0 -- Related: #2124478 - -* Wed Nov 16 2022 Jindrich Novy - 2:1.3.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.3.0 -- Related: #2124478 - -* Tue Oct 18 2022 Jindrich Novy - 2:1.2.0-1 -- update to https://github.com/containers/aardvark-dns/releases/tag/v1.2.0 -- Related: #2124478 - -* Wed Aug 24 2022 Jindrich Novy - 2:1.1.0-4 -- remove windows binaries and regenerate vendor tarball -- Related: #2061316 - -* Tue Aug 23 2022 Jindrich Novy - 2:1.1.0-3 -- conflict with older versions than aardvark-dns itself -- Related: #2061316 - -* Thu Aug 04 2022 Jindrich Novy - 2:1.1.0-2 -- add Epoch to preserve upgrade path -- Related: #2061316 - -* Wed Aug 3 2022 Jindrich Novy 1.1.0-1 -- initial import -- Related: #2061316