All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch
@ 2014-01-23  8:28 Francois Perrad
  2014-01-23  8:28 ` [Buildroot] [PATCH 2/4] luajit: refactor without shared-lib.patch Francois Perrad
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Francois Perrad @ 2014-01-23  8:28 UTC (permalink / raw)
  To: buildroot

the variable TARGET_STRIP does the job

Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
 package/luajit/luajit-03-dont-strip.patch |   23 -----------------------
 package/luajit/luajit.mk                  |    2 +-
 2 files changed, 1 insertion(+), 24 deletions(-)
 delete mode 100644 package/luajit/luajit-03-dont-strip.patch

diff --git a/package/luajit/luajit-03-dont-strip.patch b/package/luajit/luajit-03-dont-strip.patch
deleted file mode 100644
index 66bdadf..0000000
--- a/package/luajit/luajit-03-dont-strip.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Don't strip the library and binary
-
-This allows Buildroot to do it if needed, but only if needed.
-
-Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-
-Index: b/src/Makefile
-===================================================================
---- a/src/Makefile
-+++ b/src/Makefile
-@@ -665,12 +665,10 @@
- $(LUAJIT_SO): $(LJVMCORE_O)
- 	$(E) "DYNLINK   $@"
- 	$(Q)$(TARGET_LD) $(TARGET_ASHLDFLAGS) -o $@ $(LJVMCORE_DYNO) $(TARGET_ALIBS)
--	$(Q)$(TARGET_STRIP) $@
- 
- $(LUAJIT_T): $(TARGET_O) $(LUAJIT_O) $(TARGET_DEP)
- 	$(E) "LINK      $@"
- 	$(Q)$(TARGET_LD) $(TARGET_ALDFLAGS) -o $@ $(LUAJIT_O) -lluajit -L. $(TARGET_ALIBS)
--	$(Q)$(TARGET_STRIP) $@
- 	$(E) "OK        Successfully built LuaJIT"
- 
- ##############################################################################
diff --git a/package/luajit/luajit.mk b/package/luajit/luajit.mk
index 529d3c2..186b3fd 100644
--- a/package/luajit/luajit.mk
+++ b/package/luajit/luajit.mk
@@ -37,7 +37,7 @@ define LUAJIT_BUILD_CMDS
 		DYNAMIC_CC="$(TARGET_CC) -fPIC" \
 		TARGET_LD="$(TARGET_CC)" \
 		TARGET_AR="$(TARGET_AR) rcus" \
-		TARGET_STRIP="$(TARGET_STRIP)" \
+		TARGET_STRIP=@: \
 		TARGET_CFLAGS="$(TARGET_CFLAGS)" \
 		TARGET_LDFLAGS="$(TARGET_LDFLAGS)" \
 		HOST_CC="$(LUAJIT_HOST_CC)" \
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 2/4] luajit: refactor without shared-lib.patch
  2014-01-23  8:28 [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Francois Perrad
@ 2014-01-23  8:28 ` Francois Perrad
  2014-01-23  8:28 ` [Buildroot] [PATCH 3/4] luajit: add host-luajit Francois Perrad
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Francois Perrad @ 2014-01-23  8:28 UTC (permalink / raw)
  To: buildroot

the variable BUILDMODE does the job

Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
 package/luajit/luajit-02-shared-lib.patch |   17 -----------------
 package/luajit/luajit.mk                  |    1 +
 2 files changed, 1 insertion(+), 17 deletions(-)
 delete mode 100644 package/luajit/luajit-02-shared-lib.patch

diff --git a/package/luajit/luajit-02-shared-lib.patch b/package/luajit/luajit-02-shared-lib.patch
deleted file mode 100644
index 361e5c2..0000000
--- a/package/luajit/luajit-02-shared-lib.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-Compile the luajit binary dynamically against the luajit library
-
-Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-
-Index: b/src/Makefile
-===================================================================
---- a/src/Makefile
-+++ b/src/Makefile
-@@ -669,7 +669,7 @@
- 
- $(LUAJIT_T): $(TARGET_O) $(LUAJIT_O) $(TARGET_DEP)
- 	$(E) "LINK      $@"
--	$(Q)$(TARGET_LD) $(TARGET_ALDFLAGS) -o $@ $(LUAJIT_O) $(TARGET_O) $(TARGET_ALIBS)
-+	$(Q)$(TARGET_LD) $(TARGET_ALDFLAGS) -o $@ $(LUAJIT_O) -lluajit -L. $(TARGET_ALIBS)
- 	$(Q)$(TARGET_STRIP) $@
- 	$(E) "OK        Successfully built LuaJIT"
- 
diff --git a/package/luajit/luajit.mk b/package/luajit/luajit.mk
index 186b3fd..01fbb78 100644
--- a/package/luajit/luajit.mk
+++ b/package/luajit/luajit.mk
@@ -44,6 +44,7 @@ define LUAJIT_BUILD_CMDS
 		HOST_CFLAGS="$(HOST_CFLAGS)" \
 		HOST_LDFLAGS="$(HOST_LDFLAGS)" \
 		$(LUAJIT_NO_LARGEFILE) \
+		BUILDMODE=dynamic \
 		-C $(@D) amalg
 endef
 
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 3/4] luajit: add host-luajit
  2014-01-23  8:28 [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Francois Perrad
  2014-01-23  8:28 ` [Buildroot] [PATCH 2/4] luajit: refactor without shared-lib.patch Francois Perrad
@ 2014-01-23  8:28 ` Francois Perrad
  2014-01-23  8:28 ` [Buildroot] [PATCH 4/4] luarocks: allow to work with host-luajit Francois Perrad
  2014-02-27 22:59 ` [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Thomas Petazzoni
  3 siblings, 0 replies; 6+ messages in thread
From: Francois Perrad @ 2014-01-23  8:28 UTC (permalink / raw)
  To: buildroot


Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
 package/luajit/luajit.mk |    9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/package/luajit/luajit.mk b/package/luajit/luajit.mk
index 01fbb78..f742333 100644
--- a/package/luajit/luajit.mk
+++ b/package/luajit/luajit.mk
@@ -56,4 +56,13 @@ define LUAJIT_INSTALL_TARGET_CMDS
 	$(MAKE) PREFIX="/usr" DESTDIR="$(TARGET_DIR)" -C $(@D) install
 endef
 
+define HOST_LUAJIT_BUILD_CMDS
+	$(MAKE) PREFIX="/usr" BUILDMODE=static -C $(@D) amalg
+endef
+
+define HOST_LUAJIT_INSTALL_CMDS
+	$(MAKE) PREFIX="/usr" DESTDIR="$(HOST_DIR)" -C $(@D) install
+endef
+
 $(eval $(generic-package))
+$(eval $(host-generic-package))
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 4/4] luarocks: allow to work with host-luajit
  2014-01-23  8:28 [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Francois Perrad
  2014-01-23  8:28 ` [Buildroot] [PATCH 2/4] luajit: refactor without shared-lib.patch Francois Perrad
  2014-01-23  8:28 ` [Buildroot] [PATCH 3/4] luajit: add host-luajit Francois Perrad
@ 2014-01-23  8:28 ` Francois Perrad
  2014-02-27 22:59 ` [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Thomas Petazzoni
  3 siblings, 0 replies; 6+ messages in thread
From: Francois Perrad @ 2014-01-23  8:28 UTC (permalink / raw)
  To: buildroot


Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
 package/luainterpreter/luainterpreter.mk |    4 ++++
 package/luarocks/luarocks.mk             |    4 ++--
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/package/luainterpreter/luainterpreter.mk b/package/luainterpreter/luainterpreter.mk
index c37d621..d5b95db 100644
--- a/package/luainterpreter/luainterpreter.mk
+++ b/package/luainterpreter/luainterpreter.mk
@@ -5,8 +5,12 @@
 #############################################################
 
 LUAINTERPRETER_SOURCE =
+HOST_LUAINTERPRETER_SOURCE =
 LUAINTERPRETER_DEPENDENCIES = $(call qstrip,$(BR2_PACKAGE_PROVIDES_LUA_INTERPRETER))
 
 LUAINTERPRETER_ABIVER = $(call qstrip,$(BR2_PACKAGE_LUAINTERPRETER_ABI_VERSION))
 
 $(eval $(generic-package))
+$(eval $(host-generic-package))
+
+LUA_RUN = $(HOST_DIR)/usr/bin/$(call qstrip,$(BR2_PACKAGE_PROVIDES_LUA_INTERPRETER))
diff --git a/package/luarocks/luarocks.mk b/package/luarocks/luarocks.mk
index 88ab22a..1e56bc9 100644
--- a/package/luarocks/luarocks.mk
+++ b/package/luarocks/luarocks.mk
@@ -9,7 +9,7 @@ LUAROCKS_SITE = http://luarocks.org/releases/
 LUAROCKS_LICENSE = MIT
 LUAROCKS_LICENSE_FILES = COPYING
 
-HOST_LUAROCKS_DEPENDENCIES = host-lua luainterpreter
+HOST_LUAROCKS_DEPENDENCIES = host-luainterpreter luainterpreter
 
 LUAROCKS_CONFIG_DIR  = $(HOST_DIR)/usr/etc/luarocks
 LUAROCKS_CONFIG_FILE = $(LUAROCKS_CONFIG_DIR)/config-$(LUAINTERPRETER_ABIVER).lua
@@ -42,4 +42,4 @@ endef
 $(eval $(host-generic-package))
 
 LUAROCKS_RUN = LUA_PATH="$(HOST_DIR)/usr/share/lua/$(LUAINTERPRETER_ABIVER)/?.lua" \
-	$(HOST_DIR)/usr/bin/lua $(HOST_DIR)/usr/bin/luarocks
+	$(LUA_RUN) $(HOST_DIR)/usr/bin/luarocks
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch
  2014-01-23  8:28 [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Francois Perrad
                   ` (2 preceding siblings ...)
  2014-01-23  8:28 ` [Buildroot] [PATCH 4/4] luarocks: allow to work with host-luajit Francois Perrad
@ 2014-02-27 22:59 ` Thomas Petazzoni
  2014-02-28  0:40   ` François Perrad
  3 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2014-02-27 22:59 UTC (permalink / raw)
  To: buildroot

Dear Francois Perrad,

On Thu, 23 Jan 2014 09:28:30 +0100, Francois Perrad wrote:
> the variable TARGET_STRIP does the job
> 
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
> ---
>  package/luajit/luajit-03-dont-strip.patch |   23 -----------------------
>  package/luajit/luajit.mk                  |    2 +-
>  2 files changed, 1 insertion(+), 24 deletions(-)
>  delete mode 100644 package/luajit/luajit-03-dont-strip.patch

Looks good to me. Just a question below.


> +		TARGET_STRIP=@: \

Any reason to use @: instead of just : ?

Also, personally, I would probably prefer TARGET_STRIP=true. I know
it's the same, but I find the usage of ':' a bit hard to read.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch
  2014-02-27 22:59 ` [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Thomas Petazzoni
@ 2014-02-28  0:40   ` François Perrad
  0 siblings, 0 replies; 6+ messages in thread
From: François Perrad @ 2014-02-28  0:40 UTC (permalink / raw)
  To: buildroot

2014-02-27 23:59 GMT+01:00 Thomas Petazzoni
<thomas.petazzoni@free-electrons.com>:
> Dear Francois Perrad,
>
> On Thu, 23 Jan 2014 09:28:30 +0100, Francois Perrad wrote:
>> the variable TARGET_STRIP does the job
>>
>> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
>> ---
>>  package/luajit/luajit-03-dont-strip.patch |   23 -----------------------
>>  package/luajit/luajit.mk                  |    2 +-
>>  2 files changed, 1 insertion(+), 24 deletions(-)
>>  delete mode 100644 package/luajit/luajit-03-dont-strip.patch
>
> Looks good to me. Just a question below.
>
>
>> +             TARGET_STRIP=@: \
>
> Any reason to use @: instead of just : ?
>

I've seen this value in the Makefile at
http://repo.or.cz/w/luajit-2.0.git/blob/HEAD:/src/Makefile#l354
so I copy/paste it.

Fran?ois

> Also, personally, I would probably prefer TARGET_STRIP=true. I know
> it's the same, but I find the usage of ':' a bit hard to read.
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-02-28  0:40 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-23  8:28 [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Francois Perrad
2014-01-23  8:28 ` [Buildroot] [PATCH 2/4] luajit: refactor without shared-lib.patch Francois Perrad
2014-01-23  8:28 ` [Buildroot] [PATCH 3/4] luajit: add host-luajit Francois Perrad
2014-01-23  8:28 ` [Buildroot] [PATCH 4/4] luarocks: allow to work with host-luajit Francois Perrad
2014-02-27 22:59 ` [Buildroot] [PATCH 1/4] luajit: refactor without dont-strip.patch Thomas Petazzoni
2014-02-28  0:40   ` François Perrad

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.