From nobody Sat Oct 4 00:53:37 2025 X-Original-To: dev-commits-src-main@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 4cdn8f0D0xz69ds5; Sat, 04 Oct 2025 00:53:38 +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 "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cdn8d6nvKz3Wkt; Sat, 04 Oct 2025 00:53:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1759539218; 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=mQ+SdvgYe/9zovepxhl2CO23WnnczqKz+1txQcGQpXU=; b=q3mxS7R02yDA3OgO29gZRqU3EJesvVTXPDyd0mgunyyXEGbzhUohcmjo1Ox/LwnCNWpghO KJ8XQZNrhOne8Xv3ZBqFQ/BGK1eoWyvdTumHQJZAZt/9lhOnbtygy3NthOrbHkTnCHPdom kgH45WtH1y82JI1ZcQqp7jJOkCoixPQygvYFkzm6ZTheyzLISUB+Su/9GTijPtnX60aTPD 2dw1Oy1bp10ViMboQLDb1vbEegUK5BjPuOBu9mxkuda6+NgiZWcsGx1FRamld4hQJd+wR/ /S8Xzti8ZH1KFNX/27WGwtAEOsEuvPyP7mAv4QeN/zu6iW9ynD3TuUlMcDyAOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1759539218; 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=mQ+SdvgYe/9zovepxhl2CO23WnnczqKz+1txQcGQpXU=; b=NUwhbuefOdw2sZn3lXY0R8XyomrmQ8YWzeL/71oIGNVl8ubqtCDjDAqFRhklZyq0AyQoPK FLyjg+65OuacI+EhQwnWh419k+S1UHjameVbwxXBLDqfmyAzDo0dk52yv5bolaIwZcw3ZO OyhdCphDMYWJyhMMrq8YdXsDZxh+6HVWbfgV7uKa2WtCEfaIGwrBodCFNeQQRyiv6Jq+rP Vh34y/ZUUeX5gT2GolnWbRh9tO4LuWsNZHrJXhMKRjLE8bZG/WbQF4ZiKPSNopEond2yO8 Ru6oyomANoe1Xnz9I+sAmYl9B/ns/72lxmzy0TWBZRPruaCdNOvDhl5SpJpMdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1759539218; a=rsa-sha256; cv=none; b=reVXo4slME9Zgamr0vhQwXDOi2s+5N9OGLXpgqYLiQmM8IToKeSKkBBcQKuMmJQomWtT7S T/P3Ia5UHcc65rflZl+2Ac8yz64A1Q/ll7NGKkEM+reoirca3ig/65up0gSLyIaeY7DliS xzhDVoMzSBX2he9Jnd77osdtzpK7YiuYJ/2lvZgr2VLpUym6rLxWtfLkjiB01oABXTPVCw 8eW1vGxaP0mIfDeHwFNew1p1ERnGiznHNdVBOdKa2GaCMCufoqkB89qzghrXuJX5hJ84qx MjZjHr70umhCOcuZmjF8ZpsWQ4T7+dft+Z288sHtp5jEYtaX1wzvw3kAYT2Pgg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none 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 4cdn8d67Cmz3qP; Sat, 04 Oct 2025 00:53:37 +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 5940rbKb066733; Sat, 4 Oct 2025 00:53:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 5940rbos066730; Sat, 4 Oct 2025 00:53:37 GMT (envelope-from git) Date: Sat, 4 Oct 2025 00:53:37 GMT Message-Id: <202510040053.5940rbos066730@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: d4c973fa1485 - main - Revert "flua: kick out the remaining builtin modules" List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d4c973fa148544a0b949ceb1efb6c68096f02baf Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=d4c973fa148544a0b949ceb1efb6c68096f02baf commit d4c973fa148544a0b949ceb1efb6c68096f02baf Author: Kyle Evans AuthorDate: 2025-10-04 00:52:28 +0000 Commit: Kyle Evans CommitDate: 2025-10-04 00:53:28 +0000 Revert "flua: kick out the remaining builtin modules" This reverts commit 80ada959004c4386880e47b11618f8abfc2d80e1, because bootstrap flua is about to get backed out. --- libexec/flua/Makefile | 4 +--- libexec/flua/lfbsd/Makefile | 5 ----- libexec/flua/lfbsd/Makefile.inc | 2 -- libexec/flua/lfs/Makefile | 5 ----- libexec/flua/lfs/Makefile.inc | 2 -- libexec/flua/libhash/lhash.c | 2 -- libexec/flua/linit_flua.c | 7 +++++++ libexec/flua/lposix/Makefile | 5 ----- libexec/flua/lposix/Makefile.inc | 2 -- libexec/flua/{lfbsd => modules}/lfbsd.c | 4 ---- libexec/flua/{lfbsd => modules}/lfbsd.h | 0 libexec/flua/{lfs => modules}/lfs.c | 7 +------ libexec/flua/{lfs => modules}/lfs.h | 0 libexec/flua/{lposix => modules}/lposix.c | 5 ----- libexec/flua/{lposix => modules}/lposix.h | 0 stand/liblua/Makefile | 2 +- stand/loader.mk | 2 +- 17 files changed, 11 insertions(+), 43 deletions(-) diff --git a/libexec/flua/Makefile b/libexec/flua/Makefile index b43b31298205..231abe5dafa2 100644 --- a/libexec/flua/Makefile +++ b/libexec/flua/Makefile @@ -6,13 +6,10 @@ # than mucking about with the infrastructure to make them linkable -- thus, why # these are all structured to have a Makefile that describes what we want # *installed*, and a Makefile.inc that describes what we need to *build*. -FLUA_MODULES+= lfbsd -FLUA_MODULES+= lfs FLUA_MODULES+= libhash FLUA_MODULES+= libjail FLUA_MODULES+= libucl FLUA_MODULES+= liblyaml -FLUA_MODULES+= lposix .ifdef BOOTSTRAPPING FLUA_MODULES+= libfreebsd/sys/linker @@ -50,6 +47,7 @@ SRCS+= lua.c # FreeBSD Extensions .PATH: ${.CURDIR}/modules SRCS+= linit_flua.c +SRCS+= lfs.c lposix.c lfbsd.c CFLAGS+= -I${SRCTOP}/lib/liblua -I${.CURDIR}/modules -I${LUASRC} CFLAGS+= -DLUA_PROGNAME="\"${PROG}\"" diff --git a/libexec/flua/lfbsd/Makefile b/libexec/flua/lfbsd/Makefile deleted file mode 100644 index e2a4aae14bcd..000000000000 --- a/libexec/flua/lfbsd/Makefile +++ /dev/null @@ -1,5 +0,0 @@ -SHLIB_NAME= fbsd.so -WARNS?= 3 - -.include "Makefile.inc" -.include diff --git a/libexec/flua/lfbsd/Makefile.inc b/libexec/flua/lfbsd/Makefile.inc deleted file mode 100644 index 7a78ef82e0fc..000000000000 --- a/libexec/flua/lfbsd/Makefile.inc +++ /dev/null @@ -1,2 +0,0 @@ -.PATH: ${.PARSEDIR} -SRCS+= lfbsd.c diff --git a/libexec/flua/lfs/Makefile b/libexec/flua/lfs/Makefile deleted file mode 100644 index 3df83d6d2fc1..000000000000 --- a/libexec/flua/lfs/Makefile +++ /dev/null @@ -1,5 +0,0 @@ -SHLIB_NAME= lfs.so -WARNS?= 3 - -.include "Makefile.inc" -.include diff --git a/libexec/flua/lfs/Makefile.inc b/libexec/flua/lfs/Makefile.inc deleted file mode 100644 index 9d40c42dc0e6..000000000000 --- a/libexec/flua/lfs/Makefile.inc +++ /dev/null @@ -1,2 +0,0 @@ -.PATH: ${.PARSEDIR} -SRCS+= lfs.c diff --git a/libexec/flua/libhash/lhash.c b/libexec/flua/libhash/lhash.c index f455f006bf27..7127ddc1d530 100644 --- a/libexec/flua/libhash/lhash.c +++ b/libexec/flua/libhash/lhash.c @@ -178,6 +178,4 @@ luaopen_hash(lua_State *L) return 1; } -#ifndef _STANDALONE FLUA_MODULE(hash); -#endif diff --git a/libexec/flua/linit_flua.c b/libexec/flua/linit_flua.c index 161f030923d3..027f1b305d09 100644 --- a/libexec/flua/linit_flua.c +++ b/libexec/flua/linit_flua.c @@ -33,6 +33,9 @@ #include "lualib.h" #include "lauxlib.h" +#include "lfs.h" +#include "lposix.h" +#include "lfbsd.h" #include "bootstrap.h" @@ -54,6 +57,10 @@ static const luaL_Reg loadedlibs[] = { #if defined(LUA_COMPAT_BITLIB) {LUA_BITLIBNAME, luaopen_bit32}, #endif + /* FreeBSD Extensions */ + {"lfs", luaopen_lfs}, + {"posix", luaopen_posix}, + {"fbsd", luaopen_fbsd}, {NULL, NULL} }; diff --git a/libexec/flua/lposix/Makefile b/libexec/flua/lposix/Makefile deleted file mode 100644 index 92321d51be9a..000000000000 --- a/libexec/flua/lposix/Makefile +++ /dev/null @@ -1,5 +0,0 @@ -SHLIB_NAME= posix.so -WARNS?= 3 - -.include "Makefile.inc" -.include diff --git a/libexec/flua/lposix/Makefile.inc b/libexec/flua/lposix/Makefile.inc deleted file mode 100644 index 499e6779e84d..000000000000 --- a/libexec/flua/lposix/Makefile.inc +++ /dev/null @@ -1,2 +0,0 @@ -.PATH: ${.PARSEDIR} -SRCS+= lposix.c diff --git a/libexec/flua/lfbsd/lfbsd.c b/libexec/flua/modules/lfbsd.c similarity index 99% rename from libexec/flua/lfbsd/lfbsd.c rename to libexec/flua/modules/lfbsd.c index 541b6c9611df..ef660ba9fd77 100644 --- a/libexec/flua/lfbsd/lfbsd.c +++ b/libexec/flua/modules/lfbsd.c @@ -40,8 +40,6 @@ #include "lauxlib.h" #include "lfbsd.h" -#include "bootstrap.h" - #define FBSD_PROCESSHANDLE "fbsd_process_t*" struct fbsd_process { @@ -285,5 +283,3 @@ luaopen_fbsd(lua_State *L) return (1); } - -FLUA_MODULE(fbsd); diff --git a/libexec/flua/lfbsd/lfbsd.h b/libexec/flua/modules/lfbsd.h similarity index 100% rename from libexec/flua/lfbsd/lfbsd.h rename to libexec/flua/modules/lfbsd.h diff --git a/libexec/flua/lfs/lfs.c b/libexec/flua/modules/lfs.c similarity index 99% rename from libexec/flua/lfs/lfs.c rename to libexec/flua/modules/lfs.c index 517e16ae65c8..8cb8d6fc9fed 100644 --- a/libexec/flua/lfs/lfs.c +++ b/libexec/flua/modules/lfs.c @@ -66,9 +66,8 @@ #ifdef _STANDALONE #include "lstd.h" #include "lutils.h" -#endif - #include "bootstrap.h" +#endif #ifndef nitems #define nitems(x) (sizeof((x)) / sizeof((x)[0])) @@ -447,7 +446,3 @@ luaopen_lfs(lua_State *L) #endif return 1; } - -#ifndef _STANDALONE -FLUA_MODULE(lfs); -#endif diff --git a/libexec/flua/lfs/lfs.h b/libexec/flua/modules/lfs.h similarity index 100% rename from libexec/flua/lfs/lfs.h rename to libexec/flua/modules/lfs.h diff --git a/libexec/flua/lposix/lposix.c b/libexec/flua/modules/lposix.c similarity index 99% rename from libexec/flua/lposix/lposix.c rename to libexec/flua/modules/lposix.c index 430bb6f28baf..75cdd345aeaa 100644 --- a/libexec/flua/lposix/lposix.c +++ b/libexec/flua/modules/lposix.c @@ -21,8 +21,6 @@ #include "lauxlib.h" #include "lposix.h" -#include "bootstrap.h" - static void enforce_max_args(lua_State *L, int max) { @@ -699,6 +697,3 @@ luaopen_posix(lua_State *L) return (1); } - -/* Only this one needed in our bootstrap set, it will load the others. */ -FLUA_MODULE(posix); diff --git a/libexec/flua/lposix/lposix.h b/libexec/flua/modules/lposix.h similarity index 100% rename from libexec/flua/lposix/lposix.h rename to libexec/flua/modules/lposix.h diff --git a/stand/liblua/Makefile b/stand/liblua/Makefile index b1c34ec0a466..ce7eb89fe494 100644 --- a/stand/liblua/Makefile +++ b/stand/liblua/Makefile @@ -24,7 +24,7 @@ SRCS+= lauxlib.c lbaselib.c lstrlib.c loadlib.c SRCS+= lerrno.c lpager.c lstd.c lutils.c SRCS+= gfx_utils.c -.PATH: ${FLUASRC}/lfs +.PATH: ${FLUASRC}/modules SRCS+= lfs.c .PATH: ${FLUALIB}/libhash SRCS+= lhash.c diff --git a/stand/loader.mk b/stand/loader.mk index e26ba1401912..4073e523e552 100644 --- a/stand/loader.mk +++ b/stand/loader.mk @@ -89,7 +89,7 @@ SRCS+= interp_lua.c .include "${BOOTSRC}/lua.mk" LDR_INTERP= ${LIBLUA} LDR_INTERP32= ${LIBLUA32} -CFLAGS.interp_lua.c= -DLUA_PATH=\"${LUAPATH}\" -I${FLUASRC}/lfs +CFLAGS.interp_lua.c= -DLUA_PATH=\"${LUAPATH}\" -I${FLUASRC}/modules .elif ${LOADER_INTERP} == "4th" SRCS+= interp_forth.c .include "${BOOTSRC}/ficl.mk"