X-Git-Url: https://git.llucax.com/software/makeit.git/blobdiff_plain/e34ccce28de7ffcba4bc74e2eb099b53cea14493..c6aa538bed1c5038ccf2215198290a199d7cdbe0:/Makeit.mak?ds=sidebyside diff --git a/Makeit.mak b/Makeit.mak index a687ccd..3cbe089 100644 --- a/Makeit.mak +++ b/Makeit.mak @@ -172,14 +172,21 @@ vexec = $(if $V,printf $(vexec_p) \ # Same as vexec but it silence the echo command (prepending a @ if $V). exec = $V$(call vexec,$1,$2,$3) -# Compile a source file to an object, generating pre-compiled headers and -# dependencies. The pre-compiled headers are generated only if the system -# includes change. This function is designed to be used as a command in a rule. -# The first argument is the type of file to compile (typically "c" or "cpp"). -# What to compile and the output files are built using the automatic variables -# from a rule. The second argument is the base output directory (typically -# $O). You can add non-propagated object-specific flags defining a variable -# with the name of the target followed with ".EXTRA_FLAGS". +# Compile a source file to an object, generating pre-compiled headers (if +# $(GCH) is non-empty) and dependencies. The pre-compiled headers are generated +# only if the system includes change. This function is designed to be used as +# a command in a rule. The first argument is the type of file to compile +# (typically "c" or "cpp"). What to compile and the output files are built +# using the automatic variables from a rule. The second argument is the base +# output directory (typically $O). You can add non-propagated object-specific +# flags defining a variable with the name of the target followed with +# ".EXTRA_FLAGS". +# +# XXX: The pre-compiled headers generation is not very useful if you include +# local files using #include <...>, because the system headers detection +# is a little simplistic now, it just parse the source file and all its +# dependencies searching for lines starting with "#include <" and +# extracting the included files from them. define compile $(if $(GCH),\ $Vif test -f $2/$*.d; then \ @@ -362,20 +369,33 @@ $L/%.pc: $(call replace,$(PC_VARS),$*-PC-) # Run doxygen to build the documentation. It expects the first prerequisite to -# be the Doxyfile to use and the next prerequisites the input files. This rule -# is a little restrictive, but you can always make your own if it doesn't fit -# your needs ;) +# be the Doxyfile to use and the next prerequisites the input files. You +# can override Doxyfile configuration variables by defining a DOXYGEN_VARS +# Make variable for this rule. For example, defining: +# PROJECT_NAME := myproj +# DOXYGEN_VARS := PROJECT_NAME +# You can override Doxygen's PROJECT_NAME configuration option. Optionally, you +# can define DOXYGEN_VARS_PREFIX too, to avoid polluting your Makefile with +# Doxygen variables. For example: +# DOXY.PROJECT_NAME := myproj +# DOXYGEN_VARS_PREFIX := DOXY. +# DOXYGEN_VARS := PROJECT_NAME +# This rule might be still a little restrictive, but you can always make your +# own if it doesn't fit your needs ;) $D/%/doxygen-stamp: $V mkdir -p $(@D) $(call exec,(cat $<; \ echo "FULL_PATH_NAMES=YES"; \ - echo "INPUT=$(patsubst $(