diff options
Diffstat (limited to 'pkgs/development/compilers/swift/libdispatch')
3 files changed, 0 insertions, 82 deletions
diff --git a/pkgs/development/compilers/swift/libdispatch/default.nix b/pkgs/development/compilers/swift/libdispatch/default.nix deleted file mode 100644 index 4a0616ded5ac..000000000000 --- a/pkgs/development/compilers/swift/libdispatch/default.nix +++ /dev/null @@ -1,42 +0,0 @@ -{ lib -, stdenv -, callPackage -, cmake -, ninja -, useSwift ? true, swift -}: - -let - sources = callPackage ../sources.nix { }; -in stdenv.mkDerivation { - pname = "swift-corelibs-libdispatch"; - - inherit (sources) version; - src = sources.swift-corelibs-libdispatch; - - outputs = [ "out" "dev" "man" ]; - - nativeBuildInputs = [ cmake ] - ++ lib.optionals useSwift [ ninja swift ]; - - patches = [ ./disable-swift-overlay.patch ]; - - cmakeFlags = lib.optional useSwift "-DENABLE_SWIFT=ON"; - - postInstall = '' - # Provide a CMake module. This is primarily used to glue together parts of - # the Swift toolchain. Modifying the CMake config to do this for us is - # otherwise more trouble. - mkdir -p $dev/lib/cmake/dispatch - export dylibExt="${stdenv.hostPlatform.extensions.sharedLibrary}" - substituteAll ${./glue.cmake} $dev/lib/cmake/dispatch/dispatchConfig.cmake - ''; - - meta = { - description = "Grand Central Dispatch"; - homepage = "https://github.com/apple/swift-corelibs-libdispatch"; - platforms = lib.platforms.linux; - license = lib.licenses.asl20; - maintainers = with lib.maintainers; [ cmm dtzWill trepetti dduan trundle stephank ]; - }; -} diff --git a/pkgs/development/compilers/swift/libdispatch/disable-swift-overlay.patch b/pkgs/development/compilers/swift/libdispatch/disable-swift-overlay.patch deleted file mode 100644 index 0ea1869d5528..000000000000 --- a/pkgs/development/compilers/swift/libdispatch/disable-swift-overlay.patch +++ /dev/null @@ -1,35 +0,0 @@ -Enabling Swift support is normally intended for building an overlay for a -Swift SDK, which changes the installation layout. Prevent this. - ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -287,7 +287,7 @@ configure_file("${PROJECT_SOURCE_DIR}/cmake/config.h.in" - add_compile_definitions($<$<OR:$<COMPILE_LANGUAGE:C>,$<COMPILE_LANGUAGE:CXX>>:HAVE_CONFIG_H>) - - --if(ENABLE_SWIFT) -+if(0) - set(INSTALL_TARGET_DIR "${CMAKE_INSTALL_LIBDIR}/swift$<$<NOT:$<BOOL:${BUILD_SHARED_LIBS}>>:_static>/$<LOWER_CASE:${CMAKE_SYSTEM_NAME}>" CACHE PATH "Path where the libraries will be installed") - set(INSTALL_DISPATCH_HEADERS_DIR "${CMAKE_INSTALL_LIBDIR}/swift$<$<NOT:$<BOOL:${BUILD_SHARED_LIBS}>>:_static>/dispatch" CACHE PATH "Path where the headers will be installed for libdispatch") - set(INSTALL_BLOCK_HEADERS_DIR "${CMAKE_INSTALL_LIBDIR}/swift$<$<NOT:$<BOOL:${BUILD_SHARED_LIBS}>>:_static>/Block" CACHE PATH "Path where the headers will be installed for the blocks runtime") ---- a/man/CMakeLists.txt -+++ b/man/CMakeLists.txt -@@ -1,6 +1,6 @@ - - # TODO(compnerd) add symlinks --if(NOT ENABLE_SWIFT) -+if(1) - install(FILES - dispatch.3 - dispatch_after.3 ---- a/src/swift/CMakeLists.txt -+++ b/src/swift/CMakeLists.txt -@@ -47,7 +47,7 @@ get_swift_host_arch(swift_arch) - install(FILES - ${CMAKE_CURRENT_BINARY_DIR}/swift/Dispatch.swiftmodule - ${CMAKE_CURRENT_BINARY_DIR}/swift/Dispatch.swiftdoc -- DESTINATION ${INSTALL_TARGET_DIR}/${swift_arch}) -+ DESTINATION ${INSTALL_TARGET_DIR}/swift) - set_property(GLOBAL APPEND PROPERTY DISPATCH_EXPORTS swiftDispatch) - install(TARGETS swiftDispatch - EXPORT dispatchExports diff --git a/pkgs/development/compilers/swift/libdispatch/glue.cmake b/pkgs/development/compilers/swift/libdispatch/glue.cmake deleted file mode 100644 index dd696dc61085..000000000000 --- a/pkgs/development/compilers/swift/libdispatch/glue.cmake +++ /dev/null @@ -1,5 +0,0 @@ -add_library(dispatch SHARED IMPORTED) -set_property(TARGET dispatch PROPERTY IMPORTED_LOCATION "@out@/lib/libdispatch@dylibExt@") - -add_library(swiftDispatch SHARED IMPORTED) -set_property(TARGET swiftDispatch PROPERTY IMPORTED_LOCATION "@out@/lib/libswiftDispatch@dylibExt@") |