On Sun, Dec 28, 2014 at 1:59 AM, Matthew Brett <[email protected]> wrote:
> Hi, > > Sorry for this ignorant email, but we got confused trying to use > 'libnpymath.a' from the mingw builds of numpy: > > We were trying to link against the mingw numpy 'libnpymath.a' using > Visual Studio C, but this give undefined symbols from 'libnpymath.a' > like this: > This is not really supported. You should avoid mixing compilers when building C extensions using numpy C API. Either all mingw, or all MSVC. David > > npymath.lib(npy_math.o) : error LNK2019: unresolved external symbol > _atanf referenced in function _npy_atanf > npymath.lib(npy_math.o) : error LNK2019: unresolved external symbol > _acosf referenced in function _npy_acosf > npymath.lib(npy_math.o) : error LNK2019: unresolved external symbol > _asinf referenced in function _npy_asinf > > (see : > http://nipy.bic.berkeley.edu/builders/dipy-bdist32-33/builds/73/steps/shell_6/logs/stdio > ) > > npymath.lib from Christophe Gohlke's (MSVC compiled) numpies does not > give such an error. Sure enough, 'npymath.lib' shows these lines from > `dumpbin /all npymath.lib`: > > 00000281 REL32 00000000 4F asinf > 00000291 REL32 00000000 51 acosf > 000002A1 REL32 00000000 53 atanf > > whereas `dumpbin /all libnpymath.a` shows these kinds of lines: > > 000008E5 REL32 00000000 86 _asinf > 000008F5 REL32 00000000 85 _acosf > 00000905 REL32 00000000 84 _atanf > > As far as I can see, 'acosf' is defined in the msvc runtime library. > I guess that '_acosf' is defined in some mingw runtime library? Is > there any way of making a npymath library that will pick up the msvc > math and so may work with both msvc and mingw? > > Sorry again if that's a dumb question, > > Matthew > _______________________________________________ > NumPy-Discussion mailing list > [email protected] > http://mail.scipy.org/mailman/listinfo/numpy-discussion >
_______________________________________________ NumPy-Discussion mailing list [email protected] http://mail.scipy.org/mailman/listinfo/numpy-discussion
