From e4c6f9e8a03ecbaa699a8fa204a453da23c741a8 Mon Sep 17 00:00:00 2001 From: Kai Pastor Date: Tue, 15 Sep 2020 07:07:36 +0200 Subject: [PATCH] doxygen: Update to 1.8.20 --- doxygen-1.8.13.cmake => doxygen-1.8.20.cmake | 67 +++++--------------- 1 file changed, 17 insertions(+), 50 deletions(-) rename doxygen-1.8.13.cmake => doxygen-1.8.20.cmake (63%) diff --git a/doxygen-1.8.13.cmake b/doxygen-1.8.20.cmake similarity index 63% rename from doxygen-1.8.13.cmake rename to doxygen-1.8.20.cmake index 4023843d..1c296c96 100644 --- a/doxygen-1.8.13.cmake +++ b/doxygen-1.8.20.cmake @@ -27,11 +27,11 @@ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -set(version 1.8.13) -set(download_hash SHA256=af667887bd7a87dc0dbf9ac8d86c96b552dfb8ca9c790ed1cbffaa6131573f6b) -set(patch_version ${version}-10) -set(patch_hash SHA256=e4fb3fa4266998c4192dcdbb1efb563360f1f009d9a80d445721d526de4f9482) -set(base_url https://snapshot.debian.org/archive/debian/20180312T232337Z/pool/main/d/doxygen/) +set(version 1.8.20) +set(download_hash SHA256=3dbdf8814d6e68233d5149239cb1f0b40b4e7b32eef2fd53de8828fedd7aca15) +set(patch_version ${version}-4) +set(patch_hash SHA256=e7e1ea9f8dfb4decdf2617e67124ea1f90d7ecd361f5c54943603ed0be6c2e72) +set(base_url https://snapshot.debian.org/archive/debian/20201002T144451Z/pool/main/d/doxygen/) option(USE_SYSTEM_DOXYGEN "Use the system DOXYGEN if possible" ON) @@ -45,50 +45,15 @@ set(test_system_doxygen [[ endif() endif() if(CMAKE_C_COMPILER_ID MATCHES "Clang") - set(extra_flags "-Wno-tautological-constant-out-of-range-compare -Wno-deprecated-declarations" PARENT_SCOPE) + set(extra_flags "-Wno-return-type -Wno-tautological-constant-out-of-range-compare" PARENT_SCOPE) elseif(CMAKE_C_COMPILER_ID STREQUAL "GNU") - set(extra_flags "-Wno-return-type -Wno-deprecated" PARENT_SCOPE) + set(extra_flags "-Wno-return-type -Wno-write-strings" PARENT_SCOPE) else() set(extra_flags "" PARENT_SCOPE) endif() ]]) -# Fix mingw64 builds -# https://github.com/msys2/MINGW-packages/blob/b99b3d396d8d3dfcee41548d1b96729464bde4e5/mingw-w64-doxygen/fix-casts.patch -set(fix-casts_patch [[ ---- doxygen-1.8.6/qtools/qcstring.cpp.orig 2013-05-19 19:12:31.000000000 +0400 -+++ doxygen-1.8.6/qtools/qcstring.cpp 2014-04-04 06:54:07.313800000 +0400 -@@ -476,7 +476,7 @@ - if ( to > first && *(to-1) == 0x20 ) - to--; - *to = '\0'; -- result.resize( (int)((long)to - (long)result.data()) + 1 ); -+ result.resize( (int)(reinterpret_cast(to) - reinterpret_cast(result.data())) + 1 ); - return result; - } - -@@ -717,7 +717,7 @@ - int res; - uchar c; - if ( !s1 || !s2 ) -- return s1 == s2 ? 0 : (int)((long)s2 - (long)s1); -+ return s1 == s2 ? 0 : (int)(reinterpret_cast(s2) - reinterpret_cast(s1)); - for ( ; !(res = (c=tolower(*s1)) - tolower(*s2)); s1++, s2++ ) - if ( !c ) // strings are equal - break; -@@ -731,7 +731,7 @@ - int res; - uchar c; - if ( !s1 || !s2 ) -- return (int)((long)s2 - (long)s1); -+ return (int)(reinterpret_cast(s2) - reinterpret_cast(s1)); - for ( ; len--; s1++, s2++ ) { - if ( (res = (c=tolower(*s1)) - tolower(*s2)) ) - return res; -]]) - - superbuild_package( NAME doxygen-patches VERSION ${patch_version} @@ -110,18 +75,19 @@ superbuild_package( SOURCE URL ${base_url}doxygen_${version}.orig.tar.gz URL_HASH ${download_hash} - PATCH_COMMAND - patch -p1 -i fix-casts.patch + "${CMAKE_COMMAND}" + -Dpackage=doxygen-patches-${patch_version} + -P "${APPLY_PATCHES_SERIES}" COMMAND - sed -i -e "/set.ICONV_DIR/d" CMakeLists.txt + sed -e "/set.YACC_FLAGS/ s/set.*/set(YACC_FLAGS -Wno-deprecated)/" -i -- + CMakeLists.txt COMMAND - sed -i -e "/bigobj/d" CMakeLists.txt + sed -e "/BISON_EXECUTABLE/ s/ -o / -Wno-deprecated -o /" -i -- + CMakeLists.txt COMMAND - sed -i -e "s/mmacosx-version-min=10.5/mmacosx-version-min=10.11/" CMakeLists.txt - - SOURCE_WRITE - fix-casts.patch fix-casts_patch + sed -e "/set.PROJECT_WARNINGS/ s/set.*/set(PROJECT_WARNINGS )/" -i -- + cmake/CompilerWarnings.cmake USING USE_SYSTEM_DOXYGEN patch_version extra_flags BUILD_CONDITION ${test_system_doxygen} @@ -130,6 +96,7 @@ superbuild_package( "-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}" "-DCMAKE_C_FLAGS=${CMAKE_C_FLAGS} ${extra_flags}" "-DCMAKE_CXX_FLAGS=${CMAKE_CXX_FLAGS} ${extra_flags}" + -DCMAKE_BUILD_TYPE=Release -Denglish_only=1 INSTALL_COMMAND "${CMAKE_COMMAND}" --build . --target install/strip/fast