app-emulation/genymotion-bin: bump version to 3.1.0
authorMarco Genasci <fedeliallalinea@gmail.com>
Wed, 15 Apr 2020 17:43:33 +0000 (19:43 +0200)
committerJoonas Niilola <juippis@gentoo.org>
Fri, 17 Apr 2020 07:35:54 +0000 (10:35 +0300)
Package-Manager: Portage-2.3.89, Repoman-2.3.20
Bug: https://bugs.gentoo.org/717524
Signed-off-by: Marco Genasci <fedeliallalinea@gmail.com>
Signed-off-by: Joonas Niilola <juippis@gentoo.org>
app-emulation/genymotion-bin/Manifest
app-emulation/genymotion-bin/genymotion-bin-3.1.0.ebuild [new file with mode: 0644]

index fee6b87e7500c25f350f7a746f1fb0235a83a7a3..4198ba1e3705dbcc6a7158d559bfa81308b4611c 100644 (file)
@@ -1 +1,2 @@
 DIST genymotion-3.0.4-linux_x64.bin 38811828 BLAKE2B 6b8c2aa824bc232d09b43e1c69c1531d447bfc3341ea83a277058198f812d66e9e900abb7186d1c4a45c9e12c92ebec7c809e1641d0e3e30edf77c52fa1818e7 SHA512 28bebf3468049b5eeda9890167f89a0537fa21a42eacd3c30ae9a40616fd215282075853f35179fa40b21b124f400106d82e1cfb4949fffca741ed83ba69417b
+DIST genymotion-3.1.0-linux_x64.bin 40490397 BLAKE2B 4601ff24b5cc2f33c442ec6cf76e04eaa010304d4097b30ac82c7d6824dc3949b409ec5867cc7f08ee2985e254eefc9d8282ff77a5a92961dec0df9f3f80c6d7 SHA512 53a325b0a7eac6998ae525277d3a566ab6a73e21eccd6496caecefc175138b604a516d2bba1fac9f61ad52aaf9dcf0dd1fe2cd2da0c5c31a2f48c08f88a2a68a
diff --git a/app-emulation/genymotion-bin/genymotion-bin-3.1.0.ebuild b/app-emulation/genymotion-bin/genymotion-bin-3.1.0.ebuild
new file mode 100644 (file)
index 0000000..f574537
--- /dev/null
@@ -0,0 +1,126 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit bash-completion-r1 desktop pax-utils
+
+MY_PN="${PN/-bin}"
+MY_P="${MY_PN}-${PV}"
+BIN_ARCHIVE="${MY_P}-linux_x64.bin"
+
+DESCRIPTION="Complete set of tools that provide a virtual environment for Android"
+HOMEPAGE="https://genymotion.com"
+SRC_URI="${BIN_ARCHIVE}"
+
+LICENSE="genymotion"
+SLOT="0"
+KEYWORDS="-* ~amd64"
+
+RDEPEND="|| (
+               app-emulation/virtualbox
+               app-emulation/virtualbox-bin
+       )
+       || (
+               dev-libs/openssl-compat:1.0.0
+               =dev-libs/openssl-1.0*:0
+       )
+       dev-libs/hiredis:0/0.14
+       sys-apps/util-linux
+       virtual/opengl
+"
+BDEPEND="dev-util/patchelf"
+
+RESTRICT="bindist fetch"
+S="${WORKDIR}"
+
+QA_PREBUILT="
+       opt/${MY_PN}/*.so*
+       opt/${MY_PN}/imageformats/*.so
+       opt/${MY_PN}/plugins/*.so*
+       opt/${MY_PN}/${MY_PN}
+       opt/${MY_PN}/genyshell
+       opt/${MY_PN}/player
+       opt/${MY_PN}/${MY_PN}adbtunneld
+       opt/${MY_PN}/gmtool
+"
+
+pkg_nofetch() {
+       einfo
+       einfo "Please visit"
+       einfo
+       einfo "  https://www.genymotion.com/download/"
+       einfo
+       einfo "and download "
+       einfo
+       einfo "  ${BIN_ARCHIVE}"
+       einfo
+       einfo "which must be placed in DISTDIR directory."
+       einfo
+}
+
+src_unpack() {
+       cp "${DISTDIR}/${BIN_ARCHIVE}" "${WORKDIR}" || die "cp failed"
+}
+
+src_prepare() {
+       default
+
+       chmod +x ${BIN_ARCHIVE} || die "chmod failed"
+       yes | ./${BIN_ARCHIVE} > /dev/null || die "unpack failed"
+
+       # removed windows line for bashcompletion
+       sed -i "/complete -F _gmtool gmtool.exe/d" "${MY_PN}/completion/bash/gmtool.bash" || die "sed failed"
+
+       # patch to support newer hiredis version (0.14)
+       for i in genymotion genyshell gmtool player libcom.so.1.0.0 librendering.so.1.0.0 ; do
+               patchelf --replace-needed libhiredis.so.0.13 libhiredis.so.0.14 "${MY_PN}/${i}" || die "Unable to patch ${i} for hiredis"
+       done
+}
+
+src_install() {
+       insinto /opt/"${MY_PN}"
+       exeinto /opt/"${MY_PN}"
+
+       # Use qt bundled
+       doins -r "${MY_PN}"/{geoservices,Qt,QtGraphicalEffects,QtLocation,QtPositioning,QtQuick,QtQuick.2}
+       doins -r "${MY_PN}"/{icons,imageformats,platforms,plugins,sqldrivers,translations,xcbglintegrations}
+       doins "${MY_PN}"/libQt*
+       doins "${MY_PN}"/libqgsttools_p.so.1
+       doins "${MY_PN}"/qt.conf
+       doins "${MY_PN}"/libicu*
+
+       doexe "${MY_PN}"/{libcom,librendering,libswscale,libavutil}.so*
+       # android library
+       doexe "${MY_PN}"/{libEGL_translator,libGLES_CM_translator,libGLES_V2_translator,libOpenglRender,libemugl_logger}.so*
+
+       find "${ED}/opt/${MY_PN}" -name "*.so*" -type f -exec chmod +x {} \; || die "Change .so permission failed"
+
+       doexe "${MY_PN}"/{genymotion,genyshell,player,gmtool}
+
+       pax-mark -m "${ED}/opt/${MY_PN}/genymotion"
+       pax-mark -m "${ED}/opt/${MY_PN}/gmtool"
+
+       dosym ../"${MY_PN}"/genyshell /opt/bin/genyshell
+       dosym ../"${MY_PN}"/genymotion /opt/bin/genymotion
+       dosym ../"${MY_PN}"/gmtool /opt/bin/gmtool
+
+       newbashcomp "${MY_PN}/completion/bash/gmtool.bash" gmtool
+
+       insinto /usr/share/zsh/site-functions
+       doins "${MY_PN}/completion/zsh/_gmtool"
+
+       sed -i -e "s:Icon.*:Icon=/opt/${MY_PN}/icons/icon.png:" \
+               -e "s:Exec.*:Exec=/opt/${MY_PN}/genymotion:" \
+               "${HOME}"/.local/share/applications/genymobile-genymotion.desktop || die "sed failed"
+       domenu "${HOME}"/.local/share/applications/genymobile-genymotion.desktop
+}
+
+pkg_postinst() {
+       elog "Genymotion needs adb to work correctly: install with android-sdk-update-manager"
+       elog "'Android SDK Platform-tools' and 'Android SDK Tools'"
+       elog "Your user should also be in the android group to work correctly"
+       elog "Then in Genymotion set the android-sdk-update-manager directory: (Settings->ADB)"
+       elog
+       elog "      /opt/android-sdk-update-manager"
+}