Compare commits
	
		
			3 Commits
		
	
	
		
			3118c68432
			...
			5d41e7603c
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					5d41e7603c | ||
| 
						 | 
					a2bb4f1ec0 | ||
| 
						 | 
					c35830a539 | 
							
								
								
									
										1
									
								
								dev-util/nvidia-cuda-toolkit/Manifest
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								dev-util/nvidia-cuda-toolkit/Manifest
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1 @@
 | 
				
			|||||||
 | 
					DIST cuda_12.6.1_560.35.03_linux.run 4345714567 BLAKE2B 147c7f03e0d9ade4c603d93920d0cd6bb1706efc268797ae870b5244feaa8159393015f96e920c6255e93d8040dd5b046075804cfa7c5da18a645800d65b8c3d SHA512 514ec89f847457c3ba78cd0dc22c25aebf2a19a6bbd5a8d071f31519d1007889cde6ba888a01596434216a8a88bfba21059cdc8e3fa9397133c93d2a9f0c015e
 | 
				
			||||||
							
								
								
									
										28
									
								
								dev-util/nvidia-cuda-toolkit/files/cuda-config.in
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								dev-util/nvidia-cuda-toolkit/files/cuda-config.in
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,28 @@
 | 
				
			|||||||
 | 
					#!/bin/bash
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					SUPPORT_GCC_VERSIONS_BY_CUDA="CUDA_SUPPORTED_GCC"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					_print_help() {
 | 
				
			||||||
 | 
						cat <<- EOF
 | 
				
			||||||
 | 
						Usage:
 | 
				
			||||||
 | 
							$(basename "$0") [options]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							-s | --supported   Returns by current CUDA supported gcc versions
 | 
				
			||||||
 | 
							-h | --help        Shows this help
 | 
				
			||||||
 | 
						EOF
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					case ${1} in
 | 
				
			||||||
 | 
						-s|--supported)
 | 
				
			||||||
 | 
							echo "${SUPPORT_GCC_VERSIONS_BY_CUDA}"
 | 
				
			||||||
 | 
							exit 0
 | 
				
			||||||
 | 
							;;
 | 
				
			||||||
 | 
						-h|--help)
 | 
				
			||||||
 | 
							_print_help
 | 
				
			||||||
 | 
							exit 255
 | 
				
			||||||
 | 
							;;
 | 
				
			||||||
 | 
						*)
 | 
				
			||||||
 | 
							_print_help
 | 
				
			||||||
 | 
							exit 1
 | 
				
			||||||
 | 
							;;
 | 
				
			||||||
 | 
					esac
 | 
				
			||||||
							
								
								
									
										16
									
								
								dev-util/nvidia-cuda-toolkit/metadata.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								dev-util/nvidia-cuda-toolkit/metadata.xml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,16 @@
 | 
				
			|||||||
 | 
					<?xml version="1.0" encoding="UTF-8"?>
 | 
				
			||||||
 | 
					<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
 | 
				
			||||||
 | 
					<pkgmetadata>
 | 
				
			||||||
 | 
						<maintainer type="project">
 | 
				
			||||||
 | 
							<email>pierre.saundersps@gmail.com</email>
 | 
				
			||||||
 | 
							<name>Pierre Saunders</name>
 | 
				
			||||||
 | 
						</maintainer>
 | 
				
			||||||
 | 
						<use>
 | 
				
			||||||
 | 
							<flag name="debugger">Install the CUDA debugger</flag>
 | 
				
			||||||
 | 
							<flag name="nsight">Install profiling and optimizing tools (nsight-compute, nsight-systems)</flag>
 | 
				
			||||||
 | 
							<flag name="profiler">Install the NVIDIA CUDA profiler (nvprof) and the related libraries</flag>
 | 
				
			||||||
 | 
							<flag name="rdma">Enable infiniband support via <pkg>sys-cluster/rdma-core</pkg></flag>
 | 
				
			||||||
 | 
							<flag name="sanitizer">Install compute-sanitizer tool</flag>
 | 
				
			||||||
 | 
							<flag name="vis-profiler">Install the NVIDIA CUDA visual profiler (nvvp)</flag>
 | 
				
			||||||
 | 
						</use>
 | 
				
			||||||
 | 
					</pkgmetadata>
 | 
				
			||||||
							
								
								
									
										328
									
								
								dev-util/nvidia-cuda-toolkit/nvidia-cuda-toolkit-12.6.1.ebuild
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										328
									
								
								dev-util/nvidia-cuda-toolkit/nvidia-cuda-toolkit-12.6.1.ebuild
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,328 @@
 | 
				
			|||||||
 | 
					# Copyright 1999-2024 Gentoo Authors
 | 
				
			||||||
 | 
					# Distributed under the terms of the GNU General Public License v2
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					EAPI=8
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					inherit check-reqs toolchain-funcs unpacker
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					DRIVER_PV="560.35.03"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					DESCRIPTION="NVIDIA CUDA Toolkit (compiler and friends)"
 | 
				
			||||||
 | 
					HOMEPAGE="https://developer.nvidia.com/cuda-zone"
 | 
				
			||||||
 | 
					SRC_URI="https://developer.download.nvidia.com/compute/cuda/${PV}/local_installers/cuda_${PV}_${DRIVER_PV}_linux.run"
 | 
				
			||||||
 | 
					S="${WORKDIR}"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					LICENSE="NVIDIA-CUDA"
 | 
				
			||||||
 | 
					SLOT="0/${PV}"
 | 
				
			||||||
 | 
					KEYWORDS="-* ~amd64 ~amd64-linux"
 | 
				
			||||||
 | 
					IUSE="debugger examples nsight profiler rdma vis-profiler sanitizer"
 | 
				
			||||||
 | 
					RESTRICT="bindist mirror"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# since CUDA 11, the bundled toolkit driver (== ${DRIVER_PV}) and the
 | 
				
			||||||
 | 
					# actual required minimum driver version are different.
 | 
				
			||||||
 | 
					RDEPEND="
 | 
				
			||||||
 | 
						<sys-devel/gcc-14_pre[cxx]
 | 
				
			||||||
 | 
						virtual/libcrypt
 | 
				
			||||||
 | 
						examples? (
 | 
				
			||||||
 | 
							media-libs/freeglut
 | 
				
			||||||
 | 
							media-libs/glu
 | 
				
			||||||
 | 
						)
 | 
				
			||||||
 | 
						nsight? (
 | 
				
			||||||
 | 
							app-crypt/mit-krb5
 | 
				
			||||||
 | 
							dev-libs/libpfm
 | 
				
			||||||
 | 
							dev-libs/wayland
 | 
				
			||||||
 | 
							dev-qt/qtwayland:6
 | 
				
			||||||
 | 
							>=dev-libs/openssl-3
 | 
				
			||||||
 | 
							media-libs/tiff-compat:4
 | 
				
			||||||
 | 
							sys-libs/zlib
 | 
				
			||||||
 | 
						)
 | 
				
			||||||
 | 
						rdma? ( sys-cluster/rdma-core )
 | 
				
			||||||
 | 
						vis-profiler? (
 | 
				
			||||||
 | 
							>=virtual/jre-1.8:*
 | 
				
			||||||
 | 
						)"
 | 
				
			||||||
 | 
					BDEPEND="nsight? ( dev-util/patchelf )"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					QA_PREBUILT="opt/cuda/*"
 | 
				
			||||||
 | 
					CHECKREQS_DISK_BUILD="15000M"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pkg_setup() {
 | 
				
			||||||
 | 
						check-reqs_pkg_setup
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					src_prepare() {
 | 
				
			||||||
 | 
						# ATTENTION: change requires revbump, see link below for supported GCC # versions
 | 
				
			||||||
 | 
						# https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html#system-requirements
 | 
				
			||||||
 | 
						local cuda_supported_gcc="8.5 9.5 10 11 12 13"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						sed \
 | 
				
			||||||
 | 
							-e "s:CUDA_SUPPORTED_GCC:${cuda_supported_gcc}:g" \
 | 
				
			||||||
 | 
							"${FILESDIR}"/cuda-config.in > "${T}"/cuda-config || die
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						default
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					src_install() {
 | 
				
			||||||
 | 
						local cudadir=/opt/cuda
 | 
				
			||||||
 | 
						local ecudadir="${EPREFIX}${cudadir}"
 | 
				
			||||||
 | 
						local pathextradirs ldpathextradirs
 | 
				
			||||||
 | 
						dodir ${cudadir}
 | 
				
			||||||
 | 
						into ${cudadir}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# Install standard sub packages
 | 
				
			||||||
 | 
						local builddirs=(
 | 
				
			||||||
 | 
							builds/cuda_{cccl,cudart,cuobjdump,cuxxfilt,demo_suite,nvcc,nvdisasm,nvml_dev,nvprune,nvrtc,nvtx,opencl}
 | 
				
			||||||
 | 
							builds/lib{cublas,cufft,cufile,curand,cusolver,cusparse,npp,nvjitlink,nvjpeg}
 | 
				
			||||||
 | 
							builds/nvidia_fs
 | 
				
			||||||
 | 
							$(usex profiler "builds/cuda_nvprof builds/cuda_cupti builds/cuda_profiler_api" "")
 | 
				
			||||||
 | 
							$(usex vis-profiler "builds/cuda_nvvp" "")
 | 
				
			||||||
 | 
							$(usex debugger "builds/cuda_gdb" "")
 | 
				
			||||||
 | 
						)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						local d f
 | 
				
			||||||
 | 
						for d in "${builddirs[@]}"; do
 | 
				
			||||||
 | 
							ebegin "Installing ${d}"
 | 
				
			||||||
 | 
							[[ -d ${d} ]] || die "Directory does not exist: ${d}"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							if [[ -d ${d}/bin ]]; then
 | 
				
			||||||
 | 
								for f in ${d}/bin/*; do
 | 
				
			||||||
 | 
									if [[ -f ${f} ]]; then
 | 
				
			||||||
 | 
										dobin "${f}"
 | 
				
			||||||
 | 
									else
 | 
				
			||||||
 | 
										insinto ${cudadir}/bin
 | 
				
			||||||
 | 
										doins -r "${f}"
 | 
				
			||||||
 | 
									fi
 | 
				
			||||||
 | 
								done
 | 
				
			||||||
 | 
							fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							insinto ${cudadir}
 | 
				
			||||||
 | 
							if [[ -d ${d}/targets ]]; then
 | 
				
			||||||
 | 
								doins -r "${d}"/targets
 | 
				
			||||||
 | 
							fi
 | 
				
			||||||
 | 
							if [[ -d ${d}/share ]]; then
 | 
				
			||||||
 | 
								doins -r "${d}"/share
 | 
				
			||||||
 | 
							fi
 | 
				
			||||||
 | 
							if [[ -d ${d}/extras ]]; then
 | 
				
			||||||
 | 
								doins -r "${d}"/extras
 | 
				
			||||||
 | 
							fi
 | 
				
			||||||
 | 
							eend $?
 | 
				
			||||||
 | 
						done
 | 
				
			||||||
 | 
						dobin "${T}"/cuda-config
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						doins builds/EULA.txt
 | 
				
			||||||
 | 
						# nvml and nvvm need special handling
 | 
				
			||||||
 | 
						ebegin "Installing nvvm"
 | 
				
			||||||
 | 
						doins -r builds/cuda_nvcc/nvvm
 | 
				
			||||||
 | 
						fperms +x ${cudadir}/nvvm/bin/cicc
 | 
				
			||||||
 | 
						eend $?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						ebegin "Installing nvml"
 | 
				
			||||||
 | 
						doins -r builds/cuda_nvml_dev/nvml
 | 
				
			||||||
 | 
						eend $?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						if use sanitizer; then
 | 
				
			||||||
 | 
							ebegin "Installing sanitizer"
 | 
				
			||||||
 | 
							dobin builds/integration/Sanitizer/compute-sanitizer
 | 
				
			||||||
 | 
							doins -r builds/cuda_sanitizer_api/compute-sanitizer
 | 
				
			||||||
 | 
							# special handling for the executable
 | 
				
			||||||
 | 
							fperms +x ${cudadir}/compute-sanitizer/compute-sanitizer
 | 
				
			||||||
 | 
							eend $?
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						use debugger && ldpathextradirs+=":${ecudadir}/extras/Debugger/lib64"
 | 
				
			||||||
 | 
						use profiler && ldpathextradirs+=":${ecudadir}/extras/CUPTI/lib64"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						if use vis-profiler; then
 | 
				
			||||||
 | 
							ebegin "Installing libnvvp"
 | 
				
			||||||
 | 
							doins -r builds/cuda_nvvp/libnvvp
 | 
				
			||||||
 | 
							# special handling for the executable
 | 
				
			||||||
 | 
							fperms +x ${cudadir}/libnvvp/nvvp
 | 
				
			||||||
 | 
							eend $?
 | 
				
			||||||
 | 
							pathextradirs+=":${ecudadir}/libnvvp"
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						if use nsight; then
 | 
				
			||||||
 | 
							local ncu_dir=$(grep -o 'nsight-compute-[0-9][0-9\.]*' -m1 manifests/cuda_x86_64.xml)
 | 
				
			||||||
 | 
							ebegin "Installing ${ncu_dir}"
 | 
				
			||||||
 | 
							mv builds/nsight_compute builds/${ncu_dir} || die
 | 
				
			||||||
 | 
							doins -r builds/${ncu_dir}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# check this list on every bump
 | 
				
			||||||
 | 
							local exes=(
 | 
				
			||||||
 | 
								${ncu_dir}/ncu
 | 
				
			||||||
 | 
								${ncu_dir}/ncu-ui
 | 
				
			||||||
 | 
								${ncu_dir}/host/linux-desktop-glibc_2_11_3-x64/libexec/QtWebEngineProcess
 | 
				
			||||||
 | 
								${ncu_dir}/host/linux-desktop-glibc_2_11_3-x64/CrashReporter
 | 
				
			||||||
 | 
								${ncu_dir}/host/linux-desktop-glibc_2_11_3-x64/OpenGLVersionChecker
 | 
				
			||||||
 | 
								${ncu_dir}/host/linux-desktop-glibc_2_11_3-x64/QdstrmImporter
 | 
				
			||||||
 | 
								${ncu_dir}/host/linux-desktop-glibc_2_11_3-x64/ncu-ui
 | 
				
			||||||
 | 
								${ncu_dir}/host/linux-desktop-glibc_2_11_3-x64/ncu-ui.bin
 | 
				
			||||||
 | 
								${ncu_dir}/target/linux-desktop-glibc_2_11_3-x64/TreeLauncherSubreaper
 | 
				
			||||||
 | 
								${ncu_dir}/target/linux-desktop-glibc_2_11_3-x64/TreeLauncherTargetLdPreloadHelper
 | 
				
			||||||
 | 
								${ncu_dir}/target/linux-desktop-glibc_2_11_3-x64/ncu
 | 
				
			||||||
 | 
							)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							dobin builds/integration/nsight-compute/{ncu,ncu-ui}
 | 
				
			||||||
 | 
							eend $?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# remove rdma libs (unless USE=rdma)
 | 
				
			||||||
 | 
							if ! use rdma; then
 | 
				
			||||||
 | 
								rm -r "${ED}"/${cudadir}/${ncu_dir}/host/target-linux-x64/CollectX || die
 | 
				
			||||||
 | 
							fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							local nsys_dir=$(grep -o 'nsight-systems-[0-9][0-9\.]*' -m1 manifests/cuda_x86_64.xml)
 | 
				
			||||||
 | 
							ebegin "Installing ${nsys_dir}"
 | 
				
			||||||
 | 
							mv builds/nsight_systems builds/${nsys_dir} || die
 | 
				
			||||||
 | 
							doins -r builds/${nsys_dir}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# check this list on every bump
 | 
				
			||||||
 | 
							exes+=(
 | 
				
			||||||
 | 
								${nsys_dir}/host-linux-x64/nsys-ui
 | 
				
			||||||
 | 
								${nsys_dir}/host-linux-x64/nsys-ui.bin
 | 
				
			||||||
 | 
								${nsys_dir}/host-linux-x64/ResolveSymbols
 | 
				
			||||||
 | 
								${nsys_dir}/host-linux-x64/ImportNvtxt
 | 
				
			||||||
 | 
								${nsys_dir}/host-linux-x64/CrashReporter
 | 
				
			||||||
 | 
								${nsys_dir}/host-linux-x64/QdstrmImporter
 | 
				
			||||||
 | 
								${nsys_dir}/host-linux-x64/libexec/QtWebEngineProcess
 | 
				
			||||||
 | 
								${nsys_dir}/target-linux-x64/nsys
 | 
				
			||||||
 | 
								${nsys_dir}/target-linux-x64/launcher
 | 
				
			||||||
 | 
								${nsys_dir}/target-linux-x64/nvgpucs
 | 
				
			||||||
 | 
								${nsys_dir}/target-linux-x64/nsys-launcher
 | 
				
			||||||
 | 
								${nsys_dir}/target-linux-x64/sqlite3
 | 
				
			||||||
 | 
								${nsys_dir}/target-linux-x64/python/bin/python
 | 
				
			||||||
 | 
								${nsys_dir}/target-linux-x64/CudaGpuInfoDumper
 | 
				
			||||||
 | 
							)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# remove rdma libs (unless USE=rdma)
 | 
				
			||||||
 | 
							if ! use rdma; then
 | 
				
			||||||
 | 
								rm -r "${ED}"/${cudadir}/${nsys_dir}/target-linux-x64/CollectX || die
 | 
				
			||||||
 | 
							fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							dobin builds/integration/nsight-systems/{nsight-sys,nsys,nsys-ui}
 | 
				
			||||||
 | 
							eend $?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# nsight scripts and binaries need to have their executable bit set, #691284
 | 
				
			||||||
 | 
							for f in "${exes[@]}"; do
 | 
				
			||||||
 | 
								fperms +x ${cudadir}/${f}
 | 
				
			||||||
 | 
							done
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# fix broken RPATHs
 | 
				
			||||||
 | 
							patchelf --set-rpath '$ORIGIN' \
 | 
				
			||||||
 | 
							"${ED}"/${cudadir}/${ncu_dir}/host/{linux-desktop-glibc_2_11_3-x64,target-linux-x64}/{libarrow.so,libparquet.so.500.0.0} || die
 | 
				
			||||||
 | 
							patchelf --set-rpath '$ORIGIN' \
 | 
				
			||||||
 | 
							"${ED}"/${cudadir}/${nsys_dir}/{host-linux-x64,target-linux-x64}/{libarrow.so,libparquet.so.500.0.0} || die
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# remove foreign archs (triggers SONAME warning, #749903)
 | 
				
			||||||
 | 
							rm -r "${ED}"/${cudadir}/${ncu_dir}/target/linux-desktop-t210-a64 || die
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# unbundle libstdc++
 | 
				
			||||||
 | 
							rm "${ED}"/${cudadir}/${nsys_dir}/host-linux-x64/libstdc++.so.6 || die
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# unbundle openssl
 | 
				
			||||||
 | 
							rm "${ED}"/${cudadir}/${ncu_dir}/host/linux-desktop-glibc_2_11_3-x64/lib{crypto,ssl}.so* || die
 | 
				
			||||||
 | 
							rm "${ED}"/${cudadir}/${nsys_dir}/host-linux-x64/lib{crypto,ssl}.so* || die
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# unbundle libpfm
 | 
				
			||||||
 | 
							rm "${ED}"/${cudadir}/${nsys_dir}/host-linux-x64/libpfm.so* || die
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# TODO: unbundle qt5
 | 
				
			||||||
 | 
							# TODO: unbundle boost
 | 
				
			||||||
 | 
							# TODO: unbundle icu
 | 
				
			||||||
 | 
							# TODO: unbundle mesa
 | 
				
			||||||
 | 
							# TODO: unbundle libSshClient
 | 
				
			||||||
 | 
							# TODO: unbundle sqlite
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						if use examples; then
 | 
				
			||||||
 | 
							local exes=(
 | 
				
			||||||
 | 
								extras/demo_suite/bandwidthTest
 | 
				
			||||||
 | 
								extras/demo_suite/busGrind
 | 
				
			||||||
 | 
								extras/demo_suite/deviceQuery
 | 
				
			||||||
 | 
								extras/demo_suite/nbody
 | 
				
			||||||
 | 
								extras/demo_suite/oceanFFT
 | 
				
			||||||
 | 
								extras/demo_suite/randomFog
 | 
				
			||||||
 | 
								extras/demo_suite/vectorAdd
 | 
				
			||||||
 | 
							)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							# set executable bit on demo_suite binaries
 | 
				
			||||||
 | 
							for f in "${exes[@]}"; do
 | 
				
			||||||
 | 
								fperms +x ${cudadir}/${f}
 | 
				
			||||||
 | 
							done
 | 
				
			||||||
 | 
						else
 | 
				
			||||||
 | 
							rm -r "${ED}"/${cudadir}/extras/demo_suite || die
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# remove rdma libs (unless USE=rdma)
 | 
				
			||||||
 | 
						if ! use rdma; then
 | 
				
			||||||
 | 
							rm "${ED}"/${cudadir}/targets/x86_64-linux/lib/libcufile_rdma* || die
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# Add include and lib symlinks
 | 
				
			||||||
 | 
						dosym targets/x86_64-linux/include ${cudadir}/include
 | 
				
			||||||
 | 
						dosym targets/x86_64-linux/lib ${cudadir}/lib64
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# Remove bad symlinks
 | 
				
			||||||
 | 
						rm "${ED}"/${cudadir}/targets/x86_64-linux/include/include || die
 | 
				
			||||||
 | 
						rm "${ED}"/${cudadir}/targets/x86_64-linux/lib/lib64 || die
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# Remove dead gdb plugins
 | 
				
			||||||
 | 
						if use debugger; then
 | 
				
			||||||
 | 
							rm "${ED}"/${cudadir}/bin/cuda-gdb-python3.{8,9}-tui || die
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						newenvd - 99cuda <<-EOF
 | 
				
			||||||
 | 
							PATH=${ecudadir}/bin${pathextradirs}
 | 
				
			||||||
 | 
							ROOTPATH=${ecudadir}/bin
 | 
				
			||||||
 | 
							LDPATH=${ecudadir}/lib64:${ecudadir}/nvvm/lib64${ldpathextradirs}
 | 
				
			||||||
 | 
						EOF
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# Cuda prepackages libraries, don't revdep-build on them
 | 
				
			||||||
 | 
						insinto /etc/revdep-rebuild
 | 
				
			||||||
 | 
						newins - 80${PN} <<-EOF
 | 
				
			||||||
 | 
							SEARCH_DIRS_MASK="${ecudadir}"
 | 
				
			||||||
 | 
						EOF
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# https://bugs.gentoo.org/926116
 | 
				
			||||||
 | 
						insinto /etc/sandbox.d
 | 
				
			||||||
 | 
						newins - 80${PN} <<-EOF
 | 
				
			||||||
 | 
							SANDBOX_PREDICT="/proc/self/task"
 | 
				
			||||||
 | 
						EOF
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pkg_postinst_check() {
 | 
				
			||||||
 | 
						local a="$("${EROOT}"/opt/cuda/bin/cuda-config -s)"
 | 
				
			||||||
 | 
						local b="0.0"
 | 
				
			||||||
 | 
						local v
 | 
				
			||||||
 | 
						for v in ${a}; do
 | 
				
			||||||
 | 
							ver_test "${v}" -gt "${b}" && b="${v}"
 | 
				
			||||||
 | 
						done
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						# if gcc and if not gcc-version is at least greatest supported
 | 
				
			||||||
 | 
						if tc-is-gcc && \
 | 
				
			||||||
 | 
							ver_test $(gcc-version) -gt "${b}"; then
 | 
				
			||||||
 | 
								ewarn
 | 
				
			||||||
 | 
								ewarn "gcc > ${b} will not work with CUDA"
 | 
				
			||||||
 | 
								ewarn "Make sure you set an earlier version of gcc with gcc-config"
 | 
				
			||||||
 | 
								ewarn "or append --compiler-bindir= pointing to a gcc bindir like"
 | 
				
			||||||
 | 
								ewarn "--compiler-bindir=${EPREFIX}/usr/*pc-linux-gnu/gcc-bin/gcc${b}"
 | 
				
			||||||
 | 
								ewarn "to the nvcc compiler flags"
 | 
				
			||||||
 | 
								ewarn
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pkg_postinst() {
 | 
				
			||||||
 | 
						if [[ ${MERGE_TYPE} != binary ]]; then
 | 
				
			||||||
 | 
							pkg_postinst_check
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						if use profiler || use nsight; then
 | 
				
			||||||
 | 
							einfo
 | 
				
			||||||
 | 
							einfo "nvidia-drivers restrict access to performance counters."
 | 
				
			||||||
 | 
							einfo "You'll need to either run profiling tools (nvprof, nsight) "
 | 
				
			||||||
 | 
							einfo "using sudo (needs cap SYS_ADMIN) or add the following line to "
 | 
				
			||||||
 | 
							einfo "a modprobe configuration file "
 | 
				
			||||||
 | 
							einfo "(e.g. /etc/modprobe.d/nvidia-prof.conf): "
 | 
				
			||||||
 | 
							einfo
 | 
				
			||||||
 | 
							einfo "options nvidia NVreg_RestrictProfilingToAdminUsers=0"
 | 
				
			||||||
 | 
							einfo
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
							
								
								
									
										1
									
								
								dev-vcs/lazygit/Manifest
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								dev-vcs/lazygit/Manifest
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1 @@
 | 
				
			|||||||
 | 
					DIST lazygit-0.44.0.tar.gz 4712697 BLAKE2B a3da1ec65f8e3ad302f3979f615b63d1628c3df7b2b4c8ca60b30d818c0ca13fa97cf8a2216ff249adb4852622fb724a7295cc404446cff96018aefeed908017 SHA512 48cc51d8ffb92d92a04e821db69b9c0058cc2e327d796c9e5367b5e11e43c4335a1e2822d31116920744b00d901e8a8cc532aa98e75a0b5ee300db4aaa351a94
 | 
				
			||||||
							
								
								
									
										34
									
								
								dev-vcs/lazygit/lazygit-0.44.0.ebuild
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										34
									
								
								dev-vcs/lazygit/lazygit-0.44.0.ebuild
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,34 @@
 | 
				
			|||||||
 | 
					# Copyright 1999-2024 Gentoo Authors
 | 
				
			||||||
 | 
					# Distributed under the terms of the GNU General Public License v2
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					EAPI=8
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					inherit go-module
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					DESCRIPTION="Simple terminal UI for git commands"
 | 
				
			||||||
 | 
					HOMEPAGE="https://github.com/jesseduffield/lazygit"
 | 
				
			||||||
 | 
					SRC_URI="https://github.com/jesseduffield/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					S="${WORKDIR}/${P}"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					LICENSE="Apache-2.0 BSD ISC MIT Unlicense"
 | 
				
			||||||
 | 
					SLOT="0"
 | 
				
			||||||
 | 
					KEYWORDS="~amd64 ~arm64"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					RDEPEND="dev-vcs/git"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					DOCS=( {CODE-OF-CONDUCT,CONTRIBUTING,README}.md docs )
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					src_compile() {
 | 
				
			||||||
 | 
						ego build -o bin/${PN} \
 | 
				
			||||||
 | 
							-ldflags "-X main.version=${PV}"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					src_test() {
 | 
				
			||||||
 | 
						ego test ./... -short
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					src_install() {
 | 
				
			||||||
 | 
						dobin bin/${PN}
 | 
				
			||||||
 | 
						einstalldocs
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
							
								
								
									
										28
									
								
								dev-vcs/lazygit/metadata.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								dev-vcs/lazygit/metadata.xml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,28 @@
 | 
				
			|||||||
 | 
					<?xml version="1.0" encoding="UTF-8"?>
 | 
				
			||||||
 | 
					<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
 | 
				
			||||||
 | 
					<pkgmetadata>
 | 
				
			||||||
 | 
					  <maintainer type="person">
 | 
				
			||||||
 | 
					    <email>torokhov-s-a@yandex.ru</email>
 | 
				
			||||||
 | 
					    <name>Sergey Torokhov</name>
 | 
				
			||||||
 | 
					  </maintainer>
 | 
				
			||||||
 | 
					  <longdescription lang="en">
 | 
				
			||||||
 | 
					    A simple terminal UI for both docker and docker-compose, written in Go with the gocui library.
 | 
				
			||||||
 | 
					    Minor rant incoming: Something's not working? Maybe a service is down. docker-compose ps.
 | 
				
			||||||
 | 
					    Yep, it's that microservice that's still buggy. No issue, I'll just restart it: docker-compose restart.
 | 
				
			||||||
 | 
					    Okay now let's try again. Oh wait the issue is still there. Hmm. docker-compose ps.
 | 
				
			||||||
 | 
					    Right so the service must have just stopped immediately after starting.
 | 
				
			||||||
 | 
					    I probably would have known that if I was reading the log stream, but there is a lot of clutter in there from other services.
 | 
				
			||||||
 | 
					    I could get the logs for just that one service with docker compose logs --follow myservice but that dies everytime the service dies so I'd need to run that command every time I restart the service.
 | 
				
			||||||
 | 
					    I could alternatively run docker-compose up myservice and in that terminal window if the service is down I could just up it again,
 | 
				
			||||||
 | 
					    but now I've got one service hogging a terminal window even after I no longer care about its logs.
 | 
				
			||||||
 | 
					    I guess when I want to reclaim the terminal realestate I can do ctrl+P,Q, but... wait, that's not working for some reason.
 | 
				
			||||||
 | 
					    Should I use ctrl+C instead? I can't remember if that closes the foreground process or kills the actual service.
 | 
				
			||||||
 | 
					    What a headache! Memorising docker commands is hard. Memorising aliases is slightly less hard.
 | 
				
			||||||
 | 
					    Keeping track of your containers across multiple terminal windows is near impossible.
 | 
				
			||||||
 | 
					    What if you had all the information you needed in one terminal window with every common command living one keypress away (and the ability to add custom commands as well).
 | 
				
			||||||
 | 
					    Lazydocker's goal is to make that dream a reality.
 | 
				
			||||||
 | 
					  </longdescription>
 | 
				
			||||||
 | 
					  <upstream>
 | 
				
			||||||
 | 
					    <remote-id type="github">jesseduffield/lazydocker</remote-id>
 | 
				
			||||||
 | 
					  </upstream>
 | 
				
			||||||
 | 
					</pkgmetadata>
 | 
				
			||||||
							
								
								
									
										15
									
								
								metadata/md5-cache/dev-util/nvidia-cuda-toolkit-12.6.1
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								metadata/md5-cache/dev-util/nvidia-cuda-toolkit-12.6.1
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,15 @@
 | 
				
			|||||||
 | 
					BDEPEND=nsight? ( dev-util/patchelf )
 | 
				
			||||||
 | 
					DEFINED_PHASES=install postinst prepare pretend setup unpack
 | 
				
			||||||
 | 
					DESCRIPTION=NVIDIA CUDA Toolkit (compiler and friends)
 | 
				
			||||||
 | 
					EAPI=8
 | 
				
			||||||
 | 
					HOMEPAGE=https://developer.nvidia.com/cuda-zone
 | 
				
			||||||
 | 
					INHERIT=check-reqs toolchain-funcs unpacker
 | 
				
			||||||
 | 
					IUSE=debugger examples nsight profiler rdma vis-profiler sanitizer
 | 
				
			||||||
 | 
					KEYWORDS=-* ~amd64 ~amd64-linux
 | 
				
			||||||
 | 
					LICENSE=NVIDIA-CUDA
 | 
				
			||||||
 | 
					RDEPEND=<sys-devel/gcc-14_pre[cxx] virtual/libcrypt examples? ( media-libs/freeglut media-libs/glu ) nsight? ( app-crypt/mit-krb5 dev-libs/libpfm dev-libs/wayland dev-qt/qtwayland:6 >=dev-libs/openssl-3 media-libs/tiff-compat:4 sys-libs/zlib ) rdma? ( sys-cluster/rdma-core ) vis-profiler? ( >=virtual/jre-1.8:* )
 | 
				
			||||||
 | 
					RESTRICT=bindist mirror
 | 
				
			||||||
 | 
					SLOT=0/12.6.1
 | 
				
			||||||
 | 
					SRC_URI=https://developer.download.nvidia.com/compute/cuda/12.6.1/local_installers/cuda_12.6.1_560.35.03_linux.run
 | 
				
			||||||
 | 
					_eclasses_=check-reqs	02ac7654b64f7acc7a8b1a35ad9d6ddc	toolchain-funcs	333970c740aa7b1a92e4fcdc52f612bd	multilib	c19072c3cd7ac5cb21de013f7e9832e0	multiprocessing	30ead54fa2e2b5f9cd4e612ffc34d0fe	unpacker	fb4b84181244b3b9990fa0bf40232dd2
 | 
				
			||||||
 | 
					_md5_=613c71dbd1db215587f5e8c2b53e02b2
 | 
				
			||||||
							
								
								
									
										14
									
								
								metadata/md5-cache/dev-vcs/lazygit-0.44.0
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								metadata/md5-cache/dev-vcs/lazygit-0.44.0
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,14 @@
 | 
				
			|||||||
 | 
					BDEPEND=>=dev-lang/go-1.20:= app-arch/unzip
 | 
				
			||||||
 | 
					DEFINED_PHASES=compile install test unpack
 | 
				
			||||||
 | 
					DESCRIPTION=Simple terminal UI for git commands
 | 
				
			||||||
 | 
					EAPI=8
 | 
				
			||||||
 | 
					HOMEPAGE=https://github.com/jesseduffield/lazygit
 | 
				
			||||||
 | 
					INHERIT=go-module
 | 
				
			||||||
 | 
					KEYWORDS=~amd64 ~arm64
 | 
				
			||||||
 | 
					LICENSE=Apache-2.0 BSD ISC MIT Unlicense
 | 
				
			||||||
 | 
					RDEPEND=dev-vcs/git
 | 
				
			||||||
 | 
					RESTRICT=strip
 | 
				
			||||||
 | 
					SLOT=0
 | 
				
			||||||
 | 
					SRC_URI=https://github.com/jesseduffield/lazygit/archive/v0.44.0.tar.gz -> lazygit-0.44.0.tar.gz
 | 
				
			||||||
 | 
					_eclasses_=multiprocessing	30ead54fa2e2b5f9cd4e612ffc34d0fe	toolchain-funcs	333970c740aa7b1a92e4fcdc52f612bd	multilib	c19072c3cd7ac5cb21de013f7e9832e0	flag-o-matic	e503ea5acc20410237ba33ec3f7c857d	go-env	90efbc8636d2f02d9654183330e84cf7	go-module	83fd3ed1657cfc316c93d6a37018290d
 | 
				
			||||||
 | 
					_md5_=fffc26be4b9c84acf0b3dd71edb44fd3
 | 
				
			||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
BDEPEND=>=dev-lang/go-1.18 app-arch/unzip
 | 
					BDEPEND=>=dev-lang/go-1.20:= app-arch/unzip
 | 
				
			||||||
DEFINED_PHASES=compile install unpack
 | 
					DEFINED_PHASES=compile install unpack
 | 
				
			||||||
DESCRIPTION=terminal UI for npm
 | 
					DESCRIPTION=terminal UI for npm
 | 
				
			||||||
EAPI=8
 | 
					EAPI=8
 | 
				
			||||||
@@ -10,5 +10,5 @@ RDEPEND=net-libs/nodejs
 | 
				
			|||||||
RESTRICT=strip
 | 
					RESTRICT=strip
 | 
				
			||||||
SLOT=0
 | 
					SLOT=0
 | 
				
			||||||
SRC_URI=https://github.com/jesseduffield/lazynpm/archive/v0.1.4.tar.gz -> lazynpm-0.1.4.tar.gz
 | 
					SRC_URI=https://github.com/jesseduffield/lazynpm/archive/v0.1.4.tar.gz -> lazynpm-0.1.4.tar.gz
 | 
				
			||||||
_eclasses_=multiprocessing	30ead54fa2e2b5f9cd4e612ffc34d0fe	toolchain-funcs	eed10cf5e5a06916e654d31f5a1925cc	multilib	c19072c3cd7ac5cb21de013f7e9832e0	go-env	96e1747610bbb2f5c5d3fb16f0f3a83a	go-module	9e5a8f7b134fd3ed3785755097fe8ef0
 | 
					_eclasses_=multiprocessing	30ead54fa2e2b5f9cd4e612ffc34d0fe	toolchain-funcs	333970c740aa7b1a92e4fcdc52f612bd	multilib	c19072c3cd7ac5cb21de013f7e9832e0	flag-o-matic	e503ea5acc20410237ba33ec3f7c857d	go-env	90efbc8636d2f02d9654183330e84cf7	go-module	83fd3ed1657cfc316c93d6a37018290d
 | 
				
			||||||
_md5_=79d6a966ec95f1db4cf4ad25a1d4e7aa
 | 
					_md5_=5690d445a8a5788f8dafc2b4853afc21
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
# Copyright 1999-2023 Gentoo Authors
 | 
					# Copyright 1999-2024 Gentoo Authors
 | 
				
			||||||
# Distributed under the terms of the GNU General Public License v2
 | 
					# Distributed under the terms of the GNU General Public License v2
 | 
				
			||||||
 | 
					
 | 
				
			||||||
EAPI=8
 | 
					EAPI=8
 | 
				
			||||||
@@ -9,12 +9,12 @@ DESCRIPTION="terminal UI for npm"
 | 
				
			|||||||
HOMEPAGE="https://github.com/jesseduffield/lazynpm"
 | 
					HOMEPAGE="https://github.com/jesseduffield/lazynpm"
 | 
				
			||||||
SRC_URI="https://github.com/jesseduffield/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
 | 
					SRC_URI="https://github.com/jesseduffield/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					S="${WORKDIR}/${P}"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
LICENSE="Apache-2.0 BSD ISC MIT Unlicense"
 | 
					LICENSE="Apache-2.0 BSD ISC MIT Unlicense"
 | 
				
			||||||
SLOT="0"
 | 
					SLOT="0"
 | 
				
			||||||
KEYWORDS="~amd64 ~arm64"
 | 
					KEYWORDS="~amd64 ~arm64"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
S="${WORKDIR}/${P}"
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
RDEPEND="net-libs/nodejs"
 | 
					RDEPEND="net-libs/nodejs"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
DOCS=( {CODE-OF-CONDUCT,CONTRIBUTING,README}.md docs )
 | 
					DOCS=( {CODE-OF-CONDUCT,CONTRIBUTING,README}.md docs )
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user