CMakeLists.txt 732 B

12345678910111213141516171819
  1. include(${SerenityOS_SOURCE_DIR}/Meta/CMake/time_zone_data.cmake)
  2. set(SOURCES
  3. ${TIME_ZONE_DATA_SOURCES}
  4. DateTime.cpp
  5. TimeZone.cpp
  6. )
  7. set(GENERATED_SOURCES ${CURRENT_LIB_GENERATED})
  8. add_library(LibTimeZone OBJECT ${SOURCES})
  9. serenity_generated_sources(LibTimeZone)
  10. target_compile_definitions(LibTimeZone PRIVATE ENABLE_TIME_ZONE_DATA=$<BOOL:${ENABLE_TIME_ZONE_DATABASE_DOWNLOAD}>)
  11. # NOTE: These objects are used by the DynamicLoader, which is always built without coverage instrumentation.
  12. # We could allow them to be instrumented for coverage if DynamicLoader built its own copy
  13. target_link_libraries(LibTimeZone PRIVATE NoCoverage)
  14. if (SERENITYOS)
  15. add_dependencies(LibTimeZone install_libc_headers)
  16. endif()