Re: [fpc-pascal] Updated FPC from svn but make does not work..

2015-11-10 Thread Mark Morgan Lloyd

Martin Schreiber wrote:

On Monday 09 November 2015 23:57:30 Bo Berglund wrote:

On Mon, 9 Nov 2015 15:19:12 +0100, Martin Schreiber

 wrote:

On Monday 09 November 2015 11:35:05 Mark Morgan Lloyd wrote:

So. I'd suggest that you start off with Martin's binary, build the
matching 2.6.4,

FPC 2.6.4 has no support for EABIHF AFAIK. I have a patched 2.6.4 version
with EABIHF support but I suggest to use FPC 3.0 or fixes_3_0 instead. I
am sure Bo knows where to get it. ;-)

Sources yes, I have checked out something like 4 different source
trees by now.
But the binaries are another deal...


I fear you do not read my mails.
http://sourceforge.net/projects/mseide-msegui/files/fpcarm/


Agreed, best place to start.


What is EABIHF?


The application binary interface of RaspberryPi.


HF variant of the ARM (E)ABI.


So you think that fixes_3_0 would be a better fpc on my RPi2?


Yes. And I recommend to use cross compiling and debugging from a X86 Linux PC:
http://www.mail-archive.com/lazarus%40lists.lazarus.freepascal.org/msg50406.html


On that we'll have to disagree. The RPi, particularly the 2, is an 
entirely adequate computer in its own right.


--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Updated FPC from svn but make does not work..

2015-11-10 Thread Martin Schreiber
On Tuesday 10 November 2015 09:48:23 Mark Morgan Lloyd wrote:

> >
> > Yes. And I recommend to use cross compiling and debugging from a X86
> > Linux PC:
> > http://www.mail-archive.com/lazarus%40lists.lazarus.freepascal.org/msg504
> >06.html
>
> On that we'll have to disagree. The RPi, particularly the 2, is an
> entirely adequate computer in its own right.

Sure but the accustomed development environment (tools, documentation, version 
control, useful links, mail and mailinglists...) must first be installed and 
maintained separately.
I find it much more convenient to use a single "every day" development 
environment for all tasks.

Martin
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Updated FPC from svn but make does not work..

2015-11-10 Thread Mark Morgan Lloyd

Martin Schreiber wrote:

On Tuesday 10 November 2015 09:48:23 Mark Morgan Lloyd wrote:


Yes. And I recommend to use cross compiling and debugging from a X86
Linux PC:
http://www.mail-archive.com/lazarus%40lists.lazarus.freepascal.org/msg504
06.html

On that we'll have to disagree. The RPi, particularly the 2, is an
entirely adequate computer in its own right.


Sure but the accustomed development environment (tools, documentation, version 
control, useful links, mail and mailinglists...) must first be installed and 
maintained separately.
I find it much more convenient to use a single "every day" development 
environment for all tasks.


On the balance, particularly when one has something as capable as the 
RPi2, I don't. What I do find useful is being able to cut-and-paste 
between (programs running on) different hosts, which in practice either 
means running the IDE over SSH or having something running on each 
computer to implement a shared clipboard.


--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] mips linux cross compiled application error

2015-11-10 Thread Mark Morgan Lloyd

czd wrote:
Hi all, 
I have compiled a simple mips/linux application with using raspberry pi,

when I execute the app. it replies with this error. Device is onion omega.
Illegal instruction.

Here is my application output and the source.
file testmips 
testmips: ELF 32-bit MSB executable, MIPS, MIPS32 version 1, statically

linked, stripped

program test;
begin
  writeln('DATE ',{$i %DATE%});
  writeln('FPCTARGET ',{$i %FPCTARGET%});
  writeln('FPCTARGETCPU ',{$i %FPCTARGETCPU%});
  writeln('FPCTARGETOS ',{$i %FPCTARGETOS%});
  writeln('FPCVERSION ',{$i %FPCVERSION%});
end.
Is there any special options for mips/linux to compile under arm/linux?
Thanks.


I think you need to give us more information about how you've built and 
how you're invoking the compiler. Also I notice from 
https://onion.io/omega/ that it runs OpenWRT, I'm not sure what the 
situation is with this but I think you'll need to link in appropriate 
runtimes.


--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] mips linux cross compiled application error

2015-11-10 Thread Sven Barth
Am 10.11.2015 10:38 schrieb "Mark Morgan Lloyd" <
markmll.fpc-pas...@telemetry.co.uk>:
> I think you need to give us more information about how you've built and
how you're invoking the compiler. Also I notice from https://onion.io/omega/
that it runs OpenWRT, I'm not sure what the situation is with this but I
think you'll need to link in appropriate runtimes.

On Linux we're using the syscall interface instead of libc, so for a simple
program like the above this shouldn't be the problem. Propably the wrong
CPU type was selected or something like that... But as you said we need
more information.

Regards,
Sven
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] mips linux cross compiled application error

2015-11-10 Thread czd
The board that I mention looks like Big endian mips system so 
I checked and recompile the binutils again with these parameters.

./configure --target=mips-linux --prefix=/usr/local --bindir=/usr/bin
--program-prefix=mips-linux-

And here is the fpc compile steps.

make distclean OS_TARGET=linux CPU_TARGET=mips BINUTILSPREFIX=mips-linux-
CROSSBINDIR=/usr/bin
sudo make all crossinstall OS_TARGET=linux CPU_TARGET=mips
BINUTILSPREFIX=mips-linux- CROSSBINDIR=/usr/bin INSTALL_PREFIX=/usr/local

fpc -Tlinux -Pmips testmips.pas
Indeed I get that warning message if that is the case.
/usr/bin/mips-linux-ld:
/usr/local/lib/fpc/3.1.1/units/mips-linux/rtl/system.o: warning: linking
abicalls files with non-abicalls files
9 lines compiled, 0.4 sec





--
View this message in context: 
http://free-pascal-general.1045716.n5.nabble.com/mips-linux-cross-compiled-application-error-tp5723048p5723062.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] mips linux cross compiled application error

2015-11-10 Thread Mark Morgan Lloyd

czd wrote:
The board that I mention looks like Big endian mips system so 
I checked and recompile the binutils again with these parameters.


Big-endian... kinky :-)


./configure --target=mips-linux --prefix=/usr/local --bindir=/usr/bin
--program-prefix=mips-linux-

And here is the fpc compile steps.

make distclean OS_TARGET=linux CPU_TARGET=mips BINUTILSPREFIX=mips-linux-
CROSSBINDIR=/usr/bin
sudo make all crossinstall OS_TARGET=linux CPU_TARGET=mips
BINUTILSPREFIX=mips-linux- CROSSBINDIR=/usr/bin INSTALL_PREFIX=/usr/local

fpc -Tlinux -Pmips testmips.pas
Indeed I get that warning message if that is the case.
/usr/bin/mips-linux-ld:
/usr/local/lib/fpc/3.1.1/units/mips-linux/rtl/system.o: warning: linking
abicalls files with non-abicalls files
9 lines compiled, 0.4 sec


I'm about to go out. I know this has been discussed before either here 
on in fpc-devel, I'd suggest Googling for any mention of OpenWrt.


--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal