Discussion:
[Numpy-discussion] Building Numpy with OpenBLAS
G Young
2016-01-27 09:39:46 UTC
Permalink
Hello all,

I'm trying to update the documentation for building Numpy from source, and
I've hit a brick wall in trying to build the library using OpenBLAS because
I can't seem to link the libopenblas.dll file. I tried following the
suggestion of placing the DLL in numpy/core as suggested here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but it
still doesn't pick it up. What am I doing wrong?

Thanks,

Greg
Michael Sarahan
2016-01-27 13:14:15 UTC
Permalink
I'm not sure about the mingw tool chain, but usually on windows at link
time you need a .lib file, called the import library. The .dll is used at
runtime, not at link time. This is different from *nix, where the .so
serves both purposes. The link you posted mentions import files, so I hope
this is helpful information.

Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from source, and
I've hit a brick wall in trying to build the library using OpenBLAS because
I can't seem to link the libopenblas.dll file. I tried following the
suggestion of placing the DLL in numpy/core as suggested here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but it
still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
G Young
2016-01-27 13:40:28 UTC
Permalink
I do have my site.cfg file pointing to my library which contains a .lib
file along with the appropriate include_dirs parameter. However, NumPy
can't seem to find / use the DLL file no matter where I put it (numpy/core,
same directory as openblas.lib). By the way, I should mention that I am
using a slightly dated version of OpenBLAS (0.2.9), but that shouldn't have
any effect I would imagine.

Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at link
time you need a .lib file, called the import library. The .dll is used at
runtime, not at link time. This is different from *nix, where the .so
serves both purposes. The link you posted mentions import files, so I hope
this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from source,
and I've hit a brick wall in trying to build the library using OpenBLAS
because I can't seem to link the libopenblas.dll file. I tried following
the suggestion of placing the DLL in numpy/core as suggested here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
Michael Sarahan
2016-01-27 13:58:10 UTC
Permalink
When you say find/use, can you please clarify whether you have completed
the compilation/linking successfully? I'm not clear on exactly when you're
having problems. What is the error output?

One very helpful tool in diagnosing dll problems is dependency walker:
http://www.dependencywalker.com/

It may be that your openblas has a dependency that it can't load for some
reason. Dependency walker works on .pyd files as well as .dll files.

Hth,
Michael
Post by G Young
I do have my site.cfg file pointing to my library which contains a .lib
file along with the appropriate include_dirs parameter. However, NumPy
can't seem to find / use the DLL file no matter where I put it (numpy/core,
same directory as openblas.lib). By the way, I should mention that I am
using a slightly dated version of OpenBLAS (0.2.9), but that shouldn't have
any effect I would imagine.
Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at link
time you need a .lib file, called the import library. The .dll is used at
runtime, not at link time. This is different from *nix, where the .so
serves both purposes. The link you posted mentions import files, so I hope
this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from source,
and I've hit a brick wall in trying to build the library using OpenBLAS
because I can't seem to link the libopenblas.dll file. I tried following
the suggestion of placing the DLL in numpy/core as suggested here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
G Young
2016-01-27 14:19:52 UTC
Permalink
NumPy will "build" successfully, but then when I type "import numpy", it
cannot import the multiarray PYD file.

I am using dependency walker, and that's how I know it's the
libopenblas.dll file that it's not linking to properly, hence my original
question.

Greg
Post by Michael Sarahan
When you say find/use, can you please clarify whether you have completed
the compilation/linking successfully? I'm not clear on exactly when you're
having problems. What is the error output?
http://www.dependencywalker.com/
It may be that your openblas has a dependency that it can't load for some
reason. Dependency walker works on .pyd files as well as .dll files.
Hth,
Michael
Post by G Young
I do have my site.cfg file pointing to my library which contains a .lib
file along with the appropriate include_dirs parameter. However, NumPy
can't seem to find / use the DLL file no matter where I put it (numpy/core,
same directory as openblas.lib). By the way, I should mention that I am
using a slightly dated version of OpenBLAS (0.2.9), but that shouldn't have
any effect I would imagine.
Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at link
time you need a .lib file, called the import library. The .dll is used at
runtime, not at link time. This is different from *nix, where the .so
serves both purposes. The link you posted mentions import files, so I hope
this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from source,
and I've hit a brick wall in trying to build the library using OpenBLAS
because I can't seem to link the libopenblas.dll file. I tried following
the suggestion of placing the DLL in numpy/core as suggested here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
Ralf Gommers
2016-01-27 14:48:21 UTC
Permalink
Post by G Young
NumPy will "build" successfully, but then when I type "import numpy", it
cannot import the multiarray PYD file.
I am using dependency walker, and that's how I know it's the
libopenblas.dll file that it's not linking to properly, hence my original
question.
The support for MingwPy in numpy.distutils had to be temporarily reverted
(see https://github.com/numpy/numpy/pull/6536), because the patch caused
other issues. So likely it just won't work out of the box now. If you need
it, maybe you can reapply that reverted patch. But otherwise I'd wait a
little bit; we'll sort out the MingwPy build in the near future.

Ralf
Post by G Young
Greg
Post by Michael Sarahan
When you say find/use, can you please clarify whether you have completed
the compilation/linking successfully? I'm not clear on exactly when you're
having problems. What is the error output?
http://www.dependencywalker.com/
It may be that your openblas has a dependency that it can't load for some
reason. Dependency walker works on .pyd files as well as .dll files.
Hth,
Michael
Post by G Young
I do have my site.cfg file pointing to my library which contains a .lib
file along with the appropriate include_dirs parameter. However, NumPy
can't seem to find / use the DLL file no matter where I put it (numpy/core,
same directory as openblas.lib). By the way, I should mention that I am
using a slightly dated version of OpenBLAS (0.2.9), but that shouldn't have
any effect I would imagine.
Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at link
time you need a .lib file, called the import library. The .dll is used at
runtime, not at link time. This is different from *nix, where the .so
serves both purposes. The link you posted mentions import files, so I hope
this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from source,
and I've hit a brick wall in trying to build the library using OpenBLAS
because I can't seem to link the libopenblas.dll file. I tried following
the suggestion of placing the DLL in numpy/core as suggested here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
G Young
2016-01-27 14:51:10 UTC
Permalink
I don't need it at this point. I'm just going through the exercise for
purposes of updating building from source on Windows. But that's good to
know though. Thanks!

Greg
Post by Ralf Gommers
Post by G Young
NumPy will "build" successfully, but then when I type "import numpy", it
cannot import the multiarray PYD file.
I am using dependency walker, and that's how I know it's the
libopenblas.dll file that it's not linking to properly, hence my original
question.
The support for MingwPy in numpy.distutils had to be temporarily reverted
(see https://github.com/numpy/numpy/pull/6536), because the patch caused
other issues. So likely it just won't work out of the box now. If you need
it, maybe you can reapply that reverted patch. But otherwise I'd wait a
little bit; we'll sort out the MingwPy build in the near future.
Ralf
Post by G Young
Greg
Post by Michael Sarahan
When you say find/use, can you please clarify whether you have completed
the compilation/linking successfully? I'm not clear on exactly when you're
having problems. What is the error output?
http://www.dependencywalker.com/
It may be that your openblas has a dependency that it can't load for
some reason. Dependency walker works on .pyd files as well as .dll files.
Hth,
Michael
Post by G Young
I do have my site.cfg file pointing to my library which contains a .lib
file along with the appropriate include_dirs parameter. However, NumPy
can't seem to find / use the DLL file no matter where I put it (numpy/core,
same directory as openblas.lib). By the way, I should mention that I am
using a slightly dated version of OpenBLAS (0.2.9), but that shouldn't have
any effect I would imagine.
Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at
link time you need a .lib file, called the import library. The .dll is
used at runtime, not at link time. This is different from *nix, where the
.so serves both purposes. The link you posted mentions import files, so I
hope this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from
source, and I've hit a brick wall in trying to build the library using
OpenBLAS because I can't seem to link the libopenblas.dll file. I tried
following the suggestion of placing the DLL in numpy/core as suggested
here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
Ralf Gommers
2016-01-27 15:01:34 UTC
Permalink
Post by G Young
I don't need it at this point. I'm just going through the exercise for
purposes of updating building from source on Windows. But that's good to
know though. Thanks!
That effort is much appreciated by the way. Updating the build info on all
platforms on http://scipy.org/scipylib/building/index.html is a significant
amount of work, and it has never been in a state one could call complete.
So more contributions definitely welcome!

Ralf
Post by G Young
Greg
Post by Ralf Gommers
Post by G Young
NumPy will "build" successfully, but then when I type "import numpy", it
cannot import the multiarray PYD file.
I am using dependency walker, and that's how I know it's the
libopenblas.dll file that it's not linking to properly, hence my original
question.
The support for MingwPy in numpy.distutils had to be temporarily reverted
(see https://github.com/numpy/numpy/pull/6536), because the patch caused
other issues. So likely it just won't work out of the box now. If you need
it, maybe you can reapply that reverted patch. But otherwise I'd wait a
little bit; we'll sort out the MingwPy build in the near future.
Ralf
Post by G Young
Greg
Post by Michael Sarahan
When you say find/use, can you please clarify whether you have
completed the compilation/linking successfully? I'm not clear on exactly
when you're having problems. What is the error output?
http://www.dependencywalker.com/
It may be that your openblas has a dependency that it can't load for
some reason. Dependency walker works on .pyd files as well as .dll files.
Hth,
Michael
Post by G Young
I do have my site.cfg file pointing to my library which contains a
.lib file along with the appropriate include_dirs parameter. However,
NumPy can't seem to find / use the DLL file no matter where I put it
(numpy/core, same directory as openblas.lib). By the way, I should mention
that I am using a slightly dated version of OpenBLAS (0.2.9), but that
shouldn't have any effect I would imagine.
Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at
link time you need a .lib file, called the import library. The .dll is
used at runtime, not at link time. This is different from *nix, where the
.so serves both purposes. The link you posted mentions import files, so I
hope this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from
source, and I've hit a brick wall in trying to build the library using
OpenBLAS because I can't seem to link the libopenblas.dll file. I tried
following the suggestion of placing the DLL in numpy/core as suggested
here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
Carl Kleffner
2016-01-27 18:27:41 UTC
Permalink
In my timeplan the next mingwpy PR on numpy master is anticipated to take
place at the weekend, together with a build description. This PR is
targeted to build numpy with OpenBLAS.

Carl
Post by Ralf Gommers
Post by G Young
I don't need it at this point. I'm just going through the exercise for
purposes of updating building from source on Windows. But that's good to
know though. Thanks!
That effort is much appreciated by the way. Updating the build info on all
platforms on http://scipy.org/scipylib/building/index.html is a
significant amount of work, and it has never been in a state one could call
complete. So more contributions definitely welcome!
Ralf
Post by G Young
Greg
Post by Ralf Gommers
Post by G Young
NumPy will "build" successfully, but then when I type "import numpy",
it cannot import the multiarray PYD file.
I am using dependency walker, and that's how I know it's the
libopenblas.dll file that it's not linking to properly, hence my original
question.
The support for MingwPy in numpy.distutils had to be temporarily
reverted (see https://github.com/numpy/numpy/pull/6536), because the
patch caused other issues. So likely it just won't work out of the box now.
If you need it, maybe you can reapply that reverted patch. But otherwise
I'd wait a little bit; we'll sort out the MingwPy build in the near future.
Ralf
Post by G Young
Greg
Post by Michael Sarahan
When you say find/use, can you please clarify whether you have
completed the compilation/linking successfully? I'm not clear on exactly
when you're having problems. What is the error output?
http://www.dependencywalker.com/
It may be that your openblas has a dependency that it can't load for
some reason. Dependency walker works on .pyd files as well as .dll files.
Hth,
Michael
Post by G Young
I do have my site.cfg file pointing to my library which contains a
.lib file along with the appropriate include_dirs parameter. However,
NumPy can't seem to find / use the DLL file no matter where I put it
(numpy/core, same directory as openblas.lib). By the way, I should mention
that I am using a slightly dated version of OpenBLAS (0.2.9), but that
shouldn't have any effect I would imagine.
Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at
link time you need a .lib file, called the import library. The .dll is
used at runtime, not at link time. This is different from *nix, where the
.so serves both purposes. The link you posted mentions import files, so I
hope this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from
source, and I've hit a brick wall in trying to build the library using
OpenBLAS because I can't seem to link the libopenblas.dll file. I tried
following the suggestion of placing the DLL in numpy/core as suggested
here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
G Young
2016-01-27 20:30:34 UTC
Permalink
That's great! I look forward to seeing that.

Greg
Post by Carl Kleffner
In my timeplan the next mingwpy PR on numpy master is anticipated to take
place at the weekend, together with a build description. This PR is
targeted to build numpy with OpenBLAS.
Carl
Post by Ralf Gommers
Post by G Young
I don't need it at this point. I'm just going through the exercise for
purposes of updating building from source on Windows. But that's good to
know though. Thanks!
That effort is much appreciated by the way. Updating the build info on
all platforms on http://scipy.org/scipylib/building/index.html is a
significant amount of work, and it has never been in a state one could call
complete. So more contributions definitely welcome!
Ralf
Post by G Young
Greg
Post by Ralf Gommers
Post by G Young
NumPy will "build" successfully, but then when I type "import numpy",
it cannot import the multiarray PYD file.
I am using dependency walker, and that's how I know it's the
libopenblas.dll file that it's not linking to properly, hence my original
question.
The support for MingwPy in numpy.distutils had to be temporarily
reverted (see https://github.com/numpy/numpy/pull/6536), because the
patch caused other issues. So likely it just won't work out of the box now.
If you need it, maybe you can reapply that reverted patch. But otherwise
I'd wait a little bit; we'll sort out the MingwPy build in the near future.
Ralf
Post by G Young
Greg
Post by Michael Sarahan
When you say find/use, can you please clarify whether you have
completed the compilation/linking successfully? I'm not clear on exactly
when you're having problems. What is the error output?
One very helpful tool in diagnosing dll problems is dependency
walker: http://www.dependencywalker.com/
It may be that your openblas has a dependency that it can't load for
some reason. Dependency walker works on .pyd files as well as .dll files.
Hth,
Michael
Post by G Young
I do have my site.cfg file pointing to my library which contains a
.lib file along with the appropriate include_dirs parameter. However,
NumPy can't seem to find / use the DLL file no matter where I put it
(numpy/core, same directory as openblas.lib). By the way, I should mention
that I am using a slightly dated version of OpenBLAS (0.2.9), but that
shouldn't have any effect I would imagine.
Greg
Post by Michael Sarahan
I'm not sure about the mingw tool chain, but usually on windows at
link time you need a .lib file, called the import library. The .dll is
used at runtime, not at link time. This is different from *nix, where the
.so serves both purposes. The link you posted mentions import files, so I
hope this is helpful information.
Best,
Michael
Post by G Young
Hello all,
I'm trying to update the documentation for building Numpy from
source, and I've hit a brick wall in trying to build the library using
OpenBLAS because I can't seem to link the libopenblas.dll file. I tried
following the suggestion of placing the DLL in numpy/core as suggested
here
<https://github.com/numpy/numpy/wiki/Mingw-static-toolchain#notes> but
it still doesn't pick it up. What am I doing wrong?
Thanks,
Greg
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
https://mail.scipy.org/mailman/listinfo/numpy-discussion
Loading...