summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-02-24 14:45:37 (GMT)
committerKitware Robot <kwrobot@kitware.com>2021-02-24 14:45:51 (GMT)
commitd4ce3d65f3e82fd1a8549cc525a661d929e5ad10 (patch)
treed4d513e573f435fb5d6625f0a7f21dc1b10659e2 /Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c
parent022990c352ff2f0addbc8c36637880ea167bbae2 (diff)
parentb722eea9253acd9e33921779175fc615d064577a (diff)
downloadCMake-d4ce3d65f3e82fd1a8549cc525a661d929e5ad10.zip
CMake-d4ce3d65f3e82fd1a8549cc525a661d929e5ad10.tar.gz
CMake-d4ce3d65f3e82fd1a8549cc525a661d929e5ad10.tar.bz2
Merge topic 'LINK_LANGUAGE-genex-respects-LINKER_LANGUAGE-property'
b722eea925 Genex: LINK_LANGUAGE respects LINKER_LANGUAGE property Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5841
Diffstat (limited to 'Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c')
-rw-r--r--Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c b/Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c
index a908dea..689dbd7 100644
--- a/Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c
+++ b/Tests/RunCMake/target_link_libraries-LINK_LANGUAGE/main.c
@@ -1,12 +1,20 @@
-#if defined(_WIN32)
+#if defined(C_USE_CXX)
+void func_c_cxx();
+#else
+# if defined(_WIN32)
__declspec(dllimport)
-#endif
+# endif
void func_c();
+#endif
int main()
{
+#if defined(C_USE_CXX)
+ func_c_cxx();
+#else
func_c();
+#endif
return 0;
}