Mathieu Malaterre pushed to branch master at Debian Med / orthanc-wsi
Commits: c09c428c by Adrian Bunk at 2021-11-24T13:43:16+02:00 Stop forcing C++ 11, dcmtk 3.6.6 needs C++ >= 14 - - - - - cde6d86c by Mathieu Malaterre at 2021-11-24T12:28:28+00:00 Merge branch 'master' into 'master' Stop forcing C++ 11, dcmtk 3.6.6 needs C++ >= 14 See merge request med-team/orthanc-wsi!1 - - - - - 3 changed files: - + debian/patches/donotforcec++11 - debian/patches/series - debian/patches/static-framework Changes: ===================================== debian/patches/donotforcec++11 ===================================== @@ -0,0 +1,42 @@ +Description: Remove hardcoded c++11 +Author: Adrian Bunk <[email protected]> + +index e1ebcc6..4966d9f 100644 +--- a/Resources/Orthanc/CMake/DownloadOrthancFramework.cmake ++++ b/Resources/Orthanc/CMake/DownloadOrthancFramework.cmake +@@ -461,35 +461,6 @@ if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "system") + message(FATAL_ERROR "Please install the libjsoncpp-dev package") + endif() + +- # Switch to the C++11 standard if the version of JsonCpp is 1.y.z +- # (same as variable JSONCPP_CXX11 in the source code of Orthanc) +- if (EXISTS ${JSONCPP_INCLUDE_DIR}/json/version.h) +- file(STRINGS +- "${JSONCPP_INCLUDE_DIR}/json/version.h" +- JSONCPP_VERSION_MAJOR1 REGEX +- ".*define JSONCPP_VERSION_MAJOR.*") +- +- if (NOT JSONCPP_VERSION_MAJOR1) +- message(FATAL_ERROR "Unable to extract the major version of JsonCpp") +- endif() +- +- string(REGEX REPLACE +- ".*JSONCPP_VERSION_MAJOR.*([0-9]+)$" "\\1" +- JSONCPP_VERSION_MAJOR ${JSONCPP_VERSION_MAJOR1}) +- message("JsonCpp major version: ${JSONCPP_VERSION_MAJOR}") +- +- if (JSONCPP_VERSION_MAJOR GREATER 0) +- message("Switching to C++11 standard, as version of JsonCpp is >= 1.0.0") +- if (CMAKE_COMPILER_IS_GNUCXX) +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11") +- elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") +- endif() +- endif() +- else() +- message("Unable to detect the major version of JsonCpp, assuming < 1.0.0") +- endif() +- + # Look for mandatory dependency Boost (cf. BoostConfiguration.cmake) + include(FindBoost) + find_package(Boost COMPONENTS filesystem thread system date_time regex ${ORTHANC_BOOST_COMPONENTS}) ===================================== debian/patches/series ===================================== @@ -1,3 +1,4 @@ +donotforcec++11 includes orthanc-framework static-framework ===================================== debian/patches/static-framework ===================================== @@ -27,7 +27,7 @@ Index: OrthancWSI-1.0/Resources/Orthanc/CMake/DownloadOrthancFramework.cmake if (CMAKE_SYSTEM_NAME STREQUAL "Windows" AND CMAKE_COMPILER_IS_GNUCXX) # MinGW -@@ -442,113 +448,75 @@ if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "s +@@ -442,84 +448,46 @@ if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "s include(${CMAKE_CURRENT_LIST_DIR}/AutoGeneratedCode.cmake) set(EMBED_RESOURCES_PYTHON ${CMAKE_CURRENT_LIST_DIR}/EmbedResources.py) @@ -75,35 +75,6 @@ Index: OrthancWSI-1.0/Resources/Orthanc/CMake/DownloadOrthancFramework.cmake - if (NOT HAVE_JSONCPP_H) - message(FATAL_ERROR "Please install the libjsoncpp-dev package") - endif() -- -- # Switch to the C++11 standard if the version of JsonCpp is 1.y.z -- # (same as variable JSONCPP_CXX11 in the source code of Orthanc) -- if (EXISTS ${JSONCPP_INCLUDE_DIR}/json/version.h) -- file(STRINGS -- "${JSONCPP_INCLUDE_DIR}/json/version.h" -- JSONCPP_VERSION_MAJOR1 REGEX -- ".*define JSONCPP_VERSION_MAJOR.*") -- -- if (NOT JSONCPP_VERSION_MAJOR1) -- message(FATAL_ERROR "Unable to extract the major version of JsonCpp") -- endif() -- -- string(REGEX REPLACE -- ".*JSONCPP_VERSION_MAJOR.*([0-9]+)$" "\\1" -- JSONCPP_VERSION_MAJOR ${JSONCPP_VERSION_MAJOR1}) -- message("JsonCpp major version: ${JSONCPP_VERSION_MAJOR}") -- -- if (JSONCPP_VERSION_MAJOR GREATER 0) -- message("Switching to C++11 standard, as version of JsonCpp is >= 1.0.0") -- if (CMAKE_COMPILER_IS_GNUCXX) -- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11") -- elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") -- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") -- endif() -- endif() -- else() -- message("Unable to detect the major version of JsonCpp, assuming < 1.0.0") -- endif() + message("JsonCpp include dir: ${JSONCPP_INCLUDE_DIR}") + include_directories(${JSONCPP_INCLUDE_DIR}) @@ -114,21 +85,11 @@ Index: OrthancWSI-1.0/Resources/Orthanc/CMake/DownloadOrthancFramework.cmake + if (NOT HAVE_JSONCPP_H) + message(FATAL_ERROR "Please install the libjsoncpp-dev package") + endif() -+ -+ # Switch to the C++11 standard if the version of JsonCpp is 1.y.z -+ # (same as variable JSONCPP_CXX11 in the source code of Orthanc) -+ if (EXISTS ${JSONCPP_INCLUDE_DIR}/json/version.h) -+ file(STRINGS -+ "${JSONCPP_INCLUDE_DIR}/json/version.h" -+ JSONCPP_VERSION_MAJOR1 REGEX -+ ".*define JSONCPP_VERSION_MAJOR.*") - if (NOT Boost_FOUND) - message(FATAL_ERROR "Unable to locate Boost on this system") -+ if (NOT JSONCPP_VERSION_MAJOR1) -+ message(FATAL_ERROR "Unable to extract the major version of JsonCpp") - endif() - +- endif() +- - include_directories(${Boost_INCLUDE_DIRS}) - link_libraries(${Boost_LIBRARIES}) - @@ -174,26 +135,12 @@ Index: OrthancWSI-1.0/Resources/Orthanc/CMake/DownloadOrthancFramework.cmake - include(FindOpenSSL) - if (NOT ${OPENSSL_FOUND}) - message(FATAL_ERROR "Unable to find OpenSSL") -+ string(REGEX REPLACE -+ ".*JSONCPP_VERSION_MAJOR.*([0-9]+)$" "\\1" -+ JSONCPP_VERSION_MAJOR ${JSONCPP_VERSION_MAJOR1}) -+ message("JsonCpp major version: ${JSONCPP_VERSION_MAJOR}") -+ -+ if (JSONCPP_VERSION_MAJOR GREATER 0) -+ message("Switching to C++11 standard, as version of JsonCpp is >= 1.0.0") -+ if (CMAKE_COMPILER_IS_GNUCXX) -+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11") -+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") -+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") - endif() +- endif() - include_directories(${OPENSSL_INCLUDE_DIR}) - link_libraries(${OPENSSL_LIBRARIES}) - endif() -+ else() -+ message("Unable to detect the major version of JsonCpp, assuming < 1.0.0") - endif() +- endif() +- endif() - -+ # Look for Orthanc framework shared library include(CheckCXXSymbolExists) View it on GitLab: https://salsa.debian.org/med-team/orthanc-wsi/-/compare/78743eb5afd5db86dd91569bec10539e69dd77ad...cde6d86c124579c2bb5018c6db055f704af3652a -- View it on GitLab: https://salsa.debian.org/med-team/orthanc-wsi/-/compare/78743eb5afd5db86dd91569bec10539e69dd77ad...cde6d86c124579c2bb5018c6db055f704af3652a You're receiving this email because of your account on salsa.debian.org.
_______________________________________________ debian-med-commit mailing list [email protected] https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/debian-med-commit
