blob: 8e616b32c136f446add1f15b0c2a6a36c8a8467c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
|
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-libs/libextractor/libextractor-1.3.ebuild,v 1.4 2014/07/14 14:52:01 ssuominen Exp $
EAPI=5
inherit eutils flag-o-matic multilib toolchain-funcs
DESCRIPTION="A library used to extract metadata from files of arbitrary type"
HOMEPAGE="http://www.gnu.org/software/libextractor/"
SRC_URI="mirror://gnu/${PN}/${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86"
IUSE="+archive +bzip2 ffmpeg flac gif gsf gtk jpeg mp4 +magic midi mpeg tidy tiff vorbis +zlib" # test
RESTRICT="test"
RDEPEND="app-text/iso-codes
>=dev-libs/glib-2
media-gfx/exiv2
sys-devel/libtool
virtual/libiconv
virtual/libintl
archive? ( app-arch/libarchive )
bzip2? ( app-arch/bzip2 )
ffmpeg? ( virtual/ffmpeg )
flac? (
media-libs/flac
media-libs/libogg
)
gif? ( media-libs/giflib )
gsf? ( gnome-extra/libgsf )
gtk? ( x11-libs/gtk+:3 )
jpeg? ( virtual/jpeg )
mp4? ( media-libs/libmp4v2:0 )
magic? ( sys-apps/file )
midi? ( media-libs/libsmf )
mpeg? ( media-libs/libmpeg2 )
tidy? ( app-text/htmltidy )
tiff? ( media-libs/tiff:0 )
vorbis? (
media-libs/libogg
media-libs/libvorbis
)
zlib? ( sys-libs/zlib )
!<app-crypt/pkcrack-1.2.2-r1
!sci-biology/glimmer
!sci-chemistry/pdb-extract"
DEPEND="${RDEPEND}
sys-devel/gettext
virtual/pkgconfig"
# test? ( app-forensics/zzuf )
DOCS="AUTHORS ChangeLog NEWS README TODO"
src_prepare() {
# m4/ax_create_pkgconfig_info.m4 is passing environment LDFLAGS to Libs:
sed -i \
-e '/^ax_create_pkgconfig_ldflags=/s:$LDFLAGS ::' \
-e 's:tidy/tidy.h:tidy.h:' \
configure src/plugins/html_extractor.c || die
use tidy || { sed -i -e 's:tidy.h:dIsAbLe&:' configure || die; }
}
src_configure() {
e_ac_cv() {
export ac_cv_"$@"
}
e_ac_cv {lib_rpm_rpmReadPackageFile,prog_HAVE_ZZUF}=no
if use flac; then
e_ac_cv header_FLAC_all_h=yes
e_ac_cv lib_FLAC_FLAC__stream_decoder_init_stream=yes
else
e_ac_cv header_FLAC_all_h=no
e_ac_cv lib_FLAC_FLAC__stream_decoder_init_stream=no
e_ac_cv lib_FLAC_FLAC__stream_decoder_init_ogg_stream=no
fi
e_ac_cv header_archive_h=$(usex archive)
e_ac_cv header_bzlib_h=$(usex bzip2)
e_ac_cv header_gif_lib_h=$(usex gif)
e_ac_cv header_jpeglib_h=$(usex jpeg)
e_ac_cv header_magic_h=$(usex magic)
e_ac_cv header_mpeg2dec_mpeg2_h=$(usex mpeg)
e_ac_cv header_tiffio_h=$(usex tiff)
e_ac_cv header_vorbis_vorbisfile_h=$(usex vorbis)
e_ac_cv header_zlib_h=$(usex zlib)
e_ac_cv lib_mp4v2_MP4ReadProvider=$(usex mp4)
e_ac_cv lib_smf_smf_load_from_memory=$(usex midi)
# gstreamer support is for 1.0, no 0.10 support
econf \
--disable-static \
--enable-experimental \
--enable-glib \
$(use_enable gsf) \
--disable-gsf-gnome \
$(use_enable ffmpeg) \
--with-gtk_version=$(usex gtk 3.0.0 false) \
--without-gstreamer
}
src_compile() {
emake -j1
}
src_install() {
default
find "${ED}" -name '*.la' -exec sed -i -e "/^dependency_libs/s:=.*:='':" {} +
}
|