Mail Archives: djgpp/1997/02/17/04:38:51
On Sun, 16 Feb 1997, Benjamin D Chambers wrote:
> Actually, djgpp treats both / and \ identically.
The problem is *not* the DJGPP support of slashes (that's inherent to
the DJGPP libc I/O functions). The problem is that many Unix programs
have built-in assumptions about how valid pathnames look: they only
know about forward slashes, treat any pathname that doesn't begin with
a slash as relative to the working directory (what about "d:/path"?)
and don't know anything about drive letters. The code based on these
assumptions and the '/' characters are scattered throughout the entire
program, which makes it a bitch porting them to DJGPP, unless you just
give up and decide to not support DOS-style pathnames. (I think that
whoever ports a package should *not* give up.)
So it takes a lot of effort and some trickery to port a file-oriented
package, such as GNU Fileutils to DJGPP in a way that makes them
support both Unix-style and DOS-style pathnames. The interested
reader should look into the sources of the ported packages to see how
this is done.
- Raw text -