/[gentoo-x86]/x11-base/xorg-server/xorg-server-1.3.0.0-r6.ebuild
Gentoo

Contents of /x11-base/xorg-server/xorg-server-1.3.0.0-r6.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.15 - (hide annotations) (download)
Sat Sep 19 15:23:54 2009 UTC (4 years, 10 months ago) by scarabeus
Branch: MAIN
CVS Tags: HEAD
Changes since 1.14: +1 -1 lines
FILE REMOVED
Cleanup. Removal of old xorg versions.
(Portage version: 2.2_rc38/cvs/Linux i686)

1 remi 1.9 # Copyright 1999-2009 Gentoo Foundation
2 dberkholz 1.1 # Distributed under the terms of the GNU General Public License v2
3 scarabeus 1.15 # $Header: /var/cvsroot/gentoo-x86/x11-base/xorg-server/xorg-server-1.3.0.0-r6.ebuild,v 1.14 2009/08/14 09:11:25 remi Exp $
4 dberkholz 1.1
5     # Must be before x-modular eclass is inherited
6     SNAPSHOT="yes"
7    
8     inherit x-modular multilib
9    
10     OPENGL_DIR="xorg-x11"
11    
12     MESA_PN="Mesa"
13     MESA_PV="6.5.2"
14     MESA_P="${MESA_PN}-${MESA_PV}"
15     MESA_SRC_P="${MESA_PN}Lib-${MESA_PV}"
16    
17     SRC_URI="${SRC_URI}
18     mirror://sourceforge/mesa3d/${MESA_SRC_P}.tar.bz2
19     http://xorg.freedesktop.org/releases/individual/xserver/${P}.tar.bz2"
20     DESCRIPTION="X.Org X servers"
21 dberkholz 1.7 KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 sh sparc x86 ~x86-fbsd"
22 dberkholz 1.1 IUSE_INPUT_DEVICES="
23     input_devices_acecad
24     input_devices_aiptek
25     input_devices_citron
26     input_devices_elographics
27     input_devices_evdev
28     input_devices_fpit
29     input_devices_hyperpen
30     input_devices_joystick
31     input_devices_keyboard
32     input_devices_mouse
33     input_devices_mutouch
34     input_devices_penmount
35     input_devices_vmmouse
36     input_devices_void
37    
38     input_devices_wacom"
39     IUSE_VIDEO_CARDS="
40     video_cards_apm
41     video_cards_ark
42     video_cards_chips
43     video_cards_cirrus
44     video_cards_cyrix
45     video_cards_dummy
46     video_cards_epson
47     video_cards_fbdev
48     video_cards_glint
49     video_cards_i128
50     video_cards_i740
51 remi 1.8 video_cards_intel
52 dberkholz 1.1 video_cards_impact
53     video_cards_imstt
54     video_cards_mach64
55     video_cards_mga
56     video_cards_neomagic
57     video_cards_newport
58     video_cards_nsc
59     video_cards_nv
60     video_cards_r128
61     video_cards_radeon
62     video_cards_rendition
63     video_cards_s3
64     video_cards_s3virge
65     video_cards_savage
66     video_cards_siliconmotion
67     video_cards_sis
68     video_cards_sisusb
69     video_cards_sunbw2
70     video_cards_suncg14
71     video_cards_suncg3
72     video_cards_suncg6
73     video_cards_sunffb
74     video_cards_sunleo
75     video_cards_suntcx
76     video_cards_tdfx
77     video_cards_tga
78     video_cards_trident
79     video_cards_tseng
80     video_cards_v4l
81     video_cards_vesa
82     video_cards_vga
83     video_cards_via
84     video_cards_vmware
85     video_cards_voodoo
86     video_cards_nvidia"
87     IUSE_SERVERS="dmx kdrive xorg"
88     IUSE="${IUSE_VIDEO_CARDS}
89     ${IUSE_INPUT_DEVICES}
90     ${IUSE_SERVERS}
91     3dfx
92 remi 1.10 dri ipv6 minimal nptl sdl"
93 dberkholz 1.1 RDEPEND=">=x11-libs/libXfont-1.2.5
94     x11-libs/xtrans
95     x11-libs/libXau
96     x11-libs/libXext
97     x11-libs/libX11
98     x11-libs/libxkbfile
99     x11-libs/libXdmcp
100     x11-libs/libXmu
101     <x11-libs/libXrender-0.9.3
102     x11-libs/libXi
103     media-libs/freetype
104     >=media-libs/mesa-6.5.2
105     media-fonts/font-adobe-75dpi
106     media-fonts/font-misc-misc
107     media-fonts/font-cursor-misc
108     x11-misc/xbitmaps
109 remi 1.9 x11-misc/xkeyboard-config
110 dberkholz 1.1 x11-apps/iceauth
111     x11-apps/rgb
112     x11-apps/xauth
113     x11-apps/xinit
114     app-admin/eselect-opengl
115     x11-libs/libXaw
116     x11-libs/libXpm
117     x11-libs/libXxf86misc
118     x11-libs/libXxf86vm
119     dmx? ( x11-libs/libdmx
120     x11-libs/libXfixes )
121     !minimal? ( x11-libs/libXtst
122     x11-libs/libXres )
123     >=x11-libs/libxkbui-1.0.2
124     x11-libs/liblbxutil
125     kdrive? ( sdl? ( media-libs/libsdl ) )"
126     # Xres is dmx-dependent, xkbui is xorgcfg-dependent
127     # Xaw is dmx- and xorgcfg-dependent
128     # Xpm is dmx- and xorgcfg-dependent, pulls in Xt
129     # Xxf86misc and Xxf86vm are xorgcfg-dependent
130     # liblbxutil is lbx- dependent
131     DEPEND="${RDEPEND}
132     >=x11-proto/randrproto-1.2.1
133     <x11-proto/renderproto-0.9.3
134     >=x11-proto/fixesproto-4
135     >=x11-proto/damageproto-1.1
136     x11-proto/xextproto
137     x11-proto/xproto
138     x11-proto/xf86dgaproto
139     x11-proto/xf86miscproto
140     x11-proto/xf86rushproto
141     x11-proto/xf86vidmodeproto
142     x11-proto/xf86bigfontproto
143     >=x11-proto/compositeproto-0.3
144     x11-proto/recordproto
145     x11-proto/resourceproto
146     x11-proto/videoproto
147     >=x11-proto/scrnsaverproto-1.1.0
148     x11-proto/evieext
149     x11-proto/trapproto
150     >=x11-proto/xineramaproto-1.1-r1
151     x11-proto/fontsproto
152     >=x11-proto/kbproto-1.0.3
153     x11-proto/inputproto
154     x11-proto/bigreqsproto
155     x11-proto/xcmiscproto
156     >=x11-proto/glproto-1.4.8
157     dmx? ( x11-proto/dmxproto )
158     dri? ( x11-proto/xf86driproto
159 remi 1.10 >=x11-libs/libdrm-2.3 )"
160 dberkholz 1.1
161     # Drivers
162     PDEPEND="
163     xorg? (
164     input_devices_acecad? ( >=x11-drivers/xf86-input-acecad-1.1.0 )
165     input_devices_aiptek? ( >=x11-drivers/xf86-input-aiptek-1.0.1 )
166     input_devices_citron? ( >=x11-drivers/xf86-input-citron-2.2.0 )
167     input_devices_elographics? ( >=x11-drivers/xf86-input-elographics-1.1.0 )
168     input_devices_evdev? ( >=x11-drivers/xf86-input-evdev-1.1.1 )
169     input_devices_fpit? ( >=x11-drivers/xf86-input-fpit-1.1.0 )
170     input_devices_hyperpen? ( >=x11-drivers/xf86-input-hyperpen-1.1.0 )
171     input_devices_joystick? ( >=x11-drivers/xf86-input-joystick-1.1.0 )
172     input_devices_keyboard? ( =x11-drivers/xf86-input-keyboard-1.1* )
173     input_devices_mouse? ( >=x11-drivers/xf86-input-mouse-1.1.0 )
174     input_devices_mutouch? ( >=x11-drivers/xf86-input-mutouch-1.1.0 )
175     input_devices_penmount? ( >=x11-drivers/xf86-input-penmount-1.1.0 )
176     input_devices_vmmouse? ( >=x11-drivers/xf86-input-vmmouse-12.4.0 )
177     input_devices_void? ( >=x11-drivers/xf86-input-void-1.1.0 )
178    
179     input_devices_wacom? ( x11-drivers/linuxwacom )
180    
181     video_cards_apm? ( >=x11-drivers/xf86-video-apm-1.1.1 )
182     video_cards_ark? ( >=x11-drivers/xf86-video-ark-0.6.0 )
183     video_cards_chips? ( >=x11-drivers/xf86-video-chips-1.1.1 )
184     video_cards_cirrus? ( >=x11-drivers/xf86-video-cirrus-1.1.0 )
185     video_cards_cyrix? ( >=x11-drivers/xf86-video-cyrix-1.1.0 )
186     video_cards_dummy? ( >=x11-drivers/xf86-video-dummy-0.2.0 )
187     video_cards_fbdev? ( >=x11-drivers/xf86-video-fbdev-0.2.0 )
188     video_cards_glint? ( >=x11-drivers/xf86-video-glint-1.1.1 )
189     video_cards_i128? ( >=x11-drivers/xf86-video-i128-1.2.0 )
190     video_cards_i740? ( >=x11-drivers/xf86-video-i740-1.1.0 )
191 remi 1.8 video_cards_intel? ( >=x11-drivers/xf86-video-intel-1.6.0 )
192 dberkholz 1.1 video_cards_impact? ( >=x11-drivers/xf86-video-impact-0.2.0 )
193     video_cards_imstt? ( >=x11-drivers/xf86-video-imstt-1.1.0 )
194     video_cards_mach64? ( >=x11-drivers/xf86-video-ati-6.6.0 )
195     video_cards_mga? ( >=x11-drivers/xf86-video-mga-1.4.1 )
196     video_cards_neomagic? ( >=x11-drivers/xf86-video-neomagic-1.1.1 )
197     video_cards_newport? ( >=x11-drivers/xf86-video-newport-0.2.0 )
198     video_cards_nsc? ( >=x11-drivers/xf86-video-nsc-2.8.1 )
199     video_cards_nv? ( >=x11-drivers/xf86-video-nv-1.1.1 )
200     video_cards_r128? ( >=x11-drivers/xf86-video-ati-6.6.0 )
201     video_cards_radeon? ( >=x11-drivers/xf86-video-ati-6.6.0 )
202     video_cards_rendition? ( >=x11-drivers/xf86-video-rendition-4.1.0 )
203     video_cards_s3? ( >=x11-drivers/xf86-video-s3-0.4.1 )
204     video_cards_s3virge? ( >=x11-drivers/xf86-video-s3virge-1.9.1 )
205     video_cards_savage? ( >=x11-drivers/xf86-video-savage-2.1.1 )
206     video_cards_siliconmotion? ( >=x11-drivers/xf86-video-siliconmotion-1.4.1 )
207     video_cards_sis? ( >=x11-drivers/xf86-video-sis-0.9.1 )
208     video_cards_sisusb? ( >=x11-drivers/xf86-video-sisusb-0.8.1 )
209     video_cards_sunbw2? ( >=x11-drivers/xf86-video-sunbw2-1.1.0 )
210     video_cards_suncg14? ( >=x11-drivers/xf86-video-suncg14-1.1.0 )
211     video_cards_suncg3? ( >=x11-drivers/xf86-video-suncg3-1.1.0 )
212     video_cards_suncg6? ( >=x11-drivers/xf86-video-suncg6-1.1.0 )
213     video_cards_sunffb? ( >=x11-drivers/xf86-video-sunffb-1.1.0 )
214     video_cards_sunleo? ( >=x11-drivers/xf86-video-sunleo-1.1.0 )
215     video_cards_suntcx? ( >=x11-drivers/xf86-video-suntcx-1.1.0 )
216     video_cards_tdfx? ( >=x11-drivers/xf86-video-tdfx-1.2.1 )
217     video_cards_tga? ( >=x11-drivers/xf86-video-tga-1.1.0 )
218     video_cards_trident? ( >=x11-drivers/xf86-video-trident-1.2.1 )
219     video_cards_tseng? ( >=x11-drivers/xf86-video-tseng-1.1.0 )
220     video_cards_v4l? ( >=x11-drivers/xf86-video-v4l-0.1.1 )
221     video_cards_vesa? ( >=x11-drivers/xf86-video-vesa-1.1.0 )
222     video_cards_vga? ( >=x11-drivers/xf86-video-vga-4.1.0 )
223     video_cards_via? ( >=x11-drivers/xf86-video-openchrome-0.2.901 )
224     video_cards_vmware? ( >=x11-drivers/xf86-video-vmware-10.13.0 )
225     video_cards_voodoo? ( >=x11-drivers/xf86-video-voodoo-1.1.0 )
226     video_cards_tdfx? ( 3dfx? ( >=media-libs/glide-v3-3.10 ) )
227     video_cards_nvidia? ( x11-drivers/nvidia-drivers )
228     )"
229     LICENSE="${LICENSE} MIT"
230    
231 ssuominen 1.13 PATCHES=( "${FILESDIR}/${PV}-fix-xkb-openoffice-hangs.patch"
232     "${FILESDIR}/${PV}-fix-dual-head-screen-resolutions.patch"
233     "${FILESDIR}/${PV}-fix-randr-resizing.patch"
234     "${FILESDIR}/${PV}-fix-xephyr-amd64-segfault.patch"
235     "${FILESDIR}/${PV}-ramdac.patch"
236     "${FILESDIR}/use-composite-for-unequal-depths.patch"
237     "${FILESDIR}/1.2.0-fix-amd-cpu-detection.patch"
238     "${FILESDIR}/1.2.0-properly-free-device-devprivates-memory-leak-fix.patch"
239     "${FILESDIR}/1.2.0-typo-fix.patch"
240     "${FILESDIR}/1.2.0-zero-out-client-devprivates-on-allocation.patch"
241     "${FILESDIR}/${PV}-use-proc-instead-of-sys.patch"
242     "${FILESDIR}/avoid-crash-on-minimized-xv-window.patch"
243     "${FILESDIR}/xorg-server-sam225bw-quirks.patch"
244     "${FILESDIR}/1.3-alpha-build-fix.patch"
245     "${FILESDIR}/${PV}-xephyr_crash_at_exit.patch"
246     "${FILESDIR}/xorg-x11-server-1.0.1-fpic-libxf86config.patch"
247     "${FILESDIR}/1.4-0001-Fix-for-CVE-2007-5760-XFree86-Misc-extension-out-o.patch"
248     "${FILESDIR}/1.4-0002-Fix-for-CVE-2007-6428-TOG-cup-extension-memory-cor.patch"
249     "${FILESDIR}/1.3-0003-Fix-for-CVE-2007-6427-Xinput-extension-memory-corr.patch"
250     "${FILESDIR}/1.4-0004-Fix-for-CVE-2007-6429-MIT-SHM-and-EVI-extensions-i.patch"
251     "${FILESDIR}/1.4-0005-Fix-for-CVE-2008-0006-PCF-Font-parser-buffer-overf.patch"
252     "${FILESDIR}/1.3-0006-Fix-for-CVE-2007-5958-File-existence-disclosure.patch"
253     "${FILESDIR}/1.4-0007-CVE-2007-6429-Don-t-spuriously-reject-8bpp-shm-pix.patch"
254     "${FILESDIR}/1.4-0008-CVE-2007-6429-Always-test-for-size-offset-wrapping.patch"
255     "${FILESDIR}/1.4-0009-Don-t-break-grab-and-focus-state-for-a-window-when-r.patch"
256     "${FILESDIR}/xorg-server-1.4.0.90-automake-1.10.1-fixup.patch"
257     "${FILESDIR}/xorg-xserver-1.4-cve-2008-1377.diff"
258     "${FILESDIR}/xorg-xserver-1.4-cve-2008-1379.diff"
259     "${FILESDIR}/xorg-xserver-1.4-cve-2008-2360.diff"
260     "${FILESDIR}/xorg-xserver-1.4-cve-2008-2361.diff"
261     "${FILESDIR}/xorg-xserver-1.4-cve-2008-2362.diff" )
262 dberkholz 1.1
263     pkg_setup() {
264     use minimal || ensure_a_server_is_building
265    
266     # SDL only available in kdrive build
267     if use kdrive && use sdl; then
268     conf_opts="${conf_opts} --enable-xsdl"
269     else
270     conf_opts="${conf_opts} --disable-xsdl"
271     fi
272    
273     # Only Xorg and Xgl support this, and we won't build Xgl
274     # until it merges to trunk
275     if use xorg; then
276     conf_opts="${conf_opts} --with-mesa-source=${WORKDIR}/${MESA_P}"
277     fi
278    
279     # localstatedir is used for the log location; we need to override the default
280     # from ebuild.sh
281     # sysconfdir is used for the xorg.conf location; same applies
282     # --enable-install-setuid needed because sparcs default off
283     CONFIGURE_OPTIONS="
284     $(use_enable ipv6)
285     $(use_enable dmx)
286     $(use_enable kdrive)
287     $(use_enable !minimal xvfb)
288     $(use_enable !minimal xnest)
289     $(use_enable !minimal install-libxf86config)
290     $(use_enable dri)
291     $(use_enable xorg)
292 remi 1.10 --disable-xprint
293 dberkholz 1.1 $(use_enable nptl glx-tls)
294     $(use_enable !minimal xorgcfg)
295     --sysconfdir=/etc/X11
296     --localstatedir=/var
297     --enable-install-setuid
298     --with-fontdir=/usr/share/fonts
299     --with-xkb-output=/var/lib/xkb
300     ${conf_opts}"
301    
302     local diemsg="You must build xorg-server and mesa with the same nptl USE setting."
303     if built_with_use media-libs/mesa nptl; then
304     use nptl || die "${diemsg}"
305     else
306     use nptl && die "${diemsg}"
307     fi
308    
309     # (#121394) Causes window corruption
310     filter-flags -fweb
311    
312     # Nothing else provides new enough glxtokens.h
313     ewarn "Forcing on xorg-x11 for new enough glxtokens.h..."
314     OLD_IMPLEM="$(eselect opengl show)"
315     eselect opengl set --impl-headers ${OPENGL_DIR}
316     }
317    
318     src_unpack() {
319     x-modular_specs_check
320     x-modular_dri_check
321     x-modular_unpack_source
322     x-modular_patch_source
323    
324     # Set up kdrive servers to build
325     if use kdrive; then
326     kdrive_setup
327     fi
328    
329     # Make sure eautoreconf gets run if we need the autoconf/make
330     # changes.
331     if [[ ${SNAPSHOT} != "yes" ]]; then
332     if use kdrive; then
333     eautoreconf
334     fi
335     fi
336     x-modular_reconf_source
337     }
338    
339     src_install() {
340     x-modular_src_install
341    
342     dynamic_libgl_install
343    
344     server_based_install
345    
346     # Install video mode files for system-config-display
347     insinto /usr/share/xorg
348     doins hw/xfree86/common/{extra,vesa}modes \
349     || die "couldn't install extra modes"
350    
351     # Bug #151421 - this file is not built with USE="minimal"
352     # Bug #151670 - this file is also not build if USE="-xorg"
353     if ! use minimal && use xorg; then
354     # Install xorg.conf.example
355     insinto /etc/X11
356     doins hw/xfree86/xorg.conf.example \
357     || die "couldn't install xorg.conf.example"
358     fi
359     }
360    
361     pkg_postinst() {
362     switch_opengl_implem
363    
364     # Bug #135544
365     ewarn "Users of reduced blanking now need:"
366     ewarn " Option \"ReducedBlanking\""
367     ewarn "In the relevant Monitor section(s)."
368     ewarn "Make sure your reduced blanking modelines are safe!"
369     }
370    
371     pkg_postrm() {
372     # Get rid of module dir to ensure opengl-update works properly
373     if ! has_version x11-base/xorg-server; then
374     if [[ -e ${ROOT}/usr/$(get_libdir)/xorg/modules ]]; then
375     rm -rf "${ROOT}"/usr/$(get_libdir)/xorg/modules
376     fi
377     fi
378     }
379    
380     kdrive_setup() {
381     local card real_card disable_card kdrive_fbdev kdrive_vesa
382    
383     einfo "Removing unused kdrive drivers ..."
384    
385     # Some kdrive servers require fbdev and vesa
386     kdrive_fbdev="radeon neomagic sis siliconmotion"
387     # Some kdrive servers require just vesa
388     kdrive_vesa="chips mach64 mga nv glint r128 via"
389    
390     for card in ${IUSE_VIDEO_CARDS}; do
391     real_card=${card#video_cards_}
392    
393     # Differences between VIDEO_CARDS name and kdrive server name
394     real_card=${real_card/glint/pm2}
395     real_card=${real_card/radeon/ati}
396     real_card=${real_card/%nv/nvidia}
397     real_card=${real_card/siliconmotion/smi}
398     real_card=${real_card/%sis/sis300}
399    
400     disable_card=0
401    
402     # Check whether it's a valid kdrive server before we waste time
403     # on the rest of this
404     if ! grep -q -o "\b${real_card}\b" "${S}"/hw/kdrive/Makefile.am; then
405     continue
406     fi
407    
408     if ! use ${card}; then
409     if use x86; then
410     # Some kdrive servers require fbdev and vesa
411     for i in ${kdrive_fbdev}; do
412     if use video_cards_${i}; then
413     if [[ ${real_card} = fbdev ]] \
414     || [[ ${real_card} = vesa ]]; then
415     continue 2 # Don't disable
416     fi
417     fi
418     done
419    
420     # Some kdrive servers require just vesa
421     for i in ${kdrive_vesa}; do
422     if use video_cards_${i}; then
423     if [[ ${real_card} = vesa ]]; then
424     continue 2 # Don't disable
425     fi
426     fi
427     done
428     fi
429     disable_card=1
430     # Bug #150052
431     # fbdev is the only VIDEO_CARDS setting that works on non-x86
432     elif ! use x86 \
433     && [[ ${real_card} != fbdev ]]; then
434     ewarn " $real_card does not work on your architecture; disabling."
435     disable_card=1
436     fi
437    
438     if [[ $disable_card = 1 ]]; then
439     ebegin " ${real_card}"
440     sed -i \
441     -e "s:\b${real_card}\b::g" \
442     "${S}"/hw/kdrive/Makefile.am \
443     || die "sed of ${real_card} failed"
444     eend
445     fi
446    
447     done
448    
449     # smi and via are the only things on line 2. If line 2 ends up blank,
450     # we need to get rid of the backslash at the end of line 1.
451     if ! use video_cards_siliconmotion && ! use video_cards_via; then
452     sed -i \
453     -e "s:^\(VESA_SUBDIRS.*\)\\\:\1:g" \
454     "${S}"/hw/kdrive/Makefile.am
455     fi
456     }
457    
458     dynamic_libgl_install() {
459     # next section is to setup the dynamic libGL stuff
460     ebegin "Moving GL files for dynamic switching"
461     dodir /usr/$(get_libdir)/opengl/${OPENGL_DIR}/extensions
462     local x=""
463     for x in "${D}"/usr/$(get_libdir)/xorg/modules/extensions/libglx*; do
464     if [ -f ${x} -o -L ${x} ]; then
465     mv -f ${x} "${D}"/usr/$(get_libdir)/opengl/${OPENGL_DIR}/extensions
466     fi
467     done
468     eend 0
469     }
470    
471     server_based_install() {
472     if ! use xorg; then
473     rm "${D}"/usr/share/man/man1/Xserver.1x \
474     "${D}"/usr/$(get_libdir)/xserver/SecurityPolicy \
475     "${D}"/usr/$(get_libdir)/pkgconfig/xorg-server.pc \
476     "${D}"/usr/share/man/man1/Xserver.1x
477     fi
478     }
479    
480     switch_opengl_implem() {
481     # Switch to the xorg implementation.
482     # Use new opengl-update that will not reset user selected
483     # OpenGL interface ...
484     echo
485     # eselect opengl set --use-old ${OPENGL_DIR}
486     eselect opengl set ${OLD_IMPLEM}
487     }
488    
489     ensure_a_server_is_building() {
490     for server in ${IUSE_SERVERS}; do
491     use ${server} && return;
492     done
493     eerror "You need to specify at least one server to build."
494     eerror "Valid servers are: ${IUSE_SERVERS}."
495     die "No servers were specified to build."
496     }

  ViewVC Help
Powered by ViewVC 1.1.20