DJGPP/LFNs/DOSEMU

DJGPP/LFNs/DOSEMU

Post by Bart Oldema » Tue, 22 Jul 2003 06:05:44



Hi,

I have added some experimental LFN support on redirected "network"
drives to current testing versions of DOSEMU (download version 1.1.5 from
dosemu.sf.net and patch up to 1.1.5.6 using
http://www.dosemu.org/testing/patchset-1.1.5.6.tgz).

This adds an $_lfn_support option to dosemu.conf which can be on or off.

If the underlying filesystem is VFAT then the short filenames are the
exact ones (obtained using a special Linux ioctl) whereas on ext2 they are
the mangled samba style SFNs. The long filenames are case insensitive but
case preserving.

All functions are implemented except for
        case 0xa6: /* get file info by handle */
        case 0xa9: /* server create or open file */
        case 0xaa: /* create/terminate/query subst */
this is enough for DJGPP -- I tested by compiling the LIBC.

I had to work around one issue with DJGPP: it assumes that the findfirst
handles are non-zero -- where my initial implementation used
0,1,2,3,4,... for findfirst handles. This "findfirst handles are
non-zero" fact(?) is not documented in Ralf Brown's interrupt list.

-- look at this piece of code to see why:
    r.x.ax = 0x714f;
    r.x.bx = ffblk->lfn_handle;
    if(!r.x.bx)
    {
      errno = ENMFILE;
      return 1;
    }
(src/libc/dos/dir/findnext.c)

Testers are very welcome. The old DPMI descriptor leak problem is fixed in
recent DOSEMU development versions too (by Stas Sergeev).

Bart

 
 
 

DJGPP/LFNs/DOSEMU

Post by DJ Delori » Tue, 22 Jul 2003 07:22:00


Quote:> I have added some experimental LFN support on redirected "network"
> drives to current testing versions of DOSEMU (download version 1.1.5 from
> dosemu.sf.net and patch up to 1.1.5.6 using

Woo hoo!  I started doing this a while ago, but didn't get very far
(mostly because I was too busy).

 
 
 

DJGPP/LFNs/DOSEMU

Post by Eli Zaretski » Tue, 22 Jul 2003 13:32:05



> Newsgroups: comp.os.msdos.djgpp
> Date: Sun, 20 Jul 2003 21:05:44 +0000 (UTC)

> I have added some experimental LFN support on redirected "network"
> drives to current testing versions of DOSEMU (download version 1.1.5 from
> dosemu.sf.net and patch up to 1.1.5.6 using
> http://www.dosemu.org/testing/patchset-1.1.5.6.tgz).

Thanks!

Quote:> All functions are implemented except for
>         case 0xa6: /* get file info by handle */
>         case 0xa9: /* server create or open file */
>         case 0xaa: /* create/terminate/query subst */
> this is enough for DJGPP -- I tested by compiling the LIBC.

I'm surprised: I thought we use 0xa6.
 
 
 

DJGPP/LFNs/DOSEMU

Post by Bart Oldema » Tue, 22 Jul 2003 13:52:20




> > All functions are implemented except for
> >         case 0xa6: /* get file info by handle */
> >         case 0xa9: /* server create or open file */
> >         case 0xaa: /* create/terminate/query subst */
> > this is enough for DJGPP -- I tested by compiling the LIBC.

> I'm surprised: I thought we use 0xa6.

you do, in src/libc/posix/sys/stat/fstat.c, but just as a means to "try
harder" if SFT methods fail (as far as I can quickly see in the source
code, I may miss something here).

What DOSEMU does for an "open" is to create the file if necessary
and then generate the corresponding short filename and forward the request
to the DOS that runs in DOSEMU using int21/ah=6c. This DOS will then call
DOSEMU again using int2f/ax=11xx (network redirector) but assign the
SFT for that file, assign a handle, and so on. Subsequently DJGPP's fstat
can use that SFT.

Bart

 
 
 

DJGPP/LFNs/DOSEMU

Post by Andrew Cottrel » Tue, 22 Jul 2003 16:02:39


Quote:>> > this is enough for DJGPP -- I tested by compiling the LIBC.

Which version of LIBC did you use?

There are allot of changes that have been done in the 2.04 code to
support Win 2k/XP as the low level API is not compatible with 9x or
even NT.

Andrew

 
 
 

1. DJGPP & LFNs

I am trying to do a few Win32 ports of some DOS stuff I had some time
back.

I converted these to LFN but I have found that DJGPP does not like LFNs.  
I have tried GNU-Win32 but it only crashed or totally froze up.

Has anyone patched DJGPP to support LFNs?

----------
I am currently attempting to further my Employment

http://www.powerup.com.au/~wjackson

2. XIO Error

3. For DOSEMU users - djgpp and ^C troubles

4. Enumerate Nested domains

5. DJGPP, DOSEmu and IPX

6. Casiopoea or Nino?

7. DJGPP under Linux DOSEMU or Wine

8. 2 simultaneous internet connections

9. Dosemu .66.7 and DJGPP + RHIDE 1.3C

10. dosemu & djgpp

11. running DJGPP programs in DOSEMU?

12. running DJGPP programs in DOSEMU ?

13. ?Tutorial: DJGPP under DOSEMU/LINUX