app-misc/pax-utils: arm64 stable (bug #725010)
[gentoo.git] / media-libs / speexdsp / speexdsp-1.2_rc3-r2.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5 inherit autotools flag-o-matic multilib-minimal
6
7 MY_P=${P/_}
8 MY_P=${MY_P/_p/.}
9
10 DESCRIPTION="Audio compression format designed for speech -- DSP"
11 HOMEPAGE="https://www.speex.org/"
12 SRC_URI="https://downloads.xiph.org/releases/speex/${MY_P}.tar.gz"
13
14 LICENSE="BSD"
15 SLOT="0"
16 KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~mips ppc ppc64 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris"
17 IUSE="cpu_flags_x86_sse cpu_flags_x86_sse2 cpu_flags_arm_neon static-libs"
18
19 RDEPEND="!<media-libs/speex-1.2.0"
20 DEPEND="${RDEPEND}
21         virtual/pkgconfig"
22
23 S=${WORKDIR}/${MY_P}
24
25 PATCHES=(
26         "${FILESDIR}/${P}-configure.patch"
27         "${FILESDIR}/${P}-config_types.h.patch"
28         "${FILESDIR}/${P}-overflow.patch"
29 )
30
31 src_prepare() {
32         default
33
34         sed -i \
35                 -e 's:noinst_PROGRAMS:check_PROGRAMS:' \
36                 libspeexdsp/Makefile.am || die
37
38         eautoreconf
39 }
40
41 multilib_src_configure() {
42         append-lfs-flags
43
44         # Can also be configured with one of:
45         # --enable-fixed-point             (no floating point)
46         # --with-fft=proprietary-intel-mkl (mkl)
47         # --with-fft=gpl-fftw3             (fftw)
48         ECONF_SOURCE="${S}" econf \
49                 $(use_enable static-libs static) \
50                 $(use_enable cpu_flags_x86_sse sse) \
51                 $(use_enable cpu_flags_x86_sse2 sse2) \
52                 $(use_enable cpu_flags_arm_neon neon)
53 }
54
55 multilib_src_install_all() {
56         default
57         find "${D}" -name '*.la' -delete || die
58 }