I just read that the naming convention is different on Windows than Linux.
So we have:

libmpir.a    (Unix convention)
mpir.dll      (Windows convention)
mpir.lib      (Windows convention)

I do not know what needs to be passed to the mex command. However, on MinGW

-lmpir should find any of the above, but it won't find a file named
libmpir.lib. Perhaps this is also important on Windows.

Bill.

On 19 June 2015 at 16:51, Bill Hart <goodwillh...@googlemail.com> wrote:

>
>
> On 19 June 2015 at 16:46, Brian Gladman <b...@gladman.plus.com> wrote:
>
>> On 19/06/2015 15:28, 'Bill Hart' via mpir-devel wrote:
>>
>> > Anyhow the error message above suggests something is linking against
>> > MPIR but the linker is somehow looking for an internal symbol (it's
>> > something to do with the complicated way symbols are handled in MinGW).
>> > This could be because your system PATH is not set to include the
>> > directory where the dll file is.
>>
>> On Windows it is possible to link directly to a DLL but this is more
>> normally done through a stub-library.
>>
>> So on a native build on Windows the mpir.dll is accompanied by the stub
>> library mpir.lib.  So an app links to the stub library which then links
>> to the DLL itself.  IIRC a symbol 'sym' in the DLL becomes '__imp__sym'
>> in the stub library so it seems to me that the mingw/GCC build system is
>> not producing a stub library.
>>
>
> That sounds right to me. The mingw build doesn't produce a .lib file (stub
> library). You have to create one if you want to use the dll produced by
> mingw.
>
> In fact, the stub library is apparently not required to use the dll with
> mingw, which I guess is why it doesn't create one. Internally, it uses the
> Microsoft linker, but I don't completely understand the precise mechanism.
>
> Bill.
>
>
>>    Brian
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "mpir-devel" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to mpir-devel+unsubscr...@googlegroups.com.
>> To post to this group, send email to mpir-devel@googlegroups.com.
>> Visit this group at http://groups.google.com/group/mpir-devel.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"mpir-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to mpir-devel+unsubscr...@googlegroups.com.
To post to this group, send email to mpir-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/mpir-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to