From nobody Sat Apr 27 04:09:29 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1685029680; cv=none; d=zohomail.com; s=zohoarc; b=SCCiD+Kg+y9vIXuF1/KDXmJPkOn+OxAlElfoKVVaNyCnbnRQPxms3ZCefi2v+4D0i78OJlOLge/rSbPa10LDCLRbcMvKoodAwxpCwPtMaF1cHHnrPH/WxkVwR4PboFTz0s86DDpukkMPdJy4M6rhQqa3DQv7t6wWiFdZKjYJ9ME= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1685029680; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=9EoTH7im9ekI17xwbmDr9tPX5keY1sbjjPY8zVTrpog=; b=IChQpSnh/udqkzyDj7chPyq5qm7Z3TgBB3vAjing3xEt7IdYPuLYwB3QlYgtRG1GUQt0R9Os4kU2zLGiTsgKthlaQ5BQjCePlyi6Dq9WYyroOvxGi05XnaSRota0C9tyjcs9PYIVcnIGBv2e7vdXW4mLAHw95pSHavNKxZJjTOE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1685029680219571.7680296271379; Thu, 25 May 2023 08:48:00 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q2DBc-00049G-MK; Thu, 25 May 2023 11:47:32 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2DBY-00043U-Oa for qemu-devel@nongnu.org; Thu, 25 May 2023 11:47:29 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2DBX-00041w-5p for qemu-devel@nongnu.org; Thu, 25 May 2023 11:47:28 -0400 Received: from mail-ed1-f71.google.com (mail-ed1-f71.google.com [209.85.208.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-191-6mXSjs_TOsuNRBFEq03UkA-1; Thu, 25 May 2023 11:47:22 -0400 Received: by mail-ed1-f71.google.com with SMTP id 4fb4d7f45d1cf-511b509b55bso3019271a12.0 for ; Thu, 25 May 2023 08:47:21 -0700 (PDT) Received: from [192.168.10.117] ([2001:b07:6468:f312:48f9:bea:a04c:3dfe]) by smtp.gmail.com with ESMTPSA id oy11-20020a170907104b00b0096f7e6d0063sm993456ejb.75.2023.05.25.08.47.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 May 2023 08:47:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1685029646; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9EoTH7im9ekI17xwbmDr9tPX5keY1sbjjPY8zVTrpog=; b=Ur9xSDHQgeZVJ3UQVnrZVyGTmVc72iq2V3IpRONpKTYZTORkX+HaNL8teUrdSOuA1yYWIS TMjvXcaGRmvQERgBcDnFc6rW4EDmyaL/qlVzThfSFFKf20Un05HxO035auMIPXAkx9F0oV ktvQNhkepmsobxlHMRGnUTtf1zsvZfg= X-MC-Unique: 6mXSjs_TOsuNRBFEq03UkA-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685029640; x=1687621640; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=9EoTH7im9ekI17xwbmDr9tPX5keY1sbjjPY8zVTrpog=; b=kcX4TzNd0Rzn5vY9LVOgfCimqWI+PKsc90AJJe5JyHHgywPKd7scA+0A/sUQ44qxAZ qZPU2Qpqslk1wY3UVkG6J+5+L0GRX/ZRwpE6usj0sVxx64ciC1EVesRwI//q+6H9IIh9 1hWN1X5beXbu8d/MTMspAHdA8C6mzf9onc0hS1h8g4neAYosrZwWW2kgg7IThFVbZAAz KjTtFr0pPbescUHyVcjcDk1JQzLNOSwjNqKwayaZZICzdMLc7lULoi+9zSQUFhy4Qx/G 72SQgMrqdmyIyDm9zgQvAC7844zQnh9Q3rAmWmWZnW2p/8DmOm+YrFx3sKLkLxWBRi/9 4DiQ== X-Gm-Message-State: AC+VfDygwkJ5tF3gpWxVWuTAnx0XQqFBzwfHCUwfVWAkoXhBKZ+B6Icn D79lyPJ7/3W8ETJ5o8jarAM/mH8vSKSGWK1bRs1+tH2qKlWNsH5u/eh69vgqN3Faz3X8vNriUWw AZ8MdJtqjSK8qQygWVg1xE0hhM92xNb+3DVxrd0ZtNV9fLB/J+ckmtnBQ56gCXcvHXK71J6G9dx k= X-Received: by 2002:a17:907:86ab:b0:895:58be:957 with SMTP id qa43-20020a17090786ab00b0089558be0957mr1943751ejc.2.1685029640502; Thu, 25 May 2023 08:47:20 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7zFqjS/z+hzytw8JYVTk/sKE1Yombs9Sg0+x6a3RCEqqvvnGkq5/r3kJM+CU847W4x6G9CWA== X-Received: by 2002:a17:907:86ab:b0:895:58be:957 with SMTP id qa43-20020a17090786ab00b0089558be0957mr1943726ejc.2.1685029640020; Thu, 25 May 2023 08:47:20 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Cc: Juan Quintela , qemu-stable@nongnu.org Subject: [PATCH] configure: unset harmful environment variables Date: Thu, 25 May 2023 17:47:18 +0200 Message-Id: <20230525154718.355734-1-pbonzini@redhat.com> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=170.10.129.124; envelope-from=pbonzini@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1685029682392100001 Content-Type: text/plain; charset="utf-8" Apart from CLICOLOR_FORCE and GREP_OPTIONS, there are other variables that are listed in the Autoconf manual. While Autoconf neutralizes them very early, and assumes it does not (yet) run in a shell that has "unset", QEMU assumes that the user invoked configure under a POSIX shell, and therefore can simply use "unset" to clear them. CDPATH is particularly nasty because it messes up "cd ... && pwd". Reported-by: Juan Quintela Cc: qemu-stable@nongnu.org Signed-off-by: Paolo Bonzini Reviewed-by: Juan Quintela Tested-by: Juan Quintela --- configure | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/configure b/configure index db1f02346e68..42861ebc6e22 100755 --- a/configure +++ b/configure @@ -4,9 +4,8 @@ # =20 # Unset some variables known to interfere with behavior of common tools, -# just as autoconf does. -CLICOLOR_FORCE=3D GREP_OPTIONS=3D -unset CLICOLOR_FORCE GREP_OPTIONS +# just as autoconf does. Unlike autoconf, we assume that unset exists. +unset CLICOLOR_FORCE GREP_OPTIONS BASH_ENV ENV MAIL MAILPATH CDPATH =20 # Don't allow CCACHE, if present, to use cached results of compile tests! export CCACHE_RECACHE=3Dyes --=20 2.40.1