comparison Resources/CMake/BoostConfiguration.sh @ 2527:a6c2d8a2a2ec

remove filenames too long for Windows in Boost
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 11 Apr 2018 16:23:24 +0200
parents 94423976888e
children ee9a6cd63891
comparison
equal deleted inserted replaced
2526:1c37d6af7aa5 2527:a6c2d8a2a2ec
31 tar xfz ./boost_${BOOST_VERSION}.tar.gz 31 tar xfz ./boost_${BOOST_VERSION}.tar.gz
32 32
33 echo "Generating the subset..." 33 echo "Generating the subset..."
34 mkdir -p /tmp/bcp/boost_${BOOST_VERSION} 34 mkdir -p /tmp/bcp/boost_${BOOST_VERSION}
35 bcp --boost=/tmp/boost_${BOOST_VERSION} thread system locale date_time filesystem math/special_functions algorithm uuid atomic iostreams program_options numeric/ublas geometry polygon /tmp/bcp/boost_${BOOST_VERSION} 35 bcp --boost=/tmp/boost_${BOOST_VERSION} thread system locale date_time filesystem math/special_functions algorithm uuid atomic iostreams program_options numeric/ublas geometry polygon /tmp/bcp/boost_${BOOST_VERSION}
36 cd /tmp/bcp 36
37 echo "Removing documentation..."
38 rm -rf /tmp/bcp/boost_1_66_0/libs/locale/doc/html
39 rm -rf /tmp/bcp/boost_1_66_0/libs/algorithm/doc/html
40 rm -rf /tmp/bcp/boost_1_66_0/libs/geometry/doc/html
41 rm -rf /tmp/bcp/boost_1_66_0/libs/geometry/doc/doxy/doxygen_output/html
42 rm -rf /tmp/bcp/boost_1_66_0/libs/filesystem/example/
43
44 # https://stackoverflow.com/questions/1655372/longest-line-in-a-file
45 LONGEST_FILENAME=`find /tmp/bcp/ | awk '{print length, $0}' | sort -nr | head -1`
46 LONGEST=`echo "$LONGEST_FILENAME" | cut -d ' ' -f 1`
47
48 echo
49 echo "Longest filename (${LONGEST} characters):"
50 echo "${LONGEST_FILENAME}"
51 echo
52
53 if [ ${LONGEST} -ge 128 ]; then
54 echo "ERROR: Too long filename for Windows!"
55 echo
56 exit -1
57 fi
37 58
38 echo "Compressing the subset..." 59 echo "Compressing the subset..."
60 cd /tmp/bcp
39 tar cfz boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz boost_${BOOST_VERSION} 61 tar cfz boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz boost_${BOOST_VERSION}
40 ls -l boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz 62 ls -l boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz
41 md5sum boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz 63 md5sum boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz
42 readlink -f boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz 64 readlink -f boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz