dev-libs/*: Update Manifest hashes
[gentoo.git] / dev-libs / ffcall / ffcall-1.13.ebuild
1 # Copyright 1999-2017 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5
6 inherit eutils flag-o-matic toolchain-funcs
7
8 MY_PV="libffcall-${PV}"
9
10 DESCRIPTION="foreign function call libraries"
11 HOMEPAGE="https://www.gnu.org/software/libffcall/"
12 SRC_URI="mirror://gnu/libffcall/${MY_PV}.tar.gz"
13
14 # "Ffcall is under GNU GPL. As a special exception, if used in GNUstep
15 # or in derivate works of GNUstep, the included parts of ffcall are
16 # under GNU LGPL." -ffcall author
17 LICENSE="GPL-2+"
18 SLOT="0"
19 KEYWORDS="~alpha ~amd64 ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris ~x86-solaris"
20 IUSE=""
21
22 S=${WORKDIR}/${MY_PV}
23
24 DEPEND=""
25 RDEPEND=""
26
27 src_prepare() {
28         epatch "${FILESDIR}"/${PN}-make-jN.patch
29
30         # The build system is a strange mix of autogenerated
31         # files and manual tweaks on top. Uses $CFLAGS / $LDFLAGS randomly.
32         # We are adding them consistently here and a bit over the top:
33         # bugs: #334581
34
35         for mfi in {,*/,*/*/,}Makefile.in
36         do
37                 elog "Patching '${mfi}'"
38                 # usually uses only assembler here, but -march=
39                 # and -Wa, are a must to pass here.
40                 sed -e 's/$(CC) /&$(CFLAGS) /g' \
41                         -i "${mfi}" || die
42         done
43         eapply_user
44 }
45
46 src_configure() {
47         append-flags -fPIC
48
49         # Doc goes in datadir
50         econf \
51                 --datadir="${EPREFIX}"/usr/share/doc/${PF} \
52                 --enable-shared \
53                 --disable-static
54 }
55
56 src_install() {
57         dodoc NEWS README
58         dodir /usr/share/man
59         default
60         prune_libtool_files
61 }