[fpc-pascal] converting a TP/BP library to FPC
waldo kitty
wkitty42 at windstream.net
Thu Dec 6 01:25:20 CET 2012
w2k with FPC 2.6.0 release using lazarus 1.1 only as an editor... no GUI
stuffings at all... i'm using -Mtp in the project options...
i have finally gotten around to trying to convert the old FTN/BBS MKSMG library
to FPC... it was written for DOS TP/BP and has defines for windows which i
assume is the early delphi... this is a first run at this and i'm only working
with a project file that contains all the units in the uses clause...
currently i'm taking the "easiest way out" with "IFDEF FPC" to define within the
"IFDEF WINDOWS" blocks using the DOS format for most things and using the FPC
DOS unit... but i've run into something i don't know how to handle...
Var
TimeCounter: LongInt Absolute $40:$6C;
FPC tells me the following...
MKDOS.PAS(14,36) Fatal: Syntax error, ";" expected but ":" found
i know this is using direct access to the timer ticker from the BIOS but at this
time, i don't know how to best handle it in FPC...
this is not used in the current BBS message base library code that i'm working
with but it is a routine that is used in other portions of the BBS library
code... in the current unit, MKDOS, it is only used in a routine to determine if
there's been a timeout indicating user inactivity for users that were logged
into the bbs... as i say above, this is not a routine used in the message base
code which is currently my main concern in getting ported to FPC...
so how should i handle this?
PS: i saw a notation in some FPC code that Mark May had ported whatever unit i
was looking at to linux and then it was further enhanced by another
individual... i don't know if Mark is still reading these FPC lists or not,
though... i haven't seen anything indicating that the MKSMG sources have been
ported to FPC, either... so i may be "reinventing the wheel" if this work has
already been done... at least i'm getting plenty of practice typing "{$IFDEF
FPC}", "{$ELSE}" and "{$ENDIF FPC}" ;)
PPS: sorry if this is rambling... today is my birthday and i'm also celebrating
that, such as it is -=B-)
More information about the fpc-pascal
mailing list