+DIST json-c-0.12.1.tar.gz 535086 SHA256 2a136451a7932d80b7d197b10441e26e39428d67b1443ec43bbba824705e1123 SHA512 038676a0ce815e5174161fbd4339524feadc294d517f732fb408ad6aa7c4906423451c13386107569d9f24746a1a101564ca511e92e8276c5bf5b8c022ca42ed WHIRLPOOL ac558aa3cf661e8a943e2c85a684cbb7a46719de35360a23e9939cefaff32720a55ede5e5c05ea2f7b65aa3128082cc98da9ad5e6685b53ec40726857da7a53a
DIST json-c-0.12.tar.gz 501419 SHA256 000c01b2b3f82dcb4261751eb71f1b084404fb7d6a282f06074d3c17078b9f3f SHA512 c959804362386f6b77e9d04b5fedf6d6aff1fcd0ab50250edb25f759b510b402e7ad4b33d1cbadc3337b63a3145d19f310812a9ee351748348304b384dc2dc35 WHIRLPOOL b49f5c96b614302b39737306774b4346d8347afef6ced7067664ac0d68669a1496fe915f229e0d434a87b103ac9982d67c5785eb688b7026c257c7eae95c6eaf
--- /dev/null
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit autotools multilib-minimal ltprune
+
+DESCRIPTION="A JSON implementation in C"
+HOMEPAGE="https://github.com/json-c/json-c/wiki"
+SRC_URI="https://s3.amazonaws.com/json-c_releases/releases/${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0/0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~amd64-linux ~x86-linux ~ppc-macos"
+IUSE="doc static-libs"
+
+src_prepare() {
+ default
+ sed -i -e "s:-Werror::" Makefile.am.inc || die
+ eautoreconf
+
+ # tests break otherwise
+ multilib_copy_sources
+}
+
+multilib_src_configure() {
+ ECONF_SOURCE=${S} econf $(use_enable static-libs static)
+}
+
+multilib_src_test() {
+ export USE_VALGRIND=0 VERBOSE=1
+ default
+}
+
+multilib_src_install_all() {
+ use doc && HTML_DOCS=( "${S}"/doc/html/. )
+ einstalldocs
+
+ # add symlink for projects not using pkgconfig
+ dosym ../json-c /usr/include/json-c/json
+
+ prune_libtool_files
+}