2013-04-01 11:36:59 -07:00
|
|
|
# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
|
2013-02-25 12:47:21 -08:00
|
|
|
# vim: set filetype=python:
|
|
|
|
# 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/.
|
|
|
|
|
|
|
|
# libEGL depends on (links against!) libGLESv2!
|
|
|
|
if CONFIG['MOZ_ANGLE_RENDERER']:
|
|
|
|
DIRS += ['src/libGLESv2', 'src/libEGL']
|
2013-03-19 11:47:00 -07:00
|
|
|
|
2013-04-16 12:24:43 -07:00
|
|
|
EXPORTS.angle += [
|
|
|
|
'include/GLSLANG/ShaderLang.h',
|
|
|
|
'include/KHR/khrplatform.h',
|
|
|
|
]
|
|
|
|
|
2013-04-23 14:54:15 -07:00
|
|
|
# WARNING: CPP_SOURCES seems very dependent on ordering. Grouping all of these
|
|
|
|
# CPP_SOURCES lines into one list may break webgl tests.
|
|
|
|
|
|
|
|
# Target: 'preprocessor'
|
|
|
|
# src/compiler/preprocessor:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += ['src/compiler/preprocessor/' + src for src in [
|
2013-04-23 14:54:15 -07:00
|
|
|
'DiagnosticsBase.cpp',
|
|
|
|
'DirectiveHandlerBase.cpp',
|
|
|
|
'DirectiveParser.cpp',
|
|
|
|
'ExpressionParser.cpp',
|
|
|
|
'Input.cpp',
|
|
|
|
'Lexer.cpp',
|
|
|
|
'Macro.cpp',
|
|
|
|
'MacroExpander.cpp',
|
|
|
|
'Preprocessor.cpp',
|
|
|
|
'Token.cpp',
|
|
|
|
'Tokenizer.cpp',
|
2013-10-03 00:10:00 -07:00
|
|
|
]]
|
2013-04-23 14:54:15 -07:00
|
|
|
|
2013-09-06 17:24:36 -07:00
|
|
|
# Target: 'translator_common'
|
|
|
|
# Requires: 'preprocessor'
|
2013-04-23 14:54:15 -07:00
|
|
|
# src/compiler:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += ['src/compiler/' + src for src in [
|
2013-04-23 14:54:15 -07:00
|
|
|
'BuiltInFunctionEmulator.cpp',
|
|
|
|
'Compiler.cpp',
|
2013-10-23 16:05:43 -07:00
|
|
|
'compiler_debug.cpp',
|
2013-10-23 16:00:23 -07:00
|
|
|
'CompilerUniform.cpp',
|
2013-09-06 17:24:36 -07:00
|
|
|
'DetectCallDepth.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'Diagnostics.cpp',
|
|
|
|
'DirectiveHandler.cpp',
|
|
|
|
'ForLoopUnroll.cpp',
|
|
|
|
'InfoSink.cpp',
|
|
|
|
'Initialize.cpp',
|
|
|
|
'InitializeDll.cpp',
|
|
|
|
'InitializeParseContext.cpp',
|
2013-10-23 16:00:23 -07:00
|
|
|
'Intermediate.cpp',
|
2013-10-23 16:05:43 -07:00
|
|
|
'intermOut.cpp',
|
|
|
|
'IntermTraverse.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'MapLongVariableNames.cpp',
|
2013-10-23 16:05:43 -07:00
|
|
|
'parseConst.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'ParseHelper.cpp',
|
|
|
|
'PoolAlloc.cpp',
|
|
|
|
'QualifierAlive.cpp',
|
|
|
|
'RemoveTree.cpp',
|
|
|
|
'SymbolTable.cpp',
|
2013-10-23 16:05:43 -07:00
|
|
|
'util.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'ValidateLimitations.cpp',
|
|
|
|
'VariableInfo.cpp',
|
|
|
|
'VariablePacker.cpp',
|
2013-10-03 00:10:00 -07:00
|
|
|
]]
|
2013-11-17 18:47:21 -08:00
|
|
|
# The yacc source files need to be built separately.
|
|
|
|
SOURCES += ['src/compiler/' + src for src in [
|
|
|
|
'glslang_lex.cpp',
|
|
|
|
'glslang_tab.cpp',
|
|
|
|
]]
|
2013-04-23 14:54:15 -07:00
|
|
|
|
|
|
|
# src/compiler/depgraph:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += ['src/compiler/depgraph/' + src for src in [
|
2013-04-23 14:54:15 -07:00
|
|
|
'DependencyGraph.cpp',
|
|
|
|
'DependencyGraphBuilder.cpp',
|
|
|
|
'DependencyGraphOutput.cpp',
|
|
|
|
'DependencyGraphTraverse.cpp',
|
2013-10-03 00:10:00 -07:00
|
|
|
]]
|
2013-04-23 14:54:15 -07:00
|
|
|
|
|
|
|
# src/compiler/timing:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += ['src/compiler/timing/' + src for src in [
|
2013-04-23 14:54:15 -07:00
|
|
|
'RestrictFragmentShaderTiming.cpp',
|
|
|
|
'RestrictVertexShaderTiming.cpp',
|
2013-10-03 00:10:00 -07:00
|
|
|
]]
|
2013-04-23 14:54:15 -07:00
|
|
|
|
|
|
|
# src/third_party/compiler:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += ['src/third_party/compiler/' + src for src in [
|
2013-04-23 14:54:15 -07:00
|
|
|
'ArrayBoundsClamper.cpp',
|
2013-10-03 00:10:00 -07:00
|
|
|
]]
|
2013-04-23 14:54:15 -07:00
|
|
|
|
2013-09-06 17:24:36 -07:00
|
|
|
# src/third_party/murmurhash:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += ['src/third_party/murmurhash/' + src for src in [
|
2013-09-06 17:24:36 -07:00
|
|
|
'MurmurHash3.cpp',
|
2013-10-03 00:10:00 -07:00
|
|
|
]]
|
2013-09-06 17:24:36 -07:00
|
|
|
|
2013-04-23 14:54:15 -07:00
|
|
|
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += [
|
2013-10-03 00:10:00 -07:00
|
|
|
'src/compiler/ossource_win.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
]
|
|
|
|
else:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += [
|
2013-10-03 00:10:00 -07:00
|
|
|
'src/compiler/ossource_posix.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
]
|
|
|
|
|
|
|
|
# Target: 'translator_glsl'
|
|
|
|
# Requires: 'translator_common'
|
|
|
|
# src/compiler:
|
2013-11-17 18:47:21 -08:00
|
|
|
UNIFIED_SOURCES += ['src/compiler/' + src for src in [
|
2013-04-23 14:54:15 -07:00
|
|
|
'CodeGenGLSL.cpp',
|
|
|
|
'OutputESSL.cpp',
|
|
|
|
'OutputGLSL.cpp',
|
2013-10-23 16:00:23 -07:00
|
|
|
'OutputGLSLBase.cpp',
|
2013-04-23 14:54:15 -07:00
|
|
|
'ShaderLang.cpp',
|
|
|
|
'TranslatorESSL.cpp',
|
|
|
|
'TranslatorGLSL.cpp',
|
|
|
|
'VersionGLSL.cpp',
|
2013-10-03 00:10:00 -07:00
|
|
|
]]
|
2013-08-21 23:56:01 -07:00
|
|
|
MSVC_ENABLE_PGO = True
|
2013-10-24 12:06:19 -07:00
|
|
|
|
2013-11-28 06:10:38 -08:00
|
|
|
LOCAL_INCLUDES += [
|
|
|
|
'include',
|
|
|
|
'include/KHR',
|
|
|
|
'src',
|
|
|
|
]
|
|
|
|
|
2013-11-22 06:03:21 -08:00
|
|
|
if CONFIG['GKMEDIAS_SHARED_LIBRARY']:
|
2013-10-24 12:06:19 -07:00
|
|
|
NO_VISIBILITY_FLAGS = True
|
2013-11-18 18:47:14 -08:00
|
|
|
|
|
|
|
FINAL_LIBRARY = 'gkmedias'
|
2013-11-27 05:55:07 -08:00
|
|
|
|
|
|
|
DEFINES['ANGLE_DISABLE_TRACE'] = True
|
|
|
|
DEFINES['ANGLE_COMPILE_OPTIMIZATION_LEVEL'] = 'D3DCOMPILE_OPTIMIZATION_LEVEL1'
|
|
|
|
DEFINES['COMPILER_IMPLEMENTATION'] = True
|