diff options
author | Daniel Elstner <daniel.kitta@gmail.com> | 2009-09-09 08:02:25 +0200 |
---|---|---|
committer | Daniel Elstner <daniel.kitta@gmail.com> | 2009-09-09 08:02:25 +0200 |
commit | 5261228d9cdd272001582df67a00b18f9d0e63fa (patch) | |
tree | 4b9a281aad773b29c9f75aa5b3f4d5ec58bf3d05 | |
parent | f77f3ee0e514f3195c803bfd774c1b623a8eb534 (diff) | |
download | mm-common-5261228d9cdd272001582df67a00b18f9d0e63fa.tar.gz |
Refine wrap_init.cc and documentation dependencies
* build/compile-binding.am (binding_libprefix): Replace short-hand
substitution $(binding_name:lib%=) with an explicit $(filter) call.
* build/doc-reference.am (doc_dependencies): In maintainer mode, also
depend on Makefile.in in order to trigger a rebuild when the list of
input files changed.
* build/generate-binding.am (binding_stampfiles): Replace short-hand
substitution $(files_hg:%.hg=...) with an explicit $(patsubst) call.
(wrap_init.cc): Make Makefile.in a prerequisite so that the file will
be rebuilt when the list of source files changed.
-rw-r--r-- | build/compile-binding.am | 6 | ||||
-rw-r--r-- | build/doc-reference.am | 6 | ||||
-rw-r--r-- | build/generate-binding.am | 4 |
3 files changed, 9 insertions, 7 deletions
diff --git a/build/compile-binding.am b/build/compile-binding.am index 82a75c5..c8a1e35 100644 --- a/build/compile-binding.am +++ b/build/compile-binding.am @@ -34,14 +34,14 @@ binding_basedir ?= $(patsubst %/,%,$(dir $(subdir))) binding_modulename ?= $(patsubst lib%,$(binding_libprefix)%,$(basename $(lib_LTLIBRARIES))) # Try to work out whether the binding's module name includes a "lib" prefix. -binding_libprefix = $(if $(binding_name:lib%=),,lib) +binding_libprefix = $(if $(filter lib%,$(binding_name)),lib) # Files to be listed in the module's _SOURCES variable. binding_sources = $(files_built_cc) $(files_extra_cc) # Default include directories and preprocessor flags. -binding_includes = -I.. $(if $(srcdir:.=),-I$(top_srcdir)/$(binding_basedir)) -I$(top_builddir) -binding_cppflags = -DG_LOG_DOMAIN=\""$(binding_name)"\" +binding_includes = -I..$(if $(srcdir:.=), -I$(top_srcdir)/$(binding_basedir)) -I$(top_builddir) +binding_cppflags = -DG_LOG_DOMAIN=\"$(binding_name)\" # Installation directories for header files. binding_includedir = $(includedir)/$(binding_modulename)/$(binding_name) diff --git a/build/doc-reference.am b/build/doc-reference.am index ef906e8..7fee59a 100644 --- a/build/doc-reference.am +++ b/build/doc-reference.am @@ -96,20 +96,22 @@ htmlref_patterns_dup = $(foreach file,$(htmlref_patterns),'$(file)' '$(srcdir) htmlref_patterns_vpath = $(if $(srcdir:.=),$(htmlref_patterns_dup),$(htmlref_patterns:%='%')) # Expand to a list of -name 'PATTERN' arguments for use with 'find'. -htmlref_find_patterns = $(patsubst %,-name '%' -o,$(notdir $(htmlref_patterns))) -false +htmlref_find_patterns = $(patsubst %,-name '%' -o,$(notdir $(htmlref_patterns))) -false # The parameters to the Doxygen-to-Devhelp XSLT script dh_xsl_params = --stringparam book_title '$(book_title)' \ --stringparam book_name '$(book_name)' \ --stringparam book_base '$(htmlrefpub:/=)' +doc_config_deps = $(CONFIG_HEADER) $(srcdir)/reference/Doxyfile.in $(srcdir)/Makefile.in + # Regenerate the documentation automatically only in maintainer mode. # Depend on the generated configuration header files to trigger a rebuild # if a configuration value changed. The configuration header files only # have their timestamp modified when the content actually changed, which # is not the case for any other files generated by configure. if MAINTAINER_MODE -doc_dependencies = $(CONFIG_HEADER) $(doc_input) $(srcdir)/reference/Doxyfile.in +doc_dependencies = $(doc_config_deps) $(doc_input) else doc_dependencies = endif diff --git a/build/generate-binding.am b/build/generate-binding.am index be5cd40..12c1296 100644 --- a/build/generate-binding.am +++ b/build/generate-binding.am @@ -40,7 +40,7 @@ binding_stampdir = $(srcdir)/.stamps # Lists of qualified file names relative to the current directory. binding_relfiles_m4 = $(addprefix $(codegen_m4_srcdir)/,$(files_codegen_m4)) binding_relfiles_hg = $(addprefix $(srcdir)/,$(files_hg)) -binding_stampfiles = $(files_hg:%.hg=$(binding_stampdir)/%.stamp) +binding_stampfiles = $(patsubst %.hg,$(binding_stampdir)/%.stamp,$(files_hg)) # Distributed code generation source files. dist_noinst_DATA = $(files_defs) $(files_hg) $(files_ccg) @@ -65,7 +65,7 @@ $(binding_stampdir): $(MKDIR_P) $@ # Generate the wrap_init.cc file using generate_wrap_init.pl. -$(binding_outputdir)/wrap_init.cc: $(binding_relfiles_hg) +$(binding_outputdir)/wrap_init.cc: $(binding_relfiles_hg) $(srcdir)/Makefile.in $(gen_wrap_init) $(wrap_init_flags) $(binding_relfiles_hg) >$@ # Run the gmmproc code generator to produce the C++ binding code. |