From patchwork Thu Oct 31 13:26:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Thomas_B=C3=B6hler?= X-Patchwork-Id: 13857906 Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05on2101.outbound.protection.outlook.com [40.107.20.101]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5A31C19E999; Thu, 31 Oct 2024 13:26:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.20.101 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730381207; cv=fail; b=du9kNBiu0hN359ZODUBJLSSQOLc6b1RFaASB50AY6hKgKsagZ4gh5f3ot54s5vE2SYrjnnNbfGiRM2XdztMvISjE41fgcCT7qwk9mNGD2kJ2wnWoyPAWZFo6HGkY8h4/fXndF97t2jg7+iHMmuUUAlcTJprjDZTz8Zo/Bvilm8Y= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730381207; c=relaxed/simple; bh=Jz32348WOXCpo55Lgwyh6GJWnQjpGU3LU4ZTn3Mlgko=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=PQ3I2EVv0jUxqN7tdFB9tng6dYDnKqGLV4nYnpb/mA9szuUUREXDQQDd4eAUiwd/TLapV3DLWrl8BCANTQ29Wuz2z1uUkfp6KuRinoqtnAQzXZFNbZS4OcFM9b8Cv//N19BeaX0vRPBtyPb1csLMZ10LnnbLBxpFPcEv89ds/Zw= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=kunbus.com; spf=pass smtp.mailfrom=kunbus.com; dkim=pass (1024-bit key) header.d=kunbus.com header.i=@kunbus.com header.b=vOAjpTZd; arc=fail smtp.client-ip=40.107.20.101 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=kunbus.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=kunbus.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=kunbus.com header.i=@kunbus.com header.b="vOAjpTZd" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=IK4javAiq+ivmy29k+kuN6CMisdY+PaoaqOwSaAB0B83FhvkulsKR5W5zlm6u8Hu8mUS3m9lcXTttfzyix2B5a2l3heSTdwYVFhywwKq9qWThtqvHWNhCX7hTm46K70LYmb8cn5O2EhW47pU375xmxCpzxeIHxJ0ka/vS3jrrFSdUwdxxcPd8LNiNQBt5Anvs3D5LPx3vRm6LPm2GUHmxjiWvJffv0LUU0ZXzX41vJkJdapWgW/cb4EtZpeNuX8LUGrxs0R73eMbHbuWg2UO6ObojlOV/MVzKLJHYyi+2F1jG2t2dQ+YVvMt9RuV4PapwB7Fmc5WlzAbwajjpmcwrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=+gd2P2QyM6Btg7lkv0NpaudbosZkZpzI/p6utSSs/aI=; b=ixjoNQLy6SSyBDYr1PR/dg9onDD812pyStDLQ7WgwEjPecc57ap75vgJRROdHG6WbgdNv8ClqzjCkgypMs3NO6x1JZxCMF/Ls8R+tSqAea/xyOGi92fHmXIIQHsCr7cw4SkhPNUXySrf4b6NhT5J9HzsYOkuPXqrf/pAeeo7wSijmWMVqgjuslGGVSaCS2lSa8NbqwgHzXAAPPCa+Mxuk8Cpo8pk5otpRBnMWJIqpoRF3qe7k00Cm4CG6yomI0BNDpaxjzUtOsU3ALzCyceNfqt2GDMcw6XJdRZA/q5Y/V6e4jV0dPYI4kBa7MR1qCoyLg1WtGN3tkg2QfUgmAAwoQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=kunbus.com; dmarc=pass action=none header.from=kunbus.com; dkim=pass header.d=kunbus.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kunbus.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+gd2P2QyM6Btg7lkv0NpaudbosZkZpzI/p6utSSs/aI=; b=vOAjpTZde0gLHostENbbg+66exBB2NzOeVFqrIIPGmXWYVmABiFqpZcOpxCjgozUF7P4bf/9fZrdZfABo3GyAVazIEQ7g2yAkMMlRLjfe/iDPuRG2V+BjpLoA4domeusjyoWL6OBb4qXGe7IEBkppIiigPfRCl6C8agcvWPy4jw= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=kunbus.com; Received: from DBAP193MB0954.EURP193.PROD.OUTLOOK.COM (2603:10a6:10:1cc::9) by GVXP193MB2488.EURP193.PROD.OUTLOOK.COM (2603:10a6:150:1db::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8093.32; Thu, 31 Oct 2024 13:26:36 +0000 Received: from DBAP193MB0954.EURP193.PROD.OUTLOOK.COM ([fe80::ff97:4bb0:9245:6d0a]) by DBAP193MB0954.EURP193.PROD.OUTLOOK.COM ([fe80::ff97:4bb0:9245:6d0a%7]) with mapi id 15.20.8093.027; Thu, 31 Oct 2024 13:26:36 +0000 From: =?utf-8?q?Thomas_B=C3=B6hler?= To: Masahiro Yamada Cc: Nathan Chancellor , Nicolas Schier , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, Philipp Rosenberger , Lino Sanfilippo , =?utf-8?q?Thomas_B=C3=B6hler?= Subject: [PATCH 1/3] package: debian: strip headers package Date: Thu, 31 Oct 2024 14:26:28 +0100 Message-Id: <20241031132630.24667-2-t.boehler@kunbus.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20241031132630.24667-1-t.boehler@kunbus.com> References: <20241031132630.24667-1-t.boehler@kunbus.com> X-ClientProxiedBy: FR3P281CA0072.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:4b::23) To DBAP193MB0954.EURP193.PROD.OUTLOOK.COM (2603:10a6:10:1cc::9) Precedence: bulk X-Mailing-List: linux-kbuild@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBAP193MB0954:EE_|GVXP193MB2488:EE_ X-MS-Office365-Filtering-Correlation-Id: 165593c3-d4ab-4213-2260-08dcf9afa4ec X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|10070799003|52116014|376014|366016; X-Microsoft-Antispam-Message-Info: =?utf-8?q?cDICgWk71IziwsuWL6YNJ6cgw0u1Aei?= =?utf-8?q?DBS1BJkORQ13sD/3ju9OitA7PT2IDOXqRCQlPRHSbVGNITXpsvL2rjT6ulluGqbqb?= =?utf-8?q?cc28zWFRSmsimhKVGvF4j590nlM79gWeN2bzxnEN2s6XcJkQSYusCLKFZqulcnxcL?= =?utf-8?q?bc7MXPrfSnIFeCOMdGpC3bvvfNTWeGXy83jsl3bCjZIlTyXRblR7AVgnrhtDO3XxZ?= =?utf-8?q?DPTH7S3thUdALEyhLSyGHozGbC2EOspnmQo2LGYbIze4ou9MOSC3vR80LV6Ls3/X/?= =?utf-8?q?rKtoEqMRCbX6vvi42WVYcQxnZppqBYVWio4tGfGGYdVzAeZmLg/qI3Up+xfuXFQKn?= =?utf-8?q?BP0ZF02XEcXkE0MC4aDB+6/jooO1Xo+V8O4I73IYQiE5CNuWqbfhJQkGZIA7O9hpp?= =?utf-8?q?/pFSOwc08Z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?bmMtKNF1qbUph?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBAP193MB0954.EURP193.PROD.OUTLOOK.COM;PTR:;CAT:NONE;SFS:(13230040)(1800799024)(10070799003)(52116014)(376014)(366016);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?Wp04Sar1PI/ocj6C+abrTJjLXOBK?= =?utf-8?q?3AZQg05qY0hhyibI4Nuu+mIxQy/fUKyBoZMaz/l5atHPqlzQZtJh9cQFrjulJvgKR?= =?utf-8?q?yDDsb+YyjLjGk+R4+JvGgZvtYMyAV/0Dr3JuVTKDdExy+y2yRbt2JNx8nR7j3g68Z?= =?utf-8?q?ReEco12RQjlx0g4tRRPFWPMmHbkp9XHPnMqY1m5J8FagypI6kDldfJx+Dnf0Eovxi?= =?utf-8?q?GMxBDG777x+cUpfbQAABouTu8d67gUj06F9VPS/TwCTzCTOLz2GFeFGEcqZYm7Z8l?= =?utf-8?q?NmyJpoPJqiO0vn/uDVJF1rWTTPD7axDj8654i+poKLaxFqKdtBZma/P1JP7iLdwz2?= =?utf-8?q?KDbzpFYPHrtb8Mc1o9JWG+VonOG/Md/0uNM45KJ9R6Zx5jo5LAofsxpxtkUdN/3rw?= =?utf-8?q?He1jkJoGv1RVP7JQhFr1aOIdHkMlCqSkbd/65GdeYu1IYGdYVmaKCYiDZ17sgvNBL?= =?utf-8?q?jig9BH27NG0WuMVas5YYncen3UFNnopy/6Ls25MCrIkS9lnc3xboHgohI1OAC/U6h?= =?utf-8?q?DukBnYNwBIJVEW7b/YFGbA/KS7MJV5qefjuUqBshX3f7JjAE31kRr1DrFvieFpr6Z?= =?utf-8?q?sadaR8NfghdHDjuUFOCTCWRMCRSw6Q4UYBOE01YeCIZl94zZRtxlRvDEMu8+gm2KY?= =?utf-8?q?Hn/+nTeJ6FVbKGZX4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R3TyBaIxR74eliaLf11nZ+KHsRViI8EUOyxlVOQFvG5cP?= =?utf-8?q?6wSKLQq1AY4?= X-OriginatorOrg: kunbus.com X-MS-Exchange-CrossTenant-Network-Message-Id: 165593c3-d4ab-4213-2260-08dcf9afa4ec X-MS-Exchange-CrossTenant-AuthSource: DBAP193MB0954.EURP193.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Oct 2024 13:26:36.2337 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: aaa4d814-e659-4b0a-9698-1c671f11520b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Ydq/1R856sLF+PqxXTp7jMUtX8uszeNbvAv1o/bgfcMfNuoGrKsxMIefYiO4paTdvnCSo2Fgoi0swWXaXJPLSw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: GVXP193MB2488 The linux-headers package contains unstripped binaries. Lintian complains about this: E: linux-headers-6.12.0-rc4-g7e04fcfc6195: unstripped-binary-or-object [usr/src/linux-headers-6.12.0-rc4-g7e04fcfc6195/scripts/asn1_compiler] E: linux-headers-6.12.0-rc4-g7e04fcfc6195: unstripped-binary-or-object [usr/src/linux-headers-6.12.0-rc4-g7e04fcfc6195/scripts/basic/fixdep] E: linux-headers-6.12.0-rc4-g7e04fcfc6195: unstripped-binary-or-object [usr/src/linux-headers-6.12.0-rc4-g7e04fcfc6195/scripts/kallsyms] E: linux-headers-6.12.0-rc4-g7e04fcfc6195: unstripped-binary-or-object [usr/src/linux-headers-6.12.0-rc4-g7e04fcfc6195/scripts/mod/modpost] E: linux-headers-6.12.0-rc4-g7e04fcfc6195: unstripped-binary-or-object [usr/src/linux-headers-6.12.0-rc4-g7e04fcfc6195/scripts/sorttable] It's not possible to outright strip every package built with "debian/rules" as, for instance, the "binary-image" target shouldn't be stripped because it contains debug information that the "binary-image-dbg" target will make use of. Thus conditionally use "dh_strip" on the "binary-headers" target after using "dh_builddeb" to strip only the contents of the package lintian complains about. Also pass the "--no-automatic-dbgsym" option to make sure no headers-dbgsym package is created. Signed-off-by: Thomas Böhler --- scripts/package/debian/rules | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/package/debian/rules b/scripts/package/debian/rules index ca07243bd5cd..0c75319acae1 100755 --- a/scripts/package/debian/rules +++ b/scripts/package/debian/rules @@ -46,6 +46,8 @@ define binary $(Q)dh_testroot $(DH_OPTIONS) $(Q)dh_prep $(DH_OPTIONS) $(Q)+$(MAKE) $(make-opts) run-command KBUILD_RUN_COMMAND='+$$(srctree)/scripts/package/builddeb $(package)' + $(if $(filter $(headers-package),$(package)),\ + $(Q)dh_strip $(DH_OPTIONS) --no-automatic-dbgsym) $(Q)dh_installdocs $(DH_OPTIONS) $(Q)dh_installchangelogs $(DH_OPTIONS) $(Q)dh_compress $(DH_OPTIONS)