{{fbdoc item="title" value="Compiler Option: -print"}}----
Print out information

{{fbdoc item="syntax"}}##
		""-print"" //option//
##
{{fbdoc item="desc"}}
	The ##-print## option can be used to query the compiler for certain information which may be useful especially for build scripts. It does not prevent compilation of input files given besides the ##-print## option, but the compiler also can be invoked with only a ##-print## option and no input files, in which case it will not compile anything but only respond to the ##-print## option.
	
	Currently, the following -print options are recognized:
	
	{{table columns="2" cellpadding="1" cells="option;effect;fblibdir;Prints the compiler's lib/ path;host;Prints the host system on which fbc is running;target;Prints the target system for which fbc is compiling (can be affected by the -target option);x;Prints the file name of the output executable or library that fbc will or would generate (named after the -x option), depending on other command line options;sha-1;Prints the source code revision sha-1 used to build the compiler, if available"}}

{{fbdoc item="ex"}}
	A [[http://en.wikipedia.org/wiki/Make_(software)|makefile]] could use ##target := $(shell $(FBC) -print target)## to find out the compilation target, which would even work when cross-compiling, with ##FBC## set to something like ##fbc -target foo##.
	
	##fbc -print x## alone will print out the executable file extension for the target system.
	##fbc -print x -dll## on the other hand will print out the dynamic library file name format.
	##fbc -print x -m foo## will print out the executable file name that would be used when compiling a module called foo.bas.
	##fbc 1.bas 2.bas -lib -print x## will compile 1.bas and 2.bas into a library, whose file name will be displayed.

{{fbdoc item="see"}}
	- [[CompilerOptx|-x]]
	- [[CompilerOpttarget|-target]]
	- [[CompilerCmdLine|Using the Command Line]]
	- ##[[KeyPgDdfbbuildsha1|__FB_BUILD_SHA1__]]

{{fbdoc item="back" value="CatPgCompOpt|Compiler Options"}}