* [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks
@ 2020-03-22 8:07 Francois Perrad
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 2/5] pkg-luarocks: refactor infra Francois Perrad
` (4 more replies)
0 siblings, 5 replies; 10+ messages in thread
From: Francois Perrad @ 2020-03-22 8:07 UTC (permalink / raw)
To: buildroot
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/luarocks/luarocks.mk | 7 -------
1 file changed, 7 deletions(-)
diff --git a/package/luarocks/luarocks.mk b/package/luarocks/luarocks.mk
index 123f8c073..d48c95ced 100644
--- a/package/luarocks/luarocks.mk
+++ b/package/luarocks/luarocks.mk
@@ -33,17 +33,10 @@ define HOST_LUAROCKS_CONFIGURE_CMDS
cd $(@D) && ./configure $(HOST_LUAROCKS_CONF_OPTS)
endef
-ifeq ($(BR2_PACKAGE_LUAJIT),y)
-define LUAROCKS_CONFIGURE_INTERPRETER_LUAJIT
- echo "lua_interpreter = [[luajit]]" >> $(LUAROCKS_CONFIG_FILE)
-endef
-endif
-
define HOST_LUAROCKS_INSTALL_CMDS
rm -f $(LUAROCKS_CONFIG_FILE)
$(MAKE1) -C $(@D) install
cat $(HOST_LUAROCKS_PKGDIR)/luarocks-br-config.lua >> $(LUAROCKS_CONFIG_FILE)
- $(LUAROCKS_CONFIGURE_INTERPRETER_LUAJIT)
endef
$(eval $(host-generic-package))
--
2.20.1
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 2/5] pkg-luarocks: refactor infra
2020-03-22 8:07 [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Francois Perrad
@ 2020-03-22 8:07 ` Francois Perrad
2020-04-12 9:57 ` Thomas Petazzoni
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 3/5] pkg-luarocks: add support of host-luarocks-package Francois Perrad
` (3 subsequent siblings)
4 siblings, 1 reply; 10+ messages in thread
From: Francois Perrad @ 2020-03-22 8:07 UTC (permalink / raw)
To: buildroot
move stuff from luarocks.mk and luarocks-br-config.lua
to pkg-luarocks.mk
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/luarocks/luarocks-br-config.lua | 8 --------
package/luarocks/luarocks.mk | 11 -----------
package/pkg-luarocks.mk | 20 +++++++++++++++++---
3 files changed, 17 insertions(+), 22 deletions(-)
diff --git a/package/luarocks/luarocks-br-config.lua b/package/luarocks/luarocks-br-config.lua
index 32d71e1e2..3a0bd68c9 100644
--- a/package/luarocks/luarocks-br-config.lua
+++ b/package/luarocks/luarocks-br-config.lua
@@ -1,13 +1,5 @@
-- BR cross-compilation
local function getenv (name) return os_getenv(name) or '' end
-variables.LUA_INCDIR = getenv('STAGING_DIR') .. [[/usr/include]]
-variables.LUA_LIBDIR = getenv('STAGING_DIR') .. [[/usr/lib]]
-variables.CC = getenv('TARGET_CC')
-variables.LD = getenv('TARGET_CC')
-variables.CFLAGS = getenv('TARGET_CFLAGS')
-variables.LIBFLAG = [[-shared ]] .. getenv('TARGET_LDFLAGS')
external_deps_dirs = { getenv('STAGING_DIR') .. [[/usr]] }
gcc_rpath = false
-rocks_trees = { getenv('TARGET_DIR') .. [[/usr]] }
wrap_bin_scripts = false
-deps_mode = [[none]]
diff --git a/package/luarocks/luarocks.mk b/package/luarocks/luarocks.mk
index d48c95ced..17360048c 100644
--- a/package/luarocks/luarocks.mk
+++ b/package/luarocks/luarocks.mk
@@ -13,10 +13,6 @@ HOST_LUAROCKS_DEPENDENCIES = host-luainterpreter
LUAROCKS_CONFIG_DIR = $(HOST_DIR)/etc
LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/luarocks/config-$(LUAINTERPRETER_ABIVER).lua
-LUAROCKS_CFLAGS = $(TARGET_CFLAGS) -fPIC
-ifeq ($(BR2_PACKAGE_LUA_5_3),y)
-LUAROCKS_CFLAGS += -DLUA_COMPAT_5_2
-endif
define LUAROCKS_ADDON_EXTRACT
mkdir $(@D)/src/luarocks/cmd/external
@@ -41,13 +37,6 @@ endef
$(eval $(host-generic-package))
-LUAROCKS_RUN_ENV = \
- LUA_PATH="$(HOST_DIR)/share/lua/$(LUAINTERPRETER_ABIVER)/?.lua" \
- TARGET_CC="$(TARGET_CC)" \
- TARGET_CFLAGS="$(LUAROCKS_CFLAGS)" \
- TARGET_LDFLAGS="$(TARGET_LDFLAGS)"
-LUAROCKS_RUN_CMD = $(LUA_RUN) $(HOST_DIR)/bin/luarocks
-
define LUAROCKS_FINALIZE_TARGET
rm -rf $(TARGET_DIR)/usr/lib/luarocks
endef
diff --git a/package/pkg-luarocks.mk b/package/pkg-luarocks.mk
index 78d6c325f..23906f4a8 100644
--- a/package/pkg-luarocks.mk
+++ b/package/pkg-luarocks.mk
@@ -17,6 +17,12 @@
#
################################################################################
+LUAROCKS_RUN_CMD = $(HOST_DIR)/bin/luarocks
+LUAROCKS_CFLAGS = $(TARGET_CFLAGS) -fPIC
+ifeq ($(BR2_PACKAGE_LUA_5_3),y)
+LUAROCKS_CFLAGS += -DLUA_COMPAT_5_2
+endif
+
################################################################################
# inner-luarocks-package -- defines how the configuration, compilation and
# installation of a LuaRocks package should be done, implements a few hooks to
@@ -53,7 +59,7 @@ ifndef $(2)_EXTRACT_CMDS
define $(2)_EXTRACT_CMDS
mkdir -p $$($(2)_DIR)/luarocks-extract
cd $$($(2)_DIR)/luarocks-extract && \
- $$(LUAROCKS_RUN_ENV) $$(LUAROCKS_RUN_CMD) unpack --force $$($(2)_DL_DIR)/$$($(2)_SOURCE)
+ $$(LUAROCKS_RUN_CMD) unpack --force $$($(2)_DL_DIR)/$$($(2)_SOURCE)
mv $$($(2)_DIR)/luarocks-extract/*/* $$($(2)_DIR)
endef
endif
@@ -63,8 +69,16 @@ endif
#
ifndef $(2)_INSTALL_TARGET_CMDS
define $(2)_INSTALL_TARGET_CMDS
- cd $$($(2)_SRCDIR) && $$(LUAROCKS_RUN_ENV) \
- $$(LUAROCKS_RUN_CMD) make --keep $$($(2)_ROCKSPEC) $$($(2)_BUILD_OPTS)
+ cd $$($(2)_SRCDIR) && \
+ $$(LUAROCKS_RUN_CMD) make --keep --deps-mode none \
+ --tree "$$(TARGET_DIR)/usr" \
+ LUA_INCDIR="$$(STAGING_DIR)/usr/include" \
+ LUA_LIBDIR="$$(STAGING_DIR)/usr/lib" \
+ CC=$$(TARGET_CC) \
+ LD=$$(TARGET_CC) \
+ CFLAGS="$$(LUAROCKS_CFLAGS)" \
+ LIBFLAG="-shared $$(TARGET_LDFLAGS)" \
+ $$($(2)_BUILD_OPTS) $$($(2)_ROCKSPEC)
endef
endif
--
2.20.1
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 3/5] pkg-luarocks: add support of host-luarocks-package
2020-03-22 8:07 [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Francois Perrad
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 2/5] pkg-luarocks: refactor infra Francois Perrad
@ 2020-03-22 8:07 ` Francois Perrad
2020-04-12 12:59 ` Thomas Petazzoni
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 4/5] package/lua: allows to load native modules from host-lua Francois Perrad
` (2 subsequent siblings)
4 siblings, 1 reply; 10+ messages in thread
From: Francois Perrad @ 2020-03-22 8:07 UTC (permalink / raw)
To: buildroot
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
docs/manual/adding-packages-luarocks.txt | 4 +-
package/luarocks/luarocks-br-host-config.lua | 3 +
package/luarocks/luarocks.mk | 10 ++-
package/pkg-luarocks.mk | 68 +++++++++++++++++---
4 files changed, 70 insertions(+), 15 deletions(-)
create mode 100644 package/luarocks/luarocks-br-host-config.lua
diff --git a/docs/manual/adding-packages-luarocks.txt b/docs/manual/adding-packages-luarocks.txt
index df97cdd50..70f48fc02 100644
--- a/docs/manual/adding-packages-luarocks.txt
+++ b/docs/manual/adding-packages-luarocks.txt
@@ -73,9 +73,7 @@ infrastructures in Buildroot, respectively.
The main macro of the LuaRocks package infrastructure is +luarocks-package+:
like +generic-package+ it works by defining a number of variables providing
-metadata information about the package, and then calling +luarocks-package+. It
-is worth mentioning that building LuaRocks packages for the host is not
-supported, so the macro +host-luarocks-package+ is not implemented.
+metadata information about the package, and then calling +luarocks-package+.
Just like the generic infrastructure, the LuaRocks infrastructure works
by defining a number of variables before calling the +luarocks-package+
diff --git a/package/luarocks/luarocks-br-host-config.lua b/package/luarocks/luarocks-br-host-config.lua
new file mode 100644
index 000000000..631959545
--- /dev/null
+++ b/package/luarocks/luarocks-br-host-config.lua
@@ -0,0 +1,3 @@
+-- BR host compilation
+local function getenv (name) return os_getenv(name) or '' end
+external_deps_dirs = { getenv('HOST_DIR') }
diff --git a/package/luarocks/luarocks.mk b/package/luarocks/luarocks.mk
index 17360048c..b95172047 100644
--- a/package/luarocks/luarocks.mk
+++ b/package/luarocks/luarocks.mk
@@ -12,7 +12,9 @@ LUAROCKS_LICENSE_FILES = COPYING
HOST_LUAROCKS_DEPENDENCIES = host-luainterpreter
LUAROCKS_CONFIG_DIR = $(HOST_DIR)/etc
-LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/luarocks/config-$(LUAINTERPRETER_ABIVER).lua
+LUAROCKS_CONFIG_FILE_DEFAULT = $(LUAROCKS_CONFIG_DIR)/luarocks/config-$(LUAINTERPRETER_ABIVER).lua
+LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/luarocks/config.lua
+HOST_LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/luarocks/host-config.lua
define LUAROCKS_ADDON_EXTRACT
mkdir $(@D)/src/luarocks/cmd/external
@@ -30,9 +32,13 @@ define HOST_LUAROCKS_CONFIGURE_CMDS
endef
define HOST_LUAROCKS_INSTALL_CMDS
- rm -f $(LUAROCKS_CONFIG_FILE)
+ rm -f $(LUAROCKS_CONFIG_FILE_DEFAULT)
$(MAKE1) -C $(@D) install
+ cp $(LUAROCKS_CONFIG_FILE_DEFAULT) $(LUAROCKS_CONFIG_FILE)
cat $(HOST_LUAROCKS_PKGDIR)/luarocks-br-config.lua >> $(LUAROCKS_CONFIG_FILE)
+ cp $(LUAROCKS_CONFIG_FILE_DEFAULT) $(HOST_LUAROCKS_CONFIG_FILE)
+ cat $(HOST_LUAROCKS_PKGDIR)/luarocks-br-host-config.lua >> $(HOST_LUAROCKS_CONFIG_FILE)
+ rm -f $(LUAROCKS_CONFIG_FILE_DEFAULT)
endef
$(eval $(host-generic-package))
diff --git a/package/pkg-luarocks.mk b/package/pkg-luarocks.mk
index 23906f4a8..603c0851b 100644
--- a/package/pkg-luarocks.mk
+++ b/package/pkg-luarocks.mk
@@ -19,8 +19,10 @@
LUAROCKS_RUN_CMD = $(HOST_DIR)/bin/luarocks
LUAROCKS_CFLAGS = $(TARGET_CFLAGS) -fPIC
+HOST_LUAROCKS_CFLAGS = $(HOST_CFLAGS) -fPIC
ifeq ($(BR2_PACKAGE_LUA_5_3),y)
LUAROCKS_CFLAGS += -DLUA_COMPAT_5_2
+HOST_LUAROCKS_CFLAGS += -DLUA_COMPAT_5_2
endif
################################################################################
@@ -39,16 +41,50 @@ endif
define inner-luarocks-package
-$(2)_BUILD_OPTS ?=
-$(2)_NAME_UPSTREAM ?= $(1)
-$(2)_SUBDIR ?= $$($(2)_NAME_UPSTREAM)-$$(shell echo "$$($(2)_VERSION)" | sed -e "s/-[0-9]$$$$//")
-$(2)_ROCKSPEC ?= $$(call LOWERCASE,$$($(2)_NAME_UPSTREAM))-$$($(2)_VERSION).rockspec
-$(2)_SOURCE ?= $$(call LOWERCASE,$$($(2)_NAME_UPSTREAM))-$$($(2)_VERSION).src.rock
-$(2)_SITE ?= $$(call qstrip,$$(BR2_LUAROCKS_MIRROR))
+ifndef $(2)_NAME_UPSTREAM
+ ifdef $(3)_NAME_UPSTREAM
+ $(2)_NAME_UPSTREAM = $($(3)_NAME_UPSTREAM)
+ else
+ $(2)_NAME_UPSTREAM ?= $(1)
+ endif
+endif
+
+ifndef $(2)_SUBDIR
+ ifdef $(3)_SUBDIR
+ $(2)_SUBDIR = $($(3)_SUBDIR)
+ else
+ $(2)_SUBDIR ?= $$($(3)_NAME_UPSTREAM)-$$(shell echo "$$($(3)_VERSION)" | sed -e "s/-[0-9]$$$$//")
+ endif
+endif
+
+ifndef $(2)_ROCKSPEC
+ ifdef $(3)_ROCKSPEC
+ $(2)_ROCKSPEC = $($(3)_ROCKSPEC)
+ else
+ $(2)_ROCKSPEC ?= $$(call LOWERCASE,$$($(3)_NAME_UPSTREAM))-$$($(3)_VERSION).rockspec
+ endif
+endif
+
+ifndef $(2)_SOURCE
+ ifdef $(3)_SOURCE
+ $(2)_SOURCE = $($(3)_SOURCE)
+ else
+ $(2)_SOURCE ?= $$(call LOWERCASE,$$($(3)_NAME_UPSTREAM))-$$($(3)_VERSION).src.rock
+ endif
+endif
+
+ifndef $(2)_SITE
+ ifdef $(3)_SITE
+ $(2)_SITE = $($(3)_SITE)
+ else
+ $(2)_SITE ?= $$(call qstrip,$$(BR2_LUAROCKS_MIRROR))
+ endif
+endif
-# Since we do not support host-luarocks-package, we know this is
-# a target package, and can just add the required dependencies
-$(2)_DEPENDENCIES += luainterpreter
+ifeq ($(4),target)
+$(2)_DEPENDENCIES += luainterpreter
+endif
+# host-luarocks implies host-luainterpreter
$(2)_EXTRACT_DEPENDENCIES += host-luarocks
#
@@ -70,6 +106,7 @@ endif
ifndef $(2)_INSTALL_TARGET_CMDS
define $(2)_INSTALL_TARGET_CMDS
cd $$($(2)_SRCDIR) && \
+ LUAROCKS_CONFIG=$$(LUAROCKS_CONFIG_FILE) \
$$(LUAROCKS_RUN_CMD) make --keep --deps-mode none \
--tree "$$(TARGET_DIR)/usr" \
LUA_INCDIR="$$(STAGING_DIR)/usr/include" \
@@ -82,6 +119,17 @@ define $(2)_INSTALL_TARGET_CMDS
endef
endif
+ifndef $(2)_INSTALL_CMDS
+define $(2)_INSTALL_CMDS
+ cd $$($(2)_SRCDIR) && \
+ LUAROCKS_CONFIG=$$(HOST_LUAROCKS_CONFIG_FILE) \
+ $$(LUAROCKS_RUN_CMD) make --keep --deps-mode none \
+ CFLAGS="$$(HOST_LUAROCKS_CFLAGS)" \
+ LIBFLAG="-shared $$(HOST_LDFLAGS)" \
+ $$($(2)_BUILD_OPTS) $$($(2)_ROCKSPEC)
+endef
+endif
+
# Call the generic package infrastructure to generate the necessary
# make targets
$(call inner-generic-package,$(1),$(2),$(3),$(4))
@@ -99,4 +147,4 @@ endef
################################################################################
luarocks-package = $(call inner-luarocks-package,$(pkgname),$(call UPPERCASE,$(pkgname)),$(call UPPERCASE,$(pkgname)),target)
-# host-luarocks-package not supported
+host-luarocks-package = $(call inner-luarocks-package,host-$(pkgname),$(call UPPERCASE,host-$(pkgname)),$(call UPPERCASE,$(pkgname)),host)
--
2.20.1
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 4/5] package/lua: allows to load native modules from host-lua
2020-03-22 8:07 [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Francois Perrad
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 2/5] pkg-luarocks: refactor infra Francois Perrad
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 3/5] pkg-luarocks: add support of host-luarocks-package Francois Perrad
@ 2020-03-22 8:07 ` Francois Perrad
2020-04-12 12:59 ` Thomas Petazzoni
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 5/5] package/lua: allows host-lua to find installed modules Francois Perrad
2020-04-11 14:01 ` [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Thomas Petazzoni
4 siblings, 1 reply; 10+ messages in thread
From: Francois Perrad @ 2020-03-22 8:07 UTC (permalink / raw)
To: buildroot
so, we need a liblua.so
and some modules require Lua 5.2 functions
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/lua/lua.mk | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/package/lua/lua.mk b/package/lua/lua.mk
index 8a5f9258a..2ff2fdf75 100644
--- a/package/lua/lua.mk
+++ b/package/lua/lua.mk
@@ -55,6 +55,9 @@ LUA_POST_PATCH_HOOKS += LUA_32BITS_LUACONF
endif
HOST_LUA_CFLAGS = -Wall -fPIC -DLUA_USE_DLOPEN -DLUA_USE_POSIX
+ifeq ($(BR2_PACKAGE_LUA_5_3),y)
+HOST_LUA_CFLAGS += -DLUA_COMPAT_5_2
+endif
HOST_LUA_MYLIBS = -ldl
define LUA_BUILD_CMDS
@@ -74,7 +77,7 @@ define HOST_LUA_BUILD_CMDS
CFLAGS="$(HOST_LUA_CFLAGS)" \
MYLDFLAGS="$(HOST_LDFLAGS)" \
MYLIBS="$(HOST_LUA_MYLIBS)" \
- BUILDMODE=static \
+ BUILDMODE=dynamic \
PKG_VERSION=$(LUA_VERSION) -C $(@D)/src all
sed -e "s/@VERSION@/$(LUA_VERSION)/;s/@ABI@/$(LUAINTERPRETER_ABIVER)/;s/@MYLIBS@/$(HOST_LUA_MYLIBS)/" \
package/lua/lua.pc.in > $(@D)/lua.pc
--
2.20.1
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 5/5] package/lua: allows host-lua to find installed modules
2020-03-22 8:07 [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Francois Perrad
` (2 preceding siblings ...)
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 4/5] package/lua: allows to load native modules from host-lua Francois Perrad
@ 2020-03-22 8:07 ` Francois Perrad
2020-04-12 12:59 ` Thomas Petazzoni
2020-04-11 14:01 ` [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Thomas Petazzoni
4 siblings, 1 reply; 10+ messages in thread
From: Francois Perrad @ 2020-03-22 8:07 UTC (permalink / raw)
To: buildroot
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/lua/lua.mk | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/package/lua/lua.mk b/package/lua/lua.mk
index 2ff2fdf75..30dbf0d68 100644
--- a/package/lua/lua.mk
+++ b/package/lua/lua.mk
@@ -54,6 +54,12 @@ endef
LUA_POST_PATCH_HOOKS += LUA_32BITS_LUACONF
endif
+define HOST_LUA_LUACONF
+ $(SED) 's|#define LUA_ROOT.*|#define LUA_ROOT "$(HOST_DIR)/usr/"|' $(@D)/src/luaconf.h
+endef
+
+HOST_LUA_POST_PATCH_HOOKS += HOST_LUA_LUACONF
+
HOST_LUA_CFLAGS = -Wall -fPIC -DLUA_USE_DLOPEN -DLUA_USE_POSIX
ifeq ($(BR2_PACKAGE_LUA_5_3),y)
HOST_LUA_CFLAGS += -DLUA_COMPAT_5_2
--
2.20.1
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks
2020-03-22 8:07 [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Francois Perrad
` (3 preceding siblings ...)
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 5/5] package/lua: allows host-lua to find installed modules Francois Perrad
@ 2020-04-11 14:01 ` Thomas Petazzoni
4 siblings, 0 replies; 10+ messages in thread
From: Thomas Petazzoni @ 2020-04-11 14:01 UTC (permalink / raw)
To: buildroot
On Sun, 22 Mar 2020 09:07:02 +0100
Francois Perrad <fperrad@gmail.com> wrote:
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
> ---
> package/luarocks/luarocks.mk | 7 -------
> 1 file changed, 7 deletions(-)
Why no commit log? Come on Fran?ois, we've asked you many, many, many,
many times to have more details in your commit log. So an empty commit
should definitely be a sign that the patch is not good.
So, I've taken the time to extend the commit log by doing some research
in the Luarocks Git commit history. See:
https://git.buildroot.org/buildroot/commit/?id=a27d01cde157ea0534ba66fecc3e8fb82cde9155
It would really be nice if you could help us by providing more detailed
commit logs.
Thanks for your help.
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 2/5] pkg-luarocks: refactor infra
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 2/5] pkg-luarocks: refactor infra Francois Perrad
@ 2020-04-12 9:57 ` Thomas Petazzoni
0 siblings, 0 replies; 10+ messages in thread
From: Thomas Petazzoni @ 2020-04-12 9:57 UTC (permalink / raw)
To: buildroot
On Sun, 22 Mar 2020 09:07:03 +0100
Francois Perrad <fperrad@gmail.com> wrote:
> move stuff from luarocks.mk and luarocks-br-config.lua
> to pkg-luarocks.mk
>
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
> ---
> package/luarocks/luarocks-br-config.lua | 8 --------
> package/luarocks/luarocks.mk | 11 -----------
> package/pkg-luarocks.mk | 20 +++++++++++++++++---
> 3 files changed, 17 insertions(+), 22 deletions(-)
I have applied, but after extending the commit log to give more details
about what is happening:
https://git.buildroot.org/buildroot/commit/?id=052629291449147ff18dc6ff63a94f043ea4aadf
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 3/5] pkg-luarocks: add support of host-luarocks-package
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 3/5] pkg-luarocks: add support of host-luarocks-package Francois Perrad
@ 2020-04-12 12:59 ` Thomas Petazzoni
0 siblings, 0 replies; 10+ messages in thread
From: Thomas Petazzoni @ 2020-04-12 12:59 UTC (permalink / raw)
To: buildroot
Hello,
On Sun, 22 Mar 2020 09:07:04 +0100
Francois Perrad <fperrad@gmail.com> wrote:
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
So I have applied, but after splitting this into two patches. See below.
> LUAROCKS_CONFIG_DIR = $(HOST_DIR)/etc
> -LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/luarocks/config-$(LUAINTERPRETER_ABIVER).lua
> +LUAROCKS_CONFIG_FILE_DEFAULT = $(LUAROCKS_CONFIG_DIR)/luarocks/config-$(LUAINTERPRETER_ABIVER).lua
> +LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/luarocks/config.lua
> +HOST_LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/luarocks/host-config.lua
I've split out the fact that we use a different configuration file for
the target into a separate commit.
> define HOST_LUAROCKS_INSTALL_CMDS
> - rm -f $(LUAROCKS_CONFIG_FILE)
> + rm -f $(LUAROCKS_CONFIG_FILE_DEFAULT)
> $(MAKE1) -C $(@D) install
> + cp $(LUAROCKS_CONFIG_FILE_DEFAULT) $(LUAROCKS_CONFIG_FILE)
> cat $(HOST_LUAROCKS_PKGDIR)/luarocks-br-config.lua >> $(LUAROCKS_CONFIG_FILE)
I've used:
cat foo1 foo2 > foo
instead of:
cp foo1 foo
cat foo2 >> foo
But, can't we instead use some Lua statement/directive to have the
common config file included by both the host and target configuration
files ? That would be a bit nicer than having to concatenate them here.
See the two final commits:
https://git.buildroot.org/buildroot/commit/?id=a850cdce5373408890a2b35de31db04963870143
https://git.buildroot.org/buildroot/commit/?id=060eb0e7e4fe67f86f0027383c6f74ee46eb3aa0
Could you submit a patch that adds a host luarocks package, so at least
this feature is used by one package in the tree ?
Thanks,
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 4/5] package/lua: allows to load native modules from host-lua
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 4/5] package/lua: allows to load native modules from host-lua Francois Perrad
@ 2020-04-12 12:59 ` Thomas Petazzoni
0 siblings, 0 replies; 10+ messages in thread
From: Thomas Petazzoni @ 2020-04-12 12:59 UTC (permalink / raw)
To: buildroot
On Sun, 22 Mar 2020 09:07:05 +0100
Francois Perrad <fperrad@gmail.com> wrote:
> so, we need a liblua.so
> and some modules require Lua 5.2 functions
>
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
> ---
> package/lua/lua.mk | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
Applied to master with an improved commit log.
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [pkg-luarocks v2 5/5] package/lua: allows host-lua to find installed modules
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 5/5] package/lua: allows host-lua to find installed modules Francois Perrad
@ 2020-04-12 12:59 ` Thomas Petazzoni
0 siblings, 0 replies; 10+ messages in thread
From: Thomas Petazzoni @ 2020-04-12 12:59 UTC (permalink / raw)
To: buildroot
On Sun, 22 Mar 2020 09:07:06 +0100
Francois Perrad <fperrad@gmail.com> wrote:
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
> ---
> package/lua/lua.mk | 6 ++++++
> 1 file changed, 6 insertions(+)
Applied to master with an improved commit log. Thanks!
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2020-04-12 12:59 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-22 8:07 [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Francois Perrad
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 2/5] pkg-luarocks: refactor infra Francois Perrad
2020-04-12 9:57 ` Thomas Petazzoni
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 3/5] pkg-luarocks: add support of host-luarocks-package Francois Perrad
2020-04-12 12:59 ` Thomas Petazzoni
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 4/5] package/lua: allows to load native modules from host-lua Francois Perrad
2020-04-12 12:59 ` Thomas Petazzoni
2020-03-22 8:07 ` [Buildroot] [pkg-luarocks v2 5/5] package/lua: allows host-lua to find installed modules Francois Perrad
2020-04-12 12:59 ` Thomas Petazzoni
2020-04-11 14:01 ` [Buildroot] [pkg-luarocks v2 1/5] package/luarocks: now luajit is dynamically detected by luarocks Thomas Petazzoni
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.