All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
@ 2015-06-15 19:40 Peter Robinson
  2015-06-15 19:40 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c due to a with with the following error: Peter Robinson
  2015-06-16 18:24 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Simon Glass
  0 siblings, 2 replies; 9+ messages in thread
From: Peter Robinson @ 2015-06-15 19:40 UTC (permalink / raw)
  To: u-boot

In our Fedora builds we get the below errors if we build the following using 
a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
the build for rc2.

make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/

gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
In file included from ../include/configs/sandbox.h:130:0,
                 from include/config.h:5,
                 from ../tools/env/fw_env.h:11,
                 from ../tools/env/fw_env.c:34:
../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
  CONFIG_EXTRA_ENV_SETTINGS
  ^
scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
make[2]: *** [tools/env/fw_env.o] Error 1

Regards,
Peter

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c due to a with with the following error:
  2015-06-15 19:40 [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Peter Robinson
@ 2015-06-15 19:40 ` Peter Robinson
  2015-06-16 18:24 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Simon Glass
  1 sibling, 0 replies; 9+ messages in thread
From: Peter Robinson @ 2015-06-15 19:40 UTC (permalink / raw)
  To: u-boot

error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
  CONFIG_EXTRA_ENV_SETTINGS

A check to see if it's defined fixes this issue.

Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
---
 include/configs/sandbox.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/include/configs/sandbox.h b/include/configs/sandbox.h
index 3caa83c..f72675b 100644
--- a/include/configs/sandbox.h
+++ b/include/configs/sandbox.h
@@ -6,6 +6,10 @@
 #ifndef __CONFIG_H
 #define __CONFIG_H
 
+#ifndef CONFIG_SANDBOX
+#define CONFIG_SANDBOX
+#endif
+
 #ifdef FTRACE
 #define CONFIG_TRACE
 #define CONFIG_CMD_TRACE
-- 
2.4.3

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
  2015-06-15 19:40 [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Peter Robinson
  2015-06-15 19:40 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c due to a with with the following error: Peter Robinson
@ 2015-06-16 18:24 ` Simon Glass
  2015-06-16 20:04   ` Tom Rini
  2015-06-17 11:29   ` Masahiro Yamada
  1 sibling, 2 replies; 9+ messages in thread
From: Simon Glass @ 2015-06-16 18:24 UTC (permalink / raw)
  To: u-boot

Hi Peter,

On 15 June 2015 at 13:40, Peter Robinson <pbrobinson@gmail.com> wrote:
> In our Fedora builds we get the below errors if we build the following using
> a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
> the build for rc2.
>
> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/
>
> gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
> In file included from ../include/configs/sandbox.h:130:0,
>                  from include/config.h:5,
>                  from ../tools/env/fw_env.h:11,
>                  from ../tools/env/fw_env.c:34:
> ../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
>   CONFIG_EXTRA_ENV_SETTINGS
>   ^
> scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
> make[2]: *** [tools/env/fw_env.o] Error 1

Thanks for the report. I can't seem to repeat this. The build
completes OK for me.

CONFIG_SANDBOX is defined in arch/Kconfig. It ends up in your build
directory in these files.

b/sandbox/include/config/auto.conf:CONFIG_SANDBOX=y
b/sandbox/include/generated/autoconf.h:#define CONFIG_SANDBOX 1

autoconf.h is the one that matters. I wonder why this is not included
in your case?

I notice that fw_env.h starts like this:

/* Pull in the current config to define the default environment */
#ifndef __ASSEMBLY__
#define __ASSEMBLY__ /* get only #defines from config.h */
#include <config.h>
#undef __ASSEMBLY__
#else
#include <config.h>
#endif
#include <generated/autoconf.h>

Should the inclusion of autoconf.h go above the inclusion of config.h, perhaps?

Regards,
Simon

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
  2015-06-16 18:24 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Simon Glass
@ 2015-06-16 20:04   ` Tom Rini
  2015-06-16 21:07     ` Simon Glass
  2015-06-17 11:29   ` Masahiro Yamada
  1 sibling, 1 reply; 9+ messages in thread
From: Tom Rini @ 2015-06-16 20:04 UTC (permalink / raw)
  To: u-boot

On Tue, Jun 16, 2015 at 12:24:01PM -0600, Simon Glass wrote:
> Hi Peter,
> 
> On 15 June 2015 at 13:40, Peter Robinson <pbrobinson@gmail.com> wrote:
> > In our Fedora builds we get the below errors if we build the following using
> > a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
> > the build for rc2.
> >
> > make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
> > make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/
> >
> > gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
> > In file included from ../include/configs/sandbox.h:130:0,
> >                  from include/config.h:5,
> >                  from ../tools/env/fw_env.h:11,
> >                  from ../tools/env/fw_env.c:34:
> > ../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
> >   CONFIG_EXTRA_ENV_SETTINGS
> >   ^
> > scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
> > make[2]: *** [tools/env/fw_env.o] Error 1
> 
> Thanks for the report. I can't seem to repeat this. The build
> completes OK for me.

I see it too.  Make sure you start with an empty objdir.  'defconfig'
and 'sandbox_defconfig' both do it for me.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20150616/626ecdfe/attachment.sig>

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
  2015-06-16 20:04   ` Tom Rini
@ 2015-06-16 21:07     ` Simon Glass
  0 siblings, 0 replies; 9+ messages in thread
From: Simon Glass @ 2015-06-16 21:07 UTC (permalink / raw)
  To: u-boot

+Masahiro, who might have some clues

Hi Tom,

On 16 June 2015 at 14:04, Tom Rini <trini@konsulko.com> wrote:
> On Tue, Jun 16, 2015 at 12:24:01PM -0600, Simon Glass wrote:
>> Hi Peter,
>>
>> On 15 June 2015 at 13:40, Peter Robinson <pbrobinson@gmail.com> wrote:
>> > In our Fedora builds we get the below errors if we build the following using
>> > a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
>> > the build for rc2.
>> >
>> > make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
>> > make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/
>> >
>> > gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
>> > In file included from ../include/configs/sandbox.h:130:0,
>> >                  from include/config.h:5,
>> >                  from ../tools/env/fw_env.h:11,
>> >                  from ../tools/env/fw_env.c:34:
>> > ../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
>> >   CONFIG_EXTRA_ENV_SETTINGS
>> >   ^
>> > scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
>> > make[2]: *** [tools/env/fw_env.o] Error 1
>>
>> Thanks for the report. I can't seem to repeat this. The build
>> completes OK for me.
>
> I see it too.  Make sure you start with an empty objdir.  'defconfig'
> and 'sandbox_defconfig' both do it for me.

OK, I see. The oldsilentconfig seem to do something odd. Without that
it works for me. Why is it needed?

(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u> !rm
rm -r b/sandbox
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u>
make O=b/sandbox defconfig
make[1]: Entering directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
  HOSTCC  scripts/basic/fixdep
  GEN     ./Makefile
  HOSTCC  scripts/kconfig/conf.o
  SHIPPED scripts/kconfig/zconf.tab.c
  SHIPPED scripts/kconfig/zconf.lex.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/conf
*** Default configuration is based on 'sandbox_defconfig'
#
# configuration written to .config
#
make[1]: Leaving directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u>
make O=b/sandbox tools-all -s
/usr/local/google/c/cosarm/src/third_party/u-boot/files/tools/easylogo/easylogo.c:
In function ?image_load_tga?:
/usr/local/google/c/cosarm/src/third_party/u-boot/files/tools/easylogo/easylogo.c:160:8:
warning: ignoring return value of ?fread?, declared with attribute
warn_unused_result [-Wunused-result]
  fread (&header, sizeof (header), 1, file);
        ^
/usr/local/google/c/cosarm/src/third_party/u-boot/files/tools/easylogo/easylogo.c:196:8:
warning: ignoring return value of ?fread?, declared with attribute
warn_unused_result [-Wunused-result]
  fread (image->data, image->size, 1, file);
        ^
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u> !rm
rm -r b/sandbox
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u>
make O=b/sandbox defconfig
make[1]: Entering directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
  HOSTCC  scripts/basic/fixdep
  GEN     ./Makefile
  HOSTCC  scripts/kconfig/conf.o
  SHIPPED scripts/kconfig/zconf.tab.c
  SHIPPED scripts/kconfig/zconf.lex.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/conf
*** Default configuration is based on 'sandbox_defconfig'
#
# configuration written to .config
#
make[1]: Leaving directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u>
make O=b/sandbox silentoldconfig
make[1]: Entering directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
  GEN     ./Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
make[1]: Leaving directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u>
make O=b/sandbox tools-all -s
In file included from
/usr/local/google/c/cosarm/src/third_party/u-boot/files/tools/env/fw_env.c:34:0:
/usr/local/google/c/cosarm/src/third_party/u-boot/files/tools/env/fw_env.h:11:20:
fatal error: config.h: No such file or directory
 #include <config.h>
                    ^
compilation terminated.
make[2]: *** [tools/env/fw_env.o] Error 1
make[1]: *** [env] Error 2
make: *** [sub-make] Error 2


So it seems to work fine without silentoldconfig. A normal 'defconfig'
creates these files:

(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u> ls
-l `find b/sandbox/ -type f`
-rw-r----- 1 sjg eng   5666 Jun 16 15:02 b/sandbox/.config
-rw-r----- 1 sjg eng    674 Jun 16 15:02 b/sandbox/Makefile
-rwxr-x--- 1 sjg eng  14005 Jun 16 15:02 b/sandbox/scripts/basic/fixdep
-rw-r----- 1 sjg eng   4293 Jun 16 15:02 b/sandbox/scripts/basic/.fixdep.cmd
-rwxr-x--- 1 sjg eng 115167 Jun 16 15:02 b/sandbox/scripts/kconfig/conf
-rw-r----- 1 sjg eng    109 Jun 16 15:02 b/sandbox/scripts/kconfig/.conf.cmd
-rw-r----- 1 sjg eng  22712 Jun 16 15:02 b/sandbox/scripts/kconfig/conf.o
-rw-r----- 1 sjg eng   3873 Jun 16 15:02 b/sandbox/scripts/kconfig/.conf.o.cmd
-rw-r----- 1 sjg eng  12255 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.hash.c
-rw-r----- 1 sjg eng  58266 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.lex.c
-rw-r----- 1 sjg eng  75191 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.tab.c
-rw-r----- 1 sjg eng 155336 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.tab.o
-rw-r----- 1 sjg eng   5213 Jun 16 15:02
b/sandbox/scripts/kconfig/.zconf.tab.o.cmd
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u>

But with silentoldconfig we get a lot more:

make O=b/sandbox silentoldconfig
make[1]: Entering directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
  GEN     ./Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
make[1]: Leaving directory
`/usr/local/google/c/cosarm/src/third_party/u-boot/files/b/sandbox'
(try-peter=0155f0: -- b/ index.html index.html.1 sandbox/ test/) u> ls
-l `find b/sandbox/ -type f`
-rw-r----- 1 sjg eng   5666 Jun 16 15:02 b/sandbox/.config
-rw-r----- 1 sjg eng   1960 Jun 16 15:02 b/sandbox/include/config/auto.conf
-rw-r----- 1 sjg eng  18928 Jun 16 15:02 b/sandbox/include/config/auto.conf.cmd
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/bootstage.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/bootstage/report.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/bootstage/stash/addr.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/bootstage/stash/size.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/bootstage/user/count.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/cc/optimize/for/size.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/bootm.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/crc32.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/cros/ec.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/dm.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/cmd/exportenv.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/go.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/cmd/importenv.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/net.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/pmic.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/cmd/regulator.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cmd/sound.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cros/ec.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/cros/ec/keyb.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/cros/ec/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/default/device/tree.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/dm/device/remove.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/eth.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/gpio.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/i2c.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/pci.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/pmic.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/dm/pmic/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/regulator.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/dm/regulator/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/rtc.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/seq/alias.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/serial.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/spi/flash.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/spi.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/stdio.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/usb.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/dm/warn.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/errno/str.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/eth/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/eth/sandbox/raw.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/expert.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/fit.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/fit/signature.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/fit/verbose.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/have/generic/board.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/localversion/auto.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/localversion.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/netdevices.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/net.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/of/control.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/of/hostfile.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/pci.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/pci/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/regex.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/rsa.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/rsa/software/exp.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sandbox/gpio/count.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sandbox/gpio.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sandbox/serial.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sandbox/spi.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sound.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sound/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/spi/flash/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/support/of/control.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sys/arch.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sys/board.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sys/config/name.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sys/extra/options.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sys/generic/board.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sys/hz.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sys/i2c/sandbox.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sys/malloc/clear/on/init.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/sys/malloc/f.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sys/malloc/f/len.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/sys/vsnprintf.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/tpm/tis/sandbox.h
-rw-r----- 1 sjg eng     84 Jun 16 15:02 b/sandbox/include/config/tristate.conf
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/unit/test.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02
b/sandbox/include/config/usb/arch/has/hcd.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/usb/emul.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/usb.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/usb/storage.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/ut/dm.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/ut/env.h
-rw-r----- 1 sjg eng      0 Jun 16 15:02 b/sandbox/include/config/ut/time.h
-rw-r----- 1 sjg eng   2673 Jun 16 15:02 b/sandbox/include/generated/autoconf.h
-rw-r----- 1 sjg eng    674 Jun 16 15:02 b/sandbox/Makefile
-rwxr-x--- 1 sjg eng  14005 Jun 16 15:02 b/sandbox/scripts/basic/fixdep
-rw-r----- 1 sjg eng   4293 Jun 16 15:02 b/sandbox/scripts/basic/.fixdep.cmd
-rwxr-x--- 1 sjg eng 115167 Jun 16 15:02 b/sandbox/scripts/kconfig/conf
-rw-r----- 1 sjg eng    109 Jun 16 15:02 b/sandbox/scripts/kconfig/.conf.cmd
-rw-r----- 1 sjg eng  22712 Jun 16 15:02 b/sandbox/scripts/kconfig/conf.o
-rw-r----- 1 sjg eng   3873 Jun 16 15:02 b/sandbox/scripts/kconfig/.conf.o.cmd
-rw-r----- 1 sjg eng  12255 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.hash.c
-rw-r----- 1 sjg eng  58266 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.lex.c
-rw-r----- 1 sjg eng  75191 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.tab.c
-rw-r----- 1 sjg eng 155336 Jun 16 15:02 b/sandbox/scripts/kconfig/zconf.tab.o
-rw-r----- 1 sjg eng   5213 Jun 16 15:02
b/sandbox/scripts/kconfig/.zconf.tab.o.cmd

Regards,
Simon

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
  2015-06-16 18:24 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Simon Glass
  2015-06-16 20:04   ` Tom Rini
@ 2015-06-17 11:29   ` Masahiro Yamada
  2015-06-17 15:06     ` Simon Glass
  1 sibling, 1 reply; 9+ messages in thread
From: Masahiro Yamada @ 2015-06-17 11:29 UTC (permalink / raw)
  To: u-boot

Hi.


2015-06-17 3:24 GMT+09:00 Simon Glass <sjg@chromium.org>:
> Hi Peter,
>
> On 15 June 2015 at 13:40, Peter Robinson <pbrobinson@gmail.com> wrote:
>> In our Fedora builds we get the below errors if we build the following using
>> a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
>> the build for rc2.
>>
>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/
>>
>> gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
>> In file included from ../include/configs/sandbox.h:130:0,
>>                  from include/config.h:5,
>>                  from ../tools/env/fw_env.h:11,
>>                  from ../tools/env/fw_env.c:34:
>> ../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
>>   CONFIG_EXTRA_ENV_SETTINGS
>>   ^
>> scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
>> make[2]: *** [tools/env/fw_env.o] Error 1
>
> Thanks for the report. I can't seem to repeat this. The build
> completes OK for me.
>
> CONFIG_SANDBOX is defined in arch/Kconfig. It ends up in your build
> directory in these files.
>
> b/sandbox/include/config/auto.conf:CONFIG_SANDBOX=y
> b/sandbox/include/generated/autoconf.h:#define CONFIG_SANDBOX 1
>
> autoconf.h is the one that matters. I wonder why this is not included
> in your case?
>
> I notice that fw_env.h starts like this:
>
> /* Pull in the current config to define the default environment */
> #ifndef __ASSEMBLY__
> #define __ASSEMBLY__ /* get only #defines from config.h */
> #include <config.h>
> #undef __ASSEMBLY__
> #else
> #include <config.h>
> #endif
> #include <generated/autoconf.h>
>
> Should the inclusion of autoconf.h go above the inclusion of config.h, perhaps?


Right.

autoconf.h should be included earlier than any other headers.
Besides, linux/kconfig.h is preferred to generated/autoconf.h


I posted a patch for this problem last year.  See
http://patchwork.ozlabs.org/patch/417192/

I do not know why it was dismissed long.


And then, another patch was posted and picked up.

http://patchwork.ozlabs.org/patch/461411/

But, it was not good...



-- 
Best Regards
Masahiro Yamada

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
  2015-06-17 11:29   ` Masahiro Yamada
@ 2015-06-17 15:06     ` Simon Glass
  2015-06-17 15:26       ` Peter Robinson
  2015-06-17 16:00       ` Peter Robinson
  0 siblings, 2 replies; 9+ messages in thread
From: Simon Glass @ 2015-06-17 15:06 UTC (permalink / raw)
  To: u-boot

Hi Peter,

On 17 June 2015 at 05:29, Masahiro Yamada <yamada.masahiro@socionext.com> wrote:
> Hi.
>
>
> 2015-06-17 3:24 GMT+09:00 Simon Glass <sjg@chromium.org>:
>> Hi Peter,
>>
>> On 15 June 2015 at 13:40, Peter Robinson <pbrobinson@gmail.com> wrote:
>>> In our Fedora builds we get the below errors if we build the following using
>>> a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
>>> the build for rc2.
>>>
>>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
>>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/
>>>
>>> gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
>>> In file included from ../include/configs/sandbox.h:130:0,
>>>                  from include/config.h:5,
>>>                  from ../tools/env/fw_env.h:11,
>>>                  from ../tools/env/fw_env.c:34:
>>> ../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
>>>   CONFIG_EXTRA_ENV_SETTINGS
>>>   ^
>>> scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
>>> make[2]: *** [tools/env/fw_env.o] Error 1
>>
>> Thanks for the report. I can't seem to repeat this. The build
>> completes OK for me.
>>
>> CONFIG_SANDBOX is defined in arch/Kconfig. It ends up in your build
>> directory in these files.
>>
>> b/sandbox/include/config/auto.conf:CONFIG_SANDBOX=y
>> b/sandbox/include/generated/autoconf.h:#define CONFIG_SANDBOX 1
>>
>> autoconf.h is the one that matters. I wonder why this is not included
>> in your case?
>>
>> I notice that fw_env.h starts like this:
>>
>> /* Pull in the current config to define the default environment */
>> #ifndef __ASSEMBLY__
>> #define __ASSEMBLY__ /* get only #defines from config.h */
>> #include <config.h>
>> #undef __ASSEMBLY__
>> #else
>> #include <config.h>
>> #endif
>> #include <generated/autoconf.h>
>>
>> Should the inclusion of autoconf.h go above the inclusion of config.h, perhaps?
>
>
> Right.
>
> autoconf.h should be included earlier than any other headers.
> Besides, linux/kconfig.h is preferred to generated/autoconf.h
>
>
> I posted a patch for this problem last year.  See
> http://patchwork.ozlabs.org/patch/417192/
>
> I do not know why it was dismissed long.
>
>
> And then, another patch was posted and picked up.
>
> http://patchwork.ozlabs.org/patch/461411/
>
> But, it was not good...

With Masahiro's comments are you able to update your patch?

Regards,
Simon

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
  2015-06-17 15:06     ` Simon Glass
@ 2015-06-17 15:26       ` Peter Robinson
  2015-06-17 16:00       ` Peter Robinson
  1 sibling, 0 replies; 9+ messages in thread
From: Peter Robinson @ 2015-06-17 15:26 UTC (permalink / raw)
  To: u-boot

Hi Simon,

> On 17 June 2015 at 05:29, Masahiro Yamada <yamada.masahiro@socionext.com> wrote:
>> Hi.
>>
>>
>> 2015-06-17 3:24 GMT+09:00 Simon Glass <sjg@chromium.org>:
>>> Hi Peter,
>>>
>>> On 15 June 2015 at 13:40, Peter Robinson <pbrobinson@gmail.com> wrote:
>>>> In our Fedora builds we get the below errors if we build the following using
>>>> a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
>>>> the build for rc2.
>>>>
>>>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
>>>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/
>>>>
>>>> gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
>>>> In file included from ../include/configs/sandbox.h:130:0,
>>>>                  from include/config.h:5,
>>>>                  from ../tools/env/fw_env.h:11,
>>>>                  from ../tools/env/fw_env.c:34:
>>>> ../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
>>>>   CONFIG_EXTRA_ENV_SETTINGS
>>>>   ^
>>>> scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
>>>> make[2]: *** [tools/env/fw_env.o] Error 1
>>>
>>> Thanks for the report. I can't seem to repeat this. The build
>>> completes OK for me.
>>>
>>> CONFIG_SANDBOX is defined in arch/Kconfig. It ends up in your build
>>> directory in these files.
>>>
>>> b/sandbox/include/config/auto.conf:CONFIG_SANDBOX=y
>>> b/sandbox/include/generated/autoconf.h:#define CONFIG_SANDBOX 1
>>>
>>> autoconf.h is the one that matters. I wonder why this is not included
>>> in your case?
>>>
>>> I notice that fw_env.h starts like this:
>>>
>>> /* Pull in the current config to define the default environment */
>>> #ifndef __ASSEMBLY__
>>> #define __ASSEMBLY__ /* get only #defines from config.h */
>>> #include <config.h>
>>> #undef __ASSEMBLY__
>>> #else
>>> #include <config.h>
>>> #endif
>>> #include <generated/autoconf.h>
>>>
>>> Should the inclusion of autoconf.h go above the inclusion of config.h, perhaps?
>>
>>
>> Right.
>>
>> autoconf.h should be included earlier than any other headers.
>> Besides, linux/kconfig.h is preferred to generated/autoconf.h
>>
>>
>> I posted a patch for this problem last year.  See
>> http://patchwork.ozlabs.org/patch/417192/
>>
>> I do not know why it was dismissed long.
>>
>>
>> And then, another patch was posted and picked up.
>>
>> http://patchwork.ozlabs.org/patch/461411/
>>
>> But, it was not good...
>
> With Masahiro's comments are you able to update your patch?

Yes, based on the above comments I'll send a new patch through
shortly, just testing it builds etc.

Peter

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

* [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c
  2015-06-17 15:06     ` Simon Glass
  2015-06-17 15:26       ` Peter Robinson
@ 2015-06-17 16:00       ` Peter Robinson
  1 sibling, 0 replies; 9+ messages in thread
From: Peter Robinson @ 2015-06-17 16:00 UTC (permalink / raw)
  To: u-boot

Hi Simon,

>>> On 15 June 2015 at 13:40, Peter Robinson <pbrobinson@gmail.com> wrote:
>>>> In our Fedora builds we get the below errors if we build the following using
>>>> a vanilla u-boot 2015.07rc2. I'm not sure if it's the best fix but it fixes
>>>> the build for rc2.
>>>>
>>>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" defconfig V=1 O=builds/
>>>> make HOSTCC="gcc $RPM_OPT_FLAGS" CROSS_COMPILE="" tools-all V=1 O=builds/
>>>>
>>>> gcc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -Wp,-MD,tools/env/.fw_env.o.d -Itools/env -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -idirafterinclude -idirafter../include -idirafter../arch/sandbox/include -idirafter ../tools/env -DUSE_HOSTCC -DTEXT_BASE= -c -o tools/env/fw_env.o ../tools/env/fw_env.c
>>>> In file included from ../include/configs/sandbox.h:130:0,
>>>>                  from include/config.h:5,
>>>>                  from ../tools/env/fw_env.h:11,
>>>>                  from ../tools/env/fw_env.c:34:
>>>> ../include/env_default.h:104:2: error: expected '}' before 'BOOT_TARGET_DEVICES_references_HOST_without_CONFIG_SANDBOX'
>>>>   CONFIG_EXTRA_ENV_SETTINGS
>>>>   ^
>>>> scripts/Makefile.host:108: recipe for target 'tools/env/fw_env.o' failed
>>>> make[2]: *** [tools/env/fw_env.o] Error 1
>>>
>>> Thanks for the report. I can't seem to repeat this. The build
>>> completes OK for me.
>>>
>>> CONFIG_SANDBOX is defined in arch/Kconfig. It ends up in your build
>>> directory in these files.
>>>
>>> b/sandbox/include/config/auto.conf:CONFIG_SANDBOX=y
>>> b/sandbox/include/generated/autoconf.h:#define CONFIG_SANDBOX 1
>>>
>>> autoconf.h is the one that matters. I wonder why this is not included
>>> in your case?
>>>
>>> I notice that fw_env.h starts like this:
>>>
>>> /* Pull in the current config to define the default environment */
>>> #ifndef __ASSEMBLY__
>>> #define __ASSEMBLY__ /* get only #defines from config.h */
>>> #include <config.h>
>>> #undef __ASSEMBLY__
>>> #else
>>> #include <config.h>
>>> #endif
>>> #include <generated/autoconf.h>
>>>
>>> Should the inclusion of autoconf.h go above the inclusion of config.h, perhaps?
>>
>>
>> Right.
>>
>> autoconf.h should be included earlier than any other headers.
>> Besides, linux/kconfig.h is preferred to generated/autoconf.h
>>
>>
>> I posted a patch for this problem last year.  See
>> http://patchwork.ozlabs.org/patch/417192/
>>
>> I do not know why it was dismissed long.
>>
>>
>> And then, another patch was posted and picked up.
>>
>> http://patchwork.ozlabs.org/patch/461411/
>>
>> But, it was not good...
>
> With Masahiro's comments are you able to update your patch?

Patch updated [1] and posted.

Peter

[1] http://lists.denx.de/pipermail/u-boot/2015-June/216866.html

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

end of thread, other threads:[~2015-06-17 16:00 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-15 19:40 [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Peter Robinson
2015-06-15 19:40 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c due to a with with the following error: Peter Robinson
2015-06-16 18:24 ` [U-Boot] [PATCH] If CONFIG_SANDBOX isn't defined the build fails in fw_env.c Simon Glass
2015-06-16 20:04   ` Tom Rini
2015-06-16 21:07     ` Simon Glass
2015-06-17 11:29   ` Masahiro Yamada
2015-06-17 15:06     ` Simon Glass
2015-06-17 15:26       ` Peter Robinson
2015-06-17 16:00       ` Peter Robinson

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.