Skip to content

Commit 8bb1768

Browse files
Merge pull request #25235 from lsm5/main-build-origin
[skip-ci] RPM: set BUILD_ORIGIN
2 parents a475083 + 3c3baef commit 8bb1768

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

rpm/podman.spec

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,12 @@
3737
# podman-machine subpackage will be present only on these architectures
3838
%global machine_arches x86_64 aarch64
3939

40+
%if %{defined copr_build}
41+
%define build_origin Copr: %{?copr_username}/%{?copr_projectname}
42+
%else
43+
%define build_origin %{?packager}
44+
%endif
45+
4046
Name: podman
4147
%if %{defined copr_build}
4248
Epoch: 102
@@ -234,6 +240,7 @@ export CGO_CFLAGS+=" -m64 -mtune=generic -fcf-protection=full"
234240
export GOPROXY=direct
235241

236242
LDFLAGS="-X %{ld_libpod}/define.buildInfo=${SOURCE_DATE_EPOCH:-$(date +%s)} \
243+
-X \"%{ld_libpod}/define.buildOrigin=%{build_origin}\" \
237244
-X %{ld_libpod}/config._installPrefix=%{_prefix} \
238245
-X %{ld_libpod}/config._etcDir=%{_sysconfdir} \
239246
-X %{ld_project}/pkg/systemd/quadlet._binDir=%{_bindir}"

0 commit comments

Comments
 (0)