mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 05:10:05 +02:00
youcompleteme: update to latest version and to python 3.9
Unfortunately it crashes the Python interpreter.
This commit is contained in:
23
app-vim/youcompleteme/patches/ycmd-20220114.patchset
Normal file
23
app-vim/youcompleteme/patches/ycmd-20220114.patchset
Normal file
@@ -0,0 +1,23 @@
|
||||
From d3b425e747b9a8d13dd0a55f89fd6f0707b52e97 Mon Sep 17 00:00:00 2001
|
||||
From: PulkoMandy <pulkomandy@pulkomandy.tk>
|
||||
Date: Sat, 14 Jan 2023 19:24:00 +0100
|
||||
Subject: Use system libclang
|
||||
|
||||
|
||||
diff --git a/ycmd/utils.py b/ycmd/utils.py
|
||||
index 74c352b..3b7b956 100644
|
||||
--- a/ycmd/utils.py
|
||||
+++ b/ycmd/utils.py
|
||||
@@ -28,8 +28,7 @@ import threading
|
||||
|
||||
LOGGER = logging.getLogger( 'ycmd' )
|
||||
ROOT_DIR = os.path.normpath( os.path.join( os.path.dirname( __file__ ), '..' ) )
|
||||
-DIR_OF_THIRD_PARTY = os.path.join( ROOT_DIR, 'third_party' )
|
||||
-LIBCLANG_DIR = os.path.join( DIR_OF_THIRD_PARTY, 'clang', 'lib' )
|
||||
+LIBCLANG_DIR = "/system/lib"
|
||||
if hasattr( os, 'add_dll_directory' ):
|
||||
os.add_dll_directory( LIBCLANG_DIR )
|
||||
|
||||
--
|
||||
2.37.3
|
||||
|
||||
93
app-vim/youcompleteme/youcompleteme-20220114.recipe
Normal file
93
app-vim/youcompleteme/youcompleteme-20220114.recipe
Normal file
@@ -0,0 +1,93 @@
|
||||
SUMMARY="Code-completion engine for Vim"
|
||||
DESCRIPTION="YouCompleteMe is a fast, as-you-type, fuzzy-search code \
|
||||
completion engine for Vim. It has several completion engines:
|
||||
* an identifier-based engine that works with every programming language,
|
||||
* a Clang-based engine that provides native semantic code completion for \
|
||||
C/C++/Objective-C/Objective-C++ (from now on referred to as \"the C-family \
|
||||
languages\"),
|
||||
* a Jedi-based completion engine for Python 2 and 3 (using the JediHTTP wrapper),
|
||||
* an OmniSharp-based completion engine for C#,
|
||||
* a combination of Gocode and Godef semantic engines for Go,
|
||||
* a TSServer-based completion engine for TypeScript,
|
||||
* a Tern-based completion engine for JavaScript,
|
||||
* a racer-based completion engine for Rust,
|
||||
* a jdt.ls-based experimental completion engine for Java.
|
||||
* and an omnifunc-based completer that uses data from Vim's omnicomplete \
|
||||
system to provide semantic completions for many other languages (Ruby, PHP \
|
||||
etc.)."
|
||||
HOMEPAGE="http://ycm-core.github.io/YouCompleteMe/"
|
||||
COPYRIGHT="2015-2023 YouCompleteMe contributors"
|
||||
LICENSE="GNU GPL v3"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/ycm-core/YouCompleteMe/archive/7620d87fe1a1632c620921cb0989d358638fb324.zip"
|
||||
SOURCE_DIR="YouCompleteMe-7620d87fe1a1632c620921cb0989d358638fb324"
|
||||
CHECKSUM_SHA256="e8e2c979c8fff4f46da411120e5c31e80e3c638de9c2085b13c245e97f75f8b5"
|
||||
SOURCE_URI_2="https://github.com/ycm-core/ycmd/archive/f53e7acf511748dd50f733c11b7de93416410c17.zip"
|
||||
SOURCE_DIR_2="ycmd-f53e7acf511748dd50f733c11b7de93416410c17"
|
||||
PATCHES_2="ycmd-20220114.patchset"
|
||||
CHECKSUM_SHA256_2="0e288ac324a571f002a04f50cdeb144538ea936332d646f6f0519c322cb6522d"
|
||||
|
||||
ARCHITECTURES="!all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="!x86"
|
||||
|
||||
PROVIDES="
|
||||
youcompleteme$secondaryArchSuffix = $portVersion
|
||||
lib:ycm_core.cpython_39$secondaryArchSuffix
|
||||
"
|
||||
|
||||
# Yes, this needs both python (for vim embedded parts) and python3 (for the
|
||||
# ycmd server) packages.
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:vim >= 8.2
|
||||
bottle_python39
|
||||
certifi_python39
|
||||
frozendict_python39
|
||||
future_python39
|
||||
requests_futures_python39
|
||||
requests_python39
|
||||
waitress_python39
|
||||
watchdog_python39
|
||||
lib:libabsl_base$secondaryArchSuffix
|
||||
lib:libclang$secondaryArchSuffix >= 12
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libabsl_base$secondaryArchSuffix
|
||||
devel:libclang$secondaryArchSuffix >= 12
|
||||
devel:libpython3.9$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:cmake
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ninja
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
mkdir -p ycm_build
|
||||
mkdir -p $developLibDir
|
||||
cd ycm_build
|
||||
|
||||
rm -rf ../third_party/ycmd
|
||||
ln -s ../../../sources-2/ycmd-* ../third_party/ycmd
|
||||
|
||||
cmake -GNinja $cmakeDirArgs ../third_party/ycmd/cpp \
|
||||
-DUSE_SYSTEM_LIBCLANG=ON -DUSE_SYSTEM_ABSEIL=ON \
|
||||
-DPYTHON_INCLUDE_DIR=/system/develop/headers/python3.9 \
|
||||
-DCMAKE_BUILD_TYPE=Release
|
||||
ninja $jobArgs ycm_core
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
mkdir -p $dataDir/vim/vim82
|
||||
cp -r autoload doc python plugin $dataDir/vim/vim82
|
||||
|
||||
mkdir -p $dataDir/vim/vim82/third_party/ycmd
|
||||
cp -r third_party/ycmd/ycm_core.cpython-39.so $dataDir/vim/vim82/third_party/ycmd/
|
||||
cp -r third_party/ycmd/ycmd $dataDir/vim/vim82/third_party/ycmd/ycmd
|
||||
cp third_party/ycmd/CORE_VERSION $dataDir/vim/vim82/third_party/ycmd/
|
||||
}
|
||||
Reference in New Issue
Block a user