When I have CONFIG_DEFAULT_ENVIRONMENT=y and try to build barebox, I see<div>HOSTCC scripts/mod/sumversion.o</div><div>then later I see it trying to build with CC and fails. </div><div><br></div><div>I don't think that its supposed to try to build sumversion.o with the cross compiler toolchain.</div>
<div><br></div><div>Jon<br><div><br></div><div><div>make -f Makefile ARCH=arm CROSS_COMPILE=/opt/crosstool-ng-1.9.0/arm-1136j-eabi/gcc-4.4.5-newlib-1.18.0-binutils-2.20.1/bin/arm-1136j-eabi- </div><div>make[1]: Entering directory `/home/ringlej/git/barebox'</div>
<div>make[2]: `include/generated/mach-types.h' is up to date.</div><div> CHK include/generated/version.h</div><div> CHK include/generated/utsrelease.h</div><div> SYMLINK include/config.h -> arch/arm/boards/isc3//config.h</div>
<div> HOSTCC scripts/mod/sumversion.o</div><div> HOSTLD scripts/mod/modpost</div><div> CC lib/ctype.o</div><div> CC lib/rbtree.o</div><div> CC lib/display_options.o</div><div> CC lib/string.o</div>
<div> CC lib/vsprintf.o</div><div> CC lib/div64.o</div><div> CC lib/misc.o</div><div> CC lib/driver.o</div><div> CC lib/bus.o</div><div> CC lib/parameter.o</div><div> CC lib/xfuncs.o</div>
<div> CC lib/getopt.o</div><div> CC lib/readkey.o</div><div> CC lib/kfifo.o</div><div> CC lib/libbb.o</div><div> CC lib/libgen.o</div><div> CC lib/stringlist.o</div><div> CC lib/recursive_action.o</div>
<div> CC lib/make_directory.o</div><div> CC lib/bzlib.o</div><div> CC lib/bzlib_crctable.o</div><div> CC lib/bzlib_decompress.o</div><div> CC lib/bzlib_huffman.o</div><div> CC lib/bzlib_randtable.o</div>
<div> CC lib/crc32.o</div><div> CC lib/readline.o</div><div> CC lib/glob.o</div><div> CC lib/notifier.o</div><div> CC lib/copy_file.o</div><div> CC lib/random.o</div><div> CC lib/show_progress.o</div>
<div> CC lib/process_escape_sequence.o</div><div> LD lib/built-in.o</div><div> CC fs/ramfs.o</div><div> CC fs/devfs.o</div><div> CC fs/fs.o</div><div> LD fs/built-in.o</div><div> CC /home/ringlej/git/barebox/fs/fs.o</div>
<div> CC /home/ringlej/git/barebox/fs/devfs.o</div><div> CC /home/ringlej/git/barebox/fs/ramfs.o</div><div> CC /home/ringlej/git/barebox/lib/rbtree.o</div><div> CC /home/ringlej/git/barebox/lib/libbb.o</div>
<div> CC /home/ringlej/git/barebox/lib/recursive_action.o</div><div> CC /home/ringlej/git/barebox/lib/libgen.o</div><div> CC /home/ringlej/git/barebox/lib/div64.o</div><div> CC /home/ringlej/git/barebox/lib/getopt.o</div>
<div> CC /home/ringlej/git/barebox/lib/notifier.o</div><div> CC /home/ringlej/git/barebox/lib/readline.o</div><div> CC /home/ringlej/git/barebox/lib/readline_simple.o</div><div> CC /home/ringlej/git/barebox/lib/bus.o</div>
<div> CC /home/ringlej/git/barebox/lib/readkey.o</div><div> CC /home/ringlej/git/barebox/lib/random.o</div><div> CC /home/ringlej/git/barebox/lib/bzlib.o</div><div> CC /home/ringlej/git/barebox/lib/kfifo.o</div>
<div> CC /home/ringlej/git/barebox/lib/stringlist.o</div><div> CC /home/ringlej/git/barebox/lib/ctype.o</div><div> CC /home/ringlej/git/barebox/lib/process_escape_sequence.o</div><div> CC /home/ringlej/git/barebox/lib/driver.o</div>
<div> CC /home/ringlej/git/barebox/lib/misc.o</div><div> CC /home/ringlej/git/barebox/lib/bzlib_crctable.o</div><div> CC /home/ringlej/git/barebox/lib/copy_file.o</div><div> CC /home/ringlej/git/barebox/lib/string.o</div>
<div> CC /home/ringlej/git/barebox/lib/bzlib_randtable.o</div><div> CC /home/ringlej/git/barebox/lib/glob.o</div><div> CC /home/ringlej/git/barebox/lib/vsprintf.o</div><div> CC /home/ringlej/git/barebox/lib/show_progress.o</div>
<div> CC /home/ringlej/git/barebox/lib/crc32.o</div><div> CC /home/ringlej/git/barebox/lib/make_directory.o</div><div> CC /home/ringlej/git/barebox/lib/bzlib_huffman.o</div><div> CC /home/ringlej/git/barebox/lib/parameter.o</div>
<div> CC /home/ringlej/git/barebox/lib/display_options.o</div><div> CC /home/ringlej/git/barebox/lib/bzlib_decompress.o</div><div> CC /home/ringlej/git/barebox/lib/xfuncs.o</div><div> CC /home/ringlej/git/barebox/scripts/mod/sumversion.o</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:1:24: error: netinet/in.h: No such file or directory</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:5:20: error: stdint.h: No such file or directory</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:7:19: error: ctype.h: No such file or directory</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:10:20: error: limits.h: No such file or directory</div><div>
In file included from /home/ringlej/git/barebox/scripts/mod/sumversion.c:11:</div><div>/home/ringlej/git/barebox/scripts/mod/modpost.h:5:23: error: sys/types.h: No such file or directory</div><div>/home/ringlej/git/barebox/scripts/mod/modpost.h:6:22: error: sys/stat.h: No such file or directory</div>
<div>/home/ringlej/git/barebox/scripts/mod/modpost.h:7:22: error: sys/mman.h: No such file or directory</div><div>/home/ringlej/git/barebox/scripts/mod/modpost.h:9:20: error: unistd.h: No such file or directory</div><div>
/home/ringlej/git/barebox/scripts/mod/modpost.h:21:1: warning: "ELF_ST_BIND" redefined</div><div>In file included from /home/ringlej/git/barebox/scripts/mod/modpost.h:10,</div><div> from /home/ringlej/git/barebox/scripts/mod/sumversion.c:11:</div>
<div>include/elf.h:119:1: warning: this is the location of the previous definition</div><div>In file included from /home/ringlej/git/barebox/scripts/mod/sumversion.c:11:</div><div>/home/ringlej/git/barebox/scripts/mod/modpost.h:22:1: warning: "ELF_ST_TYPE" redefined</div>
<div>In file included from /home/ringlej/git/barebox/scripts/mod/modpost.h:10,</div><div> from /home/ringlej/git/barebox/scripts/mod/sumversion.c:11:</div><div>include/elf.h:120:1: warning: this is the location of the previous definition</div>
<div>In file included from /home/ringlej/git/barebox/scripts/mod/sumversion.c:11:</div><div>/home/ringlej/git/barebox/scripts/mod/modpost.h:122: error: expected specifier-qualifier-list before 'Elf32_Section'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c: In function 'le32_to_cpu_array':</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:75: warning: implicit declaration of function 'ntohl'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c: In function 'cpu_to_le32_array':</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:83: warning: implicit declaration of function 'htonl'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c: In function 'parse_file':</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:273: warning: implicit declaration of function 'isspace'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c: In function 'parse_source_files':</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:303: warning: implicit declaration of function 'malloc'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:303: warning: passing argument 1 of 'do_nofail' makes pointer from integer without a cast</div><div>/home/ringlej/git/barebox/scripts/mod/modpost.h:89: note: expected 'void *' but argument is of type 'int'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:314: warning: passing argument 1 of 'do_nofail' makes pointer from integer without a cast</div><div>/home/ringlej/git/barebox/scripts/mod/modpost.h:89: note: expected 'void *' but argument is of type 'int'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:372: warning: implicit declaration of function 'free'</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c: In function 'get_src_version':</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:385: error: 'PATH_MAX' undeclared (first use in this function)</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:385: error: (Each undeclared identifier is reported only once</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:385: error: for each function it appears in.)</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:386: warning: implicit declaration of function 'getenv'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:386: warning: initialization makes pointer from integer without a cast</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:385: warning: unused variable 'filelist'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c: In function 'write_version':</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:437: warning: implicit declaration of function 'open'</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:444: warning: implicit declaration of function 'lseek'</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:444: error: 'SEEK_SET' undeclared (first use in this function)</div>
<div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:450: warning: implicit declaration of function 'write'</div><div>/home/ringlej/git/barebox/scripts/mod/sumversion.c:456: warning: implicit declaration of function 'close'</div>
<div>make[2]: *** [/home/ringlej/git/barebox/scripts/mod/sumversion.o] Error 1</div><div>make[2]: *** Waiting for unfinished jobs....</div><div>make[1]: *** [common] Error 2</div><div>make[1]: Leaving directory `/home/ringlej/git/barebox'</div>
<div>make: *** [all] Error 2</div></div><div><br></div></div>