From patchwork Thu Jan 4 15:15:41 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 19362 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 3B47DC3240 for ; Thu, 4 Jan 2024 15:15:45 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id C034A62B58; Thu, 4 Jan 2024 16:15:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1704381344; bh=Hz10/+gr+xxlH/SpuBT08am0O4gRyM3saiCXJMFBEhE=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=yr2N/FEnmHQbufKbwvk5LgTQ0ZdO8DyNTFqP23vSp6TzOrdAq6x5lOc55+BhdJnRt AgR4VfDv98l9zB3TRLeTC1CYM9HjtfMYwFQg6ZShF75Am2PjPkNOiZA9GZ4L1ZK4tT I2ZaBKFMqeqE/K1JN3YK2/0B0VBG/A/eWFMQDajrVz9aIW3MLIMOfduXIAE6YwmMqv nCmQkdoPqKo1WqgcXgbh/k7Bw8Uw5ng2vTj1yUNoAiRlTwtxqupQBip1hOhYV9qqnj N1x/PqCig8rRn8WkyLR+Aew5eppcubNdYJcXsctA2J0XYUP6urQqqSY80vTErlFf9x HtCsk9vRMR4OQ== Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 74F4661D82 for ; Thu, 4 Jan 2024 16:15:41 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="erdtgxNt"; dkim-atps=neutral Received: from pendragon.ideasonboard.com (213-243-189-158.bb.dnainternet.fi [213.243.189.158]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id B6547D49; Thu, 4 Jan 2024 16:14:40 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1704381280; bh=Hz10/+gr+xxlH/SpuBT08am0O4gRyM3saiCXJMFBEhE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=erdtgxNtu4HEO5Bq2CrZjmKzI3zNOZIcsN63y4TkTti2gMtGTPjPlhI8V75fxoojX GJkmheKZoIVApH6TkfpJvieIFYy8ZiNlIPV0PoyuiblFWXeJ77wbbzHHpb1Uv6MIjE YYWVcGX8BN8fVIdKYAZ0BRkQ7OL7qmYMLRd14qzA= To: libcamera-devel@lists.libcamera.org Date: Thu, 4 Jan 2024 17:15:41 +0200 Message-ID: <20240104151548.2589-2-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20240104151548.2589-1-laurent.pinchart@ideasonboard.com> References: <20240104151548.2589-1-laurent.pinchart@ideasonboard.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 1/8] utils: update-mojo.sh: Properly remove old sources X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Laurent Pinchart via libcamera-devel From: Laurent Pinchart Reply-To: Laurent Pinchart Cc: Khem Raj Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The update-mojo.sh script starts by removing all sources before copying the new files from chromium. A bug in the 'rm' command makes the removal a no-op: the glob pattern is quoted, which attempts to remove a file name '*' in the tools directory, not all files in the directory. Fix it by removing the whole utils/ipc/mojo/ directory. While at it, also remove the utils/ipc/tools/ directory that contains imported sources. Signed-off-by: Laurent Pinchart Reviewed-by: Milan Zamazal Reviewed-by: Kieran Bingham --- utils/update-mojo.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/utils/update-mojo.sh b/utils/update-mojo.sh index fcbc81e70529..967d139a3f70 100755 --- a/utils/update-mojo.sh +++ b/utils/update-mojo.sh @@ -30,14 +30,18 @@ if [ -n "$(git -C "${chromium_dir}" status --porcelain)" ] ; then exit 1 fi +# Remove the previously imported files. +rm -rf "${ipc_dir}/mojo/" +rm -rf "${ipc_dir}/tools/" + # Copy the diagnosis file +mkdir -p "${ipc_dir}/tools/diagnosis" cp "${chromium_dir}/tools/diagnosis/crbug_1001171.py" "${ipc_dir}/tools/diagnosis" # Copy the rest of mojo +mkdir -p "${ipc_dir}/mojo/public" cp "${chromium_dir}/mojo/public/LICENSE" "${ipc_dir}/mojo/public" -rm -rf "${ipc_dir}/mojo/public/tools/*" - ( cd "${chromium_dir}" || exit find ./mojo/public/tools -type f \