Steps to build csound on windows with MSVC

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Steps to build csound on windows with MSVC

Victor Lazzarini
MSVC build steps:

1. Requirements:

(a) python 2.3 (www.python.org)
  just install it as per instructions

(b) scons ((0.96 will do) (www.scons.org)
as above

(c) portaudio v.19 (www.portaudio.com)
unzip and go to the pa_win/msvc directory and follow the
readme instructions to build portaudio.

(d) portmidi (http://www-2.cs.cmu.edu/~music/portmusic/)
there is a MSVC project file that can be used to build portmidi in
the package.

(e) libsndfile (http://www.mega-nerd.com/libsndfile/)
I - make sure that your ENV variables and paths are set for MSVC
     (run vcsvars32.bat or add it to your autoexec.bat, on Windows 2000 this
       is probably already set when you install MSVC)
II -  go to Win32 directory, check that the MSVC directory path is correct
       in Makefile.msvc
II -  In the command line, run nmake Makefile.msvc

(f) FLTK  (I suggest 1.1.5rc3) (www.fltk.org)
There is a MSVC project (fltk.dsw) in the visualc directory

(g) dirent.h (http://www.uku.fi/~tronkko/dirent.h)
just download the file

2. Preparation:

(a) Now make sure that you have the following files:

dirent.h
fltk.lib
fltkforms.lib
fltkgl.lib
fltkimages.lib
libsndfile.def
libsndfile.lib
sndfile.lib (this is just a copy of libsndfile.lib renamed to sndfile.lib)
libsndfile.dll
portaudio.dll
portaudio.lib
portmidi.h
portmidi.lib
porttime.h
porttime.lib
python23.dll

(if you want to build the PD csoundapi~ class, also m_pd.h and pd.lib from
the PD distro)

and the following directories:

FL (from fltk, containing all the FLTK headers)
pa_common ( from portaudio, all the needed headers)
libsndfile (from libsndfile, all the needed headers)


(b) put all the directories and files in one place, say a msvc subdirectory
of csound5. Copy the DLLs to your system32 directory, if they are not
there yet.

(c) edit custom.py adding/editing the following lines (provided MSVC is
installed in the default location and you have added the msvc directory
to the csound5 directory as described above)

elif sys.platform[:3] == 'win':

     # For the basic build you need MinGW, MSys, and libsndfile.
     # Add them here:
     print "Adding custom path"
     customLIBPATH.append("c:/Program Files/Microsoft Visual Studio/vc98/Lib")
     customLIBPATH.append('msvc')
     customCPPPATH.append("c:/Program Files/Microsoft Visual
Studio/vc98/include")
     customCPPPATH.append("msvc/pa_common")
     customCPPPATH.append("msvc")
     # If libsndfile is not in a standard location add it here:
     customCPPPATH.append("./msvc/libsndfile")
     customCCFLAGS.append("-DMSVC")
     customCCFLAGS.append("-GX")
     customCCFLAGS.append("-MD")
     customCCFLAGS.append("-W2")
     customCCFLAGS.append("-Ob2")


2. Building csound

(a) Now you are ready to build csound with MSVC and scons

in the command line, cd to your csound5 directory and do

scons MSVC=1 noDebug=1

(b) if you want to build the PD class add buildPDClass=1 to it.

Disregard the warnings, if any. That should do it.

Victor

Victor Lazzarini
Music Technology Laboratory
Music Department
National University of Ireland, Maynooth

--
Send bugs reports to this list.
To unsubscribe, send email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Steps to build csound on windows with MSVC

Istvan Varga
Victor Lazzarini wrote:

> (f) FLTK  (I suggest 1.1.5rc3) (www.fltk.org)
> There is a MSVC project (fltk.dsw) in the visualc directory

Are any specials steps needed to enable threads and build as a
shared library (the equivalent of --enable-shared --enable-threads
with configure) ?
--
Send bugs reports to this list.
To unsubscribe, send email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Steps to build csound on windows with MSVC

Victor Lazzarini
Don't think so.  I think threads are enabled by default on Windows
(using the API functions _beginthread etc.). FLTK seems to behave
as elsewhere.

Victor

At 12:24 04/07/2005, you wrote:

>Victor Lazzarini wrote:
>
>>(f) FLTK  (I suggest 1.1.5rc3) (www.fltk.org)
>>There is a MSVC project (fltk.dsw) in the visualc directory
>
>Are any specials steps needed to enable threads and build as a
>shared library (the equivalent of --enable-shared --enable-threads
>with configure) ?
>--
>Send bugs reports to this list.
>To unsubscribe, send email to [hidden email]

Victor Lazzarini
Music Technology Laboratory
Music Department
National University of Ireland, Maynooth

--
Send bugs reports to this list.
To unsubscribe, send email to [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Steps to build csound on windows with MSVC

Michael Rempel
In reply to this post by Victor Lazzarini
Thanks very much Victor.

Michael

-----Original Message-----
From: Victor Lazzarini [mailto:[hidden email]]
Sent: Monday, July 04, 2005 5:56 AM
To: [hidden email]
Subject: [Csnd] Steps to build csound on windows with MSVC


MSVC build steps:

1. Requirements:

(a) python 2.3 (www.python.org)
  just install it as per instructions

(b) scons ((0.96 will do) (www.scons.org)
as above

(c) portaudio v.19 (www.portaudio.com)
unzip and go to the pa_win/msvc directory and follow the
readme instructions to build portaudio.

(d) portmidi (http://www-2.cs.cmu.edu/~music/portmusic/)
there is a MSVC project file that can be used to build portmidi in
the package.

(e) libsndfile (http://www.mega-nerd.com/libsndfile/)
I - make sure that your ENV variables and paths are set for MSVC
     (run vcsvars32.bat or add it to your autoexec.bat, on Windows 2000 this
       is probably already set when you install MSVC)
II -  go to Win32 directory, check that the MSVC directory path is correct
       in Makefile.msvc
II -  In the command line, run nmake Makefile.msvc

(f) FLTK  (I suggest 1.1.5rc3) (www.fltk.org)
There is a MSVC project (fltk.dsw) in the visualc directory

(g) dirent.h (http://www.uku.fi/~tronkko/dirent.h)
just download the file

2. Preparation:

(a) Now make sure that you have the following files:

dirent.h
fltk.lib
fltkforms.lib
fltkgl.lib
fltkimages.lib
libsndfile.def
libsndfile.lib
sndfile.lib (this is just a copy of libsndfile.lib renamed to sndfile.lib)
libsndfile.dll
portaudio.dll
portaudio.lib
portmidi.h
portmidi.lib
porttime.h
porttime.lib
python23.dll

(if you want to build the PD csoundapi~ class, also m_pd.h and pd.lib from
the PD distro)

and the following directories:

FL (from fltk, containing all the FLTK headers)
pa_common ( from portaudio, all the needed headers)
libsndfile (from libsndfile, all the needed headers)


(b) put all the directories and files in one place, say a msvc subdirectory
of csound5. Copy the DLLs to your system32 directory, if they are not
there yet.

(c) edit custom.py adding/editing the following lines (provided MSVC is
installed in the default location and you have added the msvc directory
to the csound5 directory as described above)

elif sys.platform[:3] == 'win':

     # For the basic build you need MinGW, MSys, and libsndfile.
     # Add them here:
     print "Adding custom path"
     customLIBPATH.append("c:/Program Files/Microsoft Visual
Studio/vc98/Lib")
     customLIBPATH.append('msvc')
     customCPPPATH.append("c:/Program Files/Microsoft Visual
Studio/vc98/include")
     customCPPPATH.append("msvc/pa_common")
     customCPPPATH.append("msvc")
     # If libsndfile is not in a standard location add it here:
     customCPPPATH.append("./msvc/libsndfile")
     customCCFLAGS.append("-DMSVC")
     customCCFLAGS.append("-GX")
     customCCFLAGS.append("-MD")
     customCCFLAGS.append("-W2")
     customCCFLAGS.append("-Ob2")


2. Building csound

(a) Now you are ready to build csound with MSVC and scons

in the command line, cd to your csound5 directory and do

scons MSVC=1 noDebug=1

(b) if you want to build the PD class add buildPDClass=1 to it.

Disregard the warnings, if any. That should do it.

Victor

Victor Lazzarini
Music Technology Laboratory
Music Department
National University of Ireland, Maynooth

--
Send bugs reports to this list.
To unsubscribe, send email to [hidden email]

--
Send bugs reports to this list.
To unsubscribe, send email to [hidden email]