summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernhard Rosenkraenzer <Bernhard.Rosenkranzer@linaro.org>2012-07-12 00:33:35 +0159
committerBernhard Rosenkraenzer <Bernhard.Rosenkranzer@linaro.org>2012-07-12 00:33:35 +0159
commit6196513082f86dacbcadf05653e6b9c6f340330d (patch)
treeb98b2c4d905f5010fa736fc66df73a120df99e30
parentf455c9a267332960334794428c2abc5f716ee6ea (diff)
downloadnative-6196513082f86dacbcadf05653e6b9c6f340330d.tar.gz
frameworks/base: Make sure Singleton instantiations are exported
This fixes using Singletons across shared library borders with gcc 4.7+ Change-Id: I84b9cc99add4ace64c16e4fa8414a4fc7e4693c7 Signed-off-by: Bernhard Rosenkraenzer <Bernhard.Rosenkranzer@linaro.org>
-rw-r--r--include/utils/Singleton.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/utils/Singleton.h b/include/utils/Singleton.h
index a42ce210dd..8f0450314d 100644
--- a/include/utils/Singleton.h
+++ b/include/utils/Singleton.h
@@ -64,10 +64,10 @@ private:
* for some unknown reason using the default ctor doesn't emit the variable!
*/
-#define ANDROID_SINGLETON_STATIC_INSTANCE(TYPE) \
- template class Singleton< TYPE >; \
- template<> Mutex Singleton< TYPE >::sLock(Mutex::PRIVATE); \
- template<> TYPE* Singleton< TYPE >::sInstance(0);
+#define ANDROID_SINGLETON_STATIC_INSTANCE(TYPE) \
+ template class ANDROID_API Singleton< TYPE >; \
+ template<> ANDROID_API Mutex Singleton< TYPE >::sLock(Mutex::PRIVATE); \
+ template<> ANDROID_API TYPE* Singleton< TYPE >::sInstance(0);
// ---------------------------------------------------------------------------