Hi Folks!
SetDate (from unit DOS) is a procedure, which is only available, if "__BP_UNPORTABLE_ROUTINES__" is defined.
The following program does not work:
8<------------------- program foo;
{$define __BP_UNPORTABLE_ROUTINES__} uses DOS;
begin SetDate (2000, 3, 3) end. ------------------->8
Defining __BP_UNPORTABLE_ROUTINES__ on the command line (-D or --define) works well. What do I wrong?
I'm using 2.1 (20020510), based on gcc-2.95.2 19991024 (release)
Eike
Eike Lange wrote:
SetDate (from unit DOS) is a procedure, which is only available, if "__BP_UNPORTABLE_ROUTINES__" is defined.
The following program does not work:
8<------------------- program foo;
{$define __BP_UNPORTABLE_ROUTINES__} uses DOS;
begin SetDate (2000, 3, 3) end. ------------------->8
Defining __BP_UNPORTABLE_ROUTINES__ on the command line (-D or --define) works well. What do I wrong?
Nothing. :-) That's exactly how defines are meant to behave. They only apply to the current program/module/unit. There are several reasons for this, and I could expand on them if desired, but the bottom line is simply, put `-D__BP_UNPORTABLE_ROUTINES__' on the command line or in the Makefile (and make sure that the System unit is recompiled afterwards since automake doesn't (yet) care for defines).
Frank