You are not logged in.
Pages: 1
Hi,
I am able to crosscompile i386/win32 -> i386/linux my mORMot application.
Is it planned to support powerpc/aix?
Edit:
I'm compiling under FPC 3.1.1
It fails on line 225 of file Synopse.inc: {$ASMMODE INTEL} // as Delphi expects, and I use to write
I tried to define PUREPASCAL, it did not help.
Last edited by dexter (2016-01-22 17:16:27)
Offline
You could try using the following trick:
Inside Synopse.inc, inside the section for FPC (e.g. at line 200), add:
{$ifdef CPUPOWERPC}
{$define CPUARM}
{$endif}
If all goes well, mORMot should compile ....
Last edited by AOG (2016-01-23 07:32:17)
Offline
Fails as well, now in SynCommons:
function GetTickCount64: Int64;
begin
result := SynFPCLinux.GetTickCount64; // <-- here, saying unknown identifier SynFPCLinux
end;
SynFPCLinux is included only when $Linux is defined.
Offline
Well ... the next trick will obviously be:
{$ifdef AIX}
{$define Linux}
{$endif}
But if this will work .... unlikely ....
Offline
You can get all macros by doing :
fpc -va
or
'anycompiler' -va
Linux/unix related defines:
Macro defined: LINUX
Macro defined: UNIX
Macro defined: HASUNIX
Macro defined: BSD
Macro defined: HASUNIX
AFAIK, AIX has Linux and Unix defined !
Offline
I doubt AIX has LINUX defined, this it is not Linux based at all.
See http://wiki.freepascal.org/FPC_AIX_Port
and https://en.wikipedia.org/wiki/IBM_AIX
But HASUNIX and UNIX are probably defined for this OS.
What about the "Linux Affinity" program?
http://www-03.ibm.com/systems/power/sof … linux.html
Offline
Mmmm ... I just build a crosscompiler Win -> powerpc/aix.
It states (ppcrossppc.exe -va) : Unix and Linux.
But its definitely not Linux (also according to your links).
?
Offline
I personally would very much welcome that !
Would make compilation for Darwin easier !
Darwin = Unix.
Darwin != Linux.
Offline
So perhaps we may try to replace most LINUX conditionals for FPC specific code to UNIX...
Agree, would be very good!
Let us know please when it's done, so we can test it.
Offline
For mORMot 2, I have just made a huge refactoring of all Operating-Systems conditionals.
The LINUX conditional was very confusing, and has been renamed as OSPOSIX, which is the opposite of OSWINDOWS.
Then we have OSLINUX OSBSD OSDARWIN OSANDROID and more specific OSBSDDARWIN for OSBSD+OSDARWIN, and OSOPENBSD and OSFREEBSD.
So we don't depend on FPC conditionals any more.
Check https://github.com/synopse/mORMot2/commit/d80ccccb3507
Feedback is welcome!
Offline
The LINUX conditional was very confusing, and has been renamed as OSPOSIX, which is the opposite of OSWINDOWS.
Please note that by assuming that OSPOSIX is the opposite of OSWINDOWS you're precluding the use of systems that are neither, but would be able to use mORMot in theory (mainly modern OS/2 systems like eComStation and modern Amigas like AROS or MorphOS). If you don't want to support them right away it would be better to simple error out with an $error in the $else case instead of having undefined behavior for them. FPC's define for POSIX compatible systems is indeed UNIX.
Free Pascal Compiler Core developer
Offline
Pages: 1