From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-959228-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 D3ED3139083
	for <garchives@archives.gentoo.org>; Tue,  4 Jul 2017 06:59:20 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 3FB12E0D12;
	Tue,  4 Jul 2017 06:59:20 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 1EB28E0D12
	for <gentoo-commits@lists.gentoo.org>; Tue,  4 Jul 2017 06:59:19 +0000 (UTC)
Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52])
	(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 3588034171F
	for <gentoo-commits@lists.gentoo.org>; Tue,  4 Jul 2017 06:59:19 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 6B8872FA
	for <gentoo-commits@lists.gentoo.org>; Tue,  4 Jul 2017 06:59:17 +0000 (UTC)
From: "Alexis Ballier" <aballier@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, "Alexis Ballier" <aballier@gentoo.org>
Message-ID: <1499151522.71182f821273a894cb9c960a72b33658bc7dd56d.aballier@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ml/ocaml-cstruct/
X-VCS-Repository: repo/gentoo
X-VCS-Files: dev-ml/ocaml-cstruct/ocaml-cstruct-3.0.2.ebuild
X-VCS-Directories: dev-ml/ocaml-cstruct/
X-VCS-Committer: aballier
X-VCS-Committer-Name: Alexis Ballier
X-VCS-Revision: 71182f821273a894cb9c960a72b33658bc7dd56d
X-VCS-Branch: master
Date: Tue,  4 Jul 2017 06:59:17 +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: a4730df4-e6cc-4e8c-9735-4ce9efdcf26e
X-Archives-Hash: 9922f7500ef26d3810b115e48190a2d7

commit:     71182f821273a894cb9c960a72b33658bc7dd56d
Author:     Alexis Ballier <aballier <AT> gentoo <DOT> org>
AuthorDate: Tue Jul  4 06:58:42 2017 +0000
Commit:     Alexis Ballier <aballier <AT> gentoo <DOT> org>
CommitDate: Tue Jul  4 06:58:42 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=71182f82

dev-ml/ocaml-cstruct: build only enabled targets, should fix bug #623742

Package-Manager: Portage-2.3.6, Repoman-2.3.2

 dev-ml/ocaml-cstruct/ocaml-cstruct-3.0.2.ebuild | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/dev-ml/ocaml-cstruct/ocaml-cstruct-3.0.2.ebuild b/dev-ml/ocaml-cstruct/ocaml-cstruct-3.0.2.ebuild
index 388db7e2542..39b192f16a3 100644
--- a/dev-ml/ocaml-cstruct/ocaml-cstruct-3.0.2.ebuild
+++ b/dev-ml/ocaml-cstruct/ocaml-cstruct-3.0.2.ebuild
@@ -38,6 +38,22 @@ DEPEND="
 	${RDEPEND}
 "
 
+get_targets() {
+	local tgt="cstruct,cstruct-unix"
+	use lwt && tgt+=",cstruct-lwt"
+	use async && tgt+=",cstruct-async"
+	use ppx && tgt+=",ppx_cstruct"
+	echo "${tgt}"
+}
+
+src_compile() {
+	jbuilder build -p $(get_targets) || die
+}
+
+src_test() {
+	jbuilder runtest -p $(get_targets) || die
+}
+
 oinstall() {
 	opam-installer -i \
 		--prefix="${ED}/usr" \