[gentoo-commits] repo/gentoo:master commit in: dev-ml/llvm-ocaml/files/, dev-ml/llvm-ocaml/

2017-02-02 Thread Michał Górny
commit: 707a3d1cfc64be2148ddb6f4dce3b5ffb9e7866c
Author: Michał Górny  gentoo  org>
AuthorDate: Thu Feb  2 15:47:52 2017 +
Commit: Michał Górny  gentoo  org>
CommitDate: Thu Feb  2 15:50:27 2017 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=707a3d1c

dev-ml/llvm-ocaml: Remove obsolete CMAKE_BUILD_TYPE patch

 ...ake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch | 28 --
 dev-ml/llvm-ocaml/llvm-ocaml-4.0.0_rc1.ebuild  |  3 ---
 dev-ml/llvm-ocaml/llvm-ocaml-.ebuild   |  3 ---
 3 files changed, 34 deletions(-)

diff --git 
a/dev-ml/llvm-ocaml/files/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
 
b/dev-ml/llvm-ocaml/files/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
deleted file mode 100644
index 8a2c091..
--- 
a/dev-ml/llvm-ocaml/files/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From a2ecd4815d285281cb816e06b25dc0dc2a933073 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= 
-Date: Sun, 21 Aug 2016 23:13:45 +0200
-Subject: [PATCH 06/10] cmake: Remove the CMAKE_BUILD_TYPE assertion
-

- CMakeLists.txt | 5 -
- 1 file changed, 5 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 894bc8c..453fcb8 100644
 a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -232,11 +232,6 @@ endif()
- 
- string(TOUPPER "${CMAKE_BUILD_TYPE}" uppercase_CMAKE_BUILD_TYPE)
- 
--if (CMAKE_BUILD_TYPE AND
--NOT uppercase_CMAKE_BUILD_TYPE MATCHES 
"^(DEBUG|RELEASE|RELWITHDEBINFO|MINSIZEREL)$")
--  message(FATAL_ERROR "Invalid value for CMAKE_BUILD_TYPE: 
${CMAKE_BUILD_TYPE}")
--endif()
--
- set(LLVM_LIBDIR_SUFFIX "" CACHE STRING "Define suffix of library directory 
name (32/64)" )
- 
- set(LLVM_TOOLS_INSTALL_DIR "bin" CACHE STRING "Path for binary subdirectory 
(defaults to 'bin')")
--- 
-2.9.3
-

diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-4.0.0_rc1.ebuild 
b/dev-ml/llvm-ocaml/llvm-ocaml-4.0.0_rc1.ebuild
index d9e815d..e984d57 100644
--- a/dev-ml/llvm-ocaml/llvm-ocaml-4.0.0_rc1.ebuild
+++ b/dev-ml/llvm-ocaml/llvm-ocaml-4.0.0_rc1.ebuild
@@ -58,9 +58,6 @@ src_prepare() {
# Python is needed to run tests using lit
python_setup
 
-   # Allow custom cmake build types (like 'Gentoo')
-   eapply 
"${FILESDIR}"/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
-
# User patches
eapply_user
 }

diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-.ebuild 
b/dev-ml/llvm-ocaml/llvm-ocaml-.ebuild
index 41c9948..49f0909 100644
--- a/dev-ml/llvm-ocaml/llvm-ocaml-.ebuild
+++ b/dev-ml/llvm-ocaml/llvm-ocaml-.ebuild
@@ -57,9 +57,6 @@ src_prepare() {
# Python is needed to run tests using lit
python_setup
 
-   # Allow custom cmake build types (like 'Gentoo')
-   eapply 
"${FILESDIR}"/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
-
# User patches
eapply_user
 }



[gentoo-commits] repo/gentoo:master commit in: dev-ml/llvm-ocaml/files/, dev-ml/llvm-ocaml/

2016-11-12 Thread Michał Górny
commit: 1144ef99daab3a370e0e6d9c1b6f42cfe2d84d85
Author: Michał Górny  gentoo  org>
AuthorDate: Sat Nov 12 14:31:35 2016 +
Commit: Michał Górny  gentoo  org>
CommitDate: Sat Nov 12 14:41:04 2016 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1144ef99

dev-ml/llvm-ocaml: Split OCaml bindings out of LLVM

Introduce an ebuild to build LLVM OCaml bindings separately from LLVM
itself. As pointed out by our OCaml team, the OCaml bindings have to be
rebuilt much more frequently than LLVM itself (that is, on every
dependency upgrade). Furthermore, OCaml tests seem to have problems
running from build dir without LLVM installed. Therefore, use
the LLVM_OCAML_OUT_OF_TREE build logic that was added for OPAM.

 ...ake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch |  28 +
 dev-ml/llvm-ocaml/llvm-ocaml-.ebuild   | 115 +
 dev-ml/llvm-ocaml/metadata.xml |   7 ++
 3 files changed, 150 insertions(+)

diff --git 
a/dev-ml/llvm-ocaml/files/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
 
b/dev-ml/llvm-ocaml/files/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
new file mode 100644
index ..8a2c091
--- /dev/null
+++ 
b/dev-ml/llvm-ocaml/files/llvm-cmake-Remove-the-CMAKE_BUILD_TYPE-assertion.patch
@@ -0,0 +1,28 @@
+From a2ecd4815d285281cb816e06b25dc0dc2a933073 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= 
+Date: Sun, 21 Aug 2016 23:13:45 +0200
+Subject: [PATCH 06/10] cmake: Remove the CMAKE_BUILD_TYPE assertion
+
+---
+ CMakeLists.txt | 5 -
+ 1 file changed, 5 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 894bc8c..453fcb8 100644
+--- a/CMakeLists.txt
 b/CMakeLists.txt
+@@ -232,11 +232,6 @@ endif()
+ 
+ string(TOUPPER "${CMAKE_BUILD_TYPE}" uppercase_CMAKE_BUILD_TYPE)
+ 
+-if (CMAKE_BUILD_TYPE AND
+-NOT uppercase_CMAKE_BUILD_TYPE MATCHES 
"^(DEBUG|RELEASE|RELWITHDEBINFO|MINSIZEREL)$")
+-  message(FATAL_ERROR "Invalid value for CMAKE_BUILD_TYPE: 
${CMAKE_BUILD_TYPE}")
+-endif()
+-
+ set(LLVM_LIBDIR_SUFFIX "" CACHE STRING "Define suffix of library directory 
name (32/64)" )
+ 
+ set(LLVM_TOOLS_INSTALL_DIR "bin" CACHE STRING "Path for binary subdirectory 
(defaults to 'bin')")
+-- 
+2.9.3
+

diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-.ebuild 
b/dev-ml/llvm-ocaml/llvm-ocaml-.ebuild
new file mode 100644
index ..43a6277
--- /dev/null
+++ b/dev-ml/llvm-ocaml/llvm-ocaml-.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+: ${CMAKE_MAKEFILE_GENERATOR:=ninja}
+CMAKE_MIN_VERSION=3.4.3
+
+PYTHON_COMPAT=( python2_7 )
+inherit cmake-utils git-r3 python-any-r1
+
+DESCRIPTION="OCaml bindings for LLVM"
+HOMEPAGE="http://llvm.org/;
+SRC_URI=""
+EGIT_REPO_URI="http://llvm.org/git/llvm.git
+   https://github.com/llvm-mirror/llvm.git;
+
+# Keep in sync with sys-devel/llvm
+ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM BPF Hexagon Lanai Mips MSP430
+   NVPTX PowerPC RISCV Sparc SystemZ X86 XCore )
+ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" )
+LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/?}
+
+LICENSE="UoI-NCSA"
+SLOT="0/${PV}"
+KEYWORDS=""
+IUSE="test ${ALL_LLVM_TARGETS[*]}"
+
+RDEPEND="
+   >=dev-lang/ocaml-4.00.0:0=
+   dev-ml/ocaml-ctypes:=
+   ~sys-devel/llvm-${PV}:=[${LLVM_TARGET_USEDEPS// /,}]
+   !sys-devel/llvm[ocaml(-)]"
+# configparser-3.2 breaks the build (3.3 or none at all are fine)
+DEPEND="${RDEPEND}
+   dev-lang/perl
+   dev-ml/findlib
+   test? ( dev-ml/ounit
+   $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]') )
+   !!
+http://www.gentoo.org/dtd/metadata.dtd;>
+
+   
+   l...@gentoo.org
+   
+