Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2017-05

Error cross compiling trunk for AVR

3 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Christo

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

Schindler Karl-Michael
Show quoted text 38 lines
Am 27.05.2017 um 11:26 schrieb Date: Sat, 27 May 2017 07:58:23 +0200 From: Christo To: FPC-Pascal users discussions Subject: [fpc-pascal] Error cross compiling trunk for AVR Message-ID: 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)

Christo
to Schindler Karl-Michael
Schindler Karl-Michael wrote 14 lines
> > Am 27.05.2017 um 11:26 schrieb > org: > > Date: Sat, 27 May 2017 07:58:23 +0200 > From: Christo > > 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.