From 44985cdca7a0519b5aec15da6b741a688cf7c3ef Mon Sep 17 00:00:00 2001 From: yeshanshan Date: Wed, 21 Jan 2026 11:06:00 +0800 Subject: [PATCH] chore: remove dtk5/6 version differentiation in build rules MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. Removed DTK5_VERSION and DTK6_VERSION variable definitions that were derived from DEB_VERSION_UPSTREAM 2. Removed DTK5_MAJOR_MINOR variable calculation 3. Removed override_dh_makeshlibs target that set different version dependencies for DTK5 and DTK6 4. Simplified build system to use consistent versioning between DTK5 and DTK6 The changes were made as part of DTK unified build transformation where DTK5 and DTK6 now share the same version numbers. Previously, the build system automatically generated different version numbers for DTK5 and DTK6 based on the upstream version (e.g., 5.6.8 would become DTK5_VERSION=5.6.8 and DTK6_VERSION=6.6.8). Now that both DTK5 and DTK6 use the same version scheme, this differentiation is no longer needed. The dh_makeshlibs override that set different minimum version dependencies for DTK5 and DTK6 libraries has also been removed since they now share versioning. Influence: 1. Verify that DTK5 and DTK6 packages are built with identical version numbers 2. Test that library dependencies are correctly resolved without version conflicts 3. Ensure backward compatibility with existing installations 4. Validate that both DTK5 and DTK6 components can be installed simultaneously 5. Test package upgrades from previous versions with different versioning schemes chore: 移除构建规则中dtk5/6版本差异化处理 1. 删除了从DEB_VERSION_UPSTREAM派生的DTK5_VERSION和DTK6_VERSION变量定义 2. 删除了DTK5_MAJOR_MINOR变量计算 3. 删除了为DTK5和DTK6设置不同版本依赖的override_dh_makeshlibs目标 4. 简化了构建系统,使DTK5和DTK6使用一致的版本控制 这些更改是DTK统一构建改造的一部分,现在DTK5和DTK6使用相同的版本号。之 前,构建系统会根据上游版本自动为DTK5和DTK6生成不同的版本号(例如,5.6.8 会变成DTK5_VERSION=5.6.8和DTK6_VERSION=6.6.8)。现在DTK5和DTK6使用相同的 版本方案,不再需要这种差异化处理。同时移除了为DTK5和DTK6库设置不同最低版 本依赖的dh_makeshlibs覆盖,因为它们现在共享版本控制。 Influence: 1. 验证DTK5和DTK6包是否使用相同的版本号构建 2. 测试库依赖关系是否能正确解析,没有版本冲突 3. 确保与现有安装的向后兼容性 4. 验证DTK5和DTK6组件是否可以同时安装 5. 测试从先前使用不同版本方案的版本进行包升级 --- debian/rules | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/debian/rules b/debian/rules index c27d2303..5e2baf9f 100755 --- a/debian/rules +++ b/debian/rules @@ -14,10 +14,6 @@ DEB_CMAKE_EXTRA_FLAGS += -DCMAKE_SKIP_BUILD_RPATH=ON DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) -# x.y.z -> DTK5_VERSION=5.y.z, DTK6_VERSION=6.y.z -DTK5_VERSION := $(shell echo $(DEB_VERSION_UPSTREAM) | sed -E 's/^[0-9]+(\.|[^0-9]|$$)/5\1/') -DTK6_VERSION := $(shell echo $(DEB_VERSION_UPSTREAM) | sed -E 's/^[0-9]+(\.|[^0-9]|$$)/6\1/') - # Calculate build version: # 5.6.8 -> 0; 5.6.8.7 -> 7; 5.6.8+u001 -> 1; 5.6.8.7+u001 -> 7; 5.6.8.0+u001 -> 0 BUILD_VER := $(shell echo $(DEB_VERSION_UPSTREAM) | awk -F'[+_~-]' '{print $$1}' | awk -F'.' '{print $$4}' | sed 's/[^0-9]//g' | awk '{print int($$1)}') @@ -27,7 +23,6 @@ ifeq ($(shell expr $(shell echo "$(DEB_VERSION_UPSTREAM)" | awk -F. '{print NF-1 endif endif -DTK5_MAJOR_MINOR := $(shell echo $(DTK5_VERSION) | cut -d '.' -f 1,2) BUILD_DOCS := $(if $(filter nodoc,$(DEB_BUILD_PROFILES)),OFF,ON) BUILD_DTK5 := $(if $(filter nodtk5,$(DEB_BUILD_PROFILES)),OFF,ON) BUILD_DTK6 := $(if $(filter nodtk6,$(DEB_BUILD_PROFILES)),OFF,ON) @@ -61,14 +56,6 @@ ifeq ($(BUILD_DTK6),ON) dh_auto_install --builddirectory=build6 endif -override_dh_makeshlibs: -ifeq ($(BUILD_DTK5),ON) - dh_makeshlibs -V "libdtkcore5 (>= $(DTK5_MAJOR_MINOR))" -plibdtkcore5 -endif -ifeq ($(BUILD_DTK6),ON) - dh_makeshlibs -V "libdtk6core (>= $(DTK6_VERSION))" -plibdtk6core -endif - override_dh_link: ifeq ($(BUILD_DTK5),ON) dh_link usr/lib/$(DEB_HOST_MULTIARCH)/libdtkcore.so.5 usr/lib/$(DEB_HOST_MULTIARCH)/libdtkcore.so -p libdtkcore-dev