Sign in Join

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

Mailing lists / fpc-pascal / 2009-03

using fpc on a arm4t system failed

9 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

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

Benedikt Schindler

Hi,

i installed fpc-2.2.2 with the arm-linux-binaries from the main page. the installation finished with no problems.

but when i try to use on of the installed programms (e.g. ppcarm, fpc or fpcmake) i get a "Illegal instruction" error.
What ARM CPUs are supported by FPC?

My cpu info :

cat /proc/cpuinfo
Processor : ARM920T rev 0 (v4l)
BogoMIPS : 198.65
Features : swp half thumb
CPU implementer : 0x41
CPU architecture: 4T
CPU variant : 0x1
CPU part : 0x920
CPU revision : 0

Hardware : GTA02
Revision : 0350
Serial : 0000000000000000

Reply by email

Benedikt Schindler
to Paul Breneman

same problem with this test.
just the output "Illegal instruction".
nothing in dmesg.

-----------------------
tar -xvzf HelloWorld-fpc-2.2.2.arm-linux.tar.gz
copying
copying.fpc
hello.pas
ppcarm
prt0.o
system.o
system.ppu
TurboControlDistributionReadMe.txt
./ppcarm hello
Illegal instruction
--------------------------

Show quoted text 8 lines
Beni, Please try the ARM-Linux example on this page and see if it works: http://www.turbocontrol.com/helloworld.htm -- Regards, Paul Breneman

Reply by email

Benedikt Schindler
to Benedikt Schindler

Hi,

is there another precompiled "ppcarm" from the version v2.2.x or v2.3.x ? Or exists a maintainer for the arm version? So i could ask him for a debugging version to find the problem.
I couldn't debug the problem by my self, because i don't have a clou about assembler programming.

please give me a hint where to start.
because i really would like to programm in freepascal for the openmoko freerunner device.

best regards
benedikt

Show quoted text 32 lines
same problem with this test. just the output "Illegal instruction". nothing in dmesg. ----------------------- tar -xvzf HelloWorld-fpc-2.2.2.arm-linux.tar.gz copying copying.fpc hello.pas ppcarm prt0.o system.o system.ppu TurboControlDistributionReadMe.txt ./ppcarm hello Illegal instruction -------------------------- Paul Breneman schrieb: > Beni, > > Please try the ARM-Linux example on this page and see if it works: > http://www.turbocontrol.com/helloworld.htm > > -- > Regards, > Paul Breneman _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply by email

Henry Vermaak
to Benedikt Schindler

2009/3/23 Benedikt Schindler :

Show quoted text 11 lines
Hi, is there another precompiled  "ppcarm" from the version v2.2.x or v2.3.x ? Or exists a maintainer for the arm version? So i could ask him for a debugging version to find the problem. I couldn't debug the problem by my self, because i don't have a clou about assembler programming. please give me a hint where to start. because i really would like to programm in freepascal for the openmoko freerunner device.

i think openmoko is based on angstrom distro, which uses eabi. you will have to build your own compiler and rtl (which is not that hard).

you can do this by adding OPT="-dFPC_ARMEL" to your make params. there were a couple of threads about this, so you should read them first!

henry

Reply by email

Paul Breneman
to Benedikt Schindler: is there another precompiled "ppcarm" from the version v2.2.x or v2.3.x ? Or exists a…

Beni,

Show quoted text 9 lines
is there another precompiled "ppcarm" from the version v2.2.x or v2.3.x ? Or exists a maintainer for the arm version? So i could ask him for a debugging version to find the problem. I couldn't debug the problem by my self, because i don't have a clou about assembler programming. please give me a hint where to start. because i really would like to programm in freepascal for the openmoko freerunner device.

On 14 Dec 2008 on the fpc-devel maillist Florian Klaempfl wrote:

**************
Yes. I uploaded a starting eabi compiler to
http://www.florianklaempfl.de/ppcarm

Please use only with -O-
*************

Maybe you could try replacing the ppcarm in my helloworld example with that (and also use -O-)?

Paul

Reply by email

Henry Vermaak
to Paul Breneman

2009/3/23 Paul Breneman :

Show quoted text 24 lines
Beni, > is there another precompiled  "ppcarm" from the version v2.2.x or v2.3.x ? > Or exists a maintainer for the arm version? So i could ask him for a > debugging version to find the problem. > I couldn't debug the problem by my self, because i don't have a clou about > assembler programming. > > please give me a hint where to start. > because i really would like to programm in freepascal for the openmoko > freerunner device. On 14 Dec 2008 on the fpc-devel maillist Florian Klaempfl wrote: ************** Yes. I uploaded a starting eabi compiler to http://www.florianklaempfl.de/ppcarm Please use only with -O- ************* Maybe you could try replacing the ppcarm in my helloworld example with that (and also use -O-)?

this won't work unless you compile the rtl objects with this compiler, too. rather just try `ppcarm -h` to see if the compiler executes.

henry

Reply by email

Paul Breneman
to Henry Vermaak
Henry Vermaak wrote 27 lines
2009/3/23 Paul Breneman : > Beni, > >> is there another precompiled "ppcarm" from the version v2.2.x or v2.3.x ? >> Or exists a maintainer for the arm version? So i could ask him for a >> debugging version to find the problem. >> I couldn't debug the problem by my self, because i don't have a clou about >> assembler programming. >> >> please give me a hint where to start. >> because i really would like to programm in freepascal for the openmoko >> freerunner device. > On 14 Dec 2008 on the fpc-devel maillist Florian Klaempfl wrote: > > ************** > Yes. I uploaded a starting eabi compiler to > http://www.florianklaempfl.de/ppcarm > > Please use only with -O- > ************* > > Maybe you could try replacing the ppcarm in my helloworld example with that > (and also use -O-)? > this won't work unless you compile the rtl objects with this compiler, too. rather just try `ppcarm -h` to see if the compiler executes.

Thanks Henry for helping me as I stumble along in this and the other (fpc-devel) thread!

Reply by email

Benedikt Schindler
to Paul Breneman

Hi,

the file from Florian didn't work. But i looked around in the mailing lists and now i try to crosscompile a new version for the openmoko device.

I crosscompiled binutils for "arm4tl-unknown-linux". and then i tried to cross compile the FPC (2.3.x) with this command:

make all OS_TARGET=linux CPU_TARGET=arm
BINUTILSPREFIX=/opt/armlinux/crossbinutils/bin/arm4tl-unknown-linux- OPT="-dFPC_ARMEL -O-" FPC=/usr/bin/ppc386

Worked fine.
On the device the new ppcarm didn't say "Illegal Instruction" any more. So far so good. ... But now it didn't say did a "echo $?" after "./ppcarm -h" and it returns 216

---------------------------

if i try to compile the 2.2.2 sources i get an error:

i_linux.pas(594,11) Error: Identifier not found "abi_eabi"
i_linux.pas(594,11) Error: Illegal expression

any ideas?
I also tried to compile with -dFPC_ABI_EABI

thx, and best regards
Benedikt

Show quoted text 38 lines
Henry Vermaak wrote: > 2009/3/23 Paul Breneman : >> Beni, >> >>> is there another precompiled "ppcarm" from the version v2.2.x or >>> v2.3.x ? >>> Or exists a maintainer for the arm version? So i could ask him for a >>> debugging version to find the problem. >>> I couldn't debug the problem by my self, because i don't have a >>> clou about >>> assembler programming. >>> >>> please give me a hint where to start. >>> because i really would like to programm in freepascal for the openmoko >>> freerunner device. >> On 14 Dec 2008 on the fpc-devel maillist Florian Klaempfl wrote: >> >> ************** >> Yes. I uploaded a starting eabi compiler to >> http://www.florianklaempfl.de/ppcarm >> >> Please use only with -O- >> ************* >> >> Maybe you could try replacing the ppcarm in my helloworld example >> with that >> (and also use -O-)? >> > > this won't work unless you compile the rtl objects with this compiler, > too. rather just try `ppcarm -h` to see if the compiler executes. Thanks Henry for helping me as I stumble along in this and the other (fpc-devel) thread! _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply by email