Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not Very Stable (to the shared libraries) #3

Open
Alexhuszagh opened this issue Feb 3, 2018 · 0 comments
Open

Not Very Stable (to the shared libraries) #3

Alexhuszagh opened this issue Feb 3, 2018 · 0 comments

Comments

@Alexhuszagh
Copy link

Alexhuszagh commented Feb 3, 2018

I tried building NumPy for Python3.6 on the latest amazonlinux Docker image, but python setup.py config always showed the libraries were not being found.

The solution was painfully simple: preserve the various installed library versions and symlinks, and copy all versions (preserving symlinks) to /var/task/lib.

Original

cp /usr/lib64/atlas-sse3/liblapack.so.3 /var/task/lib/.
cp /usr/lib64/atlas-sse3/libptf77blas.so.3 /var/task/lib/.
cp /usr/lib64/atlas-sse3/libf77blas.so.3 /var/task/lib/.
cp /usr/lib64/atlas-sse3/libptcblas.so.3 /var/task/lib/.
cp /usr/lib64/atlas-sse3/libcblas.so.3 /var/task/lib/.
cp /usr/lib64/atlas-sse3/libatlas.so.3 /var/task/lib/.
cp /usr/lib64/atlas-sse3/libptf77blas.so.3 /var/task/lib/.
cp /usr/lib64/libgfortran.so.3 /var/task/lib/.
cp /usr/lib64/libquadmath.so.0 /var/task/lib/.

Fixed

function long_copy()
{
     # Pass the path
     for f in $1* ; do cp -P "$f" /var/task/lib/. ; done
}

long_copy /usr/lib64/atlas-sse3/liblapack.so
long_copy /usr/lib64/atlas-sse3/libptf77blas.so
long_copy /usr/lib64/atlas-sse3/libf77blas.so
long_copy /usr/lib64/atlas-sse3/libptcblas.so
long_copy /usr/lib64/atlas-sse3/libcblas.so
long_copy /usr/lib64/atlas-sse3/libatlas.so
long_copy /usr/lib64/atlas-sse3/libptf77blas.so
long_copy /usr/lib64/libgfortran.so
long_copy /usr/lib64/libquadmath.so

The solution is quite simple, and preserves the correct symlinks to work with the 3.6 runtime.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant