RE: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-10 Thread Ben A L Jemmett
Scott Ritchie wrote:
> Francois Gouget wrote:
> > It has been abundantly proven that the system drive is not always the c:

> > drive on Windows (via comments and our conformance test results). So 
> > it is not Wine's place to force the user to use c: as the system drive.
>
> It is on vista though, and I suspect later Windows will be as well. 

I'm not sure you're right about that; this is a copy and paste from one of
my Vista machines:

: Microsoft Windows [Version 6.0.6000]
: Copyright (c) 2006 Microsoft Corporation.  All rights reserved.
: 
: H:\Users\Administrator>echo %systemroot%
: H:\Windows
: 
: H:\Users\Administrator>

[On that machine, C: is the system volume of an XP 64-bit installation, and
E: is where Server 2003 R2 is installed.  I haven't a clue where F and G
went, maybe it skipped them when it saw the Linux partitions!]

Regards,
Ben A L Jemmett.
http://flatpack.microwavepizza.co.uk/





Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-09 Thread Scott Ritchie
Francois Gouget wrote:
> On Sun, 8 Mar 2009, Ben Klein wrote:
> 
>> This patch should fix 17619 for new wineprefixes and other cases where C: is
>> created. The logic is that C: should never be registered as a network share,
>> which is the issue in 17619. It was suggested as a response to a previous 
>> patch
>> that this should be relative to %SYSTEM% or something along those lines, but 
>> I
>> believe that C: is a true special case, similar to how A: and B: are always
>> reserved for floppy drives.
> 
> The patch still hardocdes the c: drive so it is incorrect.
> 
> It has been abundantly proven that the system drive is not always the c: 
> drive on Windows (via comments and our conformance test results). So it 
> is not Wine's place to force the user to use c: as the system drive.
> 
> 

It is on vista though, and I suspect later Windows will be as well.

Thanks,
Scott Ritchie




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-09 Thread Ben Klein
2009/3/9 Francois Gouget :
> On Sun, 8 Mar 2009, Ben Klein wrote:
>
>> This patch should fix 17619 for new wineprefixes and other cases where C: is
>> created. The logic is that C: should never be registered as a network share,
>> which is the issue in 17619. It was suggested as a response to a previous 
>> patch
>> that this should be relative to %SYSTEM% or something along those lines, but 
>> I
>> believe that C: is a true special case, similar to how A: and B: are always
>> reserved for floppy drives.
>
> The patch still hardocdes the c: drive so it is incorrect.
>
> It has been abundantly proven that the system drive is not always the c:
> drive on Windows (via comments and our conformance test results). So it
> is not Wine's place to force the user to use c: as the system drive.

OK, so let's not hard-code C, but this still doesn't answer the real
question. Should Wine enforce DRIVE_FIXED on %SystemDrive%:?




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-09 Thread Francois Gouget
On Sun, 8 Mar 2009, Ben Klein wrote:

> This patch should fix 17619 for new wineprefixes and other cases where C: is
> created. The logic is that C: should never be registered as a network share,
> which is the issue in 17619. It was suggested as a response to a previous 
> patch
> that this should be relative to %SYSTEM% or something along those lines, but I
> believe that C: is a true special case, similar to how A: and B: are always
> reserved for floppy drives.

The patch still hardocdes the c: drive so it is incorrect.

It has been abundantly proven that the system drive is not always the c: 
drive on Windows (via comments and our conformance test results). So it 
is not Wine's place to force the user to use c: as the system drive.


-- 
Francois Gouget   http://fgouget.free.fr/
  Linux: Because rebooting is for adding new hardware




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread Ben Klein
2009/3/9 Scott Ritchie :
> Ben Klein wrote:
>> 2009/3/8 Scott Ritchie :
>>> David Gerard wrote:
 2009/3/8 King InuYasha :

> Drive C: is not necessarily the truly central drive. I have seen Windows
> installs that installed on D: and have C: as a permanently mounted network
> share. To assume that drive C: is always what it is... is blasphemy.
> However, Wine does make this assumption, and probably the patch would be
> appropriate. Just throwing that out there. However, I have also seen wine
> installs onto a network where the WINEPREFIX is a network share so that
> multiple people can use the same program.
 This is true. I've seen a Windows box at work which has the system on
 the E: drive and no C: drive at all. WHAT.

 That said, is there any program in the world that would balk at
 installing on C:
>>> No, and Vista now defaults to always reassigning the system drive to C:\
>>>  - it's not bad for us to copy that behavior.
>>
>> ALL versions of Windows *default* to C: being the first (primary)
>> harddisk partition detected, and being the partition where the system
>> gets installed. Configurations that don't have C: have been
>> specifically configured as such, which is still possible with Wine.
>>
>> What I'm unsure of, but suspect is so, is that it is impossible, on
>> native Windows (XP, Vista, possibly server versions too?), for C: to
>> be a network share. I'm sure it's true of Win9x :)
>
> This isn't strictly true with XP and earlier: if you had other drives
> (even sometimes card readers and USB sticks) available at install time,
> often Windows would install itself onto an E:\ drive.  Some systems
> would run into trouble after adding a disk because Windows would
> reassign the new disk to C:\ and the old install would move off C:\,
> breaking some apps.

In cases like this, doesn't the installer think it's installing on to
C:, but then when the system boots up (with complete USB mass storage
drivers, for example), the driver order could change? I know Win9x in
particular involved nasty drive ordering rules (or lack thereof) if
you insert a new harddrive or USB stick - I had a lot of fun setting
my CD-ROM drive to X: so it wouldn't keep moving around and confusing
games :)

I'm also fully aware of drive remapping in WinXP, and that "system"
drive doesn't have to be C:, but as it has been noted a lot of
installers assume C: is at least available, and in some cases assume
that's where "Program Files" and "Windows" directories are.

> On Vista, however, when you add that new disk Windows keeps its system
> drive as C:\, even if the new disk is earlier in priority.  You can also
> have multiple installs of Windows on a system, and while the XP ones may
> be happy to boot from E:\, the Vista ones will also rename it to C:\ for
> you once inside.

If I read this right, Vista will boot off just about any partition,
but the partition it boots off will be mapped to C: before anything
else. That sounds like C: will always be a local disk to me! :)

> So, that said, I'm not sure it's possible to have a non C:\ drive as a
> system drive on Vista.  If so, it certainly requires more configuring
> than XP does, where it would happen on accident.
>
> Thanks,
> Scott Ritchie

2009/3/9 Paul Chitescu :
> Having the C: drive always present and always local is a good idea and will
> save users _lots_ of trouble.

And Wine already spends quite some effort in ensuring that drive_c
exists, from what I can see. There also appears to be a lot of
hardcoded references to C: in the registry. I've attached an analysis.
Before you ask, yes this was a completely fresh wineprefix created
with 1.1.16.


c_drive_occurance.txt.lzma
Description: Binary data



Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread Steve Brown

On Sun, 8 Mar 2009, David Gerard wrote:


2009/3/8 King InuYasha :


Drive C: is not necessarily the truly central drive. I have seen Windows
installs that installed on D: and have C: as a permanently mounted network
share. To assume that drive C: is always what it is... is blasphemy.
However, Wine does make this assumption, and probably the patch would be
appropriate. Just throwing that out there. However, I have also seen wine
installs onto a network where the WINEPREFIX is a network share so that
multiple people can use the same program.



This is true. I've seen a Windows box at work which has the system on
the E: drive and no C: drive at all. WHAT.

That said, is there any program in the world that would balk at
installing on C:?


I know of several pieces of software I have to deal with that refuse to 
install in such a situation... I've gotten fairly adept at forcing XP to 
call the drive it installs on C: instead of whatever the installer really 
wants to call it -- sadly, that sometimes involves crashing the installer, 
"deleting" the offending partition (while carefully noting the cylinders 
it contains), then creating a partition for XP to install into that 
doesn't include those cylinders.  Bleah!


Steve Brown
sbro...@umbc.edu




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread Scott Ritchie
Ben Klein wrote:
> 2009/3/8 Scott Ritchie :
>> David Gerard wrote:
>>> 2009/3/8 King InuYasha :
>>>
 Drive C: is not necessarily the truly central drive. I have seen Windows
 installs that installed on D: and have C: as a permanently mounted network
 share. To assume that drive C: is always what it is... is blasphemy.
 However, Wine does make this assumption, and probably the patch would be
 appropriate. Just throwing that out there. However, I have also seen wine
 installs onto a network where the WINEPREFIX is a network share so that
 multiple people can use the same program.
>>> This is true. I've seen a Windows box at work which has the system on
>>> the E: drive and no C: drive at all. WHAT.
>>>
>>> That said, is there any program in the world that would balk at
>>> installing on C:
>> No, and Vista now defaults to always reassigning the system drive to C:\
>>  - it's not bad for us to copy that behavior.
> 
> ALL versions of Windows *default* to C: being the first (primary)
> harddisk partition detected, and being the partition where the system
> gets installed. Configurations that don't have C: have been
> specifically configured as such, which is still possible with Wine.
> 
> What I'm unsure of, but suspect is so, is that it is impossible, on
> native Windows (XP, Vista, possibly server versions too?), for C: to
> be a network share. I'm sure it's true of Win9x :)
> 
> 

This isn't strictly true with XP and earlier: if you had other drives
(even sometimes card readers and USB sticks) available at install time,
often Windows would install itself onto an E:\ drive.  Some systems
would run into trouble after adding a disk because Windows would
reassign the new disk to C:\ and the old install would move off C:\,
breaking some apps.

On Vista, however, when you add that new disk Windows keeps its system
drive as C:\, even if the new disk is earlier in priority.  You can also
have multiple installs of Windows on a system, and while the XP ones may
be happy to boot from E:\, the Vista ones will also rename it to C:\ for
you once inside.

So, that said, I'm not sure it's possible to have a non C:\ drive as a
system drive on Vista.  If so, it certainly requires more configuring
than XP does, where it would happen on accident.

Thanks,
Scott Ritchie




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread Paul Chitescu
On Sunday 08 March 2009 02:43:43 King InuYasha wrote:
> Drive C: is not necessarily the truly central drive. I have seen Windows
> installs that installed on D: and have C: as a permanently mounted network
> share. To assume that drive C: is always what it is... is blasphemy.
> However, Wine does make this assumption, and probably the patch would be
> appropriate. Just throwing that out there. However, I have also seen wine
> installs onto a network where the WINEPREFIX is a network share so that
> multiple people can use the same program.
> [...]

Having the C: drive always present and always local is a good idea and will 
save users _lots_ of trouble.

I have (or had - not booted it in eons) a Windows 2000 server that doesn't 
have a C: but only a F: (default install of W2K on an older Compaq with SCSI 
disk and some existing partitions) and many applications failed to install, 
including several Microsoft ones.




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread King InuYasha
Also, Drive A: and B: can be used for network shares if you don't have a
floppy drive, but this will break floppy drive support. In general, it isn't
a good idea to allow Drive A: to be a network share, but since few modern
machines have a 5 1/4" floppy drive anymore, Drive B: is up for grabs as a
network device fairly safely.

On Sun, Mar 8, 2009 at 6:04 AM, King InuYasha  wrote:

> It is definitely possible for Drive C: to be a network share on all
> versions of Windows starting from Windows 95. This does not exempt Windows
> XP/Vista/2k3/2k8. In fact, a public library in Indiana that I used to go to
> before I moved has all their machines set up this way. It takes a LOT of
> tweaking to make it work properly, because some applications expect Windows
> on Drive C:, but it is possible to do it.
>
>
> On Sun, Mar 8, 2009 at 4:27 AM, Ben Klein  wrote:
>
>> 2009/3/8 Scott Ritchie :
>> > David Gerard wrote:
>> >> 2009/3/8 King InuYasha :
>> >>
>> >>> Drive C: is not necessarily the truly central drive. I have seen
>> Windows
>> >>> installs that installed on D: and have C: as a permanently mounted
>> network
>> >>> share. To assume that drive C: is always what it is... is blasphemy.
>> >>> However, Wine does make this assumption, and probably the patch would
>> be
>> >>> appropriate. Just throwing that out there. However, I have also seen
>> wine
>> >>> installs onto a network where the WINEPREFIX is a network share so
>> that
>> >>> multiple people can use the same program.
>> >>
>> >> This is true. I've seen a Windows box at work which has the system on
>> >> the E: drive and no C: drive at all. WHAT.
>> >>
>> >> That said, is there any program in the world that would balk at
>> >> installing on C:
>> >
>> > No, and Vista now defaults to always reassigning the system drive to C:\
>> >  - it's not bad for us to copy that behavior.
>>
>> ALL versions of Windows *default* to C: being the first (primary)
>> harddisk partition detected, and being the partition where the system
>> gets installed. Configurations that don't have C: have been
>> specifically configured as such, which is still possible with Wine.
>>
>> What I'm unsure of, but suspect is so, is that it is impossible, on
>> native Windows (XP, Vista, possibly server versions too?), for C: to
>> be a network share. I'm sure it's true of Win9x :)
>>
>>
>>
>



Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread King InuYasha
It is definitely possible for Drive C: to be a network share on all versions
of Windows starting from Windows 95. This does not exempt Windows
XP/Vista/2k3/2k8. In fact, a public library in Indiana that I used to go to
before I moved has all their machines set up this way. It takes a LOT of
tweaking to make it work properly, because some applications expect Windows
on Drive C:, but it is possible to do it.

On Sun, Mar 8, 2009 at 4:27 AM, Ben Klein  wrote:

> 2009/3/8 Scott Ritchie :
> > David Gerard wrote:
> >> 2009/3/8 King InuYasha :
> >>
> >>> Drive C: is not necessarily the truly central drive. I have seen
> Windows
> >>> installs that installed on D: and have C: as a permanently mounted
> network
> >>> share. To assume that drive C: is always what it is... is blasphemy.
> >>> However, Wine does make this assumption, and probably the patch would
> be
> >>> appropriate. Just throwing that out there. However, I have also seen
> wine
> >>> installs onto a network where the WINEPREFIX is a network share so that
> >>> multiple people can use the same program.
> >>
> >> This is true. I've seen a Windows box at work which has the system on
> >> the E: drive and no C: drive at all. WHAT.
> >>
> >> That said, is there any program in the world that would balk at
> >> installing on C:
> >
> > No, and Vista now defaults to always reassigning the system drive to C:\
> >  - it's not bad for us to copy that behavior.
>
> ALL versions of Windows *default* to C: being the first (primary)
> harddisk partition detected, and being the partition where the system
> gets installed. Configurations that don't have C: have been
> specifically configured as such, which is still possible with Wine.
>
> What I'm unsure of, but suspect is so, is that it is impossible, on
> native Windows (XP, Vista, possibly server versions too?), for C: to
> be a network share. I'm sure it's true of Win9x :)
>
>
>



Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread Ben Klein
2009/3/8 Scott Ritchie :
> David Gerard wrote:
>> 2009/3/8 King InuYasha :
>>
>>> Drive C: is not necessarily the truly central drive. I have seen Windows
>>> installs that installed on D: and have C: as a permanently mounted network
>>> share. To assume that drive C: is always what it is... is blasphemy.
>>> However, Wine does make this assumption, and probably the patch would be
>>> appropriate. Just throwing that out there. However, I have also seen wine
>>> installs onto a network where the WINEPREFIX is a network share so that
>>> multiple people can use the same program.
>>
>> This is true. I've seen a Windows box at work which has the system on
>> the E: drive and no C: drive at all. WHAT.
>>
>> That said, is there any program in the world that would balk at
>> installing on C:
>
> No, and Vista now defaults to always reassigning the system drive to C:\
>  - it's not bad for us to copy that behavior.

ALL versions of Windows *default* to C: being the first (primary)
harddisk partition detected, and being the partition where the system
gets installed. Configurations that don't have C: have been
specifically configured as such, which is still possible with Wine.

What I'm unsure of, but suspect is so, is that it is impossible, on
native Windows (XP, Vista, possibly server versions too?), for C: to
be a network share. I'm sure it's true of Win9x :)




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-08 Thread Scott Ritchie
David Gerard wrote:
> 2009/3/8 King InuYasha :
> 
>> Drive C: is not necessarily the truly central drive. I have seen Windows
>> installs that installed on D: and have C: as a permanently mounted network
>> share. To assume that drive C: is always what it is... is blasphemy.
>> However, Wine does make this assumption, and probably the patch would be
>> appropriate. Just throwing that out there. However, I have also seen wine
>> installs onto a network where the WINEPREFIX is a network share so that
>> multiple people can use the same program.
> 
> 
> This is true. I've seen a Windows box at work which has the system on
> the E: drive and no C: drive at all. WHAT.
> 
> That said, is there any program in the world that would balk at
> installing on C:?
> 
> 

No, and Vista now defaults to always reassigning the system drive to C:\
 - it's not bad for us to copy that behavior.

Thanks,
Scott Ritchie




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-07 Thread Austin English
On Sat, Mar 7, 2009 at 6:18 PM, Ben Klein  wrote:
> This patch should fix 17619 for new wineprefixes and other cases where C: is
> created. The logic is that C: should never be registered as a network share,
> which is the issue in 17619. It was suggested as a response to a previous 
> patch
> that this should be relative to %SYSTEM% or something along those lines, but I
> believe that C: is a true special case, similar to how A: and B: are always
> reserved for floppy drives.

I've got a box at work that has B: used for a network drive.

-- 
-Austin




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-07 Thread David Gerard
2009/3/8 King InuYasha :

> Drive C: is not necessarily the truly central drive. I have seen Windows
> installs that installed on D: and have C: as a permanently mounted network
> share. To assume that drive C: is always what it is... is blasphemy.
> However, Wine does make this assumption, and probably the patch would be
> appropriate. Just throwing that out there. However, I have also seen wine
> installs onto a network where the WINEPREFIX is a network share so that
> multiple people can use the same program.


This is true. I've seen a Windows box at work which has the system on
the E: drive and no C: drive at all. WHAT.

That said, is there any program in the world that would balk at
installing on C:?


- d.




Re: [PATCH] [RFC] Make drive C always a "Local disk"

2009-03-07 Thread King InuYasha
Drive C: is not necessarily the truly central drive. I have seen Windows
installs that installed on D: and have C: as a permanently mounted network
share. To assume that drive C: is always what it is... is blasphemy.
However, Wine does make this assumption, and probably the patch would be
appropriate. Just throwing that out there. However, I have also seen wine
installs onto a network where the WINEPREFIX is a network share so that
multiple people can use the same program.

On Sat, Mar 7, 2009 at 6:18 PM, Ben Klein  wrote:

> This patch should fix 17619 for new wineprefixes and other cases where C:
> is
> created. The logic is that C: should never be registered as a network
> share,
> which is the issue in 17619. It was suggested as a response to a previous
> patch
> that this should be relative to %SYSTEM% or something along those lines,
> but I
> believe that C: is a true special case, similar to how A: and B: are always
> reserved for floppy drives.
>
> I'm not sure if this is the right way to go, so I'd like comments :) Thanks
>
>
>
>



[PATCH] [RFC] Make drive C always a "Local disk"

2009-03-07 Thread Ben Klein
This patch should fix 17619 for new wineprefixes and other cases where C: is
created. The logic is that C: should never be registered as a network share,
which is the issue in 17619. It was suggested as a response to a previous patch
that this should be relative to %SYSTEM% or something along those lines, but I
believe that C: is a true special case, similar to how A: and B: are always
reserved for floppy drives.

I'm not sure if this is the right way to go, so I'd like comments :) Thanks
From 5bdf77a254e7a18f3eed124caa10d73b48b29a0b Mon Sep 17 00:00:00 2001
From: Ben Klein 
Date: Sun, 8 Mar 2009 11:09:23 +1100
Subject: Make drive C always a "Local disk"

This patch should fix 17619 for new wineprefixes and other cases where C: is
created. The logic is that C: should never be registered as a network share,
which is the issue in 17619. It was suggested as a response to a previous patch
that this should be relative to %SYSTEM% or something along those lines, but I
believe that C: is a true special case, similar to how A: and B: are always
reserved for floppy drives.
---
 dlls/mountmgr.sys/mountmgr.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/mountmgr.sys/mountmgr.c b/dlls/mountmgr.sys/mountmgr.c
index 00112b9..6ede7eb 100644
--- a/dlls/mountmgr.sys/mountmgr.c
+++ b/dlls/mountmgr.sys/mountmgr.c
@@ -254,7 +254,7 @@ static NTSTATUS define_unix_drive( const void *in_buff, 
SIZE_T insize )
 
 if (input->type != DRIVE_NO_ROOT_DIR)
 {
-enum device_type type = DEVICE_UNKNOWN;
+enum device_type type = (letter == c) ? DEVICE_FIXED : DEVICE_UNKNOWN;
 
 TRACE( "defining %c: dev %s mount %s type %u\n",
letter, debugstr_a(device), debugstr_a(mount_point), 
input->type );
-- 
1.6.1.3