Bug 1773205 [wpt PR 34343] - SVG Text NG: Improve performance on ancestor scaling...
[gecko.git] / modules / freetype2 / builds / modules.mk
blobabbb0ef9e854756bc13bc4b5eefdd6568e7bae52
2 # FreeType 2 modules sub-Makefile
6 # Copyright (C) 1996-2022 by
7 # David Turner, Robert Wilhelm, and Werner Lemberg.
9 # This file is part of the FreeType project, and may only be used, modified,
10 # and distributed under the terms of the FreeType project license,
11 # LICENSE.TXT. By continuing to use, modify, or distribute this file you
12 # indicate that you have read the license and understand and accept it
13 # fully.
16 # DO NOT INVOKE THIS MAKEFILE DIRECTLY! IT IS MEANT TO BE INCLUDED BY
17 # OTHER MAKEFILES.
20 # This file is in charge of handling the generation of the modules list
21 # file.
24 # Build the modules list.
26 $(FTMODULE_H): $(MODULES_CFG)
27 $(FTMODULE_H_INIT)
28 $(FTMODULE_H_CREATE)
29 $(FTMODULE_H_DONE)
31 ifneq ($(findstring $(PLATFORM),dos windows os2),)
32 OPEN_MODULE := @echo$(space)
33 CLOSE_MODULE := >> $(subst /,$(SEP),$(FTMODULE_H))
34 REMOVE_MODULE := @-$(DELETE) $(subst /,$(SEP),$(FTMODULE_H))
35 else
36 OPEN_MODULE := @echo "
37 CLOSE_MODULE := " >> $(FTMODULE_H)
38 REMOVE_MODULE := @-$(DELETE) $(FTMODULE_H)
39 endif
42 define FTMODULE_H_INIT
43 $(REMOVE_MODULE)
44 $(info Generating modules list in $(FTMODULE_H)...)
45 $(OPEN_MODULE)/* This is a generated file. */$(CLOSE_MODULE)
46 endef
48 # It is no mistake that the final closing parenthesis is on the
49 # next line -- it produces proper newlines during the expansion
50 # of `foreach'.
52 define FTMODULE_H_CREATE
53 $(foreach COMMAND,$(FTMODULE_H_COMMANDS),$($(COMMAND))
55 endef
57 define FTMODULE_H_DONE
58 $(OPEN_MODULE)/* EOF */$(CLOSE_MODULE)
59 $(info done.)
60 endef
63 # $(OPEN_DRIVER) & $(CLOSE_DRIVER) are used to specify a given font driver
64 # in the `module.mk' rules file.
66 OPEN_DRIVER := $(OPEN_MODULE)FT_USE_MODULE(
67 CLOSE_DRIVER := )$(CLOSE_MODULE)
69 ECHO_DRIVER := @echo "* module:$(space)
70 ECHO_DRIVER_DESC := (
71 ECHO_DRIVER_DONE := )"
73 # Each `module.mk' in the `src/*' subdirectories adds a variable with
74 # commands to $(FTMODULE_H_COMMANDS). Note that we can't use SRC_DIR here.
76 -include $(patsubst %,$(TOP_DIR)/src/%/module.mk,$(MODULES))
79 # EOF