pkgsrc/devel/cppcheck/Makefile

65 lines
2.1 KiB
Makefile
Raw Normal View History

# $NetBSD: Makefile,v 1.36 2015/11/25 12:49:46 jperkin Exp $
Update cppcheck to 1.69. Patch from Jonathan Buschmann in PR pkg/49885. General changes: - Added flag --platform=native, when it is used type sizes and behaviour of host system are used - Backward compatibility for Libary files is now working. Future cppcheck versions will be able to use libraries written for previous versions - Windows 32 bit builds now set /LARGEADDRESSAWARE, so that they can use up to 4 GiB New checks: - Detect bad bitmask checks (usage of | where & should be used) - Suggest usage of "explicit" for constructors with a single parameter - Suggest usage of make_shared/make_unique - Warn about usage of malloc with auto_ptr - Detect redundant pointer operations like &*ptr Improvements: - Support std::array (C++11) - Detect same expressions in both branches of a ternary operator - New <container>-tags in libraries to configure STL (and similar) container types - Several improvements to ValueFlow analysis (for example support for default function arguments) - Improved buffer overrun and memory leak checking - Removed a bunch of redundant checking code - Removed several simplifications - Stronger matching of library functions - Lots of additions to std.cfg and posix.cfg - New library for Microsoft SAL (microsoft_sal.cfg) - Improved C++11 template parsing (">>" as closing brackets, variadic templates) - Added statistics to htmlreport GUI: - Fixed language selection Additionally, lots of false positives and bugs have been fixed and several existing checks have been improved.
2015-05-08 21:35:33 +02:00
DISTNAME= cppcheck-1.69
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=cppcheck/}
EXTRACT_SUFX= .tar.bz2
MAINTAINER= reed@reedmedia.net
HOMEPAGE= http://cppcheck.sourceforge.net/
COMMENT= Tool for static C/C++ code analysis
LICENSE= gnu-gpl-v3
BUILD_DEPENDS+= libxslt-[0-9]*:../../textproc/libxslt
BUILD_DEPENDS+= docbook-xsl-[0-9]*:../../textproc/docbook-xsl
Update to 1.66: Cppcheck-1.66 has been released. New checks: - Compare pointer with '\0' - Assigning boolean expression to floating point variables Improvements: - Much improved AST - Much improved ValueFlow analysis - ValueFlow and AST now used by much more checks, improving checking accuracy and performance - Checking for self assignment now supports more complex expressions - Returning references to literals or references to calculation results is detected - Enhanced support for commutative operators in duplicate expression checking - Improved template/enum parsing - Much improved htmlreport - Definition of POD types in .cfg files - Definition of minsize for buffer arguments in .cfg files for buffer overflow checking - Fixed handling of #error: Do not report them if -f and -D are used together - New .cfg file for AVR platform - Generate xml dump of AST/ValueFlow/SymbolDatabase/TokenList if --dump is given - Improved performance in several cases - Windows Builds: Now compiled with VS2013, linked against Qt 5.3.1 GUI: - Platform settings are being saved now - Improved handling of (invalid) .cfg files - Use Win32W as default platform on Windows Additionally, a large number of false positives and crashs has been fixed. Cppcheck-1.65 has been released. General changes: Cppcheck requires a C++11 compiler supporting the common subset of features supported by GCC 4.4, Visual Studio 2010 and Clang 2.9 Problems with packaging and windows installer introduced in last release were fixed Improvements: Much improved support of complex combinations of function pointers, arrays and references Better handling of syntax errors Better detection of stack variables passed to free() Much improved value flow analysis More robust error detection in several checks due to usage of AST Better handling of unknown Macros in function declarations Allocation/Deallocation functions can be extend across different .cfg files Better handling of some C++11 language features like enum class, in-class member initializers Detect calling (std::)abs() with bool argument New checks: Check for noexcept and __attribute__((nothrow)) correctness Check for unhandled exceptions when exception specifiers are used Access to empty STL containers Repositioning operation on a file opened in append mode Find nested redundant if-statements (was experimental before) Additionally, a large number of false positives and crashs has been fixed. cppcheck-1.64 has been released. Value Flow A new value flow analysis has been added. It is generic so the same analysis can be reused by various checkers - previously many checkers have had their own value flow and control flow analysis. The new value flow analysis performs context sensitive cross-function analysis. All checkers that uses this will automatically have cross-function context sensitive value flow analysis. The new analysis is gradually introduced in the checkers - the old analysis in a checker is kept until it is redundant. The new value flow analysis is so far used to detect: division by zero null pointer dereference array index out of bounds invalid function argument Other Improvements Improved configurations for gtk, posix, sdl, std, windows Warn when using negative allocation size Check 2nd parameter for memset Cppcheck-1.63 has been released. Maintainers: The .cfg files are needed by cppcheck. Either put them in a subfolder cfg where the binary is. Otherwise compile cppcheck with CFGDIR to specify an arbitrary path where you put the .cfg files. New check: * Using pointer addition result in condition 'if (p+1)' - either a dereference is forgotten or it depends on UB (the result is only 0 if there is overflow, which is UB). Improved checks: * Leaks - ignoring return value of allocation function * Uninitialized vars - check how uninitialized malloc data is used * Rewritten 'calculation in sizeof' using syntax tree * Rewritten 'clarify calculation' using syntax tree * Rewritten 'logical disjunction' using syntax tree * Rewritten 'duplicate expressions' using syntax tree * Rewritten 'invalidFunctionUsage' that uses the *.cfg files GUI: * Library files can be enabled in the project dialog * Suppressions can be specified in the project dialog Other: * Cppcheck is now continuosly scanning all the source code in the debian archive. Results: http://cppcheck.sourceforge.net/devinfo/daca2-report/daca2.html * Fixes of templates handling, hangs, crashes and false positives cppcheck-1.62 New checks * Divide with variable and then compare to see if variable is 0 * Duplicated inherited member Improved checking: * handling of >> in templates * format string checking * comparing bool result with integer * standard isgreater()/islower() functions * standard math functions * reassigning struct members Htmlreport xml-version 2 is now handled New checks: * arithmetical usage of inf/nan result * suspicious usage of comma in return statement * sizeof(void) Improved checking: * better simplification of strlen * improved handling of array member variables 'x[y].z..' * Specific improvements in checks for buffer overruns, format strings, uninitialized variables Command line: * Using both --max-configs and -D. Normally when -D is used, Cppcheck will only check the given configuration. By using --max-configs also, you can tell Cppcheck to check more configurations. * Added --library and --check-library. Graphical user interface: * Somewhat improved response when stopping checking Cppcheck core: * Extending checking with configuration files. Cppcheck has internal knowledge for standard C/C++ functions. Knowledge for libraries and environments can be specified using configuration files. * Rules: added <tokenlist> that allow you to check 'raw' code and 'normal' code. In the 'raw' code, the comments and #include are already taken care of, but the #define statements can be analysed.
2014-08-07 13:35:10 +02:00
DEPENDS+= ${PYPKGPREFIX}-pygments-[0-9]*:../../textproc/py-pygments
Update to 1.48. Ok reed except for the cmake dependency :) Release notes for 1.48 There are no major new features in 1.48. There are more and better checks. New check: Wrong usage of ! operator in conditions. Example: if (!x == 0) { New check: Use "throw" without arguments to rethrow exceptions. New check: Comparison of substring with string literal will always/never match because size doesn't match. New check: Postfix increment of boolean New check: Clarify condition with parantheses (when there are assignment + comparison) Example: if (a = b > 0) { Release notes for 1.47 It is now possible to exclude files and folders from the analysis. Use -i on the command line (i=ignore). Custom rules can now be created using regular expressions. To read more about creating custom rules, see http://sourceforge.net/projects/cppcheck/files/Articles/ A new XML format is launched. To use this format, the --xml-version=2 is used. The new xml format is incompatible with the xml format used in previous versions. The old XML format will still be used unless --xml-version=2 is given, so your existing scripts, tools and plugins should still work. New check: sizeof used on array variable that is a function parameter. The expected bahaviour is most likely that the sizeof result is the size of the array, but the actual sizeof result is the size of the pointer. New check: catching exception by value. It is better to catch by reference for various reasons. New check: memset calls filling 0 bytes. The given size might be wrong.
2011-05-29 13:52:12 +02:00
USE_LANGUAGES= c c++
USE_TOOLS+= gmake
BUILD_TARGET= all man
BUILD_MAKE_FLAGS+= DB2MAN=${LOCALBASE}/share/xsl/docbook/manpages/docbook.xsl
Update to 1.66: Cppcheck-1.66 has been released. New checks: - Compare pointer with '\0' - Assigning boolean expression to floating point variables Improvements: - Much improved AST - Much improved ValueFlow analysis - ValueFlow and AST now used by much more checks, improving checking accuracy and performance - Checking for self assignment now supports more complex expressions - Returning references to literals or references to calculation results is detected - Enhanced support for commutative operators in duplicate expression checking - Improved template/enum parsing - Much improved htmlreport - Definition of POD types in .cfg files - Definition of minsize for buffer arguments in .cfg files for buffer overflow checking - Fixed handling of #error: Do not report them if -f and -D are used together - New .cfg file for AVR platform - Generate xml dump of AST/ValueFlow/SymbolDatabase/TokenList if --dump is given - Improved performance in several cases - Windows Builds: Now compiled with VS2013, linked against Qt 5.3.1 GUI: - Platform settings are being saved now - Improved handling of (invalid) .cfg files - Use Win32W as default platform on Windows Additionally, a large number of false positives and crashs has been fixed. Cppcheck-1.65 has been released. General changes: Cppcheck requires a C++11 compiler supporting the common subset of features supported by GCC 4.4, Visual Studio 2010 and Clang 2.9 Problems with packaging and windows installer introduced in last release were fixed Improvements: Much improved support of complex combinations of function pointers, arrays and references Better handling of syntax errors Better detection of stack variables passed to free() Much improved value flow analysis More robust error detection in several checks due to usage of AST Better handling of unknown Macros in function declarations Allocation/Deallocation functions can be extend across different .cfg files Better handling of some C++11 language features like enum class, in-class member initializers Detect calling (std::)abs() with bool argument New checks: Check for noexcept and __attribute__((nothrow)) correctness Check for unhandled exceptions when exception specifiers are used Access to empty STL containers Repositioning operation on a file opened in append mode Find nested redundant if-statements (was experimental before) Additionally, a large number of false positives and crashs has been fixed. cppcheck-1.64 has been released. Value Flow A new value flow analysis has been added. It is generic so the same analysis can be reused by various checkers - previously many checkers have had their own value flow and control flow analysis. The new value flow analysis performs context sensitive cross-function analysis. All checkers that uses this will automatically have cross-function context sensitive value flow analysis. The new analysis is gradually introduced in the checkers - the old analysis in a checker is kept until it is redundant. The new value flow analysis is so far used to detect: division by zero null pointer dereference array index out of bounds invalid function argument Other Improvements Improved configurations for gtk, posix, sdl, std, windows Warn when using negative allocation size Check 2nd parameter for memset Cppcheck-1.63 has been released. Maintainers: The .cfg files are needed by cppcheck. Either put them in a subfolder cfg where the binary is. Otherwise compile cppcheck with CFGDIR to specify an arbitrary path where you put the .cfg files. New check: * Using pointer addition result in condition 'if (p+1)' - either a dereference is forgotten or it depends on UB (the result is only 0 if there is overflow, which is UB). Improved checks: * Leaks - ignoring return value of allocation function * Uninitialized vars - check how uninitialized malloc data is used * Rewritten 'calculation in sizeof' using syntax tree * Rewritten 'clarify calculation' using syntax tree * Rewritten 'logical disjunction' using syntax tree * Rewritten 'duplicate expressions' using syntax tree * Rewritten 'invalidFunctionUsage' that uses the *.cfg files GUI: * Library files can be enabled in the project dialog * Suppressions can be specified in the project dialog Other: * Cppcheck is now continuosly scanning all the source code in the debian archive. Results: http://cppcheck.sourceforge.net/devinfo/daca2-report/daca2.html * Fixes of templates handling, hangs, crashes and false positives cppcheck-1.62 New checks * Divide with variable and then compare to see if variable is 0 * Duplicated inherited member Improved checking: * handling of >> in templates * format string checking * comparing bool result with integer * standard isgreater()/islower() functions * standard math functions * reassigning struct members Htmlreport xml-version 2 is now handled New checks: * arithmetical usage of inf/nan result * suspicious usage of comma in return statement * sizeof(void) Improved checking: * better simplification of strlen * improved handling of array member variables 'x[y].z..' * Specific improvements in checks for buffer overruns, format strings, uninitialized variables Command line: * Using both --max-configs and -D. Normally when -D is used, Cppcheck will only check the given configuration. By using --max-configs also, you can tell Cppcheck to check more configurations. * Added --library and --check-library. Graphical user interface: * Somewhat improved response when stopping checking Cppcheck core: * Extending checking with configuration files. Cppcheck has internal knowledge for standard C/C++ functions. Knowledge for libraries and environments can be specified using configuration files. * Rules: added <tokenlist> that allow you to check 'raw' code and 'normal' code. In the 'raw' code, the comments and #include are already taken care of, but the #define statements can be analysed.
2014-08-07 13:35:10 +02:00
# tell cppcheck where its config is
MAKE_FLAGS+= CFGDIR=${PREFIX}/share/cppcheck/cfg
# rules support (needs pcre)
MAKE_FLAGS+= HAVE_RULES=yes
# use pkgsrc tinyxml2 instead of included copy
MAKE_FLAGS+= TINYXML= INCLUDE_FOR_LIB=-Ilib
MAKE_FLAGS+= INCLUDE_FOR_CLI=-Ilib
MAKE_FLAGS+= INCLUDE_FOR_TEST=-Ilib\ -Icli
Update to 1.66: Cppcheck-1.66 has been released. New checks: - Compare pointer with '\0' - Assigning boolean expression to floating point variables Improvements: - Much improved AST - Much improved ValueFlow analysis - ValueFlow and AST now used by much more checks, improving checking accuracy and performance - Checking for self assignment now supports more complex expressions - Returning references to literals or references to calculation results is detected - Enhanced support for commutative operators in duplicate expression checking - Improved template/enum parsing - Much improved htmlreport - Definition of POD types in .cfg files - Definition of minsize for buffer arguments in .cfg files for buffer overflow checking - Fixed handling of #error: Do not report them if -f and -D are used together - New .cfg file for AVR platform - Generate xml dump of AST/ValueFlow/SymbolDatabase/TokenList if --dump is given - Improved performance in several cases - Windows Builds: Now compiled with VS2013, linked against Qt 5.3.1 GUI: - Platform settings are being saved now - Improved handling of (invalid) .cfg files - Use Win32W as default platform on Windows Additionally, a large number of false positives and crashs has been fixed. Cppcheck-1.65 has been released. General changes: Cppcheck requires a C++11 compiler supporting the common subset of features supported by GCC 4.4, Visual Studio 2010 and Clang 2.9 Problems with packaging and windows installer introduced in last release were fixed Improvements: Much improved support of complex combinations of function pointers, arrays and references Better handling of syntax errors Better detection of stack variables passed to free() Much improved value flow analysis More robust error detection in several checks due to usage of AST Better handling of unknown Macros in function declarations Allocation/Deallocation functions can be extend across different .cfg files Better handling of some C++11 language features like enum class, in-class member initializers Detect calling (std::)abs() with bool argument New checks: Check for noexcept and __attribute__((nothrow)) correctness Check for unhandled exceptions when exception specifiers are used Access to empty STL containers Repositioning operation on a file opened in append mode Find nested redundant if-statements (was experimental before) Additionally, a large number of false positives and crashs has been fixed. cppcheck-1.64 has been released. Value Flow A new value flow analysis has been added. It is generic so the same analysis can be reused by various checkers - previously many checkers have had their own value flow and control flow analysis. The new value flow analysis performs context sensitive cross-function analysis. All checkers that uses this will automatically have cross-function context sensitive value flow analysis. The new analysis is gradually introduced in the checkers - the old analysis in a checker is kept until it is redundant. The new value flow analysis is so far used to detect: division by zero null pointer dereference array index out of bounds invalid function argument Other Improvements Improved configurations for gtk, posix, sdl, std, windows Warn when using negative allocation size Check 2nd parameter for memset Cppcheck-1.63 has been released. Maintainers: The .cfg files are needed by cppcheck. Either put them in a subfolder cfg where the binary is. Otherwise compile cppcheck with CFGDIR to specify an arbitrary path where you put the .cfg files. New check: * Using pointer addition result in condition 'if (p+1)' - either a dereference is forgotten or it depends on UB (the result is only 0 if there is overflow, which is UB). Improved checks: * Leaks - ignoring return value of allocation function * Uninitialized vars - check how uninitialized malloc data is used * Rewritten 'calculation in sizeof' using syntax tree * Rewritten 'clarify calculation' using syntax tree * Rewritten 'logical disjunction' using syntax tree * Rewritten 'duplicate expressions' using syntax tree * Rewritten 'invalidFunctionUsage' that uses the *.cfg files GUI: * Library files can be enabled in the project dialog * Suppressions can be specified in the project dialog Other: * Cppcheck is now continuosly scanning all the source code in the debian archive. Results: http://cppcheck.sourceforge.net/devinfo/daca2-report/daca2.html * Fixes of templates handling, hangs, crashes and false positives cppcheck-1.62 New checks * Divide with variable and then compare to see if variable is 0 * Duplicated inherited member Improved checking: * handling of >> in templates * format string checking * comparing bool result with integer * standard isgreater()/islower() functions * standard math functions * reassigning struct members Htmlreport xml-version 2 is now handled New checks: * arithmetical usage of inf/nan result * suspicious usage of comma in return statement * sizeof(void) Improved checking: * better simplification of strlen * improved handling of array member variables 'x[y].z..' * Specific improvements in checks for buffer overruns, format strings, uninitialized variables Command line: * Using both --max-configs and -D. Normally when -D is used, Cppcheck will only check the given configuration. By using --max-configs also, you can tell Cppcheck to check more configurations. * Added --library and --check-library. Graphical user interface: * Somewhat improved response when stopping checking Cppcheck core: * Extending checking with configuration files. Cppcheck has internal knowledge for standard C/C++ functions. Knowledge for libraries and environments can be specified using configuration files. * Rules: added <tokenlist> that allow you to check 'raw' code and 'normal' code. In the 'raw' code, the comments and #include are already taken care of, but the #define statements can be analysed.
2014-08-07 13:35:10 +02:00
CPPFLAGS+= -I${BUILDLINK_PREFIX.tinyxml2}/include
LDFLAGS+= ${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.tinyxml2}/lib -L${BUILDLINK_PREFIX.tinyxml2}/lib -ltinyxml2
# http://5.150.254.56:443/trac-cppcheck/ticket/6026#ticket
.include "../../mk/bsd.fast.prefs.mk"
.if !empty(MACHINE_PLATFORM:MNetBSD-[0-6].*-*) || empty(MACHINE_PLATFORM:MNetBSD-*)
# no backtrace() on NetBSD<7 (6.99.8 actually); add other systems with backtrace() when you find them
CPPFLAGS+= -DNO_UNIX_BACKTRACE_SUPPORT=1
.else
LDFLAGS+= -lexecinfo
.endif
.include "../../mk/compiler.mk"
.if !empty(CC_VERSION:Mgcc-4.[0-5]*) || !empty(CC_VERSION:Mgcc-3.*)
CXXFLAGS+= -include lib/cxx11emu.h
.endif
INSTALLATION_DIRS= ${PKGMANDIR}/man1
Update to 1.66: Cppcheck-1.66 has been released. New checks: - Compare pointer with '\0' - Assigning boolean expression to floating point variables Improvements: - Much improved AST - Much improved ValueFlow analysis - ValueFlow and AST now used by much more checks, improving checking accuracy and performance - Checking for self assignment now supports more complex expressions - Returning references to literals or references to calculation results is detected - Enhanced support for commutative operators in duplicate expression checking - Improved template/enum parsing - Much improved htmlreport - Definition of POD types in .cfg files - Definition of minsize for buffer arguments in .cfg files for buffer overflow checking - Fixed handling of #error: Do not report them if -f and -D are used together - New .cfg file for AVR platform - Generate xml dump of AST/ValueFlow/SymbolDatabase/TokenList if --dump is given - Improved performance in several cases - Windows Builds: Now compiled with VS2013, linked against Qt 5.3.1 GUI: - Platform settings are being saved now - Improved handling of (invalid) .cfg files - Use Win32W as default platform on Windows Additionally, a large number of false positives and crashs has been fixed. Cppcheck-1.65 has been released. General changes: Cppcheck requires a C++11 compiler supporting the common subset of features supported by GCC 4.4, Visual Studio 2010 and Clang 2.9 Problems with packaging and windows installer introduced in last release were fixed Improvements: Much improved support of complex combinations of function pointers, arrays and references Better handling of syntax errors Better detection of stack variables passed to free() Much improved value flow analysis More robust error detection in several checks due to usage of AST Better handling of unknown Macros in function declarations Allocation/Deallocation functions can be extend across different .cfg files Better handling of some C++11 language features like enum class, in-class member initializers Detect calling (std::)abs() with bool argument New checks: Check for noexcept and __attribute__((nothrow)) correctness Check for unhandled exceptions when exception specifiers are used Access to empty STL containers Repositioning operation on a file opened in append mode Find nested redundant if-statements (was experimental before) Additionally, a large number of false positives and crashs has been fixed. cppcheck-1.64 has been released. Value Flow A new value flow analysis has been added. It is generic so the same analysis can be reused by various checkers - previously many checkers have had their own value flow and control flow analysis. The new value flow analysis performs context sensitive cross-function analysis. All checkers that uses this will automatically have cross-function context sensitive value flow analysis. The new analysis is gradually introduced in the checkers - the old analysis in a checker is kept until it is redundant. The new value flow analysis is so far used to detect: division by zero null pointer dereference array index out of bounds invalid function argument Other Improvements Improved configurations for gtk, posix, sdl, std, windows Warn when using negative allocation size Check 2nd parameter for memset Cppcheck-1.63 has been released. Maintainers: The .cfg files are needed by cppcheck. Either put them in a subfolder cfg where the binary is. Otherwise compile cppcheck with CFGDIR to specify an arbitrary path where you put the .cfg files. New check: * Using pointer addition result in condition 'if (p+1)' - either a dereference is forgotten or it depends on UB (the result is only 0 if there is overflow, which is UB). Improved checks: * Leaks - ignoring return value of allocation function * Uninitialized vars - check how uninitialized malloc data is used * Rewritten 'calculation in sizeof' using syntax tree * Rewritten 'clarify calculation' using syntax tree * Rewritten 'logical disjunction' using syntax tree * Rewritten 'duplicate expressions' using syntax tree * Rewritten 'invalidFunctionUsage' that uses the *.cfg files GUI: * Library files can be enabled in the project dialog * Suppressions can be specified in the project dialog Other: * Cppcheck is now continuosly scanning all the source code in the debian archive. Results: http://cppcheck.sourceforge.net/devinfo/daca2-report/daca2.html * Fixes of templates handling, hangs, crashes and false positives cppcheck-1.62 New checks * Divide with variable and then compare to see if variable is 0 * Duplicated inherited member Improved checking: * handling of >> in templates * format string checking * comparing bool result with integer * standard isgreater()/islower() functions * standard math functions * reassigning struct members Htmlreport xml-version 2 is now handled New checks: * arithmetical usage of inf/nan result * suspicious usage of comma in return statement * sizeof(void) Improved checking: * better simplification of strlen * improved handling of array member variables 'x[y].z..' * Specific improvements in checks for buffer overruns, format strings, uninitialized variables Command line: * Using both --max-configs and -D. Normally when -D is used, Cppcheck will only check the given configuration. By using --max-configs also, you can tell Cppcheck to check more configurations. * Added --library and --check-library. Graphical user interface: * Somewhat improved response when stopping checking Cppcheck core: * Extending checking with configuration files. Cppcheck has internal knowledge for standard C/C++ functions. Knowledge for libraries and environments can be specified using configuration files. * Rules: added <tokenlist> that allow you to check 'raw' code and 'normal' code. In the 'raw' code, the comments and #include are already taken care of, but the #define statements can be analysed.
2014-08-07 13:35:10 +02:00
REPLACE_PYTHON+= htmlreport/cppcheck-htmlreport
.include "options.mk"
post-install:
${INSTALL_MAN} ${WRKSRC}/cppcheck.1 \
${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
.if !empty(PKG_OPTIONS:Mqt)
${INSTALL_PROGRAM} ${WRKSRC}/gui/cppcheck-gui \
${DESTDIR}${PREFIX}/bin
.endif
Update to 1.66: Cppcheck-1.66 has been released. New checks: - Compare pointer with '\0' - Assigning boolean expression to floating point variables Improvements: - Much improved AST - Much improved ValueFlow analysis - ValueFlow and AST now used by much more checks, improving checking accuracy and performance - Checking for self assignment now supports more complex expressions - Returning references to literals or references to calculation results is detected - Enhanced support for commutative operators in duplicate expression checking - Improved template/enum parsing - Much improved htmlreport - Definition of POD types in .cfg files - Definition of minsize for buffer arguments in .cfg files for buffer overflow checking - Fixed handling of #error: Do not report them if -f and -D are used together - New .cfg file for AVR platform - Generate xml dump of AST/ValueFlow/SymbolDatabase/TokenList if --dump is given - Improved performance in several cases - Windows Builds: Now compiled with VS2013, linked against Qt 5.3.1 GUI: - Platform settings are being saved now - Improved handling of (invalid) .cfg files - Use Win32W as default platform on Windows Additionally, a large number of false positives and crashs has been fixed. Cppcheck-1.65 has been released. General changes: Cppcheck requires a C++11 compiler supporting the common subset of features supported by GCC 4.4, Visual Studio 2010 and Clang 2.9 Problems with packaging and windows installer introduced in last release were fixed Improvements: Much improved support of complex combinations of function pointers, arrays and references Better handling of syntax errors Better detection of stack variables passed to free() Much improved value flow analysis More robust error detection in several checks due to usage of AST Better handling of unknown Macros in function declarations Allocation/Deallocation functions can be extend across different .cfg files Better handling of some C++11 language features like enum class, in-class member initializers Detect calling (std::)abs() with bool argument New checks: Check for noexcept and __attribute__((nothrow)) correctness Check for unhandled exceptions when exception specifiers are used Access to empty STL containers Repositioning operation on a file opened in append mode Find nested redundant if-statements (was experimental before) Additionally, a large number of false positives and crashs has been fixed. cppcheck-1.64 has been released. Value Flow A new value flow analysis has been added. It is generic so the same analysis can be reused by various checkers - previously many checkers have had their own value flow and control flow analysis. The new value flow analysis performs context sensitive cross-function analysis. All checkers that uses this will automatically have cross-function context sensitive value flow analysis. The new analysis is gradually introduced in the checkers - the old analysis in a checker is kept until it is redundant. The new value flow analysis is so far used to detect: division by zero null pointer dereference array index out of bounds invalid function argument Other Improvements Improved configurations for gtk, posix, sdl, std, windows Warn when using negative allocation size Check 2nd parameter for memset Cppcheck-1.63 has been released. Maintainers: The .cfg files are needed by cppcheck. Either put them in a subfolder cfg where the binary is. Otherwise compile cppcheck with CFGDIR to specify an arbitrary path where you put the .cfg files. New check: * Using pointer addition result in condition 'if (p+1)' - either a dereference is forgotten or it depends on UB (the result is only 0 if there is overflow, which is UB). Improved checks: * Leaks - ignoring return value of allocation function * Uninitialized vars - check how uninitialized malloc data is used * Rewritten 'calculation in sizeof' using syntax tree * Rewritten 'clarify calculation' using syntax tree * Rewritten 'logical disjunction' using syntax tree * Rewritten 'duplicate expressions' using syntax tree * Rewritten 'invalidFunctionUsage' that uses the *.cfg files GUI: * Library files can be enabled in the project dialog * Suppressions can be specified in the project dialog Other: * Cppcheck is now continuosly scanning all the source code in the debian archive. Results: http://cppcheck.sourceforge.net/devinfo/daca2-report/daca2.html * Fixes of templates handling, hangs, crashes and false positives cppcheck-1.62 New checks * Divide with variable and then compare to see if variable is 0 * Duplicated inherited member Improved checking: * handling of >> in templates * format string checking * comparing bool result with integer * standard isgreater()/islower() functions * standard math functions * reassigning struct members Htmlreport xml-version 2 is now handled New checks: * arithmetical usage of inf/nan result * suspicious usage of comma in return statement * sizeof(void) Improved checking: * better simplification of strlen * improved handling of array member variables 'x[y].z..' * Specific improvements in checks for buffer overruns, format strings, uninitialized variables Command line: * Using both --max-configs and -D. Normally when -D is used, Cppcheck will only check the given configuration. By using --max-configs also, you can tell Cppcheck to check more configurations. * Added --library and --check-library. Graphical user interface: * Somewhat improved response when stopping checking Cppcheck core: * Extending checking with configuration files. Cppcheck has internal knowledge for standard C/C++ functions. Knowledge for libraries and environments can be specified using configuration files. * Rules: added <tokenlist> that allow you to check 'raw' code and 'normal' code. In the 'raw' code, the comments and #include are already taken care of, but the #define statements can be analysed.
2014-08-07 13:35:10 +02:00
.include "../../lang/python/application.mk"
Update to 1.48. Ok reed except for the cmake dependency :) Release notes for 1.48 There are no major new features in 1.48. There are more and better checks. New check: Wrong usage of ! operator in conditions. Example: if (!x == 0) { New check: Use "throw" without arguments to rethrow exceptions. New check: Comparison of substring with string literal will always/never match because size doesn't match. New check: Postfix increment of boolean New check: Clarify condition with parantheses (when there are assignment + comparison) Example: if (a = b > 0) { Release notes for 1.47 It is now possible to exclude files and folders from the analysis. Use -i on the command line (i=ignore). Custom rules can now be created using regular expressions. To read more about creating custom rules, see http://sourceforge.net/projects/cppcheck/files/Articles/ A new XML format is launched. To use this format, the --xml-version=2 is used. The new xml format is incompatible with the xml format used in previous versions. The old XML format will still be used unless --xml-version=2 is given, so your existing scripts, tools and plugins should still work. New check: sizeof used on array variable that is a function parameter. The expected bahaviour is most likely that the sizeof result is the size of the array, but the actual sizeof result is the size of the pointer. New check: catching exception by value. It is better to catch by reference for various reasons. New check: memset calls filling 0 bytes. The given size might be wrong.
2011-05-29 13:52:12 +02:00
.include "../../devel/pcre/buildlink3.mk"
Update to 1.66: Cppcheck-1.66 has been released. New checks: - Compare pointer with '\0' - Assigning boolean expression to floating point variables Improvements: - Much improved AST - Much improved ValueFlow analysis - ValueFlow and AST now used by much more checks, improving checking accuracy and performance - Checking for self assignment now supports more complex expressions - Returning references to literals or references to calculation results is detected - Enhanced support for commutative operators in duplicate expression checking - Improved template/enum parsing - Much improved htmlreport - Definition of POD types in .cfg files - Definition of minsize for buffer arguments in .cfg files for buffer overflow checking - Fixed handling of #error: Do not report them if -f and -D are used together - New .cfg file for AVR platform - Generate xml dump of AST/ValueFlow/SymbolDatabase/TokenList if --dump is given - Improved performance in several cases - Windows Builds: Now compiled with VS2013, linked against Qt 5.3.1 GUI: - Platform settings are being saved now - Improved handling of (invalid) .cfg files - Use Win32W as default platform on Windows Additionally, a large number of false positives and crashs has been fixed. Cppcheck-1.65 has been released. General changes: Cppcheck requires a C++11 compiler supporting the common subset of features supported by GCC 4.4, Visual Studio 2010 and Clang 2.9 Problems with packaging and windows installer introduced in last release were fixed Improvements: Much improved support of complex combinations of function pointers, arrays and references Better handling of syntax errors Better detection of stack variables passed to free() Much improved value flow analysis More robust error detection in several checks due to usage of AST Better handling of unknown Macros in function declarations Allocation/Deallocation functions can be extend across different .cfg files Better handling of some C++11 language features like enum class, in-class member initializers Detect calling (std::)abs() with bool argument New checks: Check for noexcept and __attribute__((nothrow)) correctness Check for unhandled exceptions when exception specifiers are used Access to empty STL containers Repositioning operation on a file opened in append mode Find nested redundant if-statements (was experimental before) Additionally, a large number of false positives and crashs has been fixed. cppcheck-1.64 has been released. Value Flow A new value flow analysis has been added. It is generic so the same analysis can be reused by various checkers - previously many checkers have had their own value flow and control flow analysis. The new value flow analysis performs context sensitive cross-function analysis. All checkers that uses this will automatically have cross-function context sensitive value flow analysis. The new analysis is gradually introduced in the checkers - the old analysis in a checker is kept until it is redundant. The new value flow analysis is so far used to detect: division by zero null pointer dereference array index out of bounds invalid function argument Other Improvements Improved configurations for gtk, posix, sdl, std, windows Warn when using negative allocation size Check 2nd parameter for memset Cppcheck-1.63 has been released. Maintainers: The .cfg files are needed by cppcheck. Either put them in a subfolder cfg where the binary is. Otherwise compile cppcheck with CFGDIR to specify an arbitrary path where you put the .cfg files. New check: * Using pointer addition result in condition 'if (p+1)' - either a dereference is forgotten or it depends on UB (the result is only 0 if there is overflow, which is UB). Improved checks: * Leaks - ignoring return value of allocation function * Uninitialized vars - check how uninitialized malloc data is used * Rewritten 'calculation in sizeof' using syntax tree * Rewritten 'clarify calculation' using syntax tree * Rewritten 'logical disjunction' using syntax tree * Rewritten 'duplicate expressions' using syntax tree * Rewritten 'invalidFunctionUsage' that uses the *.cfg files GUI: * Library files can be enabled in the project dialog * Suppressions can be specified in the project dialog Other: * Cppcheck is now continuosly scanning all the source code in the debian archive. Results: http://cppcheck.sourceforge.net/devinfo/daca2-report/daca2.html * Fixes of templates handling, hangs, crashes and false positives cppcheck-1.62 New checks * Divide with variable and then compare to see if variable is 0 * Duplicated inherited member Improved checking: * handling of >> in templates * format string checking * comparing bool result with integer * standard isgreater()/islower() functions * standard math functions * reassigning struct members Htmlreport xml-version 2 is now handled New checks: * arithmetical usage of inf/nan result * suspicious usage of comma in return statement * sizeof(void) Improved checking: * better simplification of strlen * improved handling of array member variables 'x[y].z..' * Specific improvements in checks for buffer overruns, format strings, uninitialized variables Command line: * Using both --max-configs and -D. Normally when -D is used, Cppcheck will only check the given configuration. By using --max-configs also, you can tell Cppcheck to check more configurations. * Added --library and --check-library. Graphical user interface: * Somewhat improved response when stopping checking Cppcheck core: * Extending checking with configuration files. Cppcheck has internal knowledge for standard C/C++ functions. Knowledge for libraries and environments can be specified using configuration files. * Rules: added <tokenlist> that allow you to check 'raw' code and 'normal' code. In the 'raw' code, the comments and #include are already taken care of, but the #define statements can be analysed.
2014-08-07 13:35:10 +02:00
.include "../../textproc/tinyxml2/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"