commit:     0f7b1b8fc204fd637e4e8886444b64975351bee5
Author:     Michael Egger <egger.m <AT> protonmail <DOT> com>
AuthorDate: Fri Sep 20 14:05:43 2024 +0000
Commit:     David Roman <davidroman96 <AT> gmail <DOT> com>
CommitDate: Fri Sep 20 14:05:43 2024 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=0f7b1b8f

dev-util/rust-rover: add 2024.2.1, drop 233.15026.24

Signed-off-by: Michael Egger <egger.m <AT> protonmail.com>

 dev-util/rust-rover/Manifest                       |  2 +-
 dev-util/rust-rover/metadata.xml                   | 11 ++++
 ....15026.24.ebuild => rust-rover-2024.2.1.ebuild} | 58 ++++++++++++----------
 3 files changed, 45 insertions(+), 26 deletions(-)

diff --git a/dev-util/rust-rover/Manifest b/dev-util/rust-rover/Manifest
index a8d45252a..d2171d198 100644
--- a/dev-util/rust-rover/Manifest
+++ b/dev-util/rust-rover/Manifest
@@ -1 +1 @@
-DIST RustRover-233.15026.24.tar.gz 800631981 BLAKE2B 
1ecb1f034506c61b6251bf4c96bcb05e028effdb600829c09fb6e903e0b5b90a4657621e363bf90853a2b7ce5b44eedf03c11a5aaccdec0679a14a06250319ca
 SHA512 
17b33f8c5a6d4a053a4b9ebf71269a73de756000f55d3a6ac7b4a3bd96ddd4566848607100719dcddb392a99d02f71d4cc2f69e934a4dc0ed730556b5d89215b
+DIST RustRover-2024.2.1.tar.gz 1052249211 BLAKE2B 
4035f514ec6556e15ce02c283965f87db20c78a96c03654cb4445dc8af5da715f0421eea4c3a32d50abed96d83c4a2aaa0db8baf5ab0ec530af89f0a7c70d5f7
 SHA512 
7b77850297869a5863b60521307b23738edef5315299881e2d920095823ab183618085d1c8a1ec3d058ab2b0365cc795c41755f1a57882e4d182428d5ccb5b8b

diff --git a/dev-util/rust-rover/metadata.xml b/dev-util/rust-rover/metadata.xml
new file mode 100644
index 000000000..bb14ff285
--- /dev/null
+++ b/dev-util/rust-rover/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd";>
+<pkgmetadata>
+<maintainer type="person">
+       <email>[email protected]</email>
+       <name>Michael Egger</name>
+</maintainer>
+<use>
+       <flag name="bundled-jdk">Use bundled jdk</flag>
+</use>
+</pkgmetadata>

diff --git a/dev-util/rust-rover/rust-rover-233.15026.24.ebuild 
b/dev-util/rust-rover/rust-rover-2024.2.1.ebuild
similarity index 57%
rename from dev-util/rust-rover/rust-rover-233.15026.24.ebuild
rename to dev-util/rust-rover/rust-rover-2024.2.1.ebuild
index e67cef252..650fa8c50 100644
--- a/dev-util/rust-rover/rust-rover-233.15026.24.ebuild
+++ b/dev-util/rust-rover/rust-rover-2024.2.1.ebuild
@@ -2,32 +2,25 @@
 # Distributed under the terms of the GNU General Public License v2
 EAPI=8
 
-inherit desktop wrapper
+inherit desktop wrapper xdg-utils
 
 DESCRIPTION="A feature-rich Rust IDE with timely support by JetBrarins"
-
 HOMEPAGE="https://www.jetbrains.com/rust/";
-
 SRC_URI="https://download.jetbrains.com/rustrover/RustRover-${PV}.tar.gz";
 
 # to keep it tidy.
 S="${WORKDIR}/RustRover-${PV}"
 
 LICENSE="idea-eap-EULA"
-
 SLOT="0"
-
 KEYWORDS="-* ~amd64"
-
-IUSE="gnome X"
-
+IUSE="+bundled-jdk"
 RESTRICT="bindist mirror"
-
 QA_PREBUILT="opt/RustRover"
 
 BDEPEND="dev-util/patchelf"
 
-RDEPEND="
+RDEPEND="!bundled-jdk? ( >=virtual/jre-1.8 )
        >=app-accessibility/at-spi2-core-2.46.0:2
        dev-debug/gdb
        dev-debug/lldb
@@ -68,10 +61,6 @@ src_prepare() {
                Install-Linux-tar.txt
                bin/gdb
                bin/lldb
-               plugins/cwm-plugin/quiche-native/darwin-aarch64
-               plugins/cwm-plugin/quiche-native/darwin-x86-64
-               plugins/cwm-plugin/quiche-native/linux-aarch64
-               plugins/cwm-plugin/quiche-native/win32-x86-64
                plugins/remote-dev-server/selfcontained
                plugins/intellij-rust/bin/linux/arm64
                
plugins/gateway-plugin/lib/remote-dev-workers/remote-dev-worker-linux-arm64
@@ -81,31 +70,50 @@ src_prepare() {
 
        rm -rv "${remove_me[@]}" || die
 
-       for file in "jbr/lib/{libjcef.so,jcef_helper}"
+       sed -i \
+               -e "\$a\\\\" \
+               -e 
"\$a#-----------------------------------------------------------------------" \
+               -e "\$a# Disable automatic updates as these are handled through 
Gentoo's" \
+               -e "\$a# package manager. See bug #704494" \
+               -e 
"\$a#-----------------------------------------------------------------------" \
+               -e "\$aide.no.platform.update=Gentoo" bin/idea.properties
+
+       for file in "jbr/lib/"/{libjcef.so,jcef_helper}
        do
                if [[ -f "${file}" ]]; then
-                       patchelf --set-rpath '$ORIGIN' "${file}" || die
+                       patchelf --set-rpath '$ORIGIN' ${file} || die
                fi
        done
 }
 
 src_install() {
-       local dir="/opt/RustRover"
+       local DIR="/opt/RustRover"
+       local JRE_DIR="jbr"
 
-       insinto "${dir}"
+       insinto ${DIR}
        doins -r *
-       fperms 755 
"${dir}"/bin/{format.sh,fsnotifier,inspect.sh,jetbrains_client.sh,ltedit.sh,remote-dev-server.sh,repair,restarter,rustrover.sh}
 
-       if [[ -d jbr ]]; then
-               fperms 755 
"${dir}"/jbr/bin/{java,javac,javadoc,jcmd,jdb,jfr,jhsdb,jinfo,jmap,jps,jrunscript,jstack,jstat,keytool,rmiregistry,serialver}
-               fperms 755 
"${dir}"/jbr/lib/{chrome-sandbox,jcef_helper,jexec,jspawnhelper}
+       fperms 755 
"${DIR}"/bin/{format.sh,fsnotifier,inspect.sh,jetbrains_client.sh,ltedit.sh,rustrover,rustrover.sh,repair,restarter}
+       fperms 755 
"${DIR}/${JRE_DIR}"/bin/{java,javac,javadoc,jcmd,jdb,jfr,jhsdb,jinfo,jmap,jps,jrunscript,jstack,jstat,keytool,rmiregistry,serialver}
+       fperms 755 
"${DIR}"/${JRE_DIR}/lib/{chrome-sandbox,jcef_helper,jexec,jspawnhelper}
+
+       if ! use bundled-jdk; then
+               rm -r "${D}/${DIR}/${JRE_DIR}" || die
        fi
 
-       make_wrapper "rustrover" "${dir}/bin/rustrover.sh"
+       make_wrapper "rustrover" "${DIR}/bin/rustrover"
        newicon "bin/rustrover.svg" "rustrover.svg"
        make_desktop_entry "rustrover" "RustRover" "rustrover" 
"Development;IDE;"
 
        # recommended by: 
https://confluence.jetbrains.com/display/IDEADEV/Inotify+Watches+Limit
-       insinto /usr/lib/sysctl.d
-       newins - 30-"${PN}"-inotify-watches.conf 
<<<"fs.inotify.max_user_watches = 524288"
+       dodir /etc/sysctl.d/
+       echo "fs.inotify.max_user_watches = 524288" > 
"${D}/etc/sysctl.d/30-idea-inotify-watches.conf" || die
+}
+
+pkg_postinst() {
+       xdg_icon_cache_update
+}
+
+pkg_postrm() {
+       xdg_icon_cache_update
 }

Reply via email to