From nobody Mon Jul 29 22:57:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WXtzY242cz5S8kt; Mon, 29 Jul 2024 22:57:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WXtzY1780z438C; Mon, 29 Jul 2024 22:57:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1722293849; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=t5s2wxKcHCH7l8Nc5bJeoH6Hp2XaBHX4lADyl7VcclE=; b=qcC4Yvhu5qzkr1ts2UUr4eLEteXxqRoCj24oUXk/xaqv+nCwSpTCTtDIa5wcGJb6g629UJ SO5xwGe4IsOjDdHZ8xUPW2gxYOO6WFcL9qdXtNkqlmdQdOTV6xkLlFU17Ric8HX55nfwxt J9nSihL9l+OFeFPYPYAkchqTOhNBePfXucQH6uFjmWuWzjIyXQs68xx9vN3pdgnX5D7kkC i47Unz+P/zYT/QSrg0R4sDceoq+zkhjo+O716bVqgLrJ2109Nx+musn4dcfn7fkQ8i0gMN emAIz0wK/6cWe8spKPpr3h3d6dIyoB1jrwR4tmc9/Ku5ozELht1+KHZjURoStQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1722293849; a=rsa-sha256; cv=none; b=BAFvnC5gxY+Nd/WDynJOQPFFEf/3E9KMdpm1d3rtxc32kUW98ByjwPfqYy1n3dCKL6db/P YQdf37McAn0g/mQIzoeiu/sLHYAZDL+WDxNbJb+OJqsZF/ipv/P4tOw8qWZ+GoCZoDo8qr TjFnT6B6sJDkZtzqD02WkT4dHSRxMKFEDUZ/VPnFtqGiyCdy31qcIV99u+VPaNnarW1AnE EAjJLAdVQoFWqn/Jbd7UpPUOdbWJ/igEq9nj3WOdD5lkbqoRqVFOLoY5Tk6YP0xs9k3zpK 960nd8/46lDcjeLlTaqqgbm7bslmjlO6in3FG9jYLymrQNNfykKIrsB65LtAHw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1722293849; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=t5s2wxKcHCH7l8Nc5bJeoH6Hp2XaBHX4lADyl7VcclE=; b=CSQBqQjvsKaR8IHq8fcgmx7waZdhizeqiA4X3Cpo3i2RRWRFT/V4rmpgumAp8irY6KSjNV 3taFrq2HwBcH3P/6/zW+cSlAsF/ANGbCSN2EqP6wOp8CUrgBDYzt7lw9hO2b6pUPA/7wwL xXvk3wn3vx/O/ROTCFkiS+rofP7RDy0uOVQEkkpuY7yth0xoWk31EYPD782dWpxhIkT9bI FDSfLHHCgls0AdrqGDhSkIlIo4X3VfxKzGppW+jruQ5UHjh8ZweuA+SkX1eP/br9pw40Ek m+0yCkcp+baPFALKWkMtb6YwcmPjd9y1fn5YtbU3FtIe9GxW9JiA83DyYYgcXA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WXtzY0k3kzt4V; Mon, 29 Jul 2024 22:57:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46TMvSgZ049539; Mon, 29 Jul 2024 22:57:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46TMvSbH049536; Mon, 29 Jul 2024 22:57:28 GMT (envelope-from git) Date: Mon, 29 Jul 2024 22:57:28 GMT Message-Id: <202407292257.46TMvSbH049536@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 522a65a8d97a - main - Revert "loader/lua: Remove compat shim for loader.lua_path" List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 522a65a8d97a0d6b634266f1b4a89aa8f374279c Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=522a65a8d97a0d6b634266f1b4a89aa8f374279c commit 522a65a8d97a0d6b634266f1b4a89aa8f374279c Author: Warner Losh AuthorDate: 2024-07-29 22:57:04 +0000 Commit: Warner Losh CommitDate: 2024-07-29 22:57:04 +0000 Revert "loader/lua: Remove compat shim for loader.lua_path" This reverts commit ab97d42addae97a389c6f22d6bba62ed954bb8e7. There's too many people in the field with FreeBSD 12.0 loader.efi that stubbed their toe on upgrading to 14.1 since they'd not updated loader.efi. While we sort out that mess, add back this workaround. Can revisit after 14.2 maybe. MFC After: 3 days Sponsored by: Netflix Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D45882 --- stand/lua/core.lua | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/stand/lua/core.lua b/stand/lua/core.lua index eaabff6a7602..9226de564348 100644 --- a/stand/lua/core.lua +++ b/stand/lua/core.lua @@ -65,7 +65,13 @@ end -- message on failure. function try_include(module) if module:sub(1, 1) ~= "/" then - module = loader.lua_path .. "/" .. module + local lua_path = loader.lua_path + -- XXX Temporary compat shim; this should be removed once the + -- loader.lua_path export has sufficiently spread. + if lua_path == nil then + lua_path = "/boot/lua" + end + module = lua_path .. "/" .. module -- We only attempt to append an extension if an absolute path -- wasn't specified. This assumes that the caller either wants -- to treat this like it would require() and specify just the