ladybird/Tests/LibGC/CMakeLists.txt
Andrew Kaster 8fd81c3338 LibGC+LibWeb+LibJS: Remove workaround for Swift boolean bitfield issue
We're using a main snapshot everywhere, so we can yeet the workaround.
2025-04-04 13:06:53 -06:00

25 lines
929 B
CMake

if (ENABLE_SWIFT)
find_package(SwiftTesting REQUIRED)
add_executable(TestGCSwift
TestGCBindings.swift
TestHeap.cpp
TestInterop.cpp
)
# FIXME: Swift doesn't seem to like object libraries for @main
target_sources(TestGCSwift PRIVATE ../Resources/SwiftTestMain.swift)
generate_clang_module_map(TestGCSwift)
set_target_properties(TestGCSwift PROPERTIES SUFFIX .swift-testing)
target_include_directories(TestGCSwift PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_link_libraries(TestGCSwift PRIVATE AK LibGC SwiftTesting::SwiftTesting)
get_property(testing_compile_options TARGET SwiftTesting::SwiftTesting PROPERTY INTERFACE_LINK_OPTIONS)
add_swift_target_properties(TestGCSwift
LAGOM_LIBRARIES AK LibGC
COMPILE_OPTIONS ${testing_compile_options} -enable-experimental-feature Extern
)
add_test(NAME TestGCSwift COMMAND TestGCSwift)
endif()