public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot-Users] latest (1.3.1) doesn't compile: files missing
@ 2008-01-19  1:51 M. Warner Losh
  2008-01-20  1:07 ` Wolfgang Denk
  0 siblings, 1 reply; 5+ messages in thread
From: M. Warner Losh @ 2008-01-19  1:51 UTC (permalink / raw)
  To: u-boot

There are two missing files from the distribution that prevents uboot
from compiling.

stddef.h is included by a few different things, but can be a blank
file.

stdarg.h is included by a couple of things, and can be a trivial
implementation (attached).

These are both host includes, and likely shouldn't be included at all
in the boot loader code proper.

This is when building the MPC8548CDS config.

I also get link errors on this out of the box:

                cd /pe/imp/u-boot-1.3.1 && powerpc-freebsd-ld -Bstatic -T /pe/imp/u-boot-1.3.1/board/cds/mpc8548cds/u-boot.lds -Ttext 0xfff80000  -n $UNDEF_SYM cpu/mpc85xx/start.o cpu/mpc85xx/resetvec.o \
                        --start-group lib_generic/libgeneric.a board/cds/mpc8548cds/libmpc8548cds.a cpu/mpc85xx/libmpc85xx.a lib_ppc/libppc.a fs/cramfs/libcramfs.a fs/fat/libfat.a fs/fdos/libfdos.a fs/jffs2/libjffs2.a fs/reiserfs/libreiserfs.a fs/ext2/libext2fs.a net/libnet.a disk/libdisk.a drivers/bios_emulator/libatibiosemu.a drivers/block/libblock.a drivers/hwmon/libhwmon.a drivers/i2c/libi2c.a drivers/input/libinput.a drivers/misc/libmisc.a drivers/mtd/libmtd.a drivers/mtd/nand/libnand.a drivers/mtd/nand_legacy/libnand_legacy.a drivers/mtd/onenand/libonenand.a drivers/net/libnet.a drivers/net/sk98lin/libsk98lin.a drivers/pci/libpci.a drivers/pcmcia/libpcmcia.a drivers/qe/qe.a drivers/rtc/librtc.a drivers/serial/libserial.a drivers/usb/libusb.a drivers/video/libvideo.a post/libpost.a post/drivers/libpostdrivers.a post/lib_ppc/libpostppc.a post/lib_ppc/fpu/libpostppcfpu.a common/libcommon.a libfdt/libfdt.a --end-group -L /usr/powerpc-freebsd/usr/lib -lgcc \
                        -Map u-boot.map -o u-boot
cpu/mpc85xx/resetvec.o(.debug_info+0x14): relocation truncated to fit: R_PPC_ADDR32 .resetvec+4
common/libcommon.a(env_flash.o)(.text+0xc4): In function `saveenv':
/pe/imp/u-boot-1.3.1/common/env_flash.c:312: undefined reference to `flash_sect_protect'
common/libcommon.a(env_flash.o)(.text+0xe0):/pe/imp/u-boot-1.3.1/common/env_flash.c:316: undefined reference to `flash_sect_erase'
common/libcommon.a(env_flash.o)(.text+0x130):/pe/imp/u-boot-1.3.1/common/env_flash.c:329: undefined reference to `flash_sect_protect'

Are these to be expected with binutils 2.15 and gcc 4.2.1?

Warner

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

* [U-Boot-Users] latest (1.3.1) doesn't compile: files missing
  2008-01-19  1:51 [U-Boot-Users] latest (1.3.1) doesn't compile: files missing M. Warner Losh
@ 2008-01-20  1:07 ` Wolfgang Denk
  2008-01-20  3:48   ` M. Warner Losh
  2008-01-20  9:42   ` Wolfgang Denk
  0 siblings, 2 replies; 5+ messages in thread
From: Wolfgang Denk @ 2008-01-20  1:07 UTC (permalink / raw)
  To: u-boot

In message <20080118.185100.1159141701.imp@bsdimp.com> you wrote:
> There are two missing files from the distribution that prevents uboot
> from compiling.

What sort of toolchain are you using?

> stddef.h is included by a few different things, but can be a blank
> file.
> 
> stdarg.h is included by a couple of things, and can be a trivial
> implementation (attached).
> 
> These are both host includes, and likely shouldn't be included at all
> in the boot loader code proper.
> 
> This is when building the MPC8548CDS config.
> 
> I also get link errors on this out of the box:

It seems you have a toolchain issue. This is not a problem with U-Boot
code.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
There is an order of things in this universe.
	-- Apollo, "Who Mourns for Adonais?" stardate 3468.1

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

* [U-Boot-Users] latest (1.3.1) doesn't compile: files missing
  2008-01-20  1:07 ` Wolfgang Denk
@ 2008-01-20  3:48   ` M. Warner Losh
  2008-01-20  9:49     ` Wolfgang Denk
  2008-01-20  9:42   ` Wolfgang Denk
  1 sibling, 1 reply; 5+ messages in thread
From: M. Warner Losh @ 2008-01-20  3:48 UTC (permalink / raw)
  To: u-boot

In message: <20080120010721.EA1B424764@gemini.denx.de>
            Wolfgang Denk <wd@denx.de> writes:
: In message <20080118.185100.1159141701.imp@bsdimp.com> you wrote:
: > There are two missing files from the distribution that prevents uboot
: > from compiling.
: 
: What sort of toolchain are you using?

binutils 2.15 and gcc 4.2.1.  The problem turned out to be the
combination: gcc 4.2.1 produced code that binutils couldn't assemble
properly.  That was what was causing the relocation error.

: > stddef.h is included by a few different things, but can be a blank
: > file.
: > 
: > stdarg.h is included by a couple of things, and can be a trivial
: > implementation (attached).
: > 
: > These are both host includes, and likely shouldn't be included at all
: > in the boot loader code proper.
: > 
: > This is when building the MPC8548CDS config.
: > 
: > I also get link errors on this out of the box:
: 
: It seems you have a toolchain issue. This is not a problem with U-Boot
: code.

The two include files aren't a toolchain issue.  They can't be because
uboot's makefile has said not to include anything from the standard
include files.  These files aren't included with u-boot.

Warner

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

* [U-Boot-Users] latest (1.3.1) doesn't compile: files missing
  2008-01-20  1:07 ` Wolfgang Denk
  2008-01-20  3:48   ` M. Warner Losh
@ 2008-01-20  9:42   ` Wolfgang Denk
  1 sibling, 0 replies; 5+ messages in thread
From: Wolfgang Denk @ 2008-01-20  9:42 UTC (permalink / raw)
  To: u-boot

I think I should be a bit more explicit:

In message <20080120010721.EA1B424764@gemini.denx.de> I wrote:
> 
> > stddef.h is included by a few different things, but can be a blank
> > file.

U-Boot already has a stddef.h (include/linux/stddef.h) which gets used
for all U-Boot related compiles.

> > stdarg.h is included by a couple of things, and can be a trivial
> > implementation (attached).

stdarg.h is a compiler provided file and thus has to be  provided  by
your toolchain.

As mentioned before, I don't think that any changes to U-Boot code are
necessary.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Too much of anything, even love, isn't necessarily a good thing.
	-- Kirk, "The Trouble with Tribbles", stardate 4525.6

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

* [U-Boot-Users] latest (1.3.1) doesn't compile: files missing
  2008-01-20  3:48   ` M. Warner Losh
@ 2008-01-20  9:49     ` Wolfgang Denk
  0 siblings, 0 replies; 5+ messages in thread
From: Wolfgang Denk @ 2008-01-20  9:49 UTC (permalink / raw)
  To: u-boot

In message <20080119.204823.387223958.imp@bsdimp.com> you wrote:
>
> The two include files aren't a toolchain issue.  They can't be because

They are - see previous message.

> uboot's makefile has said not to include anything from the standard
> include files.  These files aren't included with u-boot.

stddef.h is included (as include/linux/stddef.h); only host files in
tools/ reference host include files.

And stdarg.h has to be provided by your compiler.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Conceptual integrity in turn dictates that the  design  must  proceed
from  one  mind,  or  from  a  very small number of agreeing resonant
minds.               - Frederick Brooks Jr., "The Mythical Man Month"

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

end of thread, other threads:[~2008-01-20  9:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-19  1:51 [U-Boot-Users] latest (1.3.1) doesn't compile: files missing M. Warner Losh
2008-01-20  1:07 ` Wolfgang Denk
2008-01-20  3:48   ` M. Warner Losh
2008-01-20  9:49     ` Wolfgang Denk
2008-01-20  9:42   ` Wolfgang Denk

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