[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [5112] Add a facility for installing Cygwin

From: Greg Chicares
Subject: [lmi-commits] [5112] Add a facility for installing Cygwin
Date: Mon, 01 Nov 2010 21:48:25 +0000

Revision: 5112
Author:   chicares
Date:     2010-11-01 21:48:24 +0000 (Mon, 01 Nov 2010)
Log Message:
Add a facility for installing Cygwin

Modified Paths:

Added Paths:

Modified: lmi/trunk/GNUmakefile
--- lmi/trunk/GNUmakefile       2010-11-01 21:47:16 UTC (rev 5111)
+++ lmi/trunk/GNUmakefile       2010-11-01 21:48:24 UTC (rev 5112)
@@ -314,7 +314,9 @@
 # whose executable bit is improperly set. It is properly set iff the
 # file starts with a hash-bang; to avoid the cost of opening every
 # file, a simple heuristic is used, '*.sh *.sed' being the only files
-# permitted (though not required) to be executable.
+# permitted (though not required) to be executable. No exception need
+# be made for msw '.bat' files, which normally should not be run in a
+# *nix shell.
 xml_files := $(wildcard *.cns *.ill *.xml *.xrc *.xsd *.xsl)

Added: lmi/trunk/install_cygwin.bat
--- lmi/trunk/install_cygwin.bat                                (rev 0)
+++ lmi/trunk/install_cygwin.bat        2010-11-01 21:48:24 UTC (rev 5112)
@@ -0,0 +1,80 @@
+REM Cygwin installation.
+REM Copyright (C) 2010 Gregory W. Chicares.
+REM This program is free software; you can redistribute it and/or modify
+REM it under the terms of the GNU General Public License version 2 as
+REM published by the Free Software Foundation.
+REM This program is distributed in the hope that it will be useful,
+REM but WITHOUT ANY WARRANTY; without even the implied warranty of
+REM GNU General Public License for more details.
+REM You should have received a copy of the GNU General Public License
+REM along with this program; if not, write to the Free Software Foundation,
+REM Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+REM http://savannah.nongnu.org/projects/lmi
+REM email: <address@hidden>
+REM snail: Chicares, 186 Belle Woods Drive, Glastonbury CT 06033, USA
+REM $Id$
address@hidden OFF
+REM Install both Cygwin-1.5 and Cygwin-1.7 .
+REM Motivation: in case any problem is encountered with the current version,
+REM it is convenient to have the older version to fall back on.
+REM Cygwin-1.5's installer appears to be somewhat anomalous. Even when told
+REM to install to a nondefault directory, it creates 'C:\Cygwin' and puts
+REM some files and directories there. Deleting the unwanted directory and
+REM running the installer again decreases the anomaly; repeating those steps
+REM one more time produces an installation that seems to be valid. For the
+REM versions of msw that have been tested, three iterations are necessary, so
+REM for conservatism five are allowed. Postinstall script 'autoconf2.5.sh'
+REM fails because '/usr/share/info/autoconf2.61.info.gz' doesn't exist, but
+REM it's acceptable if only that 'info' page is missing.
+IF EXIST C:\cygwin\NUL GOTO FoundOldInstallation
+cd C:\cache_for_lmi
+FOR /L %%i IN (1,1,5) DO (
+  CALL :TryToInstall_1_5
+  IF NOT EXIST C:\cygwin\NUL (
+    echo "Cygwin 1.5 installation seems to have succeeded on iteration" %%i
+    GOTO Got_1_5
+  )
+  echo "Anomalous 'C:\cygwin' directory present after iteration" %%i
+  rmdir /S /Q C:\cygwin
+echo "Failed"
+START "Installing Cygwin 1.5" /WAIT setup-legacy ^
+  --quiet-mode --no-shortcuts ^
+  --site ftp://mirror.mcs.anl.gov/pub/cygwin/ ^
+  --root C:/cygwin-1_5 --packages ^
+  cvs,doxygen,gdb,libtool,make,openssh,patch,rsync,subversion,wget,zsh
+START "Installing Cygwin 1.7" /WAIT setup ^
+  --quiet-mode ^
+  --site ftp://mirror.mcs.anl.gov/pub/cygwin/ ^
+  --root C:/cygwin-1_7 --packages ^
+  cvs,doxygen,gdb,libtool,make,openssh,patch,rsync,subversion,wget,zsh
+echo "Cygwin 1.7 installation seems to have succeeded"
+echo "Directory C:\cygwin was already present"

Property changes on: lmi/trunk/install_cygwin.bat
Added: svn:keywords
   + Id

Modified: lmi/trunk/test_coding_rules.cpp
--- lmi/trunk/test_coding_rules.cpp     2010-11-01 21:47:16 UTC (rev 5111)
+++ lmi/trunk/test_coding_rules.cpp     2010-11-01 21:48:24 UTC (rev 5112)
@@ -199,6 +199,7 @@
         : ".md5sums"    == extension() ? e_md5
         : ".patch"      == extension() ? e_patch
         : ".ac"         == extension() ? e_script
+        : ".bat"        == extension() ? e_script
         : ".m4"         == extension() ? e_script
         : ".rc"         == extension() ? e_script
         : ".sed"        == extension() ? e_script
@@ -875,7 +876,6 @@
     taboo(f, "Microsoft");
     taboo(f, "Visual [A-Z]");
     taboo(f, "\\bWIN\\b");
-    taboo(f, "\\bBAT\\b", boost::regex::icase);
     taboo(f, "\\bExcel\\b");
     taboo(f, "xls|xl4", boost::regex::icase);
     // Insinuated by certain msw tools.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]