Gentoo Archives: gentoo-commits

From: "Tomas Chvatal (scarabeus)" <scarabeus@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in media-video/libav: libav-0.8.8.ebuild ChangeLog
Date: Sat, 02 Nov 2013 10:52:45
Message-Id: 20131102105237.BFD342004B@flycatcher.gentoo.org
1 scarabeus 13/11/02 10:52:37
2
3 Modified: ChangeLog
4 Added: libav-0.8.8.ebuild
5 Log:
6 Add libav 0.8.8 as it was forgotten to be bumped.
7
8 (Portage version: 2.2.7/cvs/Linux x86_64, signed Manifest commit with key 8EEE3BE8)
9
10 Revision Changes Path
11 1.170 media-video/libav/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-video/libav/ChangeLog?rev=1.170&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-video/libav/ChangeLog?rev=1.170&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-video/libav/ChangeLog?r1=1.169&r2=1.170
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/media-video/libav/ChangeLog,v
20 retrieving revision 1.169
21 retrieving revision 1.170
22 diff -u -r1.169 -r1.170
23 --- ChangeLog 16 Oct 2013 17:38:03 -0000 1.169
24 +++ ChangeLog 2 Nov 2013 10:52:37 -0000 1.170
25 @@ -1,6 +1,11 @@
26 # ChangeLog for media-video/libav
27 # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/media-video/libav/ChangeLog,v 1.169 2013/10/16 17:38:03 scarabeus Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/media-video/libav/ChangeLog,v 1.170 2013/11/02 10:52:37 scarabeus Exp $
30 +
31 +*libav-0.8.8 (02 Nov 2013)
32 +
33 + 02 Nov 2013; Tomáš Chvátal <scarabeus@g.o> +libav-0.8.8.ebuild:
34 + Add libav 0.8.8 as it was forgotten to be bumped.
35
36 *libav-9.10 (16 Oct 2013)
37
38
39
40
41 1.1 media-video/libav/libav-0.8.8.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-video/libav/libav-0.8.8.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-video/libav/libav-0.8.8.ebuild?rev=1.1&content-type=text/plain
45
46 Index: libav-0.8.8.ebuild
47 ===================================================================
48 # Copyright 1999-2013 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/media-video/libav/libav-0.8.8.ebuild,v 1.1 2013/11/02 10:52:37 scarabeus Exp $
51
52 EAPI=5
53
54 if [[ ${PV} == *9999 ]] ; then
55 SCM="git-2"
56 EGIT_REPO_URI="git://git.libav.org/libav.git"
57 [[ ${PV%9999} != "" ]] && EGIT_BRANCH="release/${PV%.9999}"
58 fi
59
60 inherit eutils flag-o-matic multilib toolchain-funcs ${SCM}
61
62 DESCRIPTION="Complete solution to record, convert and stream audio and video."
63 HOMEPAGE="http://libav.org/"
64 if [[ ${PV} == *9999 ]] ; then
65 SRC_URI=""
66 elif [[ ${PV%_p*} != ${PV} ]] ; then # Gentoo snapshot
67 SRC_URI="http://dev.gentoo.org/~lu_zero/libav/${P}.tar.xz"
68 else # Official release
69 SRC_URI="http://${PN}.org/releases/${P}.tar.xz"
70 fi
71
72 SRC_URI+=" test? ( http://dev.gentoo.org/~lu_zero/libav/fate-0.8.2.tar.xz )"
73
74 LICENSE="LGPL-2.1 gpl? ( GPL-3 )"
75 SLOT="0/0.8"
76 [[ ${PV} == *9999 ]] || \
77 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
78
79 IUSE="+3dnow +3dnowext aac alsa altivec amr bindist +bzip2 cdio cpudetection
80 custom-cflags debug dirac doc +encode faac truetype frei0r +gpl gsm
81 +hardcoded-tables ieee1394 jack jpeg2k +mmx +mmxext mp3 network openssl
82 oss pic pulseaudio +qt-faststart rtmp schroedinger sdl speex ssl +ssse3
83 static-libs test theora threads v4l vaapi vdpau vorbis vpx X x264 xvid
84 +zlib"
85
86 CPU_FEATURES="3dnow:amd3dnow 3dnowext:amd3dnowext altivec avx mmx mmxext:mmx2
87 neon ssse3 vis"
88
89 for i in ${CPU_FEATURES}; do
90 IUSE+=" ${i%:*}"
91 done
92
93 RDEPEND="
94 !media-video/ffmpeg
95 alsa? ( media-libs/alsa-lib )
96 amr? ( media-libs/opencore-amr )
97 bzip2? ( app-arch/bzip2 )
98 cdio? (
99 || (
100 dev-libs/libcdio-paranoia
101 <dev-libs/libcdio-0.90[-minimal]
102 )
103 )
104 dirac? ( media-video/dirac )
105 encode? (
106 aac? ( media-libs/vo-aacenc )
107 amr? ( media-libs/vo-amrwbenc )
108 faac? ( media-libs/faac )
109 mp3? ( >=media-sound/lame-3.98.3 )
110 theora? ( >=media-libs/libtheora-1.1.1[encode] media-libs/libogg )
111 vorbis? ( media-libs/libvorbis media-libs/libogg )
112 x264? ( >=media-libs/x264-0.0.20111017:= )
113 xvid? ( >=media-libs/xvid-1.1.0 )
114 )
115 truetype? ( media-libs/freetype:2 )
116 frei0r? ( media-plugins/frei0r-plugins )
117 gsm? ( >=media-sound/gsm-1.0.12-r1 )
118 ieee1394? ( media-libs/libdc1394 sys-libs/libraw1394 )
119 jack? ( media-sound/jack-audio-connection-kit )
120 jpeg2k? ( >=media-libs/openjpeg-1.3-r2:0 )
121 pulseaudio? ( media-sound/pulseaudio )
122 rtmp? ( >=media-video/rtmpdump-2.2f )
123 ssl? ( openssl? ( dev-libs/openssl )
124 !openssl? ( net-libs/gnutls ) )
125 sdl? ( >=media-libs/libsdl-1.2.13-r1[audio,video] )
126 schroedinger? ( media-libs/schroedinger )
127 speex? ( >=media-libs/speex-1.2_beta3 )
128 vaapi? ( x11-libs/libva )
129 vdpau? ( x11-libs/libvdpau )
130 vpx? ( >=media-libs/libvpx-0.9.6 )
131 X? ( x11-libs/libX11 x11-libs/libXext x11-libs/libXfixes )
132 zlib? ( sys-libs/zlib )
133 "
134
135 DEPEND="${RDEPEND}
136 >=sys-devel/make-3.81
137 dirac? ( virtual/pkgconfig )
138 doc? ( app-text/texi2html )
139 mmx? ( dev-lang/yasm )
140 rtmp? ( virtual/pkgconfig )
141 schroedinger? ( virtual/pkgconfig )
142 truetype? ( virtual/pkgconfig )
143 test? ( net-misc/wget )
144 v4l? ( sys-kernel/linux-headers )
145 "
146
147 # faac can't be binary distributed
148 # openssl support marked as nonfree
149 # faac and aac are concurent implementations
150 # amr and aac require at least lgpl3
151 # x264 requires gpl2
152 REQUIRED_USE="bindist? ( !faac !openssl )
153 rtmp? ( network )
154 amr? ( gpl ) aac? ( gpl ) x264? ( gpl ) X? ( gpl ) cdio? ( gpl )
155 test? ( encode )"
156
157 src_prepare() {
158 # if we have snapshot then we need to hardcode the version
159 if [[ ${PV%_p*} != ${PV} ]]; then
160 sed -i -e "s/UNKNOWN/DATE-${PV#*_pre}/" "${S}/version.sh" || die
161 fi
162 epatch "${FILESDIR}/${PN}-0.8.5-support-libcdio-paranoia.patch"
163 }
164
165 src_configure() {
166 local myconf="${EXTRA_LIBAV_CONF}"
167 local uses i
168
169 myconf+="
170 $(use_enable gpl)
171 $(use_enable gpl version3)
172 --enable-avfilter
173 "
174
175 # enabled by default
176 uses="debug doc network zlib"
177 for i in ${uses}; do
178 use ${i} || myconf+=" --disable-${i}"
179 done
180 use bzip2 || myconf+=" --disable-bzlib"
181 use sdl || myconf+=" --disable-avplay"
182
183 if use ssl; then
184 use openssl && myconf+=" --enable-openssl --enable-nonfree" \
185 || myconf+=" --enable-gnutls"
186 fi
187
188 use custom-cflags && myconf+=" --disable-optimizations"
189 use cpudetection && myconf+=" --enable-runtime-cpudetect"
190
191 #for i in h264_vdpau mpeg1_vdpau mpeg_vdpau vc1_vdpau wmv3_vdpau; do
192 # use video_cards_nvidia || myconf="${myconf} --disable-decoder=${i}"
193 # use vdpau || myconf="${myconf} --disable-decoder=${i}"
194 #done
195 use vdpau || myconf+=" --disable-vdpau"
196
197 use vaapi && myconf+=" --enable-vaapi"
198
199 # Encoders
200 if use encode; then
201 use mp3 && myconf+=" --enable-libmp3lame"
202 use amr && myconf+=" --enable-libvo-amrwbenc"
203 use faac && myconf+=" --enable-libfaac --enable-nonfree"
204 use aac && myconf+=" --enable-libvo-aacenc"
205 uses="theora vorbis x264 xvid"
206 for i in ${uses}; do
207 use ${i} && myconf+=" --enable-lib${i}"
208 done
209 else
210 myconf+=" --disable-encoders"
211 fi
212
213 # libavdevice options
214 use cdio && myconf+=" --enable-libcdio"
215 use ieee1394 && myconf+=" --enable-libdc1394"
216 use pulseaudio && myconf+=" --enable-libpulse"
217 # Indevs
218 # v4l1 is gone since linux-headers-2.6.38
219 myconf+=" --disable-indev=v4l"
220 use v4l || myconf+=" --disable-indev=v4l2"
221 for i in alsa oss jack; do
222 use ${i} || myconf+=" --disable-indev=${i}"
223 done
224 use X && myconf+=" --enable-x11grab"
225 # Outdevs
226 for i in alsa oss ; do
227 use ${i} || myconf+=" --disable-outdev=${i}"
228 done
229 # libavfilter options
230 use frei0r && myconf+=" --enable-frei0r"
231 use truetype && myconf+=" --enable-libfreetype"
232
233 # Threads; we only support pthread for now but ffmpeg supports more
234 use threads && myconf+=" --enable-pthreads"
235
236 # Decoders
237 use amr && myconf+=" --enable-libopencore-amrwb --enable-libopencore-amrnb"
238 uses="gsm dirac rtmp schroedinger speex vpx"
239 for i in ${uses}; do
240 use ${i} && myconf+=" --enable-lib${i}"
241 done
242 use jpeg2k && myconf+=" --enable-libopenjpeg"
243
244 # CPU features
245 for i in ${CPU_FEATURES}; do
246 use ${i%:*} || myconf+=" --disable-${i#*:}"
247 done
248
249 # pass the right -mfpu as extra
250 use neon && myconf+=" --extra-cflags=-mfpu=neon"
251
252 # disable mmx accelerated code if PIC is required
253 # as the provided asm decidedly is not PIC for x86.
254 if use pic && use x86 ; then
255 myconf+=" --disable-mmx --disable-mmx2"
256 fi
257
258 # Option to force building pic
259 use pic && myconf+=" --enable-pic"
260
261 # Try to get cpu type based on CFLAGS.
262 # Bug #172723
263 # We need to do this so that features of that CPU will be better used
264 # If they contain an unknown CPU it will not hurt since ffmpeg's configure
265 # will just ignore it.
266 for i in $(get-flag march) $(get-flag mcpu) $(get-flag mtune) ; do
267 [ "${i}" = "native" ] && i="host" # bug #273421
268 [[ ${i} = *-sse3 ]] && i="${i%-sse3}" # bug 283968
269 myconf+=" --cpu=${i}"
270 break
271 done
272
273 # cross compile support
274 if tc-is-cross-compiler ; then
275 myconf+=" --enable-cross-compile --arch=$(tc-arch-kernel) --cross-prefix=${CHOST}-"
276 case ${CHOST} in
277 *freebsd*)
278 myconf+=" --target-os=freebsd"
279 ;;
280 mingw32*)
281 myconf+=" --target-os=mingw32"
282 ;;
283 *linux*)
284 myconf+=" --target-os=linux"
285 ;;
286 esac
287 fi
288
289 # Misc stuff
290 use hardcoded-tables && myconf+=" --enable-hardcoded-tables"
291
292 # Specific workarounds for too-few-registers arch...
293 if [[ $(tc-arch) == "x86" ]]; then
294 filter-flags -fforce-addr -momit-leaf-frame-pointer
295 append-flags -fomit-frame-pointer
296 is-flag -O? || append-flags -O2
297 if use debug; then
298 # no need to warn about debug if not using debug flag
299 ewarn ""
300 ewarn "Debug information will be almost useless as the frame pointer is omitted."
301 ewarn "This makes debugging harder, so crashes that has no fixed behavior are"
302 ewarn "difficult to fix. Please have that in mind."
303 ewarn ""
304 fi
305 fi
306
307 cd "${S}"
308 ./configure \
309 --prefix="${EPREFIX}"/usr \
310 --libdir="${EPREFIX}"/usr/$(get_libdir) \
311 --shlibdir="${EPREFIX}"/usr/$(get_libdir) \
312 --mandir="${EPREFIX}"/usr/share/man \
313 --enable-shared \
314 --cc="$(tc-getCC)" \
315 --ar="$(tc-getAR)" \
316 $(use_enable static-libs static) \
317 ${myconf} || die
318
319 MAKEOPTS+=" V=1"
320 }
321
322 src_compile() {
323 emake
324
325 if use qt-faststart; then
326 tc-export CC
327 emake tools/qt-faststart
328 fi
329 }
330
331 src_install() {
332 emake DESTDIR="${D}" install install-man
333
334 dodoc Changelog README INSTALL doc/*.txt
335 use doc && dodoc doc/*.html
336
337 use qt-faststart && dobin tools/qt-faststart
338
339 for i in $(usex sdl avplay "") $(usex network avserver "") avprobe; do
340 dosym ${i} /usr/bin/${i/av/ff}
341 done
342 }
343
344 pkg_postinst() {
345 elog "Please note that the programs formerly known as ffplay, ffserver"
346 elog "and ffprobe are now called avplay, avserver and avprobe."
347 elog
348 elog "ffmpeg had been replaced by the feature incompatible avconv thus"
349 elog "the legacy ffmpeg is provided for compatibility with older scripts"
350 elog "but will be removed in the next version"
351 }
352
353 src_test() {
354 LD_LIBRARY_PATH="${S}/libavcore:${S}/libswscale:${S}/libavcodec:${S}/libavdevice:${S}/libavfilter:${S}/libavformat:${S}/libavutil" \
355 emake fate SAMPLES="${WORKDIR}/fate"
356 }