Gentoo Archives: gentoo-commits

From: "Göktürk Yüksek" <gokturk@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/lastpass-binary-component/
Date: Tue, 12 Dec 2017 02:57:18
Message-Id: 1513047343.b0fdfbee88ccedbcbd60305419104edc6183c65b.gokturk@gentoo
1 commit: b0fdfbee88ccedbcbd60305419104edc6183c65b
2 Author: Göktürk Yüksek <gokturk <AT> gentoo <DOT> org>
3 AuthorDate: Mon Dec 11 00:52:35 2017 +0000
4 Commit: Göktürk Yüksek <gokturk <AT> gentoo <DOT> org>
5 CommitDate: Tue Dec 12 02:55:43 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b0fdfbee
7
8 app-admin/lastpass-binary-component: bump (!) and fix the fetch failure #640506
9
10 "Let's extend LastPass support to Firefox using Native
11 Messaging. While doing so, let's modify our closed binary and change
12 who-knows-what too. And yeah, let's release it under the same version
13 4.1.44 because version bumps are sissies and only losers release
14 versioned tarballs."
15
16 Also separate the app manifest files for Chrome and Chromium because
17 allowed-origins are not the same. Add more comments to clarify the
18 file system locations for various installed files.
19
20 Update the postinst message to reflect that for some browsers users
21 have to enable the binary component manually after installing the
22 extension.
23
24 Closes: https://bugs.gentoo.org/640506
25 Package-Manager: Portage-2.3.8, Repoman-2.3.2
26
27 app-admin/lastpass-binary-component/Manifest | 2 +-
28 ...tpass-binary-component-4.1.44_p20171210.ebuild} | 59 +++++++++++++++++++---
29 2 files changed, 53 insertions(+), 8 deletions(-)
30
31 diff --git a/app-admin/lastpass-binary-component/Manifest b/app-admin/lastpass-binary-component/Manifest
32 index 1cbcb8e814d..3f6f4cab04a 100644
33 --- a/app-admin/lastpass-binary-component/Manifest
34 +++ b/app-admin/lastpass-binary-component/Manifest
35 @@ -1 +1 @@
36 -DIST lastpass-binary-component-4.1.44.tar.bz2 1623477 SHA256 adb0e91f8d212d34dbb85db0b11738fe36db1a741ad5674d7070c4019a9fc75e SHA512 6fd518fa19f7206a1007376460c61e5a5c8d868126a767b3978309f0cc7ccd069e743cb12364e6841d8d3cb29452d058122b95f42bcfd2bd4deb4b8c77dc5f75 WHIRLPOOL c50bde0ee3f82abe56803beb2bda09786f7806b5e480eb8401fe0302ee984465f2682af66243095f3ea83744d59d6d3548806c423b69a8603abed9fc3ba3d00c
37 +DIST lastpass-binary-component-4.1.44_p20171210.tar.bz2 1625075 BLAKE2B 90812cfae90c90ab7f91ac293e501e9b8c6d0b4fca9e1f05e88865eb85042286308d2ce6eb90d306583aa9481de7588746a3402c3b4b9f29e2e540e4a4c2b287 SHA512 16ceebd054fe807975f838305044bf5e75ccbba2c592f7bf08af18d1209067c7e8b0e00457092242c3869de2ec5c59bfdfdb3ff06f801dbb2108b7dac1a7adbf
38
39 diff --git a/app-admin/lastpass-binary-component/lastpass-binary-component-4.1.44.ebuild b/app-admin/lastpass-binary-component/lastpass-binary-component-4.1.44_p20171210.ebuild
40 similarity index 51%
41 rename from app-admin/lastpass-binary-component/lastpass-binary-component-4.1.44.ebuild
42 rename to app-admin/lastpass-binary-component/lastpass-binary-component-4.1.44_p20171210.ebuild
43 index c46f9987de0..beff308bc57 100644
44 --- a/app-admin/lastpass-binary-component/lastpass-binary-component-4.1.44.ebuild
45 +++ b/app-admin/lastpass-binary-component/lastpass-binary-component-4.1.44_p20171210.ebuild
46 @@ -23,7 +23,7 @@ QA_PREBUILT="
47 ${LASTPASS_EXEDIR}nplastpass*
48 "
49
50 -S="${WORKDIR}/lplinux"
51 +S="${WORKDIR}"
52
53 src_install() {
54 # This is based on the upstream installer script that's in the tarball
55 @@ -32,6 +32,7 @@ src_install() {
56 exeinto ${LASTPASS_EXEDIR}
57 doexe "${S}"/${bin}
58
59 + # Generate the policy file for Chrome/Chromium/Opera
60 cat >"${T}"/lastpass_policy.json <<-EOF || die
61 {
62 "ExtensionInstallSources": [
63 @@ -41,6 +42,13 @@ src_install() {
64 ]
65 }
66 EOF
67 + # Install the policy file for Chrome/Chromium/Opera
68 + for d in /etc/chromium /etc/opt/chrome; do
69 + insinto ${d}/policies/managed
70 + doins "${T}"/lastpass_policy.json
71 + done
72 +
73 + # Generate the app manifest for Chrome/Opera
74 cat >"${T}"/com.lastpass.nplastpass.json <<-EOF || die
75 {
76 "name": "com.lastpass.nplastpass",
77 @@ -55,19 +63,56 @@ src_install() {
78 ]
79 }
80 EOF
81 + # Install the app manifest for Chrome/Opera
82 + # https://developer.chrome.com/apps/nativeMessaging
83 + # https://dev.opera.com/extensions/message-passing/
84 + insinto /etc/opt/chrome/native-messaging-hosts
85 + doins "${T}"/com.lastpass.nplastpass.json
86
87 - for d in /etc/chromium /etc/opt/chrome; do
88 - insinto ${d}/policies/managed
89 - doins "${T}"/lastpass_policy.json
90 - insinto ${d}/native-messaging-hosts
91 - doins "${T}"/com.lastpass.nplastpass.json
92 - done
93 + # Generate the app manifest for Chromium
94 + cat >"${T}"/com.lastpass.nplastpass.json <<-EOF || die
95 + {
96 + "name": "com.lastpass.nplastpass",
97 + "description": "LastPass",
98 + "path": "${LASTPASS_EXEDIR}${bin}",
99 + "type": "stdio",
100 + "allowed_origins": [
101 + "chrome-extension://hdokiejnpimakedhajhdlcegeplioahd/",
102 + "chrome-extension://debgaelkhoipmbjnhpoblmbacnmmgbeg/",
103 + "chrome-extension://hgnkdfamjgnljokmokheijphenjjhkjc/"
104 + ]
105 + }
106 + EOF
107 + # Install the app manifest for Chromium
108 + # https://developer.chrome.com/apps/nativeMessaging
109 + insinto /etc/chromium/native-messaging-hosts/
110 + doins "${T}"/com.lastpass.nplastpass.json
111
112 + # Generate the app manifest for Firefox
113 + cat >"${T}"/com.lastpass.nplastpass.json <<-EOF || die
114 + {
115 + "name": "com.lastpass.nplastpass",
116 + "description": "LastPass",
117 + "path": "${LASTPASS_EXEDIR}${bin}",
118 + "type": "stdio",
119 + "allowed_extensions": [
120 + "support@××××××××.com"
121 + ]
122 + }
123 + EOF
124 + # Install the app manifest for Firefox
125 + # https://developer.mozilla.org/en-US/Add-ons/WebExtensions/Native_manifests#Manifest_location
126 + insinto /usr/lib/mozilla/native-messaging-hosts/
127 + doins "${T}"/com.lastpass.nplastpass.json
128 }
129
130 pkg_postinst() {
131 einfo "This package only installs the components required by the browser extension."
132 einfo "Visit the links below for your browser to install the extension itself:"
133 einfo "Chrome/Chromium: https://lastpass.com/dl/inline/?full=1"
134 + einfo "Firefox: https://lastpass.com/lastpassffx/"
135 einfo "Opera: https://lastpass.com/dl/"
136 + einfo
137 + einfo "Chrome, Chromium and Opera users need to manually enable the binary component."
138 + einfo "For more info, visit: https://lastpass.com/support.php?cmd=showfaq&id=5576"
139 }