CMakeLists.txt 941 B

1234567891011121314151617181920212223242526272829303132
  1. set(SRC_NETWORK
  2. src/SFML/Network/Http.cpp
  3. src/SFML/Network/IPAddress.cpp
  4. src/SFML/Network/Packet.cpp
  5. src/SFML/Network/Socket.cpp
  6. src/SFML/Network/SocketSelector.cpp
  7. src/SFML/Network/TcpListener.cpp
  8. src/SFML/Network/TcpSocket.cpp
  9. src/SFML/Network/UdpSocket.cpp
  10. )
  11. if(WIN32)
  12. list(APPEND SRC_NETWORK src/SFML/Network/Win32/SocketImpl.cpp)
  13. else()
  14. list(APPEND SRC_NETWORK src/SFML/Network/Unix/SocketImpl.cpp)
  15. endif()
  16. set(SRC_SYSTEM
  17. src/SFML/System/Err.cpp
  18. src/SFML/System/String.cpp
  19. src/SFML/System/Time.cpp
  20. )
  21. add_library(sfml-network STATIC ${SRC_NETWORK})
  22. add_library(sfml-system STATIC ${SRC_SYSTEM})
  23. target_compile_definitions(sfml-system PUBLIC SFML_STATIC)
  24. target_include_directories(sfml-system PUBLIC include PRIVATE src)
  25. target_include_directories(sfml-network PUBLIC include PRIVATE src)
  26. target_link_libraries(sfml-network PUBLIC sfml-system)
  27. dolphin_disable_warnings(sfml-network)
  28. dolphin_disable_warnings(sfml-system)