/[gentoo-x86]/x11-base/xorg-server/xorg-server-1.1.1-r1.ebuild
Gentoo

Diff of /x11-base/xorg-server/xorg-server-1.1.1-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.19 Revision 1.20
1# Copyright 1999-2006 Gentoo Foundation 1# Copyright 1999-2006 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/x11-base/xorg-server/Attic/xorg-server-1.1.1-r1.ebuild,v 1.19 2006/10/25 18:25:24 dberkholz Exp $ 3# $Header: /var/cvsroot/gentoo-x86/x11-base/xorg-server/Attic/xorg-server-1.1.1-r1.ebuild,v 1.20 2006/10/25 18:59:31 dberkholz Exp $
4 4
5# Must be before x-modular eclass is inherited 5# Must be before x-modular eclass is inherited
6SNAPSHOT="yes" 6SNAPSHOT="yes"
7 7
8inherit x-modular multilib 8inherit x-modular multilib
350 x-modular_unpack_source 350 x-modular_unpack_source
351 x-modular_patch_source 351 x-modular_patch_source
352 352
353 # Set up kdrive servers to build 353 # Set up kdrive servers to build
354 if use kdrive; then 354 if use kdrive; then
355 einfo "Removing unused kdrive drivers ..." 355 kdrive_setup
356
357 # Some kdrive servers require fbdev and vesa
358 local kdrive_fbdev="radeon neomagic sis siliconmotion"
359 # Some kdrive servers require just vesa
360 local kdrive_vesa="chips mach64 mga nv glint r128 via"
361
362 for card in ${IUSE_VIDEO_CARDS}; do
363 real_card=${card#video_cards_}
364
365 # Differences between VIDEO_CARDS name and kdrive server name
366 real_card=${real_card/glint/pm2}
367 real_card=${real_card/radeon/ati}
368 real_card=${real_card/%nv/nvidia}
369 real_card=${real_card/siliconmotion/smi}
370 real_card=${real_card/%sis/sis300}
371
372 disable_card=0
373
374 # Check whether it's a valid kdrive server before we waste time
375 # on the rest of this
376 if ! grep -q -o "\b${real_card}\b" ${S}/hw/kdrive/Makefile.am; then
377 continue
378 fi
379
380 if ! use ${card}; then
381 if use x86; then
382 # Some kdrive servers require fbdev and vesa
383 for i in ${kdrive_fbdev}; do
384 if use video_cards_${i}; then
385 if [[ ${real_card} = fbdev ]] \
386 || [[ ${real_card} = vesa ]]; then
387 continue 2 # Don't disable
388 fi
389 fi
390 done
391
392 # Some kdrive servers require just vesa
393 for i in ${kdrive_vesa}; do
394 if use video_cards_${i}; then
395 if [[ ${real_card} = vesa ]]; then
396 continue 2 # Don't disable
397 fi
398 fi
399 done
400 fi
401 disable_card=1
402 # Bug #150052
403 # fbdev is the only VIDEO_CARDS setting that works on non-x86
404 elif ! use x86 \
405 && [[ ${real_card} != fbdev ]]; then
406 ewarn " $real_card does not work on your architecture; disabling."
407 disable_card=1
408 fi
409
410 if [[ $disable_card = 1 ]]; then
411 ebegin " ${real_card}"
412 sed -i \
413 -e "s:\b${real_card}\b::g" \
414 ${S}/hw/kdrive/Makefile.am \
415 || die "sed of ${real_card} failed"
416 eend
417 fi
418
419 done
420
421 # smi and via are the only things on line 2. If line 2 ends up blank,
422 # we need to get rid of the backslash at the end of line 1.
423 if ! use video_cards_siliconmotion && ! use video_cards_via; then
424 sed -i \
425 -e "s:^\(VESA_SUBDIRS.*\)\\\:\1:g" \
426 ${S}/hw/kdrive/Makefile.am
427 fi
428 fi 356 fi
429 357
430 # Make sure eautoreconf gets run if we need the autoconf/make 358 # Make sure eautoreconf gets run if we need the autoconf/make
431 # changes. 359 # changes.
432 if [[ ${SNAPSHOT} != "yes" ]]; then 360 if [[ ${SNAPSHOT} != "yes" ]]; then
473 # Get rid of module dir to ensure opengl-update works properly 401 # Get rid of module dir to ensure opengl-update works properly
474 if ! has_version x11-base/xorg-server; then 402 if ! has_version x11-base/xorg-server; then
475 if [ -e ${ROOT}/usr/$(get_libdir)/xorg/modules ]; then 403 if [ -e ${ROOT}/usr/$(get_libdir)/xorg/modules ]; then
476 rm -rf ${ROOT}/usr/$(get_libdir)/xorg/modules 404 rm -rf ${ROOT}/usr/$(get_libdir)/xorg/modules
477 fi 405 fi
406 fi
407}
408
409kdrive_setup() {
410 local card real_card disable_card kdrive_fbdev kdrive_vesa
411
412 einfo "Removing unused kdrive drivers ..."
413
414 # Some kdrive servers require fbdev and vesa
415 kdrive_fbdev="radeon neomagic sis siliconmotion"
416 # Some kdrive servers require just vesa
417 kdrive_vesa="chips mach64 mga nv glint r128 via"
418
419 for card in ${IUSE_VIDEO_CARDS}; do
420 real_card=${card#video_cards_}
421
422 # Differences between VIDEO_CARDS name and kdrive server name
423 real_card=${real_card/glint/pm2}
424 real_card=${real_card/radeon/ati}
425 real_card=${real_card/%nv/nvidia}
426 real_card=${real_card/siliconmotion/smi}
427 real_card=${real_card/%sis/sis300}
428
429 disable_card=0
430
431 # Check whether it's a valid kdrive server before we waste time
432 # on the rest of this
433 if ! grep -q -o "\b${real_card}\b" ${S}/hw/kdrive/Makefile.am; then
434 continue
435 fi
436
437 if ! use ${card}; then
438 if use x86; then
439 # Some kdrive servers require fbdev and vesa
440 for i in ${kdrive_fbdev}; do
441 if use video_cards_${i}; then
442 if [[ ${real_card} = fbdev ]] \
443 || [[ ${real_card} = vesa ]]; then
444 continue 2 # Don't disable
445 fi
446 fi
447 done
448
449 # Some kdrive servers require just vesa
450 for i in ${kdrive_vesa}; do
451 if use video_cards_${i}; then
452 if [[ ${real_card} = vesa ]]; then
453 continue 2 # Don't disable
454 fi
455 fi
456 done
457 fi
458 disable_card=1
459 # Bug #150052
460 # fbdev is the only VIDEO_CARDS setting that works on non-x86
461 elif ! use x86 \
462 && [[ ${real_card} != fbdev ]]; then
463 ewarn " $real_card does not work on your architecture; disabling."
464 disable_card=1
465 fi
466
467 if [[ $disable_card = 1 ]]; then
468 ebegin " ${real_card}"
469 sed -i \
470 -e "s:\b${real_card}\b::g" \
471 ${S}/hw/kdrive/Makefile.am \
472 || die "sed of ${real_card} failed"
473 eend
474 fi
475
476 done
477
478 # smi and via are the only things on line 2. If line 2 ends up blank,
479 # we need to get rid of the backslash at the end of line 1.
480 if ! use video_cards_siliconmotion && ! use video_cards_via; then
481 sed -i \
482 -e "s:^\(VESA_SUBDIRS.*\)\\\:\1:g" \
483 ${S}/hw/kdrive/Makefile.am
478 fi 484 fi
479} 485}
480 486
481dynamic_libgl_install() { 487dynamic_libgl_install() {
482 # next section is to setup the dynamic libGL stuff 488 # next section is to setup the dynamic libGL stuff

Legend:
Removed from v.1.19  
changed lines
  Added in v.1.20

  ViewVC Help
Powered by ViewVC 1.1.20