DIST opera-12.16-1860.x86_64.linux.tar.xz 14018800 BLAKE2B e0cb727ea79868d1c3c692d445fc8949f554c3bbe2bf3c9f222885891458cab7af1a29096cd3caf6936e83068841dda4bff5b8a17eb55a86bebe39ce2b270183 SHA512 c1289f352ea5fc8133b105771f48fdc56ccd770920330b1a0ed939ff909abc68081447673572eabeb1aae6db5194b6ab35c93afad78a91d8f7a9a0f91e81ef8b
DIST opera-stable_62.0.3331.116_amd64.deb 66479598 BLAKE2B 1015f740686ce3ff8164040f6bdc3f495123dc4d8d7d30c39524d93150eda0de5d5282198103552c952dd6b268f7e88d7fc3de4b0a1fa09099542971e4d0abb8 SHA512 8bbcb77d12f86f3a37ee77f6c4de636b976a1f1367e0992d7efed76e718037bce8e651b0e1a4a722e7c8d9b2a2ad2223c0b6dfd7084191c2e4d670d682a23a52
DIST opera-stable_63.0.3368.35_amd64.deb 60629598 BLAKE2B 5e2be00d2156f87a479f58b0bc3554ca6ff1b9c3c59a7adfc9381602a139ad9172deb1a2e815dbb3c014c67deb474d2a91eb7d4851c8cd6ef857cd4a1ee09564 SHA512 2bb502fbd447efb07163f603f3e8aef23595020483a2670e7cc5ee1faeb093bbcbb8d42cb032ab13b8d6a3978ac305213246843e7603bda16b1c17295f62f87b
+DIST opera-stable_63.0.3368.43_amd64.deb 60652496 BLAKE2B 67cf673cf5d27eb7b66fd9a86f28b475db2138a77740ae5f49bb3bab2eb928950d391ee7cc38947ebb13fce79c82d8de8379f9d3691f100d0247df25df9e002e SHA512 6e3c2fb4b13ddcf0ad461542e3f7f31280042b9604db90f82e8df4c4d8b84a9e234ef76eb372cd3df5a0bebfa373fba0ea62095be74016d440a6d5921b6f216b
--- /dev/null
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+CHROMIUM_LANGS="
+ be bg bn ca cs da de el en-GB en-US es-419 es fil fi fr-CA fr hi hr hu id
+ it ja ko lt lv ms nb nl pl pt-BR pt-PT ro ru sk sr sv sw ta te th tr uk vi
+ zh-CN zh-TW
+
+"
+inherit chromium-2 multilib unpacker xdg-utils
+
+DESCRIPTION="A fast and secure web browser"
+HOMEPAGE="https://www.opera.com/"
+LICENSE="OPERA-2014"
+SLOT="0"
+SRC_URI_BASE="
+ https://download1.operacdn.com/pub/
+ https://download2.operacdn.com/pub/
+ https://download3.operacdn.com/pub/
+ https://download4.operacdn.com/pub/
+"
+for uri in ${SRC_URI_BASE}; do
+SRC_URI+="
+ "${uri}${PN}/desktop/${PV}/linux/${PN}-stable_${PV}_amd64.deb"
+"
+done
+KEYWORDS="~amd64"
+
+RDEPEND="
+ dev-libs/expat
+ dev-libs/glib:2
+ dev-libs/nspr
+ dev-libs/nss
+ gnome-base/gconf:2
+ media-libs/alsa-lib
+ media-libs/fontconfig
+ media-libs/freetype
+ net-misc/curl
+ net-print/cups
+ sys-apps/dbus
+ x11-libs/cairo
+ x11-libs/gdk-pixbuf
+ x11-libs/gtk+:3
+ x11-libs/libX11
+ x11-libs/libXScrnSaver
+ x11-libs/libXcomposite
+ x11-libs/libXcursor
+ x11-libs/libXdamage
+ x11-libs/libXext
+ x11-libs/libXfixes
+ x11-libs/libXi
+ x11-libs/libXrandr
+ x11-libs/libXrender
+ x11-libs/libXtst
+ x11-libs/libnotify
+ x11-libs/pango[X]
+"
+
+QA_PREBUILT="*"
+S=${WORKDIR}
+
+src_unpack() {
+ unpack_deb ${A}
+}
+
+src_prepare() {
+ default
+
+ OPERA_HOME="usr/$(get_libdir)/${PN}"
+
+ case ${ARCH} in
+ amd64)
+ mv usr/lib/x86_64-linux-gnu usr/$(get_libdir) || die
+ rm -r usr/lib || die
+ ;;
+ esac
+
+ rm usr/bin/${PN} || die
+
+ rm usr/share/doc/${PN}-stable/copyright || die
+ mv usr/share/doc/${PN}-stable usr/share/doc/${PF} || die
+ gunzip usr/share/doc/${PF}/changelog.gz || die
+
+ pushd "${OPERA_HOME}"/localization > /dev/null || die
+ chromium_remove_language_paks
+ popd > /dev/null || die
+
+ sed -i \
+ -e 's|^TargetEnvironment|X-&|g' \
+ usr/share/applications/${PN}.desktop || die
+}
+
+src_install() {
+ rm "${OPERA_HOME}"/${PN}_autoupdate || die
+ mv * "${D}" || die
+ dosym ../$(get_libdir)/${PN}/${PN} /usr/bin/${PN}
+ fperms 4711 /"${OPERA_HOME}"/opera_sandbox
+}
+
+pkg_postrm() {
+ xdg_icon_cache_update
+ xdg_desktop_database_update
+ xdg_mimeinfo_database_update
+}
+
+pkg_postinst() {
+ xdg_icon_cache_update
+ xdg_desktop_database_update
+ xdg_mimeinfo_database_update
+}