diff options
Diffstat (limited to 'Tests/OutOfSource')
-rw-r--r-- | Tests/OutOfSource/OutOfSourceSubdir/simple.cxx | 29 | ||||
-rw-r--r-- | Tests/OutOfSource/OutOfSourceSubdir/testlib.h | 12 | ||||
-rw-r--r-- | Tests/OutOfSource/SubDir/subdir.c | 5 | ||||
-rw-r--r-- | Tests/OutOfSource/simple.cxx | 5 |
4 files changed, 26 insertions, 25 deletions
diff --git a/Tests/OutOfSource/OutOfSourceSubdir/simple.cxx b/Tests/OutOfSource/OutOfSourceSubdir/simple.cxx index 69d7c82..12cbd1a 100644 --- a/Tests/OutOfSource/OutOfSourceSubdir/simple.cxx +++ b/Tests/OutOfSource/OutOfSourceSubdir/simple.cxx @@ -10,30 +10,25 @@ extern int simple2(); #endif extern "C" int outlib(); -int main () +int main() { - if(simple() != 123) - { + if (simple() != 123) { return -3; - } - if (strcmp(animal,"SIZZLING")) - { - fprintf(stderr,"Get definitions from a subdir did not work\n"); + } + if (strcmp(animal, "SIZZLING")) { + fprintf(stderr, "Get definitions from a subdir did not work\n"); return -2; - } - if(TestLib() != 1.0) - { + } + if (TestLib() != 1.0) { return -1; - } - if(outlib() != 456) - { + } + if (outlib() != 456) { return -4; - } + } #ifndef NO_DEEPSRC - if(simple2() != 789) - { + if (simple2() != 789) { return -5; - } + } #endif return 0; } diff --git a/Tests/OutOfSource/OutOfSourceSubdir/testlib.h b/Tests/OutOfSource/OutOfSourceSubdir/testlib.h index 75c2d84..bacf5a1 100644 --- a/Tests/OutOfSource/OutOfSourceSubdir/testlib.h +++ b/Tests/OutOfSource/OutOfSourceSubdir/testlib.h @@ -1,11 +1,11 @@ #ifdef _WIN32 -# ifdef testlib_EXPORTS -# define CM_TEST_LIB_EXPORT __declspec( dllexport ) -# else -# define CM_TEST_LIB_EXPORT __declspec( dllimport ) -# endif +#ifdef testlib_EXPORTS +#define CM_TEST_LIB_EXPORT __declspec(dllexport) #else -# define CM_TEST_LIB_EXPORT +#define CM_TEST_LIB_EXPORT __declspec(dllimport) +#endif +#else +#define CM_TEST_LIB_EXPORT #endif CM_TEST_LIB_EXPORT float TestLib(); diff --git a/Tests/OutOfSource/SubDir/subdir.c b/Tests/OutOfSource/SubDir/subdir.c index 0d0d827..abf4e18 100644 --- a/Tests/OutOfSource/SubDir/subdir.c +++ b/Tests/OutOfSource/SubDir/subdir.c @@ -1 +1,4 @@ -int subdir(void) { return 0; } +int subdir(void) +{ + return 0; +} diff --git a/Tests/OutOfSource/simple.cxx b/Tests/OutOfSource/simple.cxx index 27e79f4..ffe0db9 100644 --- a/Tests/OutOfSource/simple.cxx +++ b/Tests/OutOfSource/simple.cxx @@ -1 +1,4 @@ -int simple() { return 123; } +int simple() +{ + return 123; +} |