diff options
| author | Micael Karlberg <bmk@erlang.org> | 2022-07-11 17:26:47 +0200 |
|---|---|---|
| committer | Micael Karlberg <bmk@erlang.org> | 2022-07-13 17:34:53 +0200 |
| commit | 69deb1ac4855c6f4a33ad25d0c7edc97a46cce3d (patch) | |
| tree | 5a9cc5d34a03a0a284db7c00f5ae65e1ba4c09bb /lib/megaco | |
| parent | e782dfe68396982c586a4cb1401362b4885c2abf (diff) | |
| download | erlang-69deb1ac4855c6f4a33ad25d0c7edc97a46cce3d.tar.gz | |
[megaco|example|meas] Add dialyzer (make) targets
OTP-18179
Diffstat (limited to 'lib/megaco')
| -rw-r--r-- | lib/megaco/examples/meas/Makefile.in | 47 |
1 files changed, 46 insertions, 1 deletions
diff --git a/lib/megaco/examples/meas/Makefile.in b/lib/megaco/examples/meas/Makefile.in index 1dc3361167..7115a791a2 100644 --- a/lib/megaco/examples/meas/Makefile.in +++ b/lib/megaco/examples/meas/Makefile.in @@ -86,6 +86,18 @@ ERL_COMPILE_FLAGS += \ -pa $(ERL_TOP)/lib/megaco/ebin \ -I../include +DIA_PLT = megaco_example_meas.plt +DIA_ANALYSIS = $(basename $(DIA_PLT)).dialyzer_analysis +ifeq ($(DIAW_EH),true) +DIA_WARNINGS += -Werror_handling +endif +ifeq ($(DIAW_US),true) +DIA_WARNINGS += -Wunderspecs +endif +ifeq ($(DIAW_UR),true) +DIA_WARNINGS += -Wunmatched_returns +endif + # ---------------------------------------------------- # Special Build Targets @@ -104,7 +116,7 @@ script_skeletons: $(SCRIPT_SKELETONS) info: @echo "MODULES = $(MODULES)" - @echo "ERL_FILED = $(ERL_FILES)" + @echo "ERL_FILES = $(ERL_FILES)" @echo "" @echo "SCRIPT_SKELETON_SRC = $(SCRIPT_SKELETON_SRC)" @echo "SCRIPT_SKELETONS = $(SCRIPT_SKELETONS)" @@ -140,6 +152,39 @@ release_spec: opt release_docs_spec: +dclean: + rm -f $(DIA_PLT) + rm -f $(DIA_ANALYSIS) + +dialyzer_plt: $(DIA_PLT) + +$(DIA_PLT): $(ERL_FILES) + @echo "Building ($(basename $(DIA_PLT))) plt file" + @dialyzer --build_plt \ + --output_plt $@ \ + -r . \ + ../../ebin \ + ../../../../lib/asn1/ebin \ + ../../../../lib/et/ebin \ + ../../../../lib/kernel/ebin \ + ../../../../lib/stdlib/ebin \ + ../../../../lib/compiler/ebin \ + ../../../../lib/debugger/ebin \ + ../../../../lib/runtime_tools/ebin \ + ../../../../lib/crypto/ebin \ + ../../../../lib/mnesia/ebin \ + ../../../../lib/wx/ebin \ + ../../../../erts/preloaded/ebin \ + --output $(DIA_ANALYSIS) \ + --verbose + +dialyzer: $(DIA_PLT) + @echo "Running dialyzer on $(basename $(DIA_PLT))" + @dialyzer --plt $< \ + -r ../../ebin \ + $(DIA_WARNINGS) \ + --verbose + # ---------------------------------------------------- # Include dependencies # ---------------------------------------------------- |
