1 |
dberkholz 08/04/25 20:44:50 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: mesa-7.0.3.ebuild |
5 |
Log: |
6 |
(#209900, #212511) Bump. |
7 |
(Portage version: 2.1.5_rc6) |
8 |
|
9 |
Revision Changes Path |
10 |
1.168 media-libs/mesa/ChangeLog |
11 |
|
12 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/mesa/ChangeLog?rev=1.168&view=markup |
13 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/mesa/ChangeLog?rev=1.168&content-type=text/plain |
14 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/mesa/ChangeLog?r1=1.167&r2=1.168 |
15 |
|
16 |
Index: ChangeLog |
17 |
=================================================================== |
18 |
RCS file: /var/cvsroot/gentoo-x86/media-libs/mesa/ChangeLog,v |
19 |
retrieving revision 1.167 |
20 |
retrieving revision 1.168 |
21 |
diff -u -r1.167 -r1.168 |
22 |
--- ChangeLog 31 Jan 2008 03:41:17 -0000 1.167 |
23 |
+++ ChangeLog 25 Apr 2008 20:44:49 -0000 1.168 |
24 |
@@ -1,6 +1,11 @@ |
25 |
# ChangeLog for media-libs/mesa |
26 |
# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 |
27 |
-# $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/ChangeLog,v 1.167 2008/01/31 03:41:17 dberkholz Exp $ |
28 |
+# $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/ChangeLog,v 1.168 2008/04/25 20:44:49 dberkholz Exp $ |
29 |
+ |
30 |
+*mesa-7.0.3 (25 Apr 2008) |
31 |
+ |
32 |
+ 25 Apr 2008; Donnie Berkholz <dberkholz@g.o>; +mesa-7.0.3.ebuild: |
33 |
+ (#209900, #212511) Bump. |
34 |
|
35 |
31 Jan 2008; Donnie Berkholz <dberkholz@g.o>; -mesa-7.0.1.ebuild: |
36 |
Clean up. |
37 |
|
38 |
|
39 |
|
40 |
1.1 media-libs/mesa/mesa-7.0.3.ebuild |
41 |
|
42 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/mesa/mesa-7.0.3.ebuild?rev=1.1&view=markup |
43 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/mesa/mesa-7.0.3.ebuild?rev=1.1&content-type=text/plain |
44 |
|
45 |
Index: mesa-7.0.3.ebuild |
46 |
=================================================================== |
47 |
# Copyright 1999-2008 Gentoo Foundation |
48 |
# Distributed under the terms of the GNU General Public License v2 |
49 |
# $Header: /var/cvsroot/gentoo-x86/media-libs/mesa/mesa-7.0.3.ebuild,v 1.1 2008/04/25 20:44:49 dberkholz Exp $ |
50 |
|
51 |
MY_PN="${PN/m/M}" |
52 |
MY_P="${MY_PN}-${PV/_/-}" |
53 |
MY_SRC_P="${MY_PN}Lib-${PV/_/-}" |
54 |
|
55 |
GIT= |
56 |
if [[ $PV = *_rc* ]]; then |
57 |
SRC_URI="http://www.mesa3d.org/beta/${MY_SRC_P}.tar.gz" |
58 |
elif [[ $PV = 9999 ]]; then |
59 |
SRC_URI="" |
60 |
GIT="git" |
61 |
EGIT_REPO_URI="git://anongit.freedesktop.org/mesa/mesa" |
62 |
else |
63 |
SRC_URI="mirror://sourceforge/mesa3d/${MY_SRC_P}.tar.bz2" |
64 |
fi |
65 |
|
66 |
inherit eutils toolchain-funcs multilib flag-o-matic ${GIT} portability versionator |
67 |
|
68 |
OPENGL_DIR="xorg-x11" |
69 |
|
70 |
DESCRIPTION="OpenGL-like graphic library for Linux" |
71 |
HOMEPAGE="http://mesa3d.sourceforge.net/" |
72 |
LICENSE="LGPL-2" |
73 |
SLOT="0" |
74 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd" |
75 |
IUSE_VIDEO_CARDS=" |
76 |
video_cards_i810 |
77 |
video_cards_mach64 |
78 |
video_cards_mga |
79 |
video_cards_none |
80 |
video_cards_r128 |
81 |
video_cards_radeon |
82 |
video_cards_s3virge |
83 |
video_cards_savage |
84 |
video_cards_sis |
85 |
video_cards_sunffb |
86 |
video_cards_tdfx |
87 |
video_cards_trident |
88 |
video_cards_via" |
89 |
IUSE="${IUSE_VIDEO_CARDS} |
90 |
debug |
91 |
doc |
92 |
pic |
93 |
motif |
94 |
nptl |
95 |
xcb |
96 |
kernel_FreeBSD" |
97 |
|
98 |
RDEPEND="app-admin/eselect-opengl |
99 |
dev-libs/expat |
100 |
x11-libs/libX11 |
101 |
x11-libs/libXext |
102 |
x11-libs/libXxf86vm |
103 |
x11-libs/libXi |
104 |
x11-libs/libXmu |
105 |
x11-libs/libXdamage |
106 |
=x11-libs/libdrm-2.3* |
107 |
x11-libs/libICE |
108 |
motif? ( virtual/motif ) |
109 |
doc? ( app-doc/opengl-manpages ) |
110 |
!<=x11-base/xorg-x11-6.9 |
111 |
xcb? ( x11-libs/libxcb )" |
112 |
DEPEND="${RDEPEND} |
113 |
!<=x11-proto/xf86driproto-2.0.3 |
114 |
dev-util/pkgconfig |
115 |
x11-misc/makedepend |
116 |
x11-proto/inputproto |
117 |
x11-proto/xextproto |
118 |
!hppa? ( x11-proto/xf86driproto ) |
119 |
x11-proto/xf86vidmodeproto |
120 |
>=x11-proto/glproto-1.4.8 |
121 |
motif? ( x11-proto/printproto )" |
122 |
|
123 |
S="${WORKDIR}/${MY_P}" |
124 |
|
125 |
# Think about: ggi, svga, fbcon, no-X configs |
126 |
|
127 |
pkg_setup() { |
128 |
if use xcb; then |
129 |
if ! built_with_use x11-libs/libX11 xcb; then |
130 |
msg="You must build libX11 with xcb enabled." |
131 |
eerror ${msg} |
132 |
die ${msg} |
133 |
fi |
134 |
fi |
135 |
|
136 |
if use debug; then |
137 |
strip-flags |
138 |
append-flags -g |
139 |
fi |
140 |
|
141 |
append-flags -fno-strict-aliasing |
142 |
|
143 |
# Recommended by upstream. Since people shouldn't be setting this on |
144 |
# a system level, we set this in this package to be sure it gets it. |
145 |
append-flags -ffast-math |
146 |
|
147 |
# gcc 4.2 has buggy ivopts |
148 |
if [[ $(gcc-version) = "4.2" ]]; then |
149 |
append-flags -fno-ivopts |
150 |
fi |
151 |
|
152 |
if use x86-fbsd; then |
153 |
CONFIG="freebsd-dri-x86" |
154 |
elif use amd64-fbsd; then |
155 |
CONFIG="freebsd-dri-amd64" |
156 |
elif use kernel_FreeBSD; then |
157 |
CONFIG="freebsd-dri" |
158 |
elif use x86; then |
159 |
CONFIG="linux-dri-x86" |
160 |
elif use amd64; then |
161 |
[[ ${ABI} == "amd64" ]] && CONFIG="linux-dri-x86-64" |
162 |
[[ ${ABI} == "x86" ]] && CONFIG="linux-dri-x86" |
163 |
elif use ppc; then |
164 |
CONFIG="linux-dri-ppc" |
165 |
else |
166 |
CONFIG="linux-dri" |
167 |
fi |
168 |
} |
169 |
|
170 |
src_unpack() { |
171 |
HOSTCONF="${S}/configs/${CONFIG}" |
172 |
|
173 |
if [[ $PV = 9999 ]]; then |
174 |
git_src_unpack |
175 |
else |
176 |
unpack ${A} |
177 |
fi |
178 |
cd "${S}" |
179 |
|
180 |
# FreeBSD 6.* doesn't have posix_memalign(). |
181 |
[[ ${CHOST} == *-freebsd6.* ]] && sed -i -e "s/-DHAVE_POSIX_MEMALIGN//" configs/freebsd{,-dri} |
182 |
|
183 |
# Don't compile debug code with USE=-debug - bug #125004 |
184 |
if ! use debug; then |
185 |
einfo "Removing DO_DEBUG defs in dri drivers..." |
186 |
find src/mesa/drivers/dri -name *.[hc] -exec egrep -l "\#define\W+DO_DEBUG\W+1" {} \; | xargs sed -i -re "s/\#define\W+DO_DEBUG\W+1/\#define DO_DEBUG 0/" ; |
187 |
fi |
188 |
|
189 |
# Set up libdir |
190 |
echo "LIB_DIR = $(get_libdir)" >> "${HOSTCONF}" |
191 |
|
192 |
# Set default dri drivers directory |
193 |
echo 'DRI_DRIVER_SEARCH_DIR = /usr/$(LIB_DIR)/dri' >> "${HOSTCONF}" |
194 |
|
195 |
# Do we want thread-local storage (TLS)? |
196 |
if use nptl; then |
197 |
echo "ARCH_FLAGS += -DGLX_USE_TLS" >> "${HOSTCONF}" |
198 |
fi |
199 |
|
200 |
echo "X11_INCLUDES = `pkg-config --cflags-only-I x11`" >> "${HOSTCONF}" |
201 |
if use xcb; then |
202 |
echo "DEFINES += -DUSE_XCB" >> "${HOSTCONF}" |
203 |
echo "X11_INCLUDES += `pkg-config --cflags-only-I xcb` `pkg-config --cflags-only-I x11-xcb` `pkg-config --cflags-only-I xcb-glx`" >> "${HOSTCONF}" |
204 |
echo "GL_LIB_DEPS += `pkg-config --libs xcb` `pkg-config --libs x11-xcb` `pkg-config --libs xcb-glx`" >> "${HOSTCONF}" |
205 |
fi |
206 |
|
207 |
# Configurable DRI drivers |
208 |
driver_enable video_cards_i810 i810 i915 i915tex i965 |
209 |
driver_enable video_cards_mach64 mach64 |
210 |
driver_enable video_cards_mga mga |
211 |
driver_enable video_cards_r128 r128 |
212 |
driver_enable video_cards_radeon radeon r200 r300 |
213 |
driver_enable video_cards_s3virge s3v |
214 |
driver_enable video_cards_savage savage |
215 |
driver_enable video_cards_sis sis |
216 |
driver_enable video_cards_sunffb ffb |
217 |
driver_enable video_cards_tdfx tdfx |
218 |
driver_enable video_cards_trident trident |
219 |
driver_enable video_cards_via unichrome |
220 |
|
221 |
# Set drivers to everything on which we ran driver_enable() |
222 |
echo "DRI_DIRS = ${DRI_DRIVERS}" >> "${HOSTCONF}" |
223 |
|
224 |
if use pic; then |
225 |
einfo "Deactivating assembly code for pic build" |
226 |
echo "ASM_FLAGS =" >> "${HOSTCONF}" |
227 |
echo "ASM_SOURCES =" >> "${HOSTCONF}" |
228 |
echo "ASM_API =" >> "${HOSTCONF}" |
229 |
fi |
230 |
|
231 |
if use sparc; then |
232 |
einfo "Sparc assembly code is not working; deactivating" |
233 |
echo "ASM_FLAGS =" >> "${HOSTCONF}" |
234 |
echo "ASM_SOURCES =" >> "${HOSTCONF}" |
235 |
fi |
236 |
|
237 |
# Replace hardcoded /usr/X11R6 with this |
238 |
echo "EXTRA_LIB_PATH = `pkg-config --libs-only-L x11`" >> "${HOSTCONF}" |
239 |
|
240 |
echo 'CFLAGS = $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) $(ASM_FLAGS)' >> "${HOSTCONF}" |
241 |
echo "OPT_FLAGS = ${CFLAGS}" >> "${HOSTCONF}" |
242 |
echo "CC = $(tc-getCC)" >> "${HOSTCONF}" |
243 |
echo "CXX = $(tc-getCXX)" >> "${HOSTCONF}" |
244 |
# bug #110840 - Build with PIC, since it hasn't been shown to slow it down |
245 |
echo "PIC_FLAGS = -fPIC" >> "${HOSTCONF}" |
246 |
|
247 |
# Removed glut, since we have separate freeglut/glut ebuilds |
248 |
# Remove EGL, since Brian Paul says it's not ready for a release |
249 |
echo "SRC_DIRS = glx/x11 mesa glu glw" >> "${HOSTCONF}" |
250 |
|
251 |
# Get rid of glut includes |
252 |
rm -f "${S}"/include/GL/glut*h |
253 |
|
254 |
# Documented in configs/default |
255 |
if use motif; then |
256 |
# Add -lXm |
257 |
echo "GLW_LIB_DEPS += -lXm" >> "${HOSTCONF}" |
258 |
# Add GLwMDrawA.c |
259 |
echo "GLW_SOURCES += GLwMDrawA.c" >> "${HOSTCONF}" |
260 |
fi |
261 |
|
262 |
# Shut up pointless warnings |
263 |
# echo "MKDEP = gcc -M" >> "${HOSTCONF}" |
264 |
# echo "MKDEP_OPTIONS = -MF depend" >> "${HOSTCONF}" |
265 |
echo "MKDEP_OPTIONS = -fdepend -I$(gcc-config -L)/include" >> "${HOSTCONF}" |
266 |
echo "INSTALL_DIR = /usr" >> "${HOSTCONF}" |
267 |
echo 'DRI_DRIVER_INSTALL_DIR = /usr/$(LIB_DIR)/dri' >> "${HOSTCONF}" |
268 |
} |
269 |
|
270 |
src_compile() { |
271 |
emake -j1 ${CONFIG} || die "Build failed" |
272 |
} |
273 |
|
274 |
src_install() { |
275 |
dodir /usr |
276 |
emake -j1 \ |
277 |
DESTDIR="${D}" \ |
278 |
install || die "Installation failed" |
279 |
|
280 |
if ! use motif; then |
281 |
rm "${D}"/usr/include/GL/GLwMDrawA.h |
282 |
fi |
283 |
|
284 |
# Don't install private headers |
285 |
rm -f "${D}"/usr/include/GL/GLw*P.h |
286 |
|
287 |
fix_opengl_symlinks |
288 |
dynamic_libgl_install |
289 |
|
290 |
# Install libtool archives |
291 |
insinto /usr/$(get_libdir) |
292 |
# (#67729) Needs to be lib, not $(get_libdir) |
293 |
doins "${FILESDIR}"/lib/libGLU.la |
294 |
sed -e "s:\${libdir}:$(get_libdir):g" "${FILESDIR}"/lib/libGL.la \ |
295 |
> "${D}"/usr/$(get_libdir)/opengl/xorg-x11/lib/libGL.la |
296 |
|
297 |
# On *BSD libcs dlopen() and similar functions are present directly in |
298 |
# libc.so and does not require linking to libdl. portability eclass takes |
299 |
# care of finding the needed library (if needed) witht the dlopen_lib |
300 |
# function. |
301 |
sed -i -e 's:-ldl:'$(dlopen_lib)':g' \ |
302 |
"${D}"/usr/$(get_libdir)/libGLU.la \ |
303 |
"${D}"/usr/$(get_libdir)/opengl/xorg-x11/lib/libGL.la |
304 |
|
305 |
# Create the two-number versioned libs (.so.#.#), since only .so.# and |
306 |
# .so.#.#.# were made |
307 |
local MAJOR_2="$(printf "%.2i" $(get_version_component_range 1 ${PV}))" |
308 |
local MINOR_2="$(printf "%.2i" $(get_version_component_range 2 ${PV}))" |
309 |
local MICRO_2="$(printf "%.2i" $(get_version_component_range 3 ${PV}))" |
310 |
dosym \ |
311 |
libGLU.so.1.3.${MAJOR_2}${MINOR_2}${MICRO_2} \ |
312 |
/usr/$(get_libdir)/libGLU.so.1.3 |
313 |
dosym libGLw.so.1.0.0 /usr/$(get_libdir)/libGLw.so.1.0 |
314 |
|
315 |
# libGLU doesn't get the plain .so symlink either |
316 |
dosym libGLU.so.1 /usr/$(get_libdir)/libGLU.so |
317 |
|
318 |
# Figure out why libGL.so.1.5 is built (directfb), and why it's linked to |
319 |
# as the default libGL.so.1 |
320 |
} |
321 |
|
322 |
pkg_postinst() { |
323 |
switch_opengl_implem |
324 |
|
325 |
# We need the outer check, because xorg-server may not be installed |
326 |
# first, and built_with_use() dies if the package isn't installed. |
327 |
if has_version x11-base/xorg-server; then |
328 |
if built_with_use x11-base/xorg-server nptl; then |
329 |
ewarn "Rebuild x11-base/xorg-server without USE=nptl" |
330 |
ewarn "or AIGLX (compiz, etc.) will not work." |
331 |
ewarn "This is because of a bug in the Mesa NPTL assembly code" |
332 |
ewarn "in all Mesa 7.0.x versions (Mesa 6.x is OK)." |
333 |
fi |
334 |
fi |
335 |
} |
336 |
|
337 |
fix_opengl_symlinks() { |
338 |
# Remove invalid symlinks |
339 |
local LINK |
340 |
for LINK in $(find "${D}"/usr/$(get_libdir) \ |
341 |
-name libGL\.* -type l); do |
342 |
rm -f ${LINK} |
343 |
done |
344 |
# Create required symlinks |
345 |
if [[ ${CHOST} == *-freebsd* ]]; then |
346 |
# FreeBSD doesn't use major.minor versioning, so the library is only |
347 |
# libGL.so.1 and no libGL.so.1.2 is ever used there, thus only create |
348 |
# libGL.so symlink and leave libGL.so.1 being the real thing |
349 |
dosym libGL.so.1 /usr/$(get_libdir)/libGL.so |
350 |
else |
351 |
dosym libGL.so.1.2 /usr/$(get_libdir)/libGL.so |
352 |
dosym libGL.so.1.2 /usr/$(get_libdir)/libGL.so.1 |
353 |
fi |
354 |
} |
355 |
|
356 |
dynamic_libgl_install() { |
357 |
# next section is to setup the dynamic libGL stuff |
358 |
ebegin "Moving libGL and friends for dynamic switching" |
359 |
dodir /usr/$(get_libdir)/opengl/${OPENGL_DIR}/{lib,extensions,include} |
360 |
local x="" |
361 |
for x in "${D}"/usr/$(get_libdir)/libGL.so* \ |
362 |
"${D}"/usr/$(get_libdir)/libGL.la \ |
363 |
"${D}"/usr/$(get_libdir)/libGL.a; do |
364 |
if [ -f ${x} -o -L ${x} ]; then |
365 |
# libGL.a cause problems with tuxracer, etc |
366 |
mv -f ${x} "${D}"/usr/$(get_libdir)/opengl/${OPENGL_DIR}/lib |
367 |
fi |
368 |
done |
369 |
# glext.h added for #54984 |
370 |
for x in "${D}"/usr/include/GL/{gl.h,glx.h,glext.h,glxext.h}; do |
371 |
if [ -f ${x} -o -L ${x} ]; then |
372 |
mv -f ${x} "${D}"/usr/$(get_libdir)/opengl/${OPENGL_DIR}/include |
373 |
fi |
374 |
done |
375 |
eend 0 |
376 |
} |
377 |
|
378 |
switch_opengl_implem() { |
379 |
# Switch to the xorg implementation. |
380 |
# Use new opengl-update that will not reset user selected |
381 |
# OpenGL interface ... |
382 |
echo |
383 |
eselect opengl set --use-old ${OPENGL_DIR} |
384 |
} |
385 |
|
386 |
# $1 - VIDEO_CARDS flag |
387 |
# other args - names of DRI drivers to enable |
388 |
driver_enable() { |
389 |
if use $1; then |
390 |
shift |
391 |
DRI_DRIVERS="${DRI_DRIVERS} $@" |
392 |
fi |
393 |
} |
394 |
|
395 |
|
396 |
|
397 |
-- |
398 |
gentoo-commits@l.g.o mailing list |