summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wendler <polynomial-c@gentoo.org>2017-09-02 22:31:14 +0200
committerLars Wendler <polynomial-c@gentoo.org>2017-09-02 22:35:53 +0200
commitb7aa3f39473224c01db14ff6ed623ec2ca7bf93c (patch)
tree409123bc26f6782e6f4955ea61d752046f78e183 /sys-apps/file
parentsys-apps/file: Bump to version 5.32 (diff)
downloadgentoo-b7aa3f39473224c01db14ff6ed623ec2ca7bf93c.tar.gz
gentoo-b7aa3f39473224c01db14ff6ed623ec2ca7bf93c.tar.bz2
gentoo-b7aa3f39473224c01db14ff6ed623ec2ca7bf93c.zip
sys-apps/file: Sync live ebuild.
Package-Manager: Portage-2.3.8, Repoman-2.3.3
Diffstat (limited to 'sys-apps/file')
-rw-r--r--sys-apps/file/file-9999.ebuild37
1 files changed, 23 insertions, 14 deletions
diff --git a/sys-apps/file/file-9999.ebuild b/sys-apps/file/file-9999.ebuild
index 05427c55cb7b..4f3a87f8bf98 100644
--- a/sys-apps/file/file-9999.ebuild
+++ b/sys-apps/file/file-9999.ebuild
@@ -1,19 +1,19 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-EAPI="5"
+EAPI=6
PYTHON_COMPAT=( python2_7 python3_{4,5,6} pypy )
DISTUTILS_OPTIONAL=1
-inherit eutils distutils-r1 libtool toolchain-funcs multilib-minimal
+inherit distutils-r1 libtool ltprune toolchain-funcs multilib-minimal
if [[ ${PV} == "9999" ]] ; then
EGIT_REPO_URI="https://github.com/glensc/file.git"
inherit autotools git-r3
else
SRC_URI="ftp://ftp.astron.com/pub/file/${P}.tar.gz"
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
DESCRIPTION="identify a file's format by scanning binary data for patterns"
@@ -34,19 +34,22 @@ RDEPEND="${DEPEND}
python? ( !dev-python/python-magic )"
src_prepare() {
+ default
+
[[ ${PV} == "9999" ]] && eautoreconf
elibtoolize
# don't let python README kill main README #60043
- mv python/README{,.python}
+ mv python/README{,.python} || die
}
multilib_src_configure() {
- ECONF_SOURCE=${S} \
- econf \
- --enable-fsect-man5 \
- $(use_enable static-libs static) \
+ local myeconfargs=(
+ --enable-fsect-man5
+ $(use_enable static-libs static)
$(use_enable zlib)
+ )
+ ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
}
src_configure() {
@@ -54,8 +57,8 @@ src_configure() {
# because people often don't keep matching host/target
# file versions #362941
if tc-is-cross-compiler && ! ROOT=/ has_version ~${CATEGORY}/${P} ; then
- mkdir -p "${WORKDIR}"/build
- cd "${WORKDIR}"/build
+ mkdir -p "${WORKDIR}"/build || die
+ cd "${WORKDIR}"/build || die
tc-export_build_env BUILD_C{C,XX}
ECONF_SOURCE=${S} \
ac_cv_header_zlib_h=no \
@@ -77,7 +80,7 @@ multilib_src_compile() {
if multilib_is_native_abi ; then
emake
else
- cd src
+ cd src || die
emake magic.h #586444
emake libmagic.la
fi
@@ -91,20 +94,26 @@ src_compile() {
fi
multilib-minimal_src_compile
- use python && cd python && distutils-r1_src_compile
+ if use python ; then
+ cd python || die
+ distutils-r1_src_compile
+ fi
}
multilib_src_install() {
if multilib_is_native_abi ; then
default
else
- emake -C src install-{includeHEADERS,libLTLIBRARIES} DESTDIR="${D}"
+ emake -C src install-{nodist_includeHEADERS,libLTLIBRARIES} DESTDIR="${D}"
fi
}
multilib_src_install_all() {
dodoc ChangeLog MAINT README
- use python && cd python && distutils-r1_src_install
+ if use python ; then
+ cd python || die
+ distutils-r1_src_install
+ fi
prune_libtool_files
}