Annotation of /branches/magellan-next/extras/gpac/gpac-0.4.5-r2.smage2
Parent Directory | Revision Log
Revision 8291 -
(hide annotations)
(download)
Thu Jul 14 11:55:27 2011 UTC (12 years, 10 months ago) by niro
File size: 3331 byte(s)
Thu Jul 14 11:55:27 2011 UTC (12 years, 10 months ago) by niro
File size: 3331 byte(s)
-added patch to fix build against libpng-1.5
1 | niro | 8290 | # $Id$ |
2 | |||
3 | PNAME="gpac" | ||
4 | PVER="0.4.5" | ||
5 | PBUILD="r2" | ||
6 | |||
7 | PCATEGORIE="media-video" | ||
8 | |||
9 | DESCRIPTION="GPAC is a multimedia framework based on the MPEG-4 Systems standard (ISO/IEC 14496-1) developed from scratch in ANSI C." | ||
10 | HOMEPAGE="http://gpac.sourceforge.net/" | ||
11 | |||
12 | DEPEND=">= virtual/opengl | ||
13 | >= x11-libs/libXt-1 | ||
14 | >= x11-libs/libX11-1.4 | ||
15 | >= x11-libs/libXext-1.3 | ||
16 | >= dev-libs/libxml2-2.7 | ||
17 | >= media-libs/libsdl-1.2 | ||
18 | >= x11-libs/wxgtk-2.8.12 | ||
19 | >= media-libs/libjpeg-8 | ||
20 | >= media-libs/libpng-1.5 | ||
21 | >= media-libs/freetype-2.4 | ||
22 | >= media-libs/libfaad2-2.7 | ||
23 | >= media-video/ffmpeg-201107 | ||
24 | >= media-libs/libmad-0.15 | ||
25 | >= media-libs/libogg-1.2 | ||
26 | >= media-libs/libvorbis-1.3 | ||
27 | >= media-libs/xvid-1.3 | ||
28 | >= media-sound/pulseaudio-0.9" | ||
29 | |||
30 | SRCFILE="${PNAME}-${PVER}.tar.gz" | ||
31 | SRCDIR="${BUILDDIR}/${PNAME}" | ||
32 | |||
33 | SRC_URI=( | ||
34 | sourceforge://${PNAME}/${SRCFILE} | ||
35 | mirror://${PNAME}/${SRCFILE} | ||
36 | mirror://${PNAME}/${PNAME}-${PVER}-pic.patch | ||
37 | mirror://${PNAME}/${PNAME}-${PVER}-ffmpeg-headers.patch | ||
38 | mirror://${PNAME}/${PNAME}-${PVER}-ffmpeg-link.patch | ||
39 | mirror://${PNAME}/${PNAME}-${PVER}-ffmpeg-snapshots-compat.patch | ||
40 | mirror://${PNAME}/${PNAME}-${PVER}-implicitdecls.patch | ||
41 | mirror://${PNAME}/${PNAME}-${PVER}-pulseaudio-configable.patch | ||
42 | mirror://${PNAME}/${PNAME}-${PVER}-swscalecall.patch | ||
43 | mirror://${PNAME}/${PNAME}-${PVER}-x11-link.patch | ||
44 | niro | 8291 | mirror://${PNAME}/${PNAME}-${PVER}-libpng15.patch |
45 | niro | 8290 | ) |
46 | |||
47 | UP2DATE="updatecmd_sourceforge ${PNAME}" | ||
48 | |||
49 | src_prepare() | ||
50 | { | ||
51 | munpack ${SRCFILE} || die | ||
52 | cd ${SRCDIR} | ||
53 | |||
54 | # apply some gentoo patches | ||
55 | mpatch ${PNAME}-${PVER}-pic.patch || die | ||
56 | mpatch ${PNAME}-${PVER}-ffmpeg-headers.patch || die | ||
57 | mpatch ${PNAME}-${PVER}-ffmpeg-link.patch || die | ||
58 | mpatch ${PNAME}-${PVER}-ffmpeg-snapshots-compat.patch || die | ||
59 | mpatch ${PNAME}-${PVER}-implicitdecls.patch || die | ||
60 | mpatch ${PNAME}-${PVER}-pulseaudio-configable.patch || die | ||
61 | mpatch ${PNAME}-${PVER}-swscalecall.patch || die | ||
62 | mpatch ${PNAME}-${PVER}-x11-link.patch || die | ||
63 | niro | 8291 | # fix build against libpng-1.5 |
64 | mpatch ${PNAME}-${PVER}-libpng15.patch || die | ||
65 | niro | 8290 | |
66 | sed -i '/ldconfig / d' Makefile || die | ||
67 | |||
68 | # configure is not executable | ||
69 | chmod +x configure || die | ||
70 | |||
71 | # make sure mozilla won't be used | ||
72 | sed -i 's/osmozilla//g' applications/Makefile || die | ||
73 | |||
74 | # multilib libdir fix | ||
75 | sed -i 's:$(prefix)/lib:$(prefix)/'$(mlibdir)':' Makefile src/Makefile || die | ||
76 | sed -i 's:/lib/gpac:/'$(mlibdir)'/gpac:' configure || die | ||
77 | } | ||
78 | |||
79 | src_compile() | ||
80 | { | ||
81 | cd ${SRCDIR} | ||
82 | |||
83 | # remove the warnings noise | ||
84 | export CFLAGS="${CFLAGS} -fno-strict-aliasing" | ||
85 | export CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing" | ||
86 | |||
87 | # amd64 compile | ||
88 | if [[ ${ARCH} = x86_64 ]] | ||
89 | then | ||
90 | export CFLAGS="${CFLAGS} -fPIC" | ||
91 | export CXXFLAGS="${CXXFLAGS} -fPIC" | ||
92 | fi | ||
93 | |||
94 | mconfigure \ | ||
95 | --enable-pic \ | ||
96 | --enable-svg \ | ||
97 | --enable-opengl \ | ||
98 | --enable-ssl \ | ||
99 | --disable-amr \ | ||
100 | --disable-debug \ | ||
101 | --disable-oss-audio \ | ||
102 | --disable-jack=yes \ | ||
103 | --enable-pulseaudio=yes \ | ||
104 | --use-jpeg=system \ | ||
105 | --use-png=system \ | ||
106 | --use-ft=no \ | ||
107 | --use-ogg=system \ | ||
108 | --use-vorbis=system \ | ||
109 | --use-ffmpeg=system \ | ||
110 | --use-faad=system \ | ||
111 | --use-mad=system \ | ||
112 | --use-xvid=system \ | ||
113 | --use-js=no \ | ||
114 | || die | ||
115 | |||
116 | mmake -j1 OPTFLAGS="${CFLAGS}" || die | ||
117 | } | ||
118 | |||
119 | src_install() | ||
120 | { | ||
121 | cd ${SRCDIR} | ||
122 | |||
123 | mmake STRIP="true" OPTFLAGS="${CFLAGS}" DESTDIR="${BINDIR}" install || die | ||
124 | mmake STRIP="true" OPTFLAGS="${CFLAGS}" DESTDIR="${BINDIR}" install-lib || die | ||
125 | minstalldocs AUTHORS BUGS Changelog README TODO doc/*.html doc/*.txt || die | ||
126 | } |