x11-terms/ghostty: add missing depend dev-libs/oniguruma
[gentoo-zh.git] / app-editors / cursor / cursor-0.44.8-r1.ebuild
blob3e8362e9b613e36e454fcd1e4e6948113fb8b1fe
1 # Copyright 1999-2024 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
4 EAPI=8
6 CHROMIUM_LANGS="
7 af am ar bg bn ca cs da de el en-GB en-US es-419 es et fa fil fi fr gu he hi
8 hr hu id it ja kn ko lt lv ml mr ms nb nl pl pt-BR pt-PT ro ru sk sl sr sv sw
9 ta te th tr uk ur vi zh-CN zh-TW
12 inherit chromium-2 desktop pax-utils unpacker xdg optfeature
14 DESCRIPTION="Cursor App - AI-first coding environment"
15 HOMEPAGE="https://www.cursor.com/"
16 SRC_URI="https://download.todesktop.com/230313mzl4w4u92/${P}-build-241222ooktny8mh-amd64.deb"
17 S="${WORKDIR}"
19 LICENSE="cursor"
21 SLOT="0"
22 KEYWORDS="-* amd64"
23 IUSE="egl kerberos wayland"
24 RESTRICT="bindist mirror strip"
26 RDEPEND="
27 >=app-accessibility/at-spi2-core-2.46.0:2
28 app-crypt/libsecret[crypt]
29 app-misc/ca-certificates
30 dev-libs/expat
31 dev-libs/glib:2
32 dev-libs/nspr
33 dev-libs/nss
34 media-libs/alsa-lib
35 media-libs/libglvnd
36 media-libs/mesa
37 net-misc/curl
38 sys-apps/dbus
39 sys-libs/zlib
40 sys-process/lsof
41 x11-libs/cairo
42 x11-libs/gtk+:3
43 x11-libs/libdrm
44 x11-libs/libX11
45 x11-libs/libxcb
46 x11-libs/libXcomposite
47 x11-libs/libXdamage
48 x11-libs/libXext
49 x11-libs/libXfixes
50 x11-libs/libxkbcommon
51 x11-libs/libxkbfile
52 x11-libs/libXrandr
53 x11-libs/libXScrnSaver
54 x11-libs/pango
55 x11-misc/xdg-utils
56 kerberos? ( app-crypt/mit-krb5 )
59 QA_PREBUILT="*"
60 CURSOR_HOME="opt/Cursor"
62 src_configure() {
63 default
64 chromium_suid_sandbox_check_kernel_config
67 src_prepare() {
68 default
69 pushd "${CURSOR_HOME}/locales" > /dev/null || die
70 chromium_remove_language_paks
71 popd > /dev/null || die
74 src_install() {
75 dodir /opt/cursor
76 cp -ar "${CURSOR_HOME}/." "${D}/opt/cursor/" || die
78 fperms 4711 /opt/cursor/chrome-sandbox
79 pax-mark m /opt/cursor/cursor
80 dosym ../cursor/cursor /opt/bin/cursor
82 local EXEC_EXTRA_FLAGS=()
83 if use wayland; then
84 EXEC_EXTRA_FLAGS+=( "--ozone-platform-hint=auto" "--enable-wayland-ime" )
86 if use egl; then
87 EXEC_EXTRA_FLAGS+=( "--use-gl=egl" )
90 sed -i -e "s|^Exec=.*|Exec=cursor ${EXEC_EXTRA_FLAGS[*]} %U|" \
91 usr/share/applications/cursor.desktop || die
92 domenu usr/share/applications/cursor.desktop
94 insinto /usr/share
95 doins -r usr/share/icons
98 pkg_postinst() {
99 xdg_pkg_postinst
100 optfeature "desktop notifications" x11-libs/libnotify
101 optfeature "keyring support inside cursor" "virtual/secret-service"