Merge pull request #120285 from r-burns/pycuda

pycuda: fix opengl runpath
This commit is contained in:
Daniël de Kok 2021-04-23 07:51:56 +02:00 committed by GitHub
commit e7893cdf1d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,5 @@
{ buildPythonPackage
, addOpenGLRunpath
, fetchPypi
, fetchFromGitHub
, Mako
@ -40,6 +41,13 @@ buildPythonPackage rec {
ln -s ${compyte} $out/${python.sitePackages}/pycuda/compyte
'';
postFixup = ''
find $out/lib -type f \( -name '*.so' -or -name '*.so.*' \) | while read lib; do
echo "setting opengl runpath for $lib..."
addOpenGLRunpath "$lib"
done
'';
# Requires access to libcuda.so.1 which is provided by the driver
doCheck = false;
@ -47,6 +55,10 @@ buildPythonPackage rec {
py.test
'';
nativeBuildInputs = [
addOpenGLRunpath
];
propagatedBuildInputs = [
numpy
pytools