Mercurial > hg > orthanc
changeset 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 | 1c37d6af7aa5 |
children | 832217e4e872 |
files | Resources/CMake/BoostConfiguration.cmake Resources/CMake/BoostConfiguration.sh |
diffstat | 2 files changed, 24 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/Resources/CMake/BoostConfiguration.cmake Wed Apr 11 12:35:59 2018 +0200 +++ b/Resources/CMake/BoostConfiguration.cmake Wed Apr 11 16:23:24 2018 +0200 @@ -55,7 +55,7 @@ set(BOOST_NAME boost_1_66_0) set(BOOST_BCP_SUFFIX bcpdigest-1.3.2) - set(BOOST_MD5 "4e15b0fd883528be159be9661b6ba20a") + set(BOOST_MD5 "e509e66140e8f2fd4d326b0052825f52") set(BOOST_URL "http://www.orthanc-server.com/downloads/third-party/${BOOST_NAME}_${BOOST_BCP_SUFFIX}.tar.gz") set(BOOST_SOURCES_DIR ${CMAKE_BINARY_DIR}/${BOOST_NAME})
--- a/Resources/CMake/BoostConfiguration.sh Wed Apr 11 12:35:59 2018 +0200 +++ b/Resources/CMake/BoostConfiguration.sh Wed Apr 11 16:23:24 2018 +0200 @@ -33,9 +33,31 @@ echo "Generating the subset..." mkdir -p /tmp/bcp/boost_${BOOST_VERSION} 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} -cd /tmp/bcp + +echo "Removing documentation..." +rm -rf /tmp/bcp/boost_1_66_0/libs/locale/doc/html +rm -rf /tmp/bcp/boost_1_66_0/libs/algorithm/doc/html +rm -rf /tmp/bcp/boost_1_66_0/libs/geometry/doc/html +rm -rf /tmp/bcp/boost_1_66_0/libs/geometry/doc/doxy/doxygen_output/html +rm -rf /tmp/bcp/boost_1_66_0/libs/filesystem/example/ + +# https://stackoverflow.com/questions/1655372/longest-line-in-a-file +LONGEST_FILENAME=`find /tmp/bcp/ | awk '{print length, $0}' | sort -nr | head -1` +LONGEST=`echo "$LONGEST_FILENAME" | cut -d ' ' -f 1` + +echo +echo "Longest filename (${LONGEST} characters):" +echo "${LONGEST_FILENAME}" +echo + +if [ ${LONGEST} -ge 128 ]; then + echo "ERROR: Too long filename for Windows!" + echo + exit -1 +fi echo "Compressing the subset..." +cd /tmp/bcp tar cfz boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz boost_${BOOST_VERSION} ls -l boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz md5sum boost_${BOOST_VERSION}_bcpdigest-${ORTHANC_VERSION}.tar.gz