nanogui: Thread: uClinux/Microwindows Compilation problems - Urgent... help..


[<<] [<] Page 1 of 1 [>] [>>]
Subject: uClinux/Microwindows Compilation problems - Urgent... help..
From: "Sridharan Subramanian" ####@####.####
Date: 2 Feb 2001 17:28:21 -0000
Message-Id: <3A7AEEA8.4644D26F@email.sps.mot.com>

Hi,

I have been working on porting Microwindows to uClinux. I am using 68k
architecture. The hardware is Motorola 68EZ328
dragonball.

I successfully built the uClinux kernel 2.0.38. I followed the
instructions from the home page (uclinux.org). I used the m68k-coff
tools for the kernel and m68k-pic-coff for the userland programs. When I
installed from the CD, I was able to build the kernel
well and run it on a terminal window.

Next I was looking at an appropriate GUI for the kernel. Since
microwindows was the most widely used embedded gui currently,
I tried using it. Microwindows currently does not have support for m68k
architecture with nommu. So I basically followed the
instructions on the web page and tried building it using the
m68k-pic-coff tools. Most of the programs do build fine. However,
some programs that are large complain of 'word overflow' errors. And
others that do compile fail during link due to 'relocation or
a5world full' problems. I am attaching herewith the errors I get during
compilation.

I tried my level best with the following alternatives:
1) Changed the compiler to the current m68k-pic-coff (available on the
website)
2) Patched the compiler to the 32 bit version (Erwin's patch) and used
-fPIC option.
3) Used the new crt0.o file (32 bit).
4) Removed the large programs and tried small demo programs.
5) Tried linker options including: --embedded-relocs, -Tdata=0x0
....etc.
6) Modified the memory map uClinux-pic.ld.

But nothing seems to work. I always get the problem of 'a5world full' or
'.text truncation' or '.word overflow'

I have almost given up on this.  Please do help me. Quite
frustrating.....

Also do suggest if there is an alternative GUI that I could try. Or what
if I use a different tool chain like the m68k-elf-.

Thanks,
Sri.

Errors that I get:

1) Linker errors on normal size programs:

make[1]: Entering directory
`/opt/sri/microwindows/work/microwin/src/demos'
make -C mwin;  make -C mwobjects;  make -C nanowm;  make -C nanox;  make
-C nwidget;  make -C nxkbd;  make -C
nxscribble;  make -C vnc;
make[2]: Entering directory
`/opt/sri/microwindows/work/microwin/src/demos/mwin'
m68k-pic-coff-gcc   -I.
-I/opt/sri/microwindows/work/microwin/src/include -m68000 -Wa, -m68000
-DCONFIG_DRAGONBALL -Dlinux -D__linux__ -Dunix -DEMBED -DNANOX=1 -O2
-msoft-float -fPIC
-L/opt/sri/microwindows/work/microwin/src/lib  malpha.o -o
/opt/sri/microwindows/work/microwin/src/bin/malpha
-lmwin -lmwinlib -lmwobjects -lmwengine -lmwdrivers -lmwfonts -lmwimages

/opt/uClinux/gnu/m68k-pic-coff/bin/ld: region a5world is full
(/opt/sri/microwindows/work/microwin/src/bin/malpha section .data)
malpha.o(.text+0x34a):malpha.c: relocation truncated to fit: 16
image_car8
/opt/sri/microwindows/work/microwin/src/lib/libmwin.a(winmain.o)(.text+0x624):winmain.c:
relocation truncated
to fit: 16 errno
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(mou_ads.o)(.text+0x66):mou_ads.c:
relocation
truncated to fit: 16 errno
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(mou_ads.o)(.text+0x12c):mou_ads.c:
relocation
truncated to fit: 16 errno
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xda6):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xe46):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xe62):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xe80):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xeaa):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xec2):memplan4.c:
undefined
reference to `outb'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xee6):memplan4.c:
undefined
reference to `outb'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xf24):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0xf36):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0x11dc):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0x127a):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0x12a4):memplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x7c):vgaplan4.c:
more undefined
references to `outw' follow
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x59e):vgaplan4.c:
undefined
reference to `outb'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x5e8):vgaplan4.c:
undefined
reference to `outb'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x606):vgaplan4.c:
undefined
reference to `outb'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x62a):vgaplan4.c:
undefined
reference to `outb'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x7f4):vgaplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x808):vgaplan4.c:
undefined
reference to `outw'
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(vgaplan4.o)(.text+0x830):vgaplan4.c:
undefined
reference to `outw'
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(select.o)(.text+0x16):select.c:
relocation truncated to fit: 16
errno
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(errno_loc.o)(.text+0x6):errno_loc.c:
relocation truncated to
fit: 16 data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(strcasecmp.o)(.text+0x1e):strcasecmp.c:
relocation truncated to
fit: 16 __ctype
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(strcasecmp.o)(.text+0x42):strcasecmp.c:
relocation truncated to
fit: 16 __ctype
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(printf.o)(.text+0xe):printf.c:
relocation truncated to fit: 16
stdout
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(vsprintf.o)(.text+0x8):printf.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(qsort.o)(.text+0x244):qsort.c:
relocation truncated to fit: 16 data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(qsort.o)(.text+0x418):qsort.c:
relocation truncated to fit: 16 data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(qsort.o)(.text+0x480):qsort.c:
relocation truncated to fit: 16 data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(mmap.o)(.text+0x40):mmap.c:
relocation truncated to fit: 16 errno
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(ctype.o)(.text+0xa):ctype.c:
relocation truncated to fit: 16 data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(ctype.o)(.text+0x26):ctype.c:
relocation truncated to fit: 16 data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(_stdio_init.o)(.text+0x8):stdio.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(_stdio_init.o)(.text+0x16):stdio.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(_stdio_init.o)(.text+0x24):stdio.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(_stdio_init.o)(.text+0x6c):stdio.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(_stdio_init.o)(.text+0x7a):stdio.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(_stdio_init.o)(.text+0xac):stdio.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(_stdio_init.o)(.text+0xe2):stdio.c:
relocation truncated to fit: 16
data
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(vfprintf.o)(.text+0x42e):printf.c:
relocation truncated to fit: 16
stderr
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(fflush.o)(.text+0x16):stdio.c:
relocation truncated to fit: 16
stdin
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(fflush.o)(.text+0x2c):stdio.c:
relocation truncated to fit: 16
stdout
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(fflush.o)(.text+0x42):stdio.c:
relocation truncated to fit: 16
stderr
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(fflush.o)(.text+0x58):stdio.c:
relocation truncated to fit: 16
__IO_list
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(fflush.o)(.text+0xc2):stdio.c:
relocation truncated to fit: 16
errno
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(isatty.o)(.text+0xa):isatty.c:
relocation truncated to fit: 16
errno
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(atexit.o)(.text+0xe):atexit.c:
relocation truncated to fit: 16
__on_exit_count
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(atexit.o)(.text+0x1c):atexit.c:
relocation truncated to fit: 16
errno
/opt/uClinux/gnu/m68k-pic-coff/lib/libc.a(__do_exit.o)(.text+0xe):atexit.c:
relocation truncated to fit: 16
data
make[2]: *** [/opt/sri/microwindows/work/microwin/src/bin/malpha] Error
1
make[2]: Leaving directory
`/opt/sri/microwindows/work/microwin/src/demos/mwin'
make[2]: Entering directory
`/opt/sri/microwindows/work/microwin/src/demos/mwobjects'
make[2]: Nothing to be done for `default'.
make[2]: Leaving directory
`/opt/sri/microwindows/work/microwin/src/demos/mwobjects'
make[2]: Entering directory
`/opt/sri/microwindows/work/microwin/src/demos/nanowm'
make[2]: Nothing to be done for `default'.
make[2]: Leaving directory
`/opt/sri/microwindows/work/microwin/src/demos/nanowm'
make[2]: Entering directory
`/opt/sri/microwindows/work/microwin/src/demos/nanox'
make[2]: Nothing to be done for `default'.



2) Word overflow errors on bigger programs.
    Eg. when I compile using GIF support.

Compiling devpal2.c ...
m68k-pic-coff-gcc -c   -DMWPIXEL_FORMAT=MWPF_PALETTE -DVTSWITCH=1
-DHAVE_FILEIO
-DHAVE_BMP_SUPPORT=1
-DHAVE_GIF_SUPPORT=1 -DHAVE_PNM_SUPPORT=1 -DHAVE_XPM_SUPPORT=1 -DLINUX=1
-DUNIX=1
-I. -I/opt/sri/microwindows/work/microwin/src/include -m68000 -Wa,
-m68000 -DCONFIG_DRAGONBALL -Dlinux
-D__linux__ -Dunix -DEMBED -DNANOX=1 -O2 -msoft-float -fPIC   -o
devpal2.o devpal2.c
Compiling devimage.c ...
m68k-pic-coff-gcc -c   -DMWPIXEL_FORMAT=MWPF_PALETTE -DVTSWITCH=1
-DHAVE_FILEIO
-DHAVE_BMP_SUPPORT=1
-DHAVE_GIF_SUPPORT=1 -DHAVE_PNM_SUPPORT=1 -DHAVE_XPM_SUPPORT=1 -DLINUX=1
-DUNIX=1
-I. -I/opt/sri/microwindows/work/microwin/src/include -m68000 -Wa,
-m68000 -DCONFIG_DRAGONBALL -Dlinux
-D__linux__ -Dunix -DEMBED -DNANOX=1 -O2 -msoft-float -fPIC   -o
devimage.o devimage.c
/tmp/ccuyMWQg.s: Assembler messages:
/tmp/ccuyMWQg.s:140: Error: Value of 77528 too large for field of 2
bytes at 0x1de
/tmp/ccuyMWQg.s:140: Error: Signed .word overflow; switch may be too
large; 77528 at 0x1de
/tmp/ccuyMWQg.s:140: Error: value out of range
/tmp/ccuyMWQg.s:167: Error: Value of 77528 too large for field of 2
bytes at 0x22e
/tmp/ccuyMWQg.s:167: Error: Signed .word overflow; switch may be too
large; 77528 at 0x22e
/tmp/ccuyMWQg.s:167: Error: value out of range
/tmp/ccuyMWQg.s:296: Error: Value of 77528 too large for field of 2
bytes at 0x3d8
/tmp/ccuyMWQg.s:296: Error: Signed .word overflow; switch may be too
large; 77528 at 0x3d8
/tmp/ccuyMWQg.s:296: Error: value out of range
/tmp/ccuyMWQg.s:1208: Error: Value of 77540 too large for field of 2
bytes at 0xec4
/tmp/ccuyMWQg.s:1208: Error: Signed .word overflow; switch may be too
large; 77540 at 0xec4
/tmp/ccuyMWQg.s:1208: Error: value out of range
/tmp/ccuyMWQg.s:1215: Error: Value of 77536 too large for field of 2
bytes at 0xed6
/tmp/ccuyMWQg.s:1215: Error: Signed .word overflow; switch may be too
large; 77536 at 0xed6
/tmp/ccuyMWQg.s:1215: Error: value out of range
/tmp/ccuyMWQg.s:1230: Error: Value of 77536 too large for field of 2
bytes at 0xefc
/tmp/ccuyMWQg.s:1230: Error: Signed .word overflow; switch may be too
large; 77536 at 0xefc
/tmp/ccuyMWQg.s:1230: Error: value out of range
/tmp/ccuyMWQg.s:1231: Error: Value of 77540 too large for field of 2
bytes at 0xf00
/tmp/ccuyMWQg.s:1231: Error: Signed .word overflow; switch may be too
large; 77540 at 0xf00
/tmp/ccuyMWQg.s:1231: Error: value out of range
/tmp/ccuyMWQg.s:1268: Error: Value of 77540 too large for field of 2
bytes at 0xf54
/tmp/ccuyMWQg.s:1268: Error: Signed .word overflow; switch may be too
large; 77540 at 0xf54
/tmp/ccuyMWQg.s:1268: Error: value out of range
/tmp/ccuyMWQg.s:1445: Error: Value of 77544 too large for field of 2
bytes at 0x1222
/tmp/ccuyMWQg.s:1445: Error: Signed .word overflow; switch may be too
large; 77544 at 0x1222
/tmp/ccuyMWQg.s:1445: Error: value out of range
/tmp/ccuyMWQg.s:1629: Error: Value of 77544 too large for field of 2
bytes at 0x1446
/tmp/ccuyMWQg.s:1629: Error: Signed .word overflow; switch may be too
large; 77544 at 0x1446
/tmp/ccuyMWQg.s:1629: Error: value out of range
/tmp/ccuyMWQg.s:1746: Error: Value of 77544 too large for field of 2
bytes at 0x15a4
/tmp/ccuyMWQg.s:1746: Error: Signed .word overflow; switch may be too
large; 77544 at 0x15a4
/tmp/ccuyMWQg.s:1746: Error: value out of range
/tmp/ccuyMWQg.s:2022: Error: Signed .word overflow; switch may be too
large; 44752 at 0x186c
/tmp/ccuyMWQg.s:2023: Error: Value of 77520 too large for field of 2
bytes at 0x1870
/tmp/ccuyMWQg.s:2023: Error: Signed .word overflow; switch may be too
large; 77520 at 0x1870
/tmp/ccuyMWQg.s:2023: Error: value out of range
/tmp/ccuyMWQg.s:2045: Error: Value of 77520 too large for field of 2
bytes at 0x18ae
/tmp/ccuyMWQg.s:2045: Error: Signed .word overflow; switch may be too
large; 77520 at 0x18ae
/tmp/ccuyMWQg.s:2045: Error: value out of range
/tmp/ccuyMWQg.s:2047: Error: Signed .word overflow; switch may be too
large; 44752 at 0x18b4
/tmp/ccuyMWQg.s:2106: Error: Signed .word overflow; switch may be too
large; 44752 at 0x1956
/tmp/ccuyMWQg.s:2107: Error: Value of 77520 too large for field of 2
bytes at 0x195a
/tmp/ccuyMWQg.s:2107: Error: Signed .word overflow; switch may be too
large; 77520 at 0x195a
/tmp/ccuyMWQg.s:2107: Error: value out of range
/tmp/ccuyMWQg.s:2137: Error: Value of 77520 too large for field of 2
bytes at 0x19ac
/tmp/ccuyMWQg.s:2137: Error: Signed .word overflow; switch may be too
large; 77520 at 0x19ac
/tmp/ccuyMWQg.s:2137: Error: value out of range
/tmp/ccuyMWQg.s:2146: Error: Value of 77520 too large for field of 2
bytes at 0x19c0
/tmp/ccuyMWQg.s:2146: Error: Signed .word overflow; switch may be too
large; 77520 at 0x19c0
/tmp/ccuyMWQg.s:2146: Error: value out of range
/tmp/ccuyMWQg.s:2166: Error: Value of 77520 too large for field of 2
bytes at 0x19fc
/tmp/ccuyMWQg.s:2166: Error: Signed .word overflow; switch may be too
large; 77520 at 0x19fc
/tmp/ccuyMWQg.s:2166: Error: value out of range
/tmp/ccuyMWQg.s:2203: Error: Value of 77520 too large for field of 2
bytes at 0x1a62
/tmp/ccuyMWQg.s:2203: Error: Signed .word overflow; switch may be too
large; 77520 at 0x1a62
/tmp/ccuyMWQg.s:2203: Error: value out of range
/tmp/ccuyMWQg.s:2205: Error: Signed .word overflow; switch may be too
large; 44752 at 0x1a68
make[1]: *** [devimage.o] Error 1
make[1]: Leaving directory
`/opt/sri/microwindows/work/microwin/src/engine'
make[1]: Entering directory
`/opt/sri/microwindows/work/microwin/src/fonts'

Subject: Re: uClinux/Microwindows Compilation problems - Urgent... help..
From: Alan Cox ####@####.####
Date: 2 Feb 2001 17:34:14 -0000
Message-Id: <E14OkB0-0006sR-00@the-village.bc.nu>

> But nothing seems to work. I always get the problem of 'a5world full' or
> '.text truncation' or '.word overflow'
> 
> I have almost given up on this.  Please do help me. Quite
> frustrating.....

You probably need to push more data out of the data segment, paticularly
compiled in images. Changing the code to malloc and load the images and 
using a pointer to them should solve that

> undefined
> reference to `outw'
> /opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0x11dc):memplan4.c:

And build with the right hardware support ..

Subject: Re: uClinux/Microwindows Compilation problems - Urgent... help..
From: "Greg Haerr" ####@####.####
Date: 5 Feb 2001 18:00:00 -0000
Message-Id: <02ac01c08f99$5c51b200$15320cd0@gregh>

: > undefined
: > reference to `outw'
: >
/opt/sri/microwindows/work/microwin/src/lib/libmwdrivers.a(memplan4.o)(.text+0x1
1dc):memplan4.c:
:
: And build with the right hardware support ..

That means set FBVGA=N in microwin/src/config

Regards,

Greg

Subject: uClinux/Microwindows Compilation problems - Urgent... help..
From: Zeng_Pengcheng ####@####.####
Date: 22 Apr 2003 03:38:40 -0000
Message-Id: <31F8842A5C58D61189DE00E04C57D7C6172217@SERVER>

sir,
	
	do u know how to fix the problem? that is, do u know how to modify
the Arch.rules now? would u please send me a copy of Arch.rules?

	thanks in advance
[<<] [<] Page 1 of 1 [>] [>>]


Powered by ezmlm-browse 0.20.