From 9cc92f8562ead72cbe77fa19278e6081aeefe56b Mon Sep 17 00:00:00 2001 From: Artemis Everfree Date: Sun, 24 Sep 2023 22:41:28 -0700 Subject: app-office/obsidian: add 1.4.13, drop 1.2.8 Signed-off-by: Artemis Everfree --- app-office/obsidian/Manifest | 4 +- app-office/obsidian/obsidian-1.2.8.ebuild | 68 -------------- app-office/obsidian/obsidian-1.4.13.ebuild | 141 +++++++++++++++++++++++++++++ 3 files changed, 144 insertions(+), 69 deletions(-) delete mode 100644 app-office/obsidian/obsidian-1.2.8.ebuild create mode 100644 app-office/obsidian/obsidian-1.4.13.ebuild (limited to 'app-office') diff --git a/app-office/obsidian/Manifest b/app-office/obsidian/Manifest index 6ef1a4202..14b37904a 100644 --- a/app-office/obsidian/Manifest +++ b/app-office/obsidian/Manifest @@ -1,2 +1,4 @@ -DIST obsidian-1.2.8.gh.deb 71750440 BLAKE2B ea3194205dae9d9e9a3575cfc3a77db7932be02d3ca07df9e3de56346c7bae2ee66d67a4861896506bd80245b54966fdfabbc511973ef491b115fd4cfa7d5d2a SHA512 514706b51908355317982324391e115df1a24ba29a94a177ae465c83b45d239f59c97cac6a26c72b1705a2d7a74bba71f3869ae4170798840556c8324d8eaba3 DIST obsidian-1.3.5.gh.deb 72916766 BLAKE2B d44e9f8db6fc55e6dc7096b2a9bbcb2d68fb3a0eca06028cd0a9bbc7470dc98a05501ca3f81d15197da389f882167ce134b824961684bc8567ea7fa95907e4af SHA512 2047450ab04179be4c95e33fa35731700dbe5961795b8f11dda5410fdbc199486161a6a7abfcc1a3f555f352d014ac3515d1eeb5da984da4f0cdd4adf0e51bbe +DIST obsidian-1.4.13-amd64.tar.gz 99706160 BLAKE2B 3da6f0c2422bd6c8af611ccfe8f52a1a07ad1985a96c3e23a26daaa98d5cff67c137cba7eefa1b59f7d459888d12af4a00331f0cc184d980c316186ed4d6b1a2 SHA512 20b0fdba156bf4dac46e4bd3ddb49dedf005612bcb3687bb5da2cc5c2a8cafc9f43fa911488441adf9ee3c4e65d78158ca22665837894ca50e319774c22742b9 +DIST obsidian-1.4.13-arm64.tar.gz 100139943 BLAKE2B e132df95e4cc8f282fd0c8c81f4fc4a2642a325d0c203d774ee14e6f32a28b2c0c0b7346647e5eb42a0a125a5e74bf4fa8662c473436f79edc9ebd83939616c2 SHA512 046be9f527f4de1070b4bcbd9d3a89e484f55e7e065fd69cb5e8581b8fda4a23db05fba1b5b46af9cc1ff2c520bd5bfd565143bdf5cc7d17cd46d60fcf2fa3da +DIST obsidian-1.4.13.gh.deb 73357626 BLAKE2B d9e8623781b9777eeb9ff24267bfe5aefd02dd6a450063983f12f596c3fb713b3316bb25e4d040939939e554233718f90e4bb00c43b0f153625d922824df2146 SHA512 18806df0d5a77d99a044e2b365133fd6c719289505323e3c8c5555141532e6b5abedd6d45f882562368a4400bdd251e6afb964b68975a88c22bcf906f7885e4d diff --git a/app-office/obsidian/obsidian-1.2.8.ebuild b/app-office/obsidian/obsidian-1.2.8.ebuild deleted file mode 100644 index 7c6ac6f33..000000000 --- a/app-office/obsidian/obsidian-1.2.8.ebuild +++ /dev/null @@ -1,68 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -inherit desktop unpacker xdg - -DESCRIPTION="A second brain, for you, forever." -HOMEPAGE="https://obsidian.md/" -SRC_URI="https://github.com/obsidianmd/obsidian-releases/releases/download/v${PV}/${P/-/_}_amd64.deb -> ${P}.gh.deb" - -LICENSE="Obsidian-EULA" -SLOT="0" -KEYWORDS="~amd64" - -RDEPEND="app-accessibility/at-spi2-core:2 - dev-libs/expat - dev-libs/glib:2 - dev-libs/nspr - dev-libs/nss - media-libs/alsa-lib - media-libs/fontconfig - media-libs/mesa - net-print/cups - sys-apps/dbus - x11-libs/cairo - x11-libs/gtk+:3 - x11-libs/libX11 - x11-libs/libXcomposite - x11-libs/libXdamage - x11-libs/libXext - x11-libs/libXfixes - x11-libs/libXrandr - x11-libs/libdrm - x11-libs/libxcb - x11-libs/libxkbcommon - x11-libs/pango -" - -DIR="/opt/${PN^}" -S="${WORKDIR}" - -QA_PREBUILT="${DIR#/}/chrome-sandbox - ${DIR#/}/chrome_crashpad_handler - ${DIR#/}/libGLESv2.so - ${DIR#/}/libEGL.so - ${DIR#/}/libffmpeg.so - ${DIR#/}/libvk_swiftshader.so - ${DIR#/}/libvulkan.so.1 - ${DIR#/}/obsidian - ${DIR#/}/resources/app.asar.unpacked/node_modules/* -" - -src_install() { - insinto ${DIR} - doins -r ${DIR#/}/* - - domenu usr/share/applications/obsidian.desktop - - for size in 16 32 48 64 128 256 512; do - doicon --size ${size} usr/share/icons/hicolor/${size}x${size}/apps/${PN}.png - done - - fperms 4755 ${DIR}/chrome-sandbox - fperms +x ${DIR}/obsidian - - dosym -r ${DIR}/obsidian /usr/bin/obsidian -} diff --git a/app-office/obsidian/obsidian-1.4.13.ebuild b/app-office/obsidian/obsidian-1.4.13.ebuild new file mode 100644 index 000000000..47c9e43c2 --- /dev/null +++ b/app-office/obsidian/obsidian-1.4.13.ebuild @@ -0,0 +1,141 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +CHROMIUM_VERSION="102" +CHROMIUM_LANGS=" + af am ar bg bn ca cs da de el en-GB en-US es es-419 et fa fi fil fr gu he hi + 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 ta te th tr uk ur vi zh-CN zh-TW +" +inherit chromium-2 desktop linux-info unpacker xdg + +DESCRIPTION="A second brain, for you, forever." +HOMEPAGE="https://obsidian.md/" + +# For some reason, the main binary tarballs don't include the .desktop file or +# icon. The .deb does. One would hope then, that we could just download the .deb +# for each arch, but they only generate a .deb for amd64. Maybe we can get them +# to fix this, but in the meantime, we download the .deb purely to get the +# .desktop file and app icon out of it. +SRC_URI=" + https://github.com/obsidianmd/obsidian-releases/releases/download/v${PV}/${P/-/_}_amd64.deb -> ${P}.gh.deb + amd64? ( https://github.com/obsidianmd/obsidian-releases/releases/download/v${PV}/${P}.tar.gz -> ${P}-amd64.tar.gz ) + arm64? ( https://github.com/obsidianmd/obsidian-releases/releases/download/v${PV}/${P}-arm64.tar.gz ) + +" + +RESTRICT="mirror strip bindist" + +LICENSE="Obsidian-EULA" + +SLOT="0" +KEYWORDS="~amd64 ~arm64" +IUSE="appindicator wayland" + +RDEPEND=" + >=app-accessibility/at-spi2-core-2.46.0:2 + app-crypt/libsecret[crypt] + dev-libs/expat + dev-libs/glib:2 + dev-libs/nspr + dev-libs/nss + media-libs/alsa-lib + media-libs/fontconfig + media-libs/mesa[gbm(+)] + net-print/cups + sys-apps/dbus + sys-apps/util-linux + sys-libs/glibc + x11-libs/cairo + x11-libs/libdrm + x11-libs/gdk-pixbuf:2 + x11-libs/gtk+:3 + x11-libs/libX11 + x11-libs/libXScrnSaver + x11-libs/libXcomposite + x11-libs/libXdamage + x11-libs/libXext + x11-libs/libXfixes + x11-libs/libXrandr + x11-libs/libxcb + x11-libs/libxkbcommon + x11-libs/libxshmfence + x11-libs/pango + appindicator? ( dev-libs/libayatana-appindicator ) +" + +DIR="/opt/${PN^}" + +# deb gets extracted to WORKDIR. actual program gets extracted to its own dir +# which depends on CPU arch. +S="${WORKDIR}" + +QA_PREBUILT="*" + +CONFIG_CHECK="~USER_NS" + +set_obsidian_src_dir() { + if use amd64; then + S_OBSIDIAN="${WORKDIR}/${P}" + elif use arm64; then + S_OBSIDIAN="${WORKDIR}/${P}-arm64" + else + die "Obsidian only supports amd64 and arm64" + fi +} + +src_configure() { + default + chromium_suid_sandbox_check_kernel_config +} + +src_prepare() { + default + # cleanup languages + set_obsidian_src_dir + pushd "${S_OBSIDIAN}/locales/" >/dev/null || die "location change for language cleanup failed" + chromium_remove_language_paks + popd >/dev/null || die "location reset for language cleanup failed" + if use wayland; then + sed -i '/Exec/s/obsidian/obsidian --ozone-platform-hint=auto --enable-features=UseOzonePlatform,WaylandWindowDecorations/' \ + "usr/share/applications/obsidian.desktop" || + die "sed failed for wayland" + fi +} + +src_install() { + insinto "${DIR}" + exeinto "${DIR}" + + set_obsidian_src_dir + pushd "${S_OBSIDIAN}" >/dev/null || die "location change for main install failed" + + doexe obsidian chrome-sandbox libEGL.so libffmpeg.so libGLESv2.so libvk_swiftshader.so libvulkan.so.1 + doins chrome_100_percent.pak chrome_200_percent.pak icudtl.dat resources.pak snapshot_blob.bin \ + v8_context_snapshot.bin vk_swiftshader_icd.json + insopts -m0755 + doins -r locales resources + + # Chrome-sandbox requires the setuid bit to be specifically set. + # see https://github.com/electron/electron/issues/17972 + fowners root "${DIR}/chrome-sandbox" + fperms 4711 "${DIR}/chrome-sandbox" + + [[ -x chrome_crashpad_handler ]] && doins chrome_crashpad_handler + + popd >/dev/null || die "location reset for main install failed" + + dosym "${DIR}/obsidian" "/usr/bin/obsidian" + + if use appindicator; then + dosym ../../usr/lib64/libayatana-appindicator3.so "${DIR}/libappindicator3.so" + fi + + domenu usr/share/applications/obsidian.desktop + + for size in 16 32 48 64 128 256 512; do + doicon --size ${size} usr/share/icons/hicolor/${size}x${size}/apps/${PN}.png + done +} -- cgit v1.2.3-65-gdbad