/[gentoo-x86]/sys-fs/ecryptfs-utils/ecryptfs-utils-91.ebuild
Gentoo

Contents of /sys-fs/ecryptfs-utils/ecryptfs-utils-91.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Sat Jun 30 05:25:57 2012 UTC (21 months, 3 weeks ago) by radhermit
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +1 -1 lines
FILE REMOVED
Remove old.

(Portage version: 2.2.0_alpha114/cvs/Linux x86_64)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sys-fs/ecryptfs-utils/ecryptfs-utils-91.ebuild,v 1.3 2012/05/04 19:09:16 jdhore Exp $
4
5 EAPI="3"
6 PYTHON_DEPEND="python? 2:2.5"
7 SUPPORT_PYTHON_ABIS="1"
8 RESTRICT_PYTHON_ABIS="2.4 3.* *-jython 2.7-pypy-*"
9
10 inherit flag-o-matic pam python linux-info autotools
11
12 DESCRIPTION="eCryptfs userspace utilities"
13 HOMEPAGE="http://launchpad.net/ecryptfs"
14 SRC_URI="http://launchpad.net/ecryptfs/trunk/${PV}/+download/${PN}_${PV}.orig.tar.gz"
15
16 LICENSE="GPL-2"
17 SLOT="0"
18 KEYWORDS="~amd64 ~x86"
19 IUSE="doc gpg gtk openssl pam pkcs11 python suid tpm"
20
21 RDEPEND=">=sys-apps/keyutils-1.0
22 >=dev-libs/libgcrypt-1.2.0
23 dev-libs/nss
24 gpg? ( app-crypt/gpgme )
25 gtk? ( x11-libs/gtk+:2 )
26 openssl? ( >=dev-libs/openssl-0.9.7 )
27 pam? ( sys-libs/pam )
28 pkcs11? (
29 >=dev-libs/openssl-0.9.7
30 >=dev-libs/pkcs11-helper-1.04
31 )
32 tpm? ( app-crypt/trousers )"
33 DEPEND="${RDEPEND}
34 virtual/pkgconfig
35 sys-devel/gettext
36 >=dev-util/intltool-0.41.0
37 python? ( dev-lang/swig )"
38
39 pkg_setup() {
40 if use python; then
41 python_pkg_setup
42 fi
43
44 CONFIG_CHECK="~ECRYPT_FS"
45 linux-info_pkg_setup
46 }
47
48 src_prepare() {
49 echo "#!/bin/sh" > py-compile
50
51 # Python bindings are built/installed manually.
52 sed -e "/SUBDIRS =/s/ libecryptfs-swig//" -i src/Makefile.am || die "sed failed"
53
54 eautoreconf
55 }
56
57 src_configure() {
58 append-flags -D_FILE_OFFSET_BITS=64
59
60 econf \
61 --docdir="/usr/share/doc/${PF}" \
62 --enable-nss \
63 --with-pamdir=$(getpam_mod_dir) \
64 $(use_enable doc docs) \
65 $(use_enable gpg) \
66 $(use_enable gtk gui) \
67 $(use_enable openssl) \
68 $(use_enable pam) \
69 $(use_enable pkcs11 pkcs11-helper) \
70 $(use_enable python pywrap) \
71 $(use_enable tpm tspi)
72 }
73
74 src_compile() {
75 default
76
77 if use python; then
78 python_copy_sources src/libecryptfs-swig
79 building() {
80 emake \
81 PYTHON="$(PYTHON)" \
82 PYTHON_CPPFLAGS="-I$(python_get_includedir)" \
83 PYTHON_LDFLAGS="-L$(python_get_libdir) $(python_get_library -l)" \
84 PYTHON_SITE_PKG="$(python_get_sitedir)" \
85 PYTHON_VERSION="$(python_get_version)" \
86 SWIG_PYTHON_CPPFLAGS="-I$(python_get_includedir)" \
87 pyexecdir="$(python_get_sitedir)" \
88 pythondir="$(python_get_sitedir)"
89 }
90 python_execute_function -s --source-dir src/libecryptfs-swig building
91 fi
92 }
93
94 src_install(){
95 emake DESTDIR="${D}" install || die "emake install failed"
96
97 if use python; then
98 installation() {
99 emake \
100 DESTDIR="${D}" \
101 PYTHON="$(PYTHON)" \
102 PYTHON_CPPFLAGS="-I$(python_get_includedir)" \
103 PYTHON_LDFLAGS="-L$(python_get_libdir) $(python_get_library -l)" \
104 PYTHON_SITE_PKG="$(python_get_sitedir)" \
105 PYTHON_VERSION="$(python_get_version)" \
106 SWIG_PYTHON_CPPFLAGS="-I$(python_get_includedir)" \
107 pyexecdir="$(python_get_sitedir)" \
108 pythondir="$(python_get_sitedir)" \
109 install || return 1
110 echo "ecryptfs-utils" > "${ED}$(python_get_sitedir)/ecryptfs-utils.pth"
111 }
112 python_execute_function -s --source-dir src/libecryptfs-swig installation
113
114 python_clean_installation_image
115 fi
116
117 use suid && fperms u+s /sbin/mount.ecryptfs_private
118
119 find "${D}" -name '*.la' -exec rm -f '{}' +
120 }
121
122 pkg_postinst() {
123 if use python; then
124 python_mod_optimize ecryptfs-utils
125 fi
126
127 if use suid; then
128 ewarn
129 ewarn "You have chosen to install ${PN} with the binary setuid root. This"
130 ewarn "means that if there are any undetected vulnerabilities in the binary,"
131 ewarn "then local users may be able to gain root access on your machine."
132 ewarn
133 fi
134 }
135
136 pkg_postrm() {
137 if use python; then
138 python_mod_cleanup ecryptfs-utils
139 fi
140 }

  ViewVC Help
Powered by ViewVC 1.1.20