Subject: Re: Cygwin playbook?

From: Shawn Pearce <[email-masked]>
Date: Thu, 7 Sep 2006 03:27:41 -0400

Junio C Hamano <[email-masked]> wrote:
> "Martin Langhoff" <[email-masked]> writes:
> 
> > - What cygwin packages are needed?

I'd have to check tomorrow but I run a pretty reduced set of Cygwin
packages with Git.  I'm using something around:

	rcs (for merge)
	python (for merge-recursive, though merge-recur is a *huge* win)
	wish (for gitk)
	perl
	ssh
	openssl
	curl
	expat
	... maybe i missed something but probably not...
	make
	gcc
	binutils (sorta necessary to compile!)

iirc I build git on Windows with a command as simple as:

	make prefix=/usr/local/git NO_MMAP=1 install

I actually have it in a small shell script as I then turn around
and tar/bz2 that directory and make a Cygwin package out of it for
other folks at my site.

> > - How do I install for personal use?
> 
> make install would install under whereever you call ~/bin in
> Cygwin environment, and that is how I have mine.

I personally don't like the default prefix so I always retarget Git
to another directory.  This works just fine on Cygwin just like on
any UNIX system.
 
> > - Anything else I should know?
> 
> You would probably have great pain if on vfat.  It appears to
> work Ok on NTFS.  It appears to be quite slow, judging from
> the way it runs our standard test suite.

I see odd behavior when its not a locally mounted NTFS filesystem.
For example sometimes our SAMBA server (a Solaris system) doesn't
play nicely with our XP systems and we get bad error codes back
(still haven't figured that one out).  We also have what I believe
is a Windows 2003 server whose drive is mapped onto many 2000/XP
desktops; that drive can't properly rename the index file so we
can't use it for working directory storage.  Works fine though for
bare repositories.  Local NTFS has never been an issue.

I see large slowdowns when the number of loose objects >~100.  So I
repack frequently.  No, defragging hasn't helped.  Only repacking
has.

I just started using merge-recur (export
GIT_USE_RECUR_FOR_RECURSIVE=1 to enable) over git-merge-recursive.
Its a huge performance gain.  I'm glad Alex Riesen and Johannes
Schindelin have put so much effort into it.

gitk has layout issues on Cygwin.  I always whack my ~/.gitk
file and then have to resize the window every time it launches.
People have reported this bug in the past but I don't think anyone
has taken the time to work it out.  It hasn't annoyed me enough
(yet) to justify me spending time on it.

Git pretty much works as you would expect; its just somewhat slower
than on a good UNIX system.  Maybe its Cygwin, maybe its Windows,
maybe its the 4+ year old system its running on.  :-)

-- 
Shawn.