Commit 27ffe641 authored by sgjesse@chromium.org's avatar sgjesse@chromium.org

On Linus don't force-export V8 symbols unless v8 is built as a shared library.

This lands: http://codereview.chromium.org/160556.

TBR=piman@chromium.org
Review URL: http://codereview.chromium.org/160634

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2622 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent fd956f70
......@@ -126,6 +126,7 @@ LIBRARY_FLAGS = {
'os:linux': {
'CCFLAGS': ['-ansi'] + GCC_EXTRA_CCFLAGS,
'library:shared': {
'CPPDEFINES': ['V8_SHARED'],
'LIBS': ['pthread']
}
},
......
......@@ -55,7 +55,7 @@ typedef long long int64_t; // NOLINT
// Setup for Linux shared library export. See v8.h in this directory for
// information on how to build/use V8 as shared library.
#if defined(__GNUC__) && (__GNUC__ >= 4)
#if defined(__GNUC__) && (__GNUC__ >= 4) && defined(V8_SHARED)
#define EXPORT __attribute__ ((visibility("default")))
#else // defined(__GNUC__) && (__GNUC__ >= 4)
#define EXPORT
......
......@@ -85,11 +85,10 @@ typedef unsigned __int64 uint64_t;
#include <stdint.h>
// Setup for Linux shared library export. There is no need to destinguish
// neither between building or using the V8 shared library nor between using
// the shared or static V8 library as there is on Windows. Therefore there is
// no checking of BUILDING_V8_SHARED and USING_V8_SHARED.
#if defined(__GNUC__) && (__GNUC__ >= 4)
// Setup for Linux shared library export. There is no need to distinguish
// between building or using the V8 shared library, but we should not
// export symbols when we are building a static library.
#if defined(__GNUC__) && (__GNUC__ >= 4) && defined(V8_SHARED)
#define V8EXPORT __attribute__ ((visibility("default")))
#define V8EXPORT_INLINE __attribute__ ((visibility("default")))
#else // defined(__GNUC__) && (__GNUC__ >= 4)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment