summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp
diff options
context:
space:
mode:
authorMatthew Woehlke <matthew.woehlke@kitware.com>2016-09-02 15:23:16 (GMT)
committerBrad King <brad.king@kitware.com>2016-09-12 14:28:59 (GMT)
commitce76abb4c49a85d491a99318637c6e9e37729f6e (patch)
tree5ca1b142e9f6b40867c239f18ddda3588c3cf5ec /Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp
parent8f95b93b41622d428522ae10cfe1bc2fde13c78c (diff)
downloadCMake-ce76abb4c49a85d491a99318637c6e9e37729f6e.zip
CMake-ce76abb4c49a85d491a99318637c6e9e37729f6e.tar.gz
CMake-ce76abb4c49a85d491a99318637c6e9e37729f6e.tar.bz2
Tests: Add data symbols to GenerateExportHeader test
Add static data members and global variables to the GenerateExportHeader shared library, testing that export decoration for these works in addition to decoration of classes and free functions.
Diffstat (limited to 'Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp')
-rw-r--r--Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp28
1 files changed, 28 insertions, 0 deletions
diff --git a/Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp b/Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp
index ad6d356..7e46ab5 100644
--- a/Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp
+++ b/Tests/RunCMake/GenerateExportHeader/libshared/libshared.cpp
@@ -26,6 +26,12 @@ int Libshared::libshared_excluded() const
return 0;
}
+int const Libshared::data_exported = 1;
+
+int const Libshared::data_not_exported = 1;
+
+int const Libshared::data_excluded = 1;
+
int LibsharedNotExported::libshared() const
{
return 0;
@@ -51,6 +57,12 @@ int LibsharedNotExported::libshared_excluded() const
return 0;
}
+int const LibsharedNotExported::data_exported = 1;
+
+int const LibsharedNotExported::data_not_exported = 1;
+
+int const LibsharedNotExported::data_excluded = 1;
+
int LibsharedExcluded::libshared() const
{
return 0;
@@ -76,6 +88,12 @@ int LibsharedExcluded::libshared_excluded() const
return 0;
}
+int const LibsharedExcluded::data_exported = 1;
+
+int const LibsharedExcluded::data_not_exported = 1;
+
+int const LibsharedExcluded::data_excluded = 1;
+
int libshared()
{
return 0;
@@ -100,3 +118,13 @@ int libshared_excluded()
{
return 0;
}
+
+int const data_exported = 1;
+
+int const data_not_exported = 1;
+
+int const data_excluded = 1;
+
+void use_int(int)
+{
+}