DescriptionANGLE GCC compilation fixes
The following series fixes compilation on GCC (from mingw-w64) and allows cross compiling the source on Linux. It was tested in Mozilla tree since ANGLE has no support for GCC in its build system.
Originally it was a series of separated patches for easier review, but it looks like codereview doesn't support it (I'm new to the system, so sorry if I missed something). Here are my original changelogs:
Moved SSE2 code to separated file to allow using different compiler flags on GCC
To use SSE2 in GCC, a compiler -msse2 flag is needed. It adds both possibility to write SSE2 code in the file, but also allows compiles to optimize the whole file with SSE2. To make sure that the code works on non-SSE2 machines, moving SSE2 functions to separated file and compiling only that file with -msse2 is the common practice.
Minor GCC fixes
- Added missing typename keyword
- Use proper filenames in cludes (this matters when cross compiling on case sensitive OSes)
- Added <string> include where GCC requires it
- Avoid collision between enum variables and template params
Use unordered_map instead of hash_map on GCC
stdext namespace is a non-standard extension. Use standard std::unordered_map on GCC.
Fixed preprocessors errors on GCC
- Preprocessor variables need to be separated from string constants to be separated token
- Use ##__VA_ARGS__ GCC extension to support empry __VA_ARGS__ (should be no-op on MSVC). See:
http://www.delorie.com/gnu/docs/gcc/gcc_44.html
for details.
Patch Set 1 #
Total comments: 1
MessagesTotal messages: 2
|