source: trunk/dports/devel/cppcheck/Portfile @ 118676

Last change on this file since 118676 was 118676, checked in by macsforever2000@…, 5 years ago

cppcheck: Update to version 1.64. Handle new config files. nomaintainer. (#42352)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.8 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 118676 2014-04-07 22:46:20Z macsforever2000@macports.org $
3
4PortSystem          1.0
5
6name                cppcheck
7version             1.64
8categories          devel
9license             GPL-3
10platforms           darwin
11maintainers         nomaintainer
12
13description         Static analysis of C and C++ code.
14
15long_description    Cppcheck is an analysis tool for C and C++ code. Unlike \
16                    compilers and many other analysis tools, we do not detect \
17                    syntax errors. Cppcheck only detects the types of bugs that \
18                    the compilers normally fail to detect. The goal is no false \
19                    positives.
20
21homepage            http://cppcheck.sourceforge.net/
22master_sites        sourceforge:project/cppcheck/cppcheck/${version}
23
24checksums           rmd160  5d5567cbec377fc922288404c6aad53f9b28f42f \
25                    sha256  a138f51aee3d547c6e37becbe3deb2f8d7b23133c473690ea2fe7f8efc0bdf56
26
27depends_build       port:libxslt \
28                    port:docbook-xsl
29
30depends_lib         port:pcre
31
32use_configure       no
33
34variant universal {}
35
36build.args          CXX="${configure.cxx} [get_canonical_archflags cxx]" \
37                    HAVE_RULES=yes CFGDIR=${prefix}/share/cppcheck \
38                    DB2MAN=${prefix}/share/xsl/docbook-xsl/manpages/docbook.xsl
39build.target        all man
40
41test.run            yes
42test.target         test
43
44destroot.args       PREFIX=${prefix}
45
46post-destroot {
47    xinstall -m 444 ${worksrcpath}/cppcheck.1 ${destroot}${prefix}/share/man/man1
48    xinstall -d ${destroot}${prefix}/share/cppcheck
49    copy ${worksrcpath}/cfg/gtk.cfg ${destroot}${prefix}/share/cppcheck/gtk.cfg.dist
50    copy ${worksrcpath}/cfg/posix.cfg ${destroot}${prefix}/share/cppcheck/posix.cfg.dist
51    copy ${worksrcpath}/cfg/qt.cfg ${destroot}${prefix}/share/cppcheck/qt.cfg.dist
52    copy ${worksrcpath}/cfg/std.cfg ${destroot}${prefix}/share/cppcheck/std.cfg.dist
53    copy ${worksrcpath}/cfg/windows.cfg ${destroot}${prefix}/share/cppcheck/windows.cfg.dist
54}
55
56post-activate {
57    if {![file exists ${prefix}/share/cppcheck/gtk.cfg]} {
58        copy ${prefix}/share/cppcheck/gtk.cfg.dist ${prefix}/share/cppcheck/gtk.cfg
59    }
60
61    if {![file exists ${prefix}/share/cppcheck/posix.cfg]} {
62        copy ${prefix}/share/cppcheck/posix.cfg.dist ${prefix}/share/cppcheck/posix.cfg
63    }
64
65    if {![file exists ${prefix}/share/cppcheck/qt.cfg]} {
66        copy ${prefix}/share/cppcheck/qt.cfg.dist ${prefix}/share/cppcheck/qt.cfg
67    }
68
69    if {![file exists ${prefix}/share/cppcheck/std.cfg]} {
70        copy ${prefix}/share/cppcheck/std.cfg.dist ${prefix}/share/cppcheck/std.cfg
71    }
72
73    if {![file exists ${prefix}/share/cppcheck/windows.cfg]} {
74        copy ${prefix}/share/cppcheck/windows.cfg.dist ${prefix}/share/cppcheck/windows.cfg
75    }
76}
Note: See TracBrowser for help on using the repository browser.