OSDN Git Service

GN files, initial check in
authorAlexis Hetu <sugoi@google.com>
Tue, 7 Jun 2016 23:53:42 +0000 (19:53 -0400)
committerAlexis Hétu <sugoi@google.com>
Thu, 9 Jun 2016 20:18:52 +0000 (20:18 +0000)
First version of Chromium build files for SwiftShader.
Works for Linux only at this point.
Other platforms are there, but untested at the moment.

Change-Id: I8f389db9937feda74c7009cf7a22938dab9e69d5
Reviewed-on: https://swiftshader-review.googlesource.com/5520
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
12 files changed:
BUILD.gn [new file with mode: 0644]
src/Common/BUILD.gn [new file with mode: 0644]
src/Main/BUILD.gn [new file with mode: 0644]
src/OpenGL/common/BUILD.gn [new file with mode: 0644]
src/OpenGL/compiler/BUILD.gn [new file with mode: 0644]
src/OpenGL/compiler/preprocessor/BUILD.gn [new file with mode: 0644]
src/OpenGL/libEGL/BUILD.gn [new file with mode: 0644]
src/OpenGL/libGLESv2/BUILD.gn [new file with mode: 0644]
src/Reactor/BUILD.gn [new file with mode: 0644]
src/Renderer/BUILD.gn [new file with mode: 0644]
src/Shader/BUILD.gn [new file with mode: 0644]
third_party/LLVM/BUILD.gn [new file with mode: 0644]

diff --git a/BUILD.gn b/BUILD.gn
new file mode 100644 (file)
index 0000000..318d422
--- /dev/null
+++ b/BUILD.gn
@@ -0,0 +1,72 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+config("swiftshader_config") {
+if (is_clang) {
+    cflags = [
+      "-std=c++11",
+    ]
+
+    if (is_debug) {
+        cflags += [
+        "-g",
+      ]
+    } else { # Release
+      # All Release builds use function/data sections to make the shared libraries smaller
+      cflags += [
+        "-ffunction-sections",
+        "-fdata-sections",
+        "-Wl",
+        "--gc-sections",
+        "-s",
+        "-fomit-frame-pointer",
+      ]
+
+      # Choose the right Release architecture
+      if (target_cpu == "x64") {
+        cflags += [
+          "-march=core2",
+        ]
+      } else { # 32
+        cflags += [
+          "-march=i686",
+        ]
+      }
+    }
+
+    if (target_cpu == "x64") { # 64 bit version
+      cflags += [
+        "-m64",
+        "-fPIC",
+      ]
+    } else { # 32 bit version
+      cflags += [
+        "-m32",
+      ]
+    }
+  }
+}
+
+component("swiftshader") {
+  configs -= [ "//build/config/compiler:chromium_code" ]
+  configs += [
+    "//build/config/compiler:no_chromium_code",
+    ":swiftshader_config",
+  ]
+
+  deps = [
+    "src/OpenGL/libEGL:swiftshader_libEGL",
+    "src/OpenGL/libGLESv2:swiftshader_libGLESv2",
+  ]
+}
\ No newline at end of file
diff --git a/src/Common/BUILD.gn b/src/Common/BUILD.gn
new file mode 100644 (file)
index 0000000..71ccbb9
--- /dev/null
@@ -0,0 +1,49 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_common_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_common\"",
+      "-msse2",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_common") {
+  sources = [
+    "CPUID.cpp",
+    "Configurator.cpp",
+    "Debug.cpp",
+    "Half.cpp",
+    "Math.cpp",
+    "Memory.cpp",
+    "Resource.cpp",
+    "Socket.cpp",
+    "Thread.cpp",
+    "Timer.cpp",
+  ]
+
+  configs += [
+    ":swiftshader_common_private_config",
+  ]
+}
\ No newline at end of file
diff --git a/src/Main/BUILD.gn b/src/Main/BUILD.gn
new file mode 100644 (file)
index 0000000..254256f
--- /dev/null
@@ -0,0 +1,68 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_main_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_main\"",
+      "-msse2",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_main") {
+  deps = [
+    "../Common:swiftshader_common",
+  ]
+
+  sources = [
+    "Config.cpp",
+    "FrameBuffer.cpp",
+    "SwiftConfig.cpp",
+  ]
+
+  if (host_os == "linux") {
+    sources += [
+      "libX11.cpp",
+      "FrameBufferX11.cpp",
+    ]
+  } else if (host_os == "mac") {
+    sources += [
+      "FrameBufferOSX.mm",
+    ]
+  } else if (host_os == "win") {
+    sources += [
+      "FrameBufferDD.cpp",
+      "FrameBufferGDI.cpp",
+      "FrameBufferWin.cpp",
+    ]
+  }
+
+  configs += [
+    ":swiftshader_main_private_config",
+  ]
+
+  include_dirs = [
+    "..",
+    "../Common",
+  ]
+}
\ No newline at end of file
diff --git a/src/OpenGL/common/BUILD.gn b/src/OpenGL/common/BUILD.gn
new file mode 100644 (file)
index 0000000..0a23385
--- /dev/null
@@ -0,0 +1,48 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_opengl_common_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_opengl_common\"",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_opengl_common") {
+  sources = [
+    "debug.cpp",
+    "Image.cpp",
+    "Object.cpp",
+    "MatrixStack.cpp",
+  ]
+
+  configs += [
+    ":swiftshader_opengl_common_private_config",
+  ]
+
+  include_dirs = [
+    "..",
+    "../..",
+    "../../../include",
+  ]
+}
\ No newline at end of file
diff --git a/src/OpenGL/compiler/BUILD.gn b/src/OpenGL/compiler/BUILD.gn
new file mode 100644 (file)
index 0000000..a7b4c2b
--- /dev/null
@@ -0,0 +1,82 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_opengl_compiler_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_opengl_compiler\"",
+      "-Wno-sign-compare",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_opengl_compiler") {
+  deps = [
+    "preprocessor:swiftshader_opengl_preprocessor",
+  ]
+
+  sources = [
+    "AnalyzeCallDepth.cpp",
+    "Compiler.cpp",
+    "debug.cpp",
+    "Diagnostics.cpp",
+    "DirectiveHandler.cpp",
+    "glslang_lex.cpp",
+    "glslang_tab.cpp",
+    "InfoSink.cpp",
+    "Initialize.cpp",
+    "InitializeParseContext.cpp",
+    "IntermTraverse.cpp",
+    "Intermediate.cpp",
+    "intermOut.cpp",
+    "OutputASM.cpp",
+    "parseConst.cpp",
+    "ParseHelper.cpp",
+    "PoolAlloc.cpp",
+    "SymbolTable.cpp",
+    "TranslatorASM.cpp",
+    "util.cpp",
+    "ValidateGlobalInitializer.cpp",
+    "ValidateLimitations.cpp",
+    "ValidateSwitch.cpp",
+  ]
+
+  if ((host_os == "linux") || (host_os == "mac")) {
+    sources += [
+      "ossource_posix.cpp",
+    ]
+  } else if (host_os == "win") {
+    sources += [
+      "ossource_win.cpp",
+    ]
+  }
+
+  configs += [
+    ":swiftshader_opengl_compiler_private_config",
+  ]
+
+  include_dirs = [
+    "..",
+    "../..",
+    "../../../include",
+  ]
+}
\ No newline at end of file
diff --git a/src/OpenGL/compiler/preprocessor/BUILD.gn b/src/OpenGL/compiler/preprocessor/BUILD.gn
new file mode 100644 (file)
index 0000000..6c6ff25
--- /dev/null
@@ -0,0 +1,49 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_opengl_preprocessor_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_opengl_compiler\"",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_opengl_preprocessor") {
+  sources = [
+    "Diagnostics.cpp",
+    "DirectiveHandler.cpp",
+    "DirectiveParser.cpp",
+    "ExpressionParser.cpp",
+    "Input.cpp",
+    "Lexer.cpp",
+    "Macro.cpp",
+    "MacroExpander.cpp",
+    "Preprocessor.cpp",
+    "Token.cpp",
+    "Tokenizer.cpp",
+  ]
+
+  configs += [
+    ":swiftshader_opengl_preprocessor_private_config",
+  ]
+}
\ No newline at end of file
diff --git a/src/OpenGL/libEGL/BUILD.gn b/src/OpenGL/libEGL/BUILD.gn
new file mode 100644 (file)
index 0000000..ddd4b94
--- /dev/null
@@ -0,0 +1,69 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_libEGL_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_libEGL\"",
+      "-DEGLAPI=",
+      "-DEGL_EGLEXT_PROTOTYPES",
+      "-Wno-sign-compare",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+shared_library("swiftshader_libEGL") {
+  deps = [
+    "../../Common:swiftshader_common",
+    "../../Reactor:swiftshader_reactor",
+    "../../Renderer:swiftshader_renderer",
+    "../../OpenGL/common:swiftshader_opengl_common",
+    "../../OpenGL/compiler:swiftshader_opengl_compiler",
+    "../../Shader:swiftshader_shader",
+    "../../Main:swiftshader_main",
+    "../../../third_party/LLVM:swiftshader_llvm",
+  ]
+
+  sources = [
+    "Config.cpp",
+    "Display.cpp",
+    "Surface.cpp",
+    "libEGL.cpp",
+    "main.cpp",
+  ]
+
+  if (host_os == "mac") {
+    sources += [
+      "OSXUtils.mm",
+    ]
+  }
+
+  configs += [
+    ":swiftshader_libEGL_private_config",
+  ]
+
+  include_dirs = [
+    "../../../include",
+    "../..",
+    "..",
+  ]
+}
\ No newline at end of file
diff --git a/src/OpenGL/libGLESv2/BUILD.gn b/src/OpenGL/libGLESv2/BUILD.gn
new file mode 100644 (file)
index 0000000..90a811f
--- /dev/null
@@ -0,0 +1,81 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_libGLESv2_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_libGLESv2\"",
+      "-fno-operator-names",
+      "-D__STDC_CONSTANT_MACROS",
+      "-D__STDC_LIMIT_MACROS",
+      "-DGL_API=",
+      "-DGL_APICALL=",
+      "-DGL_GLEXT_PROTOTYPES",
+      "-Wno-sign-compare",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+shared_library("swiftshader_libGLESv2") {
+  deps = [
+    "../../Common:swiftshader_common",
+    "../../Reactor:swiftshader_reactor",
+    "../../Renderer:swiftshader_renderer",
+    "../../OpenGL/common:swiftshader_opengl_common",
+    "../../OpenGL/compiler:swiftshader_opengl_compiler",
+    "../../Shader:swiftshader_shader",
+    "../../Main:swiftshader_main",
+    "../../../third_party/LLVM:swiftshader_llvm",
+  ]
+
+  sources = [
+    "Buffer.cpp",
+    "Context.cpp",
+    "Device.cpp",
+    "Fence.cpp",
+    "Framebuffer.cpp",
+    "IndexDataManager.cpp",
+    "libGLESv2.cpp",
+    "libGLESv3.cpp",
+    "main.cpp",
+    "Program.cpp",
+    "Query.cpp",
+    "Renderbuffer.cpp",
+    "ResourceManager.cpp",
+    "Shader.cpp",
+    "Texture.cpp",
+    "TransformFeedback.cpp",
+    "utilities.cpp",
+    "VertexArray.cpp",
+    "VertexDataManager.cpp",
+  ]
+
+  configs += [
+    ":swiftshader_libGLESv2_private_config",
+  ]
+
+  include_dirs = [
+    "../../../include",
+    "../..",
+    "..",
+  ]
+}
\ No newline at end of file
diff --git a/src/Reactor/BUILD.gn b/src/Reactor/BUILD.gn
new file mode 100644 (file)
index 0000000..aa65be2
--- /dev/null
@@ -0,0 +1,62 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_reactor_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_reactor\"",
+      "-Wno-unused-local-typedef",
+      "-msse2",
+      "-D__STDC_CONSTANT_MACROS",
+      "-D__STDC_LIMIT_MACROS",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_reactor") {
+  deps = [
+    "../Common:swiftshader_common",
+    "../../third_party/LLVM:swiftshader_llvm",
+  ]
+
+  sources = [
+    "Nucleus.cpp",
+    "Routine.cpp",
+    "RoutineManager.cpp",
+  ]
+
+  if (host_os == "win") {
+    sources += [
+      "DLL.cpp",
+    ]
+  }
+
+  configs += [
+    ":swiftshader_reactor_private_config",
+  ]
+
+  include_dirs = [
+    "..",
+    "../Common",
+    "../../third_party/LLVM/include/",
+  ]
+}
\ No newline at end of file
diff --git a/src/Renderer/BUILD.gn b/src/Renderer/BUILD.gn
new file mode 100644 (file)
index 0000000..ee5213d
--- /dev/null
@@ -0,0 +1,72 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_renderer_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_renderer\"",
+      "-fno-operator-names",
+      "-msse2",
+      "-Wno-sign-compare",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_renderer") {
+  deps = [
+    "../Common:swiftshader_common",
+    "../Shader:swiftshader_shader",
+    "../Main:swiftshader_main",
+  ]
+
+  sources = [
+    "Blitter.cpp",
+    "Clipper.cpp",
+    "Color.cpp",
+    "Context.cpp",
+    "ETC_Decoder.cpp",
+    "Matrix.cpp",
+    "PixelProcessor.cpp",
+    "Plane.cpp",
+    "Point.cpp",
+    "QuadRasterizer.cpp",
+    "Renderer.cpp",
+    "Sampler.cpp",
+    "SetupProcessor.cpp",
+    "Surface.cpp",
+    "TextureStage.cpp",
+    "Vector.cpp",
+    "VertexProcessor.cpp",
+  ]
+
+  configs += [
+    ":swiftshader_renderer_private_config",
+  ]
+
+  include_dirs = [
+    ".",
+    "..",
+    "../Common",
+    "../Main",
+    "../Shader",
+  ]
+}
\ No newline at end of file
diff --git a/src/Shader/BUILD.gn b/src/Shader/BUILD.gn
new file mode 100644 (file)
index 0000000..3e9a96c
--- /dev/null
@@ -0,0 +1,65 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_shader_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-DLOG_TAG=\"swiftshader_shader\"",
+      "-fno-operator-names",
+    ]
+
+    if (!is_debug) {
+      cflags += [
+        "-DNDEBUG",
+        "-DANGLE_DISABLE_TRACE",
+      ]
+    }
+  }
+}
+
+source_set("swiftshader_shader") {
+  deps = [
+    "../Common:swiftshader_common",
+    "../Main:swiftshader_main",
+  ]
+
+  sources = [
+    "Constants.cpp",
+    "PixelPipeline.cpp",
+    "PixelProgram.cpp",
+    "PixelRoutine.cpp",
+    "PixelShader.cpp",
+    "SamplerCore.cpp",
+    "SetupRoutine.cpp",
+    "Shader.cpp",
+    "ShaderCore.cpp",
+    "VertexPipeline.cpp",
+    "VertexProgram.cpp",
+    "VertexRoutine.cpp",
+    "VertexShader.cpp",
+  ]
+
+  configs += [
+    ":swiftshader_shader_private_config",
+  ]
+
+  include_dirs = [
+    ".",
+    "..",
+    "../Common",
+    "../Main",
+    "../Renderer",
+  ]
+}
\ No newline at end of file
diff --git a/third_party/LLVM/BUILD.gn b/third_party/LLVM/BUILD.gn
new file mode 100644 (file)
index 0000000..ba7ab69
--- /dev/null
@@ -0,0 +1,419 @@
+# Copyright 2016 The SwiftShader Authors. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Need a separate config to ensure the warnings are added to the end.
+config("swiftshader_llvm_private_config") {
+  if (is_clang) {
+    cflags = [
+      "-fno-operator-names",
+      "-msse2",
+      "-D__STDC_CONSTANT_MACROS",
+      "-D__STDC_LIMIT_MACROS",
+      "-Wno-unused-local-typedef",
+      "-Wno-unused-private-field",
+      "-Wno-null-dereference",
+      "-Wno-header-hygiene",
+      "-Wno-unused-function",
+      "-Wno-deprecated-declarations",
+      "-Wno-unused-variable",
+    ]
+  }
+}
+
+source_set("swiftshader_llvm") {
+  sources = [
+    "lib/Analysis/AliasAnalysis.cpp",
+    "lib/Analysis/AliasSetTracker.cpp",
+    "lib/Analysis/BasicAliasAnalysis.cpp",
+    "lib/Analysis/BranchProbabilityInfo.cpp",
+    "lib/Analysis/CaptureTracking.cpp",
+    "lib/Analysis/ConstantFolding.cpp",
+    "lib/Analysis/DebugInfo.cpp",
+    "lib/Analysis/DIBuilder.cpp",
+    "lib/Analysis/InstructionSimplify.cpp",
+    "lib/Analysis/IVUsers.cpp",
+    "lib/Analysis/Loads.cpp",
+    "lib/Analysis/LoopInfo.cpp",
+    "lib/Analysis/LoopPass.cpp",
+    "lib/Analysis/MemoryBuiltins.cpp",
+    "lib/Analysis/MemoryDependenceAnalysis.cpp",
+    "lib/Analysis/NoAliasAnalysis.cpp",
+    "lib/Analysis/PathNumbering.cpp",
+    "lib/Analysis/PHITransAddr.cpp",
+    "lib/Analysis/ProfileInfo.cpp",
+    "lib/Analysis/ScalarEvolution.cpp",
+    "lib/Analysis/ScalarEvolutionExpander.cpp",
+    "lib/Analysis/ScalarEvolutionNormalization.cpp",
+    "lib/Analysis/TypeBasedAliasAnalysis.cpp",
+    "lib/Analysis/ValueTracking.cpp",
+    "lib/CodeGen/SelectionDAG/DAGCombiner.cpp",
+    "lib/CodeGen/SelectionDAG/FastISel.cpp",
+    "lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp",
+    "lib/CodeGen/SelectionDAG/InstrEmitter.cpp",
+    "lib/CodeGen/SelectionDAG/LegalizeDAG.cpp",
+    "lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp",
+    "lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp",
+    "lib/CodeGen/SelectionDAG/LegalizeTypes.cpp",
+    "lib/CodeGen/SelectionDAG/LegalizeTypesGeneric.cpp",
+    "lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp",
+    "lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp",
+    "lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp",
+    "lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp",
+    "lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp",
+    "lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp",
+    "lib/CodeGen/SelectionDAG/SelectionDAG.cpp",
+    "lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp",
+    "lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp",
+    "lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp",
+    "lib/CodeGen/SelectionDAG/TargetLowering.cpp",
+    "lib/CodeGen/SelectionDAG/TargetSelectionDAGInfo.cpp",
+    "lib/CodeGen/AggressiveAntiDepBreaker.cpp",
+    "lib/CodeGen/AllocationOrder.cpp",
+    "lib/CodeGen/Analysis.cpp",
+    "lib/CodeGen/BranchFolding.cpp",
+    "lib/CodeGen/CalcSpillWeights.cpp",
+    "lib/CodeGen/CallingConvLower.cpp",
+    "lib/CodeGen/CodeGen.cpp",
+    "lib/CodeGen/CodePlacementOpt.cpp",
+    "lib/CodeGen/CriticalAntiDepBreaker.cpp",
+    "lib/CodeGen/DeadMachineInstructionElim.cpp",
+    "lib/CodeGen/DwarfEHPrepare.cpp",
+    "lib/CodeGen/EdgeBundles.cpp",
+    "lib/CodeGen/ELFCodeEmitter.cpp",
+    "lib/CodeGen/ELFWriter.cpp",
+    "lib/CodeGen/ExecutionDepsFix.cpp",
+    "lib/CodeGen/ExpandISelPseudos.cpp",
+    "lib/CodeGen/ExpandPostRAPseudos.cpp",
+    "lib/CodeGen/GCMetadata.cpp",
+    "lib/CodeGen/GCStrategy.cpp",
+    "lib/CodeGen/IfConversion.cpp",
+    "lib/CodeGen/InlineSpiller.cpp",
+    "lib/CodeGen/InterferenceCache.cpp",
+    "lib/CodeGen/IntrinsicLowering.cpp",
+    "lib/CodeGen/LatencyPriorityQueue.cpp",
+    "lib/CodeGen/LexicalScopes.cpp",
+    "lib/CodeGen/LiveDebugVariables.cpp",
+    "lib/CodeGen/LiveIntervalAnalysis.cpp",
+    "lib/CodeGen/LiveInterval.cpp",
+    "lib/CodeGen/LiveIntervalUnion.cpp",
+    "lib/CodeGen/LiveRangeCalc.cpp",
+    "lib/CodeGen/LiveRangeEdit.cpp",
+    "lib/CodeGen/LiveStackAnalysis.cpp",
+    "lib/CodeGen/LiveVariables.cpp",
+    "lib/CodeGen/LLVMTargetMachine.cpp",
+    "lib/CodeGen/LocalStackSlotAllocation.cpp",
+    "lib/CodeGen/MachineBasicBlock.cpp",
+    "lib/CodeGen/MachineBlockFrequencyInfo.cpp",
+    "lib/CodeGen/MachineBranchProbabilityInfo.cpp",
+    "lib/CodeGen/MachineCSE.cpp",
+    "lib/CodeGen/MachineDominators.cpp",
+    "lib/CodeGen/MachineFunctionAnalysis.cpp",
+    "lib/CodeGen/MachineFunction.cpp",
+    "lib/CodeGen/MachineFunctionPass.cpp",
+    "lib/CodeGen/MachineFunctionPrinterPass.cpp",
+    "lib/CodeGen/MachineInstr.cpp",
+    "lib/CodeGen/MachineLICM.cpp",
+    "lib/CodeGen/MachineLoopInfo.cpp",
+    "lib/CodeGen/MachineLoopRanges.cpp",
+    "lib/CodeGen/MachineModuleInfo.cpp",
+    "lib/CodeGen/MachineModuleInfoImpls.cpp",
+    "lib/CodeGen/MachinePassRegistry.cpp",
+    "lib/CodeGen/MachineRegisterInfo.cpp",
+    "lib/CodeGen/MachineSink.cpp",
+    "lib/CodeGen/MachineSSAUpdater.cpp",
+    "lib/CodeGen/MachineVerifier.cpp",
+    "lib/CodeGen/ObjectCodeEmitter.cpp",
+    "lib/CodeGen/OcamlGC.cpp",
+    "lib/CodeGen/OptimizePHIs.cpp",
+    "lib/CodeGen/Passes.cpp",
+    "lib/CodeGen/PeepholeOptimizer.cpp",
+    "lib/CodeGen/PHIElimination.cpp",
+    "lib/CodeGen/PHIEliminationUtils.cpp",
+    "lib/CodeGen/PostRASchedulerList.cpp",
+    "lib/CodeGen/ProcessImplicitDefs.cpp",
+    "lib/CodeGen/PrologEpilogInserter.cpp",
+    "lib/CodeGen/PseudoSourceValue.cpp",
+    "lib/CodeGen/RegAllocBasic.cpp",
+    "lib/CodeGen/RegAllocFast.cpp",
+    "lib/CodeGen/RegAllocGreedy.cpp",
+    "lib/CodeGen/RegAllocLinearScan.cpp",
+    "lib/CodeGen/RegAllocPBQP.cpp",
+    "lib/CodeGen/RegisterClassInfo.cpp",
+    "lib/CodeGen/RegisterCoalescer.cpp",
+    "lib/CodeGen/RegisterScavenging.cpp",
+    "lib/CodeGen/RenderMachineFunction.cpp",
+    "lib/CodeGen/ScheduleDAG.cpp",
+    "lib/CodeGen/ScheduleDAGEmit.cpp",
+    "lib/CodeGen/ScheduleDAGInstrs.cpp",
+    "lib/CodeGen/ScheduleDAGPrinter.cpp",
+    "lib/CodeGen/ScoreboardHazardRecognizer.cpp",
+    "lib/CodeGen/ShadowStackGC.cpp",
+    "lib/CodeGen/ShrinkWrapping.cpp",
+    "lib/CodeGen/SjLjEHPrepare.cpp",
+    "lib/CodeGen/SlotIndexes.cpp",
+    "lib/CodeGen/Spiller.cpp",
+    "lib/CodeGen/SpillPlacement.cpp",
+    "lib/CodeGen/SplitKit.cpp",
+    "lib/CodeGen/Splitter.cpp",
+    "lib/CodeGen/StackProtector.cpp",
+    "lib/CodeGen/StackSlotColoring.cpp",
+    "lib/CodeGen/StrongPHIElimination.cpp",
+    "lib/CodeGen/TailDuplication.cpp",
+    "lib/CodeGen/TargetInstrInfoImpl.cpp",
+    "lib/CodeGen/TargetLoweringObjectFileImpl.cpp",
+    "lib/CodeGen/TwoAddressInstructionPass.cpp",
+    "lib/CodeGen/UnreachableBlockElim.cpp",
+    "lib/CodeGen/VirtRegMap.cpp",
+    "lib/CodeGen/VirtRegRewriter.cpp",
+    "lib/ExecutionEngine/JIT/Intercept.cpp",
+    "lib/ExecutionEngine/JIT/JIT.cpp",
+    "lib/ExecutionEngine/JIT/JITDebugRegisterer.cpp",
+    "lib/ExecutionEngine/JIT/JITDwarfEmitter.cpp",
+    "lib/ExecutionEngine/JIT/JITEmitter.cpp",
+    "lib/ExecutionEngine/JIT/JITMemoryManager.cpp",
+    "lib/ExecutionEngine/JIT/OProfileJITEventListener.cpp",
+    "lib/ExecutionEngine/ExecutionEngine.cpp",
+    "lib/ExecutionEngine/TargetSelect.cpp",
+    "lib/MC/ELFObjectWriter.cpp",
+    "lib/MC/MachObjectWriter.cpp",
+    "lib/MC/MCAsmBackend.cpp",
+    "lib/MC/MCAsmInfoCOFF.cpp",
+    "lib/MC/MCAsmInfo.cpp",
+    "lib/MC/MCAsmInfoDarwin.cpp",
+    "lib/MC/MCAsmStreamer.cpp",
+    "lib/MC/MCAssembler.cpp",
+    "lib/MC/MCAtom.cpp",
+    "lib/MC/MCCodeEmitter.cpp",
+    "lib/MC/MCCodeGenInfo.cpp",
+    "lib/MC/MCContext.cpp",
+    "lib/MC/MCDisassembler.cpp",
+    "lib/MC/MCDwarf.cpp",
+    "lib/MC/MCELF.cpp",
+    "lib/MC/MCELFObjectTargetWriter.cpp",
+    "lib/MC/MCELFStreamer.cpp",
+    "lib/MC/MCExpr.cpp",
+    "lib/MC/MCInst.cpp",
+    "lib/MC/MCInstPrinter.cpp",
+    "lib/MC/MCInstrAnalysis.cpp",
+    "lib/MC/MCLabel.cpp",
+    "lib/MC/MCLoggingStreamer.cpp",
+    "lib/MC/MCMachObjectTargetWriter.cpp",
+    "lib/MC/MCMachOStreamer.cpp",
+    "lib/MC/MCModule.cpp",
+    "lib/MC/MCNullStreamer.cpp",
+    "lib/MC/MCObjectFileInfo.cpp",
+    "lib/MC/MCObjectStreamer.cpp",
+    "lib/MC/MCObjectWriter.cpp",
+    "lib/MC/MCPureStreamer.cpp",
+    "lib/MC/MCSectionCOFF.cpp",
+    "lib/MC/MCSection.cpp",
+    "lib/MC/MCSectionELF.cpp",
+    "lib/MC/MCSectionMachO.cpp",
+    "lib/MC/MCStreamer.cpp",
+    "lib/MC/MCSubtargetInfo.cpp",
+    "lib/MC/MCSymbol.cpp",
+    "lib/MC/MCTargetAsmLexer.cpp",
+    "lib/MC/MCValue.cpp",
+    "lib/MC/MCWin64EH.cpp",
+    "lib/MC/SubtargetFeature.cpp",
+    "lib/MC/WinCOFFObjectWriter.cpp",
+    "lib/MC/WinCOFFStreamer.cpp",
+    "lib/Support/Allocator.cpp",
+    "lib/Support/APFloat.cpp",
+    "lib/Support/APInt.cpp",
+    "lib/Support/APSInt.cpp",
+    "lib/Support/Atomic.cpp",
+    "lib/Support/BlockFrequency.cpp",
+    "lib/Support/BranchProbability.cpp",
+    "lib/Support/circular_raw_ostream.cpp",
+    "lib/Support/CommandLine.cpp",
+    "lib/Support/ConstantRange.cpp",
+    "lib/Support/CrashRecoveryContext.cpp",
+    "lib/Support/DAGDeltaAlgorithm.cpp",
+    "lib/Support/DataExtractor.cpp",
+    "lib/Support/Debug.cpp",
+    "lib/Support/DeltaAlgorithm.cpp",
+    "lib/Support/Disassembler.cpp",
+    "lib/Support/Dwarf.cpp",
+    "lib/Support/DynamicLibrary.cpp",
+    "lib/Support/Errno.cpp",
+    "lib/Support/ErrorHandling.cpp",
+    "lib/Support/FileUtilities.cpp",
+    "lib/Support/FoldingSet.cpp",
+    "lib/Support/FormattedStream.cpp",
+    "lib/Support/GraphWriter.cpp",
+    "lib/Support/Host.cpp",
+    "lib/Support/IncludeFile.cpp",
+    "lib/Support/IntEqClasses.cpp",
+    "lib/Support/IntervalMap.cpp",
+    "lib/Support/IsInf.cpp",
+    "lib/Support/IsNAN.cpp",
+    "lib/Support/ManagedStatic.cpp",
+    "lib/Support/MemoryBuffer.cpp",
+    "lib/Support/Memory.cpp",
+    "lib/Support/MemoryObject.cpp",
+    "lib/Support/Mutex.cpp",
+    "lib/Support/Path.cpp",
+    "lib/Support/PathV2.cpp",
+    "lib/Support/PluginLoader.cpp",
+    "lib/Support/PrettyStackTrace.cpp",
+    "lib/Support/Process.cpp",
+    "lib/Support/Program.cpp",
+    "lib/Support/raw_os_ostream.cpp",
+    "lib/Support/raw_ostream.cpp",
+    "lib/Support/RWMutex.cpp",
+    "lib/Support/SearchForAddressOfSpecialSymbol.cpp",
+    "lib/Support/Signals.cpp",
+    "lib/Support/SmallPtrSet.cpp",
+    "lib/Support/SmallVector.cpp",
+    "lib/Support/SourceMgr.cpp",
+    "lib/Support/Statistic.cpp",
+    "lib/Support/StringExtras.cpp",
+    "lib/Support/StringMap.cpp",
+    "lib/Support/StringPool.cpp",
+    "lib/Support/StringRef.cpp",
+    "lib/Support/system_error.cpp",
+    "lib/Support/SystemUtils.cpp",
+    "lib/Support/TargetRegistry.cpp",
+    "lib/Support/Threading.cpp",
+    "lib/Support/ThreadLocal.cpp",
+    "lib/Support/Timer.cpp",
+    "lib/Support/TimeValue.cpp",
+    "lib/Support/ToolOutputFile.cpp",
+    "lib/Support/Triple.cpp",
+    "lib/Support/Twine.cpp",
+    "lib/Support/Valgrind.cpp",
+    "lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp",
+    "lib/Target/X86/InstPrinter/X86InstComments.cpp",
+    "lib/Target/X86/InstPrinter/X86IntelInstPrinter.cpp",
+    "lib/Target/X86/MCTargetDesc/X86AsmBackend.cpp",
+    "lib/Target/X86/MCTargetDesc/X86MachObjectWriter.cpp",
+    "lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp",
+    "lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp",
+    "lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp",
+    "lib/Target/X86/TargetInfo/X86TargetInfo.cpp",
+    "lib/Target/X86/Utils/X86ShuffleDecode.cpp",
+    "lib/Target/X86/X86CodeEmitter.cpp",
+    "lib/Target/X86/X86ELFWriterInfo.cpp",
+    "lib/Target/X86/X86FastISel.cpp",
+    "lib/Target/X86/X86FloatingPoint.cpp",
+    "lib/Target/X86/X86FrameLowering.cpp",
+    "lib/Target/X86/X86InstrInfo.cpp",
+    "lib/Target/X86/X86ISelDAGToDAG.cpp",
+    "lib/Target/X86/X86ISelLowering.cpp",
+    "lib/Target/X86/X86JITInfo.cpp",
+    "lib/Target/X86/X86RegisterInfo.cpp",
+    "lib/Target/X86/X86SelectionDAGInfo.cpp",
+    "lib/Target/X86/X86Subtarget.cpp",
+    "lib/Target/X86/X86TargetMachine.cpp",
+    "lib/Target/X86/X86TargetObjectFile.cpp",
+    "lib/Target/X86/X86VZeroUpper.cpp",
+    "lib/Target/Mangler.cpp",
+    "lib/Target/Target.cpp",
+    "lib/Target/TargetData.cpp",
+    "lib/Target/TargetELFWriterInfo.cpp",
+    "lib/Target/TargetFrameLowering.cpp",
+    "lib/Target/TargetInstrInfo.cpp",
+    "lib/Target/TargetLibraryInfo.cpp",
+    "lib/Target/TargetLoweringObjectFile.cpp",
+    "lib/Target/TargetMachine.cpp",
+    "lib/Target/TargetRegisterInfo.cpp",
+    "lib/Target/TargetSubtargetInfo.cpp",
+    "lib/Transforms/InstCombine/InstCombineAddSub.cpp",
+    "lib/Transforms/InstCombine/InstCombineAndOrXor.cpp",
+    "lib/Transforms/InstCombine/InstCombineCalls.cpp",
+    "lib/Transforms/InstCombine/InstCombineCasts.cpp",
+    "lib/Transforms/InstCombine/InstCombineCompares.cpp",
+    "lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp",
+    "lib/Transforms/InstCombine/InstCombineMulDivRem.cpp",
+    "lib/Transforms/InstCombine/InstCombinePHI.cpp",
+    "lib/Transforms/InstCombine/InstCombineSelect.cpp",
+    "lib/Transforms/InstCombine/InstCombineShifts.cpp",
+    "lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp",
+    "lib/Transforms/InstCombine/InstCombineVectorOps.cpp",
+    "lib/Transforms/InstCombine/InstructionCombining.cpp",
+    "lib/Transforms/Scalar/ADCE.cpp",
+    "lib/Transforms/Scalar/CodeGenPrepare.cpp",
+    "lib/Transforms/Scalar/DeadStoreElimination.cpp",
+    "lib/Transforms/Scalar/GVN.cpp",
+    "lib/Transforms/Scalar/LICM.cpp",
+    "lib/Transforms/Scalar/LoopStrengthReduce.cpp",
+    "lib/Transforms/Scalar/Reassociate.cpp",
+    "lib/Transforms/Scalar/Reg2Mem.cpp",
+    "lib/Transforms/Scalar/ScalarReplAggregates.cpp",
+    "lib/Transforms/Scalar/SCCP.cpp",
+    "lib/Transforms/Scalar/SimplifyCFGPass.cpp",
+    "lib/Transforms/Utils/AddrModeMatcher.cpp",
+    "lib/Transforms/Utils/BasicBlockUtils.cpp",
+    "lib/Transforms/Utils/BreakCriticalEdges.cpp",
+    "lib/Transforms/Utils/BuildLibCalls.cpp",
+    "lib/Transforms/Utils/DemoteRegToStack.cpp",
+    "lib/Transforms/Utils/InstructionNamer.cpp",
+    "lib/Transforms/Utils/LCSSA.cpp",
+    "lib/Transforms/Utils/Local.cpp",
+    "lib/Transforms/Utils/LoopSimplify.cpp",
+    "lib/Transforms/Utils/LowerInvoke.cpp",
+    "lib/Transforms/Utils/LowerSwitch.cpp",
+    "lib/Transforms/Utils/Mem2Reg.cpp",
+    "lib/Transforms/Utils/PromoteMemoryToRegister.cpp",
+    "lib/Transforms/Utils/SimplifyCFG.cpp",
+    "lib/Transforms/Utils/SSAUpdater.cpp",
+    "lib/Transforms/Utils/UnifyFunctionExitNodes.cpp",
+    "lib/VMCore/AsmWriter.cpp",
+    "lib/VMCore/Attributes.cpp",
+    "lib/VMCore/AutoUpgrade.cpp",
+    "lib/VMCore/BasicBlock.cpp",
+    "lib/VMCore/ConstantFold.cpp",
+    "lib/VMCore/Constants.cpp",
+    "lib/VMCore/Core.cpp",
+    "lib/VMCore/DebugInfoProbe.cpp",
+    "lib/VMCore/DebugLoc.cpp",
+    "lib/VMCore/Dominators.cpp",
+    "lib/VMCore/Function.cpp",
+    "lib/VMCore/GCOV.cpp",
+    "lib/VMCore/Globals.cpp",
+    "lib/VMCore/GVMaterializer.cpp",
+    "lib/VMCore/InlineAsm.cpp",
+    "lib/VMCore/Instruction.cpp",
+    "lib/VMCore/Instructions.cpp",
+    "lib/VMCore/IntrinsicInst.cpp",
+    "lib/VMCore/IRBuilder.cpp",
+    "lib/VMCore/LeakDetector.cpp",
+    "lib/VMCore/LLVMContext.cpp",
+    "lib/VMCore/LLVMContextImpl.cpp",
+    "lib/VMCore/Metadata.cpp",
+    "lib/VMCore/Module.cpp",
+    "lib/VMCore/Pass.cpp",
+    "lib/VMCore/PassManager.cpp",
+    "lib/VMCore/PassRegistry.cpp",
+    "lib/VMCore/PrintModulePass.cpp",
+    "lib/VMCore/Type.cpp",
+    "lib/VMCore/Use.cpp",
+    "lib/VMCore/User.cpp",
+    "lib/VMCore/Value.cpp",
+    "lib/VMCore/ValueSymbolTable.cpp",
+    "lib/VMCore/ValueTypes.cpp",
+    "lib/VMCore/Verifier.cpp",
+  ]
+
+  configs += [
+    ":swiftshader_llvm_private_config",
+  ]
+
+  include_dirs = [
+    "include-linux",
+    "include",
+    "lib/Target/X86",
+  ]
+}
\ No newline at end of file