1 # Copyright © 2016 Intel Corporation
2 # Copyright © 2016 Mauro Rossi <issor.oruam@gmail.com>
4 # Permission is hereby granted, free of charge, to any person obtaining a
5 # copy of this software and associated documentation files (the "Software"),
6 # to deal in the Software without restriction, including without limitation
7 # the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 # and/or sell copies of the Software, and to permit persons to whom the
9 # Software is furnished to do so, subject to the following conditions:
11 # The above copyright notice and this permission notice shall be included
12 # in all copies or substantial portions of the Software.
14 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17 # THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
19 # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20 # DEALINGS IN THE SOFTWARE.
23 # ---------------------------------------
24 # Build libmesa_genxml
25 # ---------------------------------------
29 LOCAL_MODULE
:= libmesa_genxml
31 LOCAL_MODULE_CLASS
:= STATIC_LIBRARIES
33 intermediates
:= $(call local-generated-sources-dir
)
35 # dummy.c source file is generated to meet the build system's rules.
36 LOCAL_GENERATED_SOURCES
+= $(intermediates
)/dummy.c
38 $(intermediates
)/dummy.c
:
40 @echo
"Gen Dummy: $(PRIVATE_MODULE) <= $(notdir $(@))"
43 # This is the list of auto-generated files headers
44 LOCAL_GENERATED_SOURCES
+= $(addprefix $(intermediates
)/, $(GENXML_GENERATED_FILES
))
48 @echo
"Gen Header: $(PRIVATE_MODULE) <= $(notdir $(@))"
49 $(hide
) $(PRIVATE_SCRIPT
) $(PRIVATE_SCRIPT_FLAGS
) $(PRIVATE_XML
) > $@
52 $(intermediates
)/genxml
/genX_bits.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_bits_header.py
53 $(intermediates
)/genxml
/genX_bits.h
: PRIVATE_SCRIPT_FLAGS
:= --cpp-guard
=GENX_BITS_H
54 $(intermediates
)/genxml
/genX_bits.h
: PRIVATE_XML
:= $(addprefix $(LOCAL_PATH
)/,$(GENXML_XML_FILES
))
55 $(intermediates
)/genxml
/genX_bits.h
: $(LOCAL_PATH
)/genxml
/gen_bits_header.py
56 $(intermediates
)/genxml
/genX_bits.h
: $(addprefix $(LOCAL_PATH
)/,$(GENXML_XML_FILES
))
59 $(intermediates
)/genxml
/gen4_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
60 $(intermediates
)/genxml
/gen4_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen4.xml
61 $(intermediates
)/genxml
/gen4_pack.h
: $(LOCAL_PATH
)/genxml
/gen4.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
64 $(intermediates
)/genxml
/gen45_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
65 $(intermediates
)/genxml
/gen45_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen45.xml
66 $(intermediates
)/genxml
/gen45_pack.h
: $(LOCAL_PATH
)/genxml
/gen45.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
69 $(intermediates
)/genxml
/gen5_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
70 $(intermediates
)/genxml
/gen5_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen5.xml
71 $(intermediates
)/genxml
/gen5_pack.h
: $(LOCAL_PATH
)/genxml
/gen5.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
74 $(intermediates
)/genxml
/gen6_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
75 $(intermediates
)/genxml
/gen6_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen6.xml
76 $(intermediates
)/genxml
/gen6_pack.h
: $(LOCAL_PATH
)/genxml
/gen6.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
79 $(intermediates
)/genxml
/gen7_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
80 $(intermediates
)/genxml
/gen7_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen7.xml
81 $(intermediates
)/genxml
/gen7_pack.h
: $(LOCAL_PATH
)/genxml
/gen7.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
84 $(intermediates
)/genxml
/gen75_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
85 $(intermediates
)/genxml
/gen75_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen75.xml
86 $(intermediates
)/genxml
/gen75_pack.h
: $(LOCAL_PATH
)/genxml
/gen75.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
89 $(intermediates
)/genxml
/gen8_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
90 $(intermediates
)/genxml
/gen8_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen8.xml
91 $(intermediates
)/genxml
/gen8_pack.h
: $(LOCAL_PATH
)/genxml
/gen8.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
94 $(intermediates
)/genxml
/gen9_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
95 $(intermediates
)/genxml
/gen9_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen9.xml
96 $(intermediates
)/genxml
/gen9_pack.h
: $(LOCAL_PATH
)/genxml
/gen9.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
99 $(intermediates
)/genxml
/gen10_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
100 $(intermediates
)/genxml
/gen10_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen10.xml
101 $(intermediates
)/genxml
/gen10_pack.h
: $(LOCAL_PATH
)/genxml
/gen10.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
104 $(intermediates
)/genxml
/gen11_pack.h
: PRIVATE_SCRIPT
:= $(MESA_PYTHON2
) $(LOCAL_PATH
)/genxml
/gen_pack_header.py
105 $(intermediates
)/genxml
/gen11_pack.h
: PRIVATE_XML
:= $(LOCAL_PATH
)/genxml
/gen11.xml
106 $(intermediates
)/genxml
/gen11_pack.h
: $(LOCAL_PATH
)/genxml
/gen11.xml
$(LOCAL_PATH
)/genxml
/gen_pack_header.py
109 $(intermediates
)/genxml
/genX_xml.h
: $(addprefix $(MESA_TOP
)/src
/intel
/,$(GENXML_XML_FILES
)) $(MESA_TOP
)/src
/intel
/genxml
/gen_zipped_file.py
111 @echo
"Gen Header: $(PRIVATE_MODULE) <= $(notdir $(@))"
112 $(hide
) $(MESA_PYTHON2
) $(MESA_TOP
)/src
/intel
/genxml
/gen_zipped_file.py
$(addprefix $(MESA_TOP
)/src
/intel
/,$(GENXML_XML_FILES
)) > $@ ||
(rm -f
$@
; false
)
114 LOCAL_EXPORT_C_INCLUDE_DIRS
:= \
115 $(MESA_TOP
)/src
/intel \
118 include $(MESA_COMMON_MK
)
119 include $(BUILD_STATIC_LIBRARY
)