commit: f631b786b5dc48a16224e856417ceb44231428a7 Author: Matthias Maier <tamiko <AT> gentoo <DOT> org> AuthorDate: Fri Dec 4 04:56:31 2020 +0000 Commit: Matthias Maier <tamiko <AT> gentoo <DOT> org> CommitDate: Fri Dec 4 05:37:16 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f631b786
dev-util/cppcheck: version bump to 2.2 Thanks to Bernd Buschinski for the initial ebuild Closes: https://bugs.gentoo.org/693352 Bug: https://bugs.gentoo.org/699594 Package-Manager: Portage-3.0.11, Repoman-3.0.2 Signed-off-by: Matthias Maier <tamiko <AT> gentoo.org> dev-util/cppcheck/Manifest | 1 + dev-util/cppcheck/cppcheck-2.2.ebuild | 80 +++++++++++++++++++++++++++++++++++ dev-util/cppcheck/metadata.xml | 3 ++ profiles/arch/hppa/package.use.mask | 4 ++ profiles/arch/sparc/package.use.mask | 4 ++ 5 files changed, 92 insertions(+) diff --git a/dev-util/cppcheck/Manifest b/dev-util/cppcheck/Manifest index 2d4d3044aea..383ff755b28 100644 --- a/dev-util/cppcheck/Manifest +++ b/dev-util/cppcheck/Manifest @@ -1,3 +1,4 @@ DIST cppcheck-1.86.tar.gz 2184186 BLAKE2B 8b488ec72d0998d6b037de2b1204373c8b3de475ad165bf108bb331399356cb0d1e20a7bc6f368f1a038ec886ad7a84ad694172d0a96a203a6877f3838c21001 SHA512 59cec55b8408e8f2e2e7172bce69350c248bc3185a0938b523c44a58f98b344e11aef957ec1b7a7b2bc7a876660b2683e51f54b76f0b550f9549497c29453655 DIST cppcheck-1.87.tar.gz 2243258 BLAKE2B ffe42bfb2e896163678c5bb24e46ae2391ba8254cbe7c1c19c3c1b16cd38adf9c773de6aaefe70af08b9c1dca8b0b0b5e9939323368a2f81491fd6981ff18139 SHA512 b0149002b40260c1488904929296403722a66b84263b41d0097c3caed28265332766c114f0d1f378ea6c7e73ab973ea71ab89c6744f6cc818f22de08933e6766 DIST cppcheck-1.88.tar.gz 2364053 BLAKE2B b688974ff83019422cc5b2ec575d9838bdff4ada17d71fb3d436f07eea50429490c222659163b845667d98c0ec186b3288464827894e379fd017dd0c3fea645f SHA512 fa4ede0665546341af0ba3dae09a00b6efae09ec7838c616c580be01ff6902594d61168a059539779be0c78e1708d2bd9c8e7987dd0bb67dc8fa332a10d1de6a +DIST cppcheck-2.2.tar.gz 3561406 BLAKE2B e436de4bec5412a18f013c8557a966c28c14edcd07fbb80eb53a897848d15f32afc180798ea1a074742f896b15d4020755c104b87dc8f82252121b58a92b92dc SHA512 d766187a69d6aa839e072e3c0ed44009621ca8492504257288ca2f49774f705a1ebcf2957f0801ac6eab2ffbdd845e9237f1213f85c6d0fcdbf16b1e7c690327 diff --git a/dev-util/cppcheck/cppcheck-2.2.ebuild b/dev-util/cppcheck/cppcheck-2.2.ebuild new file mode 100644 index 00000000000..4589cb21f5d --- /dev/null +++ b/dev-util/cppcheck/cppcheck-2.2.ebuild @@ -0,0 +1,80 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +PYTHON_COMPAT=( python{3_6,3_7,3_8,3_9} ) +inherit distutils-r1 toolchain-funcs cmake-utils + +DESCRIPTION="Static analyzer of C/C++ code" +HOMEPAGE="https://github.com/danmar/cppcheck" +SRC_URI="https://github.com/danmar/cppcheck/archive/${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-3+" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc64 ~sparc ~x86" +IUSE="htmlreport pcre qt5 +z3" + +RDEPEND=" + htmlreport? ( dev-python/pygments[${PYTHON_USEDEP}] ) + pcre? ( dev-libs/libpcre ) + qt5? ( + dev-qt/qtcore:5 + dev-qt/qtgui:5 + dev-qt/qtprintsupport:5 + ) +" +DEPEND="${RDEPEND} + app-text/docbook-xsl-stylesheets + dev-libs/libxslt + virtual/pkgconfig + z3? ( sci-mathematics/z3 ) +" + +src_prepare() { + cmake-utils_src_prepare +} + +src_configure() { + + local mycmakeargs=( + -DHAVE_RULES="$(usex pcre)" + -DBUILD_GUI="$(usex qt5)" + -DUSE_Z3="$(usex z3)" + -DFILESDIR="${EROOT}/usr/share/${PN}/" + -ENABLE_OSS_FUZZ=OFF + ) + cmake-utils_src_configure +} + +src_compile() { + cmake-utils_src_compile + + if use htmlreport ; then + pushd htmlreport || die + distutils-r1_src_compile + popd || die + fi +} + +src_install() { + # it's not autotools-based, so "${ED}" here, not "${D}", bug 531760 + emake install DESTDIR="${ED}" \ + FILESDIR="${EROOT}/usr/share/${PN}/" + + insinto "/usr/share/${PN}/cfg" + doins cfg/*.cfg + if use qt5 ; then + dobin "${WORKDIR}/${P}_build/bin/${PN}-gui" + dodoc gui/{projectfile.txt,gui.${PN}} + fi + if use htmlreport ; then + pushd htmlreport || die + distutils-r1_src_install + popd || die + find "${D}" -name "*.egg-info" -delete + else + rm "${ED}/usr/bin/cppcheck-htmlreport" || die + fi + + dodoc -r tools/triage +} diff --git a/dev-util/cppcheck/metadata.xml b/dev-util/cppcheck/metadata.xml index de3bd183267..af774e39e7f 100644 --- a/dev-util/cppcheck/metadata.xml +++ b/dev-util/cppcheck/metadata.xml @@ -7,6 +7,9 @@ </maintainer> <use> <flag name="htmlreport">install cppcheck-htmlreport</flag> + <flag name="z3"> + Enable support for <pkg>sci-mathematics/z3</pkg> backend + </flag> </use> <upstream> <remote-id type="sourceforge">cppcheck</remote-id> diff --git a/profiles/arch/hppa/package.use.mask b/profiles/arch/hppa/package.use.mask index 15062f1199b..17fd5688168 100644 --- a/profiles/arch/hppa/package.use.mask +++ b/profiles/arch/hppa/package.use.mask @@ -4,6 +4,10 @@ # NOTE: When masking a USE flag due to missing keywords, please file a keyword # request bug for the hppa arch. +# Matthias Maier <tam...@gentoo.org> (2020-12-03) +# Requires sci-mathematics/z3. +dev-util/cppcheck z3 + # Michał Górny <mgo...@gentoo.org> (2020-11-18) # Requires dev-python/coverage, bug #743355. dev-python/nose coverage diff --git a/profiles/arch/sparc/package.use.mask b/profiles/arch/sparc/package.use.mask index de6cf1c5f4e..7b9eb8fd007 100644 --- a/profiles/arch/sparc/package.use.mask +++ b/profiles/arch/sparc/package.use.mask @@ -1,6 +1,10 @@ # Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 +# Matthias Maier <tam...@gentoo.org> (2020-12-03) +# Requires sci-mathematics/z3. +dev-util/cppcheck z3 + # Mart Raudsepp <l...@gentoo.org> (2020-11-26) # dev-libs/libmanette not keyworded, limited usefulness net-libs/webkit-gtk gamepad