delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/08/06/22:30:24

From: Jack Klein <jackklein AT spamcop DOT net>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Q: Long file names, djgpp 2.95.3 / WinNT 4.00 NTFS
Message-ID: <s3kumt46rt9i8k7noi9eo5t8evd4oh64g0@4ax.com>
References: <9kn4vo$s4$1 AT newstoo DOT ericsson DOT se>
X-Newsreader: Forte Agent 1.8/32.548
MIME-Version: 1.0
Lines: 44
Date: Tue, 07 Aug 2001 02:23:03 GMT
NNTP-Posting-Host: 12.84.4.240
X-Complaints-To: abuse AT worldnet DOT att DOT net
X-Trace: bgtnsc04-news.ops.worldnet.att.net 997150983 12.84.4.240 (Tue, 07 Aug 2001 02:23:03 GMT)
NNTP-Posting-Date: Tue, 07 Aug 2001 02:23:03 GMT
Organization: AT&T Worldnet
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

On Tue, 7 Aug 2001 00:33:57 +0200, "Boris Gaspic"
<boris DOT gaspic AT am2 DOT ericsson DOT se> wrote in comp.os.msdos.djgpp:

> 
> Hello,
> 
> I am new to djgpp. I am trying to write a program which
> -must- use long file names on a WinNT 4.00 NTFS disk.
> And I can't fopen() anything that's not 8.3. (a big problem
> to me, since I'm dealing with thousands of files whose name
> is a combination of two 32-bit database keys, and I must
> access them knowing these keys...)
> 
> So it's about the fopen ("123456789.345678901", "rb");
> Is there something I'm doing wrong? Am I -supposed-
> to be able to use LFN in a shell on NT4.0? I can open the
> files fine in the "123456~4.345" format, but nothing in
> LFN. The printf ("%d\n", _USE_LFN); dumps a zero. (?!?)
> Something I should change in DJGPP.ENV? (I use the original)
> Or do I need a different libc or something?
> 
> I'd be pretty thankful for any solution which works on the
> NT4.0 / NTFS, regardless if the same program would
> later work on a different OS/FSYS combination or not.
> 
> Thank you,
> Boris

I can't help you with the LFN problem under NT, but if you basically
only need this to solve one particular task you might consider
downloading and using lcc-win32, a C only compiler that makes native
Win32 executables (including console applications) using the C
run-time library DLL built into Windows.

If you're interested you can find it at
http://www.cs.virginia.edu/~lcc-win32/

-- 
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++ ftp://snurse-l.org/pub/acllc-c++/faq

- Raw text -


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