<span id="goog_801075224"></span><span id="goog_801075225"></span><a href="/"></a>Thanks Ager and Zhirov, the macros work!<div><br></div><div><a href="http://stackoverflow.com/questions/7759667/can-pascal-units-be-compiled-as-executables/7774138#7774138">StackOverflow</a></div>

<div><br></div><div><a href="http://rosettacode.org/wiki/Scripted_main#Free_Pascal">RosettaCode</a><br clear="all"><div><br></div>Cheers,<div><br></div><div>Andrew Pennebaker</div><div><a href="http://www.yellosoft.us" target="_blank">www.yellosoft.us</a></div>


<br><div class="gmail_quote">On Fri, Oct 14, 2011 at 2:33 PM, Vladimir Zhirov <span dir="ltr"><<a href="mailto:vvzh.lists@gmail.com">vvzh.lists@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div class="im">Andrew Pennebaker wrote:<br>
> Thanks, the conditional execution code helps a lot. Does<br>
> $IFDEF look for an environment or Makefile variable?<br>
<br>
</div>No, it looks for previously defined variables. You can define<br>
variables using -dMyVar command line switch when running the<br>
compiler, or {$DEFINE MyVar} in source code. It is possible<br>
to use the first approach in makefiles.<br>
<div><div></div><div class="h5"><br>
_______________________________________________<br>
fpc-pascal maillist  -  <a href="mailto:fpc-pascal@lists.freepascal.org">fpc-pascal@lists.freepascal.org</a><br>
<a href="http://lists.freepascal.org/mailman/listinfo/fpc-pascal" target="_blank">http://lists.freepascal.org/mailman/listinfo/fpc-pascal</a><br>
</div></div></blockquote></div><br></div>