diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2020-01-08 03:32:39 +0300 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2020-01-08 03:32:39 +0300 |
commit | 7b46d443b0418b4b7a4b66e046a3dc28585821d0 (patch) | |
tree | c6d537634c9ce83274df83fd4bb7b99455ed7c17 /cmake/examples/dynamic | |
parent | AppVeyor: prettify appveyor.yml (diff) | |
download | cmake-common-7b46d443b0418b4b7a4b66e046a3dc28585821d0.tar.gz cmake-common-7b46d443b0418b4b7a4b66e046a3dc28585821d0.zip |
cmake/examples: more distinct output
Diffstat (limited to '')
-rw-r--r-- | cmake/examples/dynamic/CMakeLists.txt | 8 | ||||
-rw-r--r-- | cmake/examples/dynamic/bar.cpp | 7 | ||||
-rw-r--r-- | cmake/examples/dynamic/baz.cpp | 7 | ||||
-rw-r--r-- | cmake/examples/dynamic/baz.hpp (renamed from cmake/examples/dynamic/bar.hpp) | 2 | ||||
-rw-r--r-- | cmake/examples/dynamic/foo.cpp | 4 |
5 files changed, 14 insertions, 14 deletions
diff --git a/cmake/examples/dynamic/CMakeLists.txt b/cmake/examples/dynamic/CMakeLists.txt index 013cde1..1a602d6 100644 --- a/cmake/examples/dynamic/CMakeLists.txt +++ b/cmake/examples/dynamic/CMakeLists.txt @@ -4,10 +4,10 @@ project(example_dynamic) include(../../common.cmake) -add_library(bar SHARED bar.cpp) -target_include_directories(bar PUBLIC .) +add_library(baz SHARED baz.cpp) +target_include_directories(baz PUBLIC .) add_executable(foo foo.cpp) -target_link_libraries(foo PRIVATE bar) +target_link_libraries(foo PRIVATE baz) -install(TARGETS foo bar RUNTIME DESTINATION bin LIBRARY DESTINATION lib) +install(TARGETS foo baz RUNTIME DESTINATION bin LIBRARY DESTINATION lib) diff --git a/cmake/examples/dynamic/bar.cpp b/cmake/examples/dynamic/bar.cpp deleted file mode 100644 index 37aa9b5..0000000 --- a/cmake/examples/dynamic/bar.cpp +++ /dev/null @@ -1,7 +0,0 @@ -#include "bar.hpp" - -#include <iostream> - -void bar() { - std::cout << "bar\n"; -} diff --git a/cmake/examples/dynamic/baz.cpp b/cmake/examples/dynamic/baz.cpp new file mode 100644 index 0000000..d108ae3 --- /dev/null +++ b/cmake/examples/dynamic/baz.cpp @@ -0,0 +1,7 @@ +#include "baz.hpp" + +#include <iostream> + +void baz() { + std::cout << "baz\n"; +} diff --git a/cmake/examples/dynamic/bar.hpp b/cmake/examples/dynamic/baz.hpp index cf838ca..505a3c4 100644 --- a/cmake/examples/dynamic/bar.hpp +++ b/cmake/examples/dynamic/baz.hpp @@ -3,4 +3,4 @@ #ifdef _MSC_VER __declspec(dllexport) #endif -void bar(); +void baz(); diff --git a/cmake/examples/dynamic/foo.cpp b/cmake/examples/dynamic/foo.cpp index c6355a2..b7d9986 100644 --- a/cmake/examples/dynamic/foo.cpp +++ b/cmake/examples/dynamic/foo.cpp @@ -1,6 +1,6 @@ -#include <bar.hpp> +#include <baz.hpp> int main() { - bar(); + baz(); return 0; } |