blob: 1018641dfc48b7717cb0e4bab46ad286c16943d9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit distutils
DESCRIPTION="Zeroinstall Injector allows regular users to install software themselves"
HOMEPAGE="http://0install.net/"
SRC_URI="mirror://sourceforge/zero-install/${P}.tar.gz.gpg"
LICENSE=""
SLOT="0"
KEYWORDS=""
IUSE=""
DEPEND="app-crypt/gnupg"
RDEPEND=">=dev-python/pygtk-2.0
${DEPEND}"
# If we decide to do RESTRICT="fetch" instead of trying gpg
#pkg_nofetch() {
# einfo "Zeroinstall is distributed only in gpg-signed tarballs, which ebuilds"
# einfo "cannot currently handle. You must:"
# einfo " 1. Download the file ${P}.tar.gz.gpg from"
# einfo " http://downloads.sourceforge.net/zero-install/zeroinstall-injector-0.27.tar.gz.gpg"
# einfo " 2. Verify the signature:"
# einfo " gpg ${P}.tar.gz.gpg"
# einfo " It has the fingerprint 9242 9807 C985 3C07 44A6 8B9A AE07 8280 59A5 3CC1"
# einfo " 3. Put the resulting ${P}.tar.gz in ${DISTDIR}."
#}
src_unpack() {
local GPGSRC=${P}.tar.gz.gpg
local GPGHOME="${WORKDIR}/.gnupg"
local TARSRC=${P}.tar.gz
# Un-gpg-sign the downloaded archive
cp "${DISTDIR}/${GPGSRC}" "${WORKDIR}"
cp -r "${FILESDIR}/gpgInfo" "${GPGHOME}"
chmod 700 "${GPGHOME}"
cd "${WORKDIR}"
gpg -q --homedir "${GPGHOME}" ${GPGSRC} || die "GPG validation failed"
[ -e ${TARSRC} ] || die "GPG unwrap failed"
# Unpack the unsigned archive
tar -xzf ${TARSRC} || die "Tar unpack failed"
# Patches
cd "${S}"
epatch "${FILESDIR}/${P}-local_feed.patch"
}
src_install() {
distutils_src_install
exeinto "/usr/bin/"
doexe "${FILESDIR}/0distutils"
local BASE_XDG_CONFIG="/etc/xdg/0install.net"
insinto "${BASE_XDG_CONFIG}/injector"
newins "${FILESDIR}/global-${PV}" global
dodir "${BASE_XDG_CONFIG}/local_feeds"
}
|