Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #10681

Re: LibraryLink & MinGW

From Michael Weyrauch <michael.weyrauch@gmx.de>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: LibraryLink & MinGW
Date 2012-06-29 08:49 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <jsjq70$cuj$1@smc.vnet.net> (permalink)
References <js3uag$um$1@smc.vnet.net> <jsbt5h$6qc$1@smc.vnet.net> <jsh3b7$sj0$1@smc.vnet.net>

Show all headers | View raw


Well, unlike Alexander Rasputinov, I am using the 32 bit implementation,
and as he suspected, in this case everything works "out of the box" 
indeed.  I downloaded the the MinGW from its official website.
But, of course, in order to create the .dll I do not need to use gcc
and all that directly but everything is taken care of "out of the box"
by the appropriate Mathematica commands as e.g. CreateLibrary[].
(Of course, if you need any special libraries for your project you
need to tell this in the CreateLibrary[] command as documented. So, e.g.
I am linking in some code which was written in Fortran so I explicitely
have to load the standard Fortran libraries)

The only small issue I encountered was the fact that in order that
everthing really works "out of the box" you MUST install MinGW in
its default directory, which is "C:\MinGW". If you install it e.g. on 
another partition, the Mathematica interface to the Compiler does not 
find it. This restriction can be circumvented, but then you must change 
some Mathematica files, which I do not recommend. (Actually I find it 
rather strange that the carfully designed Mathematica interface to the 
various compilers has such a restriction, which could be easily avoided 
to my opinion.)

Michael

Am 28.6.2012 10:07, schrieb Mike Griffis:
> When reviewing these comments, I started thinking my issue is using win32 port of mingw.  Are you using win64?  Where are you downloading your mingw? I think mingw.org only gets you a win32 port.  (My gcc commands were minimal to compile and create a "shared" library.)
>


Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

LibraryLink & MinGW fortgriff <griff@eigenpt.com> - 2012-06-23 08:21 +0000
  Re: LibraryLink & MinGW "Oleksandr Rasputinov" <oleksandr_rasputinov@ymail.com> - 2012-06-24 08:25 +0000
    Re: LibraryLink & MinGW Mike Griffis <griff@eigenpt.com> - 2012-06-28 08:07 +0000
  Re: LibraryLink & MinGW Michael Weyrauch <michael.weyrauch@gmx.de> - 2012-06-26 08:50 +0000
    Re: LibraryLink & MinGW Mike Griffis <griff@eigenpt.com> - 2012-06-28 08:07 +0000
      Re: LibraryLink & MinGW Michael Weyrauch <michael.weyrauch@gmx.de> - 2012-06-29 08:49 +0000

csiph-web