[Top][All Lists]

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

[lmi-commits] [lmi] master 9ce4bae 1/2: Deal with some 'shellcheck' comp

From: Greg Chicares
Subject: [lmi-commits] [lmi] master 9ce4bae 1/2: Deal with some 'shellcheck' complaints
Date: Fri, 9 Oct 2020 18:35:16 -0400 (EDT)

branch: master
commit 9ce4bae3d4330bdf7cb9087d42fa38ce3abefb77
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>

    Deal with some 'shellcheck' complaints
    Incidental comments--also see:
    * install_wx.sh: An abbreviated SHA1 is preferable.
    * install_wxpdfdoc.sh: Copied a 'gcc_version' line from install_wx.sh,
      though it may need more work in both files:
        $ "${mingw_bin_dir}${LMI_TRIPLET}-$LMI_COMPILER" -dumpversion
        zsh: command not found: x86_64-pc-linux-gnu-gcc
    * install_xml_libraries: It's interesting that disabling SC2046 is
      sufficient in one place, but 2086 must be disabled in another.
      They're subtly different:
        SC2086: Double quote to prevent globbing and word splitting.
        SC2046: Quote this to prevent word splitting.
      and not interchangeable. Apparently SC2046 must be disabled to
      let 'eval' work on another line in this file. Amusingly enough,
        $ git grep spellcheck *
      would have revealed another mistake that's herewith corrected.
 install_wx.sh            | 2 +-
 install_wxpdfdoc.sh      | 3 ++-
 install_xml_libraries.sh | 7 ++++---
 3 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/install_wx.sh b/install_wx.sh
index 531a505..ca99a5f 100755
--- a/install_wx.sh
+++ b/install_wx.sh
@@ -56,7 +56,7 @@ esac
 # Distinguish wx dll by host type, compiler version, and wx SHA1.
 gcc_version=$("${mingw_bin_dir}${LMI_TRIPLET}-$LMI_COMPILER" -dumpversion|tr 
-d '\r')
+vendor=${LMI_TRIPLET}-$gcc_version-$(git rev-parse --short HEAD:third_party/wx)
 # Configuration reference:
 #   https://lists.nongnu.org/archive/html/lmi/2007-11/msg00001.html
diff --git a/install_wxpdfdoc.sh b/install_wxpdfdoc.sh
index 45a014f..f2fd2cd 100755
--- a/install_wxpdfdoc.sh
+++ b/install_wxpdfdoc.sh
@@ -72,7 +72,8 @@ config_options="
 cd "$wxpdfdoc_dir"
 autoreconf --verbose
+gcc_version=$("${mingw_bin_dir}${LMI_TRIPLET}-$LMI_COMPILER" -dumpversion|tr 
-d '\r')
 if [ "$wxpdfdoc_skip_clean" != 1 ]
diff --git a/install_xml_libraries.sh b/install_xml_libraries.sh
index b855630..cc50ac0 100755
--- a/install_xml_libraries.sh
+++ b/install_xml_libraries.sh
@@ -112,7 +112,7 @@ xmlsoft_common_options="
-# This variable is used inside eval, which is beyond spellcheck's ken.
+# This variable is used inside eval, which is beyond shellcheck's ken.
 # shellcheck disable=SC2034
@@ -193,6 +193,7 @@ done
 # Building xmlwrapp is similar, but sufficiently different to not try to fit it
 # into the loop above, but reuse the same structure for it just to emphasize
 # the similarity.
+# shellcheck disable=SC2043
 for lib in xmlwrapp; do
     if [ ! -x "$libdir/configure" ]; then
@@ -201,9 +202,9 @@ for lib in xmlwrapp; do
     mkdir --parents "$build_dir/$lib"
     cd "$build_dir/$lib"
-    # shellcheck disable=SC2046
+    # shellcheck disable=SC2086
     "$libdir/configure" \
-        PKG_CONFIG_LIBDIR=$exec_prefix/lib/pkgconfig \
+        PKG_CONFIG_LIBDIR="$exec_prefix"/lib/pkgconfig \
     $MAKE install

reply via email to

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