Contents of /branches/magellan-next/core/x264/x264-20110712_2245-r1.smage2
Parent Directory | Revision Log
Revision 8196 -
(show annotations)
(download)
Wed Jul 13 07:01:54 2011 UTC (12 years, 10 months ago) by niro
File size: 1737 byte(s)
Wed Jul 13 07:01:54 2011 UTC (12 years, 10 months ago) by niro
File size: 1737 byte(s)
auto added: ver bump to 20110712_2245-r1
1 | # $Id$ |
2 | |
3 | PNAME="x264" |
4 | PVER="20110712_2245" |
5 | PBUILD="r1" |
6 | |
7 | PCATEGORIE="media-libs" |
8 | |
9 | DESCRIPTION="x264 is a free AVC/H.264 video encoder library." |
10 | HOMEPAGE="http://developers.videolan.org/x264.html" |
11 | |
12 | DEPEND=">= virtual/glibc" |
13 | |
14 | # i*86 needs nasm |
15 | SDEPENDS_x86=">= dev-lang/nasm-2" |
16 | |
17 | # x86_64 needs yasm |
18 | SDEPENDS_x86_64=">= dev-lang/yasm-0.7" |
19 | |
20 | # very dirty trick to get the dependencies right |
21 | # ';' is the IFS, tr replaces ';' with an crlfs |
22 | # the var is finally decided via our common eval+echo magic |
23 | SDEPEND="\$(eval echo \\\$SDEPENDS_\${ARCH/i*86/x86} | tr ';' '\n')" |
24 | |
25 | # these vars must be exported to the mage file to get all things right |
26 | SPECIAL_VARS="SDEPENDS_x86_64 SDEPENDS_x86" |
27 | |
28 | SRCFILE="${PNAME}-snapshot-${PVER/_/-}.tar.bz2" |
29 | SRCDIR="${BUILDDIR}/${PNAME}-snapshot-${PVER/_/-}" |
30 | |
31 | sminclude mbuild |
32 | |
33 | SRC_URI=( |
34 | ftp://ftp.videolan.org/pub/videolan/${PNAME}/snapshots/${SRCFILE} |
35 | mirror://${PNAME}/${SRCFILE} |
36 | mirror://${PNAME}/${PNAME}-20100905_2245-only-libs.patch |
37 | ) |
38 | |
39 | # do not autoupdate this package as it has daily snapshots |
40 | UP2DATE="echo ${PVER}" |
41 | |
42 | # note: we build a seperate lib and util package to prevent depwalker loops |
43 | # when resolving packages: |
44 | # gpac needs ffmpeg, ffmpeg needs x264, but x264 needs gpac to compile |
45 | |
46 | src_prepare() |
47 | { |
48 | munpack ${SRCFILE} || die |
49 | cd ${SRCDIR} |
50 | |
51 | # fix the makefile to only build and install the lib |
52 | mpatch ${PNAME}-20100905_2245-only-libs.patch || die |
53 | } |
54 | |
55 | src_compile() |
56 | { |
57 | cd ${SRCDIR} |
58 | mconfigure \ |
59 | --enable-pic \ |
60 | --enable-shared \ |
61 | --enable-pthread \ |
62 | --disable-mp4-output \ |
63 | || die |
64 | mmake || die |
65 | } |
66 | |
67 | postinstall() |
68 | { |
69 | echo |
70 | echo "Please note that this package only installs the" |
71 | echo "x264 libraries. In order to have the encoder," |
72 | echo "please install 'media-video/x264-encoder'." |
73 | echo |
74 | } |