foundationdb/flow/CMakeLists.txt

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

273 lines
11 KiB
CMake
Raw Normal View History

2018-05-03 00:55:29 +08:00
find_package(Threads REQUIRED)
option(FLOW_USE_ZSTD "Enable zstd compression in flow" OFF)
2022-06-28 08:11:55 +08:00
fdb_find_sources(FLOW_SRCS)
if (FLOW_USE_ZSTD)
# NOTE: To enable boost::iostreams with zstd library support, manually add
# zstd.cpp to source files is required. Ref:
# https://www.boost.org/doc/libs/1_79_0/libs/iostreams/doc/installation.html
list(APPEND FLOW_SRCS ../contrib/boost_zstd/zstd.cpp)
endif()
# Remove files with `main` defined so we can create a link test executable.
list(REMOVE_ITEM FLOW_SRCS LinkTest.cpp)
list(REMOVE_ITEM FLOW_SRCS TLSTest.cpp)
list(REMOVE_ITEM FLOW_SRCS MkCertCli.cpp)
list(REMOVE_ITEM FLOW_SRCS acac.cpp)
2021-06-08 10:23:47 +08:00
if(CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64")
list(APPEND FLOW_SRCS aarch64/memcmp.S aarch64/memcpy.S)
2021-06-08 10:23:47 +08:00
endif()
make_directory(${CMAKE_CURRENT_BINARY_DIR}/include/flow)
set(FDB_API_VERSION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/ApiVersions.cmake" CACHE STRING "Api version cmake file." FORCE)
include(${FDB_API_VERSION_FILE})
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/ApiVersion.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/include/flow/ApiVersion.h)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/SourceVersion.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/include/flow/SourceVersion.h)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/include/flow/config.h)
2018-05-03 00:55:29 +08:00
set(PROTOCOL_VERSION_PYTHON_EXECUTABLE "${Python3_EXECUTABLE}")
find_package(Python3 REQUIRED COMPONENTS Interpreter)
find_package(Jinja2)
if(NOT Jinja2_FOUND)
message(STATUS "Jinja2 not found, setting up virtual environment for protocol_version.py")
set(PROTOCOL_VERSION_VENV_DIR "${CMAKE_BINARY_DIR}/protocol_version-venv")
execute_process(COMMAND "${Python3_EXECUTABLE}" -m venv ${PROTOCOL_VERSION_VENV_DIR})
find_program(
VENV_Python3_EXECUTABLE
NAMES python3 python3.exe
PATHS ${PROTOCOL_VERSION_VENV_DIR}/Scripts ${PROTOCOL_VERSION_VENV_DIR}/bin REQUIRED
NO_DEFAULT_PATH NO_CACHE
DOC "Checking Python3 executable in virtual environment")
execute_process(COMMAND "${VENV_Python3_EXECUTABLE}" -m ensurepip COMMAND_ERROR_IS_FATAL ANY)
execute_process(COMMAND "${VENV_Python3_EXECUTABLE}" -m pip install --upgrade pip COMMAND_ERROR_IS_FATAL ANY)
execute_process(COMMAND "${VENV_Python3_EXECUTABLE}" -m pip install -r "${CMAKE_CURRENT_SOURCE_DIR}/protocolversion/requirements.txt" COMMAND_ERROR_IS_FATAL ANY)
set(PROTOCOL_VERSION_PYTHON_EXECUTABLE "${VENV_Python3_EXECUTABLE}")
endif()
set(FDB_PROTOCOL_VERSION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/ProtocolVersions.cmake" CACHE STRING "Protocol version cmake file." FORCE)
set(FDB_PROTOCOL_VERSION_HEADER_FILE "${CMAKE_CURRENT_BINARY_DIR}/include/flow/ProtocolVersion.h")
set(FDB_PROTOCOL_VERSION_JAVA_FILE "${CMAKE_CURRENT_BINARY_DIR}/include/flow/ProtocolVersion.java")
set(FDB_PROTOCOL_VERSION_PYTHON_FILE "${CMAKE_CURRENT_BINARY_DIR}/include/flow/protocol_version.py")
add_custom_command(
OUTPUT ${FDB_PROTOCOL_VERSION_HEADER_FILE}
COMMAND ${PROTOCOL_VERSION_PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/protocolversion/protocol_version.py --source ${FDB_PROTOCOL_VERSION_FILE} --generator cpp --output ${FDB_PROTOCOL_VERSION_HEADER_FILE}
COMMAND ${PROTOCOL_VERSION_PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/protocolversion/protocol_version.py --source ${FDB_PROTOCOL_VERSION_FILE} --generator java --output ${FDB_PROTOCOL_VERSION_JAVA_FILE}
COMMAND ${PROTOCOL_VERSION_PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/protocolversion/protocol_version.py --source ${FDB_PROTOCOL_VERSION_FILE} --generator python --output ${FDB_PROTOCOL_VERSION_PYTHON_FILE}
DEPENDS
${CMAKE_CURRENT_SOURCE_DIR}/protocolversion/protocol_version.py
${CMAKE_CURRENT_SOURCE_DIR}/protocolversion/ProtocolVersion.h.template
${CMAKE_CURRENT_SOURCE_DIR}/ProtocolVersions.cmake
)
add_custom_target(ProtocolVersion DEPENDS ${FDB_PROTOCOL_VERSION_HEADER_FILE})
add_flow_target(STATIC_LIBRARY NAME flow SRCS ${FLOW_SRCS})
add_flow_target(STATIC_LIBRARY NAME flow_sampling SRCS ${FLOW_SRCS})
2022-06-28 07:05:55 +08:00
add_dependencies(flow ProtocolVersion)
add_dependencies(flow_sampling ProtocolVersion)
if (FLOW_USE_ZSTD)
include(CompileZstd)
compile_zstd()
target_link_libraries(flow PRIVATE libzstd_static)
target_compile_definitions(flow PUBLIC ZSTD_LIB_SUPPORTED)
endif()
# When creating a static or shared library, undefined symbols will be ignored.
# Since we want to ensure no symbols from other modules are used, create an
# executable so the linker will throw errors if it can't find the declaration
# of a symbol.
add_flow_target(LINK_TEST NAME flowlinktest SRCS LinkTest.cpp)
target_link_libraries(flowlinktest PRIVATE flow stacktrace)
set(IS_ARM_MAC NO)
if(APPLE AND CMAKE_SYSTEM_PROCESSOR STREQUAL "arm64")
set(IS_ARM_MAC YES)
endif()
foreach(ft flow flow_sampling flowlinktest)
target_include_directories(
${ft}
PUBLIC
"${CMAKE_CURRENT_SOURCE_DIR}/include"
"${CMAKE_CURRENT_BINARY_DIR}/include"
"${CMAKE_SOURCE_DIR}/contrib/libb64/include"
)
if (FLOW_USE_ZSTD)
target_include_directories(${ft} PRIVATE SYSTEM ${ZSTD_LIB_INCLUDE_DIR})
endif()
if (USE_JEMALLOC)
target_include_directories(${ft} PRIVATE ${jemalloc_INCLUDE_DIRS})
endif()
target_link_libraries(${ft} PRIVATE stacktrace)
target_link_libraries(${ft} PUBLIC fmt::fmt SimpleOpt crc32 libb64)
if(UNIX AND NOT APPLE)
target_link_libraries(${ft} PRIVATE folly_memcpy)
target_compile_definitions(${ft} PRIVATE WITH_FOLLY_MEMCPY)
endif()
if(NOT APPLE AND NOT WIN32)
set(FLOW_LIBS ${FLOW_LIBS} rt)
elseif(WIN32)
target_link_libraries(${ft} PUBLIC winmm.lib)
target_link_libraries(${ft} PUBLIC psapi.lib)
endif()
if(CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
set(FLOW_LIBS ${FLOW_LIBS} execinfo devstat)
find_library(EIO eio)
if(EIO)
target_link_libraries(${ft} PUBLIC ${EIO})
endif()
endif()
target_link_libraries(${ft} PRIVATE ${FLOW_LIBS})
if(USE_VALGRIND)
target_link_libraries(${ft} PUBLIC Valgrind)
endif()
target_link_libraries(${ft} PUBLIC OpenSSL::SSL)
target_link_libraries(${ft} PUBLIC Threads::Threads ${CMAKE_DL_LIBS})
2022-06-28 07:05:55 +08:00
target_link_libraries(${ft} PUBLIC boost_target)
if(APPLE)
find_library(IO_KIT IOKit)
find_library(CORE_FOUNDATION CoreFoundation)
target_link_libraries(${ft} PRIVATE ${IO_KIT} ${CORE_FOUNDATION})
2022-06-28 07:05:55 +08:00
endif()
2023-11-14 16:56:00 +08:00
find_package(Coroutines COMPONENTS Experimental Final REQUIRED)
target_link_libraries(${ft} PUBLIC std::coroutines)
2022-06-28 07:05:55 +08:00
endforeach()
2023-09-21 05:12:23 +08:00
if(OPEN_FOR_IDE)
# AcAC requires actor transpiler
add_library(acac OBJECT acac.cpp)
else()
add_executable(acac acac.cpp)
endif()
target_link_libraries(acac PUBLIC flow boost_target_program_options)
target_compile_definitions(flow_sampling PRIVATE -DENABLE_SAMPLING)
if(WIN32)
add_dependencies(flow_sampling_actors flow_actors)
endif()
2022-10-05 07:01:02 +08:00
if(OPEN_FOR_IDE)
add_library(mkcert OBJECT MkCertCli.cpp)
2022-10-05 07:01:02 +08:00
else()
add_executable(mkcert MkCertCli.cpp)
2022-10-05 07:01:02 +08:00
endif()
2022-06-28 07:05:55 +08:00
target_link_libraries(mkcert PUBLIC flow)
Introduce initial Swift support in fdbserver (#10156) * [fdbserver] workaround the FRT type layout issue to get Swfit getVersion working * MasterData.actor.h: fix comment typo * masterserver.swift: some tweaks * masterserver.swift: remove getVersion function, use the method * masterserver.swift: print replied version to output for tracing * [swift] add radar links for C++ interop issues found in getVersion bringup * Update fdbserver.actor.cpp * Migrate MasterData closer to full reference type This removes the workaround for the FRT type layout issue, and gets us closer to making MasterData a full reference type * [interop] require a new toolchain (>= Oct 19th) to build * [Swift] fix computation of toAdd for getVersion Swift implementation * add Swift to FDBClient and add async `atLeast` to NotifiedVersion * fix * use new atLeast API in master server * =build fixup link dependencies in swift fdbclient * clocks * +clock implement Clock using Flow's notion of time * [interop] workaround the immortal retain/release issue * [swift] add script to get latest centos toolchain * always install swift hooks; not only in "test" mode * simulator - first thing running WIP * cleanups * more cleanup * working snapshot * remove sim debug printlns * added convenience for whenAtLeast * try Alex's workaround * annotate nonnull * cleanup clock a little bit * fix missing impls after rebase * Undo the swift_lookup_Map_UID_CommitProxyVersionReplies workaround No longer needed - the issue was retain/release * [flow][swift] add Swift version of BUGGIFY * [swiftication] add CounterValue type to provide value semantics for Counter types on the Swift side * remove extraneous requestingProxyUID local * masterserver: initial Swift state prototype * [interop] make the Swiftied getVersion work * masterserver - remove the C++ implementation (it can't be supported as state is now missing) * Remove unnecessary SWIFT_CXX_REF_IMMORTAL annotations from Flow types * Remove C++ implementation of CommitProxyVersionReplies - it's in Swift now * [swift interop] remove more SWIFT_CXX_REF_IMMORTAL * [swift interop] add SWIFT_CXX_IMMORTAL_SINGLETON_TYPE annotation for semanticly meaningful immortal uses * rename SWIFT_CXX_REF_IMMORTAL -> UNSAFE_SWIFT_CXX_IMMORTAL_REF * Move master server waitForPrev to swift * =build fix linking swift in all modules * =build single link option * =cmake avoid manual math, just get "last" element from list * implement Streams support (#18) * [interop] update to new toolchain #6 * [interop] remove C++ vtable linking workarounds * [interop] make MasterData proper reference counted SWIFT_CXX_REF_MASTERDATA * [interop] use Swift array to pass UIDs to registerLastCommitProxyVersionReplies * [interop] expose MasterServer actor to C++ without wrapper struct * [interop] we no longer need expose on methods 🥳 * [interop] initial prototype of storing CheckedContinuation on the C++ side * Example of invoking a synchronous swift function from a C++ unit test. (#21) * move all "tests" we have in Swift, and priority support into real modules (#24) * Make set continuation functions inline * Split flow_swift into flow_swift and flow_swift_future to break circular dependency * rename SwiftContinuationCallbackStruct to FlowCallbackForSwiftContinuation * Future interop: use a method in a class template for continuation set call * Revert "Merge pull request #22 from FoundationDB/cpp-continuation" (#30) * Basic Swift Guide (#29) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * Revert "Revert "Merge pull request #22 from FoundationDB/cpp-continuation" (#30)" This reverts commit c025fe6258c4c4904d5e70cd549d408bb61f2802. * Restore the C++ continuation, but it seems waitValue is broken for CInt somehow now * disable broken tests - waitValue not accessible * Streams can be async iterated over (#27) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * remove work in progress things (#35) * remove some not used (yet) code * remove expose func for CInt, it's a primitive so we always have witness info (#37) * +masterdata implement provideVersions in Swift (#36) * serveLiveCommittedVersion in Swift (#38) * Port updateLiveCommittedVersion to swift (#33) Co-authored-by: Konrad `ktoso` Malawski <konrad_malawski@apple.com> * Implement updateRecoveryData in Swift (#39) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * Simplify flow_swift to avoid multiple targets and generate separate CheckedContinuation header * Uncomment test which was blocked on extensions not being picked up (#31) * [interop] Use a separate target for Swift-to-C++ header generation * reduce boilerplate in future and stream support (#41) * [interop] require interop v8 - that will fix linker issue (https://github.com/apple/swift/issues/62448) * [interop] fix swift_stream_support.h Swift include * [interop] bump up requirement to version 9 * [interop] Generalize the Flow.Optional -> Swift.Optional conversion using generics * [WIP] masterServer func in Swift (#45) * [interop] Try conforms_to with a SWIFT_CONFORMS_TO macro for Optional conformance (#49) * [interop] include FlowOptionalProtocol source file when generating Flow_CheckedContinuation.h This header generation step depends on the import of the C++ Flow module, which requires the presence of FlowOptionalProtocol * conform Future to FlowFutureOps * some notes * move to value() so we can use discardable result for Flow.Void * make calling into Swift async funcs nicer by returning Flow Futures * [interop] hide initial use of FlowCheckedContinuation in flow.h to break dependency cycle * [fdbserver] fix an EncryptionOpsUtils.h modularization issue (showed up with modularized libc++) * Pass GCC toolchain using CMAKE_Swift_COMPILE_EXTERNAL_TOOLCHAIN to Swift's clang importer * [interop] drop the no longer needed libstdc++ include directories * [cmake] add a configuration check to ensure Swift can import C++ standard library * [swift] include msgpack from msgpack_DIR * [interop] make sure the FDB module maps have 'export' directive * add import 'flow_swift' to swift_fdbserver_cxx_swift_value_conformance.swift This is needed for CONFORMS_TO to work in imported modules * make sure the Swift -> C++ manually bridged function signature matches generated signature * [interop][workaround] force back use of @expose attribute before _Concurrency issue is fixed * [interop] make getResolutionBalancer return a pointer to allow Swift to use it We should revert back to a reference once compiler allows references again * [interop] add a workaround for 'pop' being marked as unsafe in Swift * masterserver.swift: MasterData returns the Swift actor pointer in an unsafe manner * Add a 'getCopy' method to AsyncVar to make it more Swift friendly * [interop] bump up the toolchain requirement * Revert "[interop][workaround] force back use of @expose attribute before _Concurrency issue is fixed" This reverts commit b01b271a76d1677bbb7c5c9c64cdad4b8b2b9612. * [interop] add FIXME comments highlighting new issue workarounds * [interop] adopt the new C++ interoperability compiler flag * [interop] generate swift compile commands * Do not deduplicate Swift compilation commands * [interop] generate swift compile commands * Do not deduplicate Swift compilation commands * flow actorcompiler.h: add a SWIFT_ACTOR empty macro definition This is needed to make the actor files parsable by clangd * [cmake] add missing dependencies * experimental cross compile * [cmake] fix triple in cross-compiled cmake flags * [interop] update to interop toolchain version 16 * [x-compile] add flags for cross-compiling boost * cleanup x-compile cmake changes * [cmake] fix typo in CMAKE_Swift_COMPILER_EXTERNAL_TOOLCHAIN config variable * [interop] pass MasterDataActor from Swift to C++ and back to Swift * [fdbserver] Swift->C++ header generation for FDBServer should use same module cache path * Update swift_get_latest_toolchain.sh to fetch 5.9 toochains * set HAVE_FLAG_SEARCH_PATHS_FIRST for cross compilation * Resolve conflicts in net2/sim2/actors, can't build yet * undo SWIFT_ACTOR changes, not necessary for merge * guard c++ compiler flags with is_cxx_compile * Update flow/actorcompiler/ActorParser.cs Co-authored-by: Evan Wilde <etceterawilde@gmail.com> * update the boost dependency * Include boost directory from the container for Swift * conform flow's Optional to FlowOptionalProtocol again * Guard entire RocksDBLogForwarder.h with SSD_ROCKSDB_EXPERIMENTAL to avoid failing on missing rocksdb APIs * remove extraneous merge marker * [swift] update swift_test_streams.swifto to use vars in more places * Add header guard to flow/include/flow/ThreadSafeQueue.h to fix moduralization issue * Update net and sim impls * [cmake] use prebuilt libc++ boost only when we're actually using libc++ * [fdbserver] Swift->C++ header generation for FDBServer should use same module cache path * fixups after merge * remove CustomStringConvertible conformance that would not be used * remove self-caused deprecation warnings in future_support * handle newly added task priority * reformatting * future: make value() not mutating * remove FIXME, not needed anymore * future: clarify why as functions * Support TraceEvent in Swift * Enable TraceEvent using a class wrapper in Swift * prearing WITH_SWIFT flag * wip disabled failing Go stuff * cleanup WITH_SWIFT_FLAG and reenable Go * wip disabled failing Go stuff * move setting flag before printing it * Add SWIFT_IDE_SETUP and cleanup guides and build a bit * Revert "Wipe packet buffers that held serialized WipedString (#10018)" This reverts commit e2df6e33029897360f8e11b3aea8fef97393a98c. * [Swift] Compile workaround in KeyBackedRangeMap; default init is incorrect * [interop] do not add FlowFutureOps conformance when building flow clang module for Flow checked continuation header pre-generation * make sure to show -DUSE_LIBCXX=OFF in readme * readme updates * do not print to stderr * Update Swift and C++ code to build with latest Swift 5.9 toolchain now that we no longer support universal references and bridge the methods that take in a constant reference template parameter correctly * Fix SERVER_KNOBS and enable use them for masterserver * Bump to C++20, Swift is now able to handle it as well * Put waitForPrev behind FLOW_WITH_SWIFT knob * Forward declare updateLiveCommittedVersion * Remove unused code * fix wrong condition set for updateLiveCommittedVersion * Revert "Revert "Wipe packet buffers that held serialized WipedString (#10018)"" This reverts commit 5ad8dce0525fb1844664ed2ccd7ba595db6913dd. * Enable go-bindings in cmake * Revert "Revert "Wipe packet buffers that held serialized WipedString (#10018)"" This reverts commit 5ad8dce0525fb1844664ed2ccd7ba595db6913dd. * USE_SWIFT flag so we "build without swift" until ready to by default * uncomment a few tests which were disabled during USE_SWIFT enablement * the option is WITH_SWIFT, not USE * formatting * Fix masterserver compile error * Fix some build errors. How did it not merge cleanly? :/ * remove initializer list from constructor * Expect Swift toolchain only if WITH_SWIFT is enabled * Don't require Flow_CheckedContinuation when Swift is disabled * Don't compile FlowCheckedContinuation when WITH_SWIFT=OFF * No-op Swift macros * More compile guards * fix typo * Run clang-format * Guard swift/bridging include in fdbrpc * Remove printf to pass the test * Remove some more printf to avoid potential issues TODO: Need to be TraceEvents instead * Remove __has_feature(nullability) as its only used in Swift * Don't use __FILENAME__ * Don't call generate_module_map outside WITH_SWIFT * Add some more cmake stuff under WITH_SWIFT guard * Some more guards * Bring back TLSTest.cpp * clang-format * fix comment formatting * Remove unused command line arg * fix cmake formatting in some files * Address some review comments * fix clang-format error --------- Co-authored-by: Alex Lorenz <arphaman@gmail.com> Co-authored-by: Russell Sears <russell_sears@apple.com> Co-authored-by: Evan Wilde <etceterawilde@gmail.com> Co-authored-by: Alex Lorenz <aleksei_lorenz@apple.com> Co-authored-by: Vishesh Yadav <vishesh_yadav@apple.com> Co-authored-by: Vishesh Yadav <vishesh3y@gmail.com>
2023-06-03 05:09:28 +08:00
set(FLOW_BINARY_DIR "${CMAKE_BINARY_DIR}/flow")
if (WITH_SWIFT)
include(GenerateModulemap)
generate_modulemap("${CMAKE_BINARY_DIR}/flow/include" "Flow" flow
OMIT
sse2neon.h
ppc-asm.h
)
add_library(flow_swift STATIC
FlowCheckedContinuation.swift
stream_support.swift # general stream support types
flow_stream_support.swift # conformances for future types that we vend with this module (E.g. CInt, Void)
error_support.swift
task_priority_support.swift
SwiftBridging.swift
SwiftFileB.swift
future_support.swift # general support types
trace_support.swift # general support types
flow_future_support.swift # conformances for future types that we vend with this module (E.g. CInt, Void)
reply_support.swift
clock_support.swift
flow_optional_support.swift
)
target_include_directories(flow_swift PUBLIC
"${CMAKE_BINARY_DIR}/flow/include"
"${CMAKE_SOURCE_DIR}/flow/include"
"${CMAKE_BINARY_DIR}/flow/"
"${CMAKE_BINARY_DIR}/fdbclient/include"
"${CMAKE_BINARY_DIR}/fdbserver/include"
"${CMAKE_SOURCE_DIR}/fdbrpc/include"
"${CMAKE_BINARY_DIR}/fdbrpc/include"
"${CMAKE_SOURCE_DIR}/contrib/fmt-8.1.1/include"
"${CMAKE_SOURCE_DIR}/contrib/md5/include"
"${CMAKE_SOURCE_DIR}/contrib/libb64/include"
"${CMAKE_SOURCE_DIR}/contrib/sqlite"
"${Boost_DIR}/../../../include"
"${msgpack_DIR}/include"
)
include(FindSwiftLibs)
swift_get_linker_search_paths(SWIFT_LINK_PATHS)
target_link_directories(flow PUBLIC "${SWIFT_LINK_PATHS}")
# We need to make sure that Swift, and the concurrency library is linked
# in every module that uses flow, because we implement the Swift hooks in flow.
# TODO(swift): With upcoming CMake 3.26 we can get rid of this as it should realize
# that modules need Swift and use Swift for the linking which
# will do the right thing.
target_link_options(flow PUBLIC
"-lswiftCore"
"-lswift_Concurrency"
"-lswift_StringProcessing")
# Link with runtime initialization stub (not needed on Darwin).
if (NOT APPLE)
string(REPLACE " " ";" SWIFT_LINK_PATHS_LIST "${SWIFT_LINK_PATHS}")
list(GET SWIFT_LINK_PATHS_LIST -1 LastPath) # get the last element the list
target_link_options(flow PUBLIC "${LastPath}/swiftrt.o")
endif()
# TODO: the TBD validation skip is because of swift_job_run_generic, though it seems weird why we need to do that?
target_compile_options(flow_swift PRIVATE "$<$<COMPILE_LANGUAGE:Swift>:SHELL:-Xcc -std=c++20 -Xfrontend -validate-tbd-against-ir=none -Xcc -DNO_INTELLISENSE -Xcc -ivfsoverlay${CMAKE_BINARY_DIR}/flow/include/headeroverlay.yaml>")
# Ensure that C++ code in fdbserver can import Swift using a compatibility header.
include(SwiftToCXXInterop)
add_swift_to_cxx_header_gen_target(
flow_swift
flow_swift_checked_continuation_header
"${CMAKE_CURRENT_BINARY_DIR}/include/SwiftModules/Flow_CheckedContinuation.h"
SOURCES
"${CMAKE_CURRENT_SOURCE_DIR}/FlowCheckedContinuation.swift"
"${CMAKE_CURRENT_SOURCE_DIR}/flow_optional_support.swift"
FLAGS
-Xcc -std=c++20 -Xcc -DNO_INTELLISENSE -Xcc -ivfsoverlay${CMAKE_BINARY_DIR}/flow/include/headeroverlay.yaml
# Important: This is needed to avoid including headers that depends on this generated header.
-Xcc -DSWIFT_FUTURE_SUPPORT_H -Xcc -DSWIFT_STREAM_SUPPORT_H -Xcc -DSWIFT_HIDE_CHECKED_CONTINUTATION
)
add_swift_to_cxx_header_gen_target(
flow_swift
flow_swift_header
"${CMAKE_CURRENT_BINARY_DIR}/include/SwiftModules/Flow"
FLAGS
-Xcc -std=c++20 -Xcc -DNO_INTELLISENSE -Xcc -ivfsoverlay${CMAKE_BINARY_DIR}/flow/include/headeroverlay.yaml
)
add_dependencies(flow_swift_checked_continuation_header flow_actors boost_target ProtocolVersion)
Introduce initial Swift support in fdbserver (#10156) * [fdbserver] workaround the FRT type layout issue to get Swfit getVersion working * MasterData.actor.h: fix comment typo * masterserver.swift: some tweaks * masterserver.swift: remove getVersion function, use the method * masterserver.swift: print replied version to output for tracing * [swift] add radar links for C++ interop issues found in getVersion bringup * Update fdbserver.actor.cpp * Migrate MasterData closer to full reference type This removes the workaround for the FRT type layout issue, and gets us closer to making MasterData a full reference type * [interop] require a new toolchain (>= Oct 19th) to build * [Swift] fix computation of toAdd for getVersion Swift implementation * add Swift to FDBClient and add async `atLeast` to NotifiedVersion * fix * use new atLeast API in master server * =build fixup link dependencies in swift fdbclient * clocks * +clock implement Clock using Flow's notion of time * [interop] workaround the immortal retain/release issue * [swift] add script to get latest centos toolchain * always install swift hooks; not only in "test" mode * simulator - first thing running WIP * cleanups * more cleanup * working snapshot * remove sim debug printlns * added convenience for whenAtLeast * try Alex's workaround * annotate nonnull * cleanup clock a little bit * fix missing impls after rebase * Undo the swift_lookup_Map_UID_CommitProxyVersionReplies workaround No longer needed - the issue was retain/release * [flow][swift] add Swift version of BUGGIFY * [swiftication] add CounterValue type to provide value semantics for Counter types on the Swift side * remove extraneous requestingProxyUID local * masterserver: initial Swift state prototype * [interop] make the Swiftied getVersion work * masterserver - remove the C++ implementation (it can't be supported as state is now missing) * Remove unnecessary SWIFT_CXX_REF_IMMORTAL annotations from Flow types * Remove C++ implementation of CommitProxyVersionReplies - it's in Swift now * [swift interop] remove more SWIFT_CXX_REF_IMMORTAL * [swift interop] add SWIFT_CXX_IMMORTAL_SINGLETON_TYPE annotation for semanticly meaningful immortal uses * rename SWIFT_CXX_REF_IMMORTAL -> UNSAFE_SWIFT_CXX_IMMORTAL_REF * Move master server waitForPrev to swift * =build fix linking swift in all modules * =build single link option * =cmake avoid manual math, just get "last" element from list * implement Streams support (#18) * [interop] update to new toolchain #6 * [interop] remove C++ vtable linking workarounds * [interop] make MasterData proper reference counted SWIFT_CXX_REF_MASTERDATA * [interop] use Swift array to pass UIDs to registerLastCommitProxyVersionReplies * [interop] expose MasterServer actor to C++ without wrapper struct * [interop] we no longer need expose on methods 🥳 * [interop] initial prototype of storing CheckedContinuation on the C++ side * Example of invoking a synchronous swift function from a C++ unit test. (#21) * move all "tests" we have in Swift, and priority support into real modules (#24) * Make set continuation functions inline * Split flow_swift into flow_swift and flow_swift_future to break circular dependency * rename SwiftContinuationCallbackStruct to FlowCallbackForSwiftContinuation * Future interop: use a method in a class template for continuation set call * Revert "Merge pull request #22 from FoundationDB/cpp-continuation" (#30) * Basic Swift Guide (#29) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * Revert "Revert "Merge pull request #22 from FoundationDB/cpp-continuation" (#30)" This reverts commit c025fe6258c4c4904d5e70cd549d408bb61f2802. * Restore the C++ continuation, but it seems waitValue is broken for CInt somehow now * disable broken tests - waitValue not accessible * Streams can be async iterated over (#27) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * remove work in progress things (#35) * remove some not used (yet) code * remove expose func for CInt, it's a primitive so we always have witness info (#37) * +masterdata implement provideVersions in Swift (#36) * serveLiveCommittedVersion in Swift (#38) * Port updateLiveCommittedVersion to swift (#33) Co-authored-by: Konrad `ktoso` Malawski <konrad_malawski@apple.com> * Implement updateRecoveryData in Swift (#39) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * Simplify flow_swift to avoid multiple targets and generate separate CheckedContinuation header * Uncomment test which was blocked on extensions not being picked up (#31) * [interop] Use a separate target for Swift-to-C++ header generation * reduce boilerplate in future and stream support (#41) * [interop] require interop v8 - that will fix linker issue (https://github.com/apple/swift/issues/62448) * [interop] fix swift_stream_support.h Swift include * [interop] bump up requirement to version 9 * [interop] Generalize the Flow.Optional -> Swift.Optional conversion using generics * [WIP] masterServer func in Swift (#45) * [interop] Try conforms_to with a SWIFT_CONFORMS_TO macro for Optional conformance (#49) * [interop] include FlowOptionalProtocol source file when generating Flow_CheckedContinuation.h This header generation step depends on the import of the C++ Flow module, which requires the presence of FlowOptionalProtocol * conform Future to FlowFutureOps * some notes * move to value() so we can use discardable result for Flow.Void * make calling into Swift async funcs nicer by returning Flow Futures * [interop] hide initial use of FlowCheckedContinuation in flow.h to break dependency cycle * [fdbserver] fix an EncryptionOpsUtils.h modularization issue (showed up with modularized libc++) * Pass GCC toolchain using CMAKE_Swift_COMPILE_EXTERNAL_TOOLCHAIN to Swift's clang importer * [interop] drop the no longer needed libstdc++ include directories * [cmake] add a configuration check to ensure Swift can import C++ standard library * [swift] include msgpack from msgpack_DIR * [interop] make sure the FDB module maps have 'export' directive * add import 'flow_swift' to swift_fdbserver_cxx_swift_value_conformance.swift This is needed for CONFORMS_TO to work in imported modules * make sure the Swift -> C++ manually bridged function signature matches generated signature * [interop][workaround] force back use of @expose attribute before _Concurrency issue is fixed * [interop] make getResolutionBalancer return a pointer to allow Swift to use it We should revert back to a reference once compiler allows references again * [interop] add a workaround for 'pop' being marked as unsafe in Swift * masterserver.swift: MasterData returns the Swift actor pointer in an unsafe manner * Add a 'getCopy' method to AsyncVar to make it more Swift friendly * [interop] bump up the toolchain requirement * Revert "[interop][workaround] force back use of @expose attribute before _Concurrency issue is fixed" This reverts commit b01b271a76d1677bbb7c5c9c64cdad4b8b2b9612. * [interop] add FIXME comments highlighting new issue workarounds * [interop] adopt the new C++ interoperability compiler flag * [interop] generate swift compile commands * Do not deduplicate Swift compilation commands * [interop] generate swift compile commands * Do not deduplicate Swift compilation commands * flow actorcompiler.h: add a SWIFT_ACTOR empty macro definition This is needed to make the actor files parsable by clangd * [cmake] add missing dependencies * experimental cross compile * [cmake] fix triple in cross-compiled cmake flags * [interop] update to interop toolchain version 16 * [x-compile] add flags for cross-compiling boost * cleanup x-compile cmake changes * [cmake] fix typo in CMAKE_Swift_COMPILER_EXTERNAL_TOOLCHAIN config variable * [interop] pass MasterDataActor from Swift to C++ and back to Swift * [fdbserver] Swift->C++ header generation for FDBServer should use same module cache path * Update swift_get_latest_toolchain.sh to fetch 5.9 toochains * set HAVE_FLAG_SEARCH_PATHS_FIRST for cross compilation * Resolve conflicts in net2/sim2/actors, can't build yet * undo SWIFT_ACTOR changes, not necessary for merge * guard c++ compiler flags with is_cxx_compile * Update flow/actorcompiler/ActorParser.cs Co-authored-by: Evan Wilde <etceterawilde@gmail.com> * update the boost dependency * Include boost directory from the container for Swift * conform flow's Optional to FlowOptionalProtocol again * Guard entire RocksDBLogForwarder.h with SSD_ROCKSDB_EXPERIMENTAL to avoid failing on missing rocksdb APIs * remove extraneous merge marker * [swift] update swift_test_streams.swifto to use vars in more places * Add header guard to flow/include/flow/ThreadSafeQueue.h to fix moduralization issue * Update net and sim impls * [cmake] use prebuilt libc++ boost only when we're actually using libc++ * [fdbserver] Swift->C++ header generation for FDBServer should use same module cache path * fixups after merge * remove CustomStringConvertible conformance that would not be used * remove self-caused deprecation warnings in future_support * handle newly added task priority * reformatting * future: make value() not mutating * remove FIXME, not needed anymore * future: clarify why as functions * Support TraceEvent in Swift * Enable TraceEvent using a class wrapper in Swift * prearing WITH_SWIFT flag * wip disabled failing Go stuff * cleanup WITH_SWIFT_FLAG and reenable Go * wip disabled failing Go stuff * move setting flag before printing it * Add SWIFT_IDE_SETUP and cleanup guides and build a bit * Revert "Wipe packet buffers that held serialized WipedString (#10018)" This reverts commit e2df6e33029897360f8e11b3aea8fef97393a98c. * [Swift] Compile workaround in KeyBackedRangeMap; default init is incorrect * [interop] do not add FlowFutureOps conformance when building flow clang module for Flow checked continuation header pre-generation * make sure to show -DUSE_LIBCXX=OFF in readme * readme updates * do not print to stderr * Update Swift and C++ code to build with latest Swift 5.9 toolchain now that we no longer support universal references and bridge the methods that take in a constant reference template parameter correctly * Fix SERVER_KNOBS and enable use them for masterserver * Bump to C++20, Swift is now able to handle it as well * Put waitForPrev behind FLOW_WITH_SWIFT knob * Forward declare updateLiveCommittedVersion * Remove unused code * fix wrong condition set for updateLiveCommittedVersion * Revert "Revert "Wipe packet buffers that held serialized WipedString (#10018)"" This reverts commit 5ad8dce0525fb1844664ed2ccd7ba595db6913dd. * Enable go-bindings in cmake * Revert "Revert "Wipe packet buffers that held serialized WipedString (#10018)"" This reverts commit 5ad8dce0525fb1844664ed2ccd7ba595db6913dd. * USE_SWIFT flag so we "build without swift" until ready to by default * uncomment a few tests which were disabled during USE_SWIFT enablement * the option is WITH_SWIFT, not USE * formatting * Fix masterserver compile error * Fix some build errors. How did it not merge cleanly? :/ * remove initializer list from constructor * Expect Swift toolchain only if WITH_SWIFT is enabled * Don't require Flow_CheckedContinuation when Swift is disabled * Don't compile FlowCheckedContinuation when WITH_SWIFT=OFF * No-op Swift macros * More compile guards * fix typo * Run clang-format * Guard swift/bridging include in fdbrpc * Remove printf to pass the test * Remove some more printf to avoid potential issues TODO: Need to be TraceEvents instead * Remove __has_feature(nullability) as its only used in Swift * Don't use __FILENAME__ * Don't call generate_module_map outside WITH_SWIFT * Add some more cmake stuff under WITH_SWIFT guard * Some more guards * Bring back TLSTest.cpp * clang-format * fix comment formatting * Remove unused command line arg * fix cmake formatting in some files * Address some review comments * fix clang-format error --------- Co-authored-by: Alex Lorenz <arphaman@gmail.com> Co-authored-by: Russell Sears <russell_sears@apple.com> Co-authored-by: Evan Wilde <etceterawilde@gmail.com> Co-authored-by: Alex Lorenz <aleksei_lorenz@apple.com> Co-authored-by: Vishesh Yadav <vishesh_yadav@apple.com> Co-authored-by: Vishesh Yadav <vishesh3y@gmail.com>
2023-06-03 05:09:28 +08:00
add_dependencies(flow_swift_header flow_swift_checked_continuation_header)
add_dependencies(flow_swift flow_swift_header)
add_dependencies(flow_swift flow_actors)
add_dependencies(flow_swift boost_target)
# TODO(swift): rdar://99107402 - this will only work once CMake 3.25 is released:
# target_link_libraries(flow PRIVATE flow_swift)
add_dependencies(flow flow_swift)
add_dependencies(flow_sampling flow_swift)
Introduce initial Swift support in fdbserver (#10156) * [fdbserver] workaround the FRT type layout issue to get Swfit getVersion working * MasterData.actor.h: fix comment typo * masterserver.swift: some tweaks * masterserver.swift: remove getVersion function, use the method * masterserver.swift: print replied version to output for tracing * [swift] add radar links for C++ interop issues found in getVersion bringup * Update fdbserver.actor.cpp * Migrate MasterData closer to full reference type This removes the workaround for the FRT type layout issue, and gets us closer to making MasterData a full reference type * [interop] require a new toolchain (>= Oct 19th) to build * [Swift] fix computation of toAdd for getVersion Swift implementation * add Swift to FDBClient and add async `atLeast` to NotifiedVersion * fix * use new atLeast API in master server * =build fixup link dependencies in swift fdbclient * clocks * +clock implement Clock using Flow's notion of time * [interop] workaround the immortal retain/release issue * [swift] add script to get latest centos toolchain * always install swift hooks; not only in "test" mode * simulator - first thing running WIP * cleanups * more cleanup * working snapshot * remove sim debug printlns * added convenience for whenAtLeast * try Alex's workaround * annotate nonnull * cleanup clock a little bit * fix missing impls after rebase * Undo the swift_lookup_Map_UID_CommitProxyVersionReplies workaround No longer needed - the issue was retain/release * [flow][swift] add Swift version of BUGGIFY * [swiftication] add CounterValue type to provide value semantics for Counter types on the Swift side * remove extraneous requestingProxyUID local * masterserver: initial Swift state prototype * [interop] make the Swiftied getVersion work * masterserver - remove the C++ implementation (it can't be supported as state is now missing) * Remove unnecessary SWIFT_CXX_REF_IMMORTAL annotations from Flow types * Remove C++ implementation of CommitProxyVersionReplies - it's in Swift now * [swift interop] remove more SWIFT_CXX_REF_IMMORTAL * [swift interop] add SWIFT_CXX_IMMORTAL_SINGLETON_TYPE annotation for semanticly meaningful immortal uses * rename SWIFT_CXX_REF_IMMORTAL -> UNSAFE_SWIFT_CXX_IMMORTAL_REF * Move master server waitForPrev to swift * =build fix linking swift in all modules * =build single link option * =cmake avoid manual math, just get "last" element from list * implement Streams support (#18) * [interop] update to new toolchain #6 * [interop] remove C++ vtable linking workarounds * [interop] make MasterData proper reference counted SWIFT_CXX_REF_MASTERDATA * [interop] use Swift array to pass UIDs to registerLastCommitProxyVersionReplies * [interop] expose MasterServer actor to C++ without wrapper struct * [interop] we no longer need expose on methods 🥳 * [interop] initial prototype of storing CheckedContinuation on the C++ side * Example of invoking a synchronous swift function from a C++ unit test. (#21) * move all "tests" we have in Swift, and priority support into real modules (#24) * Make set continuation functions inline * Split flow_swift into flow_swift and flow_swift_future to break circular dependency * rename SwiftContinuationCallbackStruct to FlowCallbackForSwiftContinuation * Future interop: use a method in a class template for continuation set call * Revert "Merge pull request #22 from FoundationDB/cpp-continuation" (#30) * Basic Swift Guide (#29) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * Revert "Revert "Merge pull request #22 from FoundationDB/cpp-continuation" (#30)" This reverts commit c025fe6258c4c4904d5e70cd549d408bb61f2802. * Restore the C++ continuation, but it seems waitValue is broken for CInt somehow now * disable broken tests - waitValue not accessible * Streams can be async iterated over (#27) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * remove work in progress things (#35) * remove some not used (yet) code * remove expose func for CInt, it's a primitive so we always have witness info (#37) * +masterdata implement provideVersions in Swift (#36) * serveLiveCommittedVersion in Swift (#38) * Port updateLiveCommittedVersion to swift (#33) Co-authored-by: Konrad `ktoso` Malawski <konrad_malawski@apple.com> * Implement updateRecoveryData in Swift (#39) Co-authored-by: Alex Lorenz <arphaman@gmail.com> * Simplify flow_swift to avoid multiple targets and generate separate CheckedContinuation header * Uncomment test which was blocked on extensions not being picked up (#31) * [interop] Use a separate target for Swift-to-C++ header generation * reduce boilerplate in future and stream support (#41) * [interop] require interop v8 - that will fix linker issue (https://github.com/apple/swift/issues/62448) * [interop] fix swift_stream_support.h Swift include * [interop] bump up requirement to version 9 * [interop] Generalize the Flow.Optional -> Swift.Optional conversion using generics * [WIP] masterServer func in Swift (#45) * [interop] Try conforms_to with a SWIFT_CONFORMS_TO macro for Optional conformance (#49) * [interop] include FlowOptionalProtocol source file when generating Flow_CheckedContinuation.h This header generation step depends on the import of the C++ Flow module, which requires the presence of FlowOptionalProtocol * conform Future to FlowFutureOps * some notes * move to value() so we can use discardable result for Flow.Void * make calling into Swift async funcs nicer by returning Flow Futures * [interop] hide initial use of FlowCheckedContinuation in flow.h to break dependency cycle * [fdbserver] fix an EncryptionOpsUtils.h modularization issue (showed up with modularized libc++) * Pass GCC toolchain using CMAKE_Swift_COMPILE_EXTERNAL_TOOLCHAIN to Swift's clang importer * [interop] drop the no longer needed libstdc++ include directories * [cmake] add a configuration check to ensure Swift can import C++ standard library * [swift] include msgpack from msgpack_DIR * [interop] make sure the FDB module maps have 'export' directive * add import 'flow_swift' to swift_fdbserver_cxx_swift_value_conformance.swift This is needed for CONFORMS_TO to work in imported modules * make sure the Swift -> C++ manually bridged function signature matches generated signature * [interop][workaround] force back use of @expose attribute before _Concurrency issue is fixed * [interop] make getResolutionBalancer return a pointer to allow Swift to use it We should revert back to a reference once compiler allows references again * [interop] add a workaround for 'pop' being marked as unsafe in Swift * masterserver.swift: MasterData returns the Swift actor pointer in an unsafe manner * Add a 'getCopy' method to AsyncVar to make it more Swift friendly * [interop] bump up the toolchain requirement * Revert "[interop][workaround] force back use of @expose attribute before _Concurrency issue is fixed" This reverts commit b01b271a76d1677bbb7c5c9c64cdad4b8b2b9612. * [interop] add FIXME comments highlighting new issue workarounds * [interop] adopt the new C++ interoperability compiler flag * [interop] generate swift compile commands * Do not deduplicate Swift compilation commands * [interop] generate swift compile commands * Do not deduplicate Swift compilation commands * flow actorcompiler.h: add a SWIFT_ACTOR empty macro definition This is needed to make the actor files parsable by clangd * [cmake] add missing dependencies * experimental cross compile * [cmake] fix triple in cross-compiled cmake flags * [interop] update to interop toolchain version 16 * [x-compile] add flags for cross-compiling boost * cleanup x-compile cmake changes * [cmake] fix typo in CMAKE_Swift_COMPILER_EXTERNAL_TOOLCHAIN config variable * [interop] pass MasterDataActor from Swift to C++ and back to Swift * [fdbserver] Swift->C++ header generation for FDBServer should use same module cache path * Update swift_get_latest_toolchain.sh to fetch 5.9 toochains * set HAVE_FLAG_SEARCH_PATHS_FIRST for cross compilation * Resolve conflicts in net2/sim2/actors, can't build yet * undo SWIFT_ACTOR changes, not necessary for merge * guard c++ compiler flags with is_cxx_compile * Update flow/actorcompiler/ActorParser.cs Co-authored-by: Evan Wilde <etceterawilde@gmail.com> * update the boost dependency * Include boost directory from the container for Swift * conform flow's Optional to FlowOptionalProtocol again * Guard entire RocksDBLogForwarder.h with SSD_ROCKSDB_EXPERIMENTAL to avoid failing on missing rocksdb APIs * remove extraneous merge marker * [swift] update swift_test_streams.swifto to use vars in more places * Add header guard to flow/include/flow/ThreadSafeQueue.h to fix moduralization issue * Update net and sim impls * [cmake] use prebuilt libc++ boost only when we're actually using libc++ * [fdbserver] Swift->C++ header generation for FDBServer should use same module cache path * fixups after merge * remove CustomStringConvertible conformance that would not be used * remove self-caused deprecation warnings in future_support * handle newly added task priority * reformatting * future: make value() not mutating * remove FIXME, not needed anymore * future: clarify why as functions * Support TraceEvent in Swift * Enable TraceEvent using a class wrapper in Swift * prearing WITH_SWIFT flag * wip disabled failing Go stuff * cleanup WITH_SWIFT_FLAG and reenable Go * wip disabled failing Go stuff * move setting flag before printing it * Add SWIFT_IDE_SETUP and cleanup guides and build a bit * Revert "Wipe packet buffers that held serialized WipedString (#10018)" This reverts commit e2df6e33029897360f8e11b3aea8fef97393a98c. * [Swift] Compile workaround in KeyBackedRangeMap; default init is incorrect * [interop] do not add FlowFutureOps conformance when building flow clang module for Flow checked continuation header pre-generation * make sure to show -DUSE_LIBCXX=OFF in readme * readme updates * do not print to stderr * Update Swift and C++ code to build with latest Swift 5.9 toolchain now that we no longer support universal references and bridge the methods that take in a constant reference template parameter correctly * Fix SERVER_KNOBS and enable use them for masterserver * Bump to C++20, Swift is now able to handle it as well * Put waitForPrev behind FLOW_WITH_SWIFT knob * Forward declare updateLiveCommittedVersion * Remove unused code * fix wrong condition set for updateLiveCommittedVersion * Revert "Revert "Wipe packet buffers that held serialized WipedString (#10018)"" This reverts commit 5ad8dce0525fb1844664ed2ccd7ba595db6913dd. * Enable go-bindings in cmake * Revert "Revert "Wipe packet buffers that held serialized WipedString (#10018)"" This reverts commit 5ad8dce0525fb1844664ed2ccd7ba595db6913dd. * USE_SWIFT flag so we "build without swift" until ready to by default * uncomment a few tests which were disabled during USE_SWIFT enablement * the option is WITH_SWIFT, not USE * formatting * Fix masterserver compile error * Fix some build errors. How did it not merge cleanly? :/ * remove initializer list from constructor * Expect Swift toolchain only if WITH_SWIFT is enabled * Don't require Flow_CheckedContinuation when Swift is disabled * Don't compile FlowCheckedContinuation when WITH_SWIFT=OFF * No-op Swift macros * More compile guards * fix typo * Run clang-format * Guard swift/bridging include in fdbrpc * Remove printf to pass the test * Remove some more printf to avoid potential issues TODO: Need to be TraceEvents instead * Remove __has_feature(nullability) as its only used in Swift * Don't use __FILENAME__ * Don't call generate_module_map outside WITH_SWIFT * Add some more cmake stuff under WITH_SWIFT guard * Some more guards * Bring back TLSTest.cpp * clang-format * fix comment formatting * Remove unused command line arg * fix cmake formatting in some files * Address some review comments * fix clang-format error --------- Co-authored-by: Alex Lorenz <arphaman@gmail.com> Co-authored-by: Russell Sears <russell_sears@apple.com> Co-authored-by: Evan Wilde <etceterawilde@gmail.com> Co-authored-by: Alex Lorenz <aleksei_lorenz@apple.com> Co-authored-by: Vishesh Yadav <vishesh_yadav@apple.com> Co-authored-by: Vishesh Yadav <vishesh3y@gmail.com>
2023-06-03 05:09:28 +08:00
endif() # WITH SWIFT