Csound Csound-dev Csound-tekno Search About

[CSOUND-DEV:3636] Re: widgets.cpp

Date2003-12-04 18:58
From"gogins@pipeline.com"
Subject[CSOUND-DEV:3636] Re: widgets.cpp
Yes, I think you're right, it sounds like we are talking about different
issues. I've only used mingw for CsoundVST or Csound, and I've only used
Cygwin at work, so I'm not experienced with Cygwin and Csound.

Original Message:
-----------------
From: stevenyi stevenyi@csounds.com
Date: Thu, 04 Dec 2003 09:20:36 -0800
To: csound-dev@eartha.mills.edu
Subject: [CSOUND-DEV:3635] Re: widgets.cpp


I think maybe we're talking about different things.  You're absolutely
correct in what you're saying if you're using mingw or cygwin but using
-mno-cygwin.  If you're not using -mno-cygwin, though, I've found there
to be linking issues.  

If you try compiling fluidOpcodes in the csound4 cvs using
Makefile.cygwin, you should compile without problem.  But if you take
out the -mno-cygwin in the makefile, you'll get linking errors with
fluidsynth.  Fluidsynth was generated with 

This also happened to me yesterday with compiling csound4 on Cygwin with
FLTK.  A couple of days ago I had used -mno-cygwin and compiled and
linked fine; yesterday without -mno-cygwin I couldn't link with FLTK.  

I'll compile fluidOpocdes without -mno-cygwin to find out the error that
I googled for that lead me to where I'm at now.  

steven




On Thu, 2003-12-04 at 08:34, gogins@pipeline.com wrote:
> This is only a little bit true.
> 
> If the dll was compiled by Microsoft or Borland and contains export
records
> (meaning you see symbols if you run dumpbin /exports xxxx.dll), then you
> CAN link with mingw or Cygwin. You may or may not have to supply
additional
> linker flags (use info ld to see them).
> 
> If the dll does NOT contain exports, then you can STILL link with mingw or
> Cygwin, but you have to get or make a .def file and then use dlltool to
> create an import library (libxxx.a for xxx.dll), and you must link with
the
> import library not the dll itself.
> 
> Only if the dll does not contain exports, and you do not have a
> gcc-compiled import library, can you not link gcc-compiled code with the
> dll.
> 
> 
> Original Message:
> -----------------
> From: stevenyi stevenyi@csounds.com
> Date: Thu, 04 Dec 2003 07:56:40 -0800
> To: csound-dev@eartha.mills.edu
> Subject: [CSOUND-DEV:3632] Re: widgets.cpp
> 
> 
> Are you using -mno-cygwin?  The compiles should be largely the same when
> -mno-cygwin and mingw.  Also, something I learned in general when
> building the fluidOpcodes stuff, you must be careful *not* to mix cygwin
> generated executables and mingw/-mno-cygwin/microsoft generated dll's. 
> This actually won't work at all (you'll get linker errors).  
> 
> FLTK libraries on windows come window-compiled, as do most anything
> that's GNU-compiled and publicly released.  To compile against FLTK on
> windows, you *have* to use -mno-cygwin or mingw, or compile FLTK
> yourself with Cygwin. 
> 
> Also, you can not release anything Cygwin-compiled publicly without the
> end-user having libcygwin.dll or statically-compiling in libcygwin.a
> which bloats the executable.
> 
> I'd prefer in the end *not* to use Cygwin without -mno-cygwin and that
> the autoconf stuff check to do so.  
> 
> (Someone feel free to correct me if I'm wrong in any of the above).
> 
> Thanks,
> steven
> 
> 
> On Thu, 2003-12-04 at 07:20, John D. Ramsdell wrote:
> > For work, I had to install Cygwin on my laptop, so I tested the
> > installation by building Csound.  I had no problems when I disabled
> > windows with the -enable-windows=no configure option.  I then tested
> > the program that repeatly runs Csound and it successfully rendered the
> > same input twenty times.  This is the test driver that causes Csound
> > built on MinGW to die a horrible death after only a few renderings.
> > Csound must be exercising buggy MinGW libraries routines.  I guess
> > I'll switch to Cygwin from now on.
> > 
> > I was unable to build Csound with FLTK on Cygwin.  It's that same
> > problem with widgets.cpp we had before.  Bobby, I changed the file to
> > a previous state because your changes seem to break John ffitch.
> > Please make your fixes in a manor that is only visible on Cygwin.
> > 
> > John
> > 
> > 
> 
> 
> --------------------------------------------------------------------
> mail2web - Check your email from the web at
> http://mail2web.com/ .
> 
> 
> 


--------------------------------------------------------------------
mail2web - Check your email from the web at
http://mail2web.com/ .

Date2003-12-04 20:45
Fromsteven
Subject[CSOUND-DEV:3638] Re: widgets.cpp
I looked into it a bit more and it's hard to find clear information on 
it.  When I don't compile with -mno-cygwin, I get errors looking for:

__imp___iob

from libfluidsynth.a.  using

nm libfluidsynth.a | grep __imp

it looks that it's using iob as an imported symbol. 

Now, I get confused here but there seem to be issues with when compiling 
with regular cygwin you're linking with libcygwin and when compiling 
with mingw/-mno-cygwin you're compiling against msvcrt, and mixing the 
two in any way is apparently *really* bad.  My guess is that for 
__imp____iob, it is not available in one of the cygwin compiled 
libraries but is in the microsoft libraries.

Anyways... the short version is I figured out is that it ends up being 
much easier for me to compile with mingw/-mno-cygwin than cygwin.  But 
I've also found it easier to use cygwin over mingw because of the bash 
shell and the locations of things being *nix-like, as well being able to 
run shell scripts like the autotools.  (I haven't tried MSYS however). 

For John R asking about -mno-cygwin: I've been putting it in as flag to 
both the compiler and linker.

steven


gogins@pipeline.com wrote:

>Yes, I think you're right, it sounds like we are talking about different
>issues. I've only used mingw for CsoundVST or Csound, and I've only used
>Cygwin at work, so I'm not experienced with Cygwin and Csound.
>  
>
>  
>

Date2003-12-05 14:45
Fromramsdell@mitre.org (John D. Ramsdell)
Subject[CSOUND-DEV:3660] Re: widgets.cpp
steven  writes:

> ... For John R asking about -mno-cygwin: I've been putting it in as
> flag to both the compiler and linker.

In configure.ac, I've added -mno-cygwin to various flags when
compiling on Cygwin.  The system builds on my laptop.

John