Martin Schreiber wrote:
Where can we find a list of the possible and necessary options for building
the Free Pascal compiler? "compiler/README.txt" looks incomplete.

The most complete documentation is Marco's buildfaq:

How can we find out the possible make targets and its meanings in "compiler"
other than analyzing the make file?

There is no such documentation at this time, although in general adding CPU_TARGET=x OS_TARGET=y is all you need.

The problem Linux/ARM specifically is also that you have to be pretty much an expert at Linux/ARM and know exactly what the capabilities of your ARM hardware are before you can know what you have to build, independent of instructions regarding how to build it (which doesn't mean that instructions regarding how to build it are superfluous, of course).

The reason is that there are so many different incompatible versions of that platform:
* OABI big/little endian
* OABI with AFP big/little endian
* (EABI versions 0 to 5) with softfloat (always little endian)
* ((EABI versions 0 to 5) with softfp) and ((no fpu) or VFPv2 or (VFPv3/4 with (d16 or d32))) (always little endian) * ((EABI version 5) with hard-float) and (VFPv2 or (VFPv3/4 with (d16 or d32))) (always little endian)

And there are probably already more in the mean time...

Now, OABI is basically unused nowadays and with the EABI targets there are some fairly safe defaults, so even if you don't know the exact VFP unit or what EABI version you have, the compiler and assembler/linker will generally use something by default that works (albeit not necessarily optimal). So it's not as bad as it may seem at first sight from the above list, but it's far from trivial.

Additionally, the ARM port of FPC was the first one that had to support multiple ABIs for the same platform, and as a result has not been implemented in the best way possible, requiring different compiler binaries to target different ABIs (which is why these extra OPT= parameters are required). Changing that also requires overhauling the build system though, as we would have to store units compiled for a different ABI in different directories. There's an svn branch for this (http://svn.freepascal.org/svn/fpc/branches/target-subdir/ ), but fpmake support for this is still missing (the Makefiles already work fine).


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

Reply via email to