Added new ebuild for Microsoft Visual Studio Code.

This commit is contained in:
Ronald Farrer 2020-01-28 12:47:23 -08:00
parent 5a781b178d
commit 8cd93e3c25
3 changed files with 88 additions and 0 deletions

View file

@ -0,0 +1,3 @@
DIST vscode-1.41.1-amd64.tar.gz 81500694 BLAKE2B 575e6aef99eba240c3d47c1f2e849ef5390ee2e6bc35b38486d5351a63c1654903b93d2f4db74f0f5e0923c89f14d9a47dc69b6b1705ee877bfcbaeeaafd15ec SHA512 c180a2e112dd1bff97adca83c5aeb6d1bd66ba391d2a63dbae83629065c7bd3c0547f3f3cc3e0c1d67dac1ea601f3f620c6fe57906018883d8c943ddcc5a7830
EBUILD vscode-bin-1.41.1.ebuild 1536 BLAKE2B edd26e668bda5b83ca0ee21c5c021cf1b6f00d01242ea1d15dbcdd8ee5ad82fa296d26aeeceeddf51450f3527ef5cbaf2b822fd75996390917be429411e7dbd8 SHA512 67627330b4ee864b19df22153c789ebcacd246ceb1ea4ddc9fd479ddfebd0679892e6a65cbd7db263513cbc6f3d0404117242174a66ba2eeb8e0c977f41e5f1f
MISC metadata.xml 655 BLAKE2B 80c5d8c3e2d161ceab6e9ee70ebff06a0c71ae599b98731a932039e5fbc65afa7fd676181e46d6f5d1b25c11b704c28ee047398a2f07f47b91e685b8f731a8d9 SHA512 f24a7ac89458b31421fa30ad6c3f6c99c1512f1e78bf8668af3e4baa260a25a3b1a87b86454894d9aa2a8ca7df0953f5338f0cf9427afe44da5f76c67249e2cf

View file

@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<upstream>
<remote-id type="github">Microsoft/vscode</remote-id>
<bugs-to>https://github.com/Microsoft/vscode/issues</bugs-to>
<maintainer type="project">
<name>Microsoft</name>
<email>opensource@microsoft.com</email>
</maintainer>
</upstream>
<maintainer type="person">
<email>canutethegreat@gmail.com</email>
<name>Ronald Farrer</name>
<description>CanuteTheGreat-overlay</description>
</maintainer>
<use>
<flag name="pax_kernel">Triggers a paxmarking of the binary</flag>
</use>
</pkgmetadata>

View file

@ -0,0 +1,65 @@
# Copyright 1999-2019 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit desktop pax-utils
MY_PN="${PN/-bin}"
MY_P=${MY_PN}-${PV}
DESCRIPTION="Multiplatform Visual Studio Code from Microsoft (binary version)"
HOMEPAGE="https://code.visualstudio.com"
SRC_URI="
amd64? ( https://update.code.visualstudio.com/${PV}/linux-x64/stable -> ${MY_P}-amd64.tar.gz )
"
RESTRICT="mirror strip bindist"
LICENSE="MS-vscode-EULA"
SLOT="0"
KEYWORDS="~amd64"
IUSE="pax_kernel"
DEPEND="
>=media-libs/libpng-1.2.46
>=x11-libs/gtk+-2.24.8-r1:2
x11-libs/cairo
gnome-base/gconf
x11-libs/libXtst
!app-editors/vscode
"
RDEPEND="
${DEPEND}
app-accessibility/at-spi2-atk
>=net-print/cups-2.0.0
x11-libs/libnotify
x11-libs/libXScrnSaver
dev-libs/nss
app-crypt/libsecret[crypt]"
DOCS=( resources/app/LICENSE.rtf )
QA_PRESTRIPPED="opt/${MY_PN}/code"
QA_PREBUILT="opt/${MY_PN}/code"
pkg_setup(){
use amd64 && S="${WORKDIR}/VSCode-linux-x64"
}
src_install(){
mkdir -p "${ED}/opt/${MY_PN}"
cp -r . "${ED}/opt/${MY_PN}/"
dosym "/opt/${MY_PN}/bin/code" "/usr/bin/${MY_PN}"
dosym "/opt/${MY_PN}/bin/code" "/usr/bin/code"
make_desktop_entry "${MY_PN}" "Visual Studio Code" "${MY_PN}" "Development;IDE"
newicon "resources/app/resources/linux/code.png" ${MY_PN}.png
einstalldocs
use pax_kernel && pax-mark -m "${ED%/}"/opt/${MY_PN}/code
}
pkg_postinst(){
elog "You may install some additional utils, so check them in:"
elog "https://code.visualstudio.com/Docs/setup#_additional-tools"
}