From 9bd682d8996ed9df687bc0b25d0eca56999ed4cb Mon Sep 17 00:00:00 2001 From: Ove Kaaven Date: Fri, 2 Jun 2000 20:20:27 +0000 Subject: [PATCH] Add "Unix drives" /tmp and ${HOME}, and Device and Filesystem statements, to autogenerated wine.conf. --- tools/wineconf | 28 ++++++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) diff --git a/tools/wineconf b/tools/wineconf index 83237a9e272..c516cb679eb 100755 --- a/tools/wineconf +++ b/tools/wineconf @@ -78,10 +78,12 @@ sub ReadFSTAB { my ($device, $mntpoint, $type, @rest) = split(' ', $_); if ($device !~ m"^/dev/fd") { if ($type eq "msdos" || $type eq "vfat") { - push(@::FatDrives, [$device, $mntpoint]); + push(@::FatDrives, [$device, $mntpoint, $type]); } - elsif ($type eq "iso9660" || ($device eq '/dev/cdrom' && $type eq 'auto') ) { - push(@::CdromDrives, [$device, $mntpoint]); + elsif ($type eq "iso9660" || + $mntpoint eq "/cdrom" || + ($device eq '/dev/cdrom' && $type eq 'auto') ) { + push(@::CdromDrives, [$device, $mntpoint, 'win95']); } } } @@ -91,14 +93,18 @@ sub ReadFSTAB { warn "cannot help you (yet)\n"; exit(1); } + push(@::UnixDrives, ['', '/tmp', 'hd']); + push(@::UnixDrives, ['', '${HOME}', 'network']); my $MagicDrive = 'C'; @::FatDrives = sort byDriveOrder @::FatDrives; @::CdromDrives = sort byCdOrder @::CdromDrives; foreach my $FatDrive (@::FatDrives) { print "[Drive $MagicDrive]\n"; my $MntPoint = $FatDrive->[1]; + my $FileSys = $FatDrive->[2]; print "Path=$MntPoint\n"; print "Type=hd\n"; + print "Filesystem=$FileSys\n"; print "\n"; &RegisterDrive($MagicDrive, $FatDrive); if(!&IsMounted($FatDrive->[0])) { @@ -109,13 +115,27 @@ sub ReadFSTAB { } foreach my $CdromDrive (@::CdromDrives) { print "[Drive $MagicDrive]\n"; + my $Device = $CdromDrive->[0]; my $MntPoint = $CdromDrive->[1]; + my $FileSys = $CdromDrive->[2]; print "Path=$MntPoint\n"; print "Type=cdrom\n"; + print "Device=$Device\n"; + print "Filesystem=$FileSys\n"; print "\n"; &RegisterDrive($MagicDrive, $CdromDrive); $MagicDrive++; } + foreach my $UnixDrive (@::UnixDrives) { + print "[Drive $MagicDrive]\n"; + my $MntPoint = $UnixDrive->[1]; + my $Type = $UnixDrive->[2]; + print "Path=$MntPoint\n"; + print "Type=$Type\n"; + print "Filesystem=win95\n"; + print "\n"; + $MagicDrive++; + } } sub FindWindowsDir { @@ -199,7 +219,7 @@ sub IsMounted { } sub RegisterDrive { - my($DOSdrive, $Drive) = @_; + my($DOSdrive, $Drive, $Type) = @_; $::DOS2Unix{$DOSdrive} = $Drive; $::Device2DOS{$Drive->[0]} = $DOSdrive; $::MntPoint2DOS{$Drive->[1]} = $DOSdrive; -- 2.11.4.GIT