From 0ee68898497c14ee1663e0596b184767ffb8cdfe Mon Sep 17 00:00:00 2001 From: Tim Harder Date: Tue, 25 Aug 2015 00:26:06 -0400 Subject: [PATCH] sys-fs/ecryptfs-utils: version bump --- sys-fs/ecryptfs-utils/Manifest | 1 + .../ecryptfs-utils/ecryptfs-utils-108.ebuild | 134 ++++++++++++++++++ 2 files changed, 135 insertions(+) create mode 100644 sys-fs/ecryptfs-utils/ecryptfs-utils-108.ebuild diff --git a/sys-fs/ecryptfs-utils/Manifest b/sys-fs/ecryptfs-utils/Manifest index 0b1233dde7e6..14d62307f8c1 100644 --- a/sys-fs/ecryptfs-utils/Manifest +++ b/sys-fs/ecryptfs-utils/Manifest @@ -1 +1,2 @@ DIST ecryptfs-utils_104.orig.tar.gz 649268 SHA256 4a200176542d46439c5297021f2c7fd7343b871c20c6f73f6e6c9fc4e5fd7438 SHA512 1d093df406c731e6a44bcfc647d5e84a4110fc8d55c8a6aee7e056b0cac8f826b16fbde3dcccd0cf64fcd981a7666b71b1697951ed614ad510c4a6e403f5efd8 WHIRLPOOL e483161d9268583dd596a62299e46c9e37d2e5ceb1f0e197115a9d4b489167abe40e3fd9ff4ed411f7b97543b26c0793411d815bdba9cef211dbe69f3c7bf54c +DIST ecryptfs-utils_108.orig.tar.gz 659465 SHA256 52838b1ad41113ba88a4318b19af10cf307100c6b3f62c608998d40312fbd7dd SHA512 856d8fac587921f1b5cd0b4ff269c7db8941b6b183506c5bc2e640a77994293f3e09ecfaef94f12c00f2378e756ecec252d3f59eebbabb4229105f8be87653ba WHIRLPOOL 0e6544df51204e0fe8b9e980cded34b49b3d4cc3ad45aa367b1806d93cfc5a0e337378fb008bee4afd0846520e00cc8ff51b3de69e00263d2338a120522b5ecb diff --git a/sys-fs/ecryptfs-utils/ecryptfs-utils-108.ebuild b/sys-fs/ecryptfs-utils/ecryptfs-utils-108.ebuild new file mode 100644 index 000000000000..87b301e435fc --- /dev/null +++ b/sys-fs/ecryptfs-utils/ecryptfs-utils-108.ebuild @@ -0,0 +1,134 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI="5" +PYTHON_DEPEND="python? 2:2.5" +SUPPORT_PYTHON_ABIS="1" +RESTRICT_PYTHON_ABIS="2.4 3.* *-jython 2.7-pypy-*" + +inherit flag-o-matic pam python linux-info autotools + +DESCRIPTION="eCryptfs userspace utilities" +HOMEPAGE="https://launchpad.net/ecryptfs" +SRC_URI="https://launchpad.net/ecryptfs/trunk/${PV}/+download/${PN}_${PV}.orig.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86" +IUSE="doc gpg gtk openssl pam pkcs11 python suid tpm" + +RDEPEND=">=sys-apps/keyutils-1.0 + >=dev-libs/libgcrypt-1.2.0:0 + dev-libs/nss + gpg? ( app-crypt/gpgme ) + gtk? ( x11-libs/gtk+:2 ) + openssl? ( >=dev-libs/openssl-0.9.7 ) + pam? ( sys-libs/pam ) + pkcs11? ( + >=dev-libs/openssl-0.9.7 + >=dev-libs/pkcs11-helper-1.04 + ) + tpm? ( app-crypt/trousers )" +DEPEND="${RDEPEND} + virtual/pkgconfig + sys-devel/gettext + >=dev-util/intltool-0.41.0 + python? ( dev-lang/swig )" + +pkg_setup() { + use python && python_pkg_setup + + CONFIG_CHECK="~ECRYPT_FS" + linux-info_pkg_setup +} + +src_prepare() { + echo "#!/bin/sh" > py-compile + + # Python bindings are built/installed manually. + sed -e "/SUBDIRS =/s/ libecryptfs-swig//" -i src/Makefile.am || die "sed failed" + + eautoreconf +} + +src_configure() { + append-cppflags -D_FILE_OFFSET_BITS=64 + + econf \ + --docdir="/usr/share/doc/${PF}" \ + --enable-nss \ + --with-pamdir=$(getpam_mod_dir) \ + $(use_enable doc docs) \ + $(use_enable gpg) \ + $(use_enable gtk gui) \ + $(use_enable openssl) \ + $(use_enable pam) \ + $(use_enable pkcs11 pkcs11-helper) \ + $(use_enable python pywrap) \ + $(use_enable tpm tspi) +} + +src_compile() { + default + + if use python; then + python_copy_sources src/libecryptfs-swig + building() { + emake \ + PYTHON="$(PYTHON)" \ + PYTHON_CPPFLAGS="-I$(python_get_includedir)" \ + PYTHON_LDFLAGS="-L$(python_get_libdir) $(python_get_library -l)" \ + PYTHON_SITE_PKG="$(python_get_sitedir)" \ + PYTHON_VERSION="$(python_get_version)" \ + SWIG_PYTHON_CPPFLAGS="-I$(python_get_includedir)" \ + pyexecdir="$(python_get_sitedir)" \ + pythondir="$(python_get_sitedir)" + } + python_execute_function -s --source-dir src/libecryptfs-swig building + fi +} + +src_install(){ + emake DESTDIR="${D}" install + + if use python; then + installation() { + emake \ + DESTDIR="${D}" \ + PYTHON="$(PYTHON)" \ + PYTHON_CPPFLAGS="-I$(python_get_includedir)" \ + PYTHON_LDFLAGS="-L$(python_get_libdir) $(python_get_library -l)" \ + PYTHON_SITE_PKG="$(python_get_sitedir)" \ + PYTHON_VERSION="$(python_get_version)" \ + SWIG_PYTHON_CPPFLAGS="-I$(python_get_includedir)" \ + pyexecdir="$(python_get_sitedir)" \ + pythondir="$(python_get_sitedir)" \ + install || return 1 + echo "ecryptfs-utils" > "${ED}$(python_get_sitedir)/ecryptfs-utils.pth" + } + python_execute_function -s --source-dir src/libecryptfs-swig installation + + python_clean_installation_image + fi + + use suid && fperms u+s /sbin/mount.ecryptfs_private + + find "${ED}" -name '*.la' -exec rm -f '{}' + +} + +pkg_postinst() { + use python && python_mod_optimize ecryptfs-utils + + if use suid; then + ewarn + ewarn "You have chosen to install ${PN} with the binary setuid root. This" + ewarn "means that if there are any undetected vulnerabilities in the binary," + ewarn "then local users may be able to gain root access on your machine." + ewarn + fi +} + +pkg_postrm() { + use python && python_mod_cleanup ecryptfs-utils +} -- 2.26.2