Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(584)

Side by Side Diff: media-libs/mesa/mesa-7.9.ebuild

Issue 5925002: Switch to Mesa 7.9. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/chromiumos-overlay.git@master
Patch Set: Switch to Mesa 7.9 version 2. Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « media-libs/mesa/files/eselect-mesa.conf.7.9 ('k') | media-libs/mesa/mesa-7.9-r1.ebuild » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 1999-2010 Gentoo Foundation 1 # Copyright 1999-2010 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2 2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/mesa-7.9.ebuild,v 1.3 2010/12 /05 17:19:14 arfrever Exp $ 3 # $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/mesa-7.9.ebuild,v 1.3 2010/12 /05 17:19:14 arfrever Exp $
4 4
5 EAPI=3 5 EAPI=3
6 6
7 EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa" 7 EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa"
8 8
9 if [[ ${PV} = 9999* ]]; then 9 if [[ ${PV} = 9999* ]]; then
10 GIT_ECLASS="git" 10 GIT_ECLASS="git"
(...skipping 17 matching lines...) Expand all
28 #SRC_PATCHES="mirror://gentoo/${P}-gentoo-patches-01.tar.bz2" 28 #SRC_PATCHES="mirror://gentoo/${P}-gentoo-patches-01.tar.bz2"
29 if [[ $PV = 9999* ]]; then 29 if [[ $PV = 9999* ]]; then
30 SRC_URI="${SRC_PATCHES}" 30 SRC_URI="${SRC_PATCHES}"
31 else 31 else
32 SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_SRC_P}.tar.bz 2 32 SRC_URI="ftp://ftp.freedesktop.org/pub/mesa/${FOLDER}/${MY_SRC_P}.tar.bz 2
33 ${SRC_PATCHES}" 33 ${SRC_PATCHES}"
34 fi 34 fi
35 35
36 LICENSE="LGPL-2 kilgard" 36 LICENSE="LGPL-2 kilgard"
37 SLOT="0" 37 SLOT="0"
38 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86- fbsd" 38 KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc x86 ~x86-fb sd"
39 39
40 INTEL_CARDS="intel" 40 INTEL_CARDS="intel"
41 RADEON_CARDS="radeon" 41 RADEON_CARDS="radeon"
42 VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} mach64 mga nouveau r128 savage sis v mware tdfx via" 42 VIDEO_CARDS="${INTEL_CARDS} ${RADEON_CARDS} mach64 mga nouveau r128 savage sis v mware tdfx via"
43 for card in ${VIDEO_CARDS}; do 43 for card in ${VIDEO_CARDS}; do
44 IUSE_VIDEO_CARDS+=" video_cards_${card}" 44 IUSE_VIDEO_CARDS+=" video_cards_${card}"
45 done 45 done
46 46
47 IUSE="${IUSE_VIDEO_CARDS} 47 IUSE="${IUSE_VIDEO_CARDS}
48 +classic debug +gallium gles llvm motif +nptl pic selinux kernel_FreeBSD " 48 +classic debug +gallium gles llvm motif +nptl pic selinux kernel_FreeBSD "
49 49
50 LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.21" 50 LIBDRM_DEPSTRING=">=x11-libs/libdrm-2.4.21"
51 # keep correct libdrm and dri2proto dep 51 # keep correct libdrm and dri2proto dep
52 # keep blocks in rdepend for binpkg 52 # keep blocks in rdepend for binpkg
53 RDEPEND=" 53 RDEPEND="
54 !<x11-base/xorg-server-1.7 54 !<x11-base/xorg-server-1.7
55 !<=x11-proto/xf86driproto-2.0.3 55 !<=x11-proto/xf86driproto-2.0.3
56 >=app-admin/eselect-mesa-0.0.3 56 >=app-admin/eselect-mesa-0.0.3
57 >=app-admin/eselect-opengl-1.1.1-r2 57 >=app-admin/eselect-opengl-1.1.1-r2
58 dev-libs/expat 58 dev-libs/expat
59 dev-libs/libxml2[python]
60 sys-libs/talloc 59 sys-libs/talloc
61 x11-libs/libICE 60 x11-libs/libICE
62 » >=x11-libs/libX11-1.3.99.901 61 » >=x11-libs/libX11-1.3.3
63 x11-libs/libXdamage 62 x11-libs/libXdamage
64 x11-libs/libXext 63 x11-libs/libXext
65 x11-libs/libXi 64 x11-libs/libXi
66 x11-libs/libXmu 65 x11-libs/libXmu
67 x11-libs/libXxf86vm 66 x11-libs/libXxf86vm
68 motif? ( x11-libs/openmotif ) 67 motif? ( x11-libs/openmotif )
69 gallium? ( 68 gallium? (
70 llvm? ( 69 llvm? (
71 amd64? ( dev-libs/udis86 ) 70 amd64? ( dev-libs/udis86 )
72 x86? ( dev-libs/udis86 ) 71 x86? ( dev-libs/udis86 )
73 x86-fbsd? ( dev-libs/udis86 ) 72 x86-fbsd? ( dev-libs/udis86 )
74 sys-devel/llvm 73 sys-devel/llvm
75 ) 74 )
76 ) 75 )
77 » ${LIBDRM_DEPSTRING}[video_cards_nouveau?,video_cards_vmware?] 76 » ${LIBDRM_DEPSTRING}
78 " 77 "
79 for card in ${INTEL_CARDS}; do
80 RDEPEND="${RDEPEND}
81 video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_intel] )
82 "
83 done
84
85 for card in ${RADEON_CARDS}; do
86 RDEPEND="${RDEPEND}
87 video_cards_${card}? ( ${LIBDRM_DEPSTRING}[video_cards_radeon] )
88 "
89 done
90 78
91 DEPEND="${RDEPEND} 79 DEPEND="${RDEPEND}
92 =dev-lang/python-2* 80 =dev-lang/python-2*
81 dev-libs/libxml2
93 dev-util/pkgconfig 82 dev-util/pkgconfig
94 x11-misc/makedepend 83 x11-misc/makedepend
95 >=x11-proto/dri2proto-2.2 84 >=x11-proto/dri2proto-2.2
96 >=x11-proto/glproto-1.4.11 85 >=x11-proto/glproto-1.4.11
97 x11-proto/inputproto 86 x11-proto/inputproto
98 >=x11-proto/xextproto-7.0.99.1 87 >=x11-proto/xextproto-7.0.99.1
99 x11-proto/xf86driproto 88 x11-proto/xf86driproto
100 x11-proto/xf86vidmodeproto 89 x11-proto/xf86vidmodeproto
101 " 90 "
102 91
103 S="${WORKDIR}/${MY_P}" 92 S="${WORKDIR}/${MY_P}"
104 93
105 # It is slow without texrels, if someone wants slow 94 # It is slow without texrels, if someone wants slow
106 # mesa without texrels +pic use is worth the shot 95 # mesa without texrels +pic use is worth the shot
107 QA_EXECSTACK="usr/lib*/opengl/xorg-x11/lib/libGL.so*" 96 QA_EXECSTACK="usr/lib*/opengl/xorg-x11/lib/libGL.so*"
108 QA_WX_LOAD="usr/lib*/opengl/xorg-x11/lib/libGL.so*" 97 QA_WX_LOAD="usr/lib*/opengl/xorg-x11/lib/libGL.so*"
109 98
110 # Think about: ggi, fbcon, no-X configs 99 # Think about: ggi, fbcon, no-X configs
111 100
112 pkg_setup() { 101 pkg_setup() {
113 # gcc 4.2 has buggy ivopts 102 # gcc 4.2 has buggy ivopts
114 if [[ $(gcc-version) = "4.2" ]]; then 103 if [[ $(gcc-version) = "4.2" ]]; then
115 append-flags -fno-ivopts 104 append-flags -fno-ivopts
116 fi 105 fi
117 106
118 # recommended by upstream 107 # recommended by upstream
119 append-flags -ffast-math 108 append-flags -ffast-math
120
121 python_set_active_version 2
122 python_pkg_setup
123 } 109 }
124 110
125 src_unpack() { 111 src_unpack() {
126 [[ $PV = 9999* ]] && git_src_unpack || base_src_unpack 112 [[ $PV = 9999* ]] && git_src_unpack || base_src_unpack
127 } 113 }
128 114
129 src_prepare() { 115 src_prepare() {
130 # apply patches 116 # apply patches
131 if [[ ${PV} != 9999* && -n ${SRC_PATCHES} ]]; then 117 if [[ ${PV} != 9999* && -n ${SRC_PATCHES} ]]; then
132 EPATCH_FORCE="yes" \ 118 EPATCH_FORCE="yes" \
133 EPATCH_SOURCE="${WORKDIR}/patches" \ 119 EPATCH_SOURCE="${WORKDIR}/patches" \
134 EPATCH_SUFFIX="patch" \ 120 EPATCH_SUFFIX="patch" \
135 epatch 121 epatch
136 fi 122 fi
137 # FreeBSD 6.* doesn't have posix_memalign(). 123 # FreeBSD 6.* doesn't have posix_memalign().
138 if [[ ${CHOST} == *-freebsd6.* ]]; then 124 if [[ ${CHOST} == *-freebsd6.* ]]; then
139 sed -i \ 125 sed -i \
140 -e "s/-DHAVE_POSIX_MEMALIGN//" \ 126 -e "s/-DHAVE_POSIX_MEMALIGN//" \
141 configure.ac || die 127 configure.ac || die
142 fi 128 fi
143 129
144 # In order for mesa to complete it's build process we need to use a tool
145 # that it compiles. When we cross compile this clearly does not work
146 # so we require mesa to be built on the host system first. -solar
147 if tc-is-cross-compiler; then
148 sed -i -e "s#^GLSL_CL = .*\$#GLSL_CL = glsl_compiler#g" \
149 "${S}"/src/mesa/shader/slang/library/Makefile || die
150 fi
151
152 [[ $PV = 9999* ]] && git_src_prepare 130 [[ $PV = 9999* ]] && git_src_prepare
153 base_src_prepare 131 base_src_prepare
154 132
133 epatch "${FILESDIR}"/${PV}-get-maxsamples.patch
134 epatch "${FILESDIR}"/${PV}-add-discard.patch
135 epatch "${FILESDIR}"/${PV}-add-lower-pass-discards.patch
136 epatch "${FILESDIR}"/${PV}-conditional-discards.patch
137 epatch "${FILESDIR}"/${PV}-glbufferdata-0size.patch
138 epatch "${FILESDIR}"/${PV}-can_inline.patch
139 epatch "${FILESDIR}"/${PV}-glsl-vector-compare.patch
140 epatch "${FILESDIR}"/${PV}-gldeletebuffers.patch
141 epatch "${FILESDIR}"/${PV}-glisbuffer.patch
142 epatch "${FILESDIR}"/${PV}-optimize-discards.patch
143 epatch "${FILESDIR}"/${PV}-remove-discard-from-lower_jumps.patch
144
155 eautoreconf 145 eautoreconf
156 } 146 }
157 147
158 src_configure() { 148 src_configure() {
159 local myconf 149 local myconf
160 150
161 if use classic; then 151 if use classic; then
162 # Configurable DRI drivers 152 # Configurable DRI drivers
163 driver_enable swrast 153 driver_enable swrast
164 154
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 rm "${x}" || die "Failed to remove ${x}" 282 rm "${x}" || die "Failed to remove ${x}"
293 fi 283 fi
294 done 284 done
295 popd 285 popd
296 eend $? 286 eend $?
297 fi 287 fi
298 } 288 }
299 289
300 pkg_postinst() { 290 pkg_postinst() {
301 # Switch to the xorg implementation. 291 # Switch to the xorg implementation.
302 echo
303 eselect opengl set --use-old ${OPENGL_DIR} 292 eselect opengl set --use-old ${OPENGL_DIR}
304 # Select classic/gallium drivers 293 # Select classic/gallium drivers
305 eselect mesa set --auto 294 eselect mesa set --auto
306 } 295 }
307 296
308 # $1 - VIDEO_CARDS flag 297 # $1 - VIDEO_CARDS flag
309 # other args - names of DRI drivers to enable 298 # other args - names of DRI drivers to enable
310 driver_enable() { 299 driver_enable() {
311 case $# in 300 case $# in
312 # for enabling unconditionally 301 # for enabling unconditionally
313 1) 302 1)
314 DRI_DRIVERS+=",$1" 303 DRI_DRIVERS+=",$1"
315 ;; 304 ;;
316 *) 305 *)
317 if use $1; then 306 if use $1; then
318 shift 307 shift
319 for i in $@; do 308 for i in $@; do
320 DRI_DRIVERS+=",${i}" 309 DRI_DRIVERS+=",${i}"
321 done 310 done
322 fi 311 fi
323 ;; 312 ;;
324 esac 313 esac
325 } 314 }
OLDNEW
« no previous file with comments | « media-libs/mesa/files/eselect-mesa.conf.7.9 ('k') | media-libs/mesa/mesa-7.9-r1.ebuild » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698