[Qt] Fix build with ANGLE on platforms that provide EGL/GLESv2
[WebKit-https.git] / Source / ThirdParty / ANGLE / DerivedSources.pri
1 # -------------------------------------------------------------------
2 # Derived sources for ANGLE
3 #
4 # See 'Tools/qmake/README' for an overview of the build system
5 # -------------------------------------------------------------------
6
7 # This file is both a top level target, and included from Target.pri,
8 # so that the resulting generated sources can be added to SOURCES.
9 # We only set the template if we're a top level target, so that we
10 # don't override what Target.pri has already set.
11 sanitizedFile = $$toSanitizedPath($$_FILE_)
12 equals(sanitizedFile, $$toSanitizedPath($$_PRO_FILE_)):TEMPLATE = derived
13
14 ANGLE_FLEX_SOURCES = \
15     $$PWD/src/compiler/glslang.l \
16     $$PWD/src/compiler/preprocessor/new/Tokenizer.l
17
18 angleflex.output = ${QMAKE_FILE_BASE}_lex.cpp
19 angleflex.input = ANGLE_FLEX_SOURCES
20 angleflex.commands = flex --noline --nounistd --outfile=${QMAKE_FILE_OUT} ${QMAKE_FILE_IN}
21 GENERATORS += angleflex
22
23 ANGLE_BISON_SOURCES = \
24     $$PWD/src/compiler/glslang.y \
25     $$PWD/src/compiler/preprocessor/new/ExpressionParser.y
26
27 anglebison_decl.output = ${QMAKE_FILE_BASE}_tab.h
28 anglebison_decl.input = ANGLE_BISON_SOURCES
29 anglebison_decl.commands = bison --no-lines --skeleton=yacc.c --defines=${QMAKE_FILE_OUT} --output=${QMAKE_FUNC_FILE_OUT_PATH}$${QMAKE_DIR_SEP}${QMAKE_FILE_OUT_BASE}.cpp ${QMAKE_FILE_IN}
30 anglebison_decl.variable_out = GENERATED_FILES
31 GENERATORS += anglebison_decl
32
33 anglebison_impl.input = ANGLE_BISON_SOURCES
34 anglebison_impl.commands = $$escape_expand(\\n)
35 anglebison_impl.depends = $$GENERATED_SOURCES_DESTDIR/${QMAKE_FILE_BASE}_tab.h
36 anglebison_impl.output = ${QMAKE_FILE_BASE}_tab.cpp
37 GENERATORS += anglebison_impl
38