mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-04-07 03:10:15 -04:00
dev-java/jdtls-bin: new package, add 1.49.0-202507030451
Signed-off-by: Nguyen Dinh Dang Duong <dangduong31205@gmail.com>
This commit is contained in:
1
dev-java/jdtls-bin/Manifest
Normal file
1
dev-java/jdtls-bin/Manifest
Normal file
@@ -0,0 +1 @@
|
||||
DIST jdtls-1.49.0_p202507030451.tar.gz 49052555 BLAKE2B 62bfc716129584fe1e9d1178b2627f3f3459a11824662ae4536aacaaf74b7dcb1f550fe37d3c358ec752926de46ee94c111757322cc05b9147bfacc2394c3397 SHA512 501e628c3bae38fa18ce9c0e88fa4c8d9cd82f2d5de9bf6586bd6efd537d1343ab7f00f05af4c200208bc6446435ce4ba02d84591d21734534092f6e37b85a38
|
||||
31
dev-java/jdtls-bin/files/wrapper
Normal file
31
dev-java/jdtls-bin/files/wrapper
Normal file
@@ -0,0 +1,31 @@
|
||||
#!/bin/sh
|
||||
|
||||
share_dir="${XDG_DATA_HOME:-${HOME}/.local/share}/@PKGNAME@"
|
||||
state_dir="${XDG_STATE_HOME:-${HOME}/.local/state}/@PKGNAME@"
|
||||
|
||||
workspace_dir="${state_dir}/$(pwd | sha1sum | cut -d' ' -f1)"
|
||||
|
||||
mkdir -p "${workspace_dir}"
|
||||
|
||||
if [ ! -d "${share_dir}" ]; then
|
||||
cp -R /usr/share/@PKGNAME@/config_linux "${share_dir}"
|
||||
fi
|
||||
|
||||
cd "/usr/libexec/@PKGNAME@"
|
||||
|
||||
exec java \
|
||||
-Declipse.application=org.eclipse.jdt.ls.core.id1 \
|
||||
-Dosgi.bundles.defaultStartLevel=4 \
|
||||
-Declipse.product=org.eclipse.jdt.ls.core.product \
|
||||
-Dlog.protocol=true \
|
||||
-Dlog.level=ALL \
|
||||
-Dfile.encoding=utf-8 \
|
||||
-Xmx1G \
|
||||
--add-modules=ALL-SYSTEM \
|
||||
--add-opens java.base/java.util=ALL-UNNAMED \
|
||||
--add-opens java.base/java.lang=ALL-UNNAMED \
|
||||
-jar ./plugins/org.eclipse.equinox.launcher_*.jar \
|
||||
-configuration ${share_dir} \
|
||||
-data "${workspace_dir}" \
|
||||
"$@"
|
||||
|
||||
53
dev-java/jdtls-bin/jdtls-bin-1.49.0_p202507030451.ebuild
Normal file
53
dev-java/jdtls-bin/jdtls-bin-1.49.0_p202507030451.ebuild
Normal file
@@ -0,0 +1,53 @@
|
||||
# Copyright 2023 Gabriel Sanches
|
||||
# Distributed under the terms of the Zero-Clause BSD License
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit java-pkg-2
|
||||
|
||||
MY_PV=${PV/_p/-}
|
||||
MY_PN=${PN%%-bin}
|
||||
MY_P="${MY_PN}-${PV}"
|
||||
|
||||
DESCRIPTION="Java language server"
|
||||
SRC_URI="https://download.eclipse.org/jdtls/snapshots/jdt-language-server-${MY_PV}.tar.gz -> ${MY_P}.tar.gz"
|
||||
HOMEPAGE="https://github.com/eclipse/eclipse.jdt.ls"
|
||||
|
||||
LICENSE="EPL"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64"
|
||||
|
||||
DEPEND=">=virtual/jre-1.8:*"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
S="${WORKDIR}"
|
||||
|
||||
JDTLS_LIBEXEC="/usr/libexec/${MY_PN}"
|
||||
JDTLS_SHARE="/usr/share/${MY_PN}"
|
||||
|
||||
JDTLS_WRAPPER="${FILESDIR}/wrapper"
|
||||
|
||||
src_install() {
|
||||
dodir "${JDTLS_LIBEXEC}/bin"
|
||||
dodir "${JDTLS_SHARE}"
|
||||
|
||||
cp -Rp plugins features "${ED}/${JDTLS_LIBEXEC}" || die "failed to copy"
|
||||
cp -Rp bin/${MY_PN} "${ED}/${JDTLS_LIBEXEC}/bin" || die "failed to copy"
|
||||
cp -Rp config_linux "${ED}/${JDTLS_SHARE}" || die "failed to copy"
|
||||
|
||||
sed ${JDTLS_WRAPPER} -e "s;@PKGNAME@;${MY_PN};g" > wrapper
|
||||
dodir /usr/bin
|
||||
newbin wrapper ${MY_PN}
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "If the JDT Language Server fails to start (e.g. ClassNotFoundException),"
|
||||
elog "you may be running into stale Eclipse OSGi cache issues."
|
||||
elog
|
||||
elog "To fix this, remove the following directories:"
|
||||
elog " rm -rf \"\${XDG_DATA_HOME}/jdtls\" or rm -rf \"~/.local/share/jdtls\""
|
||||
elog " rm -rf \"\${XDG_STATE_HOME}/jdtls\" or rm -rf \"~/.local/state/jdtls\""
|
||||
elog
|
||||
elog "They will be recreated cleanly on the next launch."
|
||||
}
|
||||
|
||||
11
dev-java/jdtls-bin/metadata.xml
Normal file
11
dev-java/jdtls-bin/metadata.xml
Normal file
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="project">
|
||||
<email>java@gentoo.org</email>
|
||||
</maintainer>
|
||||
<maintainer type="person">
|
||||
<email>dangduong31205@gmail.com</email>
|
||||
<name>Nguyen Dinh Dang Duong</name>
|
||||
</maintainer>
|
||||
</pkgmetadata>
|
||||
Reference in New Issue
Block a user