Subject: passing a trailing "/" to CreateDirectory (mkdir busted?)
From: [email-masked] (Gordon Watts Brown University)

7 Mar 1998 17:01:41 -0800
Message-ID: <[email-masked]>
Mime-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
To: gnu-win cygnus mailing list <[email-masked]>

Hi,
  In b19 if you type "mkdir bogus/" from the command line it will fail. If
you try most unix boxes (at least, all I could find), you will get a new
directory in your current working directory called "bogus."

  After much sweat and tears, I patched the mkdir routine in syscalls.cc in
the winsup area. I'm happy to distribute the patch (who keeps track of fixes
and what format (i know almost nothing about unix), but I'm not sure I fixed
the right thing: perhaps all paths should have their trailing "/" stripped
off them when they are converted to win32 format. In that case, the path.cc
should have the patch. I'll let an expert tell me what to do.

  Finally, building the libraries was a disaster. I go through a blow by
blow and someone can tell me what I did wrong. I have built programs on UNIX
before, but never anything as complex as this (with configure scripts).
Someone posted instructions previously (this was all I had to go on) which
said:

	cd objdir
	srcdir/cdk/configure --prefix=/install i386-cygwin32
	make

  So, I cded to winsup, ran the configure script. It failed, after (I think)
writing a makefile with the error message "cd: lstat /f failed"... I tried
to build anyway. That failed because several includes weren't found (like
ansidecl.h). I added the path to the makefile, and then they built. Then
libc/libm were missing so I first attempted to build them. configure just
failed outright when I tried to run it from the newlib directory (couldn't
find ../../config_ml.h -- of course not, it was in ../config_ml.h!). Going
into the directory tree one deeper and I got lots of those "cd: lstat /f
failed" messages. Gave up and found the libc.a/libm.a from the distrubtion
and copied them into newlib. Then it tried to build the .dll, and died
because it couldn't find the routine strsignal. Looking in libiberty I found
it defined, but in config.h NEED_strsignal wasn't defiend, so it was never
compiled when the strsignal.cc file was built. I added this to config.h (i
know, don't edit, but I figure you'all will tell me the right way to do
things and then this file will be overwritten with the right thing). Then
things could build. My DLL is, however, 450K, while the distribution dll is
about 100K less. Not sure why this is...

  If someone could tell me what the "correct" way to build this thing is (or
point me to the web page where the instructions already exist), I would be
greatful.

	cheers,
		Gordon.

-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".