[avr-libc-dev] avr-lib compiling error

2008-12-03 Thread Boris Borisov

Hello All,
I try to update my avr-libc but compilation is fail with messages:

avr-gcc 
-I/var/tmp/cross/avr/portage/cross-avr/avr-libc-1.6.2/work/avr-libc-1.6.2/common 
-I/var/tmp/cross/avr/portage/cross-avr/avr-libc-1.6.2/work/avr-libc-1.6.2/include 
-x assembler-with-cpp -Wa,-gstabs -mmcu=avr2 -D__COMPILING_AVR_LIBC__   
-c 
/var/tmp/cross/avr/portage/cross-avr/avr-libc-1.6.2/work/avr-libc-1.6.2/libc/stdlib/setjmp.S
/var/tmp/cross/avr/portage/cross-avr/avr-libc-1.6.2/work/avr-libc-1.6.2/libc/stdlib/setjmp.S: 
Assembler messages:
/var/tmp/cross/avr/portage/cross-avr/avr-libc-1.6.2/work/avr-libc-1.6.2/libc/stdlib/setjmp.S:81: 
Error: missing model parameter
/var/tmp/cross/avr/portage/cross-avr/avr-libc-1.6.2/work/avr-libc-1.6.2/libc/stdlib/setjmp.S:128: 
Error: missing model parameter

make[5]: *** [setjmp.o] Error 1


More info about my system:
avr-gcc version:
avr-gcc (GCC) 4.2.3 (Gentoo 4.2.3 p1.0)
configuration options:
/configure --prefix=/usr --host=avr --mandir=/usr/share/man 
--infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc 
--localstatedir=/var/lib --enable-nls --libdir=/usr/lib --target=avr 
--build=i686-pc-linux-gnu


On this line in setjump.S all seems OK
78: _U(setjmp):
79:X_movwXL, jmpb_lo
80:  ; save call-saved registers and frame pointer
81:.irp.L_regno, 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,28,29
82:stX+, r\.L_regno
...
127:  ; restore call-saved registers and frame pointer
128:.irp.L_regno, 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,28,29

What I do wrong or this is bug.



___
AVR-libc-dev mailing list
AVR-libc-dev@nongnu.org
http://lists.nongnu.org/mailman/listinfo/avr-libc-dev


Re: [avr-libc-dev] avr-lib compiling error

2008-12-05 Thread Boris Borisov

Weddington, Eric wrote:
 

  

-Original Message-
From: Boris Borisov [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 03, 2008 1:35 PM

To: Weddington, Eric
Subject: Re: [avr-libc-dev] avr-lib compiling error



Hello All,
I try to update my avr-libc but compilation is fail with messages:
  
  

snip




avr-gcc (GCC) 4.2.3 (Gentoo 4.2.3 p1.0)
  
  

Are you using 'crosstool' to build your toolchain?



Excuse me, I meant 'crossdev'.

  
  
Yes with option -t avr. also I try manually in my home directory to 
build avr-libc. The result is same.





Crossdev is known to fail building a correct AVR toolchain. Please see the 
directions in the avr-libc user manual online on how to build an AVR toolchain:
http://www.nongnu.org/avr-libc/user-manual/

snip

Thanks,
Eric

  
I found temporary solutions to solve errors in crossdev compiling tool 
under Gentoo distribution.
This is problem is exist if try to compile avr-libc with low version of 
binutils = 2.15

Solution:
1. Uninstall the avr tollchain with command:
crossdev -C avr
2. Start installation using crossdev with command:
crossdev avr
This is installation  fail with message:
--
* Host Portage ARCH: 
x86
* Target Portage ARCH:   
*  
* Target System: avr

* Stage: 3 (C compiler  libc)

* binutils:  binutils-[latest]
* gcc:   gcc-[latest]
* libc:  avr-libc-[latest]

* PORTDIR_OVERLAY:   /usr/local/portage
* PORT_LOGDIR:   /var/log/portage
* PKGDIR:/usr/portage/packages/cross/avr
* PORTAGE_TMPDIR:/var/tmp/cross/avr
 _  -  ~  -  _  -  ~  -  _  -  ~  -  _  -  ~  -  _  -  ~  -  _  -  ~  
-  _  -  ~  -  _  -  ~
* Forcing the latest versions of {binutils,gcc}-config/gnuconfig 
...   [ ok ]

* Log: /var/log/portage/cross-avr-binutils.log
* Emerging cross-binutils 
...  [ ok ]

* Log: /var/log/portage/cross-avr-avr-libc-headers.log
* Emerging cross-avr-libc-headers ...

* avr-libc failed :(
* If you file a bug, please attach the following logfiles:
* /var/log/portage/cross-avr-info.log
* /var/log/portage/cross-avr-avr-libc-headers.log

This is result from trying to compile avr-libc without compiler avr-gcc 
- this is bug in script and I not find the solution because I.m is not 
expert in bash programming. But on this stage the binutils is installed 
(for me version 2.19) and ebuilds in /usr/locale/portage is created.


3. Installing gcc
add this row in /etc/portage/package.use
cross-avr/gcc -nls -fortran -gtk -openmp -mudflap
With command:
echo cross-avr/gcc -nls -fortran -gtk -openmp -mudflap  
/etc/portage/package.use

Install GCC with command
emerge cross-avr/gcc
For me this is ebuild install version 4.3.2 of GCC.

4. Continue install procedure with crossdev tool with command:
crossdev avr
Script continue installing avr-libc
For me this is avr-libc-1.6.2
And that's all

I hope this hack help other users of avr-gcc under Gentoo to not lose 
like me time in additional try  to compile or update avr toolchain.


Bobby 73!

___
AVR-libc-dev mailing list
AVR-libc-dev@nongnu.org
http://lists.nongnu.org/mailman/listinfo/avr-libc-dev