help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Windows, mkoctfile and DLLs


From: Andy Adler
Subject: Re: Windows, mkoctfile and DLLs
Date: Tue, 12 Nov 2002 13:08:17 -0500 (EST)

On Tue, 12 Nov 2002, Paul Kienzle wrote:
> You need a cygwin development environment in order to do so, but you will
> need that anyway if you are building your own oct-files.  [Hmmm... I wonder
> if you could build octave files from VC++ even though octave itself was
> compiled from Cygwin?  Probably not, since the C++ ABI is not
> standardized.]

I'm just tried this. It doesn't look easy. Even compiling is
hard, since Microsoft headers do not co-operative easily with cygwin's.
Linking would be even harder.

OTOH cygwin can call DLL's created with VC++, so that would be the way
to link foreign code into octave. [Ensuring that you are GPL compatible,
of course]

Here's an example:
$ cl  -D__IEEE_LITTLE_ENDIAN -c
   -IC:/cygwin/usr/local/include/octave-2.1.39
   -IC:/cygwin/usr/local/include/octave-2.1.39/octave
   -IC:/cygwin/usr/local/include
   -IC:/cygwin/usr/include -GX hello.cpp
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for 80x86
Copyright (C) Microsoft Corp 1984-1998. All rights reserved.

hello.cpp
C:/cygwin/usr/include\sys/reent.h(487) : error C2632: 'long' followed by 'long' 
is illegal
C:/cygwin/usr/include\stdlib.h(51) : error C2733: second C linkage of overloaded
 function 'atexit' not allowed
C:\DEVSTU~1\VC98\INCLUDE\iosfwd(73) : error C2065: 'mbstate_t' : undeclared 
identifier
C:\DEVSTU~1\VC98\INCLUDE\iosfwd(82) : error C2146: syntax error : missing ';' 
before identifier 'state_type'

... and many more errors...

> I don't know what version the prebuilt windows distributions
> are using, or whether they were built with --enable-shared.

All the prebuilt windows distributions I'm aware of use static builds.
I'm planning to put together another octave-forge one, once Paul
decides the octave-forge is 2.1.39 ready.

Andy
--
Andy Adler,
Assistant Professor, School of Information Technology and Engineering,
University of Ottawa, Tel:1(613)562-5800 X 2345, Email:address@hidden





-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]