Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
@ 2012-07-09 12:40 Philippe Reynes
  2012-07-14 21:47 ` Arnout Vandecappelle
  0 siblings, 1 reply; 9+ messages in thread
From: Philippe Reynes @ 2012-07-09 12:40 UTC (permalink / raw)
  To: buildroot

Using severals post build scripts is usefull to share
script between severals boards/projects.

Signed-off-by: Philippe Reynes <philippe.reynes@sagemcom.com>
---
 Makefile                 |    5 +++--
 target/generic/Config.in |   11 ++++++-----
 2 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/Makefile b/Makefile
index b80477f..e2979e1 100644
--- a/Makefile
+++ b/Makefile
@@ -448,8 +448,9 @@ endif
 	) >  $(TARGET_DIR)/etc/os-release
 
 ifneq ($(BR2_ROOTFS_POST_BUILD_SCRIPT),"")
-	@$(call MESSAGE,"Executing post-build script")
-	$(BR2_ROOTFS_POST_BUILD_SCRIPT) $(TARGET_DIR)
+	@$(call MESSAGE,"Executing post-build script\(s\)")
+	@$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_BUILD_SCRIPT)), \
+		$(s) $(TARGET_DIR)$(sep))
 endif
 
 ifeq ($(BR2_ENABLE_LOCALE_PURGE),y)
diff --git a/target/generic/Config.in b/target/generic/Config.in
index 88f0718..b987331 100644
--- a/target/generic/Config.in
+++ b/target/generic/Config.in
@@ -138,15 +138,16 @@ config BR2_ROOTFS_POST_BUILD_SCRIPT
 	string "Custom script to run before creating filesystem images"
 	default ""
 	help
-	  Specify a script to be run after the build has finished and before
-	  Buildroot starts packing the files into selected filesystem images.
+	  Specify a space-separated list of scripts to be run after the build
+	  has finished and before Buildroot starts packing the files into 
+	  selected filesystem images.
 
 	  This gives users the oportunity to do board-specific cleanups,
 	  add-ons and the like, so the generated files can be used directly
 	  without further processing.
 
-	  The script is called with the target directory name as first and
-	  only argument. Make sure the exit code of that script is 0,
-	  otherwise make will stop after calling it.
+	  These scripts are called with the target directory name as first and
+	  only argument. Make sure the exit code of those scripts are 0,
+	  otherwise make will stop after calling them.
 
 endmenu
-- 
1.7.1


#
" Ce courriel et les documents qui lui sont joints peuvent contenir des
informations confidentielles ou ayant un caract?re priv?. S'ils ne vous sont
pas destin?s, nous vous signalons qu'il est strictement interdit de les
divulguer, de les reproduire ou d'en utiliser de quelque mani?re que ce
soit le contenu. Si ce message vous a ?t? transmis par erreur, merci d'en
informer l'exp?diteur et de supprimer imm?diatement de votre syst?me
informatique ce courriel ainsi que tous les documents qui y sont attach?s."


                               ******

" This e-mail and any attached documents may contain confidential or
proprietary information. If you are not the intended recipient, you are
notified that any dissemination, copying of this e-mail and any attachments
thereto or use of their contents by any means whatsoever is strictly
prohibited. If you have received this e-mail in error, please advise the
sender immediately and delete this e-mail and all attached documents
from your computer system."
#

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
  2012-07-09 12:40 [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one Philippe Reynes
@ 2012-07-14 21:47 ` Arnout Vandecappelle
  2012-07-16  6:09   ` Philippe REYNES
  0 siblings, 1 reply; 9+ messages in thread
From: Arnout Vandecappelle @ 2012-07-14 21:47 UTC (permalink / raw)
  To: buildroot

On 07/09/12 14:40, Philippe Reynes wrote:
> Using severals post build scripts is usefull to share
> script between severals boards/projects.
>
> Signed-off-by: Philippe Reynes<philippe.reynes@sagemcom.com>
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>

  I assume you tested it with the $(sep)?  I didn't, I just reviewed.

  Regards,
  Arnout
-- 
Arnout Vandecappelle                               arnout at mind be
Senior Embedded Software Architect                 +32-16-286540
Essensium/Mind                                     http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium                BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
  2012-07-14 21:47 ` Arnout Vandecappelle
@ 2012-07-16  6:09   ` Philippe REYNES
  0 siblings, 0 replies; 9+ messages in thread
From: Philippe REYNES @ 2012-07-16  6:09 UTC (permalink / raw)
  To: buildroot



Arnout Vandecappelle <arnout@mind.be> wrote on 07/14/2012 23:47:04:

> >
> > Signed-off-by: Philippe Reynes<philippe.reynes@sagemcom.com>
> Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
>
>   I assume you tested it with the $(sep)?  I didn't, I just reviewed.
>

Yes, I've tested, it works fine.
Thanks a lot for the feedback.

Regards,
Philippe


#
" Ce courriel et les documents qui lui sont joints peuvent contenir des
informations confidentielles ou ayant un caract?re priv?. S'ils ne vous sont
pas destin?s, nous vous signalons qu'il est strictement interdit de les
divulguer, de les reproduire ou d'en utiliser de quelque mani?re que ce
soit le contenu. Si ce message vous a ?t? transmis par erreur, merci d'en
informer l'exp?diteur et de supprimer imm?diatement de votre syst?me
informatique ce courriel ainsi que tous les documents qui y sont attach?s."


                               ******

" This e-mail and any attached documents may contain confidential or
proprietary information. If you are not the intended recipient, you are
notified that any dissemination, copying of this e-mail and any attachments
thereto or use of their contents by any means whatsoever is strictly
prohibited. If you have received this e-mail in error, please advise the
sender immediately and delete this e-mail and all attached documents
from your computer system."
#

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
@ 2012-10-29  6:53 Philippe Reynes
  2012-10-29  7:34 ` Samuel Martin
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Philippe Reynes @ 2012-10-29  6:53 UTC (permalink / raw)
  To: buildroot

Using severals post build scripts is usefull to share
script between severals boards/projects.

Signed-off-by: Philippe Reynes <philippe.reynes@sagemcom.com>
---
 Makefile                 |    5 +++--
 target/generic/Config.in |   11 ++++++-----
 2 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/Makefile b/Makefile
index 0128839..f25141f 100644
--- a/Makefile
+++ b/Makefile
@@ -464,8 +464,9 @@ endif
 	) >  $(TARGET_DIR)/etc/os-release
 
 ifneq ($(BR2_ROOTFS_POST_BUILD_SCRIPT),"")
-	@$(call MESSAGE,"Executing post-build script")
-	$(BR2_ROOTFS_POST_BUILD_SCRIPT) $(TARGET_DIR)
+	@$(call MESSAGE,"Executing post-build script\(s\)")
+	@$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_BUILD_SCRIPT)), \
+		$(s) $(TARGET_DIR)$(sep))
 endif
 
 ifeq ($(BR2_ENABLE_LOCALE_PURGE),y)
diff --git a/target/generic/Config.in b/target/generic/Config.in
index b8472f4..298377c 100644
--- a/target/generic/Config.in
+++ b/target/generic/Config.in
@@ -170,15 +170,16 @@ config BR2_ROOTFS_POST_BUILD_SCRIPT
 	string "Custom script to run before creating filesystem images"
 	default ""
 	help
-	  Specify a script to be run after the build has finished and before
-	  Buildroot starts packing the files into selected filesystem images.
+	  Specify a space-separated list of scripts to be run after the build
+	  has finished and before Buildroot starts packing the files into 
+	  selected filesystem images.
 
 	  This gives users the oportunity to do board-specific cleanups,
 	  add-ons and the like, so the generated files can be used directly
 	  without further processing.
 
-	  The script is called with the target directory name as first and
-	  only argument. Make sure the exit code of that script is 0,
-	  otherwise make will stop after calling it.
+	  These scripts are called with the target directory name as first and
+	  only argument. Make sure the exit code of those scripts are 0,
+	  otherwise make will stop after calling them.
 
 endmenu
-- 
1.7.1


#
" Ce courriel et les documents qui lui sont joints peuvent contenir des
informations confidentielles ou ayant un caract?re priv?. S'ils ne vous sont
pas destin?s, nous vous signalons qu'il est strictement interdit de les
divulguer, de les reproduire ou d'en utiliser de quelque mani?re que ce
soit le contenu. Si ce message vous a ?t? transmis par erreur, merci d'en
informer l'exp?diteur et de supprimer imm?diatement de votre syst?me
informatique ce courriel ainsi que tous les documents qui y sont attach?s."


                               ******

" This e-mail and any attached documents may contain confidential or
proprietary information. If you are not the intended recipient, you are
notified that any dissemination, copying of this e-mail and any attachments
thereto or use of their contents by any means whatsoever is strictly
prohibited. If you have received this e-mail in error, please advise the
sender immediately and delete this e-mail and all attached documents
from your computer system."
#

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
  2012-10-29  6:53 Philippe Reynes
@ 2012-10-29  7:34 ` Samuel Martin
  2012-10-29 11:44 ` Luca Ceresoli
  2012-10-30 22:50 ` Arnout Vandecappelle
  2 siblings, 0 replies; 9+ messages in thread
From: Samuel Martin @ 2012-10-29  7:34 UTC (permalink / raw)
  To: buildroot

Hi Philippe,

2012/10/29 Philippe Reynes <philippe.reynes@sagemcom.com>:
> Using severals post build scripts is usefull to share
> script between severals boards/projects.
>
> Signed-off-by: Philippe Reynes <philippe.reynes@sagemcom.com>
Acked-by: Samuel Martin <s.martin49@gmail.com>

BTW, it would be great if you could update the doc too
(docs/manual/customize-rootfs.txt), here or in another patch.


Regards,

-- 
Sam

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
  2012-10-29  6:53 Philippe Reynes
  2012-10-29  7:34 ` Samuel Martin
@ 2012-10-29 11:44 ` Luca Ceresoli
  2012-10-30 22:50 ` Arnout Vandecappelle
  2 siblings, 0 replies; 9+ messages in thread
From: Luca Ceresoli @ 2012-10-29 11:44 UTC (permalink / raw)
  To: buildroot

Philippe Reynes wrote:
> Using severals post build scripts is usefull to share
> script between severals boards/projects.
>
> Signed-off-by: Philippe Reynes <philippe.reynes@sagemcom.com>

Acked-by: Luca Ceresoli <luca@lucaceresoli.net>

But, as Samuel suggested, you should update the manual as well.

Luca

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
  2012-10-29  6:53 Philippe Reynes
  2012-10-29  7:34 ` Samuel Martin
  2012-10-29 11:44 ` Luca Ceresoli
@ 2012-10-30 22:50 ` Arnout Vandecappelle
  2012-11-06  6:38   ` Philippe REYNES
  2 siblings, 1 reply; 9+ messages in thread
From: Arnout Vandecappelle @ 2012-10-30 22:50 UTC (permalink / raw)
  To: buildroot

On 10/29/12 07:53, Philippe Reynes wrote:
> +	@$(call MESSAGE,"Executing post-build script\(s\)")

  Aren't these backslashes redundant?

  Regards,
  Arnout
-- 
Arnout Vandecappelle                               arnout at mind be
Senior Embedded Software Architect                 +32-16-286540
Essensium/Mind                                     http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium                BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
  2012-10-30 22:50 ` Arnout Vandecappelle
@ 2012-11-06  6:38   ` Philippe REYNES
  2012-11-06 19:36     ` Arnout Vandecappelle
  0 siblings, 1 reply; 9+ messages in thread
From: Philippe REYNES @ 2012-11-06  6:38 UTC (permalink / raw)
  To: buildroot

Hi,

I've tried to remove this backslashes, and I've got an error when building:


/bin/sh: -c: line 0: syntax error near unexpected token `('
/bin/sh: -c: line 0: `echo ">>>   "Executing post-build script(s)""'
make: *** [target-finalize] Error 1

So those backslashes are usefull.

Regards,
Philippe




                                                                           
             Arnout                                                        
             Vandecappelle                                                 
             <arnout@mind.be>                                            A 
                                       Philippe Reynes                     
             10/30/2012 23:50          <philippe.reynes@sagemcom.com>      
                                                                        cc 
                                       buildroot at busybox.net               
                                                                     Objet 
                                       Re: [Buildroot] [PATCH] [v3] Allow  
                                       to run severals post build scripts  
                                       instead of only one                 
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           




On 10/29/12 07:53, Philippe Reynes wrote:
> +          @$(call MESSAGE,"Executing post-build script\(s\)")

  Aren't these backslashes redundant?

  Regards,
  Arnout
--
Arnout Vandecappelle                               arnout at mind be
Senior Embedded Software Architect                 +32-16-286540
Essensium/Mind                                     http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium                BE 872 984 063 RPR
Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F



#
" Ce courriel et les documents qui lui sont joints peuvent contenir des
informations confidentielles ou ayant un caract?re priv?. S'ils ne vous sont
pas destin?s, nous vous signalons qu'il est strictement interdit de les
divulguer, de les reproduire ou d'en utiliser de quelque mani?re que ce
soit le contenu. Si ce message vous a ?t? transmis par erreur, merci d'en
informer l'exp?diteur et de supprimer imm?diatement de votre syst?me
informatique ce courriel ainsi que tous les documents qui y sont attach?s."


                               ******

" This e-mail and any attached documents may contain confidential or
proprietary information. If you are not the intended recipient, you are
notified that any dissemination, copying of this e-mail and any attachments
thereto or use of their contents by any means whatsoever is strictly
prohibited. If you have received this e-mail in error, please advise the
sender immediately and delete this e-mail and all attached documents
from your computer system."
#

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

* [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one
  2012-11-06  6:38   ` Philippe REYNES
@ 2012-11-06 19:36     ` Arnout Vandecappelle
  0 siblings, 0 replies; 9+ messages in thread
From: Arnout Vandecappelle @ 2012-11-06 19:36 UTC (permalink / raw)
  To: buildroot

On 11/06/12 07:38, Philippe REYNES wrote:
> I've tried to remove this backslashes, and I've got an error when building:
>
>
> /bin/sh: -c: line 0: syntax error near unexpected token `('
> /bin/sh: -c: line 0: `echo ">>>    "Executing post-build script(s)""'
> make: *** [target-finalize] Error 1
>
> So those backslashes are usefull.

  Oh I see - it's because the quotes shouldn't be there...  But since we have
quotes in all MESSAGE calls at the moment, leave it as it is.

  Regards,
  Arnout

-- 
Arnout Vandecappelle                               arnout at mind be
Senior Embedded Software Architect                 +32-16-286540
Essensium/Mind                                     http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium                BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F

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

end of thread, other threads:[~2012-11-06 19:36 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-09 12:40 [Buildroot] [PATCH] [v3] Allow to run severals post build scripts instead of only one Philippe Reynes
2012-07-14 21:47 ` Arnout Vandecappelle
2012-07-16  6:09   ` Philippe REYNES
  -- strict thread matches above, loose matches on Subject: below --
2012-10-29  6:53 Philippe Reynes
2012-10-29  7:34 ` Samuel Martin
2012-10-29 11:44 ` Luca Ceresoli
2012-10-30 22:50 ` Arnout Vandecappelle
2012-11-06  6:38   ` Philippe REYNES
2012-11-06 19:36     ` Arnout Vandecappelle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox