Predefined constant for compilerdirektives. EXE or DLL

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
User avatar
Josh
Addict
Addict
Posts: 1183
Joined: Sat Feb 13, 2010 3:45 pm

Predefined constant for compilerdirektives. EXE or DLL

Post by Josh »

It would be nice, to have a predefined constant to compare, what my code is compiled. To a EXE or DLL file.

thxs
Josh
sorry for my bad english
User avatar
Danilo
Addict
Addict
Posts: 3036
Joined: Sat Apr 26, 2003 8:26 am
Location: Planet Earth

Re: Predefined constant for compilerdirektives. EXE or DLL

Post by Danilo »

+1

Code: Select all

#PB_Compiler_Target : Determines the target type for which the program is compiling. It can be one of the following:

  - #PB_Target_Gui       : compiling a GUI     application
  - #PB_Target_Console   : compiling a CONSOLE application
  - #PB_Target_Library   : compiling a LIBRARY ( DLL on Windows )
  - #PB_Target_PureLib   : compiling a PB LIBRARY (will it ever be possible without TailBite?)
User avatar
Josh
Addict
Addict
Posts: 1183
Joined: Sat Feb 13, 2010 3:45 pm

Re: Predefined constant for compilerdirektives. EXE or DLL

Post by Josh »

In the meantime i have written a workaround for my problem. I'm using a precompiler and with the parameter %EXECUTABLE it was easy to make my own constants for compilerdirectives.

josh
sorry for my bad english
Post Reply