Csound Csound-dev Csound-tekno Search About

[Cs-dev] MinGW Vs. MSVC

Date2012-01-31 00:27
FromAdam Puckett
Subject[Cs-dev] MinGW Vs. MSVC
Hey list,

I was wondering about compiler differences as related to Csound. I
know the release versions are built with MinGW, but I see in the main
directory of the sources a custom-msvc.py and a build-msvc.bat file.
Is MinGW the "preferred" compiler over MSVC for any reason? It seems
to me one could use MSVC to build PortAudio with kernel streaming
support which is lacking in MinGW, which is why I am experimenting
with an MSVC build. Also, how would one pull the sources from Git with
MSVC? Would I build Git/CVS/SVN from source?

Thanks for any help.

Adam

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2012-01-31 01:32
FromRory Walsh
SubjectRe: [Cs-dev] MinGW Vs. MSVC
Hi Adam. First thing to say is that Mike Goggins is the authority on
MSVC builds for Csound, hence he will be better able to advise you on
the subject than I. Secondly I'm not au fait with kernel streaming.
Nonetheless it might prove helpful to you if I explain how I use MSVC
in my work.

I use MSVC with Csound all the time, but I don't build Csound with
MSVC (I've tried but failed on several occasions!). I still build
Csound with MinGW but then link to the MinGW binaries in MSVC. A
typical approach for me is to build an audio app using MSVC and then
use Csound exclusively as the processing engine (through the use of
the API). In other words my MSVC compiled application takes care of
all the audio IO, much in the same way PortAudio could, but Csound
does all the signal processing.

The GUI and audio toolkits I use are distributed with excellent MSVC
sample projects so getting them up and running is really simple. On
top of that MSVC is a pretty nice IDE with a really intuitive
debugger. Linking the to Csound binaries takes a little tweaking
however. The last time I tried linking with the binaries that are
distributed with Csound for windows I had some issues with MinGW dlls.
I didn't have time to figure out the problem at the time, but linking
to MinGW Csound binaries I built myself did the trick (I should really
take the time to investigate the problem further!). Mike can probably
suggest a more straightforward solution however as it should be
possible to link directly to the libs that come with Csound for
windows, in fact I'm sure it is, it just needs to time.

I hope that helps in some way to explain one possible means of
combining the power of Csound with the power of the MSCV IDE and
compiler. Good luck with your research!

Rory.

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2012-01-31 07:22
FromMichael Gogins
SubjectRe: [Cs-dev] MinGW Vs. MSVC
AttachmentsNone  None  

MSVC is not supported for building Csound. The reasons are several but some are that MSVC does not support dynamically loading shared libraries compiled with the standard C++ library collections while MinGW does (Csound, CsoundAC, and some opcodes use these in places), OpenMP is not supported in MSVC Express Edition, and full optimization is not supported by Express Edition. That said, MSVC has been changing and the version of C++ that comes with theĀ  free Windows SDK is complete, but doesn't come with an IDE. So if you want to try to get the MSVC build of Csound working, feel free, buy it won't be easy.

The linking problems Rory mentions probably have to do with the need to have MSVC import libraries for the MinGW Csound API libraries, though these can be generated using Microft tools, and perhaps with different C++ ABIs.

As for PortAudio, go ahead and build it with MSVC, that should be better and I well probably start doing that myself.

On Jan 30, 2012 8:33 PM, "Rory Walsh" <rorywalsh@ear.ie> wrote:
Hi Adam. First thing to say is that Mike Goggins is the authority on
MSVC builds for Csound, hence he will be better able to advise you on
the subject than I. Secondly I'm not au fait with kernel streaming.
Nonetheless it might prove helpful to you if I explain how I use MSVC
in my work.

I use MSVC with Csound all the time, but I don't build Csound with
MSVC (I've tried but failed on several occasions!). I still build
Csound with MinGW but then link to the MinGW binaries in MSVC. A
typical approach for me is to build an audio app using MSVC and then
use Csound exclusively as the processing engine (through the use of
the API). In other words my MSVC compiled application takes care of
all the audio IO, much in the same way PortAudio could, but Csound
does all the signal processing.

The GUI and audio toolkits I use are distributed with excellent MSVC
sample projects so getting them up and running is really simple. On
top of that MSVC is a pretty nice IDE with a really intuitive
debugger. Linking the to Csound binaries takes a little tweaking
however. The last time I tried linking with the binaries that are
distributed with Csound for windows I had some issues with MinGW dlls.
I didn't have time to figure out the problem at the time, but linking
to MinGW Csound binaries I built myself did the trick (I should really
take the time to investigate the problem further!). Mike can probably
suggest a more straightforward solution however as it should be
possible to link directly to the libs that come with Csound for
windows, in fact I'm sure it is, it just needs to time.

I hope that helps in some way to explain one possible means of
combining the power of Csound with the power of the MSCV IDE and
compiler. Good luck with your research!

Rory.

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel

Date2012-01-31 14:12
FromAdam Puckett
SubjectRe: [Cs-dev] MinGW Vs. MSVC
OK, thanks Rory and Mike. I will probably build PortAudio with MSVC to
get kernel streaming support if possible and the rest of Csound with
MinGW.

On 1/31/12, Michael Gogins  wrote:
> MSVC is not supported for building Csound. The reasons are several but some
> are that MSVC does not support dynamically loading shared libraries
> compiled with the standard C++ library collections while MinGW does
> (Csound, CsoundAC, and some opcodes use these in places), OpenMP is not
> supported in MSVC Express Edition, and full optimization is not supported
> by Express Edition. That said, MSVC has been changing and the version of
> C++ that comes with the  free Windows SDK is complete, but doesn't come
> with an IDE. So if you want to try to get the MSVC build of Csound working,
> feel free, buy it won't be easy.
>
> The linking problems Rory mentions probably have to do with the need to
> have MSVC import libraries for the MinGW Csound API libraries, though these
> can be generated using Microft tools, and perhaps with different C++ ABIs.
>
> As for PortAudio, go ahead and build it with MSVC, that should be better
> and I well probably start doing that myself.
> On Jan 30, 2012 8:33 PM, "Rory Walsh"  wrote:
>
>> Hi Adam. First thing to say is that Mike Goggins is the authority on
>> MSVC builds for Csound, hence he will be better able to advise you on
>> the subject than I. Secondly I'm not au fait with kernel streaming.
>> Nonetheless it might prove helpful to you if I explain how I use MSVC
>> in my work.
>>
>> I use MSVC with Csound all the time, but I don't build Csound with
>> MSVC (I've tried but failed on several occasions!). I still build
>> Csound with MinGW but then link to the MinGW binaries in MSVC. A
>> typical approach for me is to build an audio app using MSVC and then
>> use Csound exclusively as the processing engine (through the use of
>> the API). In other words my MSVC compiled application takes care of
>> all the audio IO, much in the same way PortAudio could, but Csound
>> does all the signal processing.
>>
>> The GUI and audio toolkits I use are distributed with excellent MSVC
>> sample projects so getting them up and running is really simple. On
>> top of that MSVC is a pretty nice IDE with a really intuitive
>> debugger. Linking the to Csound binaries takes a little tweaking
>> however. The last time I tried linking with the binaries that are
>> distributed with Csound for windows I had some issues with MinGW dlls.
>> I didn't have time to figure out the problem at the time, but linking
>> to MinGW Csound binaries I built myself did the trick (I should really
>> take the time to investigate the problem further!). Mike can probably
>> suggest a more straightforward solution however as it should be
>> possible to link directly to the libs that come with Csound for
>> windows, in fact I'm sure it is, it just needs to time.
>>
>> I hope that helps in some way to explain one possible means of
>> combining the power of Csound with the power of the MSCV IDE and
>> compiler. Good luck with your research!
>>
>> Rory.
>>
>>
>> ------------------------------------------------------------------------------
>> Keep Your Developer Skills Current with LearnDevNow!
>> The most comprehensive online learning library for Microsoft developers
>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
>> Metro Style Apps, more. Free future releases when you subscribe now!
>> http://p.sf.net/sfu/learndevnow-d2d
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2012-01-31 22:53
FromVictor Lazzarini
Subject[Cs-dev] WASAPI (was Re: MinGW Vs. MSVC)
This reminds me of another issue. Portaudio implements WASAPI, which is supposed to be a low-latency out-of-the-box solution for Vista & 7 (no need for ASIO).
But for some reason, it does not work with Csound (although it works with the portaudio tests). Does anyone know why? Michael?

Regards

Victor

On 31 Jan 2012, at 14:12, Adam Puckett wrote:

> OK, thanks Rory and Mike. I will probably build PortAudio with MSVC to
> get kernel streaming support if possible and the rest of Csound with
> MinGW.
> 
> On 1/31/12, Michael Gogins  wrote:
>> MSVC is not supported for building Csound. The reasons are several but some
>> are that MSVC does not support dynamically loading shared libraries
>> compiled with the standard C++ library collections while MinGW does
>> (Csound, CsoundAC, and some opcodes use these in places), OpenMP is not
>> supported in MSVC Express Edition, and full optimization is not supported
>> by Express Edition. That said, MSVC has been changing and the version of
>> C++ that comes with the  free Windows SDK is complete, but doesn't come
>> with an IDE. So if you want to try to get the MSVC build of Csound working,
>> feel free, buy it won't be easy.
>> 
>> The linking problems Rory mentions probably have to do with the need to
>> have MSVC import libraries for the MinGW Csound API libraries, though these
>> can be generated using Microft tools, and perhaps with different C++ ABIs.
>> 
>> As for PortAudio, go ahead and build it with MSVC, that should be better
>> and I well probably start doing that myself.
>> On Jan 30, 2012 8:33 PM, "Rory Walsh"  wrote:
>> 
>>> Hi Adam. First thing to say is that Mike Goggins is the authority on
>>> MSVC builds for Csound, hence he will be better able to advise you on
>>> the subject than I. Secondly I'm not au fait with kernel streaming.
>>> Nonetheless it might prove helpful to you if I explain how I use MSVC
>>> in my work.
>>> 
>>> I use MSVC with Csound all the time, but I don't build Csound with
>>> MSVC (I've tried but failed on several occasions!). I still build
>>> Csound with MinGW but then link to the MinGW binaries in MSVC. A
>>> typical approach for me is to build an audio app using MSVC and then
>>> use Csound exclusively as the processing engine (through the use of
>>> the API). In other words my MSVC compiled application takes care of
>>> all the audio IO, much in the same way PortAudio could, but Csound
>>> does all the signal processing.
>>> 
>>> The GUI and audio toolkits I use are distributed with excellent MSVC
>>> sample projects so getting them up and running is really simple. On
>>> top of that MSVC is a pretty nice IDE with a really intuitive
>>> debugger. Linking the to Csound binaries takes a little tweaking
>>> however. The last time I tried linking with the binaries that are
>>> distributed with Csound for windows I had some issues with MinGW dlls.
>>> I didn't have time to figure out the problem at the time, but linking
>>> to MinGW Csound binaries I built myself did the trick (I should really
>>> take the time to investigate the problem further!). Mike can probably
>>> suggest a more straightforward solution however as it should be
>>> possible to link directly to the libs that come with Csound for
>>> windows, in fact I'm sure it is, it just needs to time.
>>> 
>>> I hope that helps in some way to explain one possible means of
>>> combining the power of Csound with the power of the MSCV IDE and
>>> compiler. Good luck with your research!
>>> 
>>> Rory.
>>> 
>>> 
>>> ------------------------------------------------------------------------------
>>> Keep Your Developer Skills Current with LearnDevNow!
>>> The most comprehensive online learning library for Microsoft developers
>>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
>>> Metro Style Apps, more. Free future releases when you subscribe now!
>>> http://p.sf.net/sfu/learndevnow-d2d
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>> 
>> 
> 
> ------------------------------------------------------------------------------
> Keep Your Developer Skills Current with LearnDevNow!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-d2d
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie




------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net