swiftPackages.{sourcekit-lsp,swift-format}: link libdispatch.so
In my experience this solution seems to be necessary on almost all if not all Swift packages on Linux
This commit is contained in:
@@ -7,6 +7,7 @@
|
|||||||
swift,
|
swift,
|
||||||
swiftpm,
|
swiftpm,
|
||||||
swiftpm2nix,
|
swiftpm2nix,
|
||||||
|
Dispatch,
|
||||||
Foundation,
|
Foundation,
|
||||||
XCTest,
|
XCTest,
|
||||||
sqlite,
|
sqlite,
|
||||||
@@ -40,6 +41,10 @@ stdenv.mkDerivation {
|
|||||||
ncursesInput
|
ncursesInput
|
||||||
];
|
];
|
||||||
|
|
||||||
|
env.LD_LIBRARY_PATH = lib.optionalString stdenv.hostPlatform.isLinux (
|
||||||
|
lib.makeLibraryPath [ Dispatch ]
|
||||||
|
);
|
||||||
|
|
||||||
configurePhase = generated.configure + ''
|
configurePhase = generated.configure + ''
|
||||||
swiftpmMakeMutable indexstore-db
|
swiftpmMakeMutable indexstore-db
|
||||||
patch -p1 -d .build/checkouts/indexstore-db -i ${./patches/indexstore-db-macos-target.patch}
|
patch -p1 -d .build/checkouts/indexstore-db -i ${./patches/indexstore-db-macos-target.patch}
|
||||||
|
|||||||
@@ -6,6 +6,7 @@
|
|||||||
swift,
|
swift,
|
||||||
swiftpm,
|
swiftpm,
|
||||||
swiftpm2nix,
|
swiftpm2nix,
|
||||||
|
Dispatch,
|
||||||
Foundation,
|
Foundation,
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
@@ -24,6 +25,10 @@ stdenv.mkDerivation {
|
|||||||
];
|
];
|
||||||
buildInputs = [ Foundation ];
|
buildInputs = [ Foundation ];
|
||||||
|
|
||||||
|
env.LD_LIBRARY_PATH = lib.optionalString stdenv.hostPlatform.isLinux (
|
||||||
|
lib.makeLibraryPath [ Dispatch ]
|
||||||
|
);
|
||||||
|
|
||||||
configurePhase = generated.configure;
|
configurePhase = generated.configure;
|
||||||
|
|
||||||
# We only install the swift-format binary, so don't need the other products.
|
# We only install the swift-format binary, so don't need the other products.
|
||||||
|
|||||||
Reference in New Issue
Block a user