diff options
author | Brad King <brad.king@kitware.com> | 2009-10-28 17:35:53 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2009-10-28 17:35:53 (GMT) |
commit | 28c3d59ed930976fd5ac4b5ea4f595632ef54758 (patch) | |
tree | cf3067e1271c86c4470085f3e76ab3767f0c2144 /Tests/OutDir/OutDir.c | |
parent | 74c59a748df858aa474342f3ad53e36cf877f9c1 (diff) | |
download | CMake-28c3d59ed930976fd5ac4b5ea4f595632ef54758.zip CMake-28c3d59ed930976fd5ac4b5ea4f595632ef54758.tar.gz CMake-28c3d59ed930976fd5ac4b5ea4f595632ef54758.tar.bz2 |
Test per-config OUTPUT_DIRECTORY properties
We test (ARCHIVE|LIBRARY|RUNTIME)_OUTPUT_DIRECTORY_<CONFIG> properties
by building COnly as a subdirectory and setting the properties to put
its files in specific locations. We build an executable that verifies
the targets actually appear where expected.
Diffstat (limited to 'Tests/OutDir/OutDir.c')
-rw-r--r-- | Tests/OutDir/OutDir.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Tests/OutDir/OutDir.c b/Tests/OutDir/OutDir.c new file mode 100644 index 0000000..53f9259 --- /dev/null +++ b/Tests/OutDir/OutDir.c @@ -0,0 +1,24 @@ +#include <OutDir.h> +#include <stdio.h> + +int main(void) +{ + const char* files[] = {TESTC1_LIB, TESTC2_LIB, CONLY_EXE, 0}; + int result = 0; + const char** fname = files; + for(;*fname;++fname) + { + FILE* f = fopen(*fname, "rb"); + if(f) + { + printf("found: [%s]\n", *fname); + fclose(f); + } + else + { + printf("error: [%s]\n", *fname); + result = 1; + } + } + return result; +} |