summaryrefslogtreecommitdiff
path: root/src/glsl
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-06-24 17:08:53 -0700
committerEric Anholt <eric@anholt.net>2010-06-24 17:23:19 -0700
commit3d6012303c3ce24c75d209267e6914f706d025c5 (patch)
tree424f42ea536b04f80e8dcaee14ba9f3dd709a437 /src/glsl
parentf4869f33269c54779f8199b68e769024100421a3 (diff)
glsl2: Wrap includes of C interfaces with extern "C".
Diffstat (limited to 'src/glsl')
-rw-r--r--src/glsl/ast_type.cpp2
-rw-r--r--src/glsl/glsl_symbol_table.h2
-rw-r--r--src/glsl/glsl_types.cpp3
-rw-r--r--src/glsl/ir_clone.cpp2
-rw-r--r--src/glsl/ir_function_inlining.cpp2
-rw-r--r--src/glsl/ir_validate.cpp2
-rw-r--r--src/glsl/linker.cpp2
7 files changed, 14 insertions, 1 deletions
diff --git a/src/glsl/ast_type.cpp b/src/glsl/ast_type.cpp
index cb0852bb77..49dfde20e9 100644
--- a/src/glsl/ast_type.cpp
+++ b/src/glsl/ast_type.cpp
@@ -23,7 +23,9 @@
#include <cstdio>
#include "ast.h"
+extern "C" {
#include "symbol_table.h"
+}
void
ast_type_specifier::print(void) const
diff --git a/src/glsl/glsl_symbol_table.h b/src/glsl/glsl_symbol_table.h
index ae2fd3f4f1..8fbc66c974 100644
--- a/src/glsl/glsl_symbol_table.h
+++ b/src/glsl/glsl_symbol_table.h
@@ -28,7 +28,9 @@
#include <new>
+extern "C" {
#include "symbol_table.h"
+}
#include "ir.h"
#include "glsl_types.h"
diff --git a/src/glsl/glsl_types.cpp b/src/glsl/glsl_types.cpp
index bef267fa6b..9a53fbdbcb 100644
--- a/src/glsl/glsl_types.cpp
+++ b/src/glsl/glsl_types.cpp
@@ -27,8 +27,9 @@
#include "glsl_parser_extras.h"
#include "glsl_types.h"
#include "builtin_types.h"
+extern "C" {
#include "hash_table.h"
-
+}
hash_table *glsl_type::array_types = NULL;
diff --git a/src/glsl/ir_clone.cpp b/src/glsl/ir_clone.cpp
index 84176383fc..01a1ce3a6d 100644
--- a/src/glsl/ir_clone.cpp
+++ b/src/glsl/ir_clone.cpp
@@ -24,7 +24,9 @@
#include <string.h>
#include "ir.h"
#include "glsl_types.h"
+extern "C" {
#include "hash_table.h"
+}
/**
* Duplicate an IR variable
diff --git a/src/glsl/ir_function_inlining.cpp b/src/glsl/ir_function_inlining.cpp
index e55780c940..1adf67868e 100644
--- a/src/glsl/ir_function_inlining.cpp
+++ b/src/glsl/ir_function_inlining.cpp
@@ -33,7 +33,9 @@
#include "ir_function_inlining.h"
#include "ir_expression_flattening.h"
#include "glsl_types.h"
+extern "C" {
#include "hash_table.h"
+}
class ir_function_inlining_visitor : public ir_hierarchical_visitor {
public:
diff --git a/src/glsl/ir_validate.cpp b/src/glsl/ir_validate.cpp
index 507e88993f..1953852487 100644
--- a/src/glsl/ir_validate.cpp
+++ b/src/glsl/ir_validate.cpp
@@ -36,7 +36,9 @@
#include <inttypes.h>
#include "ir.h"
#include "ir_hierarchical_visitor.h"
+extern "C" {
#include "hash_table.h"
+}
static unsigned int hash_func(const void *key)
{
diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp
index ba382fe881..8547f74ce6 100644
--- a/src/glsl/linker.cpp
+++ b/src/glsl/linker.cpp
@@ -77,7 +77,9 @@ extern "C" {
#include "ir.h"
#include "ir_optimization.h"
#include "program.h"
+extern "C" {
#include "hash_table.h"
+}
/**
* Visitor that determines whether or not a variable is ever written.