lmi-commits
[Top][All Lists]
Advanced

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

[lmi-commits] [lmi] master a64c67e 1/5: Make an msw-native 'md5sum' avai


From: Greg Chicares
Subject: [lmi-commits] [lmi] master a64c67e 1/5: Make an msw-native 'md5sum' available for cross builds
Date: Mon, 15 Apr 2019 07:03:20 -0400 (EDT)

branch: master
commit a64c67ea949fe5d9e06048ab80fe79250defc90e
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>

    Make an msw-native 'md5sum' available for cross builds
    
    Moved the relevant command from a README file into a script.
---
 README.schroot        | 12 ------------
 install_msw.sh        | 14 ++++++++++++++
 test_coding_rules.cpp |  1 +
 3 files changed, 15 insertions(+), 12 deletions(-)

diff --git a/README.schroot b/README.schroot
index 1be65b5..3123521 100644
--- a/README.schroot
+++ b/README.schroot
@@ -332,18 +332,6 @@ chmod +x install_msw.sh
 pushd /opt/lmi/bin
 wine ./lmi_wx_shared.exe --ash_nazg --data_path=../data
 
-# '--host' being 'i686-w64-mingw32', unit tests require an msw-native
-# 'md5sum.exe'. Fortuitously, 'install_miscellanea.make' has installed
-# one already, taking care to place it off $PATH so that it doesn't
-# shadow a native 'md5sum' provided, e.g., by cygwin. However, in this
-# chroot it cannot shadow the native GNU/Linux 'md5sum', so copy it to
-# a directory that's on $WINEPATH to make unit tests work; it doesn't
-# matter that this directory is also on $PATH. The file is tiny, so a
-# copy isn't too wasteful, and wine doesn't find it if it's simply
-# symlinked.
-
-cp -a /opt/lmi/third_party/bin/md5sum.exe /opt/lmi/local/bin
-
 # Symlink the repository's hooks/ directory:
 cd /opt/lmi/src/lmi
 mv .git/hooks .git/hooks-orig
diff --git a/install_msw.sh b/install_msw.sh
index e314a2a..8f934aa 100755
--- a/install_msw.sh
+++ b/install_msw.sh
@@ -193,6 +193,20 @@ make $coefficiency --output-sync=recurse -f 
install_libxml2_libxslt.make
 
 ./install_wxpdfdoc.sh
 
+# For cygwin builds, the expressly downloaded 'md5sum.exe' is kept off
+# $PATH to prevent it from shadowing cygwin's own version. However,
+# for cross builds, it cannot shadow the native 'md5sum', yet some
+# cross-built unit tests require an msw binary, so copy it to a
+# directory that's on $WINEPATH to make those tests work. It doesn't
+# matter that this directory is also on $PATH. The file is tiny, so a
+# copy isn't too wasteful, and 'wine' doesn't find it if it's simply
+# symlinked.
+
+if [ "Cygwin" != "$platform" ]
+then
+    cp --archive /opt/lmi/third_party/bin/md5sum.exe /opt/lmi/local/bin
+fi
+
 find /cache_for_lmi/downloads -type f | xargs md5sum
 
 export         PATH=/opt/lmi/local/bin:/opt/lmi/local/lib:$PATH
diff --git a/test_coding_rules.cpp b/test_coding_rules.cpp
index 2fa7534..68b1962 100644
--- a/test_coding_rules.cpp
+++ b/test_coding_rules.cpp
@@ -1067,6 +1067,7 @@ void enforce_taboos(file const& f)
     if
         (   !f.is_of_phylum(e_log)
         &&  !f.is_of_phylum(e_make)
+        &&  !f.is_of_phylum(e_script)
         &&  !f.is_of_phylum(e_synopsis)
         )
         {



reply via email to

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