# Sources # background.c # border.c # border_color.c # border_style.c # border_width.c # content.c # cue.c # cursor.c # font.c # font_family.c # list_style.c # margin.c # outline.c # padding.c # pause.c # play_during.c # quotes.c # text_decoration.c # voice_family.c AUTOGEN_PARSERS=$(shell perl -pe'$$_="" unless /^([^\#][^:]+):/;$$_=$$1 . " "' $(DIR)properties.gen) # Dodgy use of define/eval to bypass DIR changing define build_gen_parser $(BUILDDIR)/gen_parser: $(DIR)css_property_parser_gen.c $$(VQ)$$(ECHO) $$(ECHOFLAGS) " PREPARE: $$@" $$(Q)$$(HOST_CC) -o $$@ $$^ endef $(eval $(build_gen_parser)) define gen_prop_parser $(DIR)autogenerated_$1.c: $(DIR)properties.gen $(BUILDDIR)/gen_parser $$(VQ)$$(ECHO) $$(ECHOFLAGS) "GENERATE: $$@" $$(Q)$$(BUILDDIR)/gen_parser -o $$@ '$(shell grep "^$1:" $(DIR)properties.gen)' AUTOGEN_SOURCES := $$(AUTOGEN_SOURCES) autogenerated_$1.c endef AUTOGEN_SOURCES := $(eval $(foreach PROP,$(AUTOGEN_PARSERS),$(call gen_prop_parser,$(PROP)))) DIR_SOURCES := azimuth.c text_decoration.c background.c \ background_position.c border_spacing.c font.c outline.c \ voice_family.c border_style.c cue.c \ font_family.c list_style.c padding.c cursor.c \ list_style_type.c pause.c border.c border_width.c margin.c \ play_during.c clip.c properties.c border_color.c content.c \ elevation.c font_weight.c quotes.c utils.c DIR_SOURCES := $(DIR_SOURCES) $(AUTOGEN_SOURCES) PRE_TARGETS := $(foreach AP,$(AUTOGEN_PARSERS),src/parse/properties/autogenerated_$(AP).c) DISTCLEAN_ITEMS := $(foreach AP,$(AUTOGEN_PARSERS),src/parse/properties/autogenerated_$(AP).c) include build/makefiles/Makefile.subdir