Index: documentation/configuring.sgml
===================================================================
RCS file: /home/wine/wine/documentation/configuring.sgml,v
retrieving revision 1.25
diff -u -r1.25 configuring.sgml
--- documentation/configuring.sgml 19 Apr 2003 02:50:57 -0000 1.25
+++ documentation/configuring.sgml 20 Apr 2003 11:52:56 -0000
@@ -463,6 +463,16 @@
linkend="config-drive-main">Wine file system layer
configuration section.
+
+ "Automount" = "1"
+ This option is useful with some automounters (e.g.
+ "autofs" in Linux). These will only create the path
+ when the target is accessible, e.g. a medium is
+ inserted ("Type" = "cdrom|floppy") or the network share
+ reachable. If this option is present and non-zero then
+ the drive X is accepted with the given path/type/device
+ even when the "Path" is not existant during startup.
+
"GraphicsDriver" = "x11drv|ttydrv"
Sets the graphics driver to use for Wine output.
Index: documentation/samples/config
===================================================================
RCS file: /home/wine/wine/documentation/samples/config,v
retrieving revision 1.43
diff -u -r1.43 config
--- documentation/samples/config 7 Apr 2003 23:27:54 -0000 1.43
+++ documentation/samples/config 20 Apr 2003 11:52:56 -0000
@@ -21,6 +21,7 @@
;; - "msdos" for FAT16 (ugly, upgrading to VFAT driver strongly recommended)
;; DON'T use "unix" unless you intend to port programs using Winelib !
;; "Device"="/dev/xx" (only if you want to allow raw device access)
+;; "Automount"="x" "1"= Drive is Automounted by native file system
;;
[Drive A]
"Path" = "/mnt/fd0"
@@ -29,6 +30,7 @@
"Filesystem" = "win95"
"Serial" = "87654321"
"Device" = "/dev/fd0"
+;"Automount" = "1"
[Drive C]
"Path" = "/c"
Index: files/drive.c
===================================================================
RCS file: /home/wine/wine/files/drive.c,v
retrieving revision 1.89
diff -u -r1.89 drive.c
--- files/drive.c 19 Apr 2003 02:48:34 -0000 1.89
+++ files/drive.c 20 Apr 2003 11:53:00 -0000
@@ -204,6 +204,7 @@
static const WCHAR ReadVolInfoW[] = {'R','e','a','d','V','o','l','I','n','f','o',0};
static const WCHAR FailReadOnlyW[] = {'F','a','i','l','R','e','a','d','O','n','l','y',0};
static const WCHAR driveC_labelW[] = {'D','r','i','v','e',' ','C',' ',' ',' ',' ',0};
+ static const WCHAR AutoMountW[] = {'A','u','t','o','M','o','u','n','t',0};
for (i = 0, drive = DOSDrives; i < MAX_DOS_DRIVES; i++, name[6]++, drive++)
{
@@ -235,15 +236,24 @@
WideCharToMultiByte(drive->codepage, 0, path, -1, drive->root + strlen(drive->root), len, NULL, NULL);
}
- if (stat( drive->root, &drive_stat_buffer ))
+ if (stat( drive->root, &drive_stat_buffer ))
{
- MESSAGE("Could not stat %s (%s), ignoring drive %c:\n",
- drive->root, strerror(errno), 'A' + i);
- HeapFree( GetProcessHeap(), 0, drive->root );
- drive->root = NULL;
- continue;
+ if (PROFILE_GetWineIniBool (name, AutoMountW, 0))
+ {
+ MESSAGE("Could not stat %s (%s), keeping automount drive %c:\n",
+ drive->root, strerror(errno), 'A' + i);
+ /* never match in DRIVE_FindDriveRoot */
+ drive_stat_buffer.st_dev = 0;
+ drive_stat_buffer.st_ino = 0;
+ }else{
+ MESSAGE("Could not stat %s (%s), ignoring drive %c:\n",
+ drive->root, strerror(errno), 'A' + i);
+ HeapFree( GetProcessHeap(), 0, drive->root );
+ drive->root = NULL;
+ continue;
+ }
}
- if (!S_ISDIR(drive_stat_buffer.st_mode))
+ else if (!S_ISDIR(drive_stat_buffer.st_mode))
{
MESSAGE("%s is not a directory, ignoring drive %c:\n",
drive->root, 'A' + i );