Error cross compiling trunk for AVR

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Error cross compiling trunk for AVR

Christo Crause
A recent change in 3.1.1 seemed to have broken the AVR compiler, while
the compiler compiles fine for X86_64-linux. I think the problem
started from r36325:

make clean crossall OS_TARGET=embedded CPU_TARGET=avr SUBARCH=avr5
BINUTILSPREFIX=avr- CROSSOPT="-O3 -XX -CX"
FPC=~/fpc/3.0.2/compiler/ppcx64

When starting to compile the rtl
make[2]: Entering directory '/home/christo/fpc/3.1.1'
make -C rtl all
make[3]: Entering directory '/home/christo/fpc/3.1.1/rtl'
make -C embedded all
make[4]: Entering directory '/home/christo/fpc/3.1.1/rtl/embedded'
/bin/mkdir -p /home/christo/fpc/3.1.1/rtl/units/avr-embedded
/home/christo/fpc/3.1.1/compiler/ppcrossavr -Cpavr5 @rtl.cfg -Ur
-Tembedded -Pavr -XPavr- -Xr -Ur -Xs -O2 -n -Fi../inc -Fi../avr -FE.
-FU/home/christo/fpc/3.1.1/rtl/units/avr-embedded -davr -dRELEASE -O3
-XX -CX -Us -Sg system.pp 
/home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s: Assembler
messages:
/home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7283: Error:
pointer register (X, Y or Z) required
/home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7283: Error:
`,' required
/home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7285: Error:
pointer register (X, Y or Z) required
/home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7285: Error:
`,' required
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Error cross compiling trunk for AVR

Schindler Karl-Michael-2

> Am 27.05.2017 um 11:26 schrieb [hidden email]:
>
> Date: Sat, 27 May 2017 07:58:23 +0200
> From: Christo <[hidden email]>
> To: FPC-Pascal users discussions <[hidden email]>
> Subject: [fpc-pascal] Error cross compiling trunk for AVR
> Message-ID: <[hidden email]>
> Content-Type: text/plain; charset="UTF-8"
>
> A recent change in 3.1.1 seemed to have broken the AVR compiler, while
> the compiler compiles fine for X86_64-linux. I think the problem
> started from r36325:
>
> make clean crossall OS_TARGET=embedded CPU_TARGET=avr SUBARCH=avr5
> BINUTILSPREFIX=avr- CROSSOPT="-O3 -XX -CX"
> FPC=~/fpc/3.0.2/compiler/ppcx64
>
> When starting to compile the rtl
> make[2]: Entering directory '/home/christo/fpc/3.1.1'
> make -C rtl all
> make[3]: Entering directory '/home/christo/fpc/3.1.1/rtl'
> make -C embedded all
> make[4]: Entering directory '/home/christo/fpc/3.1.1/rtl/embedded'
> /bin/mkdir -p /home/christo/fpc/3.1.1/rtl/units/avr-embedded
> /home/christo/fpc/3.1.1/compiler/ppcrossavr -Cpavr5 @rtl.cfg -Ur
> -Tembedded -Pavr -XPavr- -Xr -Ur -Xs -O2 -n -Fi../inc -Fi../avr -FE.
> -FU/home/christo/fpc/3.1.1/rtl/units/avr-embedded -davr -dRELEASE -O3
> -XX -CX -Us -Sg system.pp
> /home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s: Assembler
> messages:
> /home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7283: Error:
> pointer register (X, Y or Z) required
> /home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7283: Error:
> `,' required
> /home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7285: Error:
> pointer register (X, Y or Z) required
> /home/christo/fpc/3.1.1/rtl/units/avr-embedded/system.s:7285: Error:
> `,’ required

Same error when building on macOS. Critical commit is 36325 in combination with  CROSSOPT="-O3". Build fails for all SUBARCHS of avr.

Bugreport submitted (https://bugs.freepascal.org/view.php?id=31926)
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Error cross compiling trunk for AVR

Christo Crause
On Sat, 2017-05-27 at 12:58 +0200, Schindler Karl-Michael wrote:
> >
> > Am 27.05.2017 um 11:26 schrieb [hidden email].
> > org:
> >
> > Date: Sat, 27 May 2017 07:58:23 +0200
> > From: Christo <[hidden email]>
> >
> > A recent change in 3.1.1 seemed to have broken the AVR compiler...

> Same error when building on macOS. Critical commit is 36325 in
> combination with  CROSSOPT="-O3". Build fails for all SUBARCHS of
> avr.
>
> Bugreport submitted (https://bugs.freepascal.org/view.php?id=31926)

Right, I see that CROSSOPT="-O2" does work. -O2 is probably OK for an
embedded target compiler. Thanks for confirming and reporting the
issue.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal