1 |
commit: 7308d22d1c50252d43ed746463f63b47f4b8a7c1 |
2 |
Author: Sébastien Fabbro <bicatali <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Jan 4 05:32:45 2017 +0000 |
4 |
Commit: Sebastien Fabbro <bicatali <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Jan 4 06:02:05 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7308d22d |
7 |
|
8 |
dev-libs/libgpuarray: initial import |
9 |
|
10 |
Package-Manager: Portage-2.3.3, Repoman-2.3.1 |
11 |
|
12 |
dev-libs/libgpuarray/Manifest | 1 + |
13 |
dev-libs/libgpuarray/libgpuarray-0.6.0_rc1.ebuild | 61 +++++++++++++++++++++++ |
14 |
dev-libs/libgpuarray/metadata.xml | 19 +++++++ |
15 |
3 files changed, 81 insertions(+) |
16 |
|
17 |
diff --git a/dev-libs/libgpuarray/Manifest b/dev-libs/libgpuarray/Manifest |
18 |
new file mode 100644 |
19 |
index 00000000..259cd45 |
20 |
--- /dev/null |
21 |
+++ b/dev-libs/libgpuarray/Manifest |
22 |
@@ -0,0 +1 @@ |
23 |
+DIST libgpuarray-0.6.0_rc1.tar.gz 228152 SHA256 c49655af200920e539597f26f975388b02af2f3971567d7e713e1a4ccd0b2a58 SHA512 90b2d31ebe38c08610643b28262375ed093b6587d4fff0bff2b1bbe249de3ec1ff01893cce67401dfec2946095cf83545d5093e8e49d86cded332eb7063d5e2e WHIRLPOOL 44471721d6a75f6dbeac313fd6de9778db3f98bc48904f6333e18b7e24792d62c0def57d05d984908be5ea5241645fcab4d7c537d2dff1fad73e2883e42c8673 |
24 |
|
25 |
diff --git a/dev-libs/libgpuarray/libgpuarray-0.6.0_rc1.ebuild b/dev-libs/libgpuarray/libgpuarray-0.6.0_rc1.ebuild |
26 |
new file mode 100644 |
27 |
index 00000000..6ef1c71 |
28 |
--- /dev/null |
29 |
+++ b/dev-libs/libgpuarray/libgpuarray-0.6.0_rc1.ebuild |
30 |
@@ -0,0 +1,61 @@ |
31 |
+# Copyright 1999-2017 Gentoo Foundation |
32 |
+# Distributed under the terms of the GNU General Public License v2 |
33 |
+# $Id$ |
34 |
+ |
35 |
+EAPI=6 |
36 |
+ |
37 |
+inherit cmake-utils cuda |
38 |
+ |
39 |
+MYPV=${PV/_/-} |
40 |
+ |
41 |
+DESCRIPTION="Library to manipulate tensors on the GPU" |
42 |
+HOMEPAGE="http://deeplearning.net/software/libgpuarray/" |
43 |
+SRC_URI="https://github.com/Theano/${PN}/archive/v${MYPV}.tar.gz -> ${P}.tar.gz" |
44 |
+ |
45 |
+LICENSE="BSD" |
46 |
+SLOT="0" |
47 |
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" |
48 |
+IUSE="cuda doc opencl static-libs test" |
49 |
+ |
50 |
+# cuda/opencl loaded dynamically at runtime, no compile time dep |
51 |
+RDEPEND=" |
52 |
+ cuda? ( amd64? ( >=dev-util/nvidia-cuda-toolkit-7 ) ) |
53 |
+ opencl? ( |
54 |
+ virtual/opencl |
55 |
+ || ( sci-libs/clblast sci-libs/clblas ) |
56 |
+ ) |
57 |
+" |
58 |
+DEPEND=" |
59 |
+ doc? ( app-doc/doxygen ) |
60 |
+ test? ( ${RDEPEND} |
61 |
+ dev-libs/check |
62 |
+ virtual/pkgconfig |
63 |
+ ) |
64 |
+" |
65 |
+S="${WORKDIR}/${PN}-${MYPV}" |
66 |
+ |
67 |
+src_prepare() { |
68 |
+ sed -e 's/DESTINATION lib/DESTINATION ${CMAKE_INSTALL_LIBDIR}/g' \ |
69 |
+ -i src/CMakeLists.txt || die |
70 |
+ use cuda && cuda_src_prepare |
71 |
+ cmake-utils_src_prepare |
72 |
+} |
73 |
+ |
74 |
+src_configure() { |
75 |
+ local mycmakeargs=() |
76 |
+ cmake-utils_src_configure |
77 |
+ use doc && emake -C doc doxy |
78 |
+} |
79 |
+ |
80 |
+src_test() { |
81 |
+ local dev=cuda |
82 |
+ use opencl && dev=opencl |
83 |
+ DEVICE=${dev} cmake-utils_src_test |
84 |
+ # if !cuda or !opencl: no testing because tests fail |
85 |
+} |
86 |
+ |
87 |
+src_install() { |
88 |
+ use doc && HTML_DOCS=( doc/_doxybuild/html/. ) |
89 |
+ cmake-utils_src_install |
90 |
+ use static-libs || rm "${ED}/usr/$(get_libdir)/libgpuarray-static.a" |
91 |
+} |
92 |
|
93 |
diff --git a/dev-libs/libgpuarray/metadata.xml b/dev-libs/libgpuarray/metadata.xml |
94 |
new file mode 100644 |
95 |
index 00000000..81c8daf |
96 |
--- /dev/null |
97 |
+++ b/dev-libs/libgpuarray/metadata.xml |
98 |
@@ -0,0 +1,19 @@ |
99 |
+<?xml version="1.0" encoding="UTF-8"?> |
100 |
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> |
101 |
+<pkgmetadata> |
102 |
+ <maintainer type="project"> |
103 |
+ <email>sci@g.o</email> |
104 |
+ <name>Gentoo Science Project</name> |
105 |
+ </maintainer> |
106 |
+ <longdescription> |
107 |
+ Multi data-types, N-dimensional array library for the GPU, and |
108 |
+ with python numpy and theano workflow in mind. |
109 |
+ </longdescription> |
110 |
+ <upstream> |
111 |
+ <remote-id type="github">Theano/libgpuarray</remote-id> |
112 |
+ </upstream> |
113 |
+ <use> |
114 |
+ <flag name="cuda">Enable NVIDIA CUDA toolkit support</flag> |
115 |
+ <flag name="opencl">Enable OpenCL support</flag> |
116 |
+ </use> |
117 |
+</pkgmetadata> |