[Libreoffice-commits] core.git: bin/gen-boost-headers

Stephan Bergmann sbergman at redhat.com
Tue May 2 12:08:12 UTC 2017


 bin/gen-boost-headers |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 89bdfccc835ad2b09b68b7081c16b14e22d1b407
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Tue May 2 14:02:55 2017 +0200

    bin/gen-boost-headers: Don't stumble over "boost" in pathname
    
    ...like
    
      workdir/UnpackedTarball/liborcus/m4/boost.m4:#include <boost/version.hpp>
    
    which would then be mis-parsed by
    
      grep -o '\bboost.*\.\(h\|hpp\|ipp\)'
    
    to a HEADER of
    
      boost.m4:#include <boost/version.hpp
    
    instead of just
    
      boost/version.hpp
    
    (-h is a non-standard GNU grep extension, but so is the already used -r.  An
    alternative fix would be to replace the later grep -o with something like
    
      grep -o '\bboost[^#]*\.\(h\|hpp\|ipp\)'
    
    instead.)
    
    Change-Id: I0b41ed520b2fed70e8982abc0e84a34804c02549

diff --git a/bin/gen-boost-headers b/bin/gen-boost-headers
index 40f4ba849e0e..a8c64caff505 100755
--- a/bin/gen-boost-headers
+++ b/bin/gen-boost-headers
@@ -21,12 +21,12 @@ mkdir ${GENDIR}
 # note: clucene contains a copy of half of boost, so ignore it too
 # note: firebird contains a copy of half of boost, so ignore it too
 
-cat <(cd ${SRCDIR} && git grep '^# *include') \
+cat <(cd ${SRCDIR} && git grep -h '^# *include') \
     <(find ${WORKDIR}/UnpackedTarball/ -mindepth 1 -maxdepth 1 -type d \
          | grep -v boost \
          | grep -v clucene \
          | grep -v firebird \
-         | xargs grep -r '^# *include') \
+         | xargs grep -hr '^# *include') \
  | grep -o '\bboost.*\.\(h\|hpp\|ipp\)' \
  | sort | uniq \
  | while read -r HEADER; do


More information about the Libreoffice-commits mailing list