2 # ***** BEGIN LICENSE BLOCK *****
3 # Version: MPL 1.1/GPL 2.0/LGPL 2.1
5 # The contents of this file are subject to the Mozilla Public License Version
6 # 1.1 (the "License"); you may not use this file except in compliance with
7 # the License. You may obtain a copy of the License at
8 # http://www.mozilla.org/MPL/
10 # Software distributed under the License is distributed on an "AS IS" basis,
11 # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 # for the specific language governing rights and limitations under the
15 # The Original Code is gecko.
17 # The Initial Developer of the Original Code is
19 # Portions created by the Initial Developer are Copyright (C) 2010
20 # the Initial Developer. All Rights Reserved.
24 # Alternatively, the contents of this file may be used under the terms of
25 # either of the GNU General Public License Version 2 or later (the "GPL"),
26 # or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
27 # in which case the provisions of the GPL or the LGPL are applicable instead
28 # of those above. If you wish to allow use of your version of this file only
29 # under the terms of either the GPL or the LGPL, and not to allow others to
30 # use your version of this file under the terms of the MPL, indicate your
31 # decision by deleting the provisions above and replace them with the notice
32 # and other provisions required by the GPL or the LGPL. If you do not delete
33 # the provisions above, a recipient may use your version of this file under
34 # the terms of any one of the MPL, the GPL or the LGPL.
36 # ***** END LICENSE BLOCK *****
39 topsrcdir
= @top_srcdir@
43 include $(DEPTH
)/config
/autoconf.mk
50 EXPORTS_NAMESPACES
= angle
53 include/GLSLANG
/ShaderLang.h \
54 include/GLSLANG
/ResourceLimits.h \
57 LOCAL_INCLUDES
+= -I
$(srcdir)/include -I
$(srcdir)/src
59 VPATH
+= $(srcdir)/src
60 VPATH
+= $(srcdir)/src
/compiler
61 VPATH
+= $(srcdir)/src
/compiler
/preprocessor
83 ValidateLimitations.
cpp \
86 # flex/yacc generated files
92 # GLSL translator backend
100 # Currently, only one or the other
103 ## HLSL translator backend
107 ## TranslatorHLSL.cpp \
108 ## UnfoldSelect.cpp \
121 DEFINES
+= -DANGLE_USE_NSPR
-DANGLE_BUILD
123 ifndef MOZ_ENABLE_LIBXUL
124 EXTRA_DSO_LDOPTS
= $(MOZ_COMPONENT_LIBS
)
127 include $(topsrcdir
)/config
/rules.mk
129 # We have to filter out -pedantic, because of
130 # comma-at-end-of-enumerator list failures. We can try to get this fixed
131 # upstream at some point.
132 CXXFLAGS
:= $(filter-out -pedantic
,$(CXXFLAGS
))
133 CFLAGS
:= $(filter-out -pedantic
,$(CFLAGS
))
136 # ANGLE only on Win32 for now, the solution isn't set up
150 ifdef MOZ_DIRECTX_SDK_PATH
151 INCLUDE
:= $(INCLUDE
);$(MOZ_DIRECTX_SDK_PATH
)\
include
152 LIB
:= $(LIB
);$(MOZ_DIRECTX_SDK_PATH
)\lib
\x86
155 ANGLE_DEP_PATTERNS
= \
156 src
/common
/*.
cpp src
/common
/*.h \
157 src
/compiler
/*.
cpp src
/compiler
/*.h \
158 src
/compiler
/preprocessor
/*.
cpp src
/compiler
/preprocessor
/*.h \
159 src
/libEGL
/*.
cpp src
/libEGL
/*.h \
160 src
/libGLESv2
/*.
cpp src
/libGLESv2
/*.h \
163 ANGLE_DEPS
= $(filter-out Gen_glslang.
cpp Gen_glslang_tab.
cpp glslang_tab.h
,$(wildcard $(ANGLE_DEP_PATTERNS
)))
165 libs
:: libGLESv2.dll libEGL.dll
166 $(INSTALL
) $(IFLAGS2
) libGLESv2.dll libEGL.dll
$(DIST
)/bin
168 # we don't want this to attempt to parallel-build these dlls;
169 # building one will build both.
170 libGLESv2.dll
: libEGL.dll
172 libEGL.dll
: $(GLOBAL_DEPS
) $(ANGLE_DEPS
)
173 @
(echo
"=== Building ANGLE via devenv.exe ===" \
174 && rm -rf angle-build
&& mkdir angle-build \
175 && cp
-r
$(srcdir)/src
$(srcdir)/include angle-build \
176 && cd angle-build
/src \
177 && echo
"Upgrading solution..." \
178 && devenv angle.sln
//upgrade \
179 && echo
"Building solution, target $(ANGLE_DIR)|Win32..." \
180 && devenv angle.sln
//useenv
//build
"$(ANGLE_DIR)|Win32" \
181 && echo
"Copying dlls..." \
182 && cp
$(ANGLE_DIR
)/*.dll ..
/..
)