/[gentoo-x86]/media-video/x264-encoder/x264-encoder-9999.ebuild
Gentoo

Contents of /media-video/x264-encoder/x264-encoder-9999.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.8 - (show annotations) (download)
Sun Mar 9 10:19:46 2014 UTC (4 years, 5 months ago) by aballier
Branch: MAIN
CVS Tags: HEAD
Changes since 1.7: +3 -2 lines
disable lsmash to avoid automagic for now

(Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key 160F534A)

1 # Copyright 1999-2014 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/media-video/x264-encoder/x264-encoder-9999.ebuild,v 1.7 2013/06/26 04:40:11 chutzpah Exp $
4
5 EAPI=5
6
7 inherit flag-o-matic multilib toolchain-funcs
8
9 DESCRIPTION="A free commandline encoder for X264/AVC streams"
10 HOMEPAGE="http://www.videolan.org/developers/x264.html"
11 if [[ ${PV} == 9999 ]]; then
12 inherit git-2
13 EGIT_REPO_URI="git://git.videolan.org/x264.git"
14 SRC_URI=""
15 else
16 inherit versionator
17 MY_P="x264-snapshot-$(get_version_component_range 3)-2245"
18 SRC_URI="http://download.videolan.org/pub/videolan/x264/snapshots/${MY_P}.tar.bz2"
19 KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
20 S="${WORKDIR}/${MY_P}"
21 fi
22
23 LICENSE="GPL-2"
24 SLOT="0"
25 IUSE="10bit avs custom-cflags ffmpeg ffmpegsource +interlaced mp4 +threads"
26
27 REQUIRED_USE="ffmpegsource? ( ffmpeg )"
28
29 RDEPEND="ffmpeg? ( virtual/ffmpeg )
30 ~media-libs/x264-${PV}[10bit=,interlaced=,threads=]
31 ffmpegsource? ( media-libs/ffmpegsource )
32 mp4? ( >=media-video/gpac-0.4.1_pre20060122 )"
33
34 ASM_DEP=">=dev-lang/yasm-1.2.0"
35 DEPEND="${RDEPEND}
36 amd64? ( ${ASM_DEP} )
37 x86? ( ${ASM_DEP} )
38 x86-fbsd? ( ${ASM_DEP} )
39 virtual/pkgconfig"
40
41 src_configure() {
42 tc-export CC
43
44 # let upstream pick the optimization level by default
45 use custom-cflags || filter-flags -O?
46
47 ./configure \
48 --prefix="${EPREFIX}"/usr \
49 --libdir="${EPREFIX}"/usr/$(get_libdir) \
50 --system-libx264 \
51 --host="${CHOST}" \
52 --disable-lsmash \
53 $(usex 10bit "--bit-depth=10" "") \
54 $(usex avs "" "--disable-avs") \
55 $(usex ffmpeg "" "--disable-lavf --disable-swscale") \
56 $(usex ffmpegsource "" "--disable-ffms") \
57 $(usex interlaced "" "--disable-interlaced") \
58 $(usex mp4 "" "--disable-gpac") \
59 $(usex threads "" "--disable-thread") || die
60
61 # this is a nasty workaround for bug #376925 for x264 that also applies
62 # here, needed because as upstream doesn't like us fiddling with their CFLAGS
63 if use custom-cflags; then
64 local cflags
65 cflags="$(grep "^CFLAGS=" config.mak | sed 's/CFLAGS=//')"
66 cflags="${cflags//$(get-flag O)/}"
67 cflags="${cflags//-O? /$(get-flag O) }"
68 cflags="${cflags//-g /}"
69 sed -i "s:^CFLAGS=.*:CFLAGS=${cflags//:/\\:}:" config.mak
70 fi
71 }

  ViewVC Help
Powered by ViewVC 1.1.20