CMakeLists.txt 763 B

1234567891011121314151617181920212223242526272829
  1. #
  2. # Demonstration CMakeLists.txt for nanomsg demos.
  3. #
  4. # This file shows how one might use nanomsg from a another project
  5. # that is also CMake-driven.
  6. #
  7. # Thanks for the idea goes to @maddouri.
  8. #
  9. cmake_minimum_required (VERSION 2.8.7)
  10. project(nanomsg-demo)
  11. # Call this from your own project's makefile.
  12. find_package(nanomsg CONFIG REQUIRED)
  13. add_executable(async_demo async_demo.c)
  14. target_link_libraries(async_demo nanomsg)
  15. add_executable(device_demo device_demo.c)
  16. target_link_libraries(device_demo nanomsg)
  17. add_executable(pthread_demo pthread_demo.c)
  18. target_link_libraries(pthread_demo nanomsg)
  19. add_executable(pubsub_demo pubsub_demo.c)
  20. target_link_libraries(pubsub_demo nanomsg)
  21. add_executable(rpc_demo rpc_demo.c)
  22. target_link_libraries(rpc_demo nanomsg)