Bug 1606850 [wpt PR 21024] - Editorial: start using blocklist, a=testonly
[gecko.git] / config / makefiles / debugmake.mk
blob48616f57c8366f4a0c4e7d9df94bf8a20329fd77
1 # -*- makefile -*-
2 # vim:set ts=8 sw=8 sts=8 noet:
4 # This Source Code Form is subject to the terms of the Mozilla Public
5 # License, v. 2.0. If a copy of the MPL was not distributed with this file,
6 # You can obtain one at http://mozilla.org/MPL/2.0/.
9 ###########################################################################
10 ## Intent: Helper targets for displaying variables and state information
11 ###########################################################################
13 # Support usage outside of config/rules.mk
14 ifndef INCLUDED_DEBUGMAKE_MK #{
16 define CR
19 endef
21 define shell_quote
22 '$(subst $(CR),\$(CR),$(subst ','\'',$(1)))'
23 endef
25 echo-variable-%:
26 @echo $(call shell_quote,$($*))
28 echo-dirs:
29 @echo $(call shell_quote,$(DIRS))
31 define print_var
32 @printf '%20s = %s\n' $1 $(call shell_quote,$($1))
34 endef
36 define print_vars
37 $(foreach var,$1,$(call print_var,$(var)))
38 endef
40 showtargs:
41 ifneq (,$(filter $(PROGRAM) $(HOST_PROGRAM) $(SIMPLE_PROGRAMS) $(LIBRARY) $(SHARED_LIBRARY),$(TARGETS)))
42 @echo --------------------------------------------------------------------------------
43 $(call print_vars,\
44 PROGRAM \
45 SIMPLE_PROGRAMS \
46 LIBRARY \
47 SHARED_LIBRARY \
48 LIBS \
49 DEF_FILE \
50 IMPORT_LIBRARY \
51 STATIC_LIBS \
52 SHARED_LIBS \
53 EXTRA_DSO_LDOPTS \
54 DEPENDENT_LIBS \
56 @echo --------------------------------------------------------------------------------
57 endif
58 $(LOOP_OVER_DIRS)
60 showbuild showhost: _DEPEND_CFLAGS=
61 showbuild showhost: COMPILE_PDB_FLAG=
62 showbuild:
63 $(call print_vars,\
64 MOZ_BUILD_ROOT \
65 MOZ_WIDGET_TOOLKIT \
66 CC \
67 CXX \
68 CCC \
69 CPP \
70 LD \
71 AR \
72 IMPLIB \
73 FILTER \
74 MKSHLIB \
75 MKCSHLIB \
76 RC \
77 CFLAGS \
78 OS_CFLAGS \
79 COMPILE_CFLAGS \
80 CXXFLAGS \
81 OS_CXXFLAGS \
82 COMPILE_CXXFLAGS \
83 COMPILE_CMFLAGS \
84 COMPILE_CMMFLAGS \
85 LDFLAGS \
86 OS_LDFLAGS \
87 DSO_LDOPTS \
88 OS_INCLUDES \
89 OS_LIBS \
90 BIN_FLAGS \
91 INCLUDES \
92 DEFINES \
93 ACDEFINES \
94 BIN_SUFFIX \
95 LIB_SUFFIX \
96 RUST_LIB_SUFFIX \
97 DLL_SUFFIX \
98 IMPORT_LIB_SUFFIX \
99 INSTALL \
100 VPATH \
103 showhost:
104 $(call print_vars,\
105 HOST_CC \
106 HOST_CXX \
107 HOST_CFLAGS \
108 HOST_LDFLAGS \
109 HOST_LIBS \
110 HOST_EXTRA_LIBS \
111 HOST_EXTRA_DEPS \
112 HOST_PROGRAM \
113 HOST_OBJS \
114 HOST_PROGOBJS \
117 INCLUDED_DEBUGMAKE_MK = 1
118 endif #}