diff options
-rw-r--r-- | app-editors/lapce/Manifest | 2 | ||||
-rw-r--r-- | app-editors/lapce/lapce-0.4.0.ebuild | 70 |
2 files changed, 72 insertions, 0 deletions
diff --git a/app-editors/lapce/Manifest b/app-editors/lapce/Manifest index 473fe9c6d..bca8f011a 100644 --- a/app-editors/lapce/Manifest +++ b/app-editors/lapce/Manifest @@ -1,2 +1,4 @@ DIST lapce-0.3.1-vendor.tar.gz 120112710 BLAKE2B 3d88b82b23e5cb2f9cb6d10f5baedb8e2f3f770ae7f75cc49984d794e35e062d8732efff720d1b5e86da5b51935f758f8bed5f7ccf87de34ed2dbecea8ebd609 SHA512 585930809e7ecb8f4670559e1c372ca3b405cb0aa7bfe51d04d44208f3fd6bc04d646dc709ff5388a68a12dc4d3e5f627bab31404a948179daad78df9d049502 DIST lapce-0.3.1.tar.gz 1607377 BLAKE2B 4c2f7e6d2d84ae5577c1c3a179f62bc7d9e0b5e85a5ca1cc5d24d0cdafe8dd69396d83a68b16bccc1ff82a95a7a7f3ec2bddd6b75c0798b89280e8abda3d195c SHA512 d7fbb5b75ff31f8ab760315fca045c1e1d7bfbcb91a4251b881a565fc6306656a2d8c63328f0cc4b2e8bb84774942b4ceb92f18ad02d245f1a44c2e6c6283dcb +DIST lapce-0.4.0-vendor.tar.gz 140918612 BLAKE2B dfbbd29f473180f98bd9f419559f0012b12515faf4ce41f0ecba2e47427574c101cc39b575848a5b811fa0499c455e661261e9a7f8b9937197671cd0e39582b0 SHA512 e47f29313a47c0ab5f045103359865050ae25b809593509e9efe5e3e4e1f72708524452e89925dbd6139b88a3d7b5be592b69e344c13bb1e3e0c8e9d8d550a2b +DIST lapce-0.4.0.tar.gz 2072771 BLAKE2B 92e86fcf42c44f412651d837cfe3b185f68d7ee82d69e8e42e576253a9f7b81a245418c4c9cfc5f10ef90b1f54c03b046595ae31d2aa981164a47f68e23dabb4 SHA512 27b8a492cda8dfd5111b9eff12ac02781051f30319e6c83b81af5a31df8a44dd57beb2dd1af2414a95b0cc726de4701ea5876f3b79455dc08b0f4baa84b89bdd diff --git a/app-editors/lapce/lapce-0.4.0.ebuild b/app-editors/lapce/lapce-0.4.0.ebuild new file mode 100644 index 000000000..460ffbc71 --- /dev/null +++ b/app-editors/lapce/lapce-0.4.0.ebuild @@ -0,0 +1,70 @@ +# Copyright 2022-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 +EAPI=8 + +CRATES="" + +inherit cargo desktop xdg-utils + +DESCRIPTION="Lightning-fast and Powerful Code Editor written in Rust " +HOMEPAGE="https://lapce.dev/" +SRC_URI=" + https://github.com/lapce/lapce/archive/v${PV}.tar.gz -> ${P}.tar.gz + https://github.com/lapce/lapce/releases/download/v${PV}/vendor.tar.gz -> ${P}-vendor.tar.gz +" + +LICENSE="0BSD Apache-2.0 Apache-2.0-with-LLVM-exceptions Artistic-2 BSD BSD-2 Boost-1.0 CC0-1.0 CeCILL-2.1 GPL-2 ISC MIT MPL-2.0 Unicode-DFS-2016 Unlicense ZLIB" +SLOT="0" +KEYWORDS="~amd64" + +DEPEND=" + x11-libs/gtk+:3 + media-libs/fontconfig + sys-libs/zlib + x11-libs/libxcb:= + dev-libs/libgit2:= +" +RDEPEND="${DEPEND}" +BDEPEND=" + dev-build/cmake + sys-devel/gcc + virtual/pkgconfig + >=virtual/rust-1.64 +" + +# rust does not use *FLAGS from make.conf, silence portage warning +QA_FLAGS_IGNORED="usr/bin/.*" + +src_unpack() { + default + cargo_gen_config + ln -s "${WORKDIR}/vendor/" "${WORKDIR}/lapce-${PV}/vendor" || die + sed -i "${ECARGO_HOME}/config" -e '/source.crates-io/d' || die + sed -i "${ECARGO_HOME}/config" -e '/replace-with = "gentoo"/d' || die + sed -i "${ECARGO_HOME}/config" -e '/local-registry = "\/nonexistent"/d' || die + cat "${WORKDIR}/vendor/vendor-config.toml" >> "${ECARGO_HOME}/config" || die +} + +src_compile() { + export RELEASE_TAG_NAME=v"${PV}" + cargo_src_compile +} + +src_install() { + local btype=release + if use debug; then + btype=debug + fi + dobin target/"${btype}"/lapce + dobin target/"${btype}"/lapce-proxy + domenu extra/linux/dev.lapce.lapce.desktop + newicon extra/images/logo.png dev.lapce.lapce.png +} + +pkg_postinst() { + xdg_desktop_database_update +} + +pkg_postrm() { + xdg_desktop_database_update +} |