Skip to content
This repository was archived by the owner on Jul 15, 2026. It is now read-only.

Commit 899c949

Browse files
committed
feat: add reproducible build parameters
1. Added CMAKE_SKIP_BUILD_RPATH=ON flag to DEB_CMAKE_EXTRA_FLAGS 2. Modified dh_auto_configure to include DEB_CMAKE_EXTRA_FLAGS in CMake configuration 3. This ensures reproducible builds by skipping RPATH embedding during compilation 4. Improves package consistency across different build environments Influence: 1. Verify that builds are reproducible across different systems 2. Test package installation and runtime functionality 3. Check that library paths are resolved correctly without embedded RPATH 4. Validate that the build process completes successfully with new flags feat: 添加可重复编译参数 1. 向 DEB_CMAKE_EXTRA_FLAGS 添加 CMAKE_SKIP_BUILD_RPATH=ON 标志 2. 修改 dh_auto_configure 以在 CMake 配置中包含 DEB_CMAKE_EXTRA_FLAGS 3. 通过在编译期间跳过 RPATH 嵌入来确保可重复构建 4. 提高不同构建环境中包的一致性 Influence: 1. 验证在不同系统上的构建是否可重复 2. 测试包安装和运行时功能 3. 检查在没有嵌入 RPATH 的情况下库路径是否正确解析 4. 验证构建过程是否使用新标志成功完成
1 parent 7ca5466 commit 899c949

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

debian/rules

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ export DEB_CFLAGS_MAINT_APPEND = -Wall
88
export DEB_CXXFLAGS_MAINT_APPEND = -Wall
99
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack -Wl,-E
1010

11+
# reproducible编译参数
12+
DEB_CMAKE_EXTRA_FLAGS += -DCMAKE_SKIP_BUILD_RPATH=ON
13+
1114
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
1215

1316
VERSION = $(DEB_VERSION_UPSTREAM)
@@ -23,7 +26,7 @@ endif
2326
dh $@
2427

2528
override_dh_auto_configure:
26-
dh_auto_configure -- -DBUILD_TESTING=OFF -DBUILD_DOCS=ON -DDTK_VERSION=$(_PACK_VER)
29+
dh_auto_configure -- $(DEB_CMAKE_EXTRA_FLAGS) -DBUILD_TESTING=OFF -DBUILD_DOCS=ON -DDTK_VERSION=$(_PACK_VER)
2730

2831
override_dh_makeshlibs:
2932
dh_makeshlibs -V "libdtk6gui (>= $(shell echo $(VERSION) | cut -d '.' -f 1,2,3))"

0 commit comments

Comments
 (0)