Bug#1098253: onevpl-intel-gpu: please make the build reproducible
Chris Lamb
lamby at debian.org
Tue Feb 18 11:51:02 GMT 2025
Source: onevpl-intel-gpu
Version: 24.3.4-1
Severity: wishlist
Tags: patch
User: reproducible-builds at lists.alioth.debian.org
Usertags: kernel
X-Debbugs-Cc: reproducible-bugs at lists.alioth.debian.org
Hi,
Whilst working on the Reproducible Builds effort [0], we noticed that
onevpl-intel-gpu could not be built reproducibly.
This is because the binary embeds the kernel version into one of the
binaries via the MFX_BUILD_INFO macro:
│ │ │ ├── ./usr/lib/x86_64-linux-gnu/libmfx-gen.so.1.2.13
│ │ │ │┄ File has been modified after NT_GNU_BUILD_ID has been applied.
│ │ │ │ ├── readelf --wide --notes {}
│ │ │ │ │ @@ -1,4 +1,4 @@
│ │ │ │ │
│ │ │ │ │ Displaying notes found in: .note.gnu.build-id
│ │ │ │ │ Owner Data size Description
│ │ │ │ │ - GNU 0x00000014 NT_GNU_BUILD_ID (unique build ID bitstring) Build ID: 97c4c33f55d6d62f6a9d25fb95e901bca16c68f0
│ │ │ │ │ + GNU 0x00000014 NT_GNU_BUILD_ID (unique build ID bitstring) Build ID: b144d3a34b074cb0ee714b4ab17c53b2059e6a71
│ │ │ │ ├── strings --all --bytes=8 {}
│ │ │ │ │ @@ -6387,15 +6387,15 @@
│ │ │ │ │ MFX_ERR_INCOMPATIBLE_VIDEO_PARAM
│ │ │ │ │ MFX_WRN_INCOMPATIBLE_VIDEO_PARAM
│ │ │ │ │ ./_studio/mfx_lib/shared/src/libmfxsw.cpp
│ │ │ │ │ APIImpl_MFXReleaseImplDescription
│ │ │ │ │ APIImpl_MFXQueryImplsDescription
│ │ │ │ │ MFXVideoCORE_SetBufferAllocator
│ │ │ │ │ mediasdk_libva_version: 1.22.0
│ │ │ │ │ -mediasdk_build_info: Linux-6.12.9+bpo-amd64 6.12.9+bpo-amd64 | GNU 14.2.0 | glibc 2.40
│ │ │ │ │ +mediasdk_build_info: Linux-6.1.0-31-amd64 6.1.0-31-amd64 | GNU 14.2.0 | glibc 2.40
│ │ │ │ │ mediasdk_copyright: Copyright(c) 2007-2020 Intel Corporation
│ │ │ │ │ mediasdk_product_name: Intel(R) Media SDK
│ │ │ │ │ APIImpl_MFXVideoCORE_SyncOperation
│ │ │ │ │ ./_studio/mfx_lib/shared/src/libmfxsw_async.cpp
A patch is attached that ensures that this value is not passed to the
compiler, resulting in "no build info" (via an #ifndef already in the
code).
An alternative approach is perhaps adding:
export DEB_CPPFLAGS_MAINT_APPEND = -DMFX_BUILD_INFO="no build info"
... to debian/rules, although this will result in "redefinition"
warnings in the build log as it will cause multiple -DMFX_BUILD_INFO="[…]"
comand-line arguments.
[0] https://reproducible-builds.org/
Regards,
--
,''`.
: :' : Chris Lamb
`. `'` lamby at debian.org / chris-lamb.co.uk
`-
-------------- next part --------------
--- a/debian/patches/reproducible-build.patch 1970-01-01 01:00:00.000000000 +0100
--- b/debian/patches/reproducible-build.patch 2025-02-18 11:36:27.514956436 +0000
@@ -0,0 +1,14 @@
+Description: Make the build reproducible
+Author: Chris Lamb <lamby at debian.org>
+Last-Update: 2025-02-18
+
+--- onevpl-intel-gpu-24.3.4.orig/builder/FindGlobals.cmake
++++ onevpl-intel-gpu-24.3.4/builder/FindGlobals.cmake
+@@ -247,7 +247,6 @@ target_compile_definitions(mfx_common_pr
+ INTERFACE
+ ${API_FLAGS}
+ ${WARNING_FLAGS}
+- MFX_BUILD_INFO=\"${BUILD_INFO}\"
+ MFX_API_VERSION=\"${API_VER_MODIF}\"
+ MFX_GIT_COMMIT=\"${git_commit}\"
+ MEDIA_VERSION_STR=\"${MEDIA_VERSION_STR}\"
--- a/debian/patches/series 2025-02-18 11:17:28.157549783 +0000
--- b/debian/patches/series 2025-02-18 11:36:26.514952356 +0000
@@ -1 +1,2 @@
#placeholder
+reproducible-build.patch
More information about the Reproducible-bugs
mailing list