delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/04/19/23:54:18

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <3CC0E6EA.2090107@ece.gatech.edu>
Date: Fri, 19 Apr 2002 23:56:26 -0400
From: Charles Wilson <cwilson AT ece DOT gatech DOT edu>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.4) Gecko/20011019 Netscape6/6.2
X-Accept-Language: en-us
MIME-Version: 1.0
To: Andre Bleau <bleau AT igb DOT umontreal DOT ca>, cygwin AT cygwin DOT com
Subject: Re: Bug with /cygdrive/X in binmode
References: <4 DOT 3 DOT 2 DOT 7 DOT 0 DOT 20020419162200 DOT 0203d918 AT irispavp DOT igb DOT umontreal DOT ca>

mount -s -b --change-cygdrive-prefix cygdrive
mount -u -b --change-cygdrive-prefix cygdrive

man mount is your friend (although it doesn't explicitly describe how to 
use the --change-cygdrive-prefix option to change the mode from text to 
binary without actually changing the prefix...

--Chuck


Andre Bleau wrote:

> I'm having trouble mounting some of my drives in binmode. As an ordinary 
> user, I tried:
> 
> mount -b -f E: /cygdrive/e
> 
> To mount the E: drive in binmode. Mount reports:
> 
> $ mount
> C:\cygwin\bin on /usr/bin type system (textmode)
> C:\cygwin\lib on /usr/lib type system (textmode)
> C:\cygwin on / type system (textmode)
> E: on /cygdrive/e type user (binmode)
> c: on /cygdrive/c type user (textmode,noumount)
> d: on /cygdrive/d type user (textmode,noumount)
> z: on /cygdrive/z type user (textmode,noumount)
> 
> Writing to files under /cydrive/e still converts \n to \r\n. I used the 
> following test program (testNL.c):
> 
> #include <stdio.h>
> main ()
> {
> FILE *fd;
> fd = fopen("HelloWorld", "w");
> fprintf(fd, "Hello world\n");
> }
> 
> Compiled with:
> 
> gcc -g testNL.c -o testNL
> 
> Test results:
> 
> cd /cygdrive/e/Partage/Images
> testNL
> od -c HelloWorld
> 0000000   H   e   l   l   o       w   o   r   l   d  \r  \n
> 0000015
> 
> However, creating another binary mount point, things work as they should:
> 
> mkdir /Partage
> mount -b  E:/Partage /Partage
> $ mount
> C:\cygwin\bin on /usr/bin type system (textmode)
> C:\cygwin\lib on /usr/lib type system (textmode)
> E:\Partage on /Partage type user (binmode)
> C:\cygwin on / type system (textmode)
> E: on /cygdrive/e type user (binmode)
> c: on /cygdrive/c type user (textmode,noumount)
> d: on /cygdrive/d type user (textmode,noumount)
> z: on /cygdrive/z type user (textmode,noumount)
> 
> cd /Partage/Images
> testNL
> od -c HelloWorld
> 0000000   H   e   l   l   o       w   o   r   l   d  \n
> 0000014
> 
> It seems that users cannot remount their drives in binmode but only 
> subdirectories.
> 
> cygwin version is 1.3.10-1
> 
> 
> André Bleau, ing., associé de recherche
> bleau AT igb DOT umontreal DOT ca
> 
> Laboratoire de recherche en imagerie et orthopédie (LIO)
> École de technologie supérieure (ETS)
> 
> 
> -- 
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> Bug reporting:         http://cygwin.com/bugs.html
> Documentation:         http://cygwin.com/docs.html
> FAQ:                   http://cygwin.com/faq/
> 
> 



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019