From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-985572-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id 99A0E139083
	for <garchives@archives.gentoo.org>; Wed, 22 Nov 2017 22:01:10 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id F0647E0EC1;
	Wed, 22 Nov 2017 22:01:09 +0000 (UTC)
Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id C172DE0EC1
	for <gentoo-commits@lists.gentoo.org>; Wed, 22 Nov 2017 22:01:08 +0000 (UTC)
Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id 80E7133FE7D
	for <gentoo-commits@lists.gentoo.org>; Wed, 22 Nov 2017 22:01:06 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 0E6A3A414
	for <gentoo-commits@lists.gentoo.org>; Wed, 22 Nov 2017 22:01:05 +0000 (UTC)
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" <asturm@gentoo.org>
Message-ID: <1511388050.87d997b2911320d50eefb69f1a8e2b67b71a8f30.asturm@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-util/cppcheck/
X-VCS-Repository: repo/gentoo
X-VCS-Files: dev-util/cppcheck/Manifest dev-util/cppcheck/cppcheck-1.81.ebuild
X-VCS-Directories: dev-util/cppcheck/
X-VCS-Committer: asturm
X-VCS-Committer-Name: Andreas Sturmlechner
X-VCS-Revision: 87d997b2911320d50eefb69f1a8e2b67b71a8f30
X-VCS-Branch: master
Date: Wed, 22 Nov 2017 22:01:05 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Archives-Salt: d10800c6-cfa2-48ad-82b0-53ca9c8e4c59
X-Archives-Hash: e6bd5d68f04d6ad26526b05685f0224d

commit:     87d997b2911320d50eefb69f1a8e2b67b71a8f30
Author:     Jens Lindenmeier <gentoo <AT> lindenmeier <DOT> com>
AuthorDate: Wed Nov 22 19:47:35 2017 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Wed Nov 22 22:00:50 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=87d997b2

dev-util/cppcheck: 1.81 version bump

Closes: https://bugs.gentoo.org/627380
Package-Manager: Portage-2.3.16, Repoman-2.3.6

 dev-util/cppcheck/Manifest             |   1 +
 dev-util/cppcheck/cppcheck-1.81.ebuild | 100 +++++++++++++++++++++++++++++++++
 2 files changed, 101 insertions(+)

diff --git a/dev-util/cppcheck/Manifest b/dev-util/cppcheck/Manifest
index f4445de6e83..7eebd8df022 100644
--- a/dev-util/cppcheck/Manifest
+++ b/dev-util/cppcheck/Manifest
@@ -1,3 +1,4 @@
 DIST cppcheck-1.77.tar.bz2 1188453 SHA256 1980ffe5c9c24bb6dea24514d42be3aa49d6ba7cc26c448b3543611fe8ba2619 SHA512 df8dddf7758c342d45b3393246e07eaa11a53dca19e8a0d09de04f12ea6232538941328d9ca9ac52eb425871fd1c49d55c77e6e38b40772b6f856fd1e9e99779 WHIRLPOOL 9f7842eba0f53a999993dbd23d09c10e5bd3dcca5ecbb0689e4ded8c7529d84fd939a57ce9cd267cdd21b2d79aeb6c07d672983ccb52be0fcc0b28ca80a31b59
 DIST cppcheck-1.78.tar.bz2 1201959 SHA256 e42696f7d6321b98cb479ad9728d051effe543b26aca8102428f60b9850786b1 SHA512 598556e9d657a3a77ff889cb6647291160017f7f9322326771416ff59d44126ce47c39767657b863cdb8a1b46d7c83bb337ec2fe0574500b37e99c33377b5dd8 WHIRLPOOL 2087ad837353d01bca828af940c427909a3e556e97e46d1822e0f2f527619c87b15d1a7f647992dd46eb3a2ef1eb4fb86344db31d7a01fb6f8a9070dfeecef96
 DIST cppcheck-1.79.tar.bz2 1206623 SHA256 2b85b693de54f15048f1841e7aef74574f99da6270d2182baba78514fa27f06d SHA512 766649b685d60b057752a49eda46f5bb42681c01c32169e83f85ea6f5d3302b572a2d484c1cee1380fd304489d5a32f83eb59a72ceefb1b787031e84bf3a2676 WHIRLPOOL dee33b68c8b924a68b90cbabcd9da6489003fb9f4fc0e2f5d411c82404c666b0c034ca33cc8e4043e4b1d18622158d1dd3de3b8ebd83d52ee01cd3513a39ad26
+DIST cppcheck-1.81.tar.bz2 1514741 BLAKE2B 2f23dfe4bdb26e203411f0bf9bc569303a4d59f96911b32a8a5f9cc9a6a7fa75e5d87c328cb0bf8cc46bd8f38747a4663c33243b8385355cc5630e1fcf6c891f SHA512 22e7b63c35e71b2784065faca06aec8c286e3173f182ac10995073cc3d61fd0bfaf353c51ad9207d3bd2c6134ab1a3990a37668709505b657c2816d561f8af92

diff --git a/dev-util/cppcheck/cppcheck-1.81.ebuild b/dev-util/cppcheck/cppcheck-1.81.ebuild
new file mode 100644
index 00000000000..2cc7f0445c1
--- /dev/null
+++ b/dev-util/cppcheck/cppcheck-1.81.ebuild
@@ -0,0 +1,100 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+PYTHON_COMPAT=( python{2_7,3_4,3_5} )
+
+inherit distutils-r1 eutils flag-o-matic qmake-utils toolchain-funcs
+
+DESCRIPTION="static analyzer of C/C++ code"
+HOMEPAGE="http://cppcheck.sourceforge.net"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~x86"
+IUSE="htmlreport pcre qt5"
+
+RDEPEND="htmlreport? ( dev-python/pygments[${PYTHON_USEDEP}] )
+	>=dev-libs/tinyxml2-2
+	qt5? ( dev-qt/qtgui:5 )
+	pcre? ( dev-libs/libpcre )"
+DEPEND="${RDEPEND}
+	app-text/docbook-xsl-stylesheets
+	dev-libs/libxslt
+	virtual/pkgconfig"
+
+src_prepare() {
+	append-cxxflags -std=c++0x
+
+	# Drop bundled libs, patch Makefile generator and re-run it
+	rm -r externals/tinyxml || die
+	epatch "${FILESDIR}"/${PN}-1.75-tinyxml2.patch
+	tc-export CXX
+	emake dmake
+	./dmake || die
+
+	default
+}
+
+src_configure() {
+	if use pcre ; then
+		sed -e '/HAVE_RULES=/s:=no:=yes:' \
+			-i Makefile
+	fi
+}
+
+src_compile() {
+	export LIBS="$(pkg-config --libs tinyxml2)"
+	emake ${PN} man \
+		CFGDIR="${EROOT}usr/share/${PN}/cfg" \
+		DB2MAN="${EROOT}usr/share/sgml/docbook/xsl-stylesheets/manpages/docbook.xsl"
+
+	if use qt5 ; then
+		pushd gui
+		eqmake5
+		emake
+		popd
+	fi
+	if use htmlreport ; then
+		pushd htmlreport
+		distutils-r1_src_compile
+		popd
+	fi
+}
+
+src_test() {
+	# safe final version
+	mv -v ${PN}{,.final}
+	mv -v lib/library.o{,.final}
+	mv -v cli/cppcheckexecutor.o{,.final}
+	#trigger recompile with CFGDIR inside ${S}
+	emake check CFGDIR="${S}/cfg"
+	# restore
+	mv -v ${PN}{.final,}
+	mv -v lib/library.o{.final,}
+	mv -v cli/cppcheckexecutor.o{.final,}
+}
+
+src_install() {
+	# it's not autotools-based, so "${ED}" here, not "${D}", bug 531760
+	emake install DESTDIR="${ED}"
+
+	insinto "/usr/share/${PN}/cfg"
+	doins cfg/*.cfg
+	if use qt5 ; then
+		dobin gui/${PN}-gui
+		dodoc gui/{projectfile.txt,gui.${PN}}
+	fi
+	if use htmlreport ; then
+		pushd htmlreport
+		distutils-r1_src_install
+		popd
+		find "${D}" -name "*.egg-info" -delete
+	else
+		rm "${ED}/usr/bin/cppcheck-htmlreport" || die
+	fi
+	doman ${PN}.1
+	dodoc -r triage
+}