Hello David
After one day rest, my condition rather better so that I can think about this 
with cool head.

Cannot src/Makefile in the fixed package come back before for mingw/cygwin pat 
without affective for
Unix build ?

My previous patch works correctly.

Using previous the Makefile that I made a patch before , the fixed.oct linked 
the following 
Linking fixed.oct
g++ -shared -Wl,--export-all-symbols -Wl,--enable-auto-import 
-Wl,--enable-runtime-pseudo-reloc -o
fixed.oct fixed-int.o fixedColVector.o fixedRowVector.o fixedMatrix.o 
fixedComplex.o fixedCColVector.o
fixedCRowVector.o fixedCMatrix.o Array-f.o fixed-conv.o ov-fixed.o 
ov-fixed-mat.o fixedNDArray.o
fixedCNDArray.o ov-fixed-complex.o ov-fixed-cx-mat.o op-fs-fs.o op-fs-fm.o 
op-fm-fs.o op-fm-fm.o
op-fs-fcs.o op-fs-fcm.o op-fm-fcs.o op-fm-fcm.o op-fcs-fs.o op-fcs-fm.o 
op-fcm-fs.o op-fcm-fm.o
op-fcs-fcs.o op-fcs-fcm.o op-fcm-fcs.o op-fcm-fcm.o fixed-var.o fixed.o
-Wl,--out-implib=liboctave_fixed.dll.a 
-L/usr/local/octave-3.0.0/lib/octave-3.0.0
-L/usr/local/octave-3.0.0/lib -loctinterp -loctave -lcruft -L/mingw/lib 
-L/usr/local/octave-3.0.0/lib
-L/GnuWin32/lib -L/GnuWin32/bin -llapack -ltmglib -lblas -lfftw3 -lreadline 
-ltermcap -lz -lm -luuid
-lgmp -lws2_32 -lkernel32 -L/mingw/lib -L/usr/local/octave-3.0.0/lib 
-L/GnuWin32/lib -L/GnuWin32/bin
-L/mingw/bin/../lib/gcc/mingw32/3.4.5 -L/mingw/bin/../lib/gcc
-L/mingw/bin/../lib/gcc/mingw32/3.4.5/../../../../mingw32/lib
-L/mingw/bin/../lib/gcc/mingw32/3.4.5/../../.. -lz -lm -luuid -lgmp -lfrtbegin 
-lg2c -lmingw32
-lmoldname -lmingwex -lmsvcrt -luser32 -lkernel32 -ladvapi32 -lshell32
Creating library file: liboctave_fixed.dll.a

Michael>This import lib is automatically generated by MSVC when there 
Michael>are exported symbols. This is not the case for MinGW, you need some 
Michael>additional compile flags.

You need some additional compile flags. ==> You need liboctave_fixed.dll.a

> How do you tell gcc that "oct" is a
> valid extension for a dll?

-shared -Wl,--export-all-symbols -Wl,--enable-auto-import 
-Wl,--enable-runtime-pseudo-reloc
--enable-auto-import -Wl, --out-implib=liboctave_fixed.dll.a   

The flag make it possible fixed.oct behaves as a dynamic link libraries.

Perhaps the MSVC case is similar, the difference is that the import lib is 
automatically generated by
MSVC as the Michael suggestion.  This was suggested in the long discussin with 
me, you and Michael.

I confirmed this like following

cd ../examples 
make

The make failed at the link, I manualy linked 
g++ -shared -Wl,--export-all-symbols -Wl,--enable-auto-import 
-Wl,--enable-runtime-pseudo-reloc -o
ffft.oct ffft.o -L/home/octaves/fixedSVN/fixed-0.7.5/src -loctave_fixed.dll
-L/usr/local/octave-3.0.0/lib/octave-3.0.0 -L/usr/local/octave-3.0.0/lib 
-loctinterp -loctave -lcruft
-L/mingw/lib -L/usr/local/octave-3.0.0/lib -L/GnuWin32/lib -L/GnuWin32/bin 
-llapack -ltmglib -lblas
-lfftw3 -lreadline -ltermcap -lz -lm -luuid -lgmp -lws2_32 -lkernel32 
-L/mingw/lib
-L/usr/local/octave-3.0.0/lib -L/GnuWin32/lib -L/GnuWin32/bin 
-L/mingw/bin/../lib/gcc/mingw32/3.4.5
-L/mingw/bin/../lib/gcc 
-L/mingw/bin/../lib/gcc/mingw32/3.4.5/../../../../mingw32/lib
-L/mingw/bin/../lib/gcc/mingw32/3.4.5/../../.. -lz -lm -luuid -lgmp -lfrtbegin 
-lg2c -lmingw32
-lmoldname -lmingwex -lmsvcrt -luser32 -lkernel32 -ladvapi32 -lshell32

-L../ -> -L/home/octaves/fixedSVN/fixed-0.7.5/src

After that 
octave 
addpath ("../src") 
a = ffft(fixed(6,4,32*randn(64,1)))

The window messages said that the dynamic link libarary fixed.oct was not 
found. 
(in reality it was represented in Japanese)
Please note that the exetention dll is not required for the windows dynamic 
link library.

Then
export PATH=/home/octaves/fixedSVN/fixed-0.7.5/src:$PATH
octave 
addpath ("../src") 
a = ffft(fixed(6,4,32*randn(64,1)))

a =

  -25.0000 +  0.0000i
  -24.0000 + 12.0000i
    4.0000 + 36.5000i
    1.0000 + 20.0000i
   -4.0000 - 15.5000i
   -5.0000 - 13.5000i
   -2.5000 + 33.0000i
   -6.5000 - 34.0000i
   15.0000 -  0.5000i
  -28.0000 - 25.5000i
  -16.5000 + 28.0000i
  -27.0000 - 24.0000i
   35.5000 - 14.5000i
  -20.5000 -  6.5000i
    9.0000 -  2.0000i
   12.5000 -  9.0000i
   21.5000 - 24.5000i
  -24.5000 + 15.0000i
   -5.0000 + 18.5000i
   -2.5000 - 16.5000i
  -28.5000 + 28.0000i
  -53.0000 - 16.0000i
        :
        :


Regards

Tatsuro

--- dbateman <[EMAIL PROTECTED]> wrote:

> 
> 
> 
> Tatsuro MATSUOKA-2 wrote:
> > 
> > Main problem is that new  Makefile by you  did not give a
> > liboctave_fixed.dll.a
> > so that the link seeme to be failed.
> > 
> 
> The idea was to try and link against the fixed.oct file rather than a
> separate library. That is what Michael did under MSVC, so I suspect there is
> some way to do it under mingw/cygwin. How do you tell gcc that "oct" is a
> valid extension for a dll?
> 
> 
> 
> > However my condition is not so good, I only just the report the results.
> > My feeling the previous fix is required for the cygwin/mingw.
> > For the dll point of view, the gcc exporting function is the same on the
> > cygwin and the mingw.
> > So that the treatments for dlls are the same.
> > 
> 
> This good in a way, as what work with mingw will alo work with cygwin. I
> hope you get better soon however..
> 
> Regards
> David
> -- 
> View this message in context:
> http://www.nabble.com/fixed-fails-to-build-on-linux-tp16220071p16367323.html
> Sent from the octave-dev mailing list archive at Nabble.com.
> 
> 
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
> _______________________________________________
> Octave-dev mailing list
> Octave-dev@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/octave-dev
> 


--------------------------------------
Easy + Joy + Powerful = Yahoo! Bookmarks x Toolbar
http://pr.mail.yahoo.co.jp/toolbar/

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Octave-dev mailing list
Octave-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/octave-dev

Reply via email to