From patchwork Thu Feb 10 10:28:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Eggers X-Patchwork-Id: 3479 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id C9EB1C433EF for ; Thu, 10 Feb 2022 10:28:40 +0000 (UTC) Received: from EUR05-DB8-obe.outbound.protection.outlook.com (EUR05-DB8-obe.outbound.protection.outlook.com [40.107.20.130]) by mx.groups.io with SMTP id smtpd.web08.8335.1644488917736663794 for ; Thu, 10 Feb 2022 02:28:40 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@arrigroup.onmicrosoft.com header.s=selector1-arrigroup-onmicrosoft-com header.b=edWWKQr6; spf=pass (domain: arri.de, ip: 40.107.20.130, mailfrom: ceggers@arri.de) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jFkI5CVb6ik3fmD+J+TAtmeCMrvSJ09YaSYKhDgh4YZhbt+qOqkZ0+rxdt+R07QvQn9cdc70qyh6Dgwf+XVAShP+1Y2bKg7fk5jFqMIP2wk1bMdmOAHh31ss4T3Fv0eb2MRQKR6ngV8I9Z8nLC9VMph8U2Cov0CdaHTOvnCCelhXVXlfpA155oKxE5OtN9+O2C3Ugpx/JSqfWu5/So1iy8RcJBylq45S5DfNIlNoj3bBxkeO/Yrp957o+FO81xvGv5ZDffE0YkD9AlYX7kPSqycqZUBPcgVTNsrgfS4ZLEaA2SG1S0TzUnSbd7Bg9XxMDJA6ik7DaDKcErpURlRvtA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=EU01FD+/4ngv7DOcmwO6SvtOMm4vtfI09lNntCIh9+s=; b=lDazRnpqCneCxgvhYcaKB1UitGoR4nHMytYlZXn2sXToriiLAv/ZfCeQxh3pZoCMvlDzdQn3Pe28ZLVoXmHFzZvx/85NUFRS3PFVe1ZMigNSSB3X86UfzoZr9QSuIpQDCnpT1zOjf3e4m9F/JAZPoDdQL9rDUBx9hhgeJKsTfAU4y4tirIArDNvKmD3pQtIfGZ6i7gHb/ext3B+O6yxaPSlpiIvMK+D3zSyAxCEVj+vAgK1+fpPP60QAykliq+LDz3SLRvDUeuQlFTcMRpUFdWOo7t5dhTyNGXC48/yXWUdm21fQX9r9QfANsHre9ERtmpel8ND/o2RxkvtCWZMm2w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 52.169.0.179) smtp.rcpttodomain=lists.openembedded.org smtp.mailfrom=arri.de; dmarc=bestguesspass action=none header.from=arri.de; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arrigroup.onmicrosoft.com; s=selector1-arrigroup-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EU01FD+/4ngv7DOcmwO6SvtOMm4vtfI09lNntCIh9+s=; b=edWWKQr64scVvKsUCR+N2XFpLt5CCpsvbtvLHEicuZz0D71BHHPPeiJbuj/J1y7wPJMDH4tIV4qPMZlbBFkx/AdvAs4K4Vmwwv3Fi4KDyRnU5EI+u8XwLltcMg7KOtyMjjH28KI6RZZ0Iu1O2dckBkea6hQoBlVNfZIMtiIUEUU= Received: from AM6P192CA0020.EURP192.PROD.OUTLOOK.COM (2603:10a6:209:83::33) by VI1PR07MB4141.eurprd07.prod.outlook.com (2603:10a6:803:32::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4975.9; Thu, 10 Feb 2022 10:28:32 +0000 Received: from VE1EUR02FT051.eop-EUR02.prod.protection.outlook.com (2603:10a6:209:83:cafe::d5) by AM6P192CA0020.outlook.office365.com (2603:10a6:209:83::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4951.14 via Frontend Transport; Thu, 10 Feb 2022 10:28:32 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 52.169.0.179) smtp.mailfrom=arri.de; dkim=none (message not signed) header.d=none;dmarc=bestguesspass action=none header.from=arri.de; Received-SPF: Pass (protection.outlook.com: domain of arri.de designates 52.169.0.179 as permitted sender) receiver=protection.outlook.com; client-ip=52.169.0.179; helo=eu2.smtp.exclaimer.net; Received: from eu2.smtp.exclaimer.net (52.169.0.179) by VE1EUR02FT051.mail.protection.outlook.com (10.152.13.5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4975.11 via Frontend Transport; Thu, 10 Feb 2022 10:28:31 +0000 Received: from EUR01-DB5-obe.outbound.protection.outlook.com (104.47.2.52) by eu2.smtp.exclaimer.net (52.169.0.179) with Exclaimer Signature Manager ESMTP Proxy eu2.smtp.exclaimer.net (tlsversion=TLS12, tlscipher=TLS_ECDHE_WITH_AES256_SHA384); Thu, 10 Feb 2022 10:28:31 +0000 X-ExclaimerHostedSignatures-MessageProcessed: true X-ExclaimerProxyLatency: 9432748 X-ExclaimerImprintLatency: 3896245 X-ExclaimerImprintAction: 6778043129784ee6bbb84efed918c906 Received: from AS8PR05CA0024.eurprd05.prod.outlook.com (2603:10a6:20b:311::29) by DBBPR07MB7658.eurprd07.prod.outlook.com (2603:10a6:10:1e4::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.6; Thu, 10 Feb 2022 10:28:30 +0000 Received: from HE1EUR02FT037.eop-EUR02.prod.protection.outlook.com (2603:10a6:20b:311:cafe::98) by AS8PR05CA0024.outlook.office365.com (2603:10a6:20b:311::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4975.11 via Frontend Transport; Thu, 10 Feb 2022 10:28:29 +0000 X-MS-Exchange-Authentication-Results: spf=fail (sender IP is 217.111.95.7) smtp.mailfrom=arri.de; dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arri.de; Received-SPF: Fail (protection.outlook.com: domain of arri.de does not designate 217.111.95.7 as permitted sender) receiver=protection.outlook.com; client-ip=217.111.95.7; helo=mta.arri.de; Received: from mta.arri.de (217.111.95.7) by HE1EUR02FT037.mail.protection.outlook.com (10.152.10.205) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.4975.11 via Frontend Transport; Thu, 10 Feb 2022 10:28:29 +0000 Received: from MucEx01.arri.de (10.10.18.25) by MucEx01.arri.de (10.10.18.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.7; Thu, 10 Feb 2022 11:28:28 +0100 Received: from CASHUB3.arri.de (192.168.100.104) by MucEx01.arri.de (10.10.18.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2375.7 via Frontend Transport; Thu, 10 Feb 2022 11:28:28 +0100 Received: from localhost.de (192.168.54.166) by mta.arri.de (192.168.100.104) with Microsoft SMTP Server (TLS) id 14.3.498.0; Thu, 10 Feb 2022 11:28:28 +0100 From: Christian Eggers To: CC: Christian Eggers Subject: [PATCH] sdk: fix search for dynamic loader Date: Thu, 10 Feb 2022 11:28:10 +0100 Message-ID: <20220210102810.15680-1-ceggers@arri.de> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Originating-IP: [192.168.54.166] X-EOPAttributedMessage: 1 X-MS-Office365-Filtering-Correlation-Id: 029621ba-8719-4163-f815-08d9ec8015d0 X-MS-TrafficTypeDiagnostic: DBBPR07MB7658:EE_|VE1EUR02FT051:EE_|VI1PR07MB4141:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:9508;OLM:6430; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: ayK2JmZ2yNMkSjycM6IsxzK6pfdZSrFV4vQY7nMxTWY5DvvrovO8bcQahy0BCx0HHctf6y9AMZaqdD/tNmmYNejnMj2lIaGm7DXV5/SC7uXxqz0GeqtFKBCVO3wfnVN1epwVidWMhwDIv6SxyEL14CeVHclwWP2p0daXC1VLOZkC8FBsh8TdxcUWv1MRaAyDm52BT+XneNLFlGb0NoX8fs/VXi1iweIzua47VW6n6AS08ux+xZZunPiLHDc5bTGcumca2uk/R0oeFWIRMXBfGYP6bA5wVUly5Y+JU/8nAfyu5bKvq4/9mnRLq+S5k4+nrHJDzktFnk/xw7qCAuVatEaj0exAwUtS7rbjk8duJzZL9UtlcCaT6+a3Tb1x1KmXzXEzUseoLlNBN3z/LIcvucutNziIl4U1MPzmmlC1XdwQnKoJlbRlouv5VTesPX23bpEkVC8oe8u5uGKVdN7iGriVxosDiZb22Ci/hJNorWD40Qam8U5SN6Mi4Sdf1eS7lUKAuxgeXHyu8+iRKQ5CvxI0+wU8ONg16npjb1bmVhBVt7HNlL//i1g40jE2GHOh1ZFL10rQeDa+VOzGL3O29lBiLrI+qlDZjxohIjVxw0b7Qb4qmJxMFRFFjFNuD9b8RgUY9R7WN6gf1BU/CW1+6APYYAEqmcNdNArFbBzUutyOba82VWOjNR3Df6Q9gWY4cB8e8x6UQ0R2cm7Ky/BREg== X-Forefront-Antispam-Report-Untrusted: CIP:217.111.95.7;CTRY:DE;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:mta.arri.de;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230001)(4636009)(40470700004)(46966006)(36840700001)(36756003)(1076003)(26005)(426003)(2906002)(2616005)(336012)(83380400001)(107886003)(16526019)(186003)(36860700001)(82310400004)(6916009)(8676002)(4326008)(70586007)(6666004)(508600001)(86362001)(8936002)(47076005)(81166007)(316002)(40460700003)(5660300002)(356005)(70206006)(36900700001);DIR:OUT;SFP:1102; X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBBPR07MB7658 X-MS-Exchange-Transport-CrossTenantHeadersStripped: VE1EUR02FT051.eop-EUR02.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 806f2f7a-8c49-4f13-b253-08d9ec80147e X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: YlACrpb0rk3Txm2dhzYemkcU6EG+2zu2Yfu8rCw718MpjT8gG8H5KcrXlOkaJIXzjBRhvCrnoEJgkcukclcVi69VoAK67Buj//OPJFxnUFFhw/aisZmiTs1RcFQ6p0bO00AKFtrwgNflzlLRuHt1SKWyUxLrSGSyjZLBxojaEWk08spZSF5cUQMLSOCShOecUB7VIM2l+iQoDZU6sWbKW2pZnpoe4Hhjml4CgkPP8aZw1wHWFEoOql9pTadHDXG3CH4AmkcEO5E3nXiiM00Vd30dUbWUSNXEAuargH+M+JSZcnnQm/3T8MDWaREpqm8JDYsU/jCF8C6/MxyzO3WGHplckJ0Xr1MYNGIDYIwe1ukTHfYdH0TuB52YM1SWB0ki03zXksOchyjc5cCWfxGtniP64vHw6TE9IvkNKaXeGgdKt+/1r6iD5Iu5VmnwnG35FzneglFcOKUBHS2y4tODPOriXf0nvnVjQoLyQJyiysI99Yvj5Nu8dOPQzkN4+divWM9dSlLHabgryjwgvjFFk/OEy5s4lQsDk82KRX54CNxzFnoCPaqn2byjWe3NGn9uM6AC2XtvVheGW10mfmcIPe6fGMAjfpnhBMQlqJ4/VxABH+3E6wNdAIL6+D+6494GNW85kQdU6y/3pWXxiIGs4FUD7ZaSesohDlq5wIM2OHV3nw3gmpafnXvunzDJCAM+ff2eUcPoQB09F8Rlc/IOQeIaUCwI2aVSswhOJpKhKi4naABeaIKXAIwwa6Z1FTmMRXVcHhgZL9uq8w5rukwDK6iJvrvKRv+F2YleoX2YT0k= X-Forefront-Antispam-Report: CIP:52.169.0.179;CTRY:IE;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:eu2.smtp.exclaimer.net;PTR:eu2.smtp.exclaimer.net;CAT:NONE;SFS:(13230001)(4636009)(36840700001)(46966006)(40470700004)(2616005)(70586007)(107886003)(7596003)(7636003)(6666004)(47076005)(36756003)(6916009)(70206006)(66574015)(508600001)(15974865002)(7066003)(8936002)(26005)(86362001)(83380400001)(336012)(426003)(36860700001)(40460700003)(166002)(1076003)(16526019)(186003)(316002)(4326008)(2906002)(5660300002)(33964004)(82310400004)(8676002);DIR:OUT;SFP:1102; X-OriginatorOrg: arri.de X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Feb 2022 10:28:31.0495 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 029621ba-8719-4163-f815-08d9ec8015d0 X-MS-Exchange-CrossTenant-Id: e6a73a5a-614d-4c51-b3e3-53b660a9433a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=e6a73a5a-614d-4c51-b3e3-53b660a9433a;Ip=[52.169.0.179];Helo=[eu2.smtp.exclaimer.net] X-MS-Exchange-CrossTenant-AuthSource: VE1EUR02FT051.eop-EUR02.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR07MB4141 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 10 Feb 2022 10:28:40 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/161604 if the package "nativesdk-glibc-dbg" is installed as part of the SDK, the existing search expression finds two files: $OECORE_NATIVE_SYSROOT/lib/.debug/ld-linux-x86-64.so.2 $OECORE_NATIVE_SYSROOT/lib/ld-linux-x86-64.so.2 The generated relocate_sdk.sh shell script contains then an extra newline and segfaults during SDK relocation. Limit the search depth to 1, to avoid finding the file in the .debug directory. Signed-off-by: Christian Eggers --- I ran into this problem at first on honister (as previous releases seem not to include nativesdk-glibc-dbg automatically, e.g. due to "dbg-pkgs" in SDKIMAGE_FEATURES). But I think that this patch may also be relevant hardknott and dunfell. meta/files/toolchain-shar-relocate.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/files/toolchain-shar-relocate.sh b/meta/files/toolchain-shar-relocate.sh index 3ece04db0a4a..cee9adbf399c 100644 --- a/meta/files/toolchain-shar-relocate.sh +++ b/meta/files/toolchain-shar-relocate.sh @@ -5,7 +5,7 @@ fi # fix dynamic loader paths in all ELF SDK binaries native_sysroot=$($SUDO_EXEC cat $env_setup_script |grep 'OECORE_NATIVE_SYSROOT='|cut -d'=' -f2|tr -d '"') -dl_path=$($SUDO_EXEC find $native_sysroot/lib -name "ld-linux*") +dl_path=$($SUDO_EXEC find $native_sysroot/lib -maxdepth 1 -name "ld-linux*") if [ "$dl_path" = "" ] ; then echo "SDK could not be set up. Relocate script unable to find ld-linux.so. Abort!" exit 1