From fe278ceca1c21d5a36009e06c0bce0c7b801bc00 Mon Sep 17 00:00:00 2001 From: Andre Maroneze <andre.oliveiramaroneze@cea.fr> Date: Thu, 6 Oct 2016 15:05:20 +0200 Subject: [PATCH] [makefile] avoid spaces before arguments in makefile functions When calling makefile functions, whitespace after commas can lead to unexpected results (especially for the 'call' function, see www.gnu.org/software/make/manual/html_node/Call-Function.html#Call-Function). Some of the changes in this commit are unnecessary, but providing a more uniform style should prevent future bugs similar to #130. --- Makefile | 128 ++++++++++++++++----------------- Makefile.generating | 32 ++++----- share/Makefile.clean | 12 ++-- share/Makefile.dynamic | 10 +-- share/Makefile.plugin.template | 54 +++++++------- 5 files changed, 118 insertions(+), 118 deletions(-) diff --git a/Makefile b/Makefile index 7afa65bccea..4719f461976 100644 --- a/Makefile +++ b/Makefile @@ -105,9 +105,9 @@ DOC_DIR = doc/code MODULES_TODOC= # Directories to include when compiling -INCLUDES=$(addprefix -I , $(FRAMAC_SRC_DIRS)) -I $(PLUGIN_LIB_DIR) +INCLUDES=$(addprefix -I ,$(FRAMAC_SRC_DIRS)) -I $(PLUGIN_LIB_DIR) ifneq ($(ENABLE_GUI),no) -GUI_INCLUDES = $(addprefix -package , $(LIBRARY_NAMES_GUI)) +GUI_INCLUDES = $(addprefix -package ,$(LIBRARY_NAMES_GUI)) else GUI_INCLUDES = endif @@ -138,7 +138,7 @@ OPT_LIBS = $(EXTRA_OPT_LIBS) OPT_LIBS+= $(GEN_OPT_LIBS) -ICONS:= $(addprefix share/, \ +ICONS:= $(addprefix share/,\ frama-c.ico frama-c.png unmark.png \ switch-on.png switch-off.png ) @@ -156,26 +156,26 @@ FEEDBACK_ICONS_NAMES:= \ inconsistent.png FEEDBACK_ICONS_DEFAULT:= \ - $(addprefix share/theme/default/, $(FEEDBACK_ICONS_NAMES)) + $(addprefix share/theme/default/,$(FEEDBACK_ICONS_NAMES)) FEEDBACK_ICONS_COLORBLIND:= \ - $(addprefix share/theme/colorblind/, $(FEEDBACK_ICONS_NAMES)) + $(addprefix share/theme/colorblind/,$(FEEDBACK_ICONS_NAMES)) ROOT_LIBC_DIR:= share/libc LIBC_SUBDIRS:= sys netinet linux net arpa -LIBC_DIR:= $(ROOT_LIBC_DIR) $(addprefix $(ROOT_LIBC_DIR)/, $(LIBC_SUBDIRS)) +LIBC_DIR:= $(ROOT_LIBC_DIR) $(addprefix $(ROOT_LIBC_DIR)/,$(LIBC_SUBDIRS)) LIBC_FILES:= \ $(wildcard share/*.h share/*.c) \ - $(wildcard $(addsuffix /*.h, $(LIBC_DIR))) \ - $(wildcard $(addsuffix /*.c, $(LIBC_DIR))) \ + $(wildcard $(addsuffix /*.h,$(LIBC_DIR))) \ + $(wildcard $(addsuffix /*.c,$(LIBC_DIR))) \ $(ROOT_LIBC_DIR)/__fc_builtin_for_normalization.i # Checks that all .h can be included multiple times. -ALL_LIBC_HEADERS:=$(wildcard share/*.h $(addsuffix /*.h, $(LIBC_DIR))) +ALL_LIBC_HEADERS:=$(wildcard share/*.h $(addsuffix /*.h,$(LIBC_DIR))) check-libc: bin/toplevel.$(OCAMLBEST)$(EXE) @echo "checking libc..."; \ EXIT_VALUE=0; \ - for file in $(filter-out share/builtin.h, $(ALL_LIBC_HEADERS)); do \ + for file in $(filter-out share/builtin.h,$(ALL_LIBC_HEADERS)); do \ echo "#include \"$$file\"" > check-libc.c; \ echo "#include \"$$file\"" >> check-libc.c; \ FRAMAC_SHARE=share bin/toplevel.$(OCAMLBEST)$(EXE) \ @@ -218,7 +218,7 @@ DISTRIB_FILES:=\ doc/code/toc_head.htm \ doc/code/toc_tail.htm \ doc/Makefile \ - $(filter-out ptests/ptests_config.ml, $(wildcard ptests/*.ml*)) \ + $(filter-out ptests/ptests_config.ml,$(wildcard ptests/*.ml*)) \ configure.in Makefile Makefile.generating \ Changelog config.h.in \ VERSION $(wildcard licenses/*) \ @@ -258,11 +258,11 @@ DISTRIB_FILES:=\ opam/opam opam/descr opam/frama-c/opam opam/frama-c/descr \ opam/files/run_autoconf_if_needed.sh -DISTRIB_TESTS=$(filter-out tests/non-free/%, $(shell git ls-files tests src/plugins/aorai/tests src/plugins/report/tests src/plugins/wp/tests)) +DISTRIB_TESTS=$(filter-out tests/non-free/%,$(shell git ls-files tests src/plugins/aorai/tests src/plugins/report/tests src/plugins/wp/tests)) # files that are needed to compile API documentation of external plugins -DOC_GEN_FILES:=$(addprefix doc/code/, \ +DOC_GEN_FILES:=$(addprefix doc/code/,\ *.css intro_plugin.txt intro_kernel_plugin.txt \ intro_plugin_default.txt intro_plugin_D_and_S \ kernel-doc.ocamldoc \ @@ -467,7 +467,7 @@ LIB_CMO+=\ GENERATED+= src/libraries/utils/json.ml -LIB_CMO:= $(addsuffix .cmo, $(LIB_CMO)) +LIB_CMO:= $(addsuffix .cmo,$(LIB_CMO)) CMO += $(LIB_CMO) # Very first files to be linked (most modules use them) @@ -485,7 +485,7 @@ FIRST_CMO= src/kernel_internals/runtime/config \ # datatype requires project_skeleton # rangemap requires datatype -FIRST_CMO:= $(addsuffix .cmo, $(FIRST_CMO)) +FIRST_CMO:= $(addsuffix .cmo,$(FIRST_CMO)) CMO += $(FIRST_CMO) #Project (Project_skeleton must be linked before Journal) @@ -496,7 +496,7 @@ PROJECT_CMO= \ state_selection \ project \ state_builder -PROJECT_CMO:= $(patsubst %, src/libraries/project/%.cmo, $(PROJECT_CMO)) +PROJECT_CMO:= $(patsubst %,src/libraries/project/%.cmo,$(PROJECT_CMO)) CMO += $(PROJECT_CMO) # kernel @@ -640,7 +640,7 @@ MODULES_NODOC+= src/kernel_internals/runtime/machdep_ppc_32.ml \ src/kernel_internals/runtime/machdep_x86_32.ml \ src/kernel_internals/runtime/machdep_x86_64.ml -GENERATED += $(addprefix src/kernel_internals/parsing/, \ +GENERATED += $(addprefix src/kernel_internals/parsing/,\ clexer.ml cparser.ml cparser.mli \ logic_lexer.ml logic_parser.ml \ logic_parser.mli logic_preprocess.ml) @@ -659,7 +659,7 @@ GEN_OPT_LIBS+= $(GEN_C_BINDINGS) src/libraries/utils/c_bindings.o: src/libraries/utils/c_bindings.c $(PRINT_CC) $@ - $(CC) $(GEN_C_BINDINGS_FLAGS) -c -I$(call winpath, $(OCAMLLIB)) -O3 -Wall -o $@ $< + $(CC) $(GEN_C_BINDINGS_FLAGS) -c -I$(call winpath,$(OCAMLLIB)) -O3 -Wall -o $@ $< # Common startup module # All link command should add it as last linked module and depend on it. @@ -691,7 +691,7 @@ SINGLE_GUI_CMO:= \ help_manager \ property_navigator -SINGLE_GUI_CMO:= $(patsubst %, src/plugins/gui/%.cmo, $(SINGLE_GUI_CMO)) +SINGLE_GUI_CMO:= $(patsubst %,src/plugins/gui/%.cmo,$(SINGLE_GUI_CMO)) ############################################################################### # # @@ -812,10 +812,10 @@ VALUE_GUI_AUX:=gui_files/gui_types gui_files/gui_eval gui_files/gui_callstacks_f PLUGIN_GUI_CMO:=$(VALUE_GUI_AUX) gui_files/register_gui PLUGIN_NO_TEST:=yes PLUGIN_DISTRIBUTED:=yes -VALUE_TYPES:=$(addprefix src/plugins/value_types/, \ +VALUE_TYPES:=$(addprefix src/plugins/value_types/,\ cilE cvalue precise_locs value_types widen_type) PLUGIN_TYPES_CMO:=$(VALUE_TYPES) -PLUGIN_TYPES_TODOC:=$(addsuffix .mli, $(VALUE_TYPES)) +PLUGIN_TYPES_TODOC:=$(addsuffix .mli,$(VALUE_TYPES)) $(eval $(call include_generic_plugin_Makefile,$(PLUGIN_NAME))) @@ -865,7 +865,7 @@ PLUGIN_DISTRIBUTED:=yes PLUGIN_INTERNAL_TEST:=yes FROM_TYPES:=src/plugins/value_types/function_Froms PLUGIN_TYPES_CMO:=$(FROM_TYPES) -PLUGIN_TYPES_TODOC:=$(addsuffix .mli, $(FROM_TYPES)) +PLUGIN_TYPES_TODOC:=$(addsuffix .mli,$(FROM_TYPES)) PLUGIN_DEPENDENCIES:=Callgraph Value $(eval $(call include_generic_plugin_Makefile,$(PLUGIN_NAME))) @@ -931,7 +931,7 @@ PLUGIN_DISTRIBUTED:=yes PLUGIN_INTERNAL_TEST:=yes INOUT_TYPES:=src/plugins/value_types/inout_type PLUGIN_TYPES_CMO:=$(INOUT_TYPES) -PLUGIN_TYPES_TODOC:=$(addsuffix .mli, $(INOUT_TYPES)) +PLUGIN_TYPES_TODOC:=$(addsuffix .mli,$(INOUT_TYPES)) PLUGIN_DEPENDENCIES:=Callgraph Value $(eval $(call include_generic_plugin_Makefile,$(PLUGIN_NAME))) @@ -971,11 +971,11 @@ PLUGIN_CMO:= pdg_parameters \ register PDG_TYPES:=pdgIndex pdgTypes pdgMarks -PDG_TYPES:=$(addprefix src/plugins/pdg_types/, $(PDG_TYPES)) +PDG_TYPES:=$(addprefix src/plugins/pdg_types/,$(PDG_TYPES)) PLUGIN_TYPES_CMO:=$(PDG_TYPES) PLUGIN_INTRO:=doc/code/intro_pdg.txt -PLUGIN_TYPES_TODOC:=$(addsuffix .mli, $(PDG_TYPES)) +PLUGIN_TYPES_TODOC:=$(addsuffix .mli,$(PDG_TYPES)) PLUGIN_DEPENDENCIES:=Callgraph Value PLUGIN_DISTRIBUTED:=yes PLUGIN_INTERNAL_TEST:=yes @@ -1033,13 +1033,13 @@ PLUGIN_CMO:= slicingParameters \ slicingCmds \ register SLICING_TYPES:=slicingInternals slicingTypes -SLICING_TYPES:=$(addprefix src/plugins/slicing_types/, $(SLICING_TYPES)) +SLICING_TYPES:=$(addprefix src/plugins/slicing_types/,$(SLICING_TYPES)) PLUGIN_TYPES_CMO:=$(SLICING_TYPES) PLUGIN_GUI_CMO:=register_gui PLUGIN_INTRO:=doc/code/intro_slicing.txt -PLUGIN_TYPES_TODOC:= $(addsuffix .ml, $(SLICING_TYPES)) +PLUGIN_TYPES_TODOC:= $(addsuffix .ml,$(SLICING_TYPES)) PLUGIN_UNDOC:=register.ml # slicing_gui.ml PLUGIN_TESTS_DIRS:= slicing @@ -1069,7 +1069,7 @@ PLUGIN_DIR:=$(1) include $(1)/Makefile endef -$(foreach p, $(EXTERNAL_PLUGINS), $(eval $(call INCLUDE_PLUGIN,$p))) +$(foreach p,$(EXTERNAL_PLUGINS),$(eval $(call INCLUDE_PLUGIN,$p))) ############################################################################### # # @@ -1089,24 +1089,24 @@ CMI = $(CMO:.cmo=.cmi) ALL_CMO = $(CMO) $(PLUGIN_CMO_LIST) $(STARTUP_CMO) ALL_CMX = $(CMX) $(PLUGIN_CMX_LIST) $(STARTUP_CMX) -FILES_FOR_OCAMLDEP+= $(addsuffix /*.mli, $(FRAMAC_SRC_DIRS)) \ - $(addsuffix /*.ml, $(FRAMAC_SRC_DIRS)) +FILES_FOR_OCAMLDEP+= $(addsuffix /*.mli,$(FRAMAC_SRC_DIRS)) \ + $(addsuffix /*.ml,$(FRAMAC_SRC_DIRS)) -MODULES_TODOC+=$(filter-out $(MODULES_NODOC), \ +MODULES_TODOC+=$(filter-out $(MODULES_NODOC),\ $(MLI_ONLY) $(NO_MLI:.mli=.ml) \ - $(filter-out $(NO_MLI), \ - $(filter-out $(PLUGIN_TYPES_CMO_LIST:.cmo=.mli), $(CMO:.cmo=.mli)))) + $(filter-out $(NO_MLI),\ + $(filter-out $(PLUGIN_TYPES_CMO_LIST:.cmo=.mli),$(CMO:.cmo=.mli)))) ################################ # toplevel.{byte,opt} binaries # ################################ -ALL_BATCH_CMO= $(filter-out src/kernel_internals/runtime/gui_init.cmo, \ +ALL_BATCH_CMO= $(filter-out src/kernel_internals/runtime/gui_init.cmo,\ $(ALL_CMO)) # ALL_BATCH_CMX is not a translation of ALL_BATCH_CMO with cmo -> cmx # in case native dynlink is not available: dynamic plugin are linked # dynamically in bytecode and statically in native code... -ALL_BATCH_CMX= $(filter-out src/kernel_internals/runtime/gui_init.cmx, \ +ALL_BATCH_CMX= $(filter-out src/kernel_internals/runtime/gui_init.cmx,\ $(ALL_CMX)) bin/toplevel.byte$(EXE): $(ALL_BATCH_CMO) $(GEN_BYTE_LIBS) \ @@ -1129,7 +1129,7 @@ bin/toplevel.opt$(EXE): $(ALL_BATCH_CMX) $(GEN_OPT_LIBS) \ # (Ocaml) Toplevel # #################### -bin/toplevel.top$(EXE): $(filter-out src/kernel_internals/runtime/boot.ml, $(ALL_BATCH_CMO)) \ +bin/toplevel.top$(EXE): $(filter-out src/kernel_internals/runtime/boot.ml,$(ALL_BATCH_CMO)) \ src/kernel_internals/runtime/toplevel_config.cmo \ $(GEN_BYTE_LIBS) $(PLUGIN_DYN_CMO_LIST) $(PRINT_OCAMLMKTOP) $@ @@ -1148,7 +1148,7 @@ SINGLE_GUI_CMX = $(SINGLE_GUI_CMO:.cmo=.cmx) GUICMO += $(SINGLE_GUI_CMO) $(PLUGIN_GUI_CMO_LIST) -MODULES_TODOC+= $(filter-out src/plugins/gui/book_manager.mli, \ +MODULES_TODOC+= $(filter-out src/plugins/gui/book_manager.mli,\ $(SINGLE_GUI_CMO:.cmo=.mli)) GUICMI = $(GUICMO:.cmo=.cmi) @@ -1172,23 +1172,23 @@ gui:: bin/viewer.opt$(EXE) endif ALL_GUI_CMO= $(ALL_CMO) $(GRAPH_GUICMO) $(GUICMO) -ALL_GUI_CMX= $(patsubst %.cma, %.cmxa, $(ALL_GUI_CMO:.cmo=.cmx)) +ALL_GUI_CMX= $(patsubst %.cma,%.cmxa,$(ALL_GUI_CMO:.cmo=.cmx)) bin/viewer.byte$(EXE): BYTE_LIBS+= $(GRAPH_GUICMO) -bin/viewer.byte$(EXE): $(filter-out $(GRAPH_GUICMO), $(ALL_GUI_CMO)) \ +bin/viewer.byte$(EXE): $(filter-out $(GRAPH_GUICMO),$(ALL_GUI_CMO)) \ $(GEN_BYTE_LIBS) \ $(PLUGIN_DYN_CMO_LIST) $(PLUGIN_DYN_GUI_CMO_LIST) $(PRINT_LINKING) $@ $(OCAMLC) $(BLINKFLAGS) -o $@ $(BYTE_LIBS) \ $(CMO) \ $(filter-out \ - $(patsubst $(PLUGIN_GUI_LIB_DIR)/%, $(PLUGIN_LIB_DIR)/%, \ - $(PLUGIN_GUI_CMO_LIST)), \ + $(patsubst $(PLUGIN_GUI_LIB_DIR)/%,$(PLUGIN_LIB_DIR)/%,\ + $(PLUGIN_GUI_CMO_LIST)),\ $(PLUGIN_CMO_LIST)) \ $(GUICMO) $(STARTUP_CMO) bin/viewer.opt$(EXE): OPT_LIBS+= $(GRAPH_GUICMX) -bin/viewer.opt$(EXE): $(filter-out $(GRAPH_GUICMX), $(ALL_GUI_CMX)) \ +bin/viewer.opt$(EXE): $(filter-out $(GRAPH_GUICMX),$(ALL_GUI_CMX)) \ $(GEN_OPT_LIBS) \ $(PLUGIN_DYN_CMX_LIST) $(PLUGIN_DYN_GUI_CMX_LIST) \ $(PLUGIN_CMX_LIST) $(PLUGIN_GUI_CMX_LIST) @@ -1196,8 +1196,8 @@ bin/viewer.opt$(EXE): $(filter-out $(GRAPH_GUICMX), $(ALL_GUI_CMX)) \ $(OCAMLOPT) $(OLINKFLAGS) -o $@ $(OPT_LIBS) \ $(CMX) \ $(filter-out \ - $(patsubst $(PLUGIN_GUI_LIB_DIR)/%, $(PLUGIN_LIB_DIR)/%, \ - $(PLUGIN_GUI_CMX_LIST)), \ + $(patsubst $(PLUGIN_GUI_LIB_DIR)/%,$(PLUGIN_LIB_DIR)/%,\ + $(PLUGIN_GUI_CMX_LIST)),\ $(PLUGIN_CMX_LIST)) \ $(GUICMX) $(STARTUP_CMX) endif @@ -1372,9 +1372,9 @@ clean-doc:: DOC_NOT_FOR_DISTRIB=yes plugins-doc: $(QUIET_MAKE) \ - $(if $(DOC_NOT_FOR_DISTRIB), $(PLUGIN_DOC_LIST), \ + $(if $(DOC_NOT_FOR_DISTRIB),$(PLUGIN_DOC_LIST),\ $(filter \ - $(addsuffix _DOC, $(PLUGIN_DISTRIBUTED_NAME_LIST)), \ + $(addsuffix _DOC,$(PLUGIN_DISTRIBUTED_NAME_LIST)),\ $(PLUGIN_DOC_LIST))) # to make the documentation for one plugin only, @@ -1405,7 +1405,7 @@ STDLIB_FILES:=\ string \ sys -STDLIB_FILES:=$(patsubst %, $(OCAMLLIB)/%.mli, $(STDLIB_FILES)) +STDLIB_FILES:=$(patsubst %,$(OCAMLLIB)/%.mli,$(STDLIB_FILES)) .PHONY: doc-kernel doc-kernel: $(DOC_DIR)/kernel-doc.ocamldoc @@ -1415,7 +1415,7 @@ $(DOC_DIR)/kernel-doc.ocamldoc: $(DOC_DEPEND) $(MKDIR) $(DOC_DIR)/html $(RM) $(DOC_DIR)/html/*.html $(OCAMLDOC) $(DOC_FLAGS) \ - $(addprefix -passopt -stdlib , $(STDLIB_FILES)) \ + $(addprefix -passopt -stdlib ,$(STDLIB_FILES)) \ -t "Frama-C Kernel" \ -sort -css-style ../style.css \ -g $(DOC_PLUGIN) \ @@ -1433,7 +1433,7 @@ DYN_MLI_DIR := src/plugins/print_api doc-dynamic: doc-kernel $(RM) $(DYN_MLI_DIR)/dynamic_plugins.mli ./bin/frama-c.byte \ - -print_api $(call winpath, $(FRAMAC_ROOT_SRCDIR)/$(DYN_MLI_DIR)) + -print_api $(call winpath,$(FRAMAC_ROOT_SRCDIR)/$(DYN_MLI_DIR)) $(PRINT_DOC) Dynamically registered plugins Documentation $(MKDIR) $(DOC_DIR)/dynamic_plugins $(RM) $(DOC_DIR)/dynamic_plugins/*.html @@ -1465,7 +1465,7 @@ doc-tgz: $(notdir $(wildcard $(DOC_DIR)/*.css $(DOC_DIR)/*.png \ $(DOC_DIR)/dynamic_plugins*)) \ html \ - $(foreach p, $(PLUGIN_DISTRIBUTED_NAME_LIST), \ + $(foreach p,$(PLUGIN_DISTRIBUTED_NAME_LIST),\ $(notdir $($(p)_DOC_DIR))) $(MKDIR) frama-c-api $(RM) -r frama-c-api/* @@ -1530,12 +1530,12 @@ check-devguide: $(CHECK_CODE) $(DOC_DEPEND) $(DOC_DIR)/kernel-doc.ocamldoc # line below does not work if INCLUDES contains twice the same directory # Do not attempt to copy gui interfaces if gui is disabled #Byte -ALL_BATCH_CMO_FIXED=$(filter-out src/kernel_internals/runtime/gui_init.cmo, $(CMO) $(STARTUP_CMO)) +ALL_BATCH_CMO_FIXED=$(filter-out src/kernel_internals/runtime/gui_init.cmo,$(CMO) $(STARTUP_CMO)) LIB_BYTE_TO_INSTALL=\ $(MLI_ONLY:.mli=.cmi) \ $(ALL_BATCH_CMO_FIXED:.cmo=.cmi) \ $(ALL_BATCH_CMO_FIXED) \ - $(filter-out %.o, $(GEN_BYTE_LIBS:.cmo=.cmi)) \ + $(filter-out %.o,$(GEN_BYTE_LIBS:.cmo=.cmi)) \ $(GEN_BYTE_LIBS) #Byte GUI @@ -1545,14 +1545,14 @@ endif #Opt ifeq ("$(OCAMLBEST)","opt") -ALL_BATCH_CMX_FIXED= $(filter-out src/kernel_internals/runtime/gui_init.cmx, \ +ALL_BATCH_CMX_FIXED= $(filter-out src/kernel_internals/runtime/gui_init.cmx,\ $(CMX) $(STARTUP_CMX)) LIB_OPT_TO_INSTALL +=\ $(ALL_BATCH_CMX) \ $(filter %.a,$(ALL_BATCH_CMX_FIXED:.cmxa=.a)) \ $(filter %.o,$(ALL_BATCH_CMX_FIXED:.cmx=.o)) \ - $(filter-out %.o, $(GEN_OPT_LIBS)) \ - $(filter-out $(GEN_BYTE_LIBS), $(filter %.o,$(GEN_OPT_LIBS:.cmx=.o))) + $(filter-out %.o,$(GEN_OPT_LIBS)) \ + $(filter-out $(GEN_BYTE_LIBS),$(filter %.o,$(GEN_OPT_LIBS:.cmx=.o))) #Opt GUI ifneq ("$(ENABLE_GUI)","no") @@ -1729,9 +1729,9 @@ check-headers: $(HDRCK) # for make 4.0+, using the 'file' function could be a better solution, # although it seems to segfault in 4.0 (but not in 4.1) $(RM) file_list_to_check.tmp - @$(foreach file, $(DISTRIB_FILES),\ + @$(foreach file,$(DISTRIB_FILES),\ echo $(file) >> file_list_to_check.tmp$(NEWLINE)) - @$(foreach file, $(HEADER_EXCEPTIONS),\ + @$(foreach file,$(HEADER_EXCEPTIONS),\ echo $(file) >> file_list_exceptions.tmp$(NEWLINE)) $(HDRCK) \ @@ -1945,8 +1945,8 @@ GENERATED+=ptests/ptests_config.ml tests/ptests_config .PHONY: src-distrib bin-distrib STANDALONE_PLUGINS_FILES = \ - $(addprefix src/dummy/hello_world/, hello_world.ml Makefile) \ - $(addprefix src/dummy/untyped_metrics/, count_for.ml Makefile) + $(addprefix src/dummy/hello_world/,hello_world.ml Makefile) \ + $(addprefix src/dummy/untyped_metrics/,count_for.ml Makefile) DISTRIB_FILES += $(wildcard $(PLUGIN_DISTRIBUTED_LIST) \ $(PLUGIN_DIST_EXTERNAL_LIST) \ @@ -1964,7 +1964,7 @@ else DISTRIB_HEADERS:=open-source # files that can be distributed DISTRIB_FILES := $(filter-out \ - src/plugins/value/domains/cvalue/builtins_nonfree%, \ + src/plugins/value/domains/cvalue/builtins_nonfree%,\ $(DISTRIB_FILES)) # files excluded to the final tarball DISTRIB_EXCLUDE=--exclude \"*/non-free/*\" @@ -1972,7 +1972,7 @@ DISTRIB_EXCLUDE=--exclude \"*/non-free/*\" DISTRIB_PROPRIETARY_HEADERS = --no-headers CEA_PROPRIETARY endif -DISTRIB_FILES:=$(filter-out $(GENERATED) $(PLUGIN_GENERATED_LIST), \ +DISTRIB_FILES:=$(filter-out $(GENERATED) $(PLUGIN_GENERATED_LIST),\ $(DISTRIB_FILES)) # Variables governing the name of the generated .tar.gz. @@ -2071,7 +2071,7 @@ byte:: bin/toplevel.byte$(EXE) \ opt:: bin/toplevel.opt$(EXE) \ share/Makefile.dynamic_config share/Makefile.kernel \ $(call create_lib_to_install_list,$(LIB_OPT_TO_INSTALL)) \ - $(filter %.o %.cmi, \ + $(filter %.o %.cmi,\ $(call create_lib_to_install_list,$(LIB_BYTE_TO_INSTALL))) \ $(PLUGIN_META_LIST) @@ -2089,8 +2089,8 @@ $(FRAMAC_LIB)/$(notdir $(1)): $(1) $(CP) $$< $$@ endef -$(eval $(foreach file, $(LIB_BYTE_TO_INSTALL), $(call copy_in_lib, $(file)))) -$(eval $(foreach file, $(LIB_OPT_TO_INSTALL), $(call copy_in_lib, $(file)))) +$(eval $(foreach file,$(LIB_BYTE_TO_INSTALL),$(call copy_in_lib,$(file)))) +$(eval $(foreach file,$(LIB_OPT_TO_INSTALL),$(call copy_in_lib,$(file)))) ################ # Generic part # diff --git a/Makefile.generating b/Makefile.generating index 15d45bc4501..4bb84658c1e 100644 --- a/Makefile.generating +++ b/Makefile.generating @@ -50,23 +50,23 @@ share/Makefile.kernel: Makefile.generating share/Makefile.config share/Makefile. $(ECHO) "# This makefile was automatically generated." > $@ $(ECHO) "# Do not modify." >> $@ $(ECHO) "ifeq (\$$(FRAMAC_INTERNAL),yes)" >> $@ - $(ECHO) "DYN_BLINKFLAGS=$(filter-out $(INCLUDES), $(BLINKFLAGS)) $(foreach d, $(INCLUDES:-I%=%), -I $(FRAMAC_ROOT_SRCDIR)/$(d))" >> $@ - $(ECHO) "DYN_GEN_BYTE_LIBS=$(addprefix $(FRAMAC_ROOT_SRCDIR)/, $(GEN_BYTE_LIBS))" >> $@ - $(ECHO) "DYN_BYTE_LIBS=$(filter-out $(GEN_BYTE_LIBS), $(BYTE_LIBS))" >> $@ - $(ECHO) "DYN_ALL_BATCH_CMO=$(addprefix $(FRAMAC_ROOT_SRCDIR)/, $(notdir $(ALL_BATCH_CMO)))" >> $@ - $(ECHO) "DYN_OLINKFLAGS=$(filter-out $(INCLUDES), $(OLINKFLAGS)) $(foreach d, $(INCLUDES:-I%=%), -I $(FRAMAC_ROOT_SRCDIR)/$(d))" >> $@ - $(ECHO) "DYN_GEN_OPT_LIBS=$(addprefix $(FRAMAC_ROOT_SRCDIR)/, $(GEN_OPT_LIBS))" >> $@ - $(ECHO) "DYN_OPT_LIBS=$(filter-out $(GEN_OPT_LIBS), $(OPT_LIBS))" >> $@ - $(ECHO) "DYN_ALL_BATCH_CMX=$(addprefix $(FRAMAC_ROOT_SRCDIR)/, $(ALL_BATCH_CMX))" >> $@ + $(ECHO) "DYN_BLINKFLAGS=$(filter-out $(INCLUDES),$(BLINKFLAGS)) $(foreach d,$(INCLUDES:-I%=%),-I $(FRAMAC_ROOT_SRCDIR)/$(d))" >> $@ + $(ECHO) "DYN_GEN_BYTE_LIBS=$(addprefix $(FRAMAC_ROOT_SRCDIR)/,$(GEN_BYTE_LIBS))" >> $@ + $(ECHO) "DYN_BYTE_LIBS=$(filter-out $(GEN_BYTE_LIBS),$(BYTE_LIBS))" >> $@ + $(ECHO) "DYN_ALL_BATCH_CMO=$(addprefix $(FRAMAC_ROOT_SRCDIR)/,$(notdir $(ALL_BATCH_CMO)))" >> $@ + $(ECHO) "DYN_OLINKFLAGS=$(filter-out $(INCLUDES),$(OLINKFLAGS)) $(foreach d,$(INCLUDES:-I%=%),-I $(FRAMAC_ROOT_SRCDIR)/$(d))" >> $@ + $(ECHO) "DYN_GEN_OPT_LIBS=$(addprefix $(FRAMAC_ROOT_SRCDIR)/,$(GEN_OPT_LIBS))" >> $@ + $(ECHO) "DYN_OPT_LIBS=$(filter-out $(GEN_OPT_LIBS),$(OPT_LIBS))" >> $@ + $(ECHO) "DYN_ALL_BATCH_CMX=$(addprefix $(FRAMAC_ROOT_SRCDIR)/,$(ALL_BATCH_CMX))" >> $@ $(ECHO) "else" >> $@ - $(ECHO) "DYN_BLINKFLAGS=$(filter-out $(INCLUDES), $(BLINKFLAGS)) $(addprefix -I ,$(filter +%,$(INCLUDES)))" >> $@ - $(ECHO) "DYN_GEN_BYTE_LIBS=$(addprefix $(FRAMAC_LIBDIR)/, $(notdir $(GEN_BYTE_LIBS)))" >> $@ - $(ECHO) "DYN_BYTE_LIBS=$(filter-out $(GEN_BYTE_LIBS), $(BYTE_LIBS))" >> $@ - $(ECHO) "DYN_ALL_BATCH_CMO=$(addprefix $(FRAMAC_LIBDIR)/, $(notdir $(ALL_BATCH_CMO)))" >> $@ - $(ECHO) "DYN_OLINKFLAGS=$(filter-out $(INCLUDES), $(OLINKFLAGS)) $(addprefix -I ,$(filter +%,$(INCLUDES)))" >> $@ - $(ECHO) "DYN_GEN_OPT_LIBS=$(addprefix $(FRAMAC_LIBDIR)/, $(notdir $(GEN_OPT_LIBS)))" >> $@ - $(ECHO) "DYN_OPT_LIBS=$(filter-out $(GEN_OPT_LIBS), $(OPT_LIBS))" >> $@ - $(ECHO) "DYN_ALL_BATCH_CMX=$(addprefix $(FRAMAC_LIBDIR)/, $(notdir $(ALL_BATCH_CMX)))" >> $@ + $(ECHO) "DYN_BLINKFLAGS=$(filter-out $(INCLUDES),$(BLINKFLAGS)) $(addprefix -I ,$(filter +%,$(INCLUDES)))" >> $@ + $(ECHO) "DYN_GEN_BYTE_LIBS=$(addprefix $(FRAMAC_LIBDIR)/,$(notdir $(GEN_BYTE_LIBS)))" >> $@ + $(ECHO) "DYN_BYTE_LIBS=$(filter-out $(GEN_BYTE_LIBS),$(BYTE_LIBS))" >> $@ + $(ECHO) "DYN_ALL_BATCH_CMO=$(addprefix $(FRAMAC_LIBDIR)/,$(notdir $(ALL_BATCH_CMO)))" >> $@ + $(ECHO) "DYN_OLINKFLAGS=$(filter-out $(INCLUDES),$(OLINKFLAGS)) $(addprefix -I ,$(filter +%,$(INCLUDES)))" >> $@ + $(ECHO) "DYN_GEN_OPT_LIBS=$(addprefix $(FRAMAC_LIBDIR)/,$(notdir $(GEN_OPT_LIBS)))" >> $@ + $(ECHO) "DYN_OPT_LIBS=$(filter-out $(GEN_OPT_LIBS),$(OPT_LIBS))" >> $@ + $(ECHO) "DYN_ALL_BATCH_CMX=$(addprefix $(FRAMAC_LIBDIR)/,$(notdir $(ALL_BATCH_CMX)))" >> $@ $(ECHO) "endif" >> $@ $(CHMOD_RO) $@ diff --git a/share/Makefile.clean b/share/Makefile.clean index 361f34b1f3b..6dcc204c38f 100644 --- a/share/Makefile.clean +++ b/share/Makefile.clean @@ -36,27 +36,27 @@ O_NO_SOURCE := src/libraries/utils/c_bindings ML_SOURCE := $(SOURCES) $(ML_NO_SOURCE) O_SOURCE := $(ML_SOURCE) $(O_NO_SOURCE) -CMO_SOURCE := $(addsuffix .cmo, $(ML_SOURCE)) +CMO_SOURCE := $(addsuffix .cmo,$(ML_SOURCE)) CMO_FOUND := $(shell find $(PATHS) -name '*.cmo') CMO_SPURIOUS := $(filter-out $(CMO_SOURCE),$(CMO_FOUND)) -CMI_SOURCE := $(addsuffix .cmi, $(ML_SOURCE)) +CMI_SOURCE := $(addsuffix .cmi,$(ML_SOURCE)) CMI_FOUND := $(shell find $(PATHS) -name '*.cmi') CMI_SPURIOUS := $(filter-out $(CMI_SOURCE),$(CMI_FOUND)) -CMX_SOURCE := $(addsuffix .cmx, $(ML_SOURCE)) +CMX_SOURCE := $(addsuffix .cmx,$(ML_SOURCE)) CMX_FOUND := $(shell find $(PATHS) -name '*.cmx') CMX_SPURIOUS := $(filter-out $(CMX_SOURCE),$(CMX_FOUND)) -CMXS_SOURCE := $(addsuffix .cmxs, $(ML_SOURCE)) +CMXS_SOURCE := $(addsuffix .cmxs,$(ML_SOURCE)) CMXS_FOUND := $(shell find $(PATHS) -name '*.cmxs') CMXS_SPURIOUS := $(filter-out $(CMXS_SOURCE),$(CMXS_FOUND)) -O_SOURCE := $(addsuffix .o, $(O_SOURCE)) +O_SOURCE := $(addsuffix .o,$(O_SOURCE)) O_FOUND := $(shell find $(PATHS) -name '*.o') O_SPURIOUS := $(filter-out $(O_SOURCE),$(O_FOUND)) -CMT_SOURCE := $(addsuffix .cmt, $(ML_SOURCE)) $(addsuffix .cmti, $(ML_SOURCE)) +CMT_SOURCE := $(addsuffix .cmt,$(ML_SOURCE)) $(addsuffix .cmti,$(ML_SOURCE)) CMT_FOUND := $(shell find $(PATHS) -name '*.cmt' -or -name '*.cmti') CMT_SPURIOUS := $(filter-out $(CMT_SOURCE),$(CMT_FOUND)) diff --git a/share/Makefile.dynamic b/share/Makefile.dynamic index f604625ea5d..96552203d29 100644 --- a/share/Makefile.dynamic +++ b/share/Makefile.dynamic @@ -94,7 +94,7 @@ endif $(PLUGIN_NAME)_INSTALL_DOC: plugin-doc/$(PLUGIN_NAME) $(PRINT_CP) $(patsubst %_INSTALL_DOC,%,$@) Documentation $(MKDIR) $(DOC_DIR)/$(@:%_INSTALL_DOC=%) - $(CP) $(patsubst %,"%", \ + $(CP) $(patsubst %,"%",\ $(wildcard $($(@:%_INSTALL_DOC=%_DOC_DIR))/*.css \ $($(@:%_INSTALL_DOC=%_DOC_DIR))/*.html \ $($(@:%_INSTALL_DOC=%_DOC_DIR))/*.png)) \ @@ -219,16 +219,16 @@ $(PLUGIN_DIR)/frama-c-$(PLUGIN_NAME).byte$(EXE): $(TARGET_TOP_CMO) $(PRINT_LINKING) $@ $(OCAMLC) $(PLUGIN_LINK_BFLAGS) $(DYN_BLINKFLAGS) \ -o $@ $(DYN_BYTE_LIBS) $(DYN_GEN_BYTE_LIBS) \ - $(patsubst %boot.cmo, \ - $(PLUGIN_EXTRA_BYTE) $(TARGET_TOP_CMO) %boot.cmo, \ + $(patsubst %boot.cmo,\ + $(PLUGIN_EXTRA_BYTE) $(TARGET_TOP_CMO) %boot.cmo,\ $(DYN_ALL_BATCH_CMO)) $(PLUGIN_DIR)/frama-c-$(PLUGIN_NAME).opt$(EXE): $(TARGET_TOP_CMX) $(PRINT_LINKING) $@ $(OCAMLOPT) $(PLUGIN_LINK_OFLAGS) $(DYN_OLINKFLAGS) \ -o $@ $(DYN_OPT_LIBS) $(DYN_GEN_OPT_LIBS) \ - $(patsubst %boot.cmx, \ - $(PLUGIN_EXTRA_OPT) $(TARGET_TOP_CMX) %boot.cmx, \ + $(patsubst %boot.cmx,\ + $(PLUGIN_EXTRA_OPT) $(TARGET_TOP_CMX) %boot.cmx,\ $(DYN_ALL_BATCH_CMX)) static.byte:: $(PLUGIN_DIR)/frama-c-$(PLUGIN_NAME).byte$(EXE) diff --git a/share/Makefile.plugin.template b/share/Makefile.plugin.template index ca81d8f7935..f4ca1854e0e 100644 --- a/share/Makefile.plugin.template +++ b/share/Makefile.plugin.template @@ -183,7 +183,7 @@ endif # The plugin types .cm* files -PLUGIN_TYPES_CMO:=$(addsuffix .cmo, $(PLUGIN_TYPES_CMO)) +PLUGIN_TYPES_CMO:=$(addsuffix .cmo,$(PLUGIN_TYPES_CMO)) PLUGIN_TYPES_CMX:=$(PLUGIN_TYPES_CMO:.cmo=.cmx) @PLUGIN_NAME@_TYPES_CMO:=$(PLUGIN_TYPES_CMO) @PLUGIN_NAME@_TYPES_CMX:=$(PLUGIN_TYPES_CMX) @@ -205,11 +205,11 @@ PLUGIN_DEPENDS:=$(PLUGIN_DEPENDS) $(PLUGIN_DEPENDENCIES) ################ PLUGIN_SRC:= $(PLUGIN_DIR)/@PLUGIN_NAME@.mli \ - $(patsubst %,$(PLUGIN_DIR)/%.ml*, $(PLUGIN_CMO)) \ - $(patsubst %,$(PLUGIN_DIR)/%.mli, $(PLUGIN_CMI)) \ - $(patsubst %.cmo,%.ml*, $(PLUGIN_TYPES_CMO)) + $(patsubst %,$(PLUGIN_DIR)/%.ml*,$(PLUGIN_CMO)) \ + $(patsubst %,$(PLUGIN_DIR)/%.mli,$(PLUGIN_CMI)) \ + $(patsubst %.cmo,%.ml*,$(PLUGIN_TYPES_CMO)) ifneq ($(ENABLE_GUI),no) -PLUGIN_SRC:= $(PLUGIN_SRC) $(patsubst %,$(PLUGIN_DIR)/%.ml*, $(PLUGIN_GUI_CMO)) +PLUGIN_SRC:= $(PLUGIN_SRC) $(patsubst %,$(PLUGIN_DIR)/%.ml*,$(PLUGIN_GUI_CMO)) endif @PLUGIN_NAME@_SRC:=$(PLUGIN_SRC) @@ -268,9 +268,9 @@ endif ifneq ("$(PLUGIN_ENABLE)","no") # The .cm* files list -PLUGIN_CMO:= $(patsubst %, $(PLUGIN_DIR)/%.cmo, $(PLUGIN_CMO)) +PLUGIN_CMO:= $(patsubst %,$(PLUGIN_DIR)/%.cmo,$(PLUGIN_CMO)) PLUGIN_CMX:= $(PLUGIN_CMO:.cmo=.cmx) -PLUGIN_CMI_ONLY:=$(patsubst %, $(PLUGIN_DIR)/%.cmi, $(PLUGIN_CMI)) +PLUGIN_CMI_ONLY:=$(patsubst %,$(PLUGIN_DIR)/%.cmi,$(PLUGIN_CMI)) PLUGIN_CMI:= $(PLUGIN_CMI_ONLY) $(PLUGIN_CMO:.cmo=.cmi) PLUGIN_INFERRED_MLI:= $(PLUGIN_CMO:.cmo=.inferred.mli) @@ -285,7 +285,7 @@ ifneq ($(ENABLE_GUI),no) ifneq ("$(PLUGIN_GUI_CMO)","") # The .cm* gui files list PLUGIN_GUI_CMO:= $(PLUGIN_CMO) \ - $(patsubst %, $(PLUGIN_DIR)/%.cmo, $(PLUGIN_GUI_CMO)) + $(patsubst %,$(PLUGIN_DIR)/%.cmo,$(PLUGIN_GUI_CMO)) PLUGIN_GUI_CMX:= $(PLUGIN_GUI_CMO:.cmo=.cmx) PLUGIN_GUI_CMI_ONLY:=$(PLUGIN_CMI_ONLY) $(PLUGIN_GUI_CMI) PLUGIN_GUI_CMI:= $(PLUGIN_CMI_ONLY) $(PLUGIN_GUI_CMO:.cmo=.cmi) @@ -404,7 +404,7 @@ PLUGIN_EXTRA_DIRS_INC:=$(patsubst %,-I $(PLUGIN_DIR)/% ,$(PLUGIN_EXTRA_DIRS)) # Set the compilation flags for the plugin INCLUDE_FLAGS:=-I $(PLUGIN_DIR) -I $(INSTALLED_PLUGIN_DIR) \ $(PLUGIN_EXTRA_DIRS_INC) \ - $(addprefix -package , $(PLUGIN_REQUIRES) $(LIBRARY_NAMES)) + $(addprefix -package ,$(PLUGIN_REQUIRES) $(LIBRARY_NAMES)) $(NAME_BFLAGS):=$(BFLAGS) $(INCLUDE_FLAGS) $(PLUGIN_BFLAGS) $(NAME_OFLAGS):=$(OFLAGS) $(INCLUDE_FLAGS) $(PLUGIN_OFLAGS) @@ -415,14 +415,14 @@ $(NAME_DOCFLAGS):= $(DOC_FLAGS) $(PLUGIN_DOCFLAGS) \ -I $(PLUGIN_DIR) \ $(PLUGIN_EXTRA_DIRS_INC) \ -I $(PLUGIN_LIB_DIR) \ - $(addprefix -package , $(PLUGIN_REQUIRES) $(LIBRARY_NAMES)) + $(addprefix -package ,$(PLUGIN_REQUIRES) $(LIBRARY_NAMES)) ifeq ($(HAS_GUI),yes) -$(NAME_GUI_BFLAGS):=$($(NAME_BFLAGS)) $(addprefix -package , $(LIBRARY_NAMES_GUI)) -$(NAME_GUI_OFLAGS):=$($(NAME_OFLAGS)) $(addprefix -package , $(LIBRARY_NAMES_GUI)) +$(NAME_GUI_BFLAGS):=$($(NAME_BFLAGS)) $(addprefix -package ,$(LIBRARY_NAMES_GUI)) +$(NAME_GUI_OFLAGS):=$($(NAME_OFLAGS)) $(addprefix -package ,$(LIBRARY_NAMES_GUI)) $(TARGET_GUI_BFLAGS):= $(PLUGIN_LINK_GUI_BFLAGS) $(TARGET_GUI_OFLAGS):= $(PLUGIN_LINK_GUI_OFLAGS) -$(NAME_DOCFLAGS) := $($(NAME_DOCFLAGS)) $(addprefix -package , $(LIBRARY_NAMES_GUI)) +$(NAME_DOCFLAGS) := $($(NAME_DOCFLAGS)) $(addprefix -package ,$(LIBRARY_NAMES_GUI)) endif $(NAME_DEPFLAGS):= -I $(PLUGIN_DIR) $(PLUGIN_DEPFLAGS) $(PLUGIN_EXTRA_DIRS_INC) @@ -675,9 +675,9 @@ endif # HAS_GUI MODULES_TODOC+= $(PLUGIN_TYPES_TODOC) -PLUGIN_UNDOC := $(addprefix $(PLUGIN_DIR)/, $(PLUGIN_UNDOC)) +PLUGIN_UNDOC := $(addprefix $(PLUGIN_DIR)/,$(PLUGIN_UNDOC)) -PLUGIN_DOC_SRC:=$(filter-out $(PLUGIN_UNDOC), $(PLUGIN_ML_SRC)) +PLUGIN_DOC_SRC:=$(filter-out $(PLUGIN_UNDOC),$(PLUGIN_ML_SRC)) @PLUGIN_NAME@_DOC_SRC:=$(PLUGIN_DOC_SRC) ifndef PLUGIN_DOC_DIR @@ -757,7 +757,7 @@ endif $(RM) $($@_DIR)/*.html # Only generate toc for kernel's documentation if we are in Frama-C's main # Makefile -ifeq ($(FRAMAC_INTERNAL), yes) +ifeq ($(FRAMAC_INTERNAL),yes) $(ECHO) '<li><a href="$(subst $(DOC_DIR)/,,$($@_DIR))/index.html">$(subst _, ,$(patsubst %_DOC,%,$@))</a></li>' > $(DOC_DIR)/$(patsubst %_DOC,%,$@).toc endif $(OCAMLDOC) $($@FLAGS) \ @@ -765,7 +765,7 @@ endif -intro $($@_DIR)/$(patsubst %_DOC,%,$@).txt \ -css-style ../style.css \ -d $($@_DIR) -g $(DOC_PLUGIN) -passopt -docpath $(DOC_DIR)/html \ - $(addprefix -load , $(wildcard $(DOC_DIR)/kernel-doc.ocamldoc)) \ + $(addprefix -load ,$(wildcard $(DOC_DIR)/kernel-doc.ocamldoc)) \ $(wildcard $($@_SRC)) # [rb+js] 20090619 # pwd is required to avoid "bad directory" message on OpenBSD @@ -844,7 +844,7 @@ endif @PLUGIN_NAME@_TESTS_DIRS:=$(PLUGIN_TESTS_DIRS) @PLUGIN_NAME@_TESTS_LIB_DIR:=$(sort $(dir $(PLUGIN_TESTS_LIB))) -@PLUGIN_NAME@_TESTS_LIB_DIR_INCLUDE:=$(foreach d, $(@PLUGIN_NAME@_TESTS_LIB_DIR), -I $d ) +@PLUGIN_NAME@_TESTS_LIB_DIR_INCLUDE:=$(foreach d,$(@PLUGIN_NAME@_TESTS_LIB_DIR),-I $d ) @PLUGIN_NAME@_EXTRA_DIRS:=$(@PLUGIN_NAME@_EXTRA_DIRS) $(@PLUGIN_NAME@_TESTS_LIB_DIR) @PLUGIN_NAME@_TESTS_LIB_OPT:=$(PLUGIN_TESTS_LIB:%.ml=%.cmx) @PLUGIN_NAME@_TESTS_LIB_OPT_DYN:=$(PLUGIN_TESTS_LIB:%.ml=%.cmxs) @@ -880,11 +880,11 @@ $(@PLUGIN_NAME@_DIR)/@PLUGIN_NAME@_DEP_REDO $(@PLUGIN_NAME@_DIR)/.depend: \ $(RM) $(@PLUGIN_NAME@_DIR)/.depend $(OCAMLDEP) $(INCLUDES) \ $(@PLUGIN_NAME@_DEPFLAGS) \ - $(patsubst ./%,%, \ + $(patsubst ./%,%,\ $(@PLUGIN_NAME@_ML_SRC) \ $(@PLUGIN_NAME@_MLI) \ $(@PLUGIN_NAME@_GUI_MLI)) \ - $(foreach d, $(@PLUGIN_NAME@_TESTS_LIB_DIR), \ + $(foreach d,$(@PLUGIN_NAME@_TESTS_LIB_DIR),\ -I $d $d*.ml $d*.mli) \ > $(@PLUGIN_NAME@_DIR)/.depend $(CHMOD_RO) $(@PLUGIN_NAME@_DIR)/.depend @@ -918,7 +918,7 @@ endif .PHONY: $(PLUGIN_DIR)/@PLUGIN_NAME@_CLEAN $(PLUGIN_DIR)/@PLUGIN_NAME@_CLEAN: - $(PRINT_RM) $(patsubst %_CLEAN, %, $(notdir $@)) + $(PRINT_RM) $(patsubst %_CLEAN,%,$(notdir $@)) if test "$(FRAMAC_INTERNAL)" = "yes"; then \ $(RM) $(dir $@).depend; \ fi @@ -931,15 +931,15 @@ $(PLUGIN_DIR)/@PLUGIN_NAME@_CLEAN: $(RM) $(patsubst %.cmo,%.o,$($(patsubst %_CLEAN,%_CMO,$(notdir $@)))) $(RM) $(patsubst %.cmo,%.cm*,\ $($(patsubst %_CLEAN,%_GUI_CMO,$(notdir $@)))) - $(RM) $(patsubst %.cmi,%.cm*, \ + $(RM) $(patsubst %.cmi,%.cm*,\ $($(patsubst %_CLEAN,%_GUI_CMI,$(notdir $@)))) - $(RM) $(patsubst %.cmo,%.annot, \ + $(RM) $(patsubst %.cmo,%.annot,\ $($(patsubst %_CLEAN,%_GUI_CMO,$(notdir $@)))) - $(RM) $(patsubst %.cmo,%.o, \ + $(RM) $(patsubst %.cmo,%.o,\ $($(patsubst %_CLEAN,%_GUI_CMO,$(notdir $@)))) $(RM) $(dir $@)*~ $(dir $@)*.cm* $(dir $@)*.o $(dir $@)*.annot - $(RM) $(foreach d, $(@:%CLEAN=%TESTS_LIB_OPT), \ - $(foreach f, $($(notdir $d)), \ + $(RM) $(foreach d,$(@:%CLEAN=%TESTS_LIB_OPT),\ + $(foreach f,$($(notdir $d)),\ $f $(f:.cmx=.cmo) $(f:.cmx=.opt) $(f:.cmx=.byte) $(f:.cmx=.o))) $(RM) -f $(@PLUGIN_NAME@_CHECK_PLUGIN_MLI) @@ -950,7 +950,7 @@ $(PLUGIN_DIR)/@PLUGIN_NAME@_DIST_CLEAN: .PHONY: $(PLUGIN_DIR)/@PLUGIN_NAME@_CLEAN_DOC $(@PLUGIN_NAME@_DOC_DIR) $(PLUGIN_DIR)/@PLUGIN_NAME@_CLEAN_DOC: $(@PLUGIN_NAME@_DOC_DIR) - $(PRINT_RM) documentation of $(patsubst %_CLEAN_DOC, %, $(notdir $@)) + $(PRINT_RM) documentation of $(patsubst %_CLEAN_DOC,%,$(notdir $@)) $(RM) -r $< $(RM) $(DOC_DIR)/$(notdir $(patsubst %_CLEAN_DOC,%,$@).toc) -- GitLab