summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorNicolas Planel <nplanel@mandriva.com>2003-09-10 18:59:48 +0000
committerNicolas Planel <nplanel@mandriva.com>2003-09-10 18:59:48 +0000
commit4725e01829626f0710de17df485e33eb686ac637 (patch)
tree609f54559de3f9a8bdacd1be3b48c7f2872f4be5 /perl-install
parent7c7b6303cb8c20c466ef4b81d030901997d6593a (diff)
downloaddrakx-4725e01829626f0710de17df485e33eb686ac637.tar
drakx-4725e01829626f0710de17df485e33eb686ac637.tar.gz
drakx-4725e01829626f0710de17df485e33eb686ac637.tar.bz2
drakx-4725e01829626f0710de17df485e33eb686ac637.tar.xz
drakx-4725e01829626f0710de17df485e33eb686ac637.zip
fixup default fglrx config to be included in Device Section. thanks pixel
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/Xconfig/card.pm103
1 files changed, 52 insertions, 51 deletions
diff --git a/perl-install/Xconfig/card.pm b/perl-install/Xconfig/card.pm
index f7e5b7c6d..3a5f9cd9b 100644
--- a/perl-install/Xconfig/card.pm
+++ b/perl-install/Xconfig/card.pm
@@ -98,6 +98,12 @@ sub from_raw_X {
sub to_raw_X {
my ($card, $raw_X) = @_;
+ #- Specific ATI fglrx driver default options
+ if ($card->{Driver} eq 'fglrx') {
+ # $default_ATI_fglrx_config need to be move in proprietary ?
+ $card->{raw_LINES} ||= default_ATI_fglrx_config();
+ }
+
$raw_X->set_devices($card, @{$card->{cards} || []});
$raw_X->{xfree4}->get_ServerLayout->{Xinerama} = { commented => !$card->{Xinerama}, Option => 1 }
@@ -117,14 +123,10 @@ sub to_raw_X {
$raw_X->{xfree4}->add_Section('DRI', { Mode => { val => '0666' } }) if $card->{use_DRI_GLX};
$raw_X->{xfree4}->remove_load_module('v4l') if $card->{use_DRI_GLX} && $card->{Driver} eq 'r128';
-
- #- Specific ATI fglrx driver default options
- if ($card->{Driver} eq 'fglrx') {
- # $default_ATI_fglrx_config need to be move in proprietary ?
- $card->{raw_LINES} ||= $default_ATI_fglrx_config;
- }
}
+sub default_ATI_fglrx_config { our $default_ATI_fglrx_config }
+
sub probe() {
#-for Pixel tests
#- my @c = { driver => 'Card:Matrox Millennium G400 DualHead', description => 'Matrox|Millennium G400 Dual HeadCard' };
@@ -615,63 +617,62 @@ sub readCardsDB {
our $default_ATI_fglrx_config = <<'END';
# === disable PnP Monitor ===
- #Option "NoDDC"
+#Option "NoDDC"
# === disable/enable XAA/DRI ===
- Option "no_accel" "no"
- Option "no_dri" "no"
+Option "no_accel" "no"
+Option "no_dri" "no"
# === FireGL DDX driver module specific settings ===
# === Screen Management ===
- Option "DesktopSetup" "0x00000000"
- Option "MonitorLayout" "AUTO, AUTO"
- Option "IgnoreEDID" "off"
- Option "HSync2" "unspecified"
- Option "VRefresh2" "unspecified"
- Option "ScreenOverlap" "0"
+Option "DesktopSetup" "0x00000000"
+Option "MonitorLayout" "AUTO, AUTO"
+Option "IgnoreEDID" "off"
+Option "HSync2" "unspecified"
+Option "VRefresh2" "unspecified"
+Option "ScreenOverlap" "0"
# === TV-out Management ===
- Option "NoTV" "yes"
- Option "TVStandard" "NTSC-M"
- Option "TVHSizeAdj" "0"
- Option "TVVSizeAdj" "0"
- Option "TVHPosAdj" "0"
- Option "TVVPosAdj" "0"
- Option "TVHStartAdj" "0"
- Option "TVColorAdj" "0"
- Option "GammaCorrectionI" "0x00000000"
- Option "GammaCorrectionII" "0x00000000"
+Option "NoTV" "yes"
+Option "TVStandard" "NTSC-M"
+Option "TVHSizeAdj" "0"
+Option "TVVSizeAdj" "0"
+Option "TVHPosAdj" "0"
+Option "TVVPosAdj" "0"
+Option "TVHStartAdj" "0"
+Option "TVColorAdj" "0"
+Option "GammaCorrectionI" "0x00000000"
+Option "GammaCorrectionII" "0x00000000"
# === OpenGL specific profiles/settings ===
- Option "Capabilities" "0x00000000"
+Option "Capabilities" "0x00000000"
# === Video Overlay for the Xv extension ===
- Option "VideoOverlay" "on"
+Option "VideoOverlay" "on"
# === OpenGL Overlay ===
# Note: When OpenGL Overlay is enabled, Video Overlay
# will be disabled automatically
- Option "OpenGLOverlay" "off"
- Option "CenterMode" "off"
+Option "OpenGLOverlay" "off"
+Option "CenterMode" "off"
# === QBS Support ===
- Option "Stereo" "off"
- Option "StereoSyncEnable" "1"
+Option "Stereo" "off"
+Option "StereoSyncEnable" "1"
# === Misc Options ===
- Option "UseFastTLS" "0"
- Option "BlockSignalsOnLock" "on"
-# Note : DON'T ENABLE UseInternalAGPGART
- Option "UseInternalAGPGART" "no"
- Option "ForceGenericCPU" "no"
+Option "UseFastTLS" "0"
+Option "BlockSignalsOnLock" "on"
+Option "UseInternalAGPGART" "no"
+Option "ForceGenericCPU" "no"
# === FSAA ===
- Option "FSAAScale" "1"
- Option "FSAADisableGamma" "no"
- Option "FSAACustomizeMSPos" "no"
- Option "FSAAMSPosX0" "0.000000"
- Option "FSAAMSPosY0" "0.000000"
- Option "FSAAMSPosX1" "0.000000"
- Option "FSAAMSPosY1" "0.000000"
- Option "FSAAMSPosX2" "0.000000"
- Option "FSAAMSPosY2" "0.000000"
- Option "FSAAMSPosX3" "0.000000"
- Option "FSAAMSPosY3" "0.000000"
- Option "FSAAMSPosX4" "0.000000"
- Option "FSAAMSPosY4" "0.000000"
- Option "FSAAMSPosX5" "0.000000"
- Option "FSAAMSPosY5" "0.000000"
+Option "FSAAScale" "1"
+Option "FSAADisableGamma" "no"
+Option "FSAACustomizeMSPos" "no"
+Option "FSAAMSPosX0" "0.000000"
+Option "FSAAMSPosY0" "0.000000"
+Option "FSAAMSPosX1" "0.000000"
+Option "FSAAMSPosY1" "0.000000"
+Option "FSAAMSPosX2" "0.000000"
+Option "FSAAMSPosY2" "0.000000"
+Option "FSAAMSPosX3" "0.000000"
+Option "FSAAMSPosY3" "0.000000"
+Option "FSAAMSPosX4" "0.000000"
+Option "FSAAMSPosY4" "0.000000"
+Option "FSAAMSPosX5" "0.000000"
+Option "FSAAMSPosY5" "0.000000"
END
1;
opt">) = @_; $su = $su eq "su"; require c; if ($ENV{DISPLAY} && system('/usr/X11R6/bin/xtest') == 0) { if ($su) { $ENV{PATH} = "/sbin:/usr/sbin:$ENV{PATH}"; if ($>) { exec("kdesu", "-c", "$0 @ARGV") or die _("kdesu missing"); } } eval { require interactive_gtk }; !$@ and return interactive_gtk->new; } if ($su && $>) { die "you must be root to run this program"; } require 'log.pm'; undef *log::l; *log::l = sub {}; # otherwise, it will bother us :( require interactive_newt; interactive_newt->new; } sub enter_console {} sub leave_console {} sub suspend {} sub resume {} sub end {} sub exit { exit($_[0]) } #-###################################################################################### #- Interactive functions #-###################################################################################### sub ask_warn { my ($o, $title, $message) = @_; local $::isWizard=0; ask_from_listf_no_check($o, $title, $message, undef, [ _("Ok") ]); } sub ask_yesorno { my ($o, $title, $message, $def, $help) = @_; ask_from_list_($o, $title, $message, [ __("Yes"), __("No") ], $def ? "Yes" : "No", $help) eq "Yes"; } sub ask_okcancel { my ($o, $title, $message, $def, $help) = @_; if ($::isWizard) { $::no_separator = 1; $o->ask_from_entries_refH_powered_no_check({ title => $title, messages => $message, focus_cancel => !$def }); } else { ask_from_list_($o, $title, $message, [ __("Ok"), __("Cancel") ], $def ? "Ok" : "Cancel", $help) eq "Ok"; } } sub ask_from_list { my ($o, $title, $message, $l, $def, $help) = @_; ask_from_listf($o, $title, $message, undef, $l, $def, $help); } sub ask_from_list_ { my ($o, $title, $message, $l, $def, $help) = @_; ask_from_listf($o, $title, $message, sub { translate($_[0]) }, $l, $def, $help); } sub ask_from_listf_ { my ($o, $title, $message, $f, $l, $def, $help) = @_; ask_from_listf($o, $title, $message, sub { translate($f->(@_)) }, $l, $def, $help); } sub ask_from_listf { my ($o, $title, $message, $f, $l, $def, $help) = @_; @$l == 0 and die 'ask_from_list: empty list'; @$l == 1 and return $l->[0]; goto &ask_from_listf_no_check; } sub ask_from_listf_no_check { my ($o, $title, $message, $f, $l, $def, $help) = @_; if (@$l <= 2 && !$::isWizard) { my $ret = eval { ask_from_entries_refH_powered_no_check($o, { title => $title, messages => $message, ok => $l->[0] && may_apply($f, $l->[0]), if_($l->[1], cancel => may_apply($f, $l->[1]), focus_cancel => $def eq $l->[1]) }, [] ) ? $l->[0] : $l->[1]; }; die if $@ && $@ !~ /^wizcancel/; $@ ? undef : $ret; } else { ask_from_entries_refH($o, $title, $message, [ { val => \$def, type => 'list', list => $l, help => $help, format => $f } ]) && $def; } } sub ask_from_treelist { my ($o, $title, $message, $separator, $l, $def) = @_; ask_from_treelistf($o, $title, $message, $separator, undef, $l, $def); } sub ask_from_treelist_ { my ($o, $title, $message, $separator, $l, $def) = @_;