summaryrefslogtreecommitdiffstats
path: root/perl-install/printer.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install/printer.pm')
-rw-r--r--perl-install/printer.pm13
1 files changed, 12 insertions, 1 deletions
diff --git a/perl-install/printer.pm b/perl-install/printer.pm
index 13f5a3f50..0332b85b6 100644
--- a/perl-install/printer.pm
+++ b/perl-install/printer.pm
@@ -291,7 +291,7 @@ sub getinfo($) {
QUEUE => "lp",
SPOOLDIR => "/var/spool/lpd/lp",
DBENTRY => "PostScript",
- PAPERSIZE => "letter",
+ PAPERSIZE => "",
ASCII_TO_PS => undef,
CRLF => undef,
NUP => 1,
@@ -686,6 +686,17 @@ sub configure_queue($) {
print PRINTCAP "\t:if=$_->{IF}:\n";
print PRINTCAP "\n";
}
+
+ my $useUSB = 0;
+ foreach (values %{$entry->{configured}}) {
+ $useUSB ||= $_->{DEVICE} =~ /usb/;
+ }
+ if ($useUSB) {
+ my $f = "$prefix/etc/sysconfig/usb";
+ my %usb = getVarsFromSh($f);
+ $usb{PRINTER} = "yes";
+ setVarsInSh($f, \%usb);
+ }
}
sub restart_queue($) {