1 |
commit: 173494a8b63a5fa4a63eac9dfcf30dd9527e4b54 |
2 |
Author: Jason Zaman <perfinion <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Nov 29 10:03:25 2019 +0000 |
4 |
Commit: Jason Zaman <perfinion <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Dec 2 14:49:42 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=173494a8 |
7 |
|
8 |
dev-util/nvidia-cuda-toolkit: bump 10.2 |
9 |
|
10 |
Package-Manager: Portage-2.3.79, Repoman-2.3.16 |
11 |
Signed-off-by: Jason Zaman <perfinion <AT> gentoo.org> |
12 |
|
13 |
dev-util/nvidia-cuda-toolkit/Manifest | 1 + |
14 |
.../nvidia-cuda-toolkit-10.2.89.ebuild | 156 +++++++++++++++++++++ |
15 |
2 files changed, 157 insertions(+) |
16 |
|
17 |
diff --git a/dev-util/nvidia-cuda-toolkit/Manifest b/dev-util/nvidia-cuda-toolkit/Manifest |
18 |
index c329f3a714f..97b780f3783 100644 |
19 |
--- a/dev-util/nvidia-cuda-toolkit/Manifest |
20 |
+++ b/dev-util/nvidia-cuda-toolkit/Manifest |
21 |
@@ -2,6 +2,7 @@ DIST cuda_10.0.130_410.48_linux.run 2020126691 BLAKE2B f784f41c06d81b6f89d07e756 |
22 |
DIST cuda_10.1.105_418.39_linux.run 2423314285 BLAKE2B 924872eaaa4e8ecd6b81765c91d5e538d968e4fc88792a805339dd9cae15dd70372f310d39b9668d76cadbab875e3c4abcfca5a5cf71e4d83c9db056dc02f51c SHA512 07cdc053989758e4cdccaad566cae7127fa79780ad85033ea52d33cc4c43c9de08e88dd087390c58b542e51703f256859cdf51a018ee57e6a412f45fb9561622 |
23 |
DIST cuda_10.1.168_418.67_linux.run 2526901749 BLAKE2B ed2207400730600c63895cc894e02a14dce59c6293f198ea2a94f6dd0fab25a005d4754f91376c267cb95f3fdc66ee08e4353ec17b69d28881c59190b9eb4746 SHA512 85635012ec7081e200fb46f973852939f9709e802f495c288d5f31ff1fbd283a578fdaca0afa8955e6e0c7ca6c4862428da5168e0938b48390952d8633350910 |
24 |
DIST cuda_10.1.243_418.87.00_linux.run 2572375299 BLAKE2B df9cb4faeeeeecc536e72697c6c73d544219f1b23cacb7fed646b0908fc7e573e85920861d56f76776ba637d84964cd1c789a0fe0d6541a4e0adf618b6c74d3c SHA512 f92b19d0242969a65a6e6db43bc293e442abc07a9e168c9e995692e1a401679504598c782e511be3879e1650b90f71a50bbc63c9ee45654c26b5007cdf33c4fe |
25 |
+DIST cuda_10.2.89_440.33.01_linux.run 2645419389 BLAKE2B 236aa70a7b45e3636c2c229fffa7d1ca0699ab4365865a73edab607a209c42c2899133dd6a83c61c5929fa754668ad15aec4d847639af1c00a8e6657c8487c77 SHA512 ad8da539ff5df7caf411d1e497ff3d6978cfa8a1fd9150fa4846089e92a604ea56be8631f3efdfe7229a655b8d2d28e6edb32f5731530a77d6f00241cc7aab6e |
26 |
DIST cuda_6.5.14_linux_32.run 76788277 BLAKE2B 75e79dce6cac5155bde8a3cafa945047c489b10272f8a3b94bf55d499df4b9c8b82506a81a20f9fd816bd4fd0514e515a6435399db1cb62b027c76490bd4dfae SHA512 89649ee0f4543b37037b7c8f5ed0b8bd502512afb4d93e3158b3df4786123be05a5288986b5abbfe15c14eb010777d2527b715225bea96a354a898c34e4a2fcc |
27 |
DIST cuda_6.5.14_linux_64.run 972320904 BLAKE2B 4a4361fb7a90989ec4b4aa433189e7b358e5a2272fb9b9c59429e0014ac14e3b8de1b247ee98dc30c3f3ee4cc009eca4fdd86027bd3b9527a683353d60bdf5c6 SHA512 fecca731b86955f5bc7b09d88b02951e3ee5d4b1f1cf5f92658227a029b87cd35d6ac22956a5fa0afe62dcdc57191f1d12bb08c9f7cc05128727cd8455947b1e |
28 |
DIST cuda_6.5.19_linux_32.run 81882112 BLAKE2B cf55ef7c969503c156431fc56301ed4e9a1234ae0cb867f12649636069f35e56bf6fc9df7482b6baade45d78c8baa2d98c41a28696da59294e0f575c4a0344ce SHA512 1ce9bd6b472b7e4f1fb181eb340dfcb757714d59a89aaa02146cfe1a97c8ccb7eb7699b4ec823276f277eb4d82d95050eaba17e7ed5fd2e47b9b5d78531c5d4e |
29 |
|
30 |
diff --git a/dev-util/nvidia-cuda-toolkit/nvidia-cuda-toolkit-10.2.89.ebuild b/dev-util/nvidia-cuda-toolkit/nvidia-cuda-toolkit-10.2.89.ebuild |
31 |
new file mode 100644 |
32 |
index 00000000000..5d9eeee669c |
33 |
--- /dev/null |
34 |
+++ b/dev-util/nvidia-cuda-toolkit/nvidia-cuda-toolkit-10.2.89.ebuild |
35 |
@@ -0,0 +1,156 @@ |
36 |
+# Copyright 1999-2019 Gentoo Authors |
37 |
+# Distributed under the terms of the GNU General Public License v2 |
38 |
+ |
39 |
+EAPI=7 |
40 |
+ |
41 |
+inherit check-reqs cuda toolchain-funcs unpacker |
42 |
+ |
43 |
+MYD=$(ver_cut 1-2 ${PV}) |
44 |
+DRIVER_PV="440.33.01" |
45 |
+ |
46 |
+DESCRIPTION="NVIDIA CUDA Toolkit (compiler and friends)" |
47 |
+HOMEPAGE="https://developer.nvidia.com/cuda-zone" |
48 |
+SRC_URI="https://developer.download.nvidia.com/compute/cuda/${MYD}/Prod/local_installers/cuda_${PV}_${DRIVER_PV}_linux.run" |
49 |
+ |
50 |
+LICENSE="NVIDIA-CUDA" |
51 |
+SLOT="0/${PV}" |
52 |
+KEYWORDS="-* ~amd64 ~amd64-linux" |
53 |
+IUSE="debugger doc eclipse profiler" |
54 |
+RESTRICT="bindist mirror" |
55 |
+ |
56 |
+BDEPEND="" |
57 |
+RDEPEND=" |
58 |
+ <sys-devel/gcc-9[cxx] |
59 |
+ >=x11-drivers/nvidia-drivers-${DRIVER_PV}[X,uvm] |
60 |
+ debugger? ( |
61 |
+ dev-libs/openssl-compat:1.0.0 |
62 |
+ sys-libs/libtermcap-compat |
63 |
+ sys-libs/ncurses-compat:5[tinfo] |
64 |
+ ) |
65 |
+ eclipse? ( |
66 |
+ dev-libs/openssl-compat:1.0.0 |
67 |
+ >=virtual/jre-1.6 |
68 |
+ ) |
69 |
+ profiler? ( |
70 |
+ dev-libs/openssl-compat:1.0.0 |
71 |
+ >=virtual/jre-1.6 |
72 |
+ )" |
73 |
+ |
74 |
+S="${WORKDIR}" |
75 |
+ |
76 |
+QA_PREBUILT="opt/cuda/*" |
77 |
+ |
78 |
+CHECKREQS_DISK_BUILD="6800M" |
79 |
+ |
80 |
+pkg_setup() { |
81 |
+ # We don't like to run cuda_pkg_setup as it depends on us |
82 |
+ check-reqs_pkg_setup |
83 |
+} |
84 |
+ |
85 |
+src_prepare() { |
86 |
+ local cuda_supported_gcc |
87 |
+ |
88 |
+ cuda_supported_gcc="4.7 4.8 4.9 5.3 5.4 6.3 6.4 7.2 7.3 8.2 8.3" |
89 |
+ |
90 |
+ sed \ |
91 |
+ -e "s:CUDA_SUPPORTED_GCC:${cuda_supported_gcc}:g" \ |
92 |
+ "${FILESDIR}"/cuda-config.in > "${T}"/cuda-config || die |
93 |
+ |
94 |
+ default |
95 |
+} |
96 |
+ |
97 |
+src_install() { |
98 |
+ local i remove=( doc ) |
99 |
+ local cudadir=/opt/cuda |
100 |
+ local ecudadir="${EPREFIX}${cudadir}" |
101 |
+ |
102 |
+ cd builds/cuda-toolkit |
103 |
+ if use doc; then |
104 |
+ DOCS+=( doc/pdf/. ) |
105 |
+ HTML_DOCS+=( doc/html/. ) |
106 |
+ fi |
107 |
+ einstalldocs |
108 |
+ |
109 |
+ mv doc/man/man3/{,cuda-}deprecated.3 || die |
110 |
+ doman doc/man/man*/* |
111 |
+ |
112 |
+ use debugger || remove+=( bin/cuda-gdb bin/cuda-gdbserver extras/Debugger share/gdb extras/cuda-gdb-${PV}.src.tar.gz ) |
113 |
+ |
114 |
+ if use profiler; then |
115 |
+ # hack found in install-linux.pl |
116 |
+ for i in nvvp nsight; do |
117 |
+ cat > bin/${i} <<- EOF || die |
118 |
+ #!/usr/bin/env sh |
119 |
+ LD_LIBRARY_PATH=\${LD_LIBRARY_PATH}:${ecudadir}/lib:${ecudadir}/lib64 \ |
120 |
+ UBUNTU_MENUPROXY=0 LIBOVERLAY_SCROLLBAR=0 \ |
121 |
+ ${ecudadir}/lib${i}/${i} -vm ${EPREFIX}/usr/bin/java |
122 |
+ EOF |
123 |
+ chmod a+x bin/${i} || die |
124 |
+ done |
125 |
+ else |
126 |
+ use eclipse || remove+=( libnvvp libnsight nsightee_plugins nsight-compute-2019.4.0 nsight-systems-2019.3.7.5 bin/nsight bin/nsight_ee_plugins_manage.sh bin/nvvp bin/computeprof ) |
127 |
+ remove+=( extras/CUPTI bin/nvprof ) |
128 |
+ fi |
129 |
+ |
130 |
+ for i in "${remove[@]}"; do |
131 |
+ ebegin "Cleaning ${i}..." |
132 |
+ rm -r "${i}" || die |
133 |
+ eend |
134 |
+ done |
135 |
+ |
136 |
+ dodir ${cudadir} |
137 |
+ into ${cudadir} |
138 |
+ |
139 |
+ # Install binaries separately to make sure the X permission is set |
140 |
+ local bindirs=( bin nvvm/bin extras/demo_suite ) |
141 |
+ for i in $(find "${bindirs[@]}" -maxdepth 1 -type f); do |
142 |
+ exeinto ${cudadir}/${i%/*} |
143 |
+ doexe ${i} |
144 |
+ rm ${i} || die |
145 |
+ done |
146 |
+ |
147 |
+ # Install the rest |
148 |
+ insinto ${cudadir} |
149 |
+ doins -r * |
150 |
+ |
151 |
+ cat > "${T}"/99cuda <<- EOF || die |
152 |
+ PATH=${ecudadir}/bin$(usex profiler ":${ecudadir}/libnvvp" "") |
153 |
+ ROOTPATH=${ecudadir}/bin |
154 |
+ LDPATH=${ecudadir}/lib64:${ecudadir}/lib:${ecudadir}/nvvm/lib64 |
155 |
+ EOF |
156 |
+ doenvd "${T}"/99cuda |
157 |
+ |
158 |
+ use profiler && \ |
159 |
+ make_wrapper nvprof "${ecudadir}/bin/nvprof" "." "${ecudadir}/lib64:${ecudadir}/lib" |
160 |
+ |
161 |
+ dobin "${T}"/cuda-config |
162 |
+} |
163 |
+ |
164 |
+pkg_postinst_check() { |
165 |
+ local a b |
166 |
+ a="$(${EROOT}/opt/cuda/bin/cuda-config -s)" |
167 |
+ b="0.0" |
168 |
+ for v in $a; do |
169 |
+ if ver_test "${v}" -gt "${b}"; then |
170 |
+ b="${v}" |
171 |
+ fi |
172 |
+ done |
173 |
+ |
174 |
+ # if gcc and if not gcc-version is at least greatest supported |
175 |
+ if tc-is-gcc && \ |
176 |
+ ver_test $(gcc-version) -gt ${b}; then |
177 |
+ ewarn "" |
178 |
+ ewarn "gcc > ${b} will not work with CUDA" |
179 |
+ ewarn "Make sure you set an earlier version of gcc with gcc-config" |
180 |
+ ewarn "or append --compiler-bindir= pointing to a gcc bindir like" |
181 |
+ ewarn "--compiler-bindir=${EPREFIX}/usr/*pc-linux-gnu/gcc-bin/gcc${b}" |
182 |
+ ewarn "to the nvcc compiler flags" |
183 |
+ ewarn "" |
184 |
+ fi |
185 |
+} |
186 |
+ |
187 |
+pkg_postinst() { |
188 |
+ if [[ ${MERGE_TYPE} != binary ]]; then |
189 |
+ pkg_postinst_check |
190 |
+ fi |
191 |
+} |