From patchwork Fri Dec 22 11:45:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roberto Bartzen Acosta X-Patchwork-Id: 1879638 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=luizalabs.com header.i=@luizalabs.com header.a=rsa-sha256 header.s=google header.b=Qq6KhX7s; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=2605:bc80:3010::133; helo=smtp2.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org) Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4SxQV14Psmz1ydZ for ; Fri, 22 Dec 2023 22:45:45 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 6210C40286; Fri, 22 Dec 2023 11:45:43 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 6210C40286 Authentication-Results: smtp2.osuosl.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=luizalabs.com header.i=@luizalabs.com header.a=rsa-sha256 header.s=google header.b=Qq6KhX7s X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lFH65V3HhVrL; Fri, 22 Dec 2023 11:45:42 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp2.osuosl.org (Postfix) with ESMTPS id 0CC2D400C8; Fri, 22 Dec 2023 11:45:41 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 0CC2D400C8 Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id D2DFFC0077; Fri, 22 Dec 2023 11:45:40 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) by lists.linuxfoundation.org (Postfix) with ESMTP id 4C6F5C0037 for ; Fri, 22 Dec 2023 11:45:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 352D283D79 for ; Fri, 22 Dec 2023 11:45:39 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 352D283D79 Authentication-Results: smtp1.osuosl.org; dkim=pass (1024-bit key) header.d=luizalabs.com header.i=@luizalabs.com header.a=rsa-sha256 header.s=google header.b=Qq6KhX7s X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 4RnHabsviywR for ; Fri, 22 Dec 2023 11:45:38 +0000 (UTC) Received: from mail-ej1-x62b.google.com (mail-ej1-x62b.google.com [IPv6:2a00:1450:4864:20::62b]) by smtp1.osuosl.org (Postfix) with ESMTPS id D362E83AF7 for ; Fri, 22 Dec 2023 11:45:37 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org D362E83AF7 Received: by mail-ej1-x62b.google.com with SMTP id a640c23a62f3a-a2343c31c4bso217204266b.1 for ; Fri, 22 Dec 2023 03:45:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=luizalabs.com; s=google; t=1703245535; x=1703850335; darn=openvswitch.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=Weuin2cMxrOTTwDzrAoyEX15LcDlmhne/1y7QODeFww=; b=Qq6KhX7slr8M4NFFUXn3XfWGR8Pe1hlau8itlpVcKBX34cMpXz4e839a2Ro6RvyWA0 wICAy3edQmzYxhqxbDF/FtW6E6gO66uI7WWumBPmFacWMFq9mJ/hGff8SmqDSNp0uYs9 OM8KJ9GcAeWRDccn6V7aZu1u4DF4JGtkA7b14= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703245535; x=1703850335; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=Weuin2cMxrOTTwDzrAoyEX15LcDlmhne/1y7QODeFww=; b=hPlGO3rd/FfEZTJo+83noUVbxmtrdcxWxlcE6v4KGUcDc9ocOJy8UlxZRBLDRuOCZn 1dtF79KUMSH54Rv4o7bbjCnbaTcwLzRmmnP5qrKnGZnM6y0z5Rd9wPfMeENsm9AzSFGz S2IAYfGEHVfvrOnbJi3rBiTGejgkD1y5AHI9HC54eQtwM7e0k6GcvLaPucF5SXh8sg/I 1UCBCEswjQuMgH8w8ZT8O/QOfPwRxg/82v89CaDYk9bKoWIiyGKoyiJNf1MKYHYIROkb WkpsHi3gwQHNPrI4JEU3nYoCrIC2InAKJ071GLjuc1ReMqTvM7L2I4TAIFlXmqmY/Nag fiYA== X-Gm-Message-State: AOJu0YzoSeo2p5X+igcyUkVagYPpoGFefcjf35Motvldooo7K8siYVUT Ig8euaEaGOF25dTEdKMDRnVrc5GDwhwk89jRnccwEgrfI3ak1lqlMLTBsrBAZ9BStd4As1gAc9n aIcSsJZmJc6bKB4fjvmZ00GnYMc/StANLN3e4u/HnkbA= X-Google-Smtp-Source: AGHT+IGrUvGVsUVihgSwRL0OQ0avE+jy+evtSIL53O38cGmcEbw8Ln0x0Cq7e3naMJAXDUp0d/gDSHjJMd/WOqS+eNU= X-Received: by 2002:a17:906:bc42:b0:a23:6a65:9fc6 with SMTP id s2-20020a170906bc4200b00a236a659fc6mr473241ejv.87.1703245535556; Fri, 22 Dec 2023 03:45:35 -0800 (PST) MIME-Version: 1.0 Date: Fri, 22 Dec 2023 08:45:37 -0300 Message-ID: To: dev@openvswitch.org X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: [ovs-dev] [PATCH ovs] debian/rules: Fix incorrect use of link-time optimizer. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Roberto Bartzen Acosta via dev From: Roberto Bartzen Acosta Reply-To: Roberto Bartzen Acosta Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" Current version of debian/rules simply uses the default lto GCC optimization settings during the linkage process. The main problem with this approach is that GCC on OS like Ubuntu Jammy, for example, can enable the -flto=auto option during the openvswitch building and linking process. In this case, the linked dynamic libraries would need to be builded based on the same lto optimization options, at the risk of not working, according to documentation [1]. I'm not sure of the real benefits of using this link-time optimization option, and since when it is enabled it causes problems with shared libs links such as libjemalloc, for example, it seems safer overwritten compiler decision by passing -fno-lto command. [1] https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#index-flto Reported-at: https://bugs.launchpad.net/ubuntu/+source/openvswitch/+bug/2015748 Signed-off-by: Roberto Bartzen Acosta --- debian/rules | 2 +- 1 file changed, 2 insertion(+), 1 deletion(-) diff --git a/debian/rules b/debian/rules index dc5cc8a65..de8771813 100755 --- a/debian/rules +++ b/debian/rules @@ -2,7 +2,7 @@ # -*- makefile -*- #export DH_VERBOSE=1 export DEB_BUILD_MAINT_OPTIONS = hardening=+all -export DEB_CFLAGS_MAINT_APPEND = -fPIC +export DEB_CFLAGS_MAINT_APPEND = -fPIC -fno-lto %: dh $@