diff --git a/.packit.yaml b/.packit.yaml index 8359f26..fd40ab5 100644 --- a/.packit.yaml +++ b/.packit.yaml @@ -29,4 +29,8 @@ actions: jobs: - job: copr_build trigger: pull_request - targets: [fedora-stable, epel-7-x86_64, rhel-8-x86_64, rhel-9-x86_64] + targets: + fedora-stable: {} + epel-7-x86_64: {} + rhel-8-x86_64: {} + rhel-9-x86_64: {} diff --git a/contrib/rpm/host-metering.spec.in b/contrib/rpm/host-metering.spec.in index 06de450..e08c05a 100644 --- a/contrib/rpm/host-metering.spec.in +++ b/contrib/rpm/host-metering.spec.in @@ -1,7 +1,7 @@ %bcond_without check %if 0%{?rhel} <= 7 && ! 0%{?fedora} && ! 0%{?centos} -%define gobuild(o:) scl enable go-toolset-1.19 -- go build -mod vendor -buildmode pie -compiler gc -tags="rpm_crashtraceback ${BUILDTAGS:-}" -ldflags "${GO_LDFLAGS:-} ${LDFLAGS:-} -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \\n') -extldflags '-Wl,-z,relro -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld'" -a -v %{?**}; +%define gobuild(o:) go build -mod vendor -buildmode pie -compiler gc -tags="rpm_crashtraceback ${BUILDTAGS:-}" -ldflags "${GO_LDFLAGS:-} ${LDFLAGS:-} -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \\n') -extldflags '-Wl,-z,relro -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld'" -a -v %{?**}; %endif %if 0%{?rhel} <= 7 && ! 0%{?fedora} && 0%{?centos} @@ -31,7 +31,7 @@ URL: https://github.com/RedHatInsights/host-metering/ Source: %{name}-%{version}.tar.gz %if 0%{?rhel} <= 7 && ! 0%{?fedora} && ! 0%{?centos} -BuildRequires: go-toolset-1.19 +BuildRequires: golang >= 1.19 %else BuildRequires: golang >= 1.19 BuildRequires: systemd-rpm-macros