mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 22:01:30 +00:00
a5c3b22cad
codegen.pp isn't available immediately (there's a rule to generate it), and so make warns when it's initially not found. But since this is a depends file, like other dependency files generated by the build process, we should silently include it so make doesn't even warn about it.
71 lines
1.8 KiB
Makefile
71 lines
1.8 KiB
Makefile
# This Source Code Form is subject to the terms of the Mozilla Public
|
|
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
webidl_base := $(topsrcdir)/dom/webidl
|
|
|
|
ifdef COMPILE_ENVIRONMENT
|
|
|
|
# Generated by moz.build
|
|
include webidlsrcs.mk
|
|
|
|
# These come from webidlsrcs.mk.
|
|
# TODO Write directly into backend.mk (bug 1281618)
|
|
CPPSRCS += $(globalgen_sources) $(unified_binding_cpp_files)
|
|
|
|
include $(topsrcdir)/config/rules.mk
|
|
|
|
# TODO This list should be emitted to a .pp file via
|
|
# GenerateCSS2PropertiesWebIDL.py (bug 1281614)
|
|
css2properties_dependencies = \
|
|
$(topsrcdir)/layout/style/nsCSSPropList.h \
|
|
$(topsrcdir)/layout/style/nsCSSPropAliasList.h \
|
|
$(webidl_base)/CSS2Properties.webidl.in \
|
|
$(topsrcdir)/layout/style/PythonCSSProps.h \
|
|
$(srcdir)/GenerateCSS2PropertiesWebIDL.py \
|
|
$(GLOBAL_DEPS) \
|
|
$(NULL)
|
|
|
|
CSS2Properties.webidl: $(css2properties_dependencies)
|
|
|
|
# Most of the logic for dependencies lives inside Python so it can be
|
|
# used by multiple build backends. We simply have rules to generate
|
|
# and include the .pp file.
|
|
#
|
|
# The generated .pp file contains all the important dependencies such as
|
|
# changes to .webidl or .py files should result in code generation being
|
|
# performed. But we do pull in file-lists.jon to catch file additions.
|
|
codegen_dependencies := \
|
|
file-lists.json \
|
|
$(nonstatic_webidl_files) \
|
|
$(GLOBAL_DEPS) \
|
|
$(NULL)
|
|
|
|
-include codegen.pp
|
|
|
|
codegen.pp: $(codegen_dependencies)
|
|
$(call py_action,webidl,$(srcdir))
|
|
@$(TOUCH) $@
|
|
|
|
.PHONY: compiletests
|
|
compiletests:
|
|
$(call SUBMAKE,libs,test)
|
|
|
|
endif
|
|
|
|
GARBAGE += \
|
|
codegen.pp \
|
|
codegen.json \
|
|
parser.out \
|
|
WebIDLGrammar.pkl \
|
|
$(wildcard *.h) \
|
|
$(wildcard *Binding.cpp) \
|
|
$(wildcard *Event.cpp) \
|
|
$(wildcard *-event.cpp) \
|
|
$(wildcard *.webidl) \
|
|
$(NULL)
|
|
|
|
DIST_GARBAGE += \
|
|
file-lists.json \
|
|
$(NULL)
|