delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/06/13/11:17:25

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <F37FF6523962D41182F800D0B708C96F03CD7F87@gaudi.spain.hp.com>
From: "POSTLBAUER,JUAN (HP-Spain,ex1)" <juan_postlbauer AT hp DOT com>
To: cygwin AT cygwin DOT com
Subject: Interoperatibility problem in tar 1.13.19
Date: Wed, 13 Jun 2001 16:44:54 +0200
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2653.19)
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id LAA18592

Two different problems:

1) 

Trying to compile the cygwin source under linux (SuSE 7.1, kernel 2.4)
complains about O_TEXT not defined.
True: "grep -r -e O_BINARY -e O_TEXT /usr/include" yields nothing.

I guess the patch would be in system.h, where you already do something
similar for O_BINARY
#ifndef O_BINARY
#define O_BINARY 0
#endif
then just do the same for O_TEXT.

That's exactly what I did in order to compile your sources on linux (see why
I needed that in problem 2 below) and it works fine.

This is not critical, as the source is intended for cygwin. But doing so
might allow for using the same sources for every plattform.

2) The big one

Also, as the numeric form of the open flags for the rmt protocol is retained
"for compatibility", it would be better to suppress from that number all
options causing compatibility problems.

Real case:
Tar is run in cygwin 1.1.8
rmt runs under linux (suse 7.1), and it's not aware of symbolic form. In
this case I also owned the linux box and was able to upgrade rmt to a newer
version. But in a general case you wouldn't be able to do it because it
wouldn't be your system.

"rmt tvf host:/dev/st" fails, because tar uses O_BINARY, which under cygwin
is 0x10000, wich under linux is O_DIRECTORY. So you get error 20: no such
directory.

My proposed fix: send the full set of "open flags" in text form, but include
only "full cross plattform" options in the numeric form.
This way if the target is a new implementation it will correctly parse the
text form and discard the numeric form, whereas if it is and old
implementation it won't get confused misunderstunding the numeric option.

	Best regards
Juan Postlbauer
   BRS Technical Consultant
   Hewlett-Packard Española
 

--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


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