diff options
author | MyungJoo Ham <myungjoo.ham@samsung.com> | 2017-10-11 15:16:57 +0900 |
---|---|---|
committer | MyungJoo Ham <myungjoo.ham@samsung.com> | 2017-10-11 15:16:57 +0900 |
commit | 915c76ded744c0f5f151402b9fa69f3fd8452573 (patch) | |
tree | ca6a387466543248890f346847acaa8343989b22 /Modules/CheckIPOSupported | |
parent | 317dbdb79761ef65e45c7358cfc7571c6afa54ad (diff) | |
download | cmake-915c76ded744c0f5f151402b9fa69f3fd8452573.tar.gz cmake-915c76ded744c0f5f151402b9fa69f3fd8452573.tar.bz2 cmake-915c76ded744c0f5f151402b9fa69f3fd8452573.zip |
Imported Upstream version 3.9.4upstream/3.9.4
Diffstat (limited to 'Modules/CheckIPOSupported')
-rw-r--r-- | Modules/CheckIPOSupported/CMakeLists-C.txt.in | 8 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/CMakeLists-CXX.txt.in | 8 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/CMakeLists-Fortran.txt.in | 8 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/foo.c | 4 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/foo.cpp | 4 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/foo.f | 2 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/main.c | 6 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/main.cpp | 6 | ||||
-rw-r--r-- | Modules/CheckIPOSupported/main.f | 3 |
9 files changed, 49 insertions, 0 deletions
diff --git a/Modules/CheckIPOSupported/CMakeLists-C.txt.in b/Modules/CheckIPOSupported/CMakeLists-C.txt.in new file mode 100644 index 000000000..5a3b8ee32 --- /dev/null +++ b/Modules/CheckIPOSupported/CMakeLists-C.txt.in @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION "@CMAKE_VERSION@") +project("@TRY_COMPILE_PROJECT_NAME@" LANGUAGES C) + +cmake_policy(SET CMP0069 NEW) + +add_library(foo foo.c) +add_executable(boo main.c) +target_link_libraries(boo PUBLIC foo) diff --git a/Modules/CheckIPOSupported/CMakeLists-CXX.txt.in b/Modules/CheckIPOSupported/CMakeLists-CXX.txt.in new file mode 100644 index 000000000..30993fa40 --- /dev/null +++ b/Modules/CheckIPOSupported/CMakeLists-CXX.txt.in @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION "@CMAKE_VERSION@") +project("@TRY_COMPILE_PROJECT_NAME@" LANGUAGES CXX) + +cmake_policy(SET CMP0069 NEW) + +add_library(foo foo.cpp) +add_executable(boo main.cpp) +target_link_libraries(boo PUBLIC foo) diff --git a/Modules/CheckIPOSupported/CMakeLists-Fortran.txt.in b/Modules/CheckIPOSupported/CMakeLists-Fortran.txt.in new file mode 100644 index 000000000..9fab0772f --- /dev/null +++ b/Modules/CheckIPOSupported/CMakeLists-Fortran.txt.in @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION "@CMAKE_VERSION@") +project("@TRY_COMPILE_PROJECT_NAME@" LANGUAGES Fortran) + +cmake_policy(SET CMP0069 NEW) + +add_library(foo foo.f) +add_executable(boo main.f) +target_link_libraries(boo PUBLIC foo) diff --git a/Modules/CheckIPOSupported/foo.c b/Modules/CheckIPOSupported/foo.c new file mode 100644 index 000000000..1e5659789 --- /dev/null +++ b/Modules/CheckIPOSupported/foo.c @@ -0,0 +1,4 @@ +int foo() +{ + return 0x42; +} diff --git a/Modules/CheckIPOSupported/foo.cpp b/Modules/CheckIPOSupported/foo.cpp new file mode 100644 index 000000000..1e5659789 --- /dev/null +++ b/Modules/CheckIPOSupported/foo.cpp @@ -0,0 +1,4 @@ +int foo() +{ + return 0x42; +} diff --git a/Modules/CheckIPOSupported/foo.f b/Modules/CheckIPOSupported/foo.f new file mode 100644 index 000000000..945d2d559 --- /dev/null +++ b/Modules/CheckIPOSupported/foo.f @@ -0,0 +1,2 @@ + SUBROUTINE FOO + END diff --git a/Modules/CheckIPOSupported/main.c b/Modules/CheckIPOSupported/main.c new file mode 100644 index 000000000..5be0864ee --- /dev/null +++ b/Modules/CheckIPOSupported/main.c @@ -0,0 +1,6 @@ +int foo(); + +int main() +{ + return foo(); +} diff --git a/Modules/CheckIPOSupported/main.cpp b/Modules/CheckIPOSupported/main.cpp new file mode 100644 index 000000000..5be0864ee --- /dev/null +++ b/Modules/CheckIPOSupported/main.cpp @@ -0,0 +1,6 @@ +int foo(); + +int main() +{ + return foo(); +} diff --git a/Modules/CheckIPOSupported/main.f b/Modules/CheckIPOSupported/main.f new file mode 100644 index 000000000..9d1de9f8a --- /dev/null +++ b/Modules/CheckIPOSupported/main.f @@ -0,0 +1,3 @@ + PROGRAM BOO + CALL FOO() + END |