From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 B67AF139694 for ; Tue, 25 Apr 2017 17:32:31 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id B6B5E21C09F; Tue, 25 Apr 2017 17:32:28 +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 9524F21C09F for ; Tue, 25 Apr 2017 17:32:28 +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 B74073415B7 for ; Tue, 25 Apr 2017 17:32:27 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 274E27434 for ; Tue, 25 Apr 2017 17:32:26 +0000 (UTC) From: "Alexis Ballier" 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" Message-ID: <1493141537.38cf9c02c6ae0043bbac15191fd38c434b0aee24.aballier@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ml/cppo/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-ml/cppo/cppo-1.5.0.ebuild X-VCS-Directories: dev-ml/cppo/ X-VCS-Committer: aballier X-VCS-Committer-Name: Alexis Ballier X-VCS-Revision: 38cf9c02c6ae0043bbac15191fd38c434b0aee24 X-VCS-Branch: master Date: Tue, 25 Apr 2017 17:32:26 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 1e9e3b2f-0b63-4251-b09f-bd7a764121b3 X-Archives-Hash: 69cb1f8df54956d1f41c2bef198e9131 commit: 38cf9c02c6ae0043bbac15191fd38c434b0aee24 Author: Alexis Ballier gentoo org> AuthorDate: Tue Apr 25 16:34:19 2017 +0000 Commit: Alexis Ballier gentoo org> CommitDate: Tue Apr 25 17:32:17 2017 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=38cf9c02 dev-ml/cppo: add ocamlopt useflag Package-Manager: Portage-2.3.5, Repoman-2.3.2 dev-ml/cppo/cppo-1.5.0.ebuild | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/dev-ml/cppo/cppo-1.5.0.ebuild b/dev-ml/cppo/cppo-1.5.0.ebuild index 933faf0db61..39915b69c08 100644 --- a/dev-ml/cppo/cppo-1.5.0.ebuild +++ b/dev-ml/cppo/cppo-1.5.0.ebuild @@ -13,16 +13,22 @@ SLOT="0/${PV}" LICENSE="BSD" KEYWORDS="~amd64 ~arm ~ppc ~x86" -IUSE="examples" +IUSE="examples +ocamlopt" -RDEPEND=">=dev-lang/ocaml-3.12:= - dev-ml/ocamlbuild:=" +RDEPEND=" + >=dev-lang/ocaml-3.12:=[ocamlopt?] + dev-ml/ocamlbuild:=[ocamlopt?]" DEPEND="${RDEPEND}" +src_compile() { + use ocamlopt || sed -e 's/ocamlbuild_cppo.cmx/ocamlbuild_cppo.cmo/' -i Makefile + emake BEST="$(usex ocamlopt '.native' '.byte')" +} + src_install() { findlib_src_preinst mkdir -p "${ED}"/usr/bin - emake PREFIX="${ED}"/usr install + emake PREFIX="${ED}"/usr BEST="$(usex ocamlopt '.native' '.byte')" install dodoc README.md Changes if use examples ; then dodoc -r examples