diff --git a/.gitignore b/.gitignore index d135a31..d322cc2 100644 --- a/.gitignore +++ b/.gitignore @@ -37,3 +37,4 @@ cppcheck-1.44.tar.bz2 /cppcheck-1.84.tar.gz /cppcheck-1.85.tar.gz /cppcheck-1.86.tar.gz +/cppcheck-1.87.tar.gz diff --git a/cppcheck-1.78-cfgdir.patch b/cppcheck-1.78-cfgdir.patch deleted file mode 100644 index f42f0bb..0000000 --- a/cppcheck-1.78-cfgdir.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff -up cppcheck-1.78/CMakeLists.txt.orig cppcheck-1.78/CMakeLists.txt -diff -up cppcheck-1.78/cmake/options.cmake.orig cppcheck-1.78/cmake/options.cmake ---- cppcheck-1.78/cmake/options.cmake.orig 2017-04-01 11:05:13.000000000 +0200 -+++ cppcheck-1.78/cmake/options.cmake 2017-04-09 14:13:30.130818011 +0200 -@@ -23,6 +23,11 @@ option(ANALYZE_DATAFLOW "Clang dynam - option(WARNINGS_ARE_ERRORS "Treat warnings as errors" OFF) - option(WARNINGS_ANSI_ISO "Issue all the mandatory diagnostics Listed in C standard" ON) - -+option(CFGDIR "Configuration file directory" OFF) -+if(CFGDIR) -+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DCFG=${CFGDIR}") -+endif(CFGDIR) -+ - set(USE_MATCHCOMPILER "Auto" CACHE STRING "Usage of match compliler") - set_property(CACHE USE_MATCHCOMPILER PROPERTY STRINGS Auto Off On Verify) - if (USE_MATCHCOMPILER STREQUAL "Auto") diff --git a/cppcheck-1.85-tinyxml.patch b/cppcheck-1.85-tinyxml.patch deleted file mode 100644 index 75d1e06..0000000 --- a/cppcheck-1.85-tinyxml.patch +++ /dev/null @@ -1,83 +0,0 @@ -diff -ur cppcheck-1.85.orig/cli/CMakeLists.txt cppcheck-1.85/cli/CMakeLists.txt ---- cppcheck-1.85.orig/cli/CMakeLists.txt 2018-10-14 14:56:51.000000000 +0200 -+++ cppcheck-1.85/cli/CMakeLists.txt 2018-11-08 15:31:17.285998825 +0100 -@@ -1,5 +1,4 @@ - include_directories(${PROJECT_SOURCE_DIR}/lib/) --include_directories(SYSTEM ${PROJECT_SOURCE_DIR}/externals/tinyxml/) - include_directories(${PROJECT_SOURCE_DIR}/externals/simplecpp/) - - file(GLOB hdrs "*.h") -@@ -8,13 +7,14 @@ - list(REMOVE_ITEM srcs ${mainfile}) - - add_library(cli_objs OBJECT ${hdrs} ${srcs}) --add_executable(cppcheck ${hdrs} ${mainfile} $ $ $ $) -+add_executable(cppcheck ${hdrs} ${mainfile} $ $ $) - if (HAVE_RULES) - target_link_libraries(cppcheck pcre) - endif() - if (WIN32 AND NOT BORLAND) - target_link_libraries(cppcheck Shlwapi.lib) - endif() -+target_link_libraries(cppcheck tinyxml2) - - install(TARGETS cppcheck - RUNTIME DESTINATION ${CMAKE_INSTALL_FULL_BINDIR} -diff -ur cppcheck-1.85.orig/CMakeLists.txt cppcheck-1.85/CMakeLists.txt ---- cppcheck-1.85.orig/CMakeLists.txt 2018-10-14 14:56:51.000000000 +0200 -+++ cppcheck-1.85/CMakeLists.txt 2018-11-08 15:28:12.574001686 +0100 -@@ -16,7 +16,6 @@ - enable_testing() - endif() - --add_subdirectory(externals/tinyxml) - add_subdirectory(externals/simplecpp) - add_subdirectory(lib) # CppCheck Library - add_subdirectory(cli) # Client application -diff -ur cppcheck-1.85.orig/gui/CMakeLists.txt cppcheck-1.85/gui/CMakeLists.txt ---- cppcheck-1.85.orig/gui/CMakeLists.txt 2018-10-14 14:56:51.000000000 +0200 -+++ cppcheck-1.85/gui/CMakeLists.txt 2018-11-08 15:28:12.575001686 +0100 -@@ -10,7 +10,6 @@ - endif() - - include_directories(${PROJECT_SOURCE_DIR}/lib/) -- include_directories(SYSTEM ${PROJECT_SOURCE_DIR}/externals/tinyxml/) - - file(GLOB hdrs "*.h") - file(GLOB srcs "*.cpp") -@@ -20,11 +19,11 @@ - QT5_ADD_RESOURCES(resources "gui.qrc") - QT5_ADD_TRANSLATION(qms ${tss}) - -- add_executable(cppcheck-gui ${hdrs} ${srcs} ${uis_hdrs} ${resources} ${qms} $ $ $) -+ add_executable(cppcheck-gui ${hdrs} ${srcs} ${uis_hdrs} ${resources} ${qms} $ $) - if (HAVE_RULES) - target_link_libraries(cppcheck-gui pcre) - endif() -- target_link_libraries(cppcheck-gui Qt5::Core Qt5::Gui Qt5::Widgets Qt5::PrintSupport) -+ target_link_libraries(cppcheck-gui tinyxml2 Qt5::Core Qt5::Gui Qt5::Widgets Qt5::PrintSupport) - - install(TARGETS cppcheck-gui RUNTIME DESTINATION ${CMAKE_INSTALL_FULL_BINDIR} COMPONENT applications) - install(FILES ${qms} DESTINATION ${CMAKE_INSTALL_FULL_BINDIR} COMPONENT applications) -diff -ur cppcheck-1.85.orig/test/CMakeLists.txt cppcheck-1.85/test/CMakeLists.txt ---- cppcheck-1.85.orig/test/CMakeLists.txt 2018-10-14 14:56:51.000000000 +0200 -+++ cppcheck-1.85/test/CMakeLists.txt 2018-11-08 15:28:12.575001686 +0100 -@@ -1,16 +1,16 @@ - if (BUILD_TESTS) - - include_directories(${PROJECT_SOURCE_DIR}/lib/ ${PROJECT_SOURCE_DIR}/cli/) -- include_directories(SYSTEM ${PROJECT_SOURCE_DIR}/externals/tinyxml) - include_directories(${PROJECT_SOURCE_DIR}/externals/simplecpp/) - - file(GLOB hdrs "*.h") - file(GLOB srcs "*.cpp") - -- add_executable(testrunner ${hdrs} ${srcs} $ $ $ $) -+ add_executable(testrunner ${hdrs} ${srcs} $ $ $) - if (HAVE_RULES) - target_link_libraries(testrunner pcre) - endif() -+ target_link_libraries(testrunner tinyxml2) - - add_custom_target(copy_cfg ALL - COMMENT "Copying cfg files") diff --git a/cppcheck-1.87-cfgdir.patch b/cppcheck-1.87-cfgdir.patch new file mode 100644 index 0000000..82becc5 --- /dev/null +++ b/cppcheck-1.87-cfgdir.patch @@ -0,0 +1,14 @@ +diff -urp cppcheck-1.87.orig/cmake/options.cmake cppcheck-1.87/cmake/options.cmake +--- cppcheck-1.87.orig/cmake/options.cmake 2019-02-09 03:31:27.000000000 -0500 ++++ cppcheck-1.87/cmake/options.cmake 2019-02-09 13:17:25.237561852 -0500 +@@ -22,6 +22,10 @@ option(ANALYZE_UNDEFINED "Clang dynam + option(ANALYZE_DATAFLOW "Clang dynamic analyzer: general dynamic dataflow analysis." OFF) + option(WARNINGS_ARE_ERRORS "Treat warnings as errors" OFF) + option(WARNINGS_ANSI_ISO "Issue all the mandatory diagnostics Listed in C standard" ON) ++option(CFGDIR "Configuration file directory" OFF) ++if(CFGDIR) ++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DCFG=${CFGDIR}") ++endif(CFGDIR) + + set(USE_MATCHCOMPILER "Auto" CACHE STRING "Usage of match compiler") + set_property(CACHE USE_MATCHCOMPILER PROPERTY STRINGS Auto Off On Verify) diff --git a/cppcheck-1.87-tinyxml.patch b/cppcheck-1.87-tinyxml.patch new file mode 100644 index 0000000..d20a6f2 --- /dev/null +++ b/cppcheck-1.87-tinyxml.patch @@ -0,0 +1,84 @@ +diff -urp cppcheck-1.87.orig/cli/CMakeLists.txt cppcheck-1.87/cli/CMakeLists.txt +--- cppcheck-1.87.orig/cli/CMakeLists.txt 2019-02-09 03:31:27.000000000 -0500 ++++ cppcheck-1.87/cli/CMakeLists.txt 2019-02-09 13:31:37.543470390 -0500 +@@ -1,5 +1,4 @@ + include_directories(${PROJECT_SOURCE_DIR}/lib/) +-include_directories(SYSTEM ${PROJECT_SOURCE_DIR}/externals/tinyxml/) + include_directories(${PROJECT_SOURCE_DIR}/externals/simplecpp/) + + file(GLOB hdrs "*.h") +@@ -8,7 +7,7 @@ file(GLOB mainfile "main.cpp") + list(REMOVE_ITEM srcs ${mainfile}) + + add_library(cli_objs OBJECT ${hdrs} ${srcs}) +-add_executable(cppcheck ${hdrs} ${mainfile} $ $ $ $) ++add_executable(cppcheck ${hdrs} ${mainfile} $ $ $) + if (HAVE_RULES) + find_library(PCRE_LIBRARY pcre) + target_link_libraries(cppcheck ${PCRE_LIBRARY}) +@@ -18,6 +17,7 @@ endif() + if (WIN32 AND NOT BORLAND) + target_link_libraries(cppcheck Shlwapi.lib) + endif() ++target_link_libraries(cppcheck tinyxml2) + + install(TARGETS cppcheck + RUNTIME DESTINATION ${CMAKE_INSTALL_FULL_BINDIR} +diff -urp cppcheck-1.87.orig/CMakeLists.txt cppcheck-1.87/CMakeLists.txt +--- cppcheck-1.87.orig/CMakeLists.txt 2019-02-09 03:31:27.000000000 -0500 ++++ cppcheck-1.87/CMakeLists.txt 2019-02-09 13:30:01.410480706 -0500 +@@ -16,7 +16,6 @@ if (BUILD_TESTS) + enable_testing() + endif() + +-add_subdirectory(externals/tinyxml) + add_subdirectory(externals/simplecpp) + add_subdirectory(lib) # CppCheck Library + add_subdirectory(cli) # Client application +diff -urp cppcheck-1.87.orig/gui/CMakeLists.txt cppcheck-1.87/gui/CMakeLists.txt +--- cppcheck-1.87.orig/gui/CMakeLists.txt 2019-02-09 03:31:27.000000000 -0500 ++++ cppcheck-1.87/gui/CMakeLists.txt 2019-02-09 13:30:01.410480706 -0500 +@@ -10,7 +10,6 @@ if (BUILD_GUI) + endif() + + include_directories(${PROJECT_SOURCE_DIR}/lib/) +- include_directories(SYSTEM ${PROJECT_SOURCE_DIR}/externals/tinyxml/) + + file(GLOB hdrs "*.h") + file(GLOB srcs "*.cpp") +@@ -20,11 +19,11 @@ if (BUILD_GUI) + QT5_ADD_RESOURCES(resources "gui.qrc") + QT5_ADD_TRANSLATION(qms ${tss}) + +- add_executable(cppcheck-gui ${hdrs} ${srcs} ${uis_hdrs} ${resources} ${qms} $ $ $) ++ add_executable(cppcheck-gui ${hdrs} ${srcs} ${uis_hdrs} ${resources} ${qms} $ $) + if (HAVE_RULES) + target_link_libraries(cppcheck-gui pcre) + endif() +- target_link_libraries(cppcheck-gui Qt5::Core Qt5::Gui Qt5::Widgets Qt5::PrintSupport) ++ target_link_libraries(cppcheck-gui tinyxml2 Qt5::Core Qt5::Gui Qt5::Widgets Qt5::PrintSupport) + + install(TARGETS cppcheck-gui RUNTIME DESTINATION ${CMAKE_INSTALL_FULL_BINDIR} COMPONENT applications) + install(FILES ${qms} DESTINATION ${CMAKE_INSTALL_FULL_BINDIR} COMPONENT applications) +diff -urp cppcheck-1.87.orig/test/CMakeLists.txt cppcheck-1.87/test/CMakeLists.txt +--- cppcheck-1.87.orig/test/CMakeLists.txt 2019-02-09 03:31:27.000000000 -0500 ++++ cppcheck-1.87/test/CMakeLists.txt 2019-02-09 13:30:01.410480706 -0500 +@@ -1,16 +1,16 @@ + if (BUILD_TESTS) + + include_directories(${PROJECT_SOURCE_DIR}/lib/ ${PROJECT_SOURCE_DIR}/cli/) +- include_directories(SYSTEM ${PROJECT_SOURCE_DIR}/externals/tinyxml) + include_directories(${PROJECT_SOURCE_DIR}/externals/simplecpp/) + + file(GLOB hdrs "*.h") + file(GLOB srcs "*.cpp") + +- add_executable(testrunner ${hdrs} ${srcs} $ $ $ $) ++ add_executable(testrunner ${hdrs} ${srcs} $ $ $) + if (HAVE_RULES) + target_link_libraries(testrunner pcre) + endif() ++ target_link_libraries(testrunner tinyxml2) + + add_custom_target(copy_cfg ALL + COMMENT "Copying cfg files") diff --git a/cppcheck.spec b/cppcheck.spec index c84fca0..9ad36a5 100644 --- a/cppcheck.spec +++ b/cppcheck.spec @@ -2,19 +2,19 @@ %global gui 1 Name: cppcheck -Version: 1.86 -Release: 2%{?dist} +Version: 1.87 +Release: 1%{?dist} Summary: Tool for static C/C++ code analysis License: GPLv3+ URL: http://cppcheck.wiki.sourceforge.net/ Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz # Use system tinyxml2 -Patch0: cppcheck-1.85-tinyxml.patch +Patch0: cppcheck-1.87-tinyxml.patch # Fix location of translations Patch1: cppcheck-1.84-translations.patch # Set location of config files -Patch2: cppcheck-1.78-cfgdir.patch +Patch2: cppcheck-1.87-cfgdir.patch # Select python2 explicitly Patch3: cppcheck-1.85-htmlreport-python2.patch @@ -132,6 +132,9 @@ cd objdir-%{_target_platform}/bin %{_bindir}/cppcheck-htmlreport %changelog +* Sat Feb 09 2019 Steve Grubb - 1.87-1 +- Update to 1.87. + * Thu Jan 31 2019 Fedora Release Engineering - 1.86-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild diff --git a/sources b/sources index 6eae46a..1105b5f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (cppcheck-1.86.tar.gz) = 59cec55b8408e8f2e2e7172bce69350c248bc3185a0938b523c44a58f98b344e11aef957ec1b7a7b2bc7a876660b2683e51f54b76f0b550f9549497c29453655 +SHA512 (cppcheck-1.87.tar.gz) = b0149002b40260c1488904929296403722a66b84263b41d0097c3caed28265332766c114f0d1f378ea6c7e73ab973ea71ab89c6744f6cc818f22de08933e6766