[fpc-devel]Unix changes in 1.1
Marco van de Voort
marcov at stack.nl
Tue Sep 16 17:31:22 CEST 2003
(note: this only applies to the unix platforms)
At the moment I'm rearranging the unix part of the 1.1 RTL. However
currently only cycle works for 1.1, I wait till fixing the building of FCL
and packages till I did some more cleaning up in the 1.1 RTL.
This all will be done in complete and utter incompability with 1.0.x, so
that it is more compatible with C naming and typing.
However for compability, the old linux unit is still somewhat available as
unit "oldlinux". Somewhat, since it is not entirely compatible either.
I advise to use the new 1.1 RTL as much as possible though in your projects.
IFDEF with
{$ifndef VER1_0} ... 1.1+ code [$else} 1.0.x code {$endif} if you have to.
While this may sound slightly negative, it isn't. The idea is to put a
somewhat portable, well designed. layered and clean base unix system as a
fundament for core services inside the RTL.
The rough idea is that unit linux/unix is split up into a lot of units, and
the calls are cleaned up with respect to typing and naming,
To ease (multi architecture in 1.1!) porting and maintenance. However the
1.0.x unit linux will roughly remain around for a while as init oldlinux.
On this moment however oldlinux follows the ERRNO handling of Baseunix,
which is compatible with C. (1.0.x errorhandling is flakey, and works
differently). This will be fixed in the future.
The POSIX (2003) part of the calls currently in linux/uni9x will move to
unit baseunix, have more unixy typing, and in general have a name that is
equal to their C name, prefixed with fp.
The rest remains in principle in unit Unix for now, but will be cleaned up a
bit.
Exceptions:
- the syscalls themselves will change prototype and move to unit syscall
Also their definition changes to a more procedural system,
no more linux specific "syscallreg"
- the x86 calls will move to unit x86. (e.g. port using)
Comments, remarks, flames to me.
More information about the fpc-devel
mailing list