Pull request for branch yem/misc-updates
From: "Yann E. MORIN" <[email protected]>
Hello All!
Here are two misc updates:
- bump the RPi firmware for some fixes
- alternate debug mode for the toolchain wrapper
Regards,
Yann E. MORIN.
The following changes since commit 1fe1165e619fdaa2fedc027137974797796f80aa:
civetweb: new package (2013-09-20 16:14:10 +0200)
are available in the git repository at:
git://gitorious.org/buildroot/buildroot.git yem/misc-updates
for you to fetch changes up to 4092a345daa1077982e8355fdfa22c27b7240a7f:
package/rpi-firmware: bump version (2013-09-20 19:57:56 +0200)
----------------------------------------------------------------
Yann E. MORIN (2):
toolchain/wrapper: add option to print one argument per line package/rpi-firmware: bump version
docs/manual/customize-toolchain.txt | 11 ++++++++++ package/rpi-firmware/rpi-firmware.mk | 2 +- .../toolchain-external/ext-toolchain-wrapper.c | 25 +++++++++++++++------- 3 files changed, 29 insertions(+), 9 deletions(-)
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH 1/2 toolchain/wrapper: add option to print one argument per line
From: "Yann E. MORIN" <[email protected]>
In case there are many arguments passed to the tools, the command line can get very long, and difficult to parse visually.
For example, the Linux kernel passes a lot of arguments to gcc (at least 45, which gives 53 with our hard-coded args). Looking at such a command line is daunting.
So, add the possibility to print each argument on its own line.
Also, enclose all args between single quotes, so the command line can be safely copy-pasted without special chars (spaces, $) being inrerpreted by the shell.
Add blurb about toolchain-wrapper to documentation at the same time.
--- docs/manual/customize-toolchain.txt | 11 ++++++++++ .../toolchain-external/ext-toolchain-wrapper.c | 25 +++++++++++++++------- 2 files changed, 28 insertions(+), 8 deletions(-)
docs/manual/customize-toolchain.txt +11 -0
@@ -17,6 +17,17 @@ generate it. It also requires to set the Buildroot settings according to the toolchain ones (see xref:external-toolchain-backend[]). +When using an external toolchain, Buildroot generates a wrapper program, that +passes the appropriate options (according to the configuration) to the +external toolchain programs. In case you need to debug this wrapper, you can +set the environment variable BR_DEBUG_WRAPPER to either one of: + +* +0+, empty or not set: no debug + +* +1+: trace all arguments on a single line + +* +2+: trace one argument per line + Using the internal Buildroot toolchain backend ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
toolchain/toolchain-external/ext-toolchain-wrapper.c +17 -8
@@ -74,7 +74,8 @@ int main(int argc, char **argv)char *relbasedir, *absbasedir;char *progpath = argv[0 ];char *basename; -int ret, i, count =0 ; +char *env_debug; +int ret, i, count =0 , debug;/* Calculate the relative paths */ basename =strrchr (progpath,'/' );
@@ -157,13 +158,21 @@ int main(int argc, char **argv)/* finish with NULL termination */ *cur =NULL ; -if (getenv ("BR_DEBUG_WRAPPER" )) { -fprintf (stderr,"Executing" ); - -for (i =0 ; args[i]; i++) -fprintf (stderr," %s" , args[i]); - -fprintf (stderr,"\n" ); +/* Debug the wrapper to see actual arguments passed to +* the compiler: +* unset, empty, or 0: do not trace +* set to 1 : trace all arguments on a single line +* set to 2 : trace one argument per line +*/ +if ((env_debug =getenv ("BR_DEBUG_WRAPPER" ))) { + debug =atoi (env_debug); +if (debug >0 ) { +fprintf (stderr,"Toolchain wrapper executing:" ); +for (i =0 ; args[i]; i++) +fprintf (stderr,"%s'%s'" , + (debug ==2 )?"\n " :" " , args[i]); +fprintf (stderr,"\n" ); + } }if (execv (path, args))
Signature · 1 line
1.8.1.2
PATCH 1/2 toolchain/wrapper: add option to print one argument per line
2013/9/21 Yann E. MORIN <[email protected]>
Quoted 15 lines
From: "Yann E. MORIN" <[email protected]>
In case there are many arguments passed to the tools, the command line can get very long, and difficult to parse visually.
For example, the Linux kernel passes a lot of arguments to gcc (at least 45, which gives 53 with our hard-coded args). Looking at such a command line is daunting.
So, add the possibility to print each argument on its own line.
Also, enclose all args between single quotes, so the command line can be safely copy-pasted without special chars (spaces, $) being inrerpreted by the shell.
Quoted 8 lines
Add blurb about toolchain-wrapper to documentation at the same time.
Signed-off-by "Yann E. MORIN" <[email protected]>Cc Thomas De Schampheleire <[email protected]>Acked-by Luca Ceresoli <[email protected]>Tested-by Luca Ceresoli <[email protected]>
Quoted 80 lines
--- docs/manual/customize-toolchain.txt | 11 ++++++++++ .../toolchain-external/ext-toolchain-wrapper.c | 25 +++++++++++++++------- 2 files changed, 28 insertions(+), 8 deletions(-)docs/manual/customize-toolchain.txt +0
-0@@ -17,6 +17,17 @@ generate it. It also requires to set the Buildroot settings according to the toolchainones
(see xref:external-toolchain-backend[]).+When using an external toolchain, Buildroot generates a wrapper program, that
docs/manual/customize-toolchain.txt +2
-0+passes the appropriate options (according to the configuration) to the +external toolchain programs. In case you need to debug this wrapper, youcan
docs/manual/customize-toolchain.txt +8
-0+set the environment variable BR_DEBUG_WRAPPER to either one of: + +* +0+, empty or not set: no debug + +* +1+: trace all arguments on a single line + +* +2+: trace one argument per line + Using the internal Buildroot toolchain backend ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^toolchain/toolchain-external/ext-toolchain-wrapper.c +17
-8@@ -74,7 +74,8 @@ int main(int argc, char **argv)char *relbasedir, *absbasedir;char *progpath = argv[0 ];char *basename; -int ret, i, count =0 ; +char *env_debug; +int ret, i, count =0 , debug;/* Calculate the relative paths */ basename =strrchr (progpath,'/' );@@ -157,13 +158,21 @@ int main(int argc, char **argv)/* finish with NULL termination */ *cur =NULL ; -if (getenv ("BR_DEBUG_WRAPPER" )) { -fprintf (stderr,"Executing" ); - -for (i =0 ; args[i]; i++) -fprintf (stderr," %s" , args[i]); - -fprintf (stderr,"\n" ); +/* Debug the wrapper to see actual arguments passed to +* the compiler: +* unset, empty, or 0: do not trace +* set to 1 : trace all arguments on a single line +* set to 2 : trace one argument per line +*/ +if ((env_debug =getenv ("BR_DEBUG_WRAPPER" ))) { + debug =atoi (env_debug); +if (debug >0 ) { +fprintf (stderr,"Toolchain wrapper executing:" ); +for (i =0 ; args[i]; i++) +fprintf (stderr,"%s'%s'" , + (debug ==2 )?"\n " :" " , args[i]); +fprintf (stderr,"\n" ); + } }if (
execv(path, args))
--
1.8.1.2
Quoted 5 lines
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
Regards,
Signature · 4 lines
Samuel -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20130922/d5df1064/attachment.html>
PATCH 1/2 toolchain/wrapper: add option to print one argument per line
In reply to Yann E. MORINQuoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Yann" == Yann E MORIN <[email protected]> writes:
Yann> From: "Yann E. MORIN" <[email protected]>
Yann> In case there are many arguments passed to the tools, the command line Yann> can get very long, and difficult to parse visually.
Yann> For example, the Linux kernel passes a lot of arguments to gcc (at least Yann> 45, which gives 53 with our hard-coded args). Looking at such a command Yann> line is daunting.
Yann> So, add the possibility to print each argument on its own line.
Yann> Also, enclose all args between single quotes, so the command line Yann> can be safely copy-pasted without special chars (spaces, $) being Yann> inrerpreted by the shell.
Yann> Add blurb about toolchain-wrapper to documentation at the same Yann> time.
Committed with minor code style changes, thanks.
Signature · 1 line
Bye, Peter Korsgaard
PATCH 2/2 package/rpi-firmware: bump version
In reply to Yann E. MORINFrom: "Yann E. MORIN" <[email protected]>
Fixes for USB and audio; enable video capture.
--- package/rpi-firmware/rpi-firmware.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
package/rpi-firmware/rpi-firmware.mk +1 -1
@@ -4,7 +4,7 @@ # ################################################################################ -RPI_FIRMWARE_VERSION = d4f5315 +RPI_FIRMWARE_VERSION = fadc4cb RPI_FIRMWARE_SITE = http://github.com/raspberrypi/firmware/tarball/$(RPI_FIRMWARE_VERSION) RPI_FIRMWARE_LICENSE = BSD-3c RPI_FIRMWARE_LICENSE_FILES = boot/LICENCE.broadcom
Signature · 1 line
1.8.1.2
PATCH 2/2 package/rpi-firmware: bump version
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Yann" == Yann E MORIN <[email protected]> writes:
Yann> From: "Yann E. MORIN" <[email protected]> Yann> Fixes for USB and audio; enable video capture.
Committed, thanks.
Signature · 1 line
Bye, Peter Korsgaard