ycmd: 2018-09-20 -> 2019-09-19; add optional golang completion (#69163)
ycmd: 2018-09-20 -> 2019-09-19; add optional golang completion
This commit is contained in:
commit
f0fec244ca
@ -1,18 +1,19 @@
|
|||||||
{ stdenv, lib, fetchgit, cmake, llvmPackages, boost, python
|
{ stdenv, lib, fetchgit, cmake, llvmPackages, boost, python
|
||||||
, gocode ? null
|
, gocode ? null
|
||||||
, godef ? null
|
, godef ? null
|
||||||
|
, gotools ? null
|
||||||
, rustracerd ? null
|
, rustracerd ? null
|
||||||
, fixDarwinDylibNames, Cocoa ? null
|
, fixDarwinDylibNames, Cocoa ? null
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
pname = "ycmd";
|
pname = "ycmd";
|
||||||
version = "2018-09-20";
|
version = "2019-09-19";
|
||||||
|
|
||||||
src = fetchgit {
|
src = fetchgit {
|
||||||
url = "https://github.com/Valloric/ycmd.git";
|
url = "https://github.com/Valloric/ycmd.git";
|
||||||
rev = "bf658fd78722c517674c0aaf2381e199bca8f163";
|
rev = "c6d360775b0c5c82e2513dce7b625f8bf3812702";
|
||||||
sha256 = "1lwa8xr76vapfpncvp81cn3m9219yw14fl7fzk5gnly60zkphbbl";
|
sha256 = "19rxlval20gg65xc5p7q9cnzfm9zw2j0m6vxxk0vqlalcyh0rnzd";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake ];
|
nativeBuildInputs = [ cmake ];
|
||||||
@ -49,18 +50,28 @@ stdenv.mkDerivation {
|
|||||||
mkdir -p $out/bin
|
mkdir -p $out/bin
|
||||||
ln -s $out/lib/ycmd/ycmd/__main__.py $out/bin/ycmd
|
ln -s $out/lib/ycmd/ycmd/__main__.py $out/bin/ycmd
|
||||||
|
|
||||||
mkdir -p $out/lib/ycmd/third_party/{gocode,godef,racerd/target/release}
|
# Copy everything: the structure of third_party has been known to change.
|
||||||
|
# When linking our own libraries below, do so with '-f'
|
||||||
for p in jedi waitress frozendict bottle parso python-future requests; do
|
# to clobber anything we may have copied here.
|
||||||
cp -r third_party/$p $out/lib/ycmd/third_party
|
mkdir -p $out/lib/ycmd/third_party
|
||||||
done
|
cp -r third_party/* $out/lib/ycmd/third_party/
|
||||||
|
|
||||||
'' + lib.optionalString (gocode != null) ''
|
'' + lib.optionalString (gocode != null) ''
|
||||||
ln -s ${gocode}/bin/gocode $out/lib/ycmd/third_party/gocode
|
TARGET=$out/lib/ycmd/third_party/gocode
|
||||||
|
mkdir -p $TARGET
|
||||||
|
ln -sf ${gocode}/bin/gocode $TARGET
|
||||||
'' + lib.optionalString (godef != null) ''
|
'' + lib.optionalString (godef != null) ''
|
||||||
ln -s ${godef}/bin/godef $out/lib/ycmd/third_party/godef
|
TARGET=$out/lib/ycmd/third_party/godef
|
||||||
|
mkdir -p $TARGET
|
||||||
|
ln -sf ${godef}/bin/godef $TARGET
|
||||||
|
'' + lib.optionalString (gotools != null) ''
|
||||||
|
TARGET=$out/lib/ycmd/third_party/go/src/golang.org/x/tools/cmd/gopls
|
||||||
|
mkdir -p $TARGET
|
||||||
|
ln -sf ${gotools}/bin/gopls $TARGET
|
||||||
'' + lib.optionalString (rustracerd != null) ''
|
'' + lib.optionalString (rustracerd != null) ''
|
||||||
ln -s ${rustracerd}/bin/racerd $out/lib/ycmd/third_party/racerd/target/release
|
TARGET=$out/lib/ycmd/third_party/racerd/target/release
|
||||||
|
mkdir -p $TARGET
|
||||||
|
ln -sf ${rustracerd}/bin/racerd $TARGET
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# fixup the argv[0] and replace __file__ with the corresponding path so
|
# fixup the argv[0] and replace __file__ with the corresponding path so
|
||||||
|
Loading…
x
Reference in New Issue
Block a user