diff -purN --exclude=*~ ../cinstall.orig/ChangeLog ./ChangeLog
--- ../cinstall.orig/ChangeLog	Tue Jan 29 21:50:51 2002
+++ ./ChangeLog	Tue Jan 29 22:29:56 2002
@@ -1,3 +1,20 @@
+2002-01-29  Jan Nieuwenhuizen  <janneke@gnu.org>
+
+	* site.cc (OnMessageCmd): Bugfix: don't try to add NULL url.
+
+	* Forward port patch to cvs -D20020129.
+	
+	* mklink2.c: Compile fix.
+
+	* desktop.cc: Remove spurious line breaks from etc_profile.
+	(make_lily_bat): New function.
+	(save_icon): Parametrize.
+	(do_desktop_setup): LilyPond support; disable Cygwin support.
+
+	* res.rc: Adapted for LilyPond.
+
+	* ini.cc (fprintf): Cygwin -> GNU LilyPond
+
 2002-01-29  Christopher Faylor  <cgf@redhat.com>
 
 	* configure: Regenerate.
@@ -3288,4 +3305,4 @@ Sat Apr  1 20:48:09 2000  Christopher Fa
 	* zlib/Makefile.in: Regenerate from Makefile.am
 
 %%% $Id: ChangeLog,v 2.189 2002/01/29 14:43:57 cgf Exp $
-$Revision: 2.189 $
+$Revision: 2.189.jcn1 $
Binary files ../cinstall.orig/LilyPond.ico and ./LilyPond.ico differ
diff -purN --exclude=*~ ../cinstall.orig/desktop.cc ./desktop.cc
--- ../cinstall.orig/desktop.cc	Tue Jan 29 10:24:32 2002
+++ ./desktop.cc	Tue Jan 29 10:33:01 2002
@@ -83,9 +83,7 @@ static const char *etc_profile[] = {
   "done",
   "",
   "export MAKE_MODE=unix",
-  "export PS1='\\[\\033]0;\\w\\007",
-  "\\033[32m\\]\\u@\\h \\[\\033[33m\\w\\033[0m\\]",
-  "$ '",
+  "export PS1='\\[\\033]0;\\w\\007\\033[32m\\]\\u@\\h \\[\\033[33m\\w\\033[0m\\]$ '",
   "",
   "cd \"$HOME\"",
   0
@@ -204,6 +202,35 @@ make_cygwin_bat ()
 }
 
 static void
+make_lily_bat ()
+{
+  batname = backslash (concat (get_root_dir (), "/lilypond.bat", 0));
+
+  /* if the batch file exists, don't overwrite it */
+  if (_access (batname, 0) == 0)
+    return;
+
+  FILE *bat = fopen (batname, "wt");
+  if (!bat)
+    return;
+
+  fprintf (bat, "@echo off\n\n");
+
+  fprintf (bat, "%.2s\n", get_root_dir ());
+  fprintf (bat, "chdir %s\n\n",
+	   backslash (concat (get_root_dir () + 2, "/bin", 0)));
+
+  if (_access (cygpath ("/usr/bin/rxvt"), 0) == 0)
+    fprintf (bat, "rxtv -e /bin/bash --login -i \n");
+  else
+    /* fprintf (bat, "bash --rcfile /bin/lilypond-profile\n"); */
+    fprintf (bat, "bash --login -i\n");
+
+  fclose (bat);
+
+}
+
+static void
 make_etc_profile ()
 {
   char *fname = cygpath ("/etc/profile", 0);
@@ -301,11 +328,11 @@ out:
 }
 
 static void
-save_icon ()
+save_icon (char const* iconfile, char const* iconres)
 {
-  iconname = backslash (cygpath ("/cygwin.ico", 0));
-
-  HRSRC rsrc = FindResource (NULL, "CYGWIN.ICON", "FILE");
+  iconname = backslash (concat (get_root_dir (), iconfile, 0));
+  
+  HRSRC rsrc = FindResource (NULL, iconres, "FILE");
   if (rsrc == NULL)
     {
       fatal ("FindResource failed");
@@ -325,12 +352,13 @@ save_icon ()
 static void
 do_desktop_setup ()
 {
-  save_icon ();
+  save_icon ("/cygwin.ico", "CYGWIN.ICON");
 
   make_cygwin_bat ();
   make_etc_profile ();
   make_passwd_group ();
 
+#if 0  
   if (root_menu)
     {
       start_menu ("Cygwin Bash Shell", batname);
@@ -339,6 +367,20 @@ do_desktop_setup ()
   if (root_desktop)
     {
       desktop_icon ("Cygwin", batname);
+    }
+#endif
+  
+  save_icon ("/LilyPond.ico", "LILYPOND.ICON");
+  make_lily_bat ();
+  
+  if (root_menu)
+    {
+      start_menu ("GNU LilyPond Shell", batname);
+    }
+ 
+  if (root_desktop)
+    {
+      desktop_icon ("GNU LilyPond", batname);
     }
 }
 
diff -purN --exclude=*~ ../cinstall.orig/ini.cc ./ini.cc
--- ../cinstall.orig/ini.cc	Tue Jan 29 10:24:34 2002
+++ ./ini.cc	Tue Jan 29 10:33:01 2002
@@ -282,7 +282,7 @@ fprintf (FILE * f, const char *fmt, ...)
 	{
 	  *nl = 0;
 	  /*OutputDebugString (stderrbuf); */
-	  MessageBox (0, buf, "Cygwin Setup", 0);
+ 	  MessageBox (0, buf, "GNU LilyPond Setup", 0);
 	  stderrbuf[0] = 0;
 	}
 
diff -purN --exclude=*~ ../cinstall.orig/msg.cc ./msg.cc
--- ../cinstall.orig/msg.cc	Sun Dec 23 13:13:29 2001
+++ ./msg.cc	Tue Jan 29 11:10:03 2002
@@ -47,7 +47,7 @@ mbox (HWND owner, const char *name, int 
 
   vsprintf (buf, fmt, args);
   log (0, "mbox %s: %s", name, buf);
-  return MessageBox (owner, buf, "Cygwin Setup", type);
+  return MessageBox (owner, buf, "GNU LilyPond Setup", type);
 }
 
 void
diff -purN --exclude=*~ ../cinstall.orig/res.rc ./res.rc
--- ../cinstall.orig/res.rc	Tue Jan 29 10:24:34 2002
+++ ./res.rc	Tue Jan 29 22:26:51 2002
@@ -30,7 +30,7 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_U
 
 IDD_SOURCE DIALOG DISCARDABLE  0, 0, 317, 179
 STYLE DS_MODALFRAME | DS_CENTER | WS_CHILD | WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     CONTROL         "&Install from Internet",IDC_SOURCE_NETINST,"Button",
@@ -39,7 +39,7 @@ BEGIN
                     BS_AUTORADIOBUTTON | WS_TABSTOP,101,84,115,10
     CONTROL         "Install from &Local Directory",IDC_SOURCE_CWD,"Button",
                     BS_AUTORADIOBUTTON | WS_TABSTOP,101,99,115,10
-    ICON            IDI_CYGWIN,IDC_STATIC,290,0,21,20
+    ICON            IDI_LILYPOND,IDC_STATIC,290,0,21,20
     CONTROL         "",IDC_STATIC,"Static",SS_BLACKFRAME | SS_SUNKEN,0,28,
                     317,1
     LTEXT           "Choose A Download Source",IDC_STATIC_HEADER_TITLE,7,0,
@@ -50,13 +50,13 @@ END
 
 IDD_LOCAL_DIR DIALOG DISCARDABLE  0, 0, 317, 179
 STYLE DS_MODALFRAME | DS_CENTER | WS_CHILD | WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     EDITTEXT        IDC_LOCAL_DIR,58,83,165,15,ES_AUTOHSCROLL | WS_GROUP
     PUSHBUTTON      "B&rowse...",IDC_LOCAL_DIR_BROWSE,223,83,34,14
     GROUPBOX        "Local Package Directory",IDC_STATIC,53,67,210,45
-    ICON            IDI_CYGWIN,IDC_STATIC,290,0,21,20
+    ICON            IDI_LILYPOND,IDC_STATIC,290,0,21,20
     CONTROL         "",IDC_STATIC,"Static",SS_BLACKFRAME | SS_SUNKEN,0,28,
                     317,1
     LTEXT           "Select a directory where you want Setup to store the installation files it dowmloads.  The directory will be created if it does not already exist.",
@@ -67,7 +67,7 @@ END
 
 IDD_ROOT DIALOG DISCARDABLE  0, 0, 317, 179
 STYLE DS_MODALFRAME | DS_CENTER | WS_CHILD | WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     GROUPBOX        "Root Directory",IDC_STATIC,5,50,305,40,WS_TABSTOP
@@ -83,7 +83,7 @@ BEGIN
                     WS_GROUP | WS_TABSTOP,170,120,90,8
     CONTROL         "&Unix",IDC_ROOT_BINARY,"Button",BS_AUTORADIOBUTTON | 
                     WS_TABSTOP,170,135,90,8
-    ICON            IDI_CYGWIN,IDC_STATIC,290,0,20,20
+    ICON            IDI_LILYPOND,IDC_STATIC,290,0,21,20
     CONTROL         "",IDC_STATIC,"Static",SS_BLACKFRAME | SS_SUNKEN,0,28,
                     317,1
     LTEXT           "Select the directory where you want to install Cygwin.  Also choose a few installation parameters.",
@@ -96,10 +96,10 @@ IDD_SITE DIALOG DISCARDABLE 0, 0, 317, 1
 STYLE DS_MODALFRAME | DS_3DLOOK | DS_CENTER | WS_CHILD | WS_VISIBLE | 
     WS_CAPTION | WS_SYSMENU
 EXSTYLE WS_EX_CONTROLPARENT
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
-    ICON            IDI_CYGWIN,IDC_STATIC,290,0,20,20
+    ICON            IDI_LILYPOND,IDC_STATIC,290,0,21,20
     LISTBOX         IDC_URL_LIST,66,45,185,110,LBS_NOINTEGRALHEIGHT | 
                     LBS_EXTENDEDSEL | WS_VSCROLL | WS_HSCROLL | WS_GROUP | 
                     WS_TABSTOP
@@ -119,7 +119,7 @@ END
 
 IDD_NET DIALOG DISCARDABLE  0, 0, 317, 179
 STYLE DS_MODALFRAME | DS_CENTER | WS_CHILD | WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     CONTROL         "&Direct Connection",IDC_NET_DIRECT,"Button",
@@ -137,7 +137,7 @@ BEGIN
                     NOT WS_GROUP
     RTEXT           "Por&t",IDC_STATIC,85,125,30,12,SS_CENTERIMAGE | NOT 
                     WS_GROUP
-    ICON            IDI_CYGWIN,IDC_STATIC,290,0,21,20
+    ICON            IDI_LILYPOND,IDC_STATIC,290,0,21,20
     CONTROL         "",IDC_STATIC,"Static",SS_BLACKFRAME | SS_SUNKEN,0,28,
                     317,1
     LTEXT           "Setup needs to know how you want it to connect to the internet.  Choose the appropriate settings below.",
@@ -149,7 +149,7 @@ END
 IDD_INSTATUS DIALOG DISCARDABLE  0, 0, 317, 179
 STYLE DS_MODALFRAME | DS_CENTER | WS_CHILD | WS_VISIBLE | WS_CAPTION | 
     WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     LTEXT           "Installing...",IDC_INS_ACTION,45,55,205,8,NOT WS_GROUP
@@ -164,7 +164,7 @@ BEGIN
     LTEXT           "Package:",IDC_INS_BL_PACKAGE,45,100,47,8,NOT WS_GROUP
     LTEXT           "Total:",IDC_INS_BL_TOTAL,45,115,48,8,NOT WS_GROUP
     LTEXT           "Disk:",IDC_INS_BL_DISK,45,130,47,8,NOT WS_GROUP
-    ICON            IDI_CYGWIN,IDC_STATIC,290,0,20,20
+    ICON            IDI_LILYPOND,IDC_STATIC,290,0,20,20
     CONTROL         "",IDC_STATIC,"Static",SS_BLACKFRAME | SS_SUNKEN,0,28,
                     317,1
     LTEXT           "This page displays the progress of the download or installation.",
@@ -175,10 +175,10 @@ END
 
 IDD_PROXY_AUTH DIALOG DISCARDABLE  0, 0, 215, 95
 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
-    ICON            IDI_CYGWIN,IDC_STATIC,5,5,20,20
+    ICON            IDI_LILYPOND,IDC_STATIC,5,5,20,20
     LTEXT           "Proxy &User ID",IDC_STATIC,5,28,55,15,SS_CENTERIMAGE,
                     WS_EX_RIGHT
     EDITTEXT        IDC_NET_USER,65,28,145,12,ES_AUTOHSCROLL
@@ -192,10 +192,10 @@ END
 
 IDD_NET_AUTH DIALOG DISCARDABLE  0, 0, 215, 95
 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
-    ICON            IDI_CYGWIN,IDC_STATIC,5,5,20,20
+    ICON            IDI_LILYPOND,IDC_STATIC,5,5,20,20
     LTEXT           "&User ID",IDC_STATIC,5,28,55,15,SS_CENTERIMAGE,
                     WS_EX_RIGHT
     EDITTEXT        IDC_NET_USER,65,28,145,12,ES_AUTOHSCROLL
@@ -210,27 +210,26 @@ END
 IDD_SPLASH DIALOG DISCARDABLE  0, 0, 317, 179
 STYLE DS_MODALFRAME | DS_3DLOOK | DS_CENTER | WS_CHILD | WS_VISIBLE | 
     WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
-    ICON            IDI_CYGWIN,IDC_STATIC,113,112,21,20,WS_GROUP
+    ICON            IDI_LILYPOND,IDC_STATIC,113,100,21,20,WS_GROUP
     CONTROL         "",IDC_STATIC,"Static",SS_WHITERECT,0,0,95,178
-    LTEXT           "Version (unknown)",IDC_VERSION,115,137,195,10
-    LTEXT           "Cygwin Net Release Setup Program",
+    LTEXT           "Version (1.4.10)",IDC_VERSION,115,137,195,10
+    LTEXT           "GNU LilyPond Setup Program",
                     IDC_STATIC_WELCOME_TITLE,115,1,195,24
-    LTEXT           "Copyright 2000, 2001 Red Hat Inc.",IDC_STATIC,115,150,
-                    195,8
-    LTEXT           "http://sources.redhat.com/cygwin/",IDC_STATIC,115,162,
-                    195,8
-    LTEXT           "This wizard will guide you through the installation and updating of the Cygwin environment and a plethora of GNU packages.",
-                    IDC_STATIC,115,33,195,54
+    LTEXT           "Copyright (C) 2000-2002 Red Hat Inc.",
+			IDC_STATIC,115,138,195,8
+    LTEXT           "                (C) 2001 Jan Nieuwenhuizen <janneke@gnu.org>",IDC_STATIC,115,150,195,8
+    LTEXT           "http://www.lilypond.org/cygwin/",IDC_STATIC,115,162,195,8
+    LTEXT           "This wizard will guide you through the installation and updating LilyPond and all other necessary Cygwin packages.",IDC_STATIC,115,33,195,54
 END
 
 IDD_CHOOSE DIALOG DISCARDABLE  0, 0, 430, 266
 STYLE DS_MODALFRAME | DS_3DLOOK | DS_CENTER | WS_CHILD | WS_VISIBLE | 
     WS_CAPTION | WS_SYSMENU
 EXSTYLE WS_EX_CONTROLPARENT
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     DEFPUSHBUTTON   "&Next -->",IDOK,311,242,45,15,WS_GROUP
@@ -243,7 +242,7 @@ BEGIN
     CONTROL         "E&xp",IDC_CHOOSE_EXP,"Button",BS_AUTORADIOBUTTON,323,5,
                     25,10
     PUSHBUTTON      "&View",IDC_CHOOSE_VIEW,353,5,20,10,WS_GROUP
-    ICON            IDI_CYGWIN,IDC_STATIC,0,2,20,20
+    ICON            IDI_LILYPOND,IDC_STATIC,0,2,20,20
     LTEXT           "Select packages to install",IDC_CHOOSE_INST_TEXT,125,5,
                     99,8
     CONTROL         "",IDC_LISTVIEW_POS,"Static",SS_BLACKFRAME | NOT 
@@ -257,14 +256,14 @@ END
 IDD_DESKTOP DIALOG DISCARDABLE  0, 0, 317, 179
 STYLE DS_MODALFRAME | DS_3DLOOK | DS_CENTER | WS_CHILD | WS_VISIBLE | 
     WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     CONTROL         "Create icon on &Desktop",IDC_ROOT_DESKTOP,"Button",
                     BS_AUTOCHECKBOX,108,78,100,8
     CONTROL         "Add icon to &Start Menu",IDC_ROOT_MENU,"Button",
                     BS_AUTOCHECKBOX,108,93,100,8
-    ICON            IDI_CYGWIN,IDC_STATIC,290,0,21,20
+    ICON            IDI_LILYPOND,IDC_STATIC,290,0,21,20
     CONTROL         "",IDC_STATIC,"Static",SS_BLACKFRAME | SS_SUNKEN,0,28,
                     317,1
     LTEXT           "Tell setup if you want it to create a few icons for convenient access to the Cygwin environment.",
@@ -275,10 +274,10 @@ END
 
 IDD_FTP_AUTH DIALOG DISCARDABLE  0, 0, 215, 95
 STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
-    ICON            IDI_CYGWIN,IDC_STATIC,5,5,20,20
+    ICON            IDI_LILYPOND,IDC_STATIC,5,5,20,20
     LTEXT           "&User ID",IDC_STATIC,5,28,55,15,SS_CENTERIMAGE,
                     WS_EX_RIGHT
     EDITTEXT        IDC_NET_USER,65,28,145,12,ES_AUTOHSCROLL
@@ -293,7 +292,7 @@ END
 IDD_CHOOSER DIALOG DISCARDABLE  0, 0, 247, 116
 STYLE DS_MODALFRAME | DS_3DLOOK | WS_CHILD | WS_VISIBLE | WS_CAPTION | 
     WS_SYSMENU
-CAPTION "Cygwin Setup"
+CAPTION "GNU LilyPond Setup"
 FONT 8, "MS Sans Serif"
 BEGIN
     CTEXT           "This space intentionally left blank",IDC_STATIC,57,45,
@@ -336,6 +335,7 @@ END
 
 // Icon with lowest ID value placed first to ensure application icon
 // remains consistent on all systems.
+IDI_LILYPOND            ICON    DISCARDABLE     "LilyPond.ico"
 IDI_CYGWIN              ICON    DISCARDABLE     "cygwin.ico"
 
 /////////////////////////////////////////////////////////////////////////////
@@ -343,6 +343,7 @@ IDI_CYGWIN              ICON    DISCARDA
 // FILE
 //
 
+LILYPOND.ICON           FILE    DISCARDABLE     "LilyPond.ico"
 CYGWIN.ICON             FILE    DISCARDABLE     "cygwin.ico"
 
 /////////////////////////////////////////////////////////////////////////////
@@ -452,7 +453,7 @@ STRINGTABLE DISCARDABLE 
 BEGIN
     IDS_ROOT_SLASH          "Warning: we recommend you do NOT use the root of your hard drive as the cygwin root.  Proceed anyway?"
     IDS_ROOT_SPACE          "You should not choose a root path that include spaces in directory names.  Proceed anyway?"
-    IDS_MIRROR_LST          "http://sources.redhat.com/cygwin/mirrors.lst"
+    IDS_MIRROR_LST          "http://www.lilypond.org/cygwin/mirrors.lst"
     IDS_DIALOG_FAILED       "Unable to create Dialog Box"
     IDS_CYGWIN_FUNC_MISSING "Error: unable to find function `%s' in %s"
     IDS_DOWNLOAD_SHORT      "Download error: %s too short (%d, wanted %d)"
@@ -461,7 +462,7 @@ BEGIN
     IDS_OLD_SETUPINI        "This setup.ini is older than the one you used last time you installed cygwin.  Proceed anyway?"
     IDS_ERR_RENAME          "Can't rename %s to %s: %s"
     IDS_NOTHING_INSTALLED   "Nothing needed to be installed"
-    IDS_INSTALL_COMPLETE    "Installation Complete"
+    IDS_INSTALL_COMPLETE    "Installation Complete.  See http://www.lilypond.org/cygwin/ for support."
     IDS_REBOOT_REQUIRED     "In-use files have been replaced. You need to reboot as soon as possible to activate the new versions. Cygwin may operate incorrectly until you reboot."
 END
 
diff -purN --exclude=*~ ../cinstall.orig/resource.h ./resource.h
--- ../cinstall.orig/resource.h	Tue Jan 29 10:24:34 2002
+++ ./resource.h	Tue Jan 29 10:34:12 2002
@@ -48,13 +48,14 @@
 #define IDB_SPIN                        118
 #define IDB_RTARROW                     119
 #define IDI_SPIN                        120
-#define IDI_CYGWIN                      121
+#define IDI_LILYPOND                    121
 #define IDD_LOCAL_DIR                   122
 #define IDB_CHECK_YES                   123
 #define IDB_CHECK_NO                    124
 #define IDB_CHECK_NA                    125
 #define IDD_FTP_AUTH                    126
 #define IDD_CHOOSER                     127
+#define IDI_CYGWIN                      128
 #define IDC_SOURCE_DOWNLOAD             1000
 #define IDC_SOURCE_NETINST              1001
 #define IDC_SOURCE_CWD                  1002
diff -purN --exclude=*~ ../cinstall.orig/site.cc ./site.cc
--- ../cinstall.orig/site.cc	Tue Jan 29 10:24:34 2002
+++ ./site.cc	Tue Jan 29 22:17:13 2002
@@ -415,6 +415,8 @@ bool SitePage::OnMessageCmd (int id, HWN
 	  {
 	    // User pushed the Add button.
 	    other_url = eget (GetHWND (), IDC_EDIT_USER_URL, other_url);
+	    if (!other_url)
+	      break;
 	    site_list_type *
 	      newsite =
 	      new
